Probability distribution
In
probability theory and
statistics , the Rayleigh distribution is a
continuous probability distribution for nonnegative-valued
random variables . Up to rescaling, it coincides with the
chi distribution with two
degrees of freedom .
The distribution is named after
Lord Rayleigh ().
[1]
A Rayleigh distribution is often observed when the overall magnitude of a vector in the plane is related to its directional
components . One example where the Rayleigh distribution naturally arises is when
wind velocity is analyzed in
two dimensions .
Assuming that each component is
uncorrelated ,
normally distributed with equal
variance , and zero
mean , which is infrequent, then the overall wind speed (
vector magnitude) will be characterized by a Rayleigh distribution.
A second example of the distribution arises in the case of random complex numbers whose real and imaginary components are independently and identically distributed
Gaussian with equal variance and zero mean. In that case, the absolute value of the complex number is Rayleigh-distributed.
Definition
The
probability density function of the Rayleigh distribution is
[2]
f
(
x
;
σ
)
=
x
σ
2
e
−
x
2
/
(
2
σ
2
)
,
x
≥
0
,
{\displaystyle f(x;\sigma )={\frac {x}{\sigma ^{2}}}e^{-x^{2}/(2\sigma ^{2})},\quad x\geq 0,}
where
σ
{\displaystyle \sigma }
is the
scale parameter of the distribution. The
cumulative distribution function is
[2]
F
(
x
;
σ
)
=
1
−
e
−
x
2
/
(
2
σ
2
)
{\displaystyle F(x;\sigma )=1-e^{-x^{2}/(2\sigma ^{2})}}
for
x
∈
0
,
∞
)
.
{\displaystyle x\in [0,\infty ).}
Relation to random vector length
Consider the two-dimensional vector
Y
=
(
U
,
V
)
{\displaystyle Y=(U,V)}
which has components that are
bivariate normally distributed , centered at zero, and independent.[
clarification needed ] Then
U
{\displaystyle U}
and
V
{\displaystyle V}
have density functions
f
U
(
x
;
σ
)
=
f
V
(
x
;
σ
)
=
e
−
x
2
/
(
2
σ
2
)
2
π
σ
2
.
{\displaystyle f_{U}(x;\sigma )=f_{V}(x;\sigma )={\frac {e^{-x^{2}/(2\sigma ^{2})}}{\sqrt {2\pi \sigma ^{2}}}}.}
Let
X
{\displaystyle X}
be the length of
Y
{\displaystyle Y}
. That is,
X
=
U
2
+
V
2
.
{\displaystyle X={\sqrt {U^{2}+V^{2}}}.}
Then
X
{\displaystyle X}
has cumulative distribution function
F
X
(
x
;
σ
)
=
∬
D
x
f
U
(
u
;
σ
)
f
V
(
v
;
σ
)
d
A
,
{\displaystyle F_{X}(x;\sigma )=\iint _{D_{x}}f_{U}(u;\sigma )f_{V}(v;\sigma )\,dA,}
where
D
x
{\displaystyle D_{x}}
is the disk
D
x
=
{
(
u
,
v
)
:
u
2
+
v
2
≤
x
}
.
{\displaystyle D_{x}=\left\{(u,v):{\sqrt {u^{2}+v^{2}}}\leq x\right\}.}
Writing the
double integral in
polar coordinates , it becomes
F
X
(
x
;
σ
)
=
1
2
π
σ
2
∫
0
2
π
∫
0
x
r
e
−
r
2
/
(
2
σ
2
)
d
r
d
θ
=
1
σ
2
∫
0
x
r
e
−
r
2
/
(
2
σ
2
)
d
r
.
{\displaystyle F_{X}(x;\sigma )={\frac {1}{2\pi \sigma ^{2}}}\int _{0}^{2\pi }\int _{0}^{x}re^{-r^{2}/(2\sigma ^{2})}\,dr\,d\theta ={\frac {1}{\sigma ^{2}}}\int _{0}^{x}re^{-r^{2}/(2\sigma ^{2})}\,dr.}
Finally, the probability density function for
X
{\displaystyle X}
is the derivative of its cumulative distribution function, which by the
fundamental theorem of calculus is
f
X
(
x
;
σ
)
=
d
d
x
F
X
(
x
;
σ
)
=
x
σ
2
e
−
x
2
/
(
2
σ
2
)
,
{\displaystyle f_{X}(x;\sigma )={\frac {d}{dx}}F_{X}(x;\sigma )={\frac {x}{\sigma ^{2}}}e^{-x^{2}/(2\sigma ^{2})},}
which is the Rayleigh distribution. It is straightforward to generalize to vectors of dimension other than 2.
There are also generalizations when the components have
unequal variance or correlations (
Hoyt distribution ), or when the vector Y follows a
bivariate Student t -distribution (see also:
Hotelling's T-squared distribution ).
[3]
Generalization to bivariate Student's t-distribution
Suppose
Y
{\displaystyle Y}
is a random vector with components
u
,
v
{\displaystyle u,v}
that follows a
multivariate t-distribution . If the components both have mean zero, equal variance, and are independent, the bivariate Student's-t distribution takes the form:
f
(
u
,
v
)
=
1
2
π
σ
2
(
1
+
u
2
+
v
2
ν
σ
2
)
−
ν
/
2
−
1
{\displaystyle f(u,v)={1 \over {2\pi \sigma ^{2}}}\left(1+{u^{2}+v^{2} \over {\nu \sigma ^{2}}}\right)^{-\nu /2-1}}
Let
R
=
U
2
+
V
2
{\displaystyle R={\sqrt {U^{2}+V^{2}}}}
be the magnitude of
Y
{\displaystyle Y}
. Then the
cumulative distribution function (CDF) of the magnitude is:
F
(
r
)
=
1
2
π
σ
2
∬
D
r
(
1
+
u
2
+
v
2
ν
σ
2
)
−
ν
/
2
−
1
d
u
d
v
{\displaystyle F(r)={1 \over {2\pi \sigma ^{2}}}\iint _{D_{r}}\left(1+{u^{2}+v^{2} \over {\nu \sigma ^{2}}}\right)^{-\nu /2-1}du\;dv}
where
D
r
{\displaystyle D_{r}}
is the disk defined by:
D
r
=
{
(
u
,
v
)
:
u
2
+
v
2
≤
r
}
{\displaystyle D_{r}=\left\{(u,v):{\sqrt {u^{2}+v^{2}}}\leq r\right\}}
Converting to
polar coordinates leads to the CDF becoming:
F
(
r
)
=
1
2
π
σ
2
∫
0
r
∫
0
2
π
ρ
(
1
+
ρ
2
ν
σ
2
)
−
ν
/
2
−
1
d
θ
d
ρ
=
1
σ
2
∫
0
r
ρ
(
1
+
ρ
2
ν
σ
2
)
−
ν
/
2
−
1
d
ρ
=
1
−
(
1
+
r
2
ν
σ
2
)
−
ν
/
2
{\displaystyle {\begin{aligned}F(r)&={1 \over {2\pi \sigma ^{2}}}\int _{0}^{r}\int _{0}^{2\pi }\rho \left(1+{\rho ^{2} \over {\nu \sigma ^{2}}}\right)^{-\nu /2-1}d\theta \;d\rho \\&={1 \over {\sigma ^{2}}}\int _{0}^{r}\rho \left(1+{\rho ^{2} \over {\nu \sigma ^{2}}}\right)^{-\nu /2-1}d\rho \\&=1-\left(1+{r^{2} \over {\nu \sigma ^{2}}}\right)^{-\nu /2}\end{aligned}}}
Finally, the
probability density function (PDF) of the magnitude may be derived:
f
(
r
)
=
F
′
(
r
)
=
r
σ
2
(
1
+
r
2
ν
σ
2
)
−
ν
/
2
−
1
{\displaystyle f(r)=F'(r)={r \over {\sigma ^{2}}}\left(1+{r^{2} \over {\nu \sigma ^{2}}}\right)^{-\nu /2-1}}
In the limit as
ν
→
∞
{\displaystyle \nu \rightarrow \infty }
, the Rayleigh distribution is recovered because:
lim
ν
→
∞
(
1
+
r
2
ν
σ
2
)
−
ν
/
2
−
1
=
e
−
r
2
/
2
σ
2
{\displaystyle \lim _{\nu \rightarrow \infty }\left(1+{r^{2} \over {\nu \sigma ^{2}}}\right)^{-\nu /2-1}=e^{-r^{2}/2\sigma ^{2}}}
Properties
The
raw moments are given by:
μ
j
=
σ
j
2
j
/
2
Γ
(
1
+
j
2
)
,
{\displaystyle \mu _{j}=\sigma ^{j}2^{j/2}\,\Gamma \left(1+{\frac {j}{2}}\right),}
where
Γ
(
z
)
{\displaystyle \Gamma (z)}
is the
gamma function .
The
mean of a Rayleigh random variable is thus :
μ
(
X
)
=
σ
π
2
≈
1.253
σ
.
{\displaystyle \mu (X)=\sigma {\sqrt {\frac {\pi }{2}}}\ \approx 1.253\ \sigma .}
The
standard deviation of a Rayleigh random variable is:
std
(
X
)
=
(
2
−
π
2
)
σ
≈
0.655
σ
{\displaystyle \operatorname {std} (X)={\sqrt {\left(2-{\frac {\pi }{2}}\right)}}\sigma \approx 0.655\ \sigma }
The
variance of a Rayleigh random variable is :
var
(
X
)
=
μ
2
−
μ
1
2
=
(
2
−
π
2
)
σ
2
≈
0.429
σ
2
{\displaystyle \operatorname {var} (X)=\mu _{2}-\mu _{1}^{2}=\left(2-{\frac {\pi }{2}}\right)\sigma ^{2}\approx 0.429\ \sigma ^{2}}
The
mode is
σ
,
{\displaystyle \sigma ,}
and the maximum pdf is
f
max
=
f
(
σ
;
σ
)
=
1
σ
e
−
1
/
2
≈
0.606
σ
.
{\displaystyle f_{\max }=f(\sigma ;\sigma )={\frac {1}{\sigma }}e^{-1/2}\approx {\frac {0.606}{\sigma }}.}
The
skewness is given by:
γ
1
=
2
π
(
π
−
3
)
(
4
−
π
)
3
/
2
≈
0.631
{\displaystyle \gamma _{1}={\frac {2{\sqrt {\pi }}(\pi -3)}{(4-\pi )^{3/2}}}\approx 0.631}
The excess
kurtosis is given by:
γ
2
=
−
6
π
2
−
24
π
+
16
(
4
−
π
)
2
≈
0.245
{\displaystyle \gamma _{2}=-{\frac {6\pi ^{2}-24\pi +16}{(4-\pi )^{2}}}\approx 0.245}
The
characteristic function is given by:
φ
(
t
)
=
1
−
σ
t
e
−
1
2
σ
2
t
2
π
2
erfi
(
σ
t
2
)
−
i
{\displaystyle \varphi (t)=1-\sigma te^{-{\frac {1}{2}}\sigma ^{2}t^{2}}{\sqrt {\frac {\pi }{2}}}\left[\operatorname {erfi} \left({\frac {\sigma t}{\sqrt {2}}}\right)-i\right]}
where
erfi
(
z
)
{\displaystyle \operatorname {erfi} (z)}
is the imaginary
error function . The
moment generating function is given by
M
(
t
)
=
1
+
σ
t
e
1
2
σ
2
t
2
π
2
erf
(
σ
t
2
)
+
1
{\displaystyle M(t)=1+\sigma t\,e^{{\frac {1}{2}}\sigma ^{2}t^{2}}{\sqrt {\frac {\pi }{2}}}\left[\operatorname {erf} \left({\frac {\sigma t}{\sqrt {2}}}\right)+1\right]}
where
erf
(
z
)
{\displaystyle \operatorname {erf} (z)}
is the
error function .
Differential entropy
The
differential entropy is given by[
citation needed ]
H
=
1
+
ln
(
σ
2
)
+
γ
2
{\displaystyle H=1+\ln \left({\frac {\sigma }{\sqrt {2}}}\right)+{\frac {\gamma }{2}}}
where
γ
{\displaystyle \gamma }
is the
Euler–Mascheroni constant .
Parameter estimation
Given a sample of N
independent and identically distributed Rayleigh random variables
x
i
{\displaystyle x_{i}}
with parameter
σ
{\displaystyle \sigma }
,
σ
2
^
=
1
2
N
∑
i
=
1
N
x
i
2
{\displaystyle {\widehat {\sigma ^{2}}}=\!\,{\frac {1}{2N}}\sum _{i=1}^{N}x_{i}^{2}}
is the
maximum likelihood estimate and also is
unbiased .
σ
^
≈
1
2
N
∑
i
=
1
N
x
i
2
{\displaystyle {\widehat {\sigma }}\approx {\sqrt {{\frac {1}{2N}}\sum _{i=1}^{N}x_{i}^{2}}}}
is a biased estimator that can be corrected via the formula
σ
=
σ
^
Γ
(
N
)
N
Γ
(
N
+
1
2
)
=
σ
^
4
N
N
!
(
N
−
1
)
!
N
(
2
N
)
!
π
{\displaystyle \sigma ={\widehat {\sigma }}{\frac {\Gamma (N){\sqrt {N}}}{\Gamma \left(N+{\frac {1}{2}}\right)}}={\widehat {\sigma }}{\frac {4^{N}N!(N-1)!{\sqrt {N}}}{(2N)!{\sqrt {\pi }}}}}
[4]
=
σ
^
c
4
(
2
N
+
1
)
{\displaystyle ={\frac {\hat {\sigma }}{c_{4}(2N+1)}}}
, where
c4 is the correction factor used to unbias estimates of standard deviation for normal random variables .
Confidence intervals
To find the (1 − α ) confidence interval, first find the bounds
a
,
b
{\displaystyle [a,b]}
where:
P
(
χ
2
N
2
≤
a
)
=
α
/
2
,
P
(
χ
2
N
2
≤
b
)
=
1
−
α
/
2
{\displaystyle P\left(\chi _{2N}^{2}\leq a\right)=\alpha /2,\quad P\left(\chi _{2N}^{2}\leq b\right)=1-\alpha /2}
then the scale parameter will fall within the bounds
N
x
2
¯
b
≤
σ
2
^
≤
N
x
2
¯
a
{\displaystyle {\frac {{N}{\overline {x^{2}}}}{b}}\leq {\widehat {\sigma ^{2}}}\leq {\frac {{N}{\overline {x^{2}}}}{a}}}
[5]
Generating random variates
Given a random variate U drawn from the
uniform distribution in the interval (0, 1), then the variate
X
=
σ
−
2
ln
U
{\displaystyle X=\sigma {\sqrt {-2\ln U}}\,}
has a Rayleigh distribution with parameter
σ
{\displaystyle \sigma }
. This is obtained by applying the
inverse transform sampling -method.
Related distributions
R
∼
R
a
y
l
e
i
g
h
(
σ
)
{\displaystyle R\sim \mathrm {Rayleigh} (\sigma )}
is Rayleigh distributed if
R
=
X
2
+
Y
2
{\displaystyle R={\sqrt {X^{2}+Y^{2}}}}
, where
X
∼
N
(
0
,
σ
2
)
{\displaystyle X\sim N(0,\sigma ^{2})}
and
Y
∼
N
(
0
,
σ
2
)
{\displaystyle Y\sim N(0,\sigma ^{2})}
are independent
normal random variables .
[6] This gives motivation to the use of the symbol
σ
{\displaystyle \sigma }
in the above parametrization of the Rayleigh density.
The magnitude
|
z
|
{\displaystyle |z|}
of a
standard complex normally distributed variable z is Rayleigh distributed.
The
chi distribution with v = 2 is equivalent to the Rayleigh Distribution with σ = 1:
R
(
σ
)
∼
σ
χ
2
.
{\displaystyle R(\sigma )\sim \sigma \chi _{2}^{\,}\ .}
If
R
∼
R
a
y
l
e
i
g
h
(
1
)
{\displaystyle R\sim \mathrm {Rayleigh} (1)}
, then
R
2
{\displaystyle R^{2}}
has a
chi-squared distribution with 2 degrees of freedom:
Q
=
R
(
σ
)
2
∼
σ
2
χ
2
2
.
{\displaystyle [Q=R(\sigma )^{2}]\sim \sigma ^{2}\chi _{2}^{2}\ .}
If
R
∼
R
a
y
l
e
i
g
h
(
σ
)
{\displaystyle R\sim \mathrm {Rayleigh} (\sigma )}
, then
∑
i
=
1
N
R
i
2
{\displaystyle \sum _{i=1}^{N}R_{i}^{2}}
has a
gamma distribution with parameters
N
{\displaystyle N}
and
1
2
σ
2
{\displaystyle {\frac {1}{2\sigma ^{2}}}}
Y
=
∑
i
=
1
N
R
i
2
∼
Γ
(
N
,
1
2
σ
2
)
.
{\displaystyle \left[Y=\sum _{i=1}^{N}R_{i}^{2}\right]\sim \Gamma \left(N,{\frac {1}{2\sigma ^{2}}}\right).}
The
Rice distribution is a
noncentral generalization of the Rayleigh distribution:
R
a
y
l
e
i
g
h
(
σ
)
=
R
i
c
e
(
0
,
σ
)
{\displaystyle \mathrm {Rayleigh} (\sigma )=\mathrm {Rice} (0,\sigma )}
.
The
Weibull distribution with the
shape parameter k = 2 yields a Rayleigh distribution. Then the Rayleigh distribution parameter
σ
{\displaystyle \sigma }
is related to the Weibull scale parameter according to
λ
=
σ
2
.
{\displaystyle \lambda =\sigma {\sqrt {2}}.}
If
X
{\displaystyle X}
has an
exponential distribution
X
∼
E
x
p
o
n
e
n
t
i
a
l
(
λ
)
{\displaystyle X\sim \mathrm {Exponential} (\lambda )}
, then
Y
=
X
∼
R
a
y
l
e
i
g
h
(
1
/
2
λ
)
.
{\displaystyle Y={\sqrt {X}}\sim \mathrm {Rayleigh} (1/{\sqrt {2\lambda }}).}
The
half-normal distribution is the one-dimensional equivalent of the Rayleigh distribution.
The
Maxwell–Boltzmann distribution is the three-dimensional equivalent of the Rayleigh distribution.
Applications
An application of the estimation of σ can be found in
magnetic resonance imaging (MRI). As MRI images are recorded as
complex images but most often viewed as magnitude images, the background data is Rayleigh distributed. Hence, the above formula can be used to estimate the noise variance in an MRI image from background data.
[7]
[8]
The Rayleigh distribution was also employed in the field of
nutrition for linking
dietary
nutrient levels and
human and
animal responses. In this way, the
parameter σ may be used to calculate nutrient response relationship.
[9]
In the field of
ballistics , the Rayleigh distribution is used for calculating the
circular error probable —a measure of a gun's precision.
In
physical oceanography , the distribution of
significant wave height approximately follows a Rayleigh distribution.
[10]
See also
References
^ "The Wave Theory of Light", Encyclopedic Britannica 1888; "The Problem of the Random Walk", Nature 1905 vol.72 p.318
^
a
b Papoulis, Athanasios; Pillai, S. (2001) Probability, Random Variables and Stochastic Processes .
ISBN
0073660116 ,
ISBN
9780073660110 [
page needed ]
^ Röver, C. (2011). "Student-t based filter for robust signal detection". Physical Review D . 84 (12): 122004.
arXiv :
1109.0442 .
Bibcode :
2011PhRvD..84l2004R .
doi :
10.1103/physrevd.84.122004 .
^
Siddiqui, M. M. (1964) "Statistical inference for Rayleigh distributions", The Journal of Research of the National Bureau of Standards, Sec. D: Radio Science , Vol. 68D, No. 9, p. 1007
^
Siddiqui, M. M. (1961) "Some Problems Connected With Rayleigh Distributions", The Journal of Research of the National Bureau of Standards; Sec. D: Radio Propagation , Vol. 66D, No. 2, p. 169
^
Hogema, Jeroen (2005) "Shot group statistics"
^ Sijbers, J.; den Dekker, A. J.; Raman, E.; Van Dyck, D. (1999). "Parameter estimation from magnitude MR images". International Journal of Imaging Systems and Technology . 10 (2): 109–114.
CiteSeerX
10.1.1.18.1228 .
doi :
10.1002/(sici)1098-1098(1999)10:2<109::aid-ima2>3.0.co;2-r .
^ den Dekker, A. J.; Sijbers, J. (2014). "Data distributions in magnetic resonance images: a review". Physica Medica . 30 (7): 725–741.
doi :
10.1016/j.ejmp.2014.05.002 .
PMID
25059432 .
^ Ahmadi, Hamed (2017-11-21).
"A mathematical function for the description of nutrient-response curve" . PLOS ONE . 12 (11): e0187292.
Bibcode :
2017PLoSO..1287292A .
doi :
10.1371/journal.pone.0187292 .
ISSN
1932-6203 .
PMC
5697816 .
PMID
29161271 .
^
"Rayleigh Probability Distribution Applied to Random Wave Heights" (PDF) . United States Naval Academy.
Discrete univariate
with finite support with infinite support
Continuous univariate
supported on a bounded interval supported on a semi-infinite interval supported on the whole real line with support whose type varies
Mixed univariate
Multivariate (joint)
Directional
Degenerate and
singular Families