Difference between revisions of "Aufgaben:Exercise 3.2Z: Two-dimensional Probability Mass Function"

From LNTwww
 
(29 intermediate revisions by 6 users not shown)
Line 1: Line 1:
  
{{quiz-Header|Buchseite=Informationstheorie und Quellencodierung/Einige Vorbemerkungen zu zweidimensionalen Zufallsgrößen
+
{{quiz-Header|Buchseite=Information_Theory/Some_Preliminary_Remarks_on_Two-Dimensional_Random_Variables
 
}}
 
}}
  
[[File:P_ID2752__Inf_Z_3_2_neu.png|right|]]
+
[[File:P_ID2752__Inf_Z_3_2_neu.png|right|frame|$\rm PMF$ of the two-dimensional  random variable  $XY$]]
Wir betrachten die Zufallsgrößen
+
We consider the random variables  $X =  \{ 0,\ 1,\ 2,\ 3 \}$  and  $Y =  \{ 0,\ 1,\ 2 \}$, whose joint probability mass function  $P_{XY}(X,\ Y)$  is given.
 +
*From this two-dimensional  probability mass function  $\rm (PMF)$,  the one-dimensional probability mass functions  $P_X(X)$  and  $P_Y(Y)$  are to be determined.
 +
*Such a one-dimensional probability mass function is sometimes also called  "marginal probability".
  
$X$ =  { 0, 1, 2, 3 },
 
  
$Y$ = { 0, 1, 2 },
+
If  $P_{XY}(X,\ Y) = P_X(X) \cdot P_Y(Y)$, the two random variables  $X$  and  $Y$  are statistically independent.  Otherwise, there are statistical dependencies between them.
  
deren gemeinsame Wahrscheinlichkeitsfunktion $P_{X,Y}(X,Y)$ gegeben ist. Aus dieser 2D–Wahrscheinlichkeitsfunktion sollen die eindimensionalen Wahrscheinlichkeitsfunktionen $P_X(X)$ und $P_Y(Y)$ ermittelt werden. Man nennt eine solche manchmal auch Randwahrscheinlichkeit (englisch: Marginal Probability).
+
In the second part of the task we consider the random variables  $U=  \big \{ 0,\ 1 \big \}$  and  $V= \big  \{ 0,\ 1 \big \}$,  which result from  $X$  and  $Y$  by modulo-2 operations:
  
Gilt  $P_{X,Y}(X,Y)$ = $P_X(X)$ . $P_Y(Y)$, so sind die beiden Zufallsgrößen X und Y statistisch unabhängig. Andernfalls bestehen statistische Bindungen zwischen $X$ und $Y$.
+
:$$U = X \hspace{0.1cm}\text{mod} \hspace{0.1cm} 2, \hspace{0.3cm}  V = Y \hspace{0.1cm}\text{mod} \hspace{0.1cm} 2.$$
  
Im zweiten Teil der Aufgabe betrachten wir die Zufallsgrößen
 
  
$U$ = { 0, 1 }, $V$ = { 0, 1 },
 
  
die sich aus $X$ und $Y$ durch Modulo–2–Operationen ergeben:
 
  
$U$ = $X$ mod 2,  $V$ = $Y$ mod 2.
 
  
'''Hinweis:''' Die Aufgabe gehört zum Themengebiet von [http://en.lntwww.de/Informationstheorie_und_Quellencodierung/Einige_Vorbemerkungen_zu_zweidimensionalen_Zufallsgrößen  Kapitel 3.1]. Ausgegangen wird hier von der gleichen Konstellation wie in [http://en.lntwww.de/Aufgaben:3.02_Erwartungswertberechnungen Aufgabe 3.02]. Dort wurde die Zufallsgrößen  $Y$ = { 0, 1, 2, 3 }  betrachtet, allerdings mit dem Zusatz $Pr(Y = 3)$ = 0. Die so erzwungene Eigenschaft $|X| = |Y|$  war in Aufgabe  [http://en.lntwww.de/Aufgaben:3.02_Erwartungswertberechnungen Aufgabe 3.02] zur formalen Berechnung des Erwartungswertes $E[P_X(X)]$ von Vorteil.
 
 
  
  
  
 +
<u>Hints:</u>
 +
*The exercise belongs to the chapter&nbsp; [[Information_Theory/Einige_Vorbemerkungen_zu_zweidimensionalen_Zufallsgrößen|Some preliminary remarks on two-dimensional random variables]].
 +
*The same constellation is assumed here as in&nbsp; [[Aufgaben:Aufgabe_3.2:_Erwartungswertberechnungen|Exercise 3.2]].
 +
*There the random variables&nbsp;  $Y = \{ 0,\ 1,\ 2,\ 3 \}$&nbsp;  were considered, but with the addition&nbsp; ${\rm Pr}(Y = 3) = 0$.
 +
*The property&nbsp; $|X| = |Y|$&nbsp; forced in this way was advantageous in the previous task for the formal calculation of the expected value.
 +
  
  
 
+
===Questions===
===Fragebogen===
 
  
 
<quiz display=simple>
 
<quiz display=simple>
  
{Wie lautet die Wahrscheinlichkeitsfunktion $P_X(X)$ ?
+
{What is the probability mass function&nbsp; $P_X(X)$?
 
|type="{}"}
 
|type="{}"}
$P_X(0)$ = { 0.5 3% }
+
$P_X(0) \ = \ $ { 0.5 3% }
$P_X(1)$ = { 0.125 3% }
+
$P_X(1) \ = \ $ { 0.125 3% }
$P_X(2)$ = { 0 3% }
+
$P_X(2)\ = \ $ { 0. }
$P_X(3)$ = { 0.375 3% }
+
$P_X(3) \ = \ ${ 0.375 3% }
  
{Wie lautet die Wahrscheinlichkeitsfunktion $P_Y(Y)$ ?
+
{What is the probability mass function&nbsp; $P_Y(Y)$?
 
|type="{}"}
 
|type="{}"}
$P_Y(0)$ = { 0.5 3% }
+
$P_Y(0) \ = \ $ { 0.5 3% }
$P_Y(1)$ = { 0.25 3% }
+
$P_Y(1) \ = \ $ { 0.25 3% }
$P_Y(2)$ = { 0.25 3% }
+
$P_Y(2) \ = \ $ { 0.25 3% }
  
{Sind die Zufallsgrößen $X$ und $Y$ statistisch unabhängig
+
{Are the random variables&nbsp; $X$&nbsp; and&nbsp; $Y$&nbsp; statistically independent?
|type="[]"}
 
+ Falsch
 
- Richtig
 
  
 +
|type="()"}
 +
- Yes,
 +
+ No.
  
{Ermitteln Sie die Wahrscheinlichkeiten $P_{UV}( U, V)$.
+
 
 +
{Determine the probabilities&nbsp; $P_{UV}( U,\ V)$.
 
|type="{}"}
 
|type="{}"}
$P_{UV}( U = 0, V = 0)$ = { 0.375 3% }
+
$P_{UV}( U = 0,\ V = 0) \ = \ $ { 0.375 3% }
$P_{UV}( U = 0, V = 1)$ { 0.375 3% }
+
$P_{UV}( U = 0,\ V = 1) \ = \ $ { 0.375 3% }
$P_{UV}( U = 1, V = 0)$ { 0.125 3% }
+
$P_{UV}( U = 1,\ V = 0) \ = \ $ { 0.125 3% }
$P_{UV}( U =1, V = 1)$ { 0.125 3% }
+
$P_{UV}( U =1,\ V = 1) \ = \ $ { 0.125 3% }
  
{Sind die Zufallsgrößen $U$ und $V$ statistisch unabhängig
+
{Are the random variables&nbsp; $U$&nbsp; and&nbsp; $V$&nbsp; statistically independent?
|type="[]"}
+
|type="()"}
- Falsch
+
+ Yes,
+ Richtig
+
- No.
  
  
Line 69: Line 70:
 
</quiz>
 
</quiz>
  
===Musterlösung===
+
===Solution===
 
{{ML-Kopf}}
 
{{ML-Kopf}}
'''1.''' Man kommt von $P_{XY}(X,Y)$ zur 1D–Wahrscheinlichkeitsfunktion $P_X(X)$ ,indem man alle $Y$-Wahrscheinlichkeiten aufsummiert:
+
'''(1)'''&nbsp; You get from&nbsp; $P_{XY}(X,\ Y)$&nbsp; to the one-dimensional probability mass function&nbsp; $P_X(X)$ by summing up all&nbsp; $Y$ probabilities:
 +
:$$P_X(X = x_{\mu}) = \sum_{y \hspace{0.05cm} \in \hspace{0.05cm} Y} \hspace{0.1cm} P_{XY}(x_{\mu}, y).$$
 +
*One thus obtains the following numerical values:
 +
:$$P_X(X = 0) = 1/4+1/8+1/8 = 1/2 \hspace{0.15cm}\underline{= 0.500},$$
 +
:$$P_X(X = 1)= 0+0+1/8 =  1/8 \hspace{0.15cm}\underline{= 0.125},$$
 +
:$$P_X(X = 2) =  0+0+0 \hspace{0.15cm}\underline{= 0}$$
 +
:$$P_X(X = 3) = 1/4+1/8+0=3/8 \hspace{0.15cm}\underline{= 0.375}\hspace{0.5cm} \Rightarrow  \hspace{0.5cm}    P_X(X) = \big [ 1/2, \ 1/8 , \ 0 , \ 3/8 \big ].$$
  
$$P_X(X = x_{\mu}) = \sum_{y \hspace{0.05cm} \in \hspace{0.05cm} Y} \hspace{0.1cm} P_{XY}(x_{\mu}, y)$$
 
  
  
$$\Rightarrow   P_X(X = 0) = 1/4+1/8+1/8 = 0.500$$
+
'''(2)'''&nbsp; Analogous to sub-task &nbsp; '''(1)'''&nbsp;, the following now holds:
 +
:$$P_Y(Y = y_{\kappa}) = \sum_{x \hspace{0.05cm} \in \hspace{0.05cm} X} \hspace{0.1cm} P_{XY}(x, y_{\kappa})$$
 +
:$$P_Y(Y= 0) = 1/4+0+0+1/4 = 1/2 \hspace{0.15cm}\underline{= 0.500},$$
 +
:$$P_Y(Y = 1) = 1/8+0+0+1/8 = 1/4  \hspace{0.15cm}\underline{= 0.250},$$
 +
:$$P_Y(Y = 2) = 1/8+1/8+0+0 = 1/4 \hspace{0.15cm}\underline{= 0.250} \hspace{0.5cm} \Rightarrow \hspace{0.5cm}  P_Y(Y= 0) = \big [ 1/2, \ 1/4 , \ 1/4 ].$$
 +
 
 +
 
 +
 
 +
'''(3)'''&nbsp; With statistical independence,&nbsp;  $P_{XY}(X,Y)= P_X(X) \cdot P_Y(Y)$&nbsp; should be.
 +
*This does not apply here: &nbsp; &nbsp;  answer &nbsp; <u>'''NO'''</u>.
 +
 
 +
 
 +
 
 +
'''(4)'''&nbsp; Starting from the left-hand table &nbsp; &rArr; &nbsp;  $P_{XY}(X,Y)$,&nbsp;  we arrive at the middle table &nbsp; &rArr; &nbsp; $P_{UY}(U,Y)$, <br>by combining certain probabilities according to&nbsp; $U = X \hspace{0.1cm}\text{mod} \hspace{0.1cm} 2$.
 +
 
 +
If one also takes into account&nbsp; $V = Y \hspace{0.1cm}\text{mod} \hspace{0.1cm} 2$, one obtains the probabilities sought according to the right-hand table:
 +
[[File:P_ID2753__Inf_Z_3_2d_neu.png|right|frame|Different probability functions]]
 +
 
 +
:$$P_{UV}( U = 0, V = 0) = 3/8 \hspace{0.15cm}\underline{=  0.375},$$
 +
:$$P_{UV}( U = 0, V = 1) = 3/8 \hspace{0.15cm}\underline{=  0.375},$$
 +
:$$P_{UV}( U = 1, V = 0) = 1/8 \hspace{0.15cm}\underline{=  0.125},$$
 +
:$$P_{UV}( U = 1, V = 1) = 1/8 \hspace{0.15cm}\underline{= 0.125}.$$
 +
 
 +
 
 +
 
 +
'''(5)'''&nbsp; The correct answer is &nbsp; <u>'''YES'''</u>:
 +
*The corresponding one-dimensional probability mass functions are:  &nbsp;
 +
:$$P_U(U) = \big [1/2 , \ 1/2 \big ],$$
 +
:$$P_V(V)=\big [3/4, \ 1/4 \big ].$$ 
 +
*Thus:&nbsp; $P_{UV}(U,V) = P_U(U) \cdot  P_V(V)$  &nbsp; &rArr;  &nbsp;  $U$&nbsp; and&nbsp; $V$&nbsp; are statistically independent.
 +
 
  
  
                                      $$P_X(X = 1)= 0+0+1/8 = 0.125$$
 
  
  
                                      $$P_X(X = 2) =  0+0+0 = 0$$
 
  
  
                                      $$P_X(X = 3) = 1/4+1/8+0=0.375$$
 
  
  
 
'''2.'''
 
'''3.'''
 
'''4.'''
 
'''5.'''
 
'''6.'''
 
'''7.'''
 
 
{{ML-Fuß}}
 
{{ML-Fuß}}
  
  
  
[[Category:Aufgaben zu Informationstheorie|^3.1 Einige Vorbemerkungen zu zweidimensionalen Zufallsgrößen^]]
+
[[Category:Information Theory: Exercises|^3.1 General Information on 2D Random Variables^]]

Latest revision as of 09:12, 24 September 2021

$\rm PMF$ of the two-dimensional random variable  $XY$

We consider the random variables  $X = \{ 0,\ 1,\ 2,\ 3 \}$  and  $Y = \{ 0,\ 1,\ 2 \}$, whose joint probability mass function  $P_{XY}(X,\ Y)$  is given.

  • From this two-dimensional probability mass function  $\rm (PMF)$,  the one-dimensional probability mass functions  $P_X(X)$  and  $P_Y(Y)$  are to be determined.
  • Such a one-dimensional probability mass function is sometimes also called  "marginal probability".


If  $P_{XY}(X,\ Y) = P_X(X) \cdot P_Y(Y)$, the two random variables  $X$  and  $Y$  are statistically independent.  Otherwise, there are statistical dependencies between them.

In the second part of the task we consider the random variables  $U= \big \{ 0,\ 1 \big \}$  and  $V= \big \{ 0,\ 1 \big \}$,  which result from  $X$  and  $Y$  by modulo-2 operations:

$$U = X \hspace{0.1cm}\text{mod} \hspace{0.1cm} 2, \hspace{0.3cm} V = Y \hspace{0.1cm}\text{mod} \hspace{0.1cm} 2.$$





Hints:

  • The exercise belongs to the chapter  Some preliminary remarks on two-dimensional random variables.
  • The same constellation is assumed here as in  Exercise 3.2.
  • There the random variables  $Y = \{ 0,\ 1,\ 2,\ 3 \}$  were considered, but with the addition  ${\rm Pr}(Y = 3) = 0$.
  • The property  $|X| = |Y|$  forced in this way was advantageous in the previous task for the formal calculation of the expected value.


Questions

1

What is the probability mass function  $P_X(X)$?

$P_X(0) \ = \ $

$P_X(1) \ = \ $

$P_X(2)\ = \ $

$P_X(3) \ = \ $

2

What is the probability mass function  $P_Y(Y)$?

$P_Y(0) \ = \ $

$P_Y(1) \ = \ $

$P_Y(2) \ = \ $

3

Are the random variables  $X$  and  $Y$  statistically independent?

Yes,
No.

4

Determine the probabilities  $P_{UV}( U,\ V)$.

$P_{UV}( U = 0,\ V = 0) \ = \ $

$P_{UV}( U = 0,\ V = 1) \ = \ $

$P_{UV}( U = 1,\ V = 0) \ = \ $

$P_{UV}( U =1,\ V = 1) \ = \ $

5

Are the random variables  $U$  and  $V$  statistically independent?

Yes,
No.


Solution

(1)  You get from  $P_{XY}(X,\ Y)$  to the one-dimensional probability mass function  $P_X(X)$ by summing up all  $Y$ probabilities:

$$P_X(X = x_{\mu}) = \sum_{y \hspace{0.05cm} \in \hspace{0.05cm} Y} \hspace{0.1cm} P_{XY}(x_{\mu}, y).$$
  • One thus obtains the following numerical values:
$$P_X(X = 0) = 1/4+1/8+1/8 = 1/2 \hspace{0.15cm}\underline{= 0.500},$$
$$P_X(X = 1)= 0+0+1/8 = 1/8 \hspace{0.15cm}\underline{= 0.125},$$
$$P_X(X = 2) = 0+0+0 \hspace{0.15cm}\underline{= 0}$$
$$P_X(X = 3) = 1/4+1/8+0=3/8 \hspace{0.15cm}\underline{= 0.375}\hspace{0.5cm} \Rightarrow \hspace{0.5cm} P_X(X) = \big [ 1/2, \ 1/8 , \ 0 , \ 3/8 \big ].$$


(2)  Analogous to sub-task   (1) , the following now holds:

$$P_Y(Y = y_{\kappa}) = \sum_{x \hspace{0.05cm} \in \hspace{0.05cm} X} \hspace{0.1cm} P_{XY}(x, y_{\kappa})$$
$$P_Y(Y= 0) = 1/4+0+0+1/4 = 1/2 \hspace{0.15cm}\underline{= 0.500},$$
$$P_Y(Y = 1) = 1/8+0+0+1/8 = 1/4 \hspace{0.15cm}\underline{= 0.250},$$
$$P_Y(Y = 2) = 1/8+1/8+0+0 = 1/4 \hspace{0.15cm}\underline{= 0.250} \hspace{0.5cm} \Rightarrow \hspace{0.5cm} P_Y(Y= 0) = \big [ 1/2, \ 1/4 , \ 1/4 ].$$


(3)  With statistical independence,  $P_{XY}(X,Y)= P_X(X) \cdot P_Y(Y)$  should be.

  • This does not apply here:     answer   NO.


(4)  Starting from the left-hand table   ⇒   $P_{XY}(X,Y)$,  we arrive at the middle table   ⇒   $P_{UY}(U,Y)$,
by combining certain probabilities according to  $U = X \hspace{0.1cm}\text{mod} \hspace{0.1cm} 2$.

If one also takes into account  $V = Y \hspace{0.1cm}\text{mod} \hspace{0.1cm} 2$, one obtains the probabilities sought according to the right-hand table:

Different probability functions
$$P_{UV}( U = 0, V = 0) = 3/8 \hspace{0.15cm}\underline{= 0.375},$$
$$P_{UV}( U = 0, V = 1) = 3/8 \hspace{0.15cm}\underline{= 0.375},$$
$$P_{UV}( U = 1, V = 0) = 1/8 \hspace{0.15cm}\underline{= 0.125},$$
$$P_{UV}( U = 1, V = 1) = 1/8 \hspace{0.15cm}\underline{= 0.125}.$$


(5)  The correct answer is   YES:

  • The corresponding one-dimensional probability mass functions are:  
$$P_U(U) = \big [1/2 , \ 1/2 \big ],$$
$$P_V(V)=\big [3/4, \ 1/4 \big ].$$
  • Thus:  $P_{UV}(U,V) = P_U(U) \cdot P_V(V)$   ⇒   $U$  and  $V$  are statistically independent.