Presentation on theme: "Ch. 5 Data Encoding. 5.1 Digital Data, Digital Signals 5.2 Digital Data, Analog Signals 5.3 Analog Data, Digital Signals 5.4 Analog Data, Analog Signals."— Presentation transcript:
Ch. 5 Data Encoding
5.1 Digital Data, Digital Signals 5.2 Digital Data, Analog Signals 5.3 Analog Data, Digital Signals 5.4 Analog Data, Analog Signals
Introduction to Ch. 5 Figure 5.1--Encoding and Modulation Techniques –Encoding onto a digital signal--x(t) Digital or analog source--g(t) –Modulation onto an analog signal--modulated signal s(t) Digital or analog source--modulating signal m(t) –Four Possible Combinations Data Source: Analog or Digital Signal Transmission: Analog or Digital
5.1 Digital Data, Digital Signals: Terminology A digital signal is a sequence of discrete, discontinuous voltage pulses. Each pulse is a signal element. Signal elements can be unipolar or bipolar.
5.1 Digital Data, Digital Signals: Terminology (p.2) The data rate is the number of bits per second being transmitted--R bps. The duration of a bit (or one bit time) is 1/R for binary signaling. The signaling rate or modulation rate (baud rate) is the number of signal elements per second. A mark refers to a logic 1 and a space refers to a logic 0.
5.1 Digital Data, Digital Signals--The Encoding Scheme The encoding scheme is the mapping from data bits to signal elements. Evaluation of encoding schemes. –Does the encoding effectively use the spectrum? –Does the encoding scheme support synchronization (clocking)? –Does the encoding permit errors to be detected more quickly? –Is the encoding scheme resistant to noise? –How costly and complex is the scheme?
5.1 Digital Signal Encoding Formats Nonreturn-to-Zero –NRZ-L (Level) –NRZI (Invert on Ones) Multilevel Binary –Bipolar-AMI (Alternate Mark Inversion) –Pseudoternary Biphase – Manchester –Differential Manchester
5.1 Tables and Figures Table 5.2--Definition of Digital Signal Encoding Formats Figure 5.2--Digital Signal Encoding Formats (waveforms) Figure 5.3--Spectral Density of Various Signal Encoding Schemes (illustrates bandwidths) Figure 5.4--Theoretical Bit Error Rate for Various Digital Encoding Schemes (noise immunity)
5.1 Nonreturn to Zero (NRZ) Two different voltage levels are used to represent a 0 and a 1. The voltage level remains constant throughout the bit interval. NRZ-L (Nonreturn to Zero--Low) –Binary 0-- high voltage. –Binary 1-- low voltage.
5.1 Nonreturn to Zero (NRZ) (p.2) NRZI (Nonreturn to zero--Invert on 1s) –Binary 0--no transition. –Binary 1--a transition (high-to-low or low-to- high) at the beginning of the bit interval. Differential encoding--the signal is decoded by comparing the polarity of adjacent signal elements (eg. NRZI).
5.1 Evaluating NRZ Signal Spectrum--Efficient use of bandwidth; but there is a DC component. Clocking--no special synchronization capability. Error Detection--no special error detection capability. Signal Interference and Noise Immunity--bit error rate performance is better than multilevel binary (at a given S/N ratio.) Cost and Complexity--simple and easy to engineer.
5.1 Evaluating NRZ (p.2) Summary – Commonly used for digital magnetic recording. –Other techniques are often better for transmission.
5.1 Multilevel Binary More than two signal levels Bipolar-AMI –Binary 0 -- no pulse. –Binary 1 -- positive or negative pulse, alternating for successive ones. Pseudoternary –Binary 0 --positive or negative pulse, alternating for successive 0's. –Binary 1 --no pulse.
5.1 Evaluating Multilevel Binary Signal Spectrum –No DC component. –Less bandwidth is required than for NRZ. Clocking –Some synchronization capability. –Bipolar-AMI is sensitive to strings of 0's and pseudoternary is sensitive to strings of 1's. Error Detection –Some errors can be detected when pulse alternation property is violated.
5.1 Evaluating Multilevel Binary (p.2) Signal Interference and Noise Immunity –Not as good as NRZ. Cost and Complexity –More complex than NRZ. Summary –Variations are used for long distance communications and ISDN.
5.1 Biphase Manchester (LAN Standards) –A transition occurs in the middle of each bit period. Binary 1--low-to-high transition. Binary 0--high-to-low transition. Differential Manchester –Beginning of the bit period is important. Binary 0 --transition at the beginning of a bit period. Binary 1-- no transition at the beginning of a bit period. –The mid-bit transition is only for clocking.
5.1 Evaluating Biphase Signal Spectrum –No DC component. –Large bandwidth requirement. Clocking –Self-clocking--always a transition in the middle of each bit. Error Detection –The absence of an expected transition can be used to detect errors.
5.1 Evaluating Biphase (p.2) Signal Interference and Noise Immunity –Same as NRZ and better than multilevel binary (for a given S/N ratio). Cost and Complexity--complex. Summary –Manchester is used for IEEE (Ethernet). –Differential Manchester is used in IEEE (token ring).
5.1 Modulation Rate vs. Data Rate Let R be the data rate or bit rate (bps) Let D be the rate at which signal elements are generated (signaling rate) in baud (signals/sec.). Let M be the number of signal elements. Let L be the number of bits per signal element--L = log 2 (M). Then: R = D (signals/sec) x L (bits/signal) Note: Some authors differ from Stallings.
5.1 Scrambling Techniques Problem: Long strings of 1s or Os could cause difficulty in clocking. Solution: Substitute signals with transitions for those with none. –Bipolar with 8-zeros substitution (B8ZS) Based on bipolar-AMI (North America.) 8 0's replaced by string with 2 code violations. –High -density bipolar --3 zeros (HDB3) Based on bipolar-AMI (Europe and Japan.) 4 0's replaced by string with 1 code violation.
5.2 Digital Data, Analog Signals --Modulation Techniques Amplitude-shift keying (ASK) (Fig. 5.7) –Binary 1: s 1 (t)= A cos(2 f c t) –Binary 0: s 0 (t)= 0 –Susceptible to additive noise. –Somewhat inefficient as related to bandwidth. – Used with optical fibers (low and high amplitudes, A 0 and A 1.)
5.2 Modulation Techniques (p.2) Binary Frequency-Shift Keying (BFSK) –Binary 1: A cos(2 f 1 t) –Binary 0: A cos(2 f 2 t) –Fig. 5.8 shows full duplex BFSK transmission on a voice grade line--Bell System 108 modems. Bandwidth is split at 1700 Hz. –One direction has frequencies at /- 100Hz. –The other has frequencies at 2125+/- 100 Hz. –BFSK is less susceptible to errors than ASK.
5.2 Modulation Techniques (p.3) Multiple FSK (MFSK) –There are M signal elements. –s i (t)= A cos(2 f i t), 1 i M (Eq. 5.4) –fc = the carrier frequency –fd = the difference frequency –M = number of signal elements –L = number bits encoded in a signal element –fi = fc + (2i-1 -M) fd
5.2 Modulation Techniques (p.4) MFSK (cont.) –Signal is held for a period of Ts= LT where T is the bit time. –Bandwidth required is 2Mfd=M/Ts –Minimum frequency spacing is 2fd. –See Fig. 5.9 for an example with M =4.
5.2 Modulation Techniques (p.5) Example 5.1 MFSK (M=8) –f c =250 kHz, f d =25kHz, M = 8 (L = 3) –f1 = 250 k Hz + (2x ) x 25kHz – = 250 k Hz + (-7) x 25 k Hz = 75 k Hz. –See page 144 for f2,..., f8. –Data rate of 2fd = 1/Ts = 50 k bps can be supported. –Bandwidth of Wd=2Mfd=400 k Hz.
5.2 Modulation Techniques (p.6) Two-Level Phase-Shift Keying (BPSK) –Binary 1: A cos(2 f c t)= (+1) A cos(2 f c t) –Binary 0: A cos(2 f c t + )= (-1) A cos(2 f c t) Alternative Representation for (BPSK) –Let d(t) be a signal that takes on the values of +1 and -1. –s d (t) = A d(t) cos(2 f c t) (Eq. 5.6)
5.2 Modulation Techniques (p.7) Differential PSK (DPSK) (Fig. 5.10) –Binary 0: send a signal burst same as the previous signal burst. –Binary 1: send a signal burst of opposite phase as the previous burst (change by degrees.) Multiple signaling is possible. –Ex.1QPSK--4 angles; 2 bits per signal. (Eq. 5.7) –Ex.2: Standard 9600 bps transmission. 16 signals with 4 bits per signal. 3 different amplitudes. 12 different angles (some angles have 2 amplitudes.)
5.2 Data Rate (R) vs. Signaling Rate (D) Recall: R = D x L = D x log 2 (M). –D = the signaling rate (or modulation rate) in bauds. –M = the number of signal elements. –L= the number of bits per signal element. Example : Standard 9600 bps Modem –D = 2400 signals/sec (baud). –M=16 signal elements. –L= log 2 (16)= 4 bits/signal element. –R= 2400 x 4= 9600 bps.
5.2 Performance of Digital Modulation Schemes Transmission bandwidth requirements. –ASK: B T = (1 + r) R (Eq. 5.8) R is the bit rate and "r" is related to the filtering technique used, and 0 < r < 1. –FSK: B T = 2 F + (1+r)R (Eq. 5.9) F = the offset of the modulated frequency from the carrier frequency. –MPSK: B T = (1 +r) R /[log 2 (M)] (Eq. 5.10) –MFSK: B T = (1+r)MR /[log 2 (M)] (Eq. 5.11) –Note: For digital signaling, B T =.5(1+r)D.
5.2 Performance of Digital Modulation Schemes (p.2) Table 5.5 shows R/B T (bandwidth efficiency.) –ASK: R/ B T =1 / (1 + r) –FSK: R/ B T =1 / [2 ) F/R + (1+r)] –PSK: R/ B T = 1/ (1 +r) –Multilevel PSK: R/ B T = [log 2 (M)] / (1+r) –NOTE: Multilevel signaling increases bandwidth efficiency above 1. –NOTE2: Table 5.5 notation: M=L; L=b (edition 6 notation--needs editing.)
5.2 BER Performance and Bandwidth Efficiency Figure 5.4--BER as a function of E b /N o. –PSK/QPSK performs 3dB better than ASK/FSK. –If we increase E b /N o then we decrease BER. –Recall that E b =ST b, T b = 1/R. –Then E b /N o = ST b / N o = S/(N o x R). Fig FSK and MPSK BER vs. E b /N o –So to improve the BER performance Increase signal strength (increase S/N). Decrease R, which actually increases E b.
5.2 BER Performance and Bandwidth Efficiency (p.2) Ex. 5.2 What is the bandwidth efficiency for FSK, ASK, PSK, and QPSK for a BER of on a channel with an S/N of 12 dB? –E b /N o = ST b /(N/B T ) = S/N x B T /R. –(E b /N o )dB = (S/N)dB + (B T /R) dB –(E b /N o )dB = (S/N)dB - (R/B T ) dB (pg.86) –From Fig. 5.4, we can find (E b /N o )dB. –Results: (see pages ). FSK, ASK: R/B T =.6 PSK: R/B T =1.2 ; QPSK: R/B T = 2.4
5.2 Quadrature Amplitude Modulation Used in asymmetric digital subscriber line (ADSL.) Combination of ASK and PSK (extension of QPSK). Sends two signals at same carrier frequency (one shifted by 90 degrees). Fig shows a diagram of the QAM Modulator.
5.3 Analog Data, Digital Signals Digitize--to convert an analog signal to a digital signal. –1.The digital data can be transmitted using NRZ-L. –2. The digital data can be transmitted using an alternative line code. –3. The digital data can be converted into an analog signal. Codec (coder-decoder)-- transforms analog data into digital form and back again.
5.3 Pulse Code Modulation PCM is based on the Sampling Theorem –If a signal is sampled at regular intervals of time and at a rate higher than twice the highest significant signal frequency, then the samples contain all the information of the original signal. The signal may be reconstructed from these samples by the use of a low-pass filter. PCM is obtained by quantizing Pulse Amplitude Modulation samples (Fig and Fig. 5.17)
5.3 Pulse Code Modulation (p.2) Quantization Noise (error) –The difference between the original signal and the reconstructed PCM signal; ie., the error produced by the PCM process. Linear Quantization –Equally spaced quantization levels. –(SNR) dB=20log 10 (2 n ) dB – = 6.02n dB, –n= the number of bits.
5.3 Pulse Code Modulation (p.3) Nonlinear Quantization –Produces the same results as companding (compression-expansion) does in analog transmission systems. –Improves the S/N for small amplitude signals. Figure 5.18 Effect of Nonlinear Coding
5.3 Pulse Code Modulation (p.4) Pulse Amplitude Modulation (PAM) –A process in which an analog source is sampled and the magnitude of each sample is transmitted as the amplitude of a pulse waveform. Pulse Code Modulation (PCM) –A process in which an analog signal is sampled, and the magnitude of each sample is quantized and converted by coding to a digital signal.
Differential PCM (Not in your text.) Differential PCM –The process in which an estimate of a signal is subtracted from the signal itself and the result (the difference) is digitized and transmitted. –At the receiver the estimate is regenerated from the differences and becomes the approximation of the original signal. –A type of wave follower encoding approach. –Reduces PCM bit rate by 1/2.
5.3 Pulse Code Modulation(p.5) Delta Modulation (DM)-- –A differential PCM coding technique in which the sign (+ or -) of the differences is coded and transmitted. –This results in 1-bit per sample, but in general the sampling rate is larger than for PCM. –Fig Delta Modulation Waveforms Small step size--slope overload. Large step size--granularity (quantization noise.)
5.3 Pulse Code Modulation (p.6) Performance –PCM --Voice Bandlimited to 4kHz. Sampled at 8kHz. Quantized to 7 or 8 bits (56 k bps or 64 k bps.) Bandwidth Requirement--at least 28 to 32 K Hz. –PCM--Video 10 bits/sample 92 M bps
5.3 Pulse Code Modulation(p.7) Performance (cont.) –Digital techniques are used for the transmission of analog data because: Repeaters are used (no additive noise.) TDM can be used (FDM has intermodulation noise.) Digital signals can be switched using digital switching techniques.
5.3 Pulse Code Modulation(p.8) Advanced Coding Techniques –Other coding techniques for analog sources continue to be developed. –Speech--down to 4Kbps. –Broadcast Video--15 Mbps. –Video Teleconference-- 64 k bps or less.
5.4 Analog Data, Analog Signals Modulation –The process of combining an input signal m(t) and a carrier signal at frequency fc to produce a signal s(t) whose bandwidth is usually centered on f c. Uses of Modulation –Effective transmission (antenna size requires higher transmission frequency.) –To combine signals onto a single communication channel (FDM).
5.4 Amplitude Modulation Mathematical Definition: –s(t) = [ 1 + na x(t)] cos ( f c t). –n a is the modulation index –m(t) = n a x(t) is the modulating signal.
5.4 Amplitude Modulation(p.2) Double sideband transmitted carrier (DSBTC) –Example 5.3 : Let x(t)=cos (2 f m t) Note: cos(a )cos(b) = 1/2[cos (a+b) + cos(a-b)] s(t) = [ 1 + n a cos (2 f m t) ] cos ( f c t). s(t) = cos 2 f c t + n a /2[cos2 (f c -f m )t + n a /2 cos2 (f c +f m )t] Figure 5.22 Amplitude Modulation Figure 5.23 Spectrum of an AM Signal
5.4 Angle Modulation FM and PM –s(t) = A c cos (2 f c t + (t) ) PM: (t) = n p m(t) FM: ' (t) = n f m(t) Bandwidth Comparison with AM –AM: B T = 2 B, where B is the bandwidth of m(t). –FM: B T = 2 F + 2B, where F is the peak deviation of the frequency (Carson's rule). –Figure 4.20 AM, FM, and PM