Matched Filter & PAM - The University of Texas at Austin

advertisement
EE445S Real-Time Digital Signal Processing Lab
Spring 2014
Matched Filtering and Digital
Pulse Amplitude Modulation (PAM)
Slides by Prof. Brian L. Evans and Dr. Serene Banerjee
Dept. of Electrical and Computer Engineering
The University of Texas at Austin
Lecture 14
Outline
• Transmitting one bit at a time
• Matched filtering
• PAM system
• Intersymbol interference
• Communication performance
Bit error probability for binary signals
Symbol error probability for M-ary (multilevel) signals
• Eye diagram
14 - 2
Transmitting One Bit
• Transmission on communication channels is analog
• One way to transmit digital information is called
2-level digital pulse amplitude modulation (PAM)
x0 (t )
receive
‘0’ bit
y0 (t )
‘0’ bit
input
Tb
t
x(t)
-A
x1 (t )
A
Tb
‘1’ bit
t
Additive Noise
Channel
output
y(t)
How does the
receiver decide
which bit was sent?
Tb
t
-A
receive
‘1’ bit
y1 (t )
A
Tb
t
14 - 3
Transmitting One Bit
• Two-level digital pulse amplitude modulation over
channel that has memory but does not add noise
x0 (t )
‘0’ bit
input
Tb
t
x(t)
-A
x1 (t )
A
Tb
‘1’ bit
t
output
LTI
Channel
Model channel as
LTI system with
impulse response
c(t)
y(t)
receive
‘0’ bit
Th
Th+Tb
y1 (t )
receive
‘1’ bit
t
-A Th
c (t )
A Th
1
Th
y0 (t )
t
Th
Th+Tb
Assume that Th < Tb
14 - 4
t
Transmitting Two Bits (Interference)
• Transmitting two bits (pulses) back-to-back
will cause overlap (interference) at the receiver
c (t )
x(t )
*
A
y (t )
=
1
Th+Tb
2Tb
Tb
t
Th
Tb
t
t
-A Th
‘1’ bit
‘0’ bit
Assume that Th < Tb
‘1’ bit
‘0’ bit
• Sample y(t) at Tb, 2 Tb, …, and
threshold with threshold of zero
• How do we prevent intersymbol
interference (ISI) at the receiver?
Intersymbol
interference
14 - 5
Preventing ISI at Receiver
• Option #1: wait Th seconds between pulses in
transmitter (called guard period or guard interval)
c (t )
x(t )
*
A
y (t )
=
1
Th+Tb
Tb
Th+Tb
t
Th
Th Tb
t
t
-A Th
‘1’ bit
‘0’ bit
Assume that Th < Tb
‘1’ bit
‘0’ bit
Disadvantages?
• Option #2: use channel equalizer in receiver
FIR filter designed via training sequences sent by transmitter
Design goal: cascade of channel memory and channel
equalizer should give all-pass frequency response
14 - 6
Digital 2-level PAM System
ak{-A,A} s(t)
bi
bits
PAM
Clock Tb
g(t)
pulse
shaper
x(t)
c(t)

h(t)
Decision
Sample at Maker
w(t) matched
AWGN
N(0, N0/2)
Transmitter
y(t) y(ti)
Channel
t=iTb
1
0
bits
Threshold l
filter Clock T
b
p 
N
lopt  0 ln  0 
4 ATb  p1 
Receiver
• Transmitted signal s(t )   ak g (t  k Tb )
k
• Requires synchronization of clocks
p0 is the
probability
bit ‘0’ sent
between transmitter and receiver
14 - 7
Matched Filter
• Detection of pulse in presence of additive noise
Receiver knows what pulse shape it is looking for
Channel memory ignored (assumed compensated by other
means, e.g. channel equalizer in receiver)
g(t)
Pulse
signal
x(t)
h(t)
y(T)
y(t)
t=T
Matched
filter
w(t)
Additive white Gaussian
noise (AWGN) with zero
mean and variance N0 /2
T is the
symbol
period
y(t )  g (t ) * h(t )  w(t ) * h(t )
 g0 (t )  n(t )
14 - 8
Matched Filter Derivation
• Design of matched filter
Maximize signal power i.e. power of g 0 (t )  g (t ) * h(t ) at t = T
Minimize noise i.e. power of n(t )  w(t ) * h(t )
• Combine design criteria
max  , where  is peak pulse SNR
T is the
symbol
period
| g 0 (T ) |2 instantane ous power


2
E{n (t )}
average power
g(t)
x(t)
h(t)
y(T)
y(t)
t=T
Pulse
signal
w(t)
Matched
filter
14 - 9
Power Spectra
• Deterministic signal x(t)
w/ Fourier transform X(f)
Power spectrum is square of
absolute value of magnitude
response (phase is ignored)
Px ( f )  X ( f )  X ( f ) X * ( f )
2
• Autocorrelation of x(t)
Rx (t )  x(t ) * x* (t )
Maximum value (when it
exists) is at Rx(0)
Rx(t) is even symmetric,
i.e. Rx(t) = Rx(-t)
x(t)
Multiplication in Fourier domain
is convolution in time domain
Conjugation in Fourier domain is
reversal & conjugation in time

X ( f ) X * ( f )  F x(t ) * x* (t )
1
0
Rx(t)
Ts
t
Ts

-Ts
Ts
t
14 - 10
Power Spectra
• Two-sided random signal n(t)
Pn ( f )  F  Rn (t ) 
Fourier transform may not exist, but power spectrum exists

*
Rn (t )  E n(t ) n (t  t )   n(t ) n* (t  t ) dt




Rn (t )  E n(t ) n* (t  t )   n(t ) n* (t  t ) dt  n(t ) * n* (t )

For zero-mean Gaussian random process n(t) with variance s2
Rn (t )  E n(t ) n* (t  t )   0 when t  0
2
*
2
P
(
f
)

s
Rn (t )  E  n(t ) n (t  t )   s  (t )
n
• Estimate noise power
spectrum in Matlab
N = 16384; % finite no. of samples
gaussianNoise = randn(N,1);
plot( abs(fft(gaussianNoise)) .^ 2 );
approximate
noise floor
14 - 11
Matched Filter Derivation
g(t)
Pulse
signal
x(t)
N0
2
t=T
w(t)
Matched filter

N0
E{ n (t ) }   S N ( f ) df 
2

AWGN

2
2
|
H
(
f
)
|
df

j 2
H
(
f
)
G
(
f
)
e

f t
df

j 2
H
(
f
)
G
(
f
)
e


Matched
filter
G0 ( f )  H ( f )G( f )

| g 0 (T ) |2  |
N0
| H ( f ) |2
2

• Signal g 0 (t )  g (t ) * h(t )

f
S N ( f )  SW ( f ) S H ( f ) 
• Noise n(t )  w(t ) * h(t )
g 0 (t ) 
y(T)
y(t)
h(t)
Noise power
spectrum SW(f)
fT
df |2
T is the
symbol
period
14 - 12
Matched Filter Derivation
• Find h(t) that maximizes pulse peak SNR 

|

 H ( f ) G( f ) e

N0
2
j 2 f T
df |2
a

2
|
H
(
f
)
|
df



b
• Schwartz’s inequality
For vectors:
T
a
b
T
*
| a b |  || a || || b ||  cos 
|| a || || b ||
2

For functions:
  ( x) 
1
-
*
2
( x) dx 

  ( x)
1
-

2
dx
  ( x)
2
2
dx
-
upper bound reached iff 1 ( x)  k 2 ( x) k  R
14 - 13
Matched Filter Derivation
Let 1 ( f )  H ( f ) and 2 ( f )  G * ( f ) e  j 2  f T


|  H ( f ) G ( f ) e j 2  f T df |2   | H ( f ) |2 df
-



| G ( f ) |2 df



|  H ( f ) G ( f ) e j 2  f T df |2
-
N0
2


| H ( f ) |2 df


2

N0



| G ( f ) |2 df
T is the
symbol
period
2
2
max 
|
G
(
f
)
|
df , which occurs when

N 0 
H opt ( f )  k G * ( f ) e  j 2  f T  k by Schwartz ' s inequality
Hence, hopt (t )  k g * (T  t )
14 - 14
Matched Filter
• Impulse response is hopt(t) = k g*(T - t)
Symbol period T, transmitter pulse shape g(t) and gain k
Scaled, conjugated, time-reversed, and shifted version of g(t)
Duration and shape determined by pulse shape g(t)
• Maximizes peak pulse SNR


2 Eb
2
2
2
2
max 
| G ( f ) | df 
| g (t ) | dt 
 SNR


N 0 
N 0 
N0
Does not depend on pulse shape g(t)
Proportional to signal energy (energy per bit) Eb
Inversely proportional to power spectral density of noise
14 - 15
Matched Filter for Rectangular Pulse
• Matched filter for causal rectangular pulse shape
Impulse response is causal rectangular pulse of same duration
• Convolve input with rectangular pulse of duration
T sec and sample result at T sec is same as
First, integrate for T sec
Sample and dump
Second, sample at symbol period T sec
Third, reset integration for next time period
• Integrate and dump circuit

h(t) = ___
t=nT
T
14 - 16
Digital 2-level PAM System
ak{-A,A} s(t)
bi
bits
PAM
Clock Tb
g(t)
pulse
shaper
x(t)
c(t)

h(t)
Decision
Sample at Maker
w(t) matched
AWGN
N(0, N0/2)
Transmitter
y(t) y(ti)
Channel
t=iTb
1
0
bits
Threshold l
filter Clock T
b
p 
N
lopt  0 ln  0 
4 ATb  p1 
Receiver
• Transmitted signal s(t )   ak g (t  k Tb )
k
• Requires synchronization of clocks
p0 is the
probability
bit ‘0’ sent
between transmitter and receiver
14 - 17
Digital 2-level PAM System
• Why is g(t) a pulse and not an impulse?
Otherwise, s(t) would require infinite bandwidth
s(t )   ak  (t  k Tb )
k
We limit its bandwidth by using a pulse shaping filter
• Neglecting noise, would like y(t) = g(t) * c(t) * h(t)
to be a pulse, i.e. y(t) =  p(t) , to eliminate ISI
y (t )    ak p(t  kTb )  n(t ) where n(t )  w(t ) * h(t )
k
 y (ti )   ai p(ti  iTb )    ak p(i  k )Tb   n(ti )
k ,k i
actual value
(note that ti = i Tb)
intersymbol
interference (ISI)
p(t) is
centered
at origin
noise
14 - 18
Eliminating ISI in PAM
• One choice for P(f) is a
rectangular pulse
W is the bandwidth of the
system
Inverse Fourier transform
of a rectangular pulse is
is a sinc function
p (t )  sinc (2  W t )
 1
 2 W ,W  f  W
P( f )  
 0
, | f | W

1
f
P( f ) 
rect (
)
2W
2W
• This is called the Ideal Nyquist Channel
• It is not realizable because pulse shape is not
causal and is infinite in duration
14 - 19
Eliminating ISI in PAM
• Another choice for P(f) is a raised cosine spectrum



 1
P( f )  
 4W



1
2W



1  sin   (| f | W )  
 2W  2 f  

1 


0
0  | f |  f1
f1  | f |  2W  f1
2W  f1  | f |  2W
• Roll-off factor gives bandwidth in excess
f1
  1
W
of bandwidth W for ideal Nyquist channel
 
• Raised cosine pulse p(t )  sinc  t  cos2 2 W2 t 2
 Ts  1  16  W t
has zero ISI when
Nyquist channel dampening adjusted by
sampled correctly idealimpulse
response rolloff factor 
• Let g(t) and h(t) be square root raised cosine pulses
14 - 20
Bit Error Probability for 2-PAM
• Tb is bit period (bit rate is fb = 1/Tb)
s(t)
r(t)
r(t)
rn
s(t )   ak g (t  k Tb )
k

h(t)
Sample at
Matched
filter
r (t )  s(t )  w(t )
t = nTb
r(t) = h(t) * r(t)
w(t)
w(t) is AWGN with zero mean and variance s2
• Lowpass filtering a Gaussian random process
produces another Gaussian random process
Mean scaled by H(0)
Variance scaled by twice lowpass filter’s bandwidth
• Matched filter’s bandwidth is ½ fb
14 - 21
Bit Error Probability for 2-PAM
• Noise power at matched filter output

v(nT )   h(t ) w(nT  t )dt
Filtered noise
T = Tsym

2
 


E v (nT )  E   h(t ) w(nT  t )dt 
 
 

2

Noise power
 
 E{   gT (t 1 ) w(nT  t 1 ) gT (t 2 ) w(nT  t 2 )dt 1dt 2 }
  
 

 g
T
(t 1 ) gT (t 2 ) E{w(nT  t 1 ) w(nT  t 2 )}dt 1dt 2
  
s2 (t1–t2)

1
 s  h (t )dt  s
2

2
2
2
sym / 2
H



sym / 2
2
( )d 
s2
T
14 - 22
Bit Error Probability for 2-PAM
• Symbol amplitudes of +A and -A
• Rectangular pulse shape with amplitude 1
• Bit duration (Tb) of 1 second
• Matched filtering with gain of one (see slide 14-15)
Integrate received signal over nth bit period and sample
n 1
Prn (rn )
rn   r (t ) dt
n
n 1
 A
 w(t ) dt
n
  A  vn
-
A
rn
0
A
Probability density function (PDF)
14 - 23
Bit Error Probability for 2-PAM
• Probability of error given that
Tb = 1
transmitted pulse has amplitude –A
 vn A 
P(error | s (nTb )   A)  P( A  vn  0)  P(vn  A)  P  
s s 
• Random variable
PDF for vn / s
vn
s is Gaussian with
zero mean and
variance of one
0

PDF for
N(0, 1)
A/s
1
 vn A 
P(error | s(nT )   A)  P    
e
 s s  A 2
v2

2
 A
dv  Q 
s 
s
Q function on next slide
14 - 24
Q Function
• Q function
1   y2 / 2
Q( x) 
dy
e
2 x
• Complementary error
function erfc
2  t 2
erfc ( x) 
 e dt

• Relationship
x
1
 x 
Q( x)  erfc

2
 2
Erfc[x] in Mathematica
erfc(x) in Matlab
14 - 25
Bit Error Probability for 2-PAM
• Probability of error given that
transmitted pulse has amplitude A
Tb = 1
P(error | s(nTb )  A)  Q( A / s )
• Assume that 0 and 1 are equally likely bits
P (error)  P ( A) P (error | s (nTb )  A)  P ( A) P (error | s (nTb )   A)
1  A 1  A
 A
 Q   Q   Q   Q 
2 σ 2 σ
σ

A2

2
where,   SNR  2
1
e
s
 
Q(  ) 
• Probability of error exponentially
2

decreases with SNR (see slide 8-16) for large positive 
14 - 26
PAM Symbol Error Probability
• Set symbol time (Tsym) to 1 second
• Average transmitted signal power
1
PSignal  E{an2 } 
2


| GT ( ) |2 d  E{an2 }

3d
d
d
-d
d
GT() square root raised cosine spectrum
• M-level PAM symbol amplitudes
M
M
i
 1, . . . , 0, . . . ,
2
2
li  d (2i  1),
• With each symbol equally likely
1
PSignal 
M
M
2
2
l

M M
i   1
2
i
M
2
d2
d (2i  1)   ( M  1)

3
i 1
2
3 d
2-PAM
4-PAM
Constellation points
with receiver
decision boundaries
2
2
14 - 27
PAM Symbol Error Probability
• Noise power and SNR
PNoise
1

2
sym / 2



sym / 2
N0
N0
d 
2
2
two-sided power spectral
density of AWGN
SNR 
PSignal
PNoise
2( M 2  1) d 2


3
N0
• Assume ideal channel,
i.e. one without ISI
rn  an  vn
channel noise after matched
filtering and sampling
• Consider M-2 inner
levels in constellation
Error only if | vn | d
where s 2  N 0 / 2
Probability of error is
d 
P(| vn | d )  2 Q 
s 
• Consider two outer
levels in constellation
d
P ( vn  d )  Q  
s 
14 - 28
PAM Symbol Error Probability
• Assuming that each symbol is equally likely,
symbol error probability for M-level PAM
Pe 
M 2
d
 2 Q
M 
s
M-2 interior points
2  d  2( M  1)  d 



Q  
Q 

M
 M  s 
s 
2 exterior points
• Symbol error probability in terms of SNR
1


2
PSignal
M 1   3
d2
 
2
Pe  2
Q  2
SNR   since SNR 

M
1
2
M
PNoise 3s
 
  M 1



14 - 29

Visualizing ISI
• Eye diagram is empirical measure of signal quality




g (nTsym  kTsym ) 

x(n)   ak g (n Tsym  k Tsym )  g (0)  an   ak

g (0)
k  
k  


k

n


• Intersymbol interference (ISI):
D  ( M  1) d

g (nTsym  kTsym )
k   , k  n
g (0)

 ( M  1) d

g (kTsym )
k   , k  n
g (0)

Raised cosine filter has zero
ISI when correctly sampled
14 - 30
Eye Diagram for 2-PAM
• Useful for PAM transmitter and receiver analysis
and troubleshooting
Sampling instant
M=2
Margin over noise
Distortion over
zero crossing
Slope indicates
sensitivity to
timing error
Interval over which it can be sampled
t - Tsym
t
t + Tsym
• The more open the eye, the better the reception
14 - 31
Eye Diagram for 4-PAM
3d
d
-d
-3d
Due to
startup
transients.
Fix is to
discard first
few symbols
equal to
number of
symbol
periods in
pulse shape.
14 - 32
Download