1 1 Digital vs. Analog Transmission Nyquist and Shannon Laws Required reading: Garcia 3.1 to 3.5 CSE 3213, Fall 2010 Instructor: N. Vlajic
2 Transmission Impairments 2 Transmission / Signal Impairments caused by imperfections of transmission media for analog signals, impairments can degrade signal quality Sent Received for digital signals, impairments can cause bit errors Sent Received main types of transmission impairments:
3 Transmission Impairments: Attenuation 3 Attenuation reduction / loss in signal power when a signal travels through a medium it loses some of its energy by overcoming the resistance of medium main challenges in combating attenuation: Less of a problem for digital signal!!! (1) received signal must have sufficient strength so that receiver can detect signal, but should not be too strong to overload transmitter/receiver circuitry (2) signal must maintain a level sufficiently higher than noise at all times, to be received without error to compensate for loss, analog amplifiers / digital repeaters are used to boost the signal at regular intervals
4 Transmission Impairments: Attenuation (cont.) 4 Attenuation (cont.) def. loss in signal power as it is transferred across a system (medium) P in > P out determined for each individual frequency apply sinwave of freq. f and power P in to channel input and observe signal power P out at output Attenuation(f) = L(f) = 10 log 10 P P in out (f) (f) [db] 1 Amplitude Response A(f)= A out (f) A in (f) aka magnitude of frequency response P (f) A (f) 2 in in L(f) = = = 2 Pout(f) A out(f) 1 A(f) 2 Atten.(f) = L(f) = 20 log10 1 A(f) [db] See Garcia pp f channel s amplitude response function A(f)
5 Which frequencies are better passed through the medium? 5
6 Transmission Impairments: Attenuation (cont.) 6 Why decibel (log function)? 1. Signal strength often falls off exponentially, so loss is easily expressed in terms of decibels linear function in log-plot. 2. The net gain or loss in a cascaded transmission path can be calculated with simple addition and subtraction. In figure below, a signal travels a long distance from point 1 to point 4. The signal is attenuated by the time it reaches point 2. Between points 2 and 3, the signal is amplified. Again, between points 3 and 4, the signal is attenuated. We can find the resultant attenuation just by adding the decibel measurements between each set of points. -1 db 3dB -7dB 3 db P in P out In this case, the attenuation can be calculated as: = -1, which means that the signal has gained power.
7 Transmission Impairments: Attenuation (cont.) 7 Example [ attenuation ] Consider a series of transmission elements as shown in the figure below. The input signal has the power of P 1 = 4 mw. The 1 st element is a transmission line with a loss of 5 (x), the 2 nd element is an amplifier with a gain of 7 (x), nd the 3 rd element is a transmission line with a loss of 3 (x). Calculate the output power P 4. loss = 5 gain = 7 loss = 3 P 1 = 4 mw P 4 =??? P P P P P P P P = = = P 4 = [mw] = 1.88 [mw]
8 Transmission Impairments: Attenuation (cont.) 8 G 1 G 2 G 3 P 1 = 4 mw P 4 =??? P4 P4 P3 P = = G1 G2 G3 = P P P P L L L P4 10 log [db] = 10 log(g1 G2 G3 ) = 10 log(g 1) + 10 log(g2) + 10 log(g3 ) P 1 P4 10 log [db] = G 1[dB] + G2[dB] + G3[dB] P 1
9 Transmission Impairments: Attenuation (cont.) 9 Example [ attenuation ] Consider a series of transmission elements as shown in the figure below. The input signal has the power of P 1 = 4 mw. The 1 st element is a Transmission line with a 12 db loss, the 2 nd element is an amplifier with a 35 db gain, and the 3 rd element is a transmission line with a 10 db loss. Calculate the output power P db 12 db -35 db 10 db P 1 = 4 mw P 4 =??? P 10 log P in out = 13 [db] G [db] L [db] Pin 1.3 Pout = = Pin 10 = = 79.8 [mw]
10 Transmission Impairments: Delay Distortion 10 Delay Distortion change in signal s form / shape each signal component has its own propagation speed through a medium, and therefore, its own delay in arriving at the final destination critical for composite-analog & digital signals some of the signal components of one bit position will spill over into other bit, causing intersymbol interference major limitation to achieving high bit rates in bandlimited channels, velocity tends to be highest near the center frequency and fall off towards the edges of the band
11 Transmission Impairments: Noise 11 Noise unwanted signals that get inserted / generated somewhere between transmitter and receiver major limiting factor in communications system performance cannot be predicted appears at random! presence of noise limits the reliability with which the receiver can correctly determine the information that was transmitted main categories of noise: (1) thermal noise (2) intermodulation noise (3) crosstalk (4) impulse noise
12 Transmission Impairments: Noise (cont.) 12 (1) Thermal Noise result of random motion of electrons appears in all electronic devices and transmission media cannot be eliminated function of temperature uniformly distributed across frequency spectrum aka white noise noise power density (N o ) = amount of thermal noise to be found in a bandwidth of 1Hz N o = k T [W/Hz] where k = Boltzmann s constant = *10-23 [J/K] T = temperature [K] thermal noise (N) in [W], in a bandwidth of B [Hz] N = k T B [W] Example Calculate N on 20C and 1GHz: N = k*(273+20)*10 9 = 3.8*10-12.
13 Transmission Impairments: Noise (cont.) 13 (2) Intermodulation Noise signals that are sum / difference of original frequencies sharing a medium result of nonlinearity in transmission medium output signal is a complex function of the input V o (t) V o (t) linear channel V i (t) non-linear channel V i (t) (3) Crosstalk effect of one wire on the other one wire acts as a sending antenna and the other as the receiving antenna can be reduced by careful shielding and using twisted pairs of the same magnitude, or less, than thermal noise (4) Impulse Noise non-continuous, consisting of irregular pulses or noise spikes of short duration and of relatively high amplitude induced by external electromagnetic disturbances, such as lightening, faults and flaws in communication system
14 Transmission Impairments: Noise (cont.) 14 Signal to Noise Ratio (SNR) ratio of the power in the desired signal to the power in the superimposed noise average SNR = average signal noise power power SNR (db) = 10 log 10 SNR high SNR high-quality signal & low number of required amplifiers / repeaters
15 Analog Transmission 15 Analog Long-Distance Communications Goals: 1) restore amplitude 2) remove delay distortion 3) remove noise each repeater attempts to restore analog signal to its original form restoration (noise removal) is imperfect noise gets amplified too! if signal only had components in certain freq. band, repeater could remove noise components outside signal band but, not those inside signal quality decreases with # of repeaters communications is distance-limited analogy: copy a song using cassette recorder Attenuated and distorted signal + noise Recovered signal + residual noise Amp Equalizer Repeater
17 Digital Transmission 17 Digital Long-Distance Communications regenerator does not need to completely recover the original shape of the transmitted signal it only needs to determine whether the original pulse was positive or negative original signal can be completely recovered each time communication over very long distance is possible analogy: copy an MP3 file compensate for distortion introduced by the channel Amplifier equalizer Decision circuit and signal regenerator sample signal at midpoint of each pulse to determine its polarity keep track of intervals that define each pulse Timing recovery
18 Digital Transmission (cont.) 18 Example [ transmission impairments in digital transmission ] Digital transmission can easily recover from various types of channel impairments So, is digital transmission the ultimate winner?!
19 Analog vs. Digital Transmission 19 Low-pass Channel bandwidth = [0, f 1 ) entire medium/bandwidth dedicated to 2 devices devices alternate in transmission Band-pass Channel bandwidth = [f 1, f 2 ) medium is shared among multiple users each pair of users gets a portion of overall bandwidth
20 Analog vs. Digital Transmission (cont.) 20 Digital Transmission Advantages Digital Transmission Disadvantages signal can be transmitted over long-distance without loosing any quality can operate with lower signal levels lower system cost easier to apply encryption easier integration of voice, video and data digital signal theoretically needs a bandwidth [0, ) upper limit can be relaxed if we decide to work with a limited number of harmonics digital transmission needs a low-pass channel analog transmission can use a band-pass channel Both analog and digital data may be transmitted on suitable transmission media using either digital coding or analog modulation.
21 Analog vs. Digital Transmission (cont.) 21 digital or analog data low-pass channel (digital signal) digital or analog data digital or analog data band-pass channel (analog signal) digital or analog data
22 Analog vs. Digital Transmission (cont.) 22 Example [ digital transmission of digital and analog data ] Digital Data Digital Signal: Line Coding Analog Data Digital Signal: PCM (Pulse Code Modul.) or Delta Modulation
23 Analog vs. Digital Transmission (cont.) 23 Example [ analog transmission of digital and analog data ] Digital data Analog Signal: Digital Modulation Analog data Analog Signal: Analog Modulation
24 Last Note about Signals 24 Throughput measurement of how fast data can pass through an entity in the network (computer, router, channel, etc.) if we consider this entity as a wall through which bits pass, throughput is the number of bits that can pass this wall in one second e.g. R=56 kbps Example [ throughput ] If the throughput at the connection between a device and the transmission medium is 56 kbps, how long does it take to send 100,000 bits out of this device? N [ bits] [bit] t = = = 1,786 [sec] R[ bps] [bps]
25 Last Note about Signals (cont.) 25 Propagation Time measures the time required for a signal (or a bit) to travel from one point of transmission medium to another p = d c [sec] d length of physical link [m] c signal propagation speed in medium 2*10 8 [m/s] Example [ propagation time ] The light of the Sun takes approximately 8 minutes to reach the Earth? What is the distance between the Sun and the Earth? m 8 m 9 6 d = p [sec] c [ ] = 8 * 60 [sec] 3 10 [ ] = [m] = [km] sec sec
26 Last Note about Signals (cont.) 26 Overall Delay L [bits] number of bits in message R [bps] speed of digital transmission system d [m] distance in meters c [m/s] speed of light (3x10 8 m/s in vacuum) Time to deliver a block of L bits: Delay = t propagation + t transmission = d/c + L/R seconds Use data compression to reduce L. Use higher speed modem/cable to increase R. Place server closer to reduce d. How can the time to download a file be minimized???
27 Data Rate Limits in Digital Transmission 27 Max Data Rate [bps] Over a Channel? depends on three factors: bandwidth available # of levels in digital signal quality of channel level of noise Nyquist Theorem defines theoretical max bit rate in noiseless channel  even perfect (noiseless) channels have limited capacity Shannon Theorem Shannon Theorem Nyquist Theorem extended  defines theoretical max bit rate in noisy channel if random noise is present, situation deteriorates rapidly! T
28 Data Rate Limits: Nyquist Theorem 28 Intersymbol Interference the inevitable filtering effect of any practical channel will cause spreading of individual data symbols that pass through the channel this spreading causes part of symbol energy to overlap with neighbouring symbols causing intersymbol interference (ISI) ISI can significantly degrade the ability of the data detector to differentiate a current symbol from the diffused energy of adjacent symbols narrow pulse impulse response: delayed pulse with ringing Bandwidth: B[Hz] T s = 1/2B As the channel bandwidth B increases, the width of the impulse response decreases pulses can be input in the system more closely spaced, i.e. at a higher rate.
29 Data Rate Limits: Nyquist Theorem 29 Impulse Response response of a low-pass channel (of bandwidth B) to a narrow pulse h(t), aka Nyquist pulse: zeros: where sin(2πbt)= t -7 T -6 T -5 T -4 T -3 T -2 T T T 1 T 2 T 3 T 4 T 5 T 6 T T S = 2B 2 2B s(t) = 3 2B sin(2πbt) 2πBt t 1 = 2B What is the minimum pulse/bit duration time to avoid significant ISI?!
30 Data Rate Limits: Nyquist Theorem 30 Example [ system response to binary input 110 ] T S T S T S -1-1 three separate pulses -2 combined signal Assume: channel bandwidth = max analog frequency passed = B [Hz]. New pulse is sent every T S sec data rate = 1/T S [bps] = 2B [bps] The combined signal has the correct values at t = 0, 1, 2. r max = 1 T S pulse second = 2W = 2B pulses second Maximum signaling rate that is achievable through an ideal low-pass channel.
31 Data Rate Limits: Nyquist Theorem 31 Nyquist Law max rate at which digital data can be transmitted over a comm. channel of bandwidth B [Hz] is Cnoiseless = 2 B log2m [bps] M number of discrete levels in digital signal M C, however this places increased burden on receiver instead of distinguishing one of two possible signals, now it must distinguish between M possible signals especially complex in the presence of noise max amplitude min amplitude Four signal levels Typical noise Eight signal levels if spacing between levels becomes too small, noise signal can cause receiver to make wrong decision
32 Data Rate Limits: Nyquist Theorem 32 Example [ multilevel digital transmission ] 2-level encoding: C=2B [bps] one pulse one bit 4-level encoding: C=2*2=4B [bps] one pulse two bits level encoding: C=2*3=6B [bps] one pulse three bits
33 Data Rate Limits: Shannon Theorem 33 Shannon Law max transmission rate over a channel with bandwidth B, with Gaussian distributed noise, and with signal-tonoise ratio SNR=S/N, is C 2 noisy = B log (1+ SNR) [bps] theoretical limit there are numerous impairments in every real channel besides those taken into account in Shannon's Law (e.g. attenuation, delay distortion, or impulse noise) no indication of levels no matter how many levels we use, we cannot achieve a data rate higher than the capacity of the channel in practice we need to use both methods (Nyquist & Shannon) to find what data rate and signal levels are appropriate for each particular channel: The Shannon capacity gives us the upper limit! The Nyquist formula tells us how many levels we need!
34 Data Rate Limits 34 Example [ data rate over telephone line ] What is the theoretical highest bit rate of a regular telephone line? A telephone line normally has a bandwidth of 3000 Hz (300 Hz to 3300 Hz). The signal-to-noise ratio is usually 35 db (3162) on up-link channel (user-to-network). Solution: We can calculate the theoretical highest bit rate of a regular telephone line as: C = B log 2 (1 + SNR) = = 3000 log 2 ( ) = = 3000 log 2 (3163) C = = 34,860 bps
35 Data Rate Limits 35 Example [ data rate / number of levels ] We have a channel with a 1 MHz bandwidth. The SNR for this channel is 63; what is the appropriate bit rate and number of signal level? Solution: First use Shannon formula to find the upper limit on the channel s data-rate C = B log 2 (1 + SNR) = 10 6 log 2 (1 + 63) = 10 6 log 2 (64) = 6 Mbps Although the Shannon formula gives us 6 Mbps, this is the upper limit. For better performance choose something lower, e.g. 4 Mbps. Then use the Nyquist formula to find the number of signal levels. C = 2 B log2m [bps] 4 Mbps = 2 1 MHz log 2 L L = 4