LU 3-Digital and Analog Signal Lecture - Version.v2
LU 3-Digital and Analog Signal Lecture - Version.v2
Signals
TMF6044
ICT Infrastructure
Watch this:
https://www.youtube.com/watch?v=JT9zM_-2S6g
2
Think about it ?
• How do you transfer an image file like jpeg, gif, tiff
through Internet?
• Can you just transfer the image into the wire only?
3
Solution
• Need to transmit an encoded description of the
image
– use encoder to create a stream of 1s and 0s
– further convert into a form that transmission media can
accept - energy in the form of electromagnetic signals.
carry digital data
5
Need to Understand
• Analog vs Digital
– Analog data vs Digital data
– Analog signal vs Digitalslalunya
repeating patern, they dont carry data (no meaning)
signal
data transfer adalah non-periodic
• Periodic and non-periodic signal
– Sine wave – Frequency, Period, Phase, Wavelength
• Digital Transmission
– Baseband vs Broadband
• Transmission Impairment
– Attenuation, Distortion, Noise
• Data Rate Limits jitter
– Noiseless Nyquist Bit Rate vs Noisy Shannon Capacity - sometimes faster connection,
sometimes slower connection
• Performance
- different timing
average delay - always look at slower
voice
• A computer stores
the 3-colour image
as right.
• Size of the image =
9x13x2 = 234 bits
How about 4 colours?
• For the 3-colour house we
have used the binary
strings 00, 01, 10.
• But 11, which corresponds
to 3 in decimal, was not
used,
• Use binary 11 to represent
green colour
– 0 = 00: white
– 1 = 01: black
– 2 = 10: red
– 3 = 11: green
4-colour binary representation
• A computer stores the 4-
colour house image as
right.
• Size of the image = 9x13x2
= 234 bits
Exercise
• A signal has been received that only has values of -
1, 0 and 1. Is this an analog or a digital signal?
17
Periodic and non-
periodic signal
Sine Wave
Wavelength
Time and Frequency Domain
Composite Signals
Bandwidth
19
Periodic and non-periodic signal
• Periodic signal
– completes a pattern in a measurable time frame called a period.
– It then repeats the pattern over and over again in following, identical,
periods.
– Example, clock can be thought as periodic cycling
• Non-periodic signal
– changes without exhibiting a pattern or cycle that repeats over time.
20
carrier that use to carry data
22
Frequency and period are inverses of
each other
𝐹𝑟𝑒𝑞𝑢𝑒𝑛𝑐𝑦, 𝑓 = 1Τ𝑇
𝑃𝑒𝑟𝑖𝑜𝑑, 𝑇 = 1Τ𝑓
how much time to complete one cycle
23
Period and frequency
Technique for calculating T and f
1.Check the T
2.Calculate the complete cycle in 1 second
f = 12 Hz
1 second
f = 6 Hz
25
Units of periods and frequencies
26
More about frequency
• Frequency is the rate of change with respect to time.
Change in a short span of time means high
frequency. Change over a long span of time means
low frequency .
27
More about Signal
• If a signal does not change at all, its frequency is
zero.
• If a signal changes instantaneously, its frequency is
infinite.
28
Exercise
• Express a period of 100 ms in microseconds, and
express the corresponding frequency in kilohertz.
29
Solution
• From above table, we find the equivalent of 1 ms.
We make the following substitutions:
• 100 ms = 100 10-3 s = 100 10-3 106 ms = 105 ms
31
Exercise
• Given the following periods, calculate the
corresponding frequency. Express the frequency in
hertz, kilohertz, megahertz, gigahertz
–5s
– 12 μs
32
Wavelength
• Binds the period or the frequency of a simple sine
wave to the propagation speed of the medium
• The wavelength is the distance a simple signal can
travel in one period
33
Wavelength and Phase
1
𝑓𝑟𝑒𝑞𝑢𝑒𝑛𝑐𝑦 (𝑓) =
𝑤𝑎𝑣𝑒𝑙𝑒𝑛𝑔𝑡ℎ (𝜆)
34
Phase
• Phase describes the position of the waveform
relative to time zero.
• Phase is measured in degrees or Radians
– 360o = 2π radiant
– So, 1o =2π / 360o and
– 1 rad = 3600 / 2π = 360 / 6.284 = 57.290
35
Relationship btw different phases
Three sine waves
with the same
amplitude and
frequency, but
different phases
36
Example
• A sine wave is offset 1/6 of a cycle with respect to
time zero. What is its phase in degrees and radians?
37
Solution
We know that one complete cycle is 360 degrees.
Therefore, 1/6 cycle is
(1/6) 360 = 60 degrees = 60 x 2p /360 rad = 1.046 rad
38
Propagation Time
• Measure the time required for a signal (or a bit) to
travel from one point of the transmission medium to
another.
39
Propagation Speed
• Measures the distance a signal or a bit can travel
through a medium in one second
40
Example
What is the propagation time if the distance between the two
points is 12,000 km? Assume the propagation speed to be 2.4 ×
108 m/s in cable.
Solution
We can calculate the propagation time as
42
Time & Frequency domains
43
Time & Frequency domains (cont.)
44
Composite signals
• A simple sine wave signal is useless for data
communications
• Need to change one or more of its characteristics
for data communication (why?)
– When change one or more characteristics of a single-
frequency signal, it become composite signal which
made of many frequencies
– Modulate (combine) data signal with a carrier signal will
form a composite signal
45
Bandwidth
• It is the width of a frequency band
• The property of a medium or the width of a single
spectrum or the range of frequencies that a medium
can pass.
• It is the difference between the highest and the
lowest frequencies that the medium can
satisfactorily pass.
• No medium can pass or block all frequencies
46
Bandwidth
48
Solution
• B = fh - fl = 900 - 100 = 800 Hz
• The spectrum has only five spikes, at 100, 300, 500,
700, and 900
49
Example
A 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 integral
frequencies of the same amplitude.
50
Solution
• B = fh - fl
• 20 = 60 - fl
• fl = 60 - 20 = 40 Hz
51
Digital Signals
Bit Rate
Bit Length
Digital Signal as a Composite Analog Signal
52
Introduction
• Digital signal represented as 1 and 0
– 1, encoded as a positive voltage
– 0, zero voltage
• Most digital signals are non-periodic thus use period
and frequency are not appropriate
– Used bit interval (instead of period) and bit rate (instead
of frequency) to describe digital signals
internet speed always calculated in bit
B - byte
b - bit
1 byte = 8 bit
cth: mBps
53
Digital Signal
54
Two digital signals: one with two signal
levels and the other with four signal levels
55
Example
• A digital signal has eight levels. How many bits are
needed per level? We calculate the number of bits
from the formula
56
Solution
Number of bits per level = log 2 8 = 3
59
Bit Length
• Bit length is the distance one bit occupies on the
transmission medium
61
Solution
• The bit interval is the inverse of the bit rate.
• Bit interval = 1/ 2000 s = 0.000500 s
= 0.000500 x 106 ms = 500 ms
62
Exercise
• What is the bit rate for each of the following signals?
– A signal in which 1 bit lasts 0.0001s
– A signal in which 1 bit lasts 2 ms
63
Digital Signal as a Composite Analog
signal
• Based on Fourier analysis
– A digital signal is composite analog signal
– If the digital signal is periodic, (rare in data
communication), the decomposed signal has a
frequency domain representation with an infinite
bandwidth and discrete frequencies
– If the digital signal is non-periodic, the decomposed signal
still has an infinite bandwidth, but the frequencies are
continuous.
64
The time and frequency domains of periodic
and non-periodic digital signals
65
Exercise
• What is the duration of 1 bit for each of the following
signals?
– A signal with a bit rate of 100bps
– A signal with a bit rate of 200Kbps
66
Digital Transmission
Baseband Transmissionbetween computer system. computer to computer using cable
Broadband Transmission
67
Transmission of Digital Signal
• We can transmit a digital signal by using two
approaches:
– Baseband transmission
– Broadband transmission (using modulation)
69
Baseband transmission
• Transmitting the original form of digital signal
• Sending a digital signal over a channel without
changing the digital signal to an analog signal
• Require to have a low-pass channel
70
Baseband transmission (cont.)
• Baseband transmission of a digital signal that
preserves the shape of the digital signal is possible
only if we have a low-pass channel with an infinite or
very wide bandwidth
71
Broadband transmission (using
modulation)
• Changing the digital signal to an analog signal for
transmission.
• Modulation allows to use bandpass-channel, a
channel with a bandwidth that does not start from
zero
72
Broadband transmission (using
modulation) (cont.)
• If the available channel is a bandpass channel, we
cannot send the digital signal directly to the
channel.
• We need to convert the digital signal to an analog
signal before transmission.
73
Modulation of a digital signal for
transmission on a bandpass channel
74
Transmission impairment
Cause of impairment: Attenuation, Distortion, Noise
75
Transmission Impairment
• Signal are not perfect while travel through
transmission media and cause impairment on the
signal
• What is sent is not what is received
76
Attenuation
will amplify the signal into the original size. make it louder again.
78
Solution
10 log10 (P2/P1) = 10 log10 ((0.5P1)/P1)
= 10 log10 (0.5)
= 10(–0.3)
= –3 dB
79
Example
• Imagine a signal travels through an amplifier and its
power is increased ten times. This means that P2 = 10
x P1.
80
Solution
10 log10 (P2/P1) = 10 log10 (10P1/P1)
= 10 log10 (10)
= 10 (1)
= 10 dB
81
Example
one reason that engineers use the decibel to measure the
changes in the strength of a signal is that decibel numbers
can be added (or subtracted) when we are measuring
several points (cascading) instead of just two.
In Figure below, a signal travels from point 1 to point 4. In
this case, the decibel value can be calculated as
dB = -3 + 7 -3 = +1
82
Distortion
• Signal changes its form or shape
• Can occur in a composite signal made of different frequencies due to delay in arrival time at
the final destination
– Signal components at the receiver have phases different from what they had at the sender
– Therefore, shape of the composite signal not the same
83
Noise
• Several types of noise
– Thermal noise – random motion of electrons in the wire which creates an extra signal not
originally sent by the transmitter
– Induce noise – comes from sources such as motors and appliances (act as sending
antenna, and the transmission medium acts as the receiving antenna) cth mcm peti ais and speaker
contoh mcm fon di opis. masih boleh dengar suara belakang
– Crosstalk – the effect of one wire on the other (one act as sending antenna, and other
acts as the receiving antenna)
– Impulse noise – signal with high energy in a very short time that comes from power lines,
lightning, etc.
85
Signal to Noise Ratio (SNR)
• ratio of what is wanted (signal) to what is not wanted (noise)
• High SNR – signal is less corrupted by noise
• Low SNR – signal is more corrupted by noise
if this happen,
ask for re-transmission
87
Example
The power of a signal is 10 mW and the power of the
noise is 1 μW; what are the values of SNR and SNRdB ?
88
Solution
The values of SNR and SNRdB can be calculated as
follows:
89
Data Rate Limits
Noiseless Channel: Nyquist Bit Rate
Noisy Channel: Shannon Capacity
90
Data Rate Limits
• How fast we can send data (bps) is a very important
consideration in data communication.
• Data rate depends on 3 factors:
– Bandwidth
– Level of the signal
– Quality of the channel (level of noise)
• Two theoretical formulas were used for calculate the
data rate
– Nyquist for noiseless channel
– Shannon for a noisy channel
91
Noiseless Channel: Nyquist Bit Rate
92
Noiseless Channel: Nyquist Bit Rate
• Increase the levels of signal may reduce the
reliability of the system
• Why ?
– The receiver must be very sophisticated to distinguish
more different levels, for example using 64 instead of 2
levels.
93
2-level vs 4-level vs 16-level vs 64-level
2-level
(BPSK) 4-level 16-level 64-level
(QPSK)
24 = 16
21 = 2 0000, 0001, 0010,…
0, 1 22 = 4
00, 01, 10, 11
94
Example
Consider a noiseless channel of 3kHz bandwidth,
transmitting a signal with four signal levels (for each
level, we send two bits).
95
Solution
• Bit Rate = 2 x 3000 x log2 4 = 12,000 bps (12kbps)
96
Noisy Channel: Shannon Capacity
• Noisy Channel: Shannon Capacity
97
Example
Consider an extremely noisy channel in which the
value of the signal-to-noise ratio is almost zero. In other
words, the noise is so strong that the signal is faint.
98
Example
A telephone line normally has a bandwidth of 3000Hz.
The signal-to-noise ratio is usually 3162.
99
Solution
For this channel the capacity is calculated as
This means that the highest bit rate for a telephone line
is 34.860 kbps. If we want to send data faster than this,
we can either increase the bandwidth of the line or
improve the signal-to-noise ratio.
100
Nyquist vs Shannon
• The Shannon capacity gives us the upper limit; the
Nyquist formula tells us how many signal levels we
need
101
Performance
Bandwidth
Throughput
Latency (Delay)
Bandwidth Delay Product
102
Bandwidth in Hertz and Bit per second
– Bandwidth in Hertz
• The range of frequencies contained in a composite signal or the
range of frequencies a channel can pass.
• Example: bandwidth of a subscriber telephone line is 4kHz
103
Throughput
• how fast data can pass through an entity (network
point)
104
Example
A network with bandwidth of 10 Mbps can pass only
an average of 12,000 frames per minute with each
frame carrying an average of 10,000 bits. What is the
throughput of this network?
105
Solution
• We can calculate the throughput as
106
Bandwidth vs throughput
• A link may have a bandwidth of B bps, but we can
only send T bps through this link with T always less
than B.
• Bandwidth is a potential measurement of a link
• Throughput is an actual measurement of how fast
we can send data
Car scenario
• A highway designed to transmit 1000 cars per minute
from one point to other
• If there is a congestion, this figure may be reduced
to 100 cars per minute
– The bandwidth is 1000 cars per minute
– The throughput is 100 cars per minute
108
Latency
• Delay defines how long it takes for an entire
message to completely arrive at the destination from
the time the first bit is sent out from the source
• Four components:
– Propagation time
– Transmission time
– Queuing time
– Processing delay
• Latency = propagation time + transmission time+
queuing time +processing delay
109
Propagation Time vs. Transmission time
vs. Queuing time
• Propagation Time: time required for a bit to ravel from the
source to the destination
– Propagation time = Distance / Propagation speed
• Transmission time: time required for transmission of a
message depends on the size of the message and
bandwidth of the channel
– Transmission time = message size/ bandwidth
• Queuing time: time needed for each intermediate or end
device to hold the message before it can be processed.
110
Bandwidth – Delay Product
• Bandwidth and delay are two performance metrics
of a link
• Bandwidth – delay product defines the number of
bits that can fill the link.
– Important if need to send data in bursts and wait for the
acknowledgment for each burst before sending the next
one
111
The scenario
• We can think about the link between two points as a
pipe. The cross section of the pipe represents the
bandwidth, and the length of the pipe represents
the delay. We can say the volume of the pipe
defines the bandwidth-delay product, as shown in
figure below.
112
Case 1:
113
Case 2:
114
Jitter
• Related to delay
• It is a problem if different packets of data encounter
different delays and the application using the data
at the receiver site is time-sensitive (audio and video
data)
• Example: if the first packet is 20ms delayed, second is
45 ms delayed, then the real-time application that
uses the packets endures jitter
115
Summary
• Data and signal can be analog or digital
– Analog
• Frequency, period, phase, wavelength
– Digital
• Bit rate, bit length
• Data rate limits
– Shannon , Nyquist
• Transmission impairment
– Attenuation, distortion, noise
• Performance
– Bandwidth
– Throughput
– Bandwidth delay product
116