LECTURE 3 - SIGNALS

15
Department of EEE CS 65- Computer Networks Prepared by Dr.S.Muralidharan 1 1 TERMINOLOGY TERMINOLOGY Time domain concepts Time domain concepts Analog signal Analog signal Signal intensity varies in a smooth fashion Signal intensity varies in a smooth fashion over time (no breaks) over time (no breaks) Digital signal Digital signal Changes from one constant level to Changes from one constant level to another another Periodic signal Periodic signal Pattern repeated over time Pattern repeated over time Sine wave for analog signal Sine wave for analog signal Square wave for digital signal Square wave for digital signal 2 Analog & Digital Signals Analog & Digital Signals 3 Periodic Signals Periodic Signals 4

Transcript of LECTURE 3 - SIGNALS

Page 1: LECTURE 3 - SIGNALS

Department of EEE CS 65- Computer Networks

Prepared by Dr.S.Muralidharan 1

1

TERMINOLOGY TERMINOLOGY Time domain conceptsTime domain concepts

–– Analog signalAnalog signal•• Signal intensity varies in a smooth fashion Signal intensity varies in a smooth fashion

over time (no breaks)over time (no breaks)–– Digital signalDigital signal

•• Changes from one constant level to Changes from one constant level to anotheranother

–– Periodic signalPeriodic signal•• Pattern repeated over timePattern repeated over time•• Sine wave for analog signalSine wave for analog signal•• Square wave for digital signalSquare wave for digital signal

2

Analog & Digital SignalsAnalog & Digital Signals

3

Periodic SignalsPeriodic Signals

4

Page 2: LECTURE 3 - SIGNALS

Department of EEE CS 65- Computer Networks

Prepared by Dr.S.Muralidharan 2

•• Peak Amplitude (A)Peak Amplitude (A)–– maximum strength of signalmaximum strength of signal–– Measure in voltsMeasure in volts

•• Frequency (f)Frequency (f)–– Rate of change of signal (cycles per second)Rate of change of signal (cycles per second)–– Hertz (Hz) or cycles per secondHertz (Hz) or cycles per second–– Period = time for one repetition (T)Period = time for one repetition (T)

•• Phase (Phase (φφφφφφφφ))– Phase describes the position of the waveform relative

to time 0. 5

Two signals with the same phase and frequency, different amplitudes

6

Two signals with the same amplitude and phase, different frequencies

7

Three sine waves with the same amplitude and frequency, but different phases

8

Page 3: LECTURE 3 - SIGNALS

Department of EEE CS 65- Computer Networks

Prepared by Dr.S.Muralidharan 3

WavelengthWavelength•• Distance occupied by one cycleDistance occupied by one cycle

9

Frequency Domain ConceptsFrequency Domain Concepts•• Signal usually made up of many frequenciesSignal usually made up of many frequencies•• Components are sine wavesComponents are sine waves•• Can be shown (Fourier analysis) that any Can be shown (Fourier analysis) that any

signal is made up of component sine wavessignal is made up of component sine waves•• Can plot frequency domain functionsCan plot frequency domain functions

10

The time-domain and frequency-domain plots of a sine wave

11

The time domain and frequency domain of three sine waves

12

Page 4: LECTURE 3 - SIGNALS

Department of EEE CS 65- Computer Networks

Prepared by Dr.S.Muralidharan 4

Composite signals• A single-frequency sine wave is not useful in data

communications;• we need to send a composite signal, a signal made of

many simple sine waves.• According to Fourier analysis, any composite signal is

a combination of simple sine waves with different frequencies, amplitudes, and phases.

• If the composite signal is periodic, the decomposition gives a series of signals with discrete frequencies; if the composite signal is nonperiodic, the decomposition gives a combination of sine waves with continuous frequencies.

13

A composite periodic signal

14

Decomposition of a composite periodic signal in the time and frequency domains

15

Addition of Frequency

Components(T=1/f)

16

Page 5: LECTURE 3 - SIGNALS

Department of EEE CS 65- Computer Networks

Prepared by Dr.S.Muralidharan 5

Figure shows a nonperiodic composite signal. It can bethe signal created by a microphone or a telephone setwhen a word or two is pronounced. In this case, thecomposite signal cannot be periodic, because thatimplies that we are repeating the same word or wordswith exactly the same tone.

The time and frequency domains of a nonperiodic signal

17

Spectrum & BandwidthSpectrum & Bandwidth•• SpectrumSpectrum

–– range of frequencies contained in signalrange of frequencies contained in signal•• Any transmission system has a limited band of Any transmission system has a limited band of

frequencies. The absolute value of the difference frequencies. The absolute value of the difference between the lowest and highest frequencies of a signal between the lowest and highest frequencies of a signal is known as is known as BandwidthBandwidth–– Absolute bandwidthAbsolute bandwidth

•• width of spectrumwidth of spectrum–– Effective bandwidthEffective bandwidth

•• Often just Often just bandwidthbandwidth•• Narrow band of frequencies containing most of the energyNarrow band of frequencies containing most of the energy

–– For example, consider an average voice:For example, consider an average voice:–– Average voice has a frequency range of roughly 300 Hz to Average voice has a frequency range of roughly 300 Hz to

3100 Hz3100 Hz–– The spectrum would thus be 300 The spectrum would thus be 300 -- 3100 Hz3100 Hz–– The bandwidth would be 2800 HzThe bandwidth would be 2800 Hz

–– This limits the data rate that can be carriedThis limits the data rate that can be carried 18

• The bandwidth of a composite signal is the difference between the highest and the lowest frequencies contained in that signal

The bandwidth of periodic and nonperiodic composite signals

19

How to calculate ….?A periodic signal has a bandwidth of 20 Hz. The highest frequency is 60 Hz. What is the lowest frequency? Draw the spectrum if the signal contains all frequencies of the sameamplitude.Solution : Let “fh” be the highest frequency, “fl” the lowestfrequency, and “B” the bandwidth. Then the spectrumcontains all integer frequencies which has been shown as a series of spikes

20

Page 6: LECTURE 3 - SIGNALS

Department of EEE CS 65- Computer Networks

Prepared by Dr.S.Muralidharan 6

How to calculate…..? (contd)A nonperiodic composite signal has a bandwidth of 200kHz,with a middle frequency of 140 kHz and peak amplitude of 20 V. The two extreme frequencies have an amplitude of 0.Draw the frequency domain of the signal.Solution : The lowest frequency must be at 40 kHz andthe highest at 240 kHz. Figure below shows the frequencydomain and the bandwidth.

21

Data Rate (Or) Bit Rate Data Rate (Or) Bit Rate •• A very important consideration in data communications is A very important consideration in data communications is

how fast we can send data, in bits per second, over a how fast we can send data, in bits per second, over a channel. Data rate depends on three factors:channel. Data rate depends on three factors:–– The bandwidth availableThe bandwidth available–– The level of the signals we useThe level of the signals we use–– The quality of the channel (the level of noise)The quality of the channel (the level of noise)

22

• In networking, we use the term bandwidth in two contexts.– The first, bandwidth in hertz, refers to the range

of frequencies in a composite signal or the range of frequencies that a channel can pass.

– The second, bandwidth in bits per second, refers to the speed of bit transmission in a channel or link.

23

Example 1:Assume we need to download text documents at the rate of 100 pages per sec. What is the required bit rate of the channel?SolutionA page is an average of 24 lines with 80 characters in each line. If we assume that one character requires 8 bits, the bit rate is

24

Page 7: LECTURE 3 - SIGNALS

Department of EEE CS 65- Computer Networks

Prepared by Dr.S.Muralidharan 7

Example 2:A digitized voice channel is made by digitizing a 4-kHz bandwidth analog voice signal. We need to sample the signal at twice the highest frequency (two samples per hertz). We assume that each sample requires 8 bits. What is the required bit rate?

SolutionThe bit rate can be calculated as

25

Analog TransmissionAnalog Transmission–– Analog signal transmitted without regard to Analog signal transmitted without regard to

contentcontent•• Data may be analog or digital Data may be analog or digital

–– Attenuated over distance Attenuated over distance –– Use amplifiers to boost signalUse amplifiers to boost signal

•• Also amplifies noiseAlso amplifies noise

26

Conversion of Voice Input into Conversion of Voice Input into Analog SignalAnalog Signal

27

Digital TransmissionDigital Transmission–– Concerned with contentConcerned with content–– Integrity endangered by noise, attenuation etc.Integrity endangered by noise, attenuation etc.–– Repeaters usedRepeaters used

•• Repeater receives signalRepeater receives signal•• Extracts bit patternExtracts bit pattern•• RetransmitsRetransmits

–– Attenuation is overcomeAttenuation is overcome–– Noise is not amplifiedNoise is not amplified

28

Page 8: LECTURE 3 - SIGNALS

Department of EEE CS 65- Computer Networks

Prepared by Dr.S.Muralidharan 8

Conversion of PC Input to Digital Conversion of PC Input to Digital SignalSignal

29

Advantages of Digital TransmissionAdvantages of Digital Transmission•• Digital technologyDigital technology

–– Low cost LSI/VLSI technologyLow cost LSI/VLSI technology•• Data integrityData integrity

–– Longer distances over lower quality linesLonger distances over lower quality lines•• Capacity utilizationCapacity utilization

–– High bandwidth links economicalHigh bandwidth links economical–– High degree of multiplexing easier with digital techniquesHigh degree of multiplexing easier with digital techniques

•• Security & PrivacySecurity & Privacy–– EncryptionEncryption

•• IntegrationIntegration–– Can treat analog and digital data similarlyCan treat analog and digital data similarly

30

Attenuation of Digital SignalsAttenuation of Digital Signals

31

Analog Signals Carrying Analog and Analog Signals Carrying Analog and Digital DataDigital Data

32

Page 9: LECTURE 3 - SIGNALS

Department of EEE CS 65- Computer Networks

Prepared by Dr.S.Muralidharan 9

Digital Signals Carrying Analog and Digital Signals Carrying Analog and Digital DataDigital Data

33

Signal Element Vs Data Element• In data communication, goal is to send the data

elements, which is the smallest entity that can represent a piece of information. ie. a bit.

• In data communication, a signal element is one which carries data elements.– Simply data elements are being carried ; signal

elements are the carriers.• data element is like a person to be transported

from one place to another. And the vehicle he/she uses signal element. 34

35

Transmission ImpairmentsTransmission ImpairmentsSignalsSignals traveltravel throughthrough transmissiontransmission media,media,whichwhich areare notnot perfectperfect.. TheThe imperfectionimperfection causescausessignalsignal impairmentimpairment.. ThisThis meansmeans thatthat thethe signalsignalatat thethe beginningbeginning ofof thethe mediummedium isis notnot thethesamesame asas thethe signalsignal atat thethe endend ofof thethe mediummedium..WhatWhat isis sentsent isis notnot whatwhat isis receivedreceived.. ThreeThreecausescauses ofof impairmentimpairment areare attenuationattenuation,,distortiondistortion,, andand noisenoise..

36

Page 10: LECTURE 3 - SIGNALS

Department of EEE CS 65- Computer Networks

Prepared by Dr.S.Muralidharan 10

AttenuationAttenuation–– Signal strength falls off with distanceSignal strength falls off with distance–– Depends on mediumDepends on medium–– Received signal strength:Received signal strength:

•• must be enough to be detectedmust be enough to be detected•• must be sufficiently higher than noise to be must be sufficiently higher than noise to be

received without errorreceived without error–– Attenuation is an increasing function of frequencyAttenuation is an increasing function of frequency

37

Example 1:Suppose a signal travels through a transmissionmedium and its power is reduced to one-half. Thismeans that P2 is (1/2)P1. In this case, the attenuation(loss of power) can be calculated as

A loss of 3 dB (–3 dB) is equivalent to losing one-halfthe power

Example 2:A signal travels through an amplifier, and its power isincreased 10 times. This means that P2 = 10P1 . Inthis case, the amplification (gain of power) can becalculated as

38

One reason that engineers use the decibel to measurethe changes in the strength of a signal is that decibelnumbers can be added (or subtracted) when we aremeasuring several points (cascading) instead of just two.In Figure below a signal travels from point 1 to point 4. Inthis case, the decibel value can be calculated as

39

Example 3:Sometimes the decibel is used to measure signal powerin milliwatts. In this case, it is referred to as dBm and iscalculated as dBm = 10 log10 Pm , where Pm is thepower in milliwatts. Calculate the power of a signal withdBm = −30.SolutionWe can calculate the power in the signal as

40

Page 11: LECTURE 3 - SIGNALS

Department of EEE CS 65- Computer Networks

Prepared by Dr.S.Muralidharan 11

Example 4:The loss in a cable is usually defined in decibels per kilometer (dB/km). If the signal at the beginning of a cable with −0.3 dB/km has a power of 2 mW, what is the power of the signal at 5 km?SolutionThe loss in the cable in decibels is 5 × (−0.3) = −1.5 dB. We can calculate the power as

41

Delay DistortionDelay Distortion•• Only in guided mediaOnly in guided media•• Propagation velocity varies with frequencyPropagation velocity varies with frequency

42

NoiseNoise–– Additional signals inserted between transmitter Additional signals inserted between transmitter

and receiverand receiver–– ThermalThermal

•• Due to thermal agitation of electronsDue to thermal agitation of electrons•• Uniformly distributedUniformly distributed•• White noiseWhite noise

–– CrosstalkCrosstalk•• A signal from one line is picked up by anotherA signal from one line is picked up by another

–– ImpulseImpulse•• Irregular pulses or spikesIrregular pulses or spikes•• e.g. External electromagnetic interferencee.g. External electromagnetic interference•• Short durationShort duration•• High amplitudeHigh amplitude 43

Noise

44

Page 12: LECTURE 3 - SIGNALS

Department of EEE CS 65- Computer Networks

Prepared by Dr.S.Muralidharan 12

– Want a high Signal-to-Noise Ratio (SNR)• Signal strength divided by average noise strength• As SNR falls, errors increase

SignalStrength

Distance

Signal

Noise FloorSNR

45

Example 1The power of a signal is 10 mW and the power ofthe noise is 1 µW; what are the values of SNR andSNRdB?

SolutionThe values of SNR and SNRdB can be calculatedas follows:

46

Two cases of SNR: a high SNR and a low SNR

47

Example 2The values of SNR and SNRdB for a noiselesschannel are

We can never achieve this ratio in real life; itis an ideal.

48

Page 13: LECTURE 3 - SIGNALS

Department of EEE CS 65- Computer Networks

Prepared by Dr.S.Muralidharan 13

Data rate Vs. Signal rate :• Data rate or Bit rate : defines the number of

data element (bits) sent in 1 second.• Signal rate or Pulse rate or Modulation rate or

Baud rate : is the number of signal elements sent in 1 second.

• In data communication the objective is to increase the data rate while decreasing the signal rate. Increasing the data rate increases the speed of transmission; decreasing the signals rate decreases the bandwidth requirement.

• Analogy : increase the number of persons per vehicle to transport all speedily and with less number of vehicles and thereby the less traffic jam.

49

In Analog Transmission :• The relationship between data rate (bit rate) and

signal rate (baud rate) is S = N x (1/r)

Where N is the data rate(bps) and r is the number of data elements carried in one signal element.In analog transmission r = log2L where L is the type

of signal element, not the level.

50

In Digital TransmissionThe relation between data rate (bit rate) and signal rate (baud rate) is

S = c x N x (1/r)Where N is the data rate(bps); c is the case factor which

varies for each case (worst case is when we need the maximum signal rate; best case is when we need the minimum; normally in data communication, we are usually interested in average ie.c= ½) ; S is the number of signal elements; and r depends on number of data bit per signal element.(ie. r=1 if one data bit per one signal element, r=1/2 if one data element per two signal element; r=2 if two data elements per one signal; r=4/3 if four data elements per three signal elements)

51

Performance of Network• Network performance is measured in two

fundamental ways: bandwidth (also called throughput) and latency (also called delay).

• The bandwidth of a network is given by the number of bits that can be transmitted over the network in a certain period of time.

• For example, a network might have a bandwidth of 10 million bits/second (Mbps), meaning that it is able to deliver 10 million bits every second. It is sometimes useful to think of bandwidth in terms of how long it takes to transmit each bit of data. On a 10-Mbps network, for example, it takes 0.1 microsecond (µs) to transmit each bit.

• The second performance metric, latency, corresponds to how long it takes a message to travel from one end of a network to the other. It is measure in time.

52

Page 14: LECTURE 3 - SIGNALS

Department of EEE CS 65- Computer Networks

Prepared by Dr.S.Muralidharan 14

Total latency can be described byLatency = Propagation + Transmit + QueuePropagation = Distance/Speed Of Light

where “Distance” is the length of the wire over which the data will travel, “Speed- Of Light” is the effective speed of light over that wire, “Size” is the size of the packet, and “Bandwidth” is the bandwidth at which the packet is transmitted. Queue corresponds to the delay happening at the node because of congestion and Transmit is the time required for transmission at the node and is given by

Transmit = Size/Bandwidth

Round-Trip Time (RTT) - it is the time taken by a message transmitted from one end of a network to the other and back.

53

Delay x Bandwidth ProductIf we think of a channel between a pair of processes as a

hollow pipe, where the latency corresponds to the length of the pipe and the bandwidth gives the diameter of the pipe, then the delay ×bandwidth product gives the volume of the pipe—the maximum number of bits that could be in transit through the pipe at any given instant. Said another way, if latency (measured in time) corresponds to the length of the pipe, then given the width of each bit (also measured in time), you can calculate how many bits fit in the pipe. For example, a transcontinental channel with a one-way latency of 50 ms and a bandwidth of 45 Mbps is able to hold 50×10−3 sec×45×106 bits/sec = 2.25 ×106 bits or approximately 280 KB of data. In other words, this example channel (pipe) holds as many bytes as the memory of a personal computer from the early 1980s could hold.

54

• The delay × bandwidth product is important to know when constructing high-performance networks because it corresponds to how many bits the sender must transmit before the first bit arrives at the receiver. If the sender is expecting the receiver to somehow signal that bits are starting to arrive, and it takes another channel latency for this signal to propagate back to the sender, then the sender can send up to two delay × bandwidths worth of data before hearing from the receiver that all is well. The bits in the pipe are said to be “in flight,” which means that if the receiver tells the sender to stop transmitting, it might receive up to a delay × bandwidth’s worth of data before the sender manages to respond. In our example above, that amount corresponds to 5.5 × 106 bits (671 KB) of data. On the other hand, if the sender does not fill the pipe—send a whole delay×bandwidth product’s worth of data before it stops to wait for a signal—the sender will not fully utilize the network.

55

Case Study to insist the need for high speed networks Requirement : to transmit a 1-MB file over

a) 1-Mbps network b) 1-Gbps network, both of which have an RTT of 100 ms.

• In the case of the 1-Mbps network, it takes 80 round-trip times to transmit the file; during each RTT, 1.25%of the file is sent.

• In contrast, the same 1-MB file doesn’t even come close to filling 1 RTT’s worth of the 1-Gbps link, which has a delay × bandwidth product of 12.5 MB.

56

Page 15: LECTURE 3 - SIGNALS

Department of EEE CS 65- Computer Networks

Prepared by Dr.S.Muralidharan 15

• The effective end-to-end throughput that can be achieved over a network is given by the simple relationship

Throughput = TransferSize/TransferTime

where TransferTime includes not only the elements of one-way Latency identified earlier in this section, but also any additional time spent requesting or setting up the transfer. Generally, we represent this relationship as

TransferTime = RTT + 1/Bandwidth x TransferSize57