# $$\text{NormalCDF}$$¶

You can use the $$\text{NormalCDF}$$ function to calculate the cumulative distribution function (CDF) of the normal or Gaussian distribution.

You can use the \normalc backslash command to insert this function.

The following variants of this function are available:

• $$\text{real } \text{NormalCDF} \left ( \text{<x>} \right )$$

• $$\text{real } \text{NormalCDF} \left ( \text{<x>}, \text{<}\mu\text{>} \right )$$

• $$\text{real } \text{NormalCDF} \left ( \text{<x>}, \text{<}\mu\text{>}, \text{<}\sigma\text{>} \right )$$

The $$\text{x}$$, $$\text{<}\mu\text{>}$$, and $$\text{<}\sigma\text{>}$$ are scalar values representing the value of interest, the mean value of the distribution, and the standard deviation respectively. The $$\text{<}\mu\text{>}$$ and $$\text{<}\sigma\text{>}$$ parameters are optional. If the $$\text{<}\mu\text{>}$$ parameter is not included, a value of 0 is used. If the $$\text{<}\sigma\text{>}$$ parameter is not included, a value of 1 is used. Note that the function is defined over the range $$\sigma > 0$$ and will generate a run-time error or return NaN for values for which the function is not defined.

The returned value is calculated directly using the relation:

$\text{NormalCDF} \left ( x, \mu, \sigma \right ) = \frac{1}{2} \left [ 1 + \text{erf} \left ( \frac{x - \mu}{\sigma \sqrt{2}} \right ) \right ]$

The normal distribution is one of the most widely used distribution as it represents the sum of a large number of random processes with fininte mean and variance. The resulting distribution from the sum will approach the normal distribution as the number of random processes approaches infinity. In practice, only a small number of random processes are needed to obtain a close approximation of the normal distribution.

Figure 177 shows the basic use of the $$\text{NormalCDF}$$ function.

Figure 177 Example Use Of the NormalCDF Function