/span>, where
<span class="math inline">\(\Phi\)</span> is the inverse cumulative distribution function for the
standard normal, and then finally, scale and translate, <span class="math inline">\(y = \mu + \sigma \cdot z\)</span>. In code,</p>
<pre><code>real my_normal_rng(real mu, real sigma) {
  real u = uniform_rng(0, 1);
  real z = Phi(u);
  real y = mu + sigma * z;
  return y;
}</code></pre>
<p>A robust version of this function would test that the arguments are
finite and that <code>sigma</code> is non