ELEG3410 Random Process & DSP Tutorial # 2 Outline: 1. Probability Density Function (p.d.f) & Continuous R.V & Discrete R.V. 2. Probability Distribution Function (PDF) 3. Expected Value & Moment 4. Error Function of Gaussian Distribution 5. Error Rate in PCM 11. Probability Density Function (pdf) Continuous Variable: Gaussian / Normal Laplacian 2 ⎛ x − µ ⎞1⎛ ⎞1 ()x − µ ⎜ ⎟ p()x = exp − ⎜ ⎟p()x = exp − ⎜ ⎟2⎜ ⎟ 2b b2 σ2 π σ ⎝ ⎠ ⎝ ⎠ Uniform 1p()x = b − a Discrete Variable: Assume the discrete random variable x takes only the values x1, x2, …, xj, …, xn with probability P(x1), P(x2), …, P(xj), …, P(xn). The p.d.f. of x is n p(x) = P(x ) ⋅ δ (x − x )∑ j jj =1 2P(x ) 3P(x ) P(x ) 4 nP(x ) P (x ) 1 2……x x x x x1 2 3 4 n Example: Throw a dice: {1,2,3,4,5,6} 1 1 1 1 1 1p(x) = δ (x −1) + δ (x − 2) + δ (x − 3) + δ (x − 4) + δ (x − 5) + δ (x − 6) 6 6 6 6 6 6 2. Probability Distribution Function (PDF) Continuous Variable: The distribution function of random variable x x1W()x = p(x)dx = P(x ≤ x) 1 1∫− ∞The p.d.f. p(x) is not a probability but a rate of change of the probability dW(x)dxW(x) : Gaussian / Normal 2⎛ ⎞1 ()x − µ ⎜ ⎟p()x = exp −⎜ 2 ⎟2 σ2 π σ ⎝ ⎠probability density function and probability distribution funtion 3Discrete Variable: ...
ELEG3410 Random Process & DSP Tutorial # 2 Outline: 1. Probability Density Function (p.d.f) & Continuous R.V & Discrete R.V. 2. Probability Distribution Function (PDF) 3.Expected Value & Moment 4. Error Function of Gaussian Distribution 5.Error Rate in PCM
1
1. Probability Density Function (pdf) Continuous Variable: Gaussian / Normal Laplacian ⎛x−µ⎞ 2 1⎛(x−µ)⎞1 (x)=exp⎜−⎟p(x)=exp⎜ ⎟p− 2 σ2b b 2π σ2 ⎝ ⎠⎝ ⎠
Uniform 1 p(x)=b−a
Discrete Variable: Assume the discrete random variablextakes only the values x1,x2, ,xj, ,xn… … with probability P(x1), P(x2), …, P(xj), …, P(xn). Thep.d.f.ofx is n p(x)=P(x)⋅δ(x−x) ∑j j j=1
2
P(x1) P(x2)
P(x3)
P(x4)
P(xn)
…… x1x2x3x4xn Example: Throw a dice: {1,2,3,4,5,6} 1 1 1 1 1 1 p(x)=δ(x−1)+δ(x−2)+δ(x−3)+δ(x−4)+δ(x−5)+δ(x−6) 6 6 6 6 6 6 2. Probability Distribution Function (PDF) Continuous Variable: The distribution function of random variablexx 1 ( ) (x x) W x1=p(x)dx=P≤1∫ −∞ Thep.d.f.p(xnot a probability but a rate of change of the probability) is dW(x) dx W(x) : Gaussian / Normal 2 ⎛( )⎞ 1x−µ p(x)=exp⎜−⎟ 2 2π σ2σ ⎝ ⎠ probability density function and probability distribution funtion
3
Discrete Variable: W(x)=p(x)=P(x≤x)∑ 1 1 x≤x 1
Probability distribution for discrete random variable Jumps in the distribution function correspond to impulses in the density function. W(x) monotonically nondecreasing inx. 3. Expected Value & Moment The statistical average (or mean, centroid, center of gravity, first moment about the origin, expected value) is defined as: ∞ x=xp(x)dx=E[x] ∫− ∞ Ifg(x) is an arbitrary function ofx, the expected value ofg(x) is ∞ E[g(x)]=g(x)⋅p(x)dx. ∫−∞
4
Moment th zabout the origin is defined as:n moment ∞ n n E[x]=x p(x)dx ∫−∞ µ th th zn moment about the mean (n central moment) is defined as: ∞ n n E[(x−µ)]=(x−µ)p(x)dx ∫−∞ st zabout the origin is the expected value of the R.V.1 moment Mean Value of R.V. nd zabout the origin is the average power of the R.V.2 moment ∞ − 2 2 2 E[x]=x p(x)dx=x ∫−∞ Mean Square Value of R.V. nd zabout the mean is the variance of the R.V.2 moment 2 2 2 2 2 2 σ=E[(x−µ)]=E[x]−(E[x])=x−x It measures the “spread” or “dispersion” of the R.V. Uniform ⎧1b forx∈[a,a+b] p(x)= ⎨ 0 otherwise ⎩ p(x)
x −2σ2 x − Note that in Matlab, the error function is defined differently: k 2−x 2 erf(k)=e dx ∫Matlab π 0 You can also check outerfc(k), the complement of error function, or1-erf(k);
7
5.Error Rate in PCM 1 =Avolt signal 0 = 0volt t Zero mean noisew Gaussianp.d.f. 2t Varianceσ p(w))( ) ( ) ( ) ( ) P e=P0⋅P e0+P1⋅P e1 1 P(1)=P(0)= p(e/0) p(e/1) 2 ⎛A⎞ P(e0)=P⎜w> ⎟ ⎝2⎠ A/2A/2 ⎛A⎞ P(e)P(e1)=P⎜w≤ − ⎟ ⎝2⎠ 1 P(e)=[P(e0)+P(e1)] 2 2 10 1⎡A⎤ =1−erf⎢ ⎥ 4 2⎣2σ⎦ 10 6 10 8 10 10 10 A [dB] 10 14 18 22σ 20 log107.4 = 17.3dB 21dB = 20 log1011.2 For transmission rate = 20 k bit/sec 104→ 1 error in every 0.5 sec 108→ 1 error in every 1 hr 23 minutes on average
8
How to determine the pdf of a random variable?
∆t 1
∆t 2
∆t 3
T
p(x)
∆t 4
∆x=x−x 2 1
t
x
∆x (1) choose a value for∆x (resolution improves as∆x↓) (2) choose a valueTimproves as (accuracy T↑) x 2 p(x)dx=P(x≤x≤x) ∫ 1 2 x1 P(x)(x−x)≅P(x≤x≤x),x∈[x,x] 2 1 1 2 1 2 p(x)x≅x will be approximately constant over that interval, for1 2 (3)P(x≤x≤x)1 2 p(x)≅,x∈[x,x] 1 2 x−x 2 1 j ∆t ∑i 1i=1 p(x)≅ • ∆x T 9