You are on page 1of 55

Data Communications

&
Computer Network

Dr. Sumit Srivastava


Dept. of CSE, BIT Mesra Ranchi
Email:- sumit.srivs88@gmail.com
Module-1
References

▪ Data and Computer Communications, William Stallings, PHI


▪ Tanenbaum and David J Wetherall, Computer Networks, 5th Edition, Pearson
Edu, 2010
▪ Computer Networks: A Top-Down Approach, Behrouz A. Forouzan, Firouz
Mosharraf, McGraw Hill Education
▪ Larry L. Peterson and Bruce S. Davie, “Computer Networks – A Systems
Approach” (5th ed), Morgan Kaufmann/ Elsevier, 2011
▪ Data Communications and Networking, Behrouz A. Forouzan, TMH
▪ Computer Networks, Andrew S. Tanenbaum, PHI Version 2 CSE IIT,
Kharagpur
▪ Internetworking with TCP/IP; Principles, Protocols, and Architecture, Douglas
E. Commer, 3rd Edition, Prentice Hall of India

Module-1
Terminology

▪ Transmitter
▪ Receiver
▪ Medium
—Guided medium
• e.g. twisted pair, optical fiber
—Unguided medium
• e.g. air, water, vacuum

Module-1
Analog Signal and Digital Signal

Like the data they represent, signals can be either analog or


digital
▪ Analog signals can have an infinite number of values in a
range
▪ Digital signals can have only a limited number of values

In data communications, we commonly use


periodic analog signals and nonperiodic digital signals.

Module-1
Periodic and Nonperiodic

• A periodic signal completes a pattern within a measurable


time frame, called a period, and repeats that pattern over
subsequent identical periods. The completion of one full
pattern is called a cycle.

• A nonperiodic signal changes without exhibiting a pattern


or cycle that repeats over time

Module-1
PERIODIC ANALOG SIGNALS

Periodic analog signals can be classified as simple or


composite.
▪ A simple periodic analog signal, a sine wave, cannot be
decomposed into simpler signals.
▪ A composite periodic analog signal is composed of multiple
sine waves.

Module-1
Signal Amplitude

Module-1
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.

▪ If a signal does not change at all, its frequency is zero


▪ If a signal changes instantaneously, its frequency is
infinite.

Module-1
Frequency and Period

Frequency and period are the inverse of each other.

Units of period and frequency

Module-1
Two signals with the same amplitude,
but different frequencies

Module-1
Phase

Phase describes the position of the waveform


relative to time 0
Three sine waves with the same amplitude and frequency,
but different phases

Module-1
Wavelength and Period

Wavelength = Propagation speed x Period


= Propagation speed / Frequency

Module-1
Time and Frequency Domains

• A sine wave is comprehensively defined by its amplitude,


frequency, and phase.

• We have been showing a sine wave by using what is


called a time domain plot. The time-domain plot shows
changes in signal amplitude with respect to time (it is an
amplitude-versus-time plot).

• Phase is not explicitly shown on a time-domain plot.

Module-1
Time-domain and frequency-domain plots of
a sine wave
A complete sine wave in the time domain can be
represented by one single spike in the frequency domain.

Module-1
Frequency Domain

▪ The frequency domain is more compact and useful when we are


dealing with more than one sine wave.
▪ A single-frequency sine wave is not useful in data communication
We need to send a composite signal, a signal made of many
simple sine waves.
Module-1
Fourier analysis

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.

Module-1
A composite periodic signal

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

17
Module-1
Time and frequency domains of a
nonperiodic signal
A nonperiodic composite signal
▪ It can be a signal created by a microphone or a telephone set when a
word or two is pronounced.
▪ In this case, the composite signal cannot be periodic
▪ because that implies that we are repeating the same word or words
with exactly the same tone.

18
Module-1
Bandwidth
The bandwidth of a composite signal is
the difference between the highest and the lowest
frequencies contained in that signal.

19
Module-1
DIGITAL SIGNALS

▪ In addition to being represented by an analog signal,


information can also be represented by a digital signal.
▪ For example, a 1 can be encoded as a positive voltage
and a 0 as zero voltage.
▪ A digital signal can have more than two levels.
▪ In this case, we can send more than 1 bit for each level.

Module-1
Two digital signals: one with two signal levels and
the other with four signal levels

Module-1
The time and frequency domains of periodic and
nonperiodic digital signals

Module-1
TRANSMISSION IMPAIRMENT

▪ Signals travel through transmission media, which are not


perfect.
▪ The imperfection causes signal impairment.
▪ This means that the signal at the beginning of the medium is
not the same as the signal at the end of the medium ( i.e.,
What is sent is not what is received).
▪ Three causes of impairment are attenuation, distortion, and
noise.

Module-1
Attenuation

Module-1
Attenuation

▪ Attenuation can be considered as the loss of energy


▪ When a signal travels through a medium it loses energy
overcoming the resistance of the medium. That is why a
wire carrying electric signals gets warm, if not hot, after a
while. Some of the electrical energy in the signal is
converted to heat.

▪ It decides how far the signal can go without amplification

▪ Amplifiers are used to compensate for this loss of energy


by amplifying the signal.

Module-1
Decibel

▪ To show that a signal has lost or gained strength, we use


the unit of the decibel.
▪ The decibel (dB) measures the relative strengths of two
signals or one signal at two different points.
▪ Note that the decibel is:
▪ Negative if a signal is attenuated and
▪ Positive if a signal is amplified.

▪ PI and P2 are the powers of a signal at points 1 and 2, respectively

Module-1
Example

• Suppose a signal travels through a transmission medium and its


power is reduced to one-half. This means 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-half the


power.

Module-1
A signal travels from point 1 to point 4. In this case, the decibel
value can be calculated as

▪ Whenever we amplify then we get a value which is positive and


whenever attenuation occurs, we get a value which is negative
Module-1
Distortion

Module-1
Distortion

◼ Means that the signal changes its form or shape

◼ Distortion occurs in composite signals

◼ Each frequency component has its own propagation


speed traveling through a medium.

◼ The different components therefore arrive with


different delays at the receiver.

◼ That means that the signals have different phases at


the receiver than they did at the source.
Module-1
▪ Distortion means that the signal changes its form or shape.

▪ Distortion can occur in a composite signal made of different


frequencies.
▪ Each signal component has its own propagation speed
through a medium and, therefore, its own delay in arriving at
the final destination.
▪ Differences in delay may create a difference in phase if the
delay is not exactly the same as the period duration.
▪ In other words, signal components at the receiver have
phases different from what they had at the sender.
▪ The shape of the composite signal is therefore not the same.

Module-1
Delay distortion
• Delay distortion arises particularly in a guided media but
not in air

• Delay distortion arises because velocity of propagation


varies with frequency.

• That means this signal components that we are sending


will have different velocities for different frequency
components as it passes through a guided media, and this
leads to delay distortion

Module-1
Noise

Module-1
Noise

▪ Thermal noise is the random motion of electrons in a wire


which creates an extra signal not originally sent by the
transmitter.
▪ Induced noise comes from sources such as motors and
appliances.
• These devices act as a sending antenna, and the
transmission medium acts as the receiving antenna.
▪ Cross-talk is the effect of one wire on the other. One wire
acts as a sending antenna and the other as the receiving
antenna.
▪ Impulse noise is a spike (a signal with high energy in a
very short time) that comes from power lines, lightning,
and so on.
Module-1
Effect Of Noise On A Signal

Module-1
Signal-to-Noise Ratio (SNR)

• To find the theoretical bit rate limit, we need to know the


ratio of the signal power to the noise power.

• The signal-to-noise ratio is defined as:

SNR = average signal power / average noise power

• We need to consider the average signal power and the


average noise power because these may change with
time.

Module-1
Module-1
Signal-to-Noise Ratio (SNR)
▪ SNR is actually the ratio of what is wanted (signal) to
what is not wanted (noise).
• A high SNR means the signal is less corrupted by
noise;
• A low SNR means the signal is more corrupted by
noise.
▪ Because SNR is the ratio of two powers, it is often
described in decibel units, SNRdB defined as:

SNRdB = 10 log10 SNR

Module-1
Data Rate Limits
▪ A very important consideration in data communications is
how fast we can send data, in bits per second. over a
channel.
▪ Data rate depends on three factors:
1. The bandwidth available
2. The level of the signals we use
3. The quality of the channel (the level of noise)
▪ Two theoretical formulas were developed to calculate the
data rate:
• By Nyquist: For a noiseless channel
• By Shannon: For a noisy channel.
Module-1
Data Rate Limits

Noiseless Channel: Nyquist Bit Rate

▪ For a noiseless channel, the Nyquist bit rate formula


defines the theoretical maximum bit rate

Bit Rate = 2 x bandwidth x 10g2 L

▪ In this formula, bandwidth is the bandwidth of the channel,


L is the number of signal levels used to represent data,
and Bit Rate is the bit rate in bits per second.

Module-1
Nyquist Bit Rate

Bit Rate = 2 x bandwidth x 10g2 L

▪ According to the formula, we might think that, given a


specific bandwidth, we can have any bit rate we want by
increasing the number of signal levels.

▪ Although the idea is theoretically correct, practically there is


a limit. When we increase the number of signal levels, we
impose a burden on the receiver.

Module-1
Nyquist Bit Rate

Bit Rate = 2 x bandwidth x 10g2 L

▪ If the number of levels in a signal is just 2, the receiver can


easily distinguish between a 0 and a 1.

▪ If the level of a signal is 64, the receiver must be very


sophisticated to distinguish between 64 different levels.

▪ In other words,.
Increasing the levels of a signal may reduce the reliability
of the system.

Module-1
Noisy Channel: Shannon Capacity
▪ In reality, we cannot have a noiseless channel; the
channel is always noisy.

▪ In 1944, Claude Shannon introduced a formula, called the


Shannon capacity, to determine the theoretical highest
data rate for a noisy channel:
Capacity =bandwidth X log2 (1 +SNR)

▪ In this formula, bandwidth is the bandwidth of the


channel, SNR is the signal-to-noise ratio, and capacity is
the capacity of the channel in bits per second.
Module-1
Noisy Channel: Shannon Capacity

Noisy Channel: Shannon Capacity

Capacity =bandwidth X log2 (1 +SNR)

▪ Note that in the Shannon formula there is no indication of


the signal level, which means that no matter how many
levels we have, we cannot. achieve a data rate higher
than the capacity of the channel

▪ In other words, the formula defines a characteristic of the


channel, not the method of transmission.
Module-1
Bandwidth
▪ One characteristic that measures network performance is
bandwidth.

▪ However, the term can be used in two different contexts with


two different measuring values:

▪ bandwidth in hertz and

▪ bandwidth in bits per second

▪ Bandwidth in hertz is the range of frequencies contained in a


composite signal or the range of frequencies a channel can
pass (For example, we can say the bandwidth of a subscriber
telephone line is 4 kHz).
Module-1
Bandwidth
Bandwidth in Hertz
▪ range of frequencies a channel can pass, or range of
frequencies contained in a composite signal

Bandwidth in Bits per Seconds

▪ The term bandwidth can also refer to the number of bits per
second that a channel, a link, or even a network can transmit.

▪ For example, one can say the bandwidth of a Fast Ethernet


network (or the links in this network) is a maximum of 100
Mbps. This means that this network can send 100 Mbps.

Module-1
Throughput

▪ The throughput is a measure of how fast we can actually send


data through a network.

▪ Although, bandwidth in bits per second and throughput seem the


same, they are different.

▪ 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.

▪ In other words, the bandwidth is a potential measurement of a


link; the throughput is an actual measurement of how fast we
can send data.
Module-1
Latency (Delay)

▪ The latency or 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.

▪ Latency is made of four components:

▪ Propagation time

▪ Transmission time

▪ Queuing time and

▪ Processing delay

Module-1
Latency

Latency
=
propagation time + transmission time + queuing
time + processing delay

Module-1
Latency (Delay)

Propagation Time
 The time required for a bit to travel from the source to the destination.
 The propagation time is calculated by dividing the distance by the
propagation speed.

Propagation time = Distance / Propagation speed

Module-1
Latency (Delay)

Propagation Time
 The propagation speed of electromagnetic signals depends on the
medium and on the frequency of the signal.
 For example, in a vacuum, light is propagated with a speed of 3 x 108
m/s. It is lower in air; it is much lower in cable.

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 x 108 m/s in cable.

Solution

Propagation time = Distance / Propagation speed

Propagation time = 12000 x 1000 / 2.4 x 108


= 50 ms
Module-1
Latency (Delay)

Transmission Time
 We don't send just 1 bit, we send a message.
 The first bit may take a time equal to the propagation time to reach its
destination; the last bit also may take the same amount of time.
 However, there is a time between the first bit leaving the sender and the
last bit arriving at the receiver.
 The first bit leaves earlier and arrives earlier; the last bit leaves later
and arrives later.
 The time required for transmission of a message depends on the
size of the message and the bandwidth of the channel.

Transmission time = Message Size / Bandwidth

Module-1
Latency (Delay)

Example
 What are the propagation time and the transmission time for a 2.5 KB
message (an e-mail) if the bandwidth of the network is 1 Gbps? Assume
that the distance between the sender and the receiver is 12,000 km and
that light travels at 2.4 x 108 m/s.

Solution

Propagation time = Distance / Propagation speed

Propagation time = 12000 x 1000 / 2.4 x 108


= 50 ms

Transmission time = Message Size / Bandwidth

Transmission time = 2500 x 8/109


= 0.020 ms
Module-1
Latency (Delay)

Queuing Time
 The third component in latency is the queuing time, the time needed for
each intermediate or end device to hold the message before it can be
processed.
 The queuing time is not a fixed factor; it changes with the load imposed
on the network.
 When there is heavy traffic on the network, the queuing time increases.
An intermediate device, such as a router, queues the arrived messages
and processes them one by one. If there are many messages, each
message will have to wait.

Module-1
Module-1

You might also like