Line Codes RZ AND NRZ
Line Codes RZ AND NRZ
Features:
• Ease of generation as it uses single power supply.
• More bandwidth requirement.
• It has a nonzero dc component leading to dc wandering.
• Along string of 0’s will lack pulse transitions and could lead to loss of synchronization.
• There is no error detection capability and, hence, performance monitoring is not possible.
Non Return to
Zero(NRZ)
Return to Zero
POLAR
(RZ)
BIPHASE
Polar RZ
It is the most common and easy way to transmit binary data where a positive voltage level represents one bit and an equal
magnitude negative voltage level represents the other. Means In Polar RZ ‘1’ is represented as positive voltage polarity and
‘0’ is represented by negative voltage polarity.
Polar NRZ
In polar NRZ ‘1’ is represented by positive polarity and ‘0’ is represented by negative polarity. These polarities
are maintained over the complete pulse duration.
• As the polar NRZ signal has more r.m.s value than their unipolar counterparts, they can carry more energy.
• This will aid in better signal to noise ratio at the receiving end.
• The drawback of polar NRZ, however, is that it lacks error detection capability when the transmitted signal has a long
sequence of 0’s or 1’s.
• This problem is overcome in polar RZ signals, as the signal drops to zero in the middle of each bit interval.
• The Polar NRZ code is used to transmit signals on a computer motherboard. It is also used Fiber-based Gigabit Ethernet.
There are two types of NRZ polar encoding schemes namely
Non-Return-to-Zero-Level (NRZ-L) and
Non-Return-to-Zero, Invert (NRZ-I).
Features:
• The average dc component is zero.
• Has more r.m.s value than unipolar NRZ, so can carry more energy.
• Better signal to noise ratio at the receiving end.
• Lacks error detection capability.
Bipolar NRZ (Alternate Mark Inversion (AMI))
In this format the successive ‘1’s are represented by pulses with alternate polarity and ‘0’s are represented by no pulses.
Each binary 1 is represented by a positive half–bit period pulse followed by a negative half–bit period pulse. Similarly,
a binary 0 is represented by a negative half–bit period pulse followed by a positive half–bit period pulse. This type of
signaling is also called split–phase encoding.
• NRZ-L: Used in Digital Logic Circuits
• NRZ-M: Used in magnetic tape recording
• Unipolar RZ, bipolar RZ, : used in baseband
data transmission and magnetic tape recording
• RZ-AMI: used in telephone system
• Phase coding schemes are used in magnetic tape recording and
optical communication and in some satellite telemetry links
Line Codes in PCM
• The output of an ADC can be transmitted over a baseband channel.
• The digital information must first be converted into a physical signal.
• The physical signal is called a line code. Line coders use the terminology mark to
mean binary one and space to mean binary zero.
Analog
Input
Signal
Sample
X
Quantize ADC
XQ
Encode
Xk
Line
Code
x(t) PCM signal
Line codes
1 1 0 1 0 0 1 BINARY DATA
(a) Punched Tape Mark Mark space Mark space space Mark
(hole) (hole) (hole) (hole)
Volts
A
0
(b) Unipolar NRZ
Tb Time
0
(d) Unipolar RZ
A
(e) Bipolar RZ 0
-A
A
(f) Manchester NRZ 0
-A
• Self-synchronization.
• The ability to recover timing from the signal itself.
• Long series of ones and zeros could cause a problem.
t
p(t ) = NRZ pulse shape
• Where Tb is the bit period.
Tb
+ A when X k = 1
ak =
0 when X k = 0
t
p(t ) = RZ pulse shape
Tb / 2
Long strings of 1’s no longer a problem.
Pulse of half the duration of NRZ
However strings of 0’s still problem.
requires twice the bandwidth!
1 0 1 1 0 1
A
Polar NRZ
Now we can handle
long strings of 0’s, too.
A
Polar RZ
−A
Manchester Line Codes
• Manchester line codes use the antipodal mapping
and the following split-phase pulse shape:
p(t )
t + Tb / 4 t − Tb / 4
p(t ) = −
b T / 2 b T / 2
1 0 1 1 0 1
0 when X k = 0
ak = − A when X k = 1 and last mark → + A
+ A when X k = 1 and last mark → − A
• Also called pseudoternary signalling and alternate mark
inversion (AMI).
• Either RZ or NRZ pulse shape can be used.
1 0 1 1 0 1
A
Bipolar (RZ)
−A
Comparison of Line Codes
• Self-synchronization:
• Manchester codes have built in timing information because
they always have a zero crossing in the center of the pulse.
• Polar RZ codes tend to be good because the signal level
always goes to zero for the second half of the pulse.
• NRZ signals are not good for self-synchronization.
• Error probability:
• Polar codes perform better (are more energy efficient) than
Unipolar or Bipolar codes.
• Channel characteristics:
• We need to find the PSD of the line codes to answer this ...
Power Spectra for Binary Line Codes
➢ PSD can be calculated using the autocorrelation function:
t
➢ A digital signal is represented by s (t ) = an f (t = nTs ) ; f (t ) = for unipolar NRZ
n =− Ts
an and an + k are levels of the data pulses at the n ' th and (n + k )'th symbol positions
Pi Probability of having the ith an an + k product
PSD for Polar NRZ Signaling
Possible levels for the a’s : +A and -A
I
R(k ) = (an an + k )i Pi an and an + k are the level of the pulses at the nth and (n + k )th symbols
i =1
2
1 2 1
R(0) = (an an )i Pi = A + (− A) = A2
2
i =1 2 2
4
For k 0, R(k ) = (an an + k ) Pi = A21/ 4 + (− A)( A)1/ 4 + ( A)(− A)1/ 4 + (− A) 21/ 4 = 0
i =1
A2 , k = 0
R polar (k ) =
0, k 0
F( f )
2
sin fTb
2 kfTs
f (t ) = (t / Tb ) F ( f ) = Tb
fTb
Ps ( f ) =
Ts
k =−
R (k ) e
2
sin fTb
PPolar NRZ ( f ) = A Tb
2
fTb
PSD for line codes
Unipolar NRZ
2
A2Tb sin fTb 1
PUni. NRZ ( f ) = 1 + ( f )
4 fTb Tb
Polar NRZ
2
sin fTb
PPolar NRZ ( f ) = A Tb
2
fTb
Bipolar RZ 2
A Tb sin fTb
2
PBipolar RZ ( f ) = sin ( fTb )
2
4 fTb
Manchester
NRZ
2
sin fTb / 2
PManch. NRZ ( f ) = A2Tb sin ( fTb / 2 )
2
fTb / 2
➢ Intersymbol Interference
➢ ISI on Eye Patterns
➢ Combatting ISI
➢ Nyquist’s First Method for zero ISI
➢ Raised Cosine-Rolloff Pulse Shape
➢ Nyquist Filter
Intersymbol Interference
• Intersymbol interference (ISI) occurs when a pulse spreads out in such a way that it
interferes with adjacent pulses at the sample instant.
• Example: assume polar NRZ line code. The channel outputs are shown as spreaded
(width Tb becomes 2Tb) pulses shown (Spreading due to bandlimited channel
characteristics).
Channel Input Channel Output
Pulse width Tb Pulse width Tb
Data 1
− Tb 0 Tb − Tb 0 Tb
Data 0
− Tb 0 Tb − Tb 0 Tb
Intersymbol Interference
• For the input data stream:
1 0 1 1 0 1
A
0 Tb 2Tb 3Tb 4Tb 5Tb
Distortion
Amplitude
Noise
Margin
Tb Extension
Beyond Tb is
ISI
Time (Tb)
Intersymbol Interference
➢ If the rectangular multilevel pulses are filtered improperly as they pass through a
communications system, they will spread in time, and the pulse for each symbol may be
smeared into adjacent time slots and cause Intersymbol Interference.
➢ How can we restrict BW and at the same time not introduce ISI? 3 Techniques.
Intersymbol Interference
➢ Flat-topped multilevel input signal having pulse shape h(t) and values ak:
w in ( t ) = an h ( t − nTs ) = an h(t ) * ( t − nTs ) = an ( t − nTs ) * h ( t )
n n
t 1
Where h ( t ) = Where D = pulses/s
s
T T s
wout ( t ) = an ( t − nTs ) * he ( t ) = an he ( t − nTs )
n n
h (t ) = h (t ) * h (t ) * h (t ) * h (t )
e T C R
➢ Equivalent transfer function:
t sin Ts f
H e ( f ) = H ( f ) H T ( f ) H C ( f ) H R ( f ) Where H ( f ) = F = Ts
s
T Ts f
➢ Receiving filter can be designed to produce a needed He(f) in terms of HT(f) and HC(f):
He ( f )
HR ( f ) =
H ( f ) HT ( f ) H C ( f )
wout ( t ) = an he ( t − nTs )
n
➢ He(f), chosen such to minimize ISI is called EQUALIZING FILTER)
Combating ISI
• Three strategies for eliminating ISI:
• Use a line code that is absolutely bandlimited.
• Would require Sinc pulse shape.
• Can’t actually do this (but can approximate).
➢ This type of pulse will allow signalling at a baud rate of D=1/Ts=2B (for Binary R=1/Ts=2B)
where B is the absolute bandwidth of the system.
He(f)
1/fs
f
-fs/2 0 fs/2
fs
Absolute bandwidth is: B = MINIMUM BANDWIDTH
2
Signalling Rate is: D=1 Ts = 2 B Pulses/sec
Nyquist’s First Method for Zero ISI
Nyquist’s First Method for Zero ISI
He(f)
he(t) 1/fs
f
Zero crossings at non-zero integer multiples of the bit period -fs/2 0 fs/2
• Since pulses are not possible to create due to:
• Infinite time duration.
• Sharp transition band in the frequency domain.
• The Sinc pulse shape can cause significant ISI in the presence of timing errors.
• If the received signal is not sampled at exactly the bit instant (Synchronization
Errors), then ISI will occur.
f Rb
Rolloff factor: r = Bandwidth: B= (1 + r )
f0 2
Raised Cosine-Rolloff Nyquist Filtering
➢ Now filtering requirements are relaxed because absolute bandwidth is
increased.
➢ Clock timing requirements are also relaxed.
➢ The r=0 case corresponds to the previous Minimum bandwidth case.
1 ( f − f )
H ( f ) = 1 + cos
1
e
2
2 f
B = fo + f
f R D
Rolloff factor: r = Bandwidth: B = (1 + r ) = (1 + r )
f0 2 2
Raised Cosine-Rolloff Nyquist Filtering
cos 2 f t
➢ Impulse response is given by: he (t ) = F H e ( f ) = 2 f0
−1 sin 2 f 0 t
1 − ( 4 f t )
2
2 f 0 t
r→B
r → ISI
Raised Cosine-Rolloff Nyquist Filtering
➢ Illustrating the received bit stream of Raised Cosine pulse shaped
transmission corresponding to the binary stream of 1 0 0 1 0 for 3 different
values of r=0, 0.5, 1.
1 0 0 1 0 1 0 0 1 0
Bandwidth for Raised Cosine Nyquist Filtering
• The bandwidth of a Raised-cosine (RC) rolloff pulse shape is a function of the bit
rate and the rolloff factor:
f
B = f o + f = f o 1 + = f o (1 + r )
fo
R
B = (1 + r )
2
D
B = (1 + r ) Multilevel Signalling
2 the expression:
• Or solving for bit rate yields
2B
R=
1+ r
• This is the maximum transmitted bit rate when a RC-rolloff pulse shape with
Rolloff factor r is transmitted over a baseband channel with bandwidth B.
Nyquist Filter
➢ Raised Cosine Filter is also called a NYQUIST FILTER.
➢ NYQUIST FILTERS refer to a general class of filters that satisfy the
NYQUIST’s First Criterion.
D = f s = 2 f0
Nyquist Filter Characteristics
f
+Y ( f ), f f0
H e ( f ) = 2 f0
0, f Elsewhere