I want to choose a random vector in high dimensions such that it all directions have the same uniform chance (i.e. isotropic in all directions). My current idea is the following algorithm:
- sample v from a high dim multivariate Gaussian
- then normalize that vector by dividing by its norm
I believe this is sufficient but don't know how to prove it. I know that high dimension stats can have weird behaviours (like most of the volume of a Gaussian is at the "edge") so I wanted to make sure I didn't miss anything trivial but important. Anyone know if this is correct? If it is how do I prove it?
What I have in mind in pytorch looks as follows:
v = MultivariateNormal(torch.zeros(10000), torch.eye(10000))
v = v/v.norm(10000)
v.norm(2)
isn't extremely small for numerical reasons; this is luckily very unlikely in high dimensions. $\endgroup$