Skip to content

Turning uniform draws into normal draws

Question

What methods can you use to generate standard normal random variables starting from uniform random numbers?

Short answer

Inverse transform, Box-Muller, Marsaglia's polar method or rejection sampling. Inverse transform sets Z=Φ−1(U)Z=\Phi^{-1}(U) using an accurate rational approximation. Box-Muller maps two uniforms to −2ln⁡U1cos⁡(2πU2)\sqrt{-2\ln U_1}\cos(2\pi U_2) and the matching sine term, two independent normals. The polar method avoids trig by rejecting points outside the unit disc (acceptance π/4\pi/4); rejection from e.g. an exponential envelope also works.

Adapted from Zhou, A Practical Guide to Quantitative Finance Interviews, sec. 7.3 Numerical Methods, 'Monte Carlo simulation B', p.184; question and answer rewritten by SelfMadeQuant.com.

See the hint and the full worked solution in the question bank (free account).

Open the worked solution

Lessons behind this question

Start with a free lesson: Normal Distribution is part of a free topic. Create a free account, no card needed, to read it in full with worked solutions.

Read it free