Data Communication Math
1. What is the channel capacity for a teleprinter channel with a 300Hz bandwidth and
signal to noise ratio( SNR) of 3db? 2017
Using shannon’s capacity equation : C = B log2 (1 + SNR)
Given , B = 300Hz
SNR = 10 b = 10 0.3
So , Capacity, C= 300 log 2(1+ 10 0.3 ) = 474 bps
2. Given the following information , find the minimum bandwidth required for the path:
FDM multiplexing, Five devices, each require 4000Hz.
200Hz guard band for each device. 2017,15
No. of device = 5
No. of guard bands required among those is 4
Hence, total bandwidth = ( 4000*5) + ( 200*4)
= 20.8 KHz
3. Given a channel a channel with intended capacity of 20 Mbps. The bandwidth of the
channel is 3 MHz .What signal to noise ratio is required in order to achieve the
capacity? 2018,15
Given, Capaity, C= 20 Mbps
Bandwidth , B = 3 MHz
We know, C = B log2 (1 + SNR)
20* 1024 = 3*106 ( 1+ SNR)
SNR = 20.04db
4. A channel has a bit rate of 4kbps and a propagation delay of 20ms second. For what
range of frame size does stop wait given efficiency at least 50% ? 2015
Given , Bit rate = 4 kbps
One way propagation delay is = 20 ms
Efficiency = Transmission time of packet / ( Transmission time of packet + 2*
propagation delay)
0.5 = X / X + 2* 20* 10-3
X= 40* 10-3
Minimum bit rate = 40* 10-3 bps.
Minimum frame size = Transmission time of packet * given bit rate
= 40* 10-3 * 4* 103
= 160 bits
5. A multiplexer combines four 100kbps channel using a time slot of 2 bits. Show out the
fours arbitrary inputs. 2018,2014
a) What is the frame rate? b) What is the bit rate?
c)What is the frame duration? d) what is the bit duration?
The output ( 4* 100kbps) for four arbitrary inputs.
a) The link carries = 400kb/ 2*4 = 50000 frame per second
b) Bit rate = 4 * 100= 400 kbps
c) The frame duration is = 1/ 50000 = 20 micro sec
d) The bit duration on the output link is = 1/ 400000 = 2.5 micro second
6. A channel have a bandwidth of 5KHz. If we want to send data at 150 Kbps what will be
the the minimum SNRdb.
Given , Bandwidth = 5 KHz , data rate = 150 kbps
We know, C = B log2 (1 + SNR)
150* 1000 = 5* 1000 log2 (1 + SNR)
SNR = 90 db
IP address is an address having information about how to reach a specific host,
especially outside the LAN. An IP address is a 32 bit unique address having an
address space of 232.
Generally, there are two notations in which IP address is written, dotted decimal
notation and hexadecimal notation.
Dotted Decimal Notation:
Hexadecimal Notation:
Some points to be noted about dotted decimal notation:
1. The value of any segment (byte) is between 0 and 255 (both included).
2. There are no zeroes preceding the value in any segment (054 is wrong, 54 is
correct).
Classful Addressing
The 32 bit IP address is divided into five sub-classes. These are:
• Class A
• Class B
• Class C
• Class D
• Class E
Each of these classes has a valid range of IP addresses. Classes D and E are reserved
for multicast and experimental purposes respectively. The order of bits in the first
octet determine the classes of IP address.
IPv4 address is divided into two parts:
• Network ID
• Host ID
The class of IP address is used to determine the bits used for network ID and host ID
and the number of total networks and hosts possible in that particular class. Each ISP
or network administrator assigns IP address to each device that is connected to its
network.
Note: IP addresses are globally managed by Internet Assigned Numbers Authority(IANA)
and regional Internet registries(RIR).
Note: While finding the total number of host IP addresses, 2 IP addresses are not counted
and are therefore, decreased from the total count because the first IP address of any network
is the network number and whereas the last IP address is reserved for broadcast IP.
Class A
IP address belonging to class A are assigned to the networks that contain a large number of
hosts.
• The network ID is 8 bits long.
• The host ID is 24 bits long.
The higher order bit of the first octet in class A is always set to 0. The remaining 7 bits in
first octet are used to determine network ID. The 24 bits of host ID are used to
determine the host in any network. The default subnet mask for class A is
255.x.x.x. Therefore, class A has a total of:
• 2^7-2= 126 network ID(Here 2 address is subtracted because 0.0.0.0 and
127.x.y.z are special address. )
• 2^24 – 2 = 16,777,214 host ID
IP addresses belonging to class A ranges from 1.x.x.x – 126.x.x.x
Class B
IP address belonging to class B are assigned to the networks that ranges from medium-sized
to large-sized networks.
• The network ID is 16 bits long.
• The host ID is 16 bits long.
The higher order bits of the first octet of IP addresses of class B are always set to 10. The
remaining 14 bits are used to determine network ID. The 16 bits of host ID is used to
determine the host in any network. The default sub-net mask for class B is 255.255.x.x.
Class B has a total of:
• 2^14 = 16384 network address
• 2^16 – 2 = 65534 host address
IP addresses belonging to class B ranges from 128.0.x.x – 191.255.x.x.
Class C
IP address belonging to class C are assigned to small-sized networks.
• The network ID is 24 bits long.
• The host ID is 8 bits long.
The higher order bits of the first octet of IP addresses of class C are always
set to 110. The remaining 21 bits are used to determine network ID. The 8
bits of host ID is used to determine the host in any network. The default sub-
net mask for class C is 255.255.255.x. Class C has a total of:
• 2^21 = 2097152 network address
• 2^8 – 2 = 254 host address
IP addresses belonging to class C ranges from 192.0.0.x – 223.255.255.x.
Class D
IP address belonging to class D are reserved for multi-casting. The
higher order bits of the first octet of IP addresses belonging to class D
are always set to 1110. The remaining bits are for the address that
interested hosts recognize.
Class D does not posses any sub-net mask. IP addresses belonging to
class D ranges from 224.0.0.0 – 239.255.255.255.
Class E
IP addresses belonging to class E are reserved for experimental and research
purposes. IP addresses of class E ranges from 240.0.0.0 – 255.255.255.254.
This class doesn’t have any sub-net mask. The higher order bits of first octet
of class E are always set to 1111.
Range of special IP addresses:
169.254.0.0 – 169.254.0.16 : Link local addresses
127.0.0.0 – 127.0.0.8 : Loop-back addresses
0.0.0.0 – 0.0.0.8 : used to communicate within the current network.
Rules for assigning Host ID:
Host ID’s are used to identify a host within a network. The host ID are
assigned based on the following rules:
• Within any network, the host ID must be unique to that network.
• Host ID in which all bits are set to 0 cannot be assigned because
this host ID is used to represent the network ID of the IP address.
• Host ID in which all bits are set to 1 cannot be assigned because
this host ID is reserved as a broadcast address to send packets to
all the hosts present on that particular network .
Rules for assigning Network ID:
Hosts that are located on the same physical network are identified by the
network ID, as all host on the same physical network is assigned the same
network ID. The network ID is assigned based on the following rules:
• The network ID cannot start with 127 because 127 belongs to
class A address and is reserved for internal loop-back functions.
• All bits of network ID set to 1 are reserved for use as an IP
broadcast address and therefore, cannot be used.
• All bits of network ID set to 0 are used to denote a specific host
on the local network and are not routed and therefore, aren’t used.
Subnet Mask
A subnet mask is a 32-bit number created by setting host bits to all 0s and setting network bits to all 1s.
In this way, the subnet mask separates the IP address into the network and host addresses.
The “255” address is always assigned to a broadcast address, and the “0” address is always assigned to
a network address. Neither can be assigned to hosts, as they are reserved for these special purposes.
Q. Given an IP address of 192.168.10.0 (192.168.10.0/ 27) and subnet mask
255.255.225.224 . Now calculate
a) block size b) Number of Subnet c) Number of valid host d) What are the valid subnets
or subnet id
e)What are the first valid host and last valid host?
f) What’s the broadcast address?
Sol:
a) Number of block size = 256-224= 32
b) Number of subnet = 2x = 23 = 8 ( 224 = 11100000); X= No. of One
c) Number of valid host = 2y – 2 = 25 -2 =30 ( 1st one is network id and last
one is broadcast id)
D)
Subnet id 0 32 64 96 128 160 192 224
1st valid 1 33 65 97 129 161 193 225
host
Last valid 30 62 94 126 158 190 222 254
host
Broadcast 31 63 95 127 159 191 223 255
id
Another Example: