Loading [MathJax]/jax/output/HTML-CSS/fonts/TeX/fontdata.js

Two-Dimensional Gaussian Random Variables

From LNTwww

Probability density function and cumulative distribution function


All previous statements of the fourth main chapter  "Random Variables with Statistical Dependence"  apply in general.

For the special case  Gaussian random variables  – the name goes back to the scientist  Carl Friedrich Gauss  – we can further note:

  • The joint probability density function of a two-dimensional Gaussian random variable  (x,y)  with mean values  mx=0my=0  and correlation coefficient  ρxy  is:
fxy(x,y)=12πσxσy1ρ2xyexp[12(1ρ2xy)(x2σ2x+y2σ2y2ρxyxyσxσy)].
  • Replacing  x  by  (xmx)  and  y  by  (ymy),  we obtain the more general PDF of a two-dimensional Gaussian random variable with mean.
  • The two marginal probability density functions fx(x)  and fy(y)  of a two-dimensional Gaussian random variable are also Gaussian with rms values  σx  and σy, resp.
  • For uncorrelated components  x  and  y  in the above equation  ρxy=0  must be substituted,  and then the result is obtained:
fxy(x,y)=12πσxex2/(2σ2x)12πσyey2/(2σ2y)=fx(x)fy(y).

Conclusion:  In the special case of a 2D random variable with Gaussian PDF  fxy(x,y),  "statistical independence"  follows directly from  "uncorrelatedness":

fxy(x,y)=fx(x)fy(y).

Please note:

  • In no other PDF can  "uncorrelatedness"  be used to infer  "statistical independence".
  • However,  one can always   ⇒   for any two-dimensional PDF  fxy(x,y)  infer "uncorrelatedness" from "statistical independence"  because:
If two random variables  x  and  y  are completely  (statistically)  independent of each other, 
then of course there are no  "linear dependencies"  between them   ⇒   they are also uncorrelated.


The interactive HTML5/JavaScript applet  "Two-dimensional Gaussian Random Variables"  plots the 2D functions PDF and CDF for arbitrary values of  σx, σy  and  ρxy.

Two-dimensional Gaussian PDF and CDF

Example 1:  The graphic shows

  • the probability density function  (left),
  • cumulative distribution function  (right)


of a two-dimensional Gaussian random variable  (x,y)  with relatively strong positive correlation of the individual components:  

ρxy=0.8.

As in the  previous examples,  the random variable is more extended in  x  direction than in  y  direction:   σx=2σy.
These representations can be interpreted as follows:

  • The PDF here is comparable to a mountain ridge extending from the lower left to the upper right.
  • The maximum is at  mx=0  and  my=0.  This means that the the two-dimensional random variable is mean-free.
  • The 2D–CDF as the integral in two directions over the 2D–PDF increases continuously from lower left to upper right from  0  to  1.



Contour lines for uncorrelated random variables


Contour lines of 2D–PDF with uncorrelated variables

From the conditional equation  fxy(x,y)=const.  the contour lines of the PDF can be calculated.

If the components  x  and  y  are uncorrelated  (ρxy=0),  the equation obtained for the contour lines is:

x2σ2x+y2σ2y=const.

In this case,  the contour lines describe the following figures:

  • "Circles"  (for  σx=σy,   green curve), or
  • "Ellipses"  (for  σxσy,   blue curve) in alignment of the two axes.


More information on this topic with signal examples is provided in the first part "Gaussian random variables without statistical bindings" of the learning video (German).

Gaussian 2D random variables.


Screen capture of tutorial video "Gaussian 2D random variables"

Example 2: 

  • More information on this topic with signal examples is provided in the first part "Gaussian random variables without statistical bindings" of the learning video (German).
Gaussian 2D random variables.
  • The graphic shows a snapshot of this learning video.


  • The second part covers "Gaussian random variables with statistical bindings" according to the following section

.


Contour lines for correlated random variables


For correlated components  (ρxy0)  the PDF contour lines are always elliptic, thus also for the special case  σx=σy

Here the equation of determination of the PDF contour lines is:

fxy(x,y)=const.x2σ2x+y2σ2y2ρxyxyσxσy=const.

The following graph shows in lighter blue two contour lines for different parameter sets, each with  ρxy0.

height lines of 2D PDF at correlated sizes
  • The ellipse major axis is dashed in dark blue.
  • The correlation line  K(x)  is drawn in red throughout.


Based on this plot, the following statements can be made:

  • The ellipse shape depends not only on the correlation coefficient  ρxy  but also on the ratio of the two standard deviations  σx  and  σy  .
  • The angle of inclination  α  of the ellipse major axis  (dashed straight line)  with respect to  x–axis also depends on  σxσy  and  ρxy  :
α=1/2arctan (2ρxyσxσyσ2xσ2y).
  • The (red) correlation line  y=K(x)  of a Gaussian 2D random variable always lies below the (blue dashed) ellipse major axis.
  • K(x)  can also be constructed geometrically from the intersection of the contour lines and their vertical tangents, as indicated in green in the sketches above.


For more information on this topic, see the learning video (German)  Gaussian 2D Random Variables:

  • Part 1:   Gaussian random variables without statistical bindings,
  • Part 2:   Gaussian random variables with statistical bindings.

Rotation of the coordinate system


For some tasks it is advantageous to rotate the coordinate system, as indicated in the following graphic:

To rotate the coordinate system
  • The  (ξ,η) coordinate system is rotated with respect to the original  (x,y) system by the angle  β  .
  • In contrast  α  denotes the angle between the ellipse major axis and the  x axis.


The following relationships exist between the coordinates of the two reference frames:

ξ=cos(β)x+sin(β)yresp.x=cos(β)ξsin(β)η,
η=sin(β)x+cos(β)yresp.y=sin(β)ξ+cos(β)η.


If  (x,y)  is a 2D Gaussian random variable, then the random variable  (ξ,η)  is also Gaussian distributed.

Substituting the above equations into the 2D PDF fxy(x,y)  and comparing the coefficients, we obtain the following governing equations for  σxσy  and  ρxy  respectively  σξ,ση  and  ρξη:

1(1ρ2ξη)σ2ξ=1(1ρ2xy)[cos2(β)σ2x+sin2(β)σ2y2ρxysin(β)cos(β)σxσy],
1(1ρ2ξη)σ2η=1(1ρ2xy)[sin2(β)σ2x+cos2(β)σ2y+2ρxysin(β)cos(β)σxσy],
ρξη(1ρ2ξη)σξση=1(1ρ2xy)[sin(β)cos(β)σ2xsin(β)cos(β)σ2y+ρxyσxσy(cos2(β)sin2(β))].

With these three equations the in each case three parameters of the two coordinate systems can be converted directly, which is possible however only in special cases without substantial computational expenditure   Following an example with justifiable computational expenditure.


EN Sto T 4 2 S4.png

Example 3:  We consider a Gaussian 2D PDF with the following properties:

  • The variances of the two components are equal:   σ2x=σ2y=1.
  • The correlation coefficient between  x  and  y  is  ρxy=0.5.
  • The angle of the ellipse major axis with respect to  x–axis is thus  α=45.


If the coordinate system were also rotated by  β=45  , there would be uncorrelated components because of  σx=σy  and because of  sin(β)=cos(β)=1/2  for the new correlation coefficient  ρξη=0   ⇒   .

The two standard deviations - related to the new coordinate system - would then result according to the first two equations to  σξ=1.5  and  ση=0.5.

However, the above sketch is not based on  β=α  but on  β=α/2.

  • With  σx=σy=1ρxy=0.5,
  • as well as  α=45sin(β)cos(β)=sin(2β)/2=sin(α)/2  and
  • cos2(β)sin2(β)=cos(2β)=cos(α)


the system of equations can be represented as follows:

(I)1(1ρ2ξη)σ2ξ=43[112sin(α)]=0.862,
(II)1(1ρ2ξη)σ2η=43[1+12sin(α)]=1.805,(I)(II):σησξ=0.8621.805=0.691,
(III)ρξη(1ρ2ξη)σξση=ρξη(1ρ2ξη)σ2ξ0.691=23cos(α)=0.471.

Dividing now the equation  (III)  by the equation  (I), we get:

ρξη0.691=0.4710.862ρξη=0.378.

The other two parameters of the new coordinate system now result in  σξ1  and  ση0.7.

Exercises for the chapter


Exercise 4.4: Gaussian 2D PDF

Exercise 4.4Z: Contour Lines of the 2D PDF

Exercise 4.5: Two-dimensional Examination Evaluation

Exercise 4.6: Coordinate Rotation