# SuanShu, a Java numerical and statistical library

com.numericalmethod.suanshu.analysis.function.special.gaussian

## Class CumulativeNormalHastings

• All Implemented Interfaces:
Function<Vector,Double>, RealScalarFunction, UnivariateRealFunction, StandardCumulativeNormal

public class CumulativeNormalHastings
extends AbstractUnivariateRealFunction
implements StandardCumulativeNormal
Hastings algorithm is faster but less accurate way to compute the cumulative standard Normal. It has a maximum absolute error less than 7.5e-8.
• "Hastings, C., Jr. "Approximations for Digital Computers," Princeton University Press, Princeton, NJ. 1995."
• "Abramowitz, M., and Stegun, I.A, Handbook of Mathematical Functions, National Bureau of Standards, Washington, D.C. Reprinted by Dover, New York. 1964."

• ### Nested classes/interfaces inherited from interface com.numericalmethod.suanshu.analysis.function.Function

Function.EvaluationException
• ### Constructor Summary

Constructors
Constructor and Description
CumulativeNormalHastings()
• ### Method Summary

All Methods
Modifier and Type Method and Description
double evaluate(double x)
Evaluate $$F(x;\,\mu,\sigma^2)$$.
• ### Methods inherited from class com.numericalmethod.suanshu.analysis.function.rn2r1.univariate.AbstractUnivariateRealFunction

evaluate
• ### Methods inherited from class com.numericalmethod.suanshu.analysis.function.rn2r1.AbstractRealScalarFunction

dimensionOfDomain, dimensionOfRange
• ### Methods inherited from class java.lang.Object

clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
• ### Methods inherited from interface com.numericalmethod.suanshu.analysis.function.Function

dimensionOfDomain, dimensionOfRange
• ### Constructor Detail

• #### CumulativeNormalHastings

public CumulativeNormalHastings()
• ### Method Detail

• #### evaluate

public double evaluate(double x)
Description copied from interface: StandardCumulativeNormal
Evaluate $$F(x;\,\mu,\sigma^2)$$.
Specified by:
evaluate in interface UnivariateRealFunction
Specified by:
evaluate in interface StandardCumulativeNormal
Parameters:
x - x
Returns:
$$F(x;\,1,1)$$