Probabilities::NormalPDF Function

Overload List

#SignatureDescription
1double NormalPDF(double x, double Mu, double sigma);Normal (Gaussian) probability density function (PDF).
2void NormalPDF(TDenseMtxVec *X, double Mu, double sigma, TDenseMtxVec *Res);Normal distribution PDF (vectorized).
3void NormalPDF(TDenseMtxVec *X, TDenseMtxVec *Mu, TDenseMtxVec *sigma, TDenseMtxVec *Res);Normal distribution PDF (vectorized).

Overload 1: double NormalPDF(double x, double Mu, double sigma);

Normal (Gaussian) probability density function (PDF).

#NameTypeDescription
1xdoubleFunction domain, any real value.
2MudoubleDistribution location parameter (mean), any real value.
3sigmadoubleDistribution scale parameter (standard deviation), real value > 0.

Returns: the normal probability density function (PDF) at x for mean Mu and standard deviation sigma. Returns NAN when sigma <= 0.

Remarks:

Computes the normal PDF

PDF(x|mu,sigma )= 1/(sigma sqrt(2pi)) exp ( - ((x-mu)^2)/(2sigma ^2))

where mu (Mu) is the mean and sigma (sigma) the standard deviation. The special case mu=0,sigma=1 is the standard normal distribution. Domain: x in R, mu in R, sigma > 0. If sigma <= 0 the result is NAN.

Overloads: a scalar form (this one) and vectorized forms taking a TDenseMtxVec domain (vector or matrix), with the parameters supplied either as scalars or as per-element vectors; the result operand is auto-sized to the domain.

See Also: Probabilities::NormalCDF, Probabilities::NormalCDFInv
Declared in Dew::Math::Units::Probabilities · Dew.Math/Units.Probabilities.h · Cross-compiler

Overload 2: void NormalPDF(TDenseMtxVec *X, double Mu, double sigma, TDenseMtxVec *Res);

Normal distribution PDF (vectorized).

#NameTypeDescription
1XTDenseMtxVec *Defines distribution domain, real vector or matrix.
2MudoubleDistribution location parameter, real value.
3sigmadoubleDistribution scale parameter, real positive value.
4ResTDenseMtxVec *After calculation stores the PDF calculated from X, Mu and sigma. Length and Complex properties of Res are adjusted automatically to match Length and Complex properties of X.
Declared in Dew::Math::Units::Probabilities · Dew.Math/Units.Probabilities.h · Cross-compiler

Overload 3: void NormalPDF(TDenseMtxVec *X, TDenseMtxVec *Mu, TDenseMtxVec *sigma, TDenseMtxVec *Res);

Normal distribution PDF (vectorized).

#NameTypeDescription
1XTDenseMtxVec *Defines distribution domain, real vector or matrix.
2MuTDenseMtxVec *Distribution location parameter, real vector or matrix.
3sigmaTDenseMtxVec *Distribution scale parameter, real positive vector or matrix.
4ResTDenseMtxVec *After calculation stores the PDF calculated from X, Mu and sigma. Length and Complex properties of Res are adjusted automatically to match Length and Complex properties of X.
Declared in Dew::Math::Units::Probabilities · Dew.Math/Units.Probabilities.h · Cross-compiler