Difference between revisions of "Aufgaben:Exercise 4.4Z: Supplement to Exercise 4.4"

From LNTwww
Line 1: Line 1:
{{quiz-Header|Buchseite=Kanalcodierung/Soft–in Soft–out Decoder}}
+
{{quiz-Header|Buchseite=Channel_Coding/Soft-in_Soft-Out_Decoder}}
  
[[File:P_ID2994__KC_Z_4_4_v3.png |right|frame|Hamming–Gewichte und Sequenzwahrscheinlichkeiten ]]
+
[[File:P_ID2994__KC_Z_4_4_v3.png |right|frame|Hamming weights and sequence probabilities ]]
Der Informationstheoretiker  [https://de.wikipedia.org/wiki/Robert_Gray_Gallager Robert G. Gallager]  hat sich bereits 1963 mit folgender Fragestellung beschäftigt:
+
Der Informationstheoretiker  [https://en.wikipedia.org/wiki/Robert_G._Gallager "Robert G. Gallager"]  hat sich bereits 1963 mit folgender Fragestellung beschäftigt:
 
* Gegeben ist ein Zufallsvektor  $\underline{x} = (x_1, \, x_2, \hspace{-0.04cm} \text{ ...} \hspace{0.08cm} , x_n)$  mit  $n$  binären Elementen  $x_i ∈ \{0, \, 1\}$.
 
* Gegeben ist ein Zufallsvektor  $\underline{x} = (x_1, \, x_2, \hspace{-0.04cm} \text{ ...} \hspace{0.08cm} , x_n)$  mit  $n$  binären Elementen  $x_i ∈ \{0, \, 1\}$.
 
* Bekannt sind alle Wahrscheinlichkeiten  $p_i = {\rm Pr}(x_i = 1)$  und  $q_i = {\rm Pr}(x_i = 0) = 1 - p_i$  mit Index  $i = 1, \hspace{-0.04cm}\text{ ...} \hspace{0.08cm} ,\ n$.
 
* Bekannt sind alle Wahrscheinlichkeiten  $p_i = {\rm Pr}(x_i = 1)$  und  $q_i = {\rm Pr}(x_i = 0) = 1 - p_i$  mit Index  $i = 1, \hspace{-0.04cm}\text{ ...} \hspace{0.08cm} ,\ n$.
 
* Gesucht ist die Wahrscheinlichkeit, dass die Anzahl der Einsen in diesem Vektor geradzahlig ist.
 
* Gesucht ist die Wahrscheinlichkeit, dass die Anzahl der Einsen in diesem Vektor geradzahlig ist.
* Oder ausgedrückt mit dem  [[Channel_Coding/Zielsetzung_der_Kanalcodierung#Einige_wichtige_Definitionen_zur_Blockcodierung|Hamming–Gewicht]]:   Wie groß ist die Wahrscheinlichkeit  ${\rm Pr}[w_{\rm H}(\underline{x}) {\rm \ ist \ gerade}]$?
+
* Oder ausgedrückt mit dem  [[Channel_Coding/Objective_of_Channel_Coding#Important_definitions_for_block_coding|"Hamming–Gewicht"]]:   Wie groß ist die Wahrscheinlichkeit  ${\rm Pr}[w_{\rm H}(\underline{x}) {\rm \ ist \ gerade}]$?
  
  
Line 29: Line 29:
 
Die Gleichung wendet man zum Beispiel an, um die extrinsischen&nbsp; $L$&ndash;Werte eines&nbsp; <i>Single Parity&ndash;check Codes</i>&nbsp; zu berechnen.  
 
Die Gleichung wendet man zum Beispiel an, um die extrinsischen&nbsp; $L$&ndash;Werte eines&nbsp; <i>Single Parity&ndash;check Codes</i>&nbsp; zu berechnen.  
  
Wie bereits in der&nbsp; [[Aufgaben:4.4_Extrinsische_L%E2%80%93Werte_beim_SPC| Aufgabe A4.4]]&nbsp; dargelegt, lautet nämlich der extrinsische $L$&ndash;Wert mit dem Hamming&ndash;Gewicht&nbsp; $w_{\rm H}$&nbsp; der verkürzten Folge&nbsp; $\underline{x}^{(-i)}$:
+
Wie bereits in der&nbsp; [[Aufgaben:Exercise_4.4:_Extrinsic_L-values_at_SPC| "Aufgabe A4.4"]]&nbsp; dargelegt, lautet nämlich der extrinsische $L$&ndash;Wert mit dem Hamming&ndash;Gewicht&nbsp; $w_{\rm H}$&nbsp; der verkürzten Folge&nbsp; $\underline{x}^{(-i)}$:
 
:$$L_{\rm E}(i) = {\rm ln} \hspace{0.15cm}\frac{{\rm Pr} \left [w_{\rm H}(\underline{x}^{(-i)})\hspace{0.15cm}{\rm ist \hspace{0.15cm} gerade} \hspace{0.05cm} | \hspace{0.05cm}\underline{y} \hspace{0.05cm}\right ]}{{\rm Pr} \left [w_{\rm H}(\underline{x}^{(-i)})\hspace{0.15cm}{\rm ist \hspace{0.15cm} ungerade} \hspace{0.05cm} | \hspace{0.05cm}\underline{y} \hspace{0.05cm}\right ]}
 
:$$L_{\rm E}(i) = {\rm ln} \hspace{0.15cm}\frac{{\rm Pr} \left [w_{\rm H}(\underline{x}^{(-i)})\hspace{0.15cm}{\rm ist \hspace{0.15cm} gerade} \hspace{0.05cm} | \hspace{0.05cm}\underline{y} \hspace{0.05cm}\right ]}{{\rm Pr} \left [w_{\rm H}(\underline{x}^{(-i)})\hspace{0.15cm}{\rm ist \hspace{0.15cm} ungerade} \hspace{0.05cm} | \hspace{0.05cm}\underline{y} \hspace{0.05cm}\right ]}
 
  \hspace{0.05cm}.$$
 
  \hspace{0.05cm}.$$
Line 44: Line 44:
  
  
''Hinweise:''
+
Hints:
* Die Aufgabe gehört zum Kapitel&nbsp; [[Channel_Coding/Soft%E2%80%93in_Soft%E2%80%93out_Decoder| Soft&ndash;in Soft&ndash;out Decoder]].
+
*This exercise belongs to the chapter&nbsp; [[Channel_Coding/Soft%E2%80%93in_Soft%E2%80%93out_Decoder|"Soft&ndash;in Soft&ndash;out Decoder"]].
*Bezug genommen wird insbesondere auf die Seite&nbsp; [[Channel_Coding/Soft–in_Soft–out_Decoder#Zur_Berechnung_der_extrinsischen_L.E2.80.93Werte|Zur Berechnung der extrinsischen&nbsp; $L$&ndash;Werte]].  
+
*Reference is made in particular to the page&nbsp; [[Channel_Coding/Soft-in_Soft-out_Decoder#For_Calculating_the_extrinsic_L.E2.80.93Values|"For calculating the extrinsic&nbsp; $L$&ndash;values"]].  
*Die Aufgabe ist als Ergänzung zur&nbsp; [[Aufgaben:Aufgabe_4.4:_Extrinsische_L–Werte_beim_SPC| Aufgabe 4.4]]&nbsp; gedacht.
+
*The exercise is intended as a supplement to&nbsp; [[Exercises:Exercise_4.4:_Extrinsic_L-values_at_SPC| "Exercise 4.4"]]&nbsp;.
 
   
 
   
  
  
  
===Fragebogen===
+
===Questions===
 
<quiz display=simple>
 
<quiz display=simple>
{Wir betrachten den Vektor&nbsp; $\underline{x} = (x_1, \, x_2) \ \Rightarrow \ n = 2$&nbsp; mit&nbsp; $x_i &#8712; \{0, \, 1\}$&nbsp; und&nbsp; $p_1 = 0.2, \ p_2 = 0.9$.  <br>Wie groß ist die Wahrscheinlichkeit, dass&nbsp; $\underline{x}$&nbsp; eine gerade Anzahl an Einsen beinhaltet?
+
{We consider the vector&nbsp; $\underline{x} = (x_1, \, x_2) \ \Rightarrow \ n = 2$&nbsp; with&nbsp; $x_i &#8712; \{0, \, 1\}$&nbsp; and&nbsp; $p_1 = 0.2, \ p_2 = 0.9$.  <br>What is the probability that&nbsp; $\underline{x}$&nbsp; contains an even number of ones?
 
|type="{}"}
 
|type="{}"}
 
${\rm Pr}\big [w_{\rm H}(\underline{x}) \ {\rm ist \ gerade}\big ] \ = \ ${ 0.26 3% }
 
${\rm Pr}\big [w_{\rm H}(\underline{x}) \ {\rm ist \ gerade}\big ] \ = \ ${ 0.26 3% }
Line 62: Line 62:
 
${\rm Pr}\big [w_{\rm H}(\underline{x}) \ {\rm ist \ gerade}\big ] \ = \ ${ 0.404 3% }
 
${\rm Pr}\big [w_{\rm H}(\underline{x}) \ {\rm ist \ gerade}\big ] \ = \ ${ 0.404 3% }
  
{Nun gelte&nbsp; $n = 4$&nbsp; und&nbsp; $p_1 = 0.2, \ p_2 = 0.9, \ p_3 = 0.3, \ p_4 = 0.6$. Berechnen Sie nach der Gallager&ndash;Gleichung folgende Größen:
+
{Now let&nbsp; $n = 4$&nbsp; and&nbsp; $p_1 = 0.2, \ p_2 = 0.9, \ p_3 = 0.3, \ p_4 = 0.6$. Calculate the following quantities according to Gallager's equation:
 
|type="{}"}
 
|type="{}"}
${\rm Pr(blau) = Pr}\big [w_{\rm H}(\underline{x}) \ {\rm ist \ gerade}\big ] \hspace{0.33cm} = \ ${ 0.5192 3% }
+
${\rm Pr(blue) = Pr}\big [w_{\rm H}(\underline{x}) \ {\rm is \ even}\big ] \hspace{0.33cm} = \ ${ 0.5192 3% }
${\rm Pr(rot) = Pr}\big [w_{\rm H}(\underline{x}) \ {\rm ist \ ungerade}\big ] \hspace{0.1cm} = \ ${ 0.4808 3% }
+
${\rm Pr(red) = Pr}\big [w_{\rm H}(\underline{x}) \ {\rm is \ uneven}\big ] \hspace{0.1cm} = \ ${ 0.4808 3% }
 
$\text{Quotient }Q = {\rm Pr(blau)/Pr(rot)} \hspace{0.4cm} = \ ${ 1.0799 3% }
 
$\text{Quotient }Q = {\rm Pr(blau)/Pr(rot)} \hspace{0.4cm} = \ ${ 1.0799 3% }
  
{Wie groß ist der extrinsische&nbsp; $L$&ndash;Wert für das Symbol&nbsp; $i = 5$&nbsp; beim&nbsp; $\text{SPC (5, 4, 2)}$&nbsp; mit&nbsp; $p_1 = 0.2, \ p_2 = 0.9, \ p_3 = 0.3, \ p_4 = 0.6, \ p_5 = 0.9$?
+
{What is the extrinsic&nbsp; $L$ value for the symbol&nbsp; $i = 5$&nbsp; at&nbsp; $\text{SPC (5, 4, 2)}$&nbsp; with&nbsp; $p_1 = 0.2, \ p_2 = 0.9, \ p_3 = 0.3, \ p_4 = 0.6, \ p_5 = 0.9$?
 
|type="{}"}
 
|type="{}"}
 
$L_{\rm E}(i = 5) \ = \ ${ 0.077 3% }
 
$L_{\rm E}(i = 5) \ = \ ${ 0.077 3% }
  
{Wie ändert sich&nbsp; $L_{\rm E}(i = 5)$, wenn man stattdessen von&nbsp; $p_5 = 0.1$&nbsp; ausgeht?
+
{How does&nbsp; $L_{\rm E}(i = 5)$ change if we assume&nbsp; $p_5 = 0.1$&nbsp; instead?
 
|type="()"}
 
|type="()"}
- $L_{\rm E}(i = 5)$&nbsp; wird größer.
+
- $L_{\rm E}(i = 5)$&nbsp; becomes larger.
- $L_{\rm E}(i = 5)$&nbsp; wird kleiner.
+
- $L_{\rm E}(i = 5)$&nbsp; becomes smaller.
+ $L_{\rm E}(i = 5)$&nbsp; wird gegenüber Teilaufgabe '''(4)''' nicht verändert.
+
+ $L_{\rm E}(i = 5)$&nbsp; is not changed compared to subtask '''(4)'''.
 
</quiz>
 
</quiz>
  
===Musterlösung===
+
===Solution===
 
{{ML-Kopf}}
 
{{ML-Kopf}}
[[File:P_ID2996__KC_Z_4_4a_v1.png|frame|right|Herleitung „$w_{\rm H}$ ist gerade” für die Codelänge $n = 2$]]
+
[[File:P_ID2996__KC_Z_4_4a_v1.png|frame|right|Derivation "$w_{\rm H}$ is even" for code length $n = 2$.]]
'''(1)'''&nbsp;  Entsprechend der nebenstehenden Tabelle gilt:
+
'''(1)'''&nbsp;  According to the adjacent table applies:
:$${\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.10cm}{\rm ist \hspace{0.10cm} gerade}\right ] =
+
:$${\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.10cm}{\rm is \hspace{0.10cm} even}\right ] =
 
{\rm Pr} \left [w_{\rm H} = 0 \right] + {\rm Pr} \left [w_{\rm H} = 2 \right]
 
{\rm Pr} \left [w_{\rm H} = 0 \right] + {\rm Pr} \left [w_{\rm H} = 2 \right]
 
\hspace{0.05cm}. $$
 
\hspace{0.05cm}. $$
  
Mit den Wahrscheinlichkeiten
+
With the probabilities
 
:$$p_1 = {\rm Pr} (x_1 = 1) \hspace{-0.15cm} \ = \ \hspace{-0.15cm} 0.2\hspace{0.05cm},\hspace{0.3cm}q_1 = {\rm Pr} (x_1 = 0) = 0.8\hspace{0.05cm},$$
 
:$$p_1 = {\rm Pr} (x_1 = 1) \hspace{-0.15cm} \ = \ \hspace{-0.15cm} 0.2\hspace{0.05cm},\hspace{0.3cm}q_1 = {\rm Pr} (x_1 = 0) = 0.8\hspace{0.05cm},$$
 
:$$p_2 = {\rm Pr} (x_2 = 1) \hspace{-0.15cm} \ = \ \hspace{-0.15cm} 0.9\hspace{0.05cm},\hspace{0.3cm}q_2 = {\rm Pr} (x_2 = 0) = 0.1$$
 
:$$p_2 = {\rm Pr} (x_2 = 1) \hspace{-0.15cm} \ = \ \hspace{-0.15cm} 0.9\hspace{0.05cm},\hspace{0.3cm}q_2 = {\rm Pr} (x_2 = 0) = 0.1$$
  
erhält man:
+
one obtains:
 
:$${\rm Pr} \left [w_{\rm H}(\underline{x}) = 0\right] \hspace{-0.15cm} \ = \ \hspace{-0.15cm}  
 
:$${\rm Pr} \left [w_{\rm H}(\underline{x}) = 0\right] \hspace{-0.15cm} \ = \ \hspace{-0.15cm}  
 
{\rm Pr} \left [(x_1 = 0)\cap (x_2 = 0) \right] = q_1 \cdot q_2 = 0.8 \cdot 0.1
 
{\rm Pr} \left [(x_1 = 0)\cap (x_2 = 0) \right] = q_1 \cdot q_2 = 0.8 \cdot 0.1
Line 100: Line 100:
 
\hspace{0.05cm}.$$
 
\hspace{0.05cm}.$$
  
Die Gallager&ndash;Gleichung liefert für den gleichen Parametersatz:
+
The Gallager's equation provides for the same set of parameters:
 
:$${\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm ist \hspace{0.15cm} gerade}\right] \hspace{-0.15cm} \ = \ \hspace{-0.15cm}  0.5 + 0.5 \cdot \prod\limits_{i =1}^{2} \hspace{0.25cm}(1-2\cdot p_i) = 0.5 + 0.5 \cdot  (1 - 2 \cdot 0.2)\cdot  (1 - 2 \cdot 0.9) = 0.26
 
:$${\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm ist \hspace{0.15cm} gerade}\right] \hspace{-0.15cm} \ = \ \hspace{-0.15cm}  0.5 + 0.5 \cdot \prod\limits_{i =1}^{2} \hspace{0.25cm}(1-2\cdot p_i) = 0.5 + 0.5 \cdot  (1 - 2 \cdot 0.2)\cdot  (1 - 2 \cdot 0.9) = 0.26
 
\hspace{0.05cm}.$$
 
\hspace{0.05cm}.$$
  
Die von Gallager 1963 angegebene Gleichung wurde hiermit für $n = 2$ verifiziert.
+
The equation given by Gallager 1963 was hereby verified for $n = 2$.
  
  
[[File:P_ID2997__KC_Z_4_4b_v1.png|right|frame|Herleitung „$w_{\rm H}$ ist gerade” für die Codelänge $n = 3$]]  
+
[[File:P_ID2997__KC_Z_4_4b_v1.png|right|frame|Derivation "$w_{\rm H}$ is even" for code length $n = 3$.]]  
'''(2)'''&nbsp; In der zweiten Tabelle sind die vier Kombinationen mit einer geraden Anzahl an Einsen blau markiert. Die Auftrittswahrscheinlichkeiten der einzelnen Kombinationen sind in der letzten Spalte angegeben. Somit ergibt sich:
+
'''(2)'''&nbsp; In the second table, the four combinations with an even number of ones are marked in blue. The probabilities of occurrence of each combination are given in the last column. Thus, the result is:
 
:$$ {\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm ist \hspace{0.15cm} gerade}\right] =  0.056 + 0.216 + 0.006 + 0.126 \hspace{0.15cm} \underline{= 0.404}
 
:$$ {\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm ist \hspace{0.15cm} gerade}\right] =  0.056 + 0.216 + 0.006 + 0.126 \hspace{0.15cm} \underline{= 0.404}
 
\hspace{0.05cm}.$$
 
\hspace{0.05cm}.$$
  
Die roten Zeilen liefern das Komplementärereignis:
+
The red rows provide the complementary event:
 
:$$ {\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm ist \hspace{0.15cm} ungerade}\right] =  0.024 + 0.504 + 0.014 + 0.054= 0.596
 
:$$ {\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm ist \hspace{0.15cm} ungerade}\right] =  0.024 + 0.504 + 0.014 + 0.054= 0.596
 
\hspace{0.05cm}.$$
 
\hspace{0.05cm}.$$
  
Die Gallager&ndash;Gleichung liefert auch hier wieder das exakt gleiche Ergebnis, wobei anzumerken ist, dass diese Gleichung für alle $n$ und alle beliebigen Wahrscheinlichkeiten gültig ist:
+
The Gallager's equation again gives the exact same result, although it should be noted that this equation is valid for all $n$ and all arbitrary probabilities:
:$${\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm ist \hspace{0.15cm} gerade}\right] \hspace{-0.15cm} \ = \ \hspace{-0.15cm}  0.5 + 0.5 \cdot \prod\limits_{i =1}^{3} \hspace{0.25cm}(1-2\cdot p_i) $$
+
:$${\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm is \hspace{0.15cm} even}\right] \hspace{-0.15cm} \ = \ \hspace{-0.15cm}  0.5 + 0.5 \cdot \prod\limits_{i =1}^{3} \hspace{0.25cm}(1-2\cdot p_i) $$
:$$\Rightarrow\hspace{0.3cm}{\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm ist \hspace{0.15cm} gerade}\right] \hspace{-0.15cm} \ = \ \hspace{-0.15cm} 0.5 + 0.5 \cdot  (+0.6) \cdot  (-0.8) \cdot  (+0.4) = 0.404
+
:$$\Rightarrow\hspace{0.3cm}{\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm is \hspace{0.15cm} even}\right] \hspace{-0.15cm} \ = \ \hspace{-0.15cm} 0.5 + 0.5 \cdot  (+0.6) \cdot  (-0.8) \cdot  (+0.4) = 0.404
 
\hspace{0.05cm}.$$
 
\hspace{0.05cm}.$$
  
  
'''(3)'''&nbsp; Entsprechend der Angabenseite gilt:
+
'''(3)'''&nbsp; According to the specification page applies:
 
:$$\pi = \prod\limits_{i =1}^{4} \hspace{0.25cm}(1-2\cdot p_i) \hspace{-0.15cm} \ = \ \hspace{-0.15cm} (1 - 2 \cdot 0.2) \cdot  (1 - 2 \cdot 0.9) \cdot  (1 - 2 \cdot 0.3) \cdot  (1 - 2 \cdot 0.6) $$
 
:$$\pi = \prod\limits_{i =1}^{4} \hspace{0.25cm}(1-2\cdot p_i) \hspace{-0.15cm} \ = \ \hspace{-0.15cm} (1 - 2 \cdot 0.2) \cdot  (1 - 2 \cdot 0.9) \cdot  (1 - 2 \cdot 0.3) \cdot  (1 - 2 \cdot 0.6) $$
 
:$$\Rightarrow\hspace{0.3cm}\pi = \prod\limits_{i =1}^{4} \hspace{0.25cm}(1-2\cdot p_i) \hspace{-0.15cm} \ = \ \hspace{-0.15cm}(+0.6) \cdot  (-0.8) \cdot  (+0.4) \cdot  (-0.2) = 0.0384  
 
:$$\Rightarrow\hspace{0.3cm}\pi = \prod\limits_{i =1}^{4} \hspace{0.25cm}(1-2\cdot p_i) \hspace{-0.15cm} \ = \ \hspace{-0.15cm}(+0.6) \cdot  (-0.8) \cdot  (+0.4) \cdot  (-0.2) = 0.0384  
 
  \hspace{0.05cm}.$$
 
  \hspace{0.05cm}.$$
  
Daraus lassen sich berechnen:
+
From this can be calculated:
:$${\rm Pr}({\rm blau}) = {\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm ist \hspace{0.15cm} gerade}\right] \hspace{-0.15cm} \ = \ \hspace{-0.15cm}  0.5 + 0.5 \cdot \pi  = 0.5 + 0.5 \cdot 0.0384\hspace{0.15cm} \underline{= 0.5192}\hspace{0.05cm},$$
+
:$${\rm Pr}({\rm blue}) = {\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm is \hspace{0.15cm} even}\right] \hspace{-0.15cm} \ = \ \hspace{-0.15cm}  0.5 + 0.5 \cdot \pi  = 0.5 + 0.5 \cdot 0.0384\hspace{0.15cm} \underline{= 0.5192}\hspace{0.05cm},$$
:$${\rm Pr}({\rm rot}) = {\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm ist \hspace{0.15cm} ungerade}\right] \hspace{-0.15cm} \ = \ \hspace{-0.15cm}  0.5 - 0.5 \cdot \pi  = 0.5 - 0.5 \cdot 0.0384\hspace{0.15cm} \underline{= 0.4808}\hspace{0.05cm}. $$
+
:$${\rm Pr}({\rm red}) = {\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm is \hspace{0.15cm} uneven}\right] \hspace{-0.15cm} \ = \ \hspace{-0.15cm}  0.5 - 0.5 \cdot \pi  = 0.5 - 0.5 \cdot 0.0384\hspace{0.15cm} \underline{= 0.4808}\hspace{0.05cm}. $$
  
Addiert man die blauen bzw. die roten Wahrscheinlichkeiten auf der Angabenseite, so erhält man exakt die hier berechneten Werte.  
+
If you add up the blue and red probabilities on the information page, you get exactly the values calculated here.  
  
Für den Quotienten ergibt sich:
+
For the quotient we get:
 
:$$Q = \frac{{\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm ist \hspace{0.15cm} gerade}\right]} { {\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm ist \hspace{0.15cm} ungerade}\right]} = \frac{0.5192}{0.4808}\hspace{0.15cm} \underline{= 1.0799}
 
:$$Q = \frac{{\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm ist \hspace{0.15cm} gerade}\right]} { {\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm ist \hspace{0.15cm} ungerade}\right]} = \frac{0.5192}{0.4808}\hspace{0.15cm} \underline{= 1.0799}
 
\hspace{0.05cm}. $$
 
\hspace{0.05cm}. $$
  
  
'''(4)'''&nbsp; Für den <i>Single Parity&ndash;check Code</i> wurde der extrinsische $L$&ndash;Wert bezüglich des $i$&ndash;ten Bits wie folgt angegeben:
+
'''(4)'''&nbsp; For the <i>single parity&ndash;check code</i>, the extrinsic $L$ value with respect to the $i$th bit was specified as follows:
 
:$$L_{\rm E}(i) = {\rm ln} \hspace{0.15cm}\frac{{\rm Pr} \left [w_{\rm H}(\underline{x}^{(-i)})\hspace{0.15cm}{\rm ist \hspace{0.15cm} gerade} \hspace{0.05cm} | \hspace{0.05cm}\underline{y} \hspace{0.05cm}\right ]}{{\rm Pr} \left [w_{\rm H}(\underline{x}^{(-i)})\hspace{0.15cm}{\rm ist \hspace{0.15cm} ungerade} \hspace{0.05cm} | \hspace{0.05cm}\underline{y} \hspace{0.05cm}\right ]}
 
:$$L_{\rm E}(i) = {\rm ln} \hspace{0.15cm}\frac{{\rm Pr} \left [w_{\rm H}(\underline{x}^{(-i)})\hspace{0.15cm}{\rm ist \hspace{0.15cm} gerade} \hspace{0.05cm} | \hspace{0.05cm}\underline{y} \hspace{0.05cm}\right ]}{{\rm Pr} \left [w_{\rm H}(\underline{x}^{(-i)})\hspace{0.15cm}{\rm ist \hspace{0.15cm} ungerade} \hspace{0.05cm} | \hspace{0.05cm}\underline{y} \hspace{0.05cm}\right ]}
 
  \hspace{0.05cm},$$
 
  \hspace{0.05cm},$$
  
oder:
+
or:
 
:$$L_{\rm E}(i) = {\rm ln} \hspace{0.15cm}\frac{1+\prod_{j \ne i} \hspace{0.25cm}(1-2\cdot p_j)}{1-\prod_{j \ne i} \hspace{0.25cm}(1-2\cdot p_j)}
 
:$$L_{\rm E}(i) = {\rm ln} \hspace{0.15cm}\frac{1+\prod_{j \ne i} \hspace{0.25cm}(1-2\cdot p_j)}{1-\prod_{j \ne i} \hspace{0.25cm}(1-2\cdot p_j)}
 
  \hspace{0.05cm}.$$
 
  \hspace{0.05cm}.$$
  
Beim&nbsp; $\text{SPC (5, 4, 2}$) &nbsp; &#8658; &nbsp; $n = 5$ ergibt sich dieses Produkt für $i = 5$ aus folgenden vier Multiplikanden:
+
At&nbsp; $\text{SPC (5, 4, 2}$) &nbsp; &#8658; &nbsp; $n = 5$, this product for $i = 5$ results from the following four factors:
 
:$$\pi = \prod\limits_{j = 1,  \hspace{0.05cm}2,  \hspace{0.05cm}3,  \hspace{0.05cm}4} \hspace{0.05cm}(1-2\cdot p_j) =  
 
:$$\pi = \prod\limits_{j = 1,  \hspace{0.05cm}2,  \hspace{0.05cm}3,  \hspace{0.05cm}4} \hspace{0.05cm}(1-2\cdot p_j) =  
 
(1-2\cdot p_1) \cdot (1-2\cdot p_2) \cdot (1-2\cdot p_3) \cdot (1-2\cdot p_4)
 
(1-2\cdot p_1) \cdot (1-2\cdot p_2) \cdot (1-2\cdot p_3) \cdot (1-2\cdot p_4)
 
  \hspace{0.05cm}.$$
 
  \hspace{0.05cm}.$$
  
Der Vergleich mit der Teilaufgabe '''(3)''' zeigt, dass $L_{\rm E}(i = 5) = \ln {Q} = \ln {(1.0799)} \ \underline{\approx 0.077}$ ist.
+
The comparison with the subtask '''(3)''' shows that $L_{\rm E}(i = 5) = \ln {Q} = \ln {(1.0799)} \ \underline{\approx 0.077}$.
  
  
'''(5)'''&nbsp; Richtig ist der <u>Lösungsvorschlag 3</u>, weil das Ergebnis für $L_{\rm E}(i = 5)$ unabhängig von $p_5$ ist.
+
'''(5)'''&nbsp; Correct is <u>proposed solution 3</u> because the result for $L_{\rm E}(i = 5)$ is independent of $p_5$.
 
{{ML-Fuß}}
 
{{ML-Fuß}}
  
  
 
[[Category:Channel Coding: Exercises|^4.1 Soft–in Soft–out Decoder^]]
 
[[Category:Channel Coding: Exercises|^4.1 Soft–in Soft–out Decoder^]]

Revision as of 21:44, 29 October 2022

Hamming weights and sequence probabilities

Der Informationstheoretiker  "Robert G. Gallager"  hat sich bereits 1963 mit folgender Fragestellung beschäftigt:

  • Gegeben ist ein Zufallsvektor  $\underline{x} = (x_1, \, x_2, \hspace{-0.04cm} \text{ ...} \hspace{0.08cm} , x_n)$  mit  $n$  binären Elementen  $x_i ∈ \{0, \, 1\}$.
  • Bekannt sind alle Wahrscheinlichkeiten  $p_i = {\rm Pr}(x_i = 1)$  und  $q_i = {\rm Pr}(x_i = 0) = 1 - p_i$  mit Index  $i = 1, \hspace{-0.04cm}\text{ ...} \hspace{0.08cm} ,\ n$.
  • Gesucht ist die Wahrscheinlichkeit, dass die Anzahl der Einsen in diesem Vektor geradzahlig ist.
  • Oder ausgedrückt mit dem  "Hamming–Gewicht":   Wie groß ist die Wahrscheinlichkeit  ${\rm Pr}[w_{\rm H}(\underline{x}) {\rm \ ist \ gerade}]$?


Die Grafik verdeutlicht die Aufgabenstellung für das Beispiel  $n = 4$  sowie  $p_1 = 0.2$,  $p_2 = 0.9$,  $p_3 = 0.3$  und  $p_4 = 0.6$.

  • Für die grün hinterlegte Zeile   ⇒   $\underline{x} = (1, \, 0, \, 0, \, 1)$  gilt  $w_{\rm H}(\underline{x}) = 2$  und
$${\rm Pr}(\underline{x}) = p_1 \cdot q_2 \cdot q_3 \cdot p_4 = 0.0084.$$
  • Blaue Schrift bedeutet "$w_{\rm H}(\underline{x})$ ist gerade". Rote Schrift steht für "$w_{\rm H}(\underline{x})$ ist ungerade".
  • Die Wahrscheinlichkeit  ${\rm Pr}[w_{\rm H}(\underline{x}) {\rm \ ist \ gerade}]$  ist die Summe der blauen Zahlen in der letzten Spalte.
  • Die Summe der roten Zahlen ergibt  ${\rm Pr}[w_{\rm H}(\underline{x}) {\rm \ ist \ ungerade}] = 1 - {\rm Pr}[w_{\rm H}(\underline{x}) {\rm \ ist \ gerade}]$.


Gallager hat das Problem in analytischer Weise gelöst:

$$ {\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm ist \hspace{0.15cm} gerade} \right ] \hspace{-0.15cm} \ = \ \hspace{-0.15cm} 1/2 \cdot [1 + \pi]\hspace{0.05cm},$$
$${\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm ist \hspace{0.15cm} ungerade} \right ] \hspace{-0.15cm} \ = \ \hspace{-0.15cm} 1/2 \cdot [1 - \pi]\hspace{0.05cm}.$$

Hierbei ist die folgende Hilfsgröße verwendet:

$$\pi = \prod\limits_{i =1}^{n} \hspace{0.25cm}(1-2p_i) \hspace{0.05cm}.$$

Die Gleichung wendet man zum Beispiel an, um die extrinsischen  $L$–Werte eines  Single Parity–check Codes  zu berechnen.

Wie bereits in der  "Aufgabe A4.4"  dargelegt, lautet nämlich der extrinsische $L$–Wert mit dem Hamming–Gewicht  $w_{\rm H}$  der verkürzten Folge  $\underline{x}^{(-i)}$:

$$L_{\rm E}(i) = {\rm ln} \hspace{0.15cm}\frac{{\rm Pr} \left [w_{\rm H}(\underline{x}^{(-i)})\hspace{0.15cm}{\rm ist \hspace{0.15cm} gerade} \hspace{0.05cm} | \hspace{0.05cm}\underline{y} \hspace{0.05cm}\right ]}{{\rm Pr} \left [w_{\rm H}(\underline{x}^{(-i)})\hspace{0.15cm}{\rm ist \hspace{0.15cm} ungerade} \hspace{0.05cm} | \hspace{0.05cm}\underline{y} \hspace{0.05cm}\right ]} \hspace{0.05cm}.$$

Hierbei ist berücksichtigt, dass man für  $L_{\rm E}(i)$  nur die anderen Symbole  $(j ≠ i)$  heranziehen darf:

$$\underline{x}^{(-i)} = \big ( \hspace{0.03cm}x_1, \hspace{-0.04cm} \text{ ...} \hspace{0.08cm} , \hspace{0.03cm} x_{i-1}, \hspace{0.43cm} x_{i+1}, \hspace{-0.04cm} \text{ ...} \hspace{0.08cm} , x_{n} \hspace{0.03cm} \big )\hspace{0.03cm}. $$





Hints:



Questions

1

We consider the vector  $\underline{x} = (x_1, \, x_2) \ \Rightarrow \ n = 2$  with  $x_i ∈ \{0, \, 1\}$  and  $p_1 = 0.2, \ p_2 = 0.9$.
What is the probability that  $\underline{x}$  contains an even number of ones?

${\rm Pr}\big [w_{\rm H}(\underline{x}) \ {\rm ist \ gerade}\big ] \ = \ $

2

Berechnen Sie die gleiche Wahrscheinlichkeit für  $\underline{x} = (x_1, \, x_2, \, x_3) \ \Rightarrow \ n = 3$  und  $p_1 = 0.2, \ p_2 = 0.9, \ p_3 = 0.3$.

${\rm Pr}\big [w_{\rm H}(\underline{x}) \ {\rm ist \ gerade}\big ] \ = \ $

3

Now let  $n = 4$  and  $p_1 = 0.2, \ p_2 = 0.9, \ p_3 = 0.3, \ p_4 = 0.6$. Calculate the following quantities according to Gallager's equation:

${\rm Pr(blue) = Pr}\big [w_{\rm H}(\underline{x}) \ {\rm is \ even}\big ] \hspace{0.33cm} = \ $

${\rm Pr(red) = Pr}\big [w_{\rm H}(\underline{x}) \ {\rm is \ uneven}\big ] \hspace{0.1cm} = \ $

$\text{Quotient }Q = {\rm Pr(blau)/Pr(rot)} \hspace{0.4cm} = \ $

4

What is the extrinsic  $L$ value for the symbol  $i = 5$  at  $\text{SPC (5, 4, 2)}$  with  $p_1 = 0.2, \ p_2 = 0.9, \ p_3 = 0.3, \ p_4 = 0.6, \ p_5 = 0.9$?

$L_{\rm E}(i = 5) \ = \ $

5

How does  $L_{\rm E}(i = 5)$ change if we assume  $p_5 = 0.1$  instead?

$L_{\rm E}(i = 5)$  becomes larger.
$L_{\rm E}(i = 5)$  becomes smaller.
$L_{\rm E}(i = 5)$  is not changed compared to subtask (4).


Solution

Derivation "$w_{\rm H}$ is even" for code length $n = 2$.

(1)  According to the adjacent table applies:

$${\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.10cm}{\rm is \hspace{0.10cm} even}\right ] = {\rm Pr} \left [w_{\rm H} = 0 \right] + {\rm Pr} \left [w_{\rm H} = 2 \right] \hspace{0.05cm}. $$

With the probabilities

$$p_1 = {\rm Pr} (x_1 = 1) \hspace{-0.15cm} \ = \ \hspace{-0.15cm} 0.2\hspace{0.05cm},\hspace{0.3cm}q_1 = {\rm Pr} (x_1 = 0) = 0.8\hspace{0.05cm},$$
$$p_2 = {\rm Pr} (x_2 = 1) \hspace{-0.15cm} \ = \ \hspace{-0.15cm} 0.9\hspace{0.05cm},\hspace{0.3cm}q_2 = {\rm Pr} (x_2 = 0) = 0.1$$

one obtains:

$${\rm Pr} \left [w_{\rm H}(\underline{x}) = 0\right] \hspace{-0.15cm} \ = \ \hspace{-0.15cm} {\rm Pr} \left [(x_1 = 0)\cap (x_2 = 0) \right] = q_1 \cdot q_2 = 0.8 \cdot 0.1 = 0.08 \hspace{0.05cm},$$
$${\rm Pr} \left [w_{\rm H}(\underline{x}) = 2\right] \hspace{-0.15cm} \ = \ \hspace{-0.15cm} {\rm Pr} \left [(x_1 = 1)\cap (x_2 = 1) \right] = p_1 \cdot p_2 = 0.2 \cdot 0.9 = 0.18$$
$$\Rightarrow \hspace{0.3cm} {\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm ist \hspace{0.15cm} gerade}\right] = 0.8 + 0.18 \hspace{0.15cm} \underline{= 0.26} \hspace{0.05cm}.$$

The Gallager's equation provides for the same set of parameters:

$${\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm ist \hspace{0.15cm} gerade}\right] \hspace{-0.15cm} \ = \ \hspace{-0.15cm} 0.5 + 0.5 \cdot \prod\limits_{i =1}^{2} \hspace{0.25cm}(1-2\cdot p_i) = 0.5 + 0.5 \cdot (1 - 2 \cdot 0.2)\cdot (1 - 2 \cdot 0.9) = 0.26 \hspace{0.05cm}.$$

The equation given by Gallager 1963 was hereby verified for $n = 2$.


Derivation "$w_{\rm H}$ is even" for code length $n = 3$.

(2)  In the second table, the four combinations with an even number of ones are marked in blue. The probabilities of occurrence of each combination are given in the last column. Thus, the result is:

$$ {\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm ist \hspace{0.15cm} gerade}\right] = 0.056 + 0.216 + 0.006 + 0.126 \hspace{0.15cm} \underline{= 0.404} \hspace{0.05cm}.$$

The red rows provide the complementary event:

$$ {\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm ist \hspace{0.15cm} ungerade}\right] = 0.024 + 0.504 + 0.014 + 0.054= 0.596 \hspace{0.05cm}.$$

The Gallager's equation again gives the exact same result, although it should be noted that this equation is valid for all $n$ and all arbitrary probabilities:

$${\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm is \hspace{0.15cm} even}\right] \hspace{-0.15cm} \ = \ \hspace{-0.15cm} 0.5 + 0.5 \cdot \prod\limits_{i =1}^{3} \hspace{0.25cm}(1-2\cdot p_i) $$
$$\Rightarrow\hspace{0.3cm}{\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm is \hspace{0.15cm} even}\right] \hspace{-0.15cm} \ = \ \hspace{-0.15cm} 0.5 + 0.5 \cdot (+0.6) \cdot (-0.8) \cdot (+0.4) = 0.404 \hspace{0.05cm}.$$


(3)  According to the specification page applies:

$$\pi = \prod\limits_{i =1}^{4} \hspace{0.25cm}(1-2\cdot p_i) \hspace{-0.15cm} \ = \ \hspace{-0.15cm} (1 - 2 \cdot 0.2) \cdot (1 - 2 \cdot 0.9) \cdot (1 - 2 \cdot 0.3) \cdot (1 - 2 \cdot 0.6) $$
$$\Rightarrow\hspace{0.3cm}\pi = \prod\limits_{i =1}^{4} \hspace{0.25cm}(1-2\cdot p_i) \hspace{-0.15cm} \ = \ \hspace{-0.15cm}(+0.6) \cdot (-0.8) \cdot (+0.4) \cdot (-0.2) = 0.0384 \hspace{0.05cm}.$$

From this can be calculated:

$${\rm Pr}({\rm blue}) = {\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm is \hspace{0.15cm} even}\right] \hspace{-0.15cm} \ = \ \hspace{-0.15cm} 0.5 + 0.5 \cdot \pi = 0.5 + 0.5 \cdot 0.0384\hspace{0.15cm} \underline{= 0.5192}\hspace{0.05cm},$$
$${\rm Pr}({\rm red}) = {\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm is \hspace{0.15cm} uneven}\right] \hspace{-0.15cm} \ = \ \hspace{-0.15cm} 0.5 - 0.5 \cdot \pi = 0.5 - 0.5 \cdot 0.0384\hspace{0.15cm} \underline{= 0.4808}\hspace{0.05cm}. $$

If you add up the blue and red probabilities on the information page, you get exactly the values calculated here.

For the quotient we get:

$$Q = \frac{{\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm ist \hspace{0.15cm} gerade}\right]} { {\rm Pr} \left [w_{\rm H}(\underline{x})\hspace{0.15cm}{\rm ist \hspace{0.15cm} ungerade}\right]} = \frac{0.5192}{0.4808}\hspace{0.15cm} \underline{= 1.0799} \hspace{0.05cm}. $$


(4)  For the single parity–check code, the extrinsic $L$ value with respect to the $i$th bit was specified as follows:

$$L_{\rm E}(i) = {\rm ln} \hspace{0.15cm}\frac{{\rm Pr} \left [w_{\rm H}(\underline{x}^{(-i)})\hspace{0.15cm}{\rm ist \hspace{0.15cm} gerade} \hspace{0.05cm} | \hspace{0.05cm}\underline{y} \hspace{0.05cm}\right ]}{{\rm Pr} \left [w_{\rm H}(\underline{x}^{(-i)})\hspace{0.15cm}{\rm ist \hspace{0.15cm} ungerade} \hspace{0.05cm} | \hspace{0.05cm}\underline{y} \hspace{0.05cm}\right ]} \hspace{0.05cm},$$

or:

$$L_{\rm E}(i) = {\rm ln} \hspace{0.15cm}\frac{1+\prod_{j \ne i} \hspace{0.25cm}(1-2\cdot p_j)}{1-\prod_{j \ne i} \hspace{0.25cm}(1-2\cdot p_j)} \hspace{0.05cm}.$$

At  $\text{SPC (5, 4, 2}$)   ⇒   $n = 5$, this product for $i = 5$ results from the following four factors:

$$\pi = \prod\limits_{j = 1, \hspace{0.05cm}2, \hspace{0.05cm}3, \hspace{0.05cm}4} \hspace{0.05cm}(1-2\cdot p_j) = (1-2\cdot p_1) \cdot (1-2\cdot p_2) \cdot (1-2\cdot p_3) \cdot (1-2\cdot p_4) \hspace{0.05cm}.$$

The comparison with the subtask (3) shows that $L_{\rm E}(i = 5) = \ln {Q} = \ln {(1.0799)} \ \underline{\approx 0.077}$.


(5)  Correct is proposed solution 3 because the result for $L_{\rm E}(i = 5)$ is independent of $p_5$.