4 ms·
The goal is not well-defined here. If the goal is to generate uniformly-distributed points in a circle then this algorithm is wrong, but it’s not clear that’s a
by ssfrr 5y ago
The goal is not well-defined here. If the goal is to generate uniformly-distributed points in a circle then this algorithm is wrong, but it’s not clear that’s actually what they want.
Generating a spectrum with a given magnitude distribution and uniform phase distribution is pretty common (at least in audio).
- cozzyd 5y agoYes, though e.g. if you want white nose you'd use a Rayleigh distribution for magnitude rather than a Gaussian as you would use for real and imaginary parts.