Concepts in
Signal Encoding Techniques
Monday, February 4, 2013
• Unipolar
— All signal elements have same sign 0, +1
• Bipolar
— One logic state represented by positive voltage the other by negative voltage -1, +1
• Data rate
— Rate of data transmission in bits per second
• Duration or length of a bit
— Time taken for transmitter to emit the bit
• Mark and Space
— Mark 1
— Space 0
B
The Nyquist Theorem & Noiseless Channels
•
Baud Rate : the frequency with which components change
• Each bit string is composed of n bits, and hence the signal component may have up to
2 n different amplitudes (one for each unique combination for b
1
, b
2
, …b n
)
•
Are bit rate and baud rate the Same?
•
No, bit rate depends on the number of bits ( n ) as well as the baud rate; more precisely:
Bit Rate = n * Baud Rate
•
Bit rate can then be increased by either increasing the baud rate or n ; however only up to a point
B
(continued...)
•
This result is surprisingly old, back to 1920s, when Harry Nyquist developed his classic theory
•
Nyquist theory showed that if f is the maximum frequency a medium can transmit, then the receiver can reconstruct the signal by sampling it
2f times per second
•
For example, if the maximum frequency is 4000 Hz, then the receiver can completely construct it by sampling it at a rate of 8000 per second
•
Assuming that the transmitter baud rate is 2 f
, in other words changes signal each
1 / 2f intervals, we can state
Bit Rate = n * Baud Rate = n * 2 * f
•
This can also be stated based on component; if
B is the number of different components, then
B =
2 n or n = log
2
(
B
)
•
Hence,
Bit Rate = 2 * f * log
2
( B )
B
(continued...)
Noisy Channels
1.
More components mean subtler change among them
2.
Channels are subject to noise
• The transmitted signal can be distorted due to the channel noise
•
If distortion is too large, the receiver may not be able to reconstruct the signal at all
B
(continued...)
Shannon’s Result
• How much noise is bad? This depends on its ratio to the signal
•
We define S/N ( Signal-to-Noise-Ratio )
• A higher S/N (less significant noise) indicates higher quality
•
Because S >> N, the ratio is often scaled down as
R = log
10
(S/N) bels // bels is the measurement unit
For example,
If S is 10 times larger than N, then
R = log
10
(10N/N) = 1 bel
If S is 100 times larger than N, then
R = log
10
(100N/N) = 2 bels
Perhaps, a more familiar measurement is the decibel (dB)
1 dB = 0.1 bel
B
(continued...)
Shannon’s Result
• In 1940, Claude Shannon went beyond Nyquist’s results and considered noisy channels
•
Shannon related the maximum bit rate not only to the frequency but also to the S / N ratio; specifically he showed that:
Bit Rate = Bandwidth * log
2
(1 + S / N ) bps
•
The formula states that a higher BW and S / N ratio allow higher bit rate
•
Hence, for the telephone system, which has a frequency of about 4000 Hz and S / N
≈ 35 dB, or
3.5 bels, Shannon’s result yields the following
3.5 = log
10
( S / N )
S = 10
3.5
N
S
≈ 3162
N
S / N
≈
3162
Bit Rate = Bandwidth * log
2
(1 + S / N )
= 4000 * log
2
(1 + 3162)
≈ 4000 * 11.63 bps
≈ 46,506 bps
≈ 46.5 kbps
• Nonreturn to Zero-Level (NRZ-L)
• Nonreturn to Zero Inverted (NRZI)
• Bipolar –AMI (
A lternate M ark I nversion
)
• Pseudoternary
• Manchester
• Differential Manchester
• B8ZS (
B ipolar With 8 Z ero S ubstitution
)
• HDB3 (
H igh D ensity B ipolar 3 Zeros
)
• Two different voltages for 0 and 1 bits
• Voltage constant during bit interval
— no transition I.e. no return to zero voltage
• e.g. Absence of voltage for zero, constant positive voltage for one
• More often, negative voltage for one value and positive for the other
• This is NRZ-L
• Nonreturn to zero inverted on ones
• Constant voltage pulse for duration of bit
• Data encoded as presence or absence of signal transition at beginning of bit time
• Transition (low to high or high to low) denotes a binary 1
• No transition denotes binary 0
• An example of differential encoding
• Data represented by changes rather than levels
• More reliable detection of transition rather than level
• In complex transmission layouts it is easy to lose sense of polarity
• Pros + ’s
— Easy to engineer
— Make good use of bandwidth
• Cons – ’s
— DC component
— Lack of synchronization capability
• Used for magnetic recording
(outdated)
• Not often used for signal transmission
• Use more than two levels
• Bipolar-AMI (
A lternate M ark I nversion
)
— zero represented by no line signal
— one represented by positive or negative pulse
— one pulses alternate in polarity
— No loss of sync if a long string of ones (zeros still a problem)
— No net DC component
— Lower bandwidth
— Easy error detection
• One represented by absence of line signal
• Zero represented by alternating positive and negative
• No advantage or disadvantage over bipolar-AMI
• Not as efficient as NRZ
— Each signal element only represents one bit (con)
— In a 3 level system could represent log
2
3 = 1.58 bits
— Receiver must distinguish between three levels
(+A, -A, 0) (con)
— Requires approximately 3dB more signal power for same probability of bit error (con)
• Manchester
— Transition in middle of each bit period
— Transition serves as clock and data
— Low to high represents one
— High to low represents zero
— Used by IEEE 802.3
• Differential Manchester
— Midbit transition is clocking only
— Transition at start of a bit period represents zero
— No transition at start of a bit period represents one
— Note: this is a differential encoding scheme
— Used by IEEE 802.5
• Cons
— At least one transition per bit time and possibly two
— Maximum modulation rate is twice NRZ
— Requires more bandwidth
• Pros
— Synchronization on mid bit transition (self clocking)
— No DC component
— Error detection
• Absence of expected transition
(a note)
gate to filling
• Use scrambling to replace sequences that would produce constant voltage
• Filling sequence
— Must produce enough transitions to sync
— Must be recognized by receiver and replace with original
— Same length as original
• No DC component
• No long sequences of zero level line signal
• No reduction in data rate
• Error detection capability
• B ipolar With 8 Z eros S ubstitution
• Based on bipolar-AMI
• If octet of all zeros and last voltage pulse preceding was positive encode as 000+-0-+
• If octet of all zeros and last voltage pulse preceding was negative encode as 000-+0+-
• Causes two violations of AMI code
• Unlikely to occur as a result of noise
• Receiver detects and interprets as octet of all zeros
• H igh D ensity B ipolar 3 Zeros
• Based on bipolar-AMI
• String of four zeros replaced with one or two pulses
• Public telephone system
— 300Hz to 3400Hz
— Use modem (modulator-demodulator)
• Amplitude shift keying (ASK)
• Frequency shift keying (FSK)
• Phase shift keying (PSK)
• Values represented by different amplitudes of carrier
• Usually, one amplitude is zero
— i.e. presence and absence of carrier is used
• Susceptible to sudden gain changes
• Inefficient
• Up to 1200bps on voice grade lines
• Used over optical fiber
• Most common form is binary FSK (BFSK)
• Two binary values represented by two different frequencies (near carrier)
• Less susceptible to error than ASK
• Up to 1200bps on voice grade lines
• High frequency radio
• Even higher frequency on LANs using co-ax
(for info)
• Phase of carrier signal is shifted to represent data
• Binary PSK
— Two phases represent two binary digits
• Differential PSK
— Phase shifted relative to previous transmission rather than some reference signal
• Is the next bit different than the current bit?
• More efficient use by each signal element representing more than one bit
— e.g. shifts of /2 (90 o )
— Each element represents two bits
— Can use 8 phase angles and have more than one amplitude
— 9600bps modem use 12 angles , four of which have two amplitudes
• Offset QPSK (orthogonal QPSK)
— Delay in Q stream
(recording your voice and storing in PC)
• If a signal is sampled at regular intervals at a rate higher than twice the highest signal frequency, the samples contain all the information of the original signal
• If f s
> 2 f c
OK
• Voice data limited to below 4000Hz
• Requires 8000 samples per second
• Analog samples (Pulse Amplitude Modulation, PAM)
• Each sample assigned digital value
• 4 bit system gives 16 levels (2 4 = 16)
• Quantized
— Quantizing error or noise
— Approximations mean it is impossible to recover original exactly
• 8 bit sample gives 256 levels (2 8 = 256)
• Quality comparable with analog transmission
• 8000 samples per second of 8 bits each gives
64kbps
• Analog input is approximated by a staircase function
• Move up or down one level ( ) at each sample interval
• Binary behavior
— Function moves up or down at each sample interval
• Good voice reproduction
— PCM - 128 levels (7 bit) (again 2 7 = 128)
— Voice bandwidth 4khz
— Should be 8000 x 7 = 56kbps for PCM