Difference between revisions of "Theory of Stochastic Signals/Uniformly Distributed Random Variables"

From LNTwww
 
(14 intermediate revisions by 4 users not shown)
Line 7: Line 7:
 
==General description and definition==
 
==General description and definition==
 
<br>
 
<br>
 +
{{BlaueBox|TEXT= 
 +
$\text{Definition:}$&nbsp; A random variable&nbsp; $x$&nbsp; is said to be&nbsp; &raquo;'''uniformly distributed'''&laquo;&nbsp; if it can only take values in the range of&nbsp; $x_{\rm min}$&nbsp; to&nbsp; $x_{\rm max}$&nbsp; with equal probability.
 
[[File:P_ID45__Sto_T_3_4_S1_neu100.png |frame|PDF and CDF of uniform distribution]]
 
[[File:P_ID45__Sto_T_3_4_S1_neu100.png |frame|PDF and CDF of uniform distribution]]
{{BlaueBox|TEXT= 
 
$\text{Definition:}$&nbsp; A random variable&nbsp; $x$&nbsp; is said to be&nbsp; '''uniformly distributed''' if it can only take values in the range of&nbsp; $x_{\rm min}$&nbsp; to&nbsp; $x_{\rm max}$&nbsp; with equal probability.
 
  
The graph shows  
+
The graph shows of such an equally distributed random variable&nbsp; $x$
*on the left the probability density function&nbsp; $f_{x}(x)$,  
+
#on the left the probability density function&nbsp; $f_{x}(x)$,  
*right the distribution function&nbsp; $F_{x}(r)$
+
#on the right the cumulative distribution function&nbsp; $F_{x}(r)$.
  
  
of such an equally distributed random variable&nbsp; $x$.}}
+
From the graph and this definition,&nbsp; the following properties can be derived:
 +
*The probability density function&nbsp; $\rm (PDF)$&nbsp; has in the range from&nbsp; $x_{\rm min}$&nbsp; to&nbsp; $x_{\rm max}$&nbsp; the constant value&nbsp; $1/(x_{\rm max} - x_{\rm min})$.&nbsp;
  
 +
*On the range limits,&nbsp; only half the value &ndash; that is,&nbsp; the average value between the left&ndash;hand and right&ndash;hand limits &ndash; is to be set for&nbsp; $f_{x}(x)$&nbsp; in each case.
  
From the graph and the definition, the following properties can be derived:
+
*The cumulative distribution function&nbsp; $\rm (CDF)$&nbsp; increases linearly from&nbsp; $x_{\rm min}$&nbsp; to&nbsp; $x_{\rm max}$&nbsp; in the range from&nbsp; $0$&nbsp; to&nbsp; $1$&nbsp;.
*The probability density function&nbsp; $\rm (PDF)$&nbsp; has in the range from&nbsp; $x_{\rm min}$&nbsp; to&nbsp; $x_{\rm max}$&nbsp; the constant value&nbsp; $1/(x_{\rm max} - x_{\rm min})$.&nbsp;
+
 
*On the range limits, only half the value - that is, the average value between the left-hand and right-hand limits - is to be set for&nbsp; $f_{x}(x)$&nbsp; in each case.
+
*Mean, variance and standard deviation have the following values:
*The distribution function&nbsp; $\rm (CDF)$&nbsp; increases linearly from&nbsp; $x_{\rm min}$&nbsp; to&nbsp; $x_{\rm max}$&nbsp; in the range from&nbsp; $0$&nbsp; to&nbsp; $1$&nbsp;.
+
:$$m_{\rm 1} = \frac{x_ {\rm max} + x_{\rm min} }{2},\hspace{0.5cm}
*Mean and dispersion have the following values for the uniform distribution:
+
\sigma^2 = \frac{[x_{\rm max} - x_{\rm min}]^2}{12},\hspace{0.5cm}
:$$m_{\rm 1} = \frac{\it x_ {\rm max} \rm + \it x_{\rm min}}{2},\hspace{0.5cm}
+
\sigma = \frac{x_{\rm max} - x_{\rm min} }{2 \sqrt{3} }.$$
\sigma = \frac{\it x_{\rm max} - \it x_{\rm min}}{2 \sqrt{3}}.$$
+
 
*For symmetric PDF &nbsp; &rArr; &nbsp; $x_{\rm min} = -x_{\rm max}$&nbsp; we obtain as a special case the mean&nbsp; $m_1 = 0$&nbsp; and the variance&nbsp; $σ^2 = x_{\rm max}^2/3.$
+
*For symmetric PDF &nbsp; &rArr; &nbsp; $x_{\rm min} = -x_{\rm max}$&nbsp; we obtain as a special case the mean&nbsp; $m_1 = 0$&nbsp; and the variance&nbsp; $σ^2 = x_{\rm max}^2/3.$}}
  
  
 
{{GraueBox|TEXT=   
 
{{GraueBox|TEXT=   
$\text{Example 1:}$&nbsp;  
+
$\text{Example 1:}$&nbsp; The graph shows two signal waveforms with uniform amplitude distribution.
The graph shows two signal waveforms with uniform amplitude distribution.
+
[[File:P_ID618__Sto_T_3_4_S2_neu100.png |right|frame|Examples of uniformly distributed signals]]
  
[[File:P_ID618__Sto_T_3_4_S2_neu100.png |right|frame|Examples of uniformly distributed signals]]
 
  
 
   
 
   
*On the left, statistical independence of the individual samples is assumed, that is,the random variable&nbsp; $x_ν$&nbsp; can take all values between&nbsp; $x_{\rm min}$&nbsp; and&nbsp; $x_{\rm max}$&nbsp; with equal probability, and independently of the past&nbsp; $(x_{ν-1}, x_{ν-2}, \hspace{0.1cm}\text{...}).$  
+
$\rm (A)$&nbsp; On the left,&nbsp; statistical independence of the individual samples is assumed,&nbsp; that is,&nbsp; the random variable&nbsp; $x_ν$&nbsp; can take all values between&nbsp; $x_{\rm min}$&nbsp; and&nbsp; $x_{\rm max}$&nbsp; with equal probability,&nbsp; and independently of the past&nbsp; $(x_{ν-1}, x_{ν-2}, \hspace{0.1cm}\text{...}).$  
  
  
*For the right signal&nbsp; $y(t)$&nbsp; this independence of successive signal values is no longer given&nbsp; Rather, this sawtooth signal represents a deterministic signal.
+
$\rm (B)$&nbsp; For the right signal&nbsp; $y(t)$&nbsp; this independence of successive signal values is no longer given.&nbsp; Rather,&nbsp; this sawtooth signal represents a deterministic signal.}}
  
}}
+
==Importance of the uniform distribution for Communications Engineering==
 
 
==Bedeutung der Gleichverteilung für die Nachrichtentechnik==
 
 
<br>
 
<br>
Die Bedeutung gleichverteilter Zufallsgrößen für die Informations&ndash; und Kommunikationstechnik ist darauf zurückzuführen, dass diese WDF–Form aus Sicht der Informationstheorie unter der Nebenbedingung&nbsp; [[Digital_Signal_Transmission/Optimierung_der_Basisbandübertragungssysteme#Leistungs.E2.80.93_und_Spitzenwertbegrenzung|Spitzenwertbegrenzung]]&nbsp; ein Optimum darstellt:  
+
The importance of uniformly distributed random variables for information&nbsp; and communication technology is due to the fact that,&nbsp; from the point of view of information theory,&nbsp; this PDF form represents an optimum under the constraint&nbsp; [[Digital_Signal_Transmission/Optimization_of_Baseband_Transmission_Systems#Power_and_peak_limitation|&raquo;peak limitation&laquo;]]:  
*Mit keiner anderen Verteilung als der Gleichverteilung erreicht man unter dieser Voraussetzung eine größere&nbsp; [[Information_Theory/Differentielle_Entropie#Differentielle_Entropie_einiger_spitzenwertbegrenzter_Zufallsgr.C3.B6.C3.9Fen|differentielle Entropie]].   
+
*With no distribution other than the uniform distribution one achieves greater&nbsp; [[Information_Theory/Differential_Entropy#Differential_entropy_of_some_peak-constrained_random_variables|&raquo;differential entropy&laquo;]]&nbsp; under this condition.  
*Mit dieser Thematik beschäftigt sich das Kapitel&nbsp; [[Information_Theory/Differentielle_Entropie|Differentielle Entropie]]&nbsp; im Buch "Informationstheorie".  
+
   
 +
*This topic is dealt with in the chapter&nbsp; [[Information_Theory/Differential_Entropy|&raquo;Differential Entropy&laquo;]]&nbsp; in the book&nbsp; &raquo;Information Theory&laquo;.  
  
  
Daneben sind unter Anderem noch folgende Punkte zu nennen:
+
{{BlaueBox|TEXT=
 +
$\text{In addition,&nbsp; the following points should be mentioned,&nbsp; among others:}$
  
'''(1)''' &nbsp; Die Bedeutung der Gleichverteilung für die Simulation nachrichtentechnischer Systeme ist darauf zurückzuführen, dass man entsprechende "Pseudo–Zufallsgeneratoren" relativ einfach realisieren kann, und dass sich daraus andere Verteilungen wie zum Beispiel die&nbsp; [[Theory_of_Stochastic_Signals/Gaußverteilte_Zufallsgröße#Wahrscheinlichkeitsdichte-_und_Verteilungsfunktion|Gaußverteilung]]&nbsp; und die&nbsp; [[Theory_of_Stochastic_Signals/Exponentialverteilte_Zufallsgrößen#Einseitige_Exponentialverteilung|Exponentialverteilung]]&nbsp; leicht ableiten lassen.  
+
'''(1)''' &nbsp; The importance of the uniform distribution for the simulation of communication systems is due to the fact that one can realize corresponding&nbsp; &raquo;pseudo-random generators&laquo;&nbsp; relatively easily,&nbsp; and that other distributions,&nbsp; such as the&nbsp; [[Theory_of_Stochastic_Signals/Gaussian_Distributed_Random_Variables#Probability_density_function_.E2.80.93_Cumulative_density_function|&raquo;Gaussian distribution&laquo;]]&nbsp; and the&nbsp; [[Theory_of_Stochastic_Signals/Exponentially_Distributed_Random_Variables#One-sided_exponential_distribution|&raquo;exponential distribution&laquo;]]&nbsp; can be easily derived.  
  
'''(2)''' &nbsp; In der ''Bildverarbeitung & Bildcodierung'' wird oft vereinfachend mit der Gleichverteilung anstelle der tatsächlichen, meist sehr viel komplizierteren Verteilung des Originalbildes gerechnet, da der Unterschied des Informationsgehaltes zwischen ''natürlichem Bild'' und dem auf der Gleichverteilung basierenden Modell relativ gering ist.  
+
'''(2)''' &nbsp; In&nbsp; &raquo;Image Processing&laquo;,&nbsp; simplifying calculations are often made using the uniform distribution instead of the actual distribution of the original image,&nbsp; which is often much more complicated,&nbsp; since the difference in information content between a&nbsp; &raquo;natural image&laquo;&nbsp; and the model based on the uniform distribution is relatively small.  
  
'''(3)''' &nbsp; Für die Modellierung übertragungstechnischer Systeme sind gleichverteilte Zufallsgrößen dagegen die Ausnahme.&nbsp; Ein Beispiel für eine tatsächlich (nahezu) gleichverteilte Zufallsgröße ist die Phase bei kreissymmetrischen Störungen, wie sie beispielsweise bei&nbsp; ''Quadratur&ndash;Amplitudenmodulationsverfahren''&nbsp; (QAM) auftreten.  
+
'''(3)''' &nbsp; For modeling transmission systems,&nbsp; on the other hand,&nbsp; uniformly distributed random variables are the exception.&nbsp; An example of an&nbsp; $($nearly$)$&nbsp; uniformly distributed random variable is the phase in the presence of circularly symmetric interference,&nbsp; such as occurs in&nbsp; &raquo;quadrature amplitude modulation techniques&laquo;&nbsp; $\rm (QAM)$.}}
 +
  
Das interaktive Applet&nbsp; [[Applets:WDF,_VTF_und_Momente_spezieller_Verteilungen_(Applet)|WDF, VTF und Momente spezieller Verteilungen]]&nbsp; berechnet alle Kenngrößen der Gleichverteilung für beliebige Parameter&nbsp; $x_{\rm min}$&nbsp; und&nbsp; $x_{\rm max}$.  
+
The HTML5/JavaScript applet&nbsp; [[Applets:PDF,_CDF_and_Moments_of_Special_Distributions|&raquo;PDF, CDF and moments of special distributions&laquo;]]&nbsp; calculates the characteristics of the uniform distribution for any parameters&nbsp; $x_{\rm min}$&nbsp; and&nbsp; $x_{\rm max}$.  
  
  
==Erzeugung einer Gleichverteilung mit Pseudo&ndash;Noise&ndash;Generatoren==
+
==Generating a uniform distribution with pseudo&ndash;noise generators==
 
<br>
 
<br>
{{BlaueBox|TEXT=
+
{{BlaueBox|TEXT=
$\text{Definition}$&nbsp; Die heute verwendeten Zufallsgeneratoren sind meist&nbsp; '''pseudozufällig'''.&nbsp; Das bedeutet,  
+
$\text{Definition}$&nbsp; The random generators used today are mostly&nbsp; &raquo;'''pseudo&ndash;random'''&laquo;.&nbsp; This means,  
*dass die erzeugte Folge als das Ergebnis eines festen Algorithmuses eigentlich deterministisch ist,  
+
*that the sequence generated is actually deterministic as the result of a fixed algorithm,
*für den Anwender jedoch aufgrund der großen Periodenlänge&nbsp; $P$&nbsp; als stochastisch erscheint.
 
  
 +
*but appears to the user as stochastic due to the large period length&nbsp; $P$.
  
Mehr hierzu im Kapitel&nbsp; [[Theory_of_Stochastic_Signals/Erzeugung_von_diskreten_Zufallsgrößen|Erzeugung von diskreten Zufallsgrößen]]. }}
 
  
 +
More on this in the chapter&nbsp; [[Theory_of_Stochastic_Signals/Generation_of_Discrete_Random_Variables|&raquo;Generation of discrete random variables&laquo;]]. }}
  
Für die Systemsimulation haben Pseudo&ndash;Noise&nbsp; $\rm (PN)$&ndash;Generatoren gegenüber echten Zufallsgeneratoren den entscheidenden Vorteil, dass die erzeugten Zufallsfolgen ohne Speicherung reproduzierbar sind, was
 
*zum einen den Vergleich verschiedener Systemmodelle ermöglicht, und
 
*auch die Fehlersuche wesentlich erleichtert.
 
  
 +
For system simulation,&nbsp; pseudo&ndash;noise&nbsp; $\rm (PN)$&nbsp; generators have the distinct advantage over true random generators that the generated random sequences can be reproduced without storage, which allows the comparison of different system models,&nbsp; and also makes troubleshooting much easier.
  
Ein Zufallsgenerator sollte dabei folgende Kriterien erfüllen:  
+
{{BlaueBox|TEXT=
 +
$\text{A random sequence generator should meet the following criteria:}$
  
'''(1)''' &nbsp; Die Zufallsgrößen&nbsp; $x_ν$&nbsp; einer generierten Folge sollten mit sehr guter Näherung gleichverteilt sein. Bei wertdiskreter Darstellung an einem Rechner erfordert dies unter anderem eine hinreichend&nbsp; ''hohe Bitauflösung'',&nbsp; zum Beispiel mit&nbsp; $32$&nbsp; oder&nbsp; $64$&nbsp; Bit pro Abtastwert.  
+
'''(1)''' &nbsp; The random variables&nbsp; $x_ν$&nbsp; of a generated sequence should be uniformly distributed with very good approximation.&nbsp; For the discrete-value representation on a computer,&nbsp; this requires,&nbsp; among other things,&nbsp; a sufficiently&nbsp; high bit resolution,&nbsp; for example, with&nbsp; $32$&nbsp; or&nbsp; $64$&nbsp; bits per sample.  
  
'''(2)''' &nbsp; Bildet man aus der sequentiellen Zufallsfolge&nbsp; $〈x_ν〉$&nbsp; jeweils nichtüberlappende Paare von Zufallsgrößen, beispielsweise&nbsp; $(x_ν, x_{ν+1})$,&nbsp; $(x_{ν+2}$,&nbsp; $x_{ν+3})$, ... , so sollten diese&nbsp; ''Tupel''&nbsp; in einer zweidimensionalen Darstellung innerhalb eines Quadrates ebenfalls gleichverteilt sein.  
+
'''(2)''' &nbsp; If one forms from the sequential random sequence&nbsp; $〈x_ν〉$&nbsp; respectively non-overlapping pairs of random variables,&nbsp; for example&nbsp; $(x_ν, x_{ν+1})$,&nbsp; $(x_{ν+2}$,&nbsp; $x_{ν+3})$, ... , then these&nbsp; &raquo;tuples&laquo;&nbsp; should also be equally distributed in a two-dimensional representation within a square.  
  
'''(3)''' &nbsp; Bildet man aus der sequentiellen Folge&nbsp; $〈x_ν〉$&nbsp; nicht überlappende&nbsp; $n$&ndash;''Tupel'' &nbsp; von Zufallsgrößen &nbsp; ⇒ &nbsp; $(x_ν$, ... , $x_{ν+n–1})$,&nbsp; $(x_{ν+n}$, ... , $x_{ν+2n–1})$&nbsp; usw., so sollten auch diese innerhalb eines&nbsp; $n$&ndash;dimensionalen Würfels möglichst die Gleichverteilung ergeben.  
+
'''(3)''' &nbsp; If one forms from the sequential series&nbsp; $〈x_ν〉$&nbsp; non-overlapping&nbsp; $n$&ndash;tuples &nbsp; of random variables &nbsp; ⇒ &nbsp; $(x_ν$, . ... , $x_{ν+n-1})$,&nbsp; $(x_{ν+n}$, ... , $x_{ν+2n-1})$&nbsp; and so on, <br>then these should also yield the uniform distribution within a&nbsp; $n$&ndash;dimensional cube.}}
  
  
''Anmerkung:''
+
 
*Die erste Forderung bezieht sich ausschließlich auf die&nbsp; ''Amplitudenverteilung''&nbsp; $\rm (WDF)$&nbsp; und ist im Allgemeinen leichter zu erfüllen.  
+
$\text{Note:}$
*Die weiteren Forderungen gewährleisten eine „ausreichende Zufälligkeit” der Folge.&nbsp; Sie betreffen die statistische Unabhängigkeit aufeinander folgender Zufallswerte.  
+
*The first requirement refers exclusively to the&nbsp; &raquo;amplitude distribution&laquo;&nbsp; $\rm (PDF)$&nbsp; and is generally easier to satisfy.
 +
 +
*The other requirements ensure&nbsp; &raquo;sufficient randomness&laquo;&nbsp; of the sequence.&nbsp; They concern the statistical independence of successive random values.  
  
  
 
==Multiplicative Congruental Generator==
 
==Multiplicative Congruental Generator==
 
<br>
 
<br>
$\text{Multiplicative Congruental Generator}$&nbsp; ist das bekannteste Verfahren  zur Erzeugung einer Folge&nbsp; $〈 x_\nu 〉$&nbsp; mit gleichverteilten Werten&nbsp; $ x_\nu$&nbsp; zwischen&nbsp; $0$&nbsp; und&nbsp; $1$.&nbsp; Diese Methode wird hier stichpunktartig angegeben:  
+
The&nbsp; &raquo;'''multiplicative congruental generator'''&laquo;&nbsp; is the best known method for generating a sequence&nbsp; $〈 x_\nu 〉$&nbsp; with equally distributed values&nbsp; $ x_\nu$&nbsp; between&nbsp; $0$&nbsp; and&nbsp; $1$.&nbsp; This method is given here in a bullet-point fashion:
 +
 
 +
'''(1)''' &nbsp; These random generators are based on the successive manipulation of an integer variable&nbsp; $k$.&nbsp; If the number representation in the computer happens with&nbsp; $L$&nbsp; bit,&nbsp; this variable takes all values between&nbsp; $1$&nbsp; and&nbsp; $2^{L - 1}$&nbsp; exactly once each,&nbsp; if the sign bit is handled appropriately.
 +
 
 +
'''(2)''' &nbsp; The random variable&nbsp; $x={k}/{\rm 2^{\it L - \rm 1}}$&nbsp;  derived from this is also discrete-valued&nbsp; $($with level number&nbsp; $M = 2^{L- 1})$:
 +
::$$x={k}/{\rm 2^{\it L - \rm 1}} = k\cdot \Delta x \in \{\Delta x, \hspace{0.05cm}2\cdot \Delta x,\hspace{0.05cm}\text{ ...}\hspace{0.05cm} , \hspace{0.05cm}1-\Delta x,\hspace{0.05cm} 1\}.$$
 +
:If the bit number&nbsp; $L$&nbsp; is sufficiently large,&nbsp; the distance&nbsp; $Δx = 1/2^{L- 1}$&nbsp; between two possible values is very small,&nbsp; and one may well interpret&nbsp; $x$&nbsp; as a continuous-valued random variable in the context of simulation accuracy.  
 +
 
 +
'''(3)''' &nbsp; The recursive generation rule of such&nbsp;  &raquo;multiplicative congruential generators&laquo;&nbsp; is:
 +
::$$k_\nu=(a\cdot k_{\nu-1})\hspace{0.1cm} \rm mod \hspace{0.1cm} \it m.$$
  
'''(1)''' &nbsp; Diese Zufallsgeneratoren basieren auf der sukzessiven Manipulation einer Integervariablen&nbsp; $k$.&nbsp; Geschieht die Zahlendarstellung im Rechner mit&nbsp; $L$&nbsp; Bit, so nimmt diese Variable bei geeigneter Behandlung des Vorzeichenbits alle Werte zwischen&nbsp; $1$&nbsp; und&nbsp; $2^{L − 1}$&nbsp; jeweils genau einmal an.  
+
'''(4)''' &nbsp; The statistical properties of the sequence depend crucially on the parameters&nbsp; $a$&nbsp; and&nbsp; $m$.&nbsp; The initial value&nbsp; $k_0$&nbsp; has a minor importance for the statistics.  
  
'''(2)''' &nbsp; Die hieraus abgeleitete Zufallsgröße&nbsp; $x={k}/{\rm 2^{\it L - \rm 1}}$&nbsp; ist ebenfalls diskret&nbsp; $($mit Stufenzahl&nbsp; $M = 2^{L– 1})$:
+
'''(5)''' &nbsp; The best results are obtained with the base&nbsp; $m =2\hspace{0.05cm}^l-1$,&nbsp; where&nbsp; $l$&nbsp; denotes any natural number.&nbsp; Widely used in computers with 32-bit architecture and one sign bit is the base&nbsp; $m = 2^{31} - 1 = 2\hspace{0.08cm}147\hspace{0.08cm}483\hspace{0.08cm}647$.&nbsp; A corresponding algorithm is:
:$$x={k}/{\rm 2^{\it L - \rm 1}} = k\cdot \Delta x \in  \{\Delta x, \hspace{0.05cm}2\cdot \Delta x,\hspace{0.05cm}\text{ ...}\hspace{0.05cm} , \hspace{0.05cm}1-\Delta x,\hspace{0.05cm} 1\}.$$
+
::$$k_\nu=(16807\cdot k_{\nu-1})\hspace{0.1cm} \rm mod\hspace{0.1cm}(2^{31}-1).$$
:Ist die Bitanzahl $L$ hinreichend groß, so ist der Abstand&nbsp; $Δx = 1/2^{L– 1}$&nbsp; zwischen zwei möglichen Werten sehr klein, und man kann&nbsp; $x$&nbsp; im Rahmen der Simulationsgenauigkeit durchaus als eine wertkontinuierliche Zufallsgröße interpretieren.
 
  
'''(3)''' &nbsp; Die rekursive Generierungsvorschrift eines solchen&nbsp; ''Multiplicative Congruential Generators''&nbsp; lautet:
+
'''(6)''' &nbsp; For such a generator, only the initial value&nbsp; $k_0 = 0$&nbsp; is not allowed.&nbsp; For&nbsp; $k_0 \ne 0$&nbsp; the period duration&nbsp; $P = 2^{31} - 2.$
:$$k_\nu=(a\cdot k_{\nu-1})\hspace{0.1cm} \rm mod \hspace{0.1cm} \it m.$$
 
  
'''(4)''' &nbsp; Die statistischen Eigenschaften der Folge hängen entscheidend von den Parametern&nbsp; $a$&nbsp; und&nbsp; $m$&nbsp; ab. Der Startwert&nbsp; $k_0$&nbsp; hat dagegen für die Statistik eine eher untergeordnete Bedeutung.
+
{{GraueBox|TEXT=
 +
[[File:EN_Sto_T_3_4_S4.png |right|frame| Multiplicative Congruental Generator&nbsp; $($C program$)$]]
  
'''(5)''' &nbsp; Die besten Ergebnisse erzielt man mit der Basis&nbsp; $m =2\hspace{0.05cm}^l-1$, wobei&nbsp; $l$&nbsp; eine beliebige natürliche Zahl angibt. Weit verbreitet ist bei Rechnern mit 32 Bit-Architektur und einem Vorzeichenbit die Basis&nbsp; $m = 2^{31} - 1 = 2\hspace{0.08cm}147\hspace{0.08cm}483\hspace{0.08cm}647$.&nbsp; Ein entsprechender Algorithmus lautet:  
+
$\text{Example 2:}$&nbsp; We analyze the&nbsp; &raquo;multiplicative congruental generator&laquo;&nbsp; in more detail:
:$$k_\nu=(16807\cdot k_{\nu-1})\hspace{0.1cm} \rm mod\hspace{0.1cm}(2^{31}-1).$$
 
  
'''(6)''' &nbsp; Für einen solchen Generator ist nur der Startwert&nbsp; $k_0 = 0$&nbsp; nicht erlaubt.&nbsp; Für&nbsp; $k_0 \ne 0$&nbsp; beträgt die Periodendauer&nbsp; $P = 2^{31} - 2.$
 
  
[[File:EN_Sto_T_3_4_S4.png |right|frame| Multiplicative Congruental Generator (C-Programm)]]
 
{{GraueBox|TEXT= 
 
$\text{Beispiel 2:}$&nbsp; Wir analysieren den oben beschriebenen&nbsp; ''Multiplicative Congruental Generator''&nbsp; genauer:
 
*Den Algorithmus kann man allerdings auf einem 32 Bit&ndash;Rechner nicht direkt implementieren, da das Multiplikationsergebnis bis zu 46 Bit benötigt.
 
*Er kann aber so abgewandelt werden, dass zu keinem Zeitpunkt der Berechnung der 32 Bit&ndash;Integerzahlenbereich überschritten wird.
 
*Das so modifizierte C-Programm&nbsp; $\text{uniform( )}$&nbsp; ist rechts angegeben.}}
 
  
==Aufgaben zum Kapitel==
+
*The algorithm cannot be implemented directly on a 32&ndash;bit computer,&nbsp; since the multiplication result requires up to 46 bits.
 +
 
 +
*But it can be modified in such a way that at no time during the calculation the 32&ndash;bit integer number range is exceeded.
 +
 
 +
*The C program&nbsp; $\text{uniform( )}$&nbsp;  thus modified is given on the right.}}
 +
 
 +
==Exercises for the chapter==
 
<br>
 
<br>
[[Aufgaben:3.5 Dreieck- und Trapezsignal|Aufgabe 3.5: Dreieck&ndash; und Trapezsignal]]
+
[[Aufgaben:Exercise_3.5:_Triangular_and_Trapezoidal_Signal|Exercise 3.5: Triangular and Trapezoidal Signal]]
  
[[Aufgaben:3.5Z Antennengebiete|Aufgabe 3.5Z: Antennengebiete]]
+
[[Aufgaben:Exercise_3.5Z:_Antenna_Areas|Exercise 3.5Z: Antenna Areas]]
  
  
 
{{Display}}
 
{{Display}}

Latest revision as of 18:01, 20 February 2024

General description and definition


$\text{Definition:}$  A random variable  $x$  is said to be  »uniformly distributed«  if it can only take values in the range of  $x_{\rm min}$  to  $x_{\rm max}$  with equal probability.

PDF and CDF of uniform distribution

The graph shows of such an equally distributed random variable  $x$

  1. on the left the probability density function  $f_{x}(x)$,
  2. on the right the cumulative distribution function  $F_{x}(r)$.


From the graph and this definition,  the following properties can be derived:

  • The probability density function  $\rm (PDF)$  has in the range from  $x_{\rm min}$  to  $x_{\rm max}$  the constant value  $1/(x_{\rm max} - x_{\rm min})$. 
  • On the range limits,  only half the value – that is,  the average value between the left–hand and right–hand limits – is to be set for  $f_{x}(x)$  in each case.
  • The cumulative distribution function  $\rm (CDF)$  increases linearly from  $x_{\rm min}$  to  $x_{\rm max}$  in the range from  $0$  to  $1$ .
  • Mean, variance and standard deviation have the following values:
$$m_{\rm 1} = \frac{x_ {\rm max} + x_{\rm min} }{2},\hspace{0.5cm} \sigma^2 = \frac{[x_{\rm max} - x_{\rm min}]^2}{12},\hspace{0.5cm} \sigma = \frac{x_{\rm max} - x_{\rm min} }{2 \sqrt{3} }.$$
  • For symmetric PDF   ⇒   $x_{\rm min} = -x_{\rm max}$  we obtain as a special case the mean  $m_1 = 0$  and the variance  $σ^2 = x_{\rm max}^2/3.$


$\text{Example 1:}$  The graph shows two signal waveforms with uniform amplitude distribution.

Examples of uniformly distributed signals


$\rm (A)$  On the left,  statistical independence of the individual samples is assumed,  that is,  the random variable  $x_ν$  can take all values between  $x_{\rm min}$  and  $x_{\rm max}$  with equal probability,  and independently of the past  $(x_{ν-1}, x_{ν-2}, \hspace{0.1cm}\text{...}).$


$\rm (B)$  For the right signal  $y(t)$  this independence of successive signal values is no longer given.  Rather,  this sawtooth signal represents a deterministic signal.

Importance of the uniform distribution for Communications Engineering


The importance of uniformly distributed random variables for information  and communication technology is due to the fact that,  from the point of view of information theory,  this PDF form represents an optimum under the constraint  »peak limitation«:

  • With no distribution other than the uniform distribution one achieves greater  »differential entropy«  under this condition.


$\text{In addition,  the following points should be mentioned,  among others:}$

(1)   The importance of the uniform distribution for the simulation of communication systems is due to the fact that one can realize corresponding  »pseudo-random generators«  relatively easily,  and that other distributions,  such as the  »Gaussian distribution«  and the  »exponential distribution«  can be easily derived.

(2)   In  »Image Processing«,  simplifying calculations are often made using the uniform distribution instead of the actual distribution of the original image,  which is often much more complicated,  since the difference in information content between a  »natural image«  and the model based on the uniform distribution is relatively small.

(3)   For modeling transmission systems,  on the other hand,  uniformly distributed random variables are the exception.  An example of an  $($nearly$)$  uniformly distributed random variable is the phase in the presence of circularly symmetric interference,  such as occurs in  »quadrature amplitude modulation techniques«  $\rm (QAM)$.


The HTML5/JavaScript applet  »PDF, CDF and moments of special distributions«  calculates the characteristics of the uniform distribution for any parameters  $x_{\rm min}$  and  $x_{\rm max}$.


Generating a uniform distribution with pseudo–noise generators


$\text{Definition}$  The random generators used today are mostly  »pseudo–random«.  This means,

  • that the sequence generated is actually deterministic as the result of a fixed algorithm,
  • but appears to the user as stochastic due to the large period length  $P$.


More on this in the chapter  »Generation of discrete random variables«.


For system simulation,  pseudo–noise  $\rm (PN)$  generators have the distinct advantage over true random generators that the generated random sequences can be reproduced without storage, which allows the comparison of different system models,  and also makes troubleshooting much easier.

$\text{A random sequence generator should meet the following criteria:}$

(1)   The random variables  $x_ν$  of a generated sequence should be uniformly distributed with very good approximation.  For the discrete-value representation on a computer,  this requires,  among other things,  a sufficiently  high bit resolution,  for example, with  $32$  or  $64$  bits per sample.

(2)   If one forms from the sequential random sequence  $〈x_ν〉$  respectively non-overlapping pairs of random variables,  for example  $(x_ν, x_{ν+1})$,  $(x_{ν+2}$,  $x_{ν+3})$, ... , then these  »tuples«  should also be equally distributed in a two-dimensional representation within a square.

(3)   If one forms from the sequential series  $〈x_ν〉$  non-overlapping  $n$–tuples   of random variables   ⇒   $(x_ν$, . ... , $x_{ν+n-1})$,  $(x_{ν+n}$, ... , $x_{ν+2n-1})$  and so on,
then these should also yield the uniform distribution within a  $n$–dimensional cube.


$\text{Note:}$

  • The first requirement refers exclusively to the  »amplitude distribution«  $\rm (PDF)$  and is generally easier to satisfy.
  • The other requirements ensure  »sufficient randomness«  of the sequence.  They concern the statistical independence of successive random values.


Multiplicative Congruental Generator


The  »multiplicative congruental generator«  is the best known method for generating a sequence  $〈 x_\nu 〉$  with equally distributed values  $ x_\nu$  between  $0$  and  $1$.  This method is given here in a bullet-point fashion:

(1)   These random generators are based on the successive manipulation of an integer variable  $k$.  If the number representation in the computer happens with  $L$  bit,  this variable takes all values between  $1$  and  $2^{L - 1}$  exactly once each,  if the sign bit is handled appropriately.

(2)   The random variable  $x={k}/{\rm 2^{\it L - \rm 1}}$  derived from this is also discrete-valued  $($with level number  $M = 2^{L- 1})$:

$$x={k}/{\rm 2^{\it L - \rm 1}} = k\cdot \Delta x \in \{\Delta x, \hspace{0.05cm}2\cdot \Delta x,\hspace{0.05cm}\text{ ...}\hspace{0.05cm} , \hspace{0.05cm}1-\Delta x,\hspace{0.05cm} 1\}.$$
If the bit number  $L$  is sufficiently large,  the distance  $Δx = 1/2^{L- 1}$  between two possible values is very small,  and one may well interpret  $x$  as a continuous-valued random variable in the context of simulation accuracy.

(3)   The recursive generation rule of such  »multiplicative congruential generators«  is:

$$k_\nu=(a\cdot k_{\nu-1})\hspace{0.1cm} \rm mod \hspace{0.1cm} \it m.$$

(4)   The statistical properties of the sequence depend crucially on the parameters  $a$  and  $m$.  The initial value  $k_0$  has a minor importance for the statistics.

(5)   The best results are obtained with the base  $m =2\hspace{0.05cm}^l-1$,  where  $l$  denotes any natural number.  Widely used in computers with 32-bit architecture and one sign bit is the base  $m = 2^{31} - 1 = 2\hspace{0.08cm}147\hspace{0.08cm}483\hspace{0.08cm}647$.  A corresponding algorithm is:

$$k_\nu=(16807\cdot k_{\nu-1})\hspace{0.1cm} \rm mod\hspace{0.1cm}(2^{31}-1).$$

(6)   For such a generator, only the initial value  $k_0 = 0$  is not allowed.  For  $k_0 \ne 0$  the period duration  $P = 2^{31} - 2.$

Multiplicative Congruental Generator  $($C program$)$

$\text{Example 2:}$  We analyze the  »multiplicative congruental generator«  in more detail:


  • The algorithm cannot be implemented directly on a 32–bit computer,  since the multiplication result requires up to 46 bits.
  • But it can be modified in such a way that at no time during the calculation the 32–bit integer number range is exceeded.
  • The C program  $\text{uniform( )}$  thus modified is given on the right.

Exercises for the chapter


Exercise 3.5: Triangular and Trapezoidal Signal

Exercise 3.5Z: Antenna Areas