Normal Distribution

Author

Eric W. Weisstein
April 19, 2024

This notebook downloaded from http://mathworld.wolfram.com/notebooks/Statistics/NormalDistribution.nb.

For more information, see Eric's MathWorld entry http://mathworld.wolfram.com/NormalDistribution.html.

©2024 Wolfram Research, Inc. except for portions noted otherwise

Usage

?NormalDistribution

Plots

MakeBoxes[PDF[x_],TraditionalForm]:=RowBox[{"D","(",MakeBoxes[x,TraditionalForm],")"}]

MakeBoxes[CDF[x_],TraditionalForm]:=RowBox[{"P","(",MakeBoxes[x,TraditionalForm],")"}]

GraphicsRow[
Table[Plot[f[NormalDistribution[0,1],x],{x,-5,5},AxesLabel->TraditionalForm/@{x,f[x]},Ticks->None,BaseStyle->Directive[14,FontFamily->"Times"],PlotStyle->Red],{f,{PDF,CDF}}]
]

Limit of binomial distribution

With[{n=15,p=.5,samples=10^4},
Show[{
Histogram[RandomVariate[BinomialDistribution[n,p],samples],Automatic,"PDF",ChartStyle->Red],
Plot[(1/(Sqrt[2π n p(1-p)]))Exp[-(((((x-n p))^2)/2)/(n p(1-p)))],{x,1,n},PlotStyle->Black]
},BaseStyle->Directive[12,FontFamily->"Times"],AxesLabel->{Style["n",Italic],(Subscript[P, p])[Style["n",Italic]|n]}]]

Stats

Stats[NormalDistribution[μ,σ],x]//StatsForm//TraditionalForm

Normalization

Integrate[Exp[-(x-μ)^2/(2σ^2)],{x,-∞,∞},Assumptions->σ>0]/(σ Sqrt[2π])

PDF

PDF[NormalDistribution[μ,σ],x]//TraditionalForm

CDF

Integrate[Exp[-(x-μ)^2/(2σ^2)],{x,-∞,x},Assumptions->σ>0]/(σ Sqrt[2π])

Moments

Kurtosis

Kurtosis[NormalDistribution[μ,σ]]

KurtosisExcess[NormalDistribution[μ,σ]]

Cumulants

v4.2.1

FourierTransform[PDF[NormalDistribution[μ,σ],x],x,t,Assumptions->σ>0]

FullSimplify[%]

FourierTransform[PDF[NormalDistribution[μ,σ],x],x,t]

Simplify[%,σ>0]

v5.0.0

FourierTransform[PDF[NormalDistribution[μ,σ],x],x,t]//Timing

FourierTransform[PDF[NormalDistribution[μ,σ],x],x,t,Assumptions->σ>0]//Timing

v5.0.1

FourierTransform[PDF[NormalDistribution[μ,σ],x],x,t]//Timing

FourierTransform[PDF[NormalDistribution[μ,σ],x],x,t,Assumptions->σ>0]//Timing

v5.1

FourierTransform[PDF[NormalDistribution[μ,σ],x],x,t]//Timing

FourierTransform[PDF[NormalDistribution[μ,σ],x],x,t,Assumptions->σ>0]//Timing

v6

FourierTransform[PDF[NormalDistribution[μ,σ],x],x,t]//Timing

FourierTransform[PDF[NormalDistribution[μ,σ],x],x,t,Assumptions->σ>0]

Series

ser=SeriesTerm[-(1/2) t (-2 I μ+t (σ^2)),{t,0,n}]

ser n!/I^n/.n->1

ser n!/I^n/.n->2

ser=(1/2) (-(σ^2) KroneckerDelta[-2+n]+2 I μ KroneckerDelta[-1+n]);Simplify[ser n!/I^n,n>2]

Characteristic Function

v4.2.1

FourierTransform[1/σ/Sqrt[2Pi] Exp[-(x-μ)^2/σ^2/2],x,t]//Timing

FourierTransform[1/σ/Sqrt[2Pi] Exp[-(x-μ)^2/σ^2/2],x,t,Assumptions->σ>0]//FullSimplify//Timing

...messy...

InverseFourierTransform[((E^(-(1/2) t (-2 I μ+t (σ^2)))))^n,t,x,Assumptions->σ>0]//Timing

v5.0.0

FourierTransform[1/σ/Sqrt[2Pi] Exp[-(x-μ)^2/σ^2/2],x,t]//Timing

...unevaluated...

FourierTransform[1/σ/Sqrt[2Pi] Exp[-(x-μ)^2/σ^2/2],x,t,Assumptions->σ>0]//Timing

InverseFourierTransform[((E^(-(1/2) t (-2 I μ+t (σ^2)))))^n,t,x,Assumptions->σ>0]//Timing

...wrong...

v5.0.1

FourierTransform[1/σ/Sqrt[2Pi] Exp[-(x-μ)^2/σ^2/2],x,t]//Timing

...wrong...

FourierTransform[1/σ/Sqrt[2Pi] Exp[-(x-μ)^2/σ^2/2],x,t,Assumptions->σ>0]//Timing

InverseFourierTransform[((E^(-(1/2) t (-2 I μ+t (σ^2)))))^n,t,x,Assumptions->σ>0]//Timing

...wrong...

v5.1

FourierTransform[1/σ/Sqrt[2Pi] Exp[-(x-μ)^2/σ^2/2],x,t]//Timing

FourierTransform[1/σ/Sqrt[2Pi] Exp[-(x-μ)^2/σ^2/2],x,t,Assumptions->σ>0]//Timing

InverseFourierTransform[((E^(-(1/2) t (-2 I μ+t (σ^2)))))^n,t,x,Assumptions->σ>0]//Timing