rand_unit_vector¶
Get a random unit vector with num_dims
dimensions.
Arguments¶
num_dims
- Number of dimensions.
Return values¶
r
- A random unit vector withnum_dims
dimensions.
Note¶
This function is stochastic. For reproducibility set the PRNG seed with
cluseed()
as discussed in the Reference.