r2017 CN Lab Manual
r2017 CN Lab Manual
LABORATORY
LAB MANUAL
(Regulation 2017)
LIST OF EXPERIMENTS:
THEORY:
Introduction to NS-2:
Widely known as NS2, is simply an event driven simulation tool.
Useful in studying the dynamic nature of communication networks.
Simulation of wired as well as wireless network functions and protocols (e.g., routing
algorithms, TCP, UDP) can be done using NS2.
In general, NS2 provides users with a way of specifying such network protocols and
simulating their corresponding behaviors.
Tcl scripting
• Tcl is a general purpose scripting language. [Interpreter]
• Tcl runs on most of the platforms such as Unix, Windows, and Mac.
• The strength of Tcl is its simplicity.
• It is not necessary to declare a data type for variable prior to the usage.
Basics of TCL
Syntax: command arg1 arg2 arg3
Hello World!
puts stdout{Hello, World!}
Hello, World!
Variables Command Substitution
set a 5 set len [string length foobar]
set b $a set len [expr [string length foobar] + 9]
Simple
Arithmetic
expr 7.2 / 4
Procedures
proc Diag {a b} {
set c [expr sqrt($a * $a + $b * $b)]
return $c }
puts ―Diagonal of a 3, 4 right triangle is [Diag 3
4]‖ Output: Diagonal of a 3, 4 right triangle is 5.0
Loops
while{$i < $n} { for {set i 0} {$i < $n} {incr i} {
... ...
} }
Wired TCL Script Components
Create the event scheduler
Open new files & turn on the tracing
Create the nodes
Setup the links
Configure the traffic type (e.g., TCP, UDP, etc)
Set the time of traffic generation (e.g., CBR, FTP)
Terminate the simulation
NS Simulator Preliminaries.
1. Initialization and termination aspects of the ns simulator.
2. Definition of network nodes, links, queues and topology.
3. Definition of agents and of applications.
4. The nam visualization tool.
5. Tracing and random variables.
Initialization and Termination of TCL Script in NS-2
An ns simulation starts with the command
Which is thus the first line in the tcl script? This line declares a new variable as using the set
command, you can call this variable as you wish, In general people declares it as ns because it is
an instance of the Simulator class, so an object the code[new Simulator] is indeed the installation
of the class Simulator using the reserved word new.
In order to have output files with data on the simulation (trace files) or files used for
visualization (nam files), we need to create the files using ―open‖ command:
#Open the Trace file
set tracefile1 [open out.tr w]
The above creates a dta trace file called ―out.tr‖ and a nam visualization trace file called
―out.nam‖.Within the tcl script,these files are not called explicitly by their names,but instead by
pointers that are declared above and called ―tracefile1‖ and ―namfile‖ respectively.Remark that
they begins with a # symbol.The second line open the file ―out.tr‖ to be used for
writing,declared with the letter ―w‖.The third line uses a simulator method called trace-all that
have as parameter the name of the file where the traces will go.
The last line tells the simulator to record all simulation traces in NAM input format.It
also gives the file name that the trace will be written to later by the command $ns flush-trace.In
our case,this will be the file pointed at by the pointer ―$namfile‖,i.e the file ―out.tr‖.
The termination of the program is done using a ―finish‖ procedure.
#Define a „finish‟ procedure
Proc finish { } {
$ns flush-trace
Close $tracefile1
Close $namfile
Exit 0
The word proc declares a procedure in this case called finish and without arguments. The
word global is used to tell that we are using variables declared outside the procedure. The
simulator method ―flush-trace” will dump the traces on the respective files. The tcl command
―close” closes the trace files defined before and exec executes the nam program for
visualization. The command exit will ends the application and return the number 0 as status to
the system. Zero is the default for a clean exit. Other values can be used to say that is a exit
because something fails.
At the end of ns program we should call the procedure ―finish‖ and specify at what time
the termination should occur. For example,
$ns at 125.0 “finish”
will be used to call ―finish‖ at time 125sec.Indeed,the at method of the simulator allows us to
schedule events explicitly.
The simulation can then begin using the command
$ns run
Which means that $n0 and $n2 are connected using a bi-directional link that has 10ms of
propagation delay and a capacity of 10Mb per sec for each direction.
To define a directional link instead of a bi-directional one, we should replace ―duplex-
link‖ by ―simplex-link‖.
In NS, an output queue of a node is implemented as a part of each link whose input is that
node. The definition of the link then includes the way to handle overflow at that queue. In our
case, if the buffer capacity of the output queue is exceeded then the last packet to arrive is
dropped. Many alternative options exist, such as the RED (Random Early Discard) mechanism,
the FQ (Fair Queuing), the DRR (Deficit Round Robin), the stochastic Fair Queuing (SFQ) and
the CBQ (which including a priority and a round-robin scheduler).
In ns, an output queue of a node is implemented as a part of each link whose input is that
node. We should also define the buffer capacity of the queue related to each link. An example
would be:
#set Queue Size of link (n0-n2) to 20
Scheduling Events
NS is a discrete event based simulation. The tcp script defines when event should occur.
The initializing command set ns [new Simulator] creates an event scheduler, and events are then
scheduled using the format:
$ns at <time> <event>
The scheduler is started when running ns that is through the command $ns run.
The beginning and end of the FTP and CBR application can be done through the following
command
$ns at 0.1 “$cbr start”
1. The first field is the event type. It is given by one of four possible symbols r, +, -, d which
correspond respectively to receive (at the output of the link), enqueued, dequeued and dropped.
2. The second field gives the time at which the event occurs.
3. Gives the input node of the link at which the event occurs.
4. Gives the output node of the link at which the event occurs.
5. Gives the packet type (eg CBR or TCP)
6. Gives the packet size
7. Some flags
8. This is the flow id (fid) of IPv6 that a user can set for each flow at the input OTcl script one can
further use this field for analysis purposes; it is also used when specifying stream color for the
NAM display.
9. This is the source address given in the form of ―node.port‖.
10. This is the destination address, given in the same form.
11. This is the network layer protocol’s packet sequence number. Even though UDP
implementations in a real network do not use sequence number, ns keeps track of UDP packet
sequence number for analysis purposes
12. The last field shows the Unique id of the packet.
VIVA QUESTIONS:
1. What protocols does ns support?
2. What Is Simulation?
3. Define Network
4. What is meant by Protocol?
5. What are the constituent parts of NS2?
RESULT:
AIM:
To create scenario and study the performance of token bus protocol through simulation.
THEORY:
Token bus is a LAN protocol operating in the MAC layer. Token bus is standardized as per IEEE 802.4. Token
bus can operate at speeds of 5Mbps, 10 Mbps and 20 Mbps. The operation of token bus is as follows: Unlike
token ring in token bus the ring topology is virtually created and maintained by the protocol. A node can receive
data even if it is not part of the virtual ring, a node joins the virtual ring only if it has data to transmit. In token
bus data is transmitted to the destination node only where as other control frames is hop to hop. After each data
transmission there is a solicit_successsor control frame transmitted which reduces the performance of the
protocol.
ALGORITHM:
PROGRAM:
OUTPUT:
RESULT:
Thus the Bus Topology was Simulated and studied.
XPT.NO.2b NETWORK TOPOLOGY
DATE: RING TOPOLOGY
AIM:
To create scenario and study the performance of token ring protocols through simulation.
THEORY:
Token ring is a LAN protocol operating in the MAC layer. Token ring is standardized as per IEEE 802.5. Token
ring can operate at speeds of 4mbps and 16 mbps. The operation of token ring is as follows: When there is no
traffic on the network a simple 3-byte token circulates the ring. If the token is free (no reserved by a station of
higher priority as explained later) then the station may seize the token and start sending the data frame. As the
frame travels around the ring ach station examines the destination address and is either forwarded (if the
recipient is another node) or copied. After copying4 bits of the last byte is changed. This packet then continues
around the ring till it reaches the originating station. After the frame makes a round trip the sender receives the
frame and releases a new token onto the ring.
ALGORITHM:
PROGRAM:
OUTPUT:
RESULT:
Thus the Ring Topology was simulated and studied.
2c
NETWORK TOPOLOGY
STAR TOPOLOGY
AIM:
To create scenario and study the performance of token ring protocols through simulation.
THEORY:
Star networks are one of the most common computer network topologies. In its simplest form, a star
network consists of one central switch, hub or computer, which acts as a conduit to transmit messages.
This consists of a central node, to which all other nodes are connected; this central node provides a
common connection point for all nodes through a hub. In star topology, every node (computer
workstation or any other peripheral) is connected to a central node called a hub or switch. The switch is
the server and the peripherals are the clients. Thus, the hub and leaf nodes, and the transmission lines
between them, form a graph with the topology of a star. If the central node is passive, the originating
node must be able to tolerate the reception of an echo of its own transmission, delayed by the two-way
transmission time (i.e. to and from the central node) plus any delay generated in the central node. An
active star network has an active central node that usually has the means to prevent echo-related
problems
The star topology reduces the damage caused by line failure by connecting all of the systems to a
central node. When applied to a bus-based network, this central hub rebroadcasts all transmissions
received from any peripheral node to all peripheral nodes on the network, sometimes including the
originating node. All peripheral nodes may thus communicate with all others by transmitting to, and
receiving from, the central node only. The failure of a transmission line linking any peripheral node to
the central node will result in the isolation of that peripheral node from all others, but the rest of the
systems will be unaffected.
ALGORITHM:
PROGRAM:
#Create a simulator object
set ns [new Simulator]
}
#Create six nodes
set n0 [$ns node]
set n1 [$ns node]
set n2 [$ns node]
set n3 [$ns node]
set n4 [$ns node]
set n5 [$ns node]
OUTPUT:
RESULT:
Thus the star Topology was simulated and studied.
Ex.No. 3
IMPLEMENTATION OF DISTANCE VECTOR ROUTING ALGORITHM
AIM:
To simulate and study the Distance Vector routing algorithm using simulation.
SOFTWARE REQUIRED:
NS-2
THEORY:
Distance Vector Routing is one of the routing algorithm in a Wide Area Network for computing shortest
path between source and destination. The Router is one main devices used in a wide area network. The
main task of the router is Routing. It forms the routing table and delivers the packets depending upon the
routes in the tableeither directly or via an intermediate devices. Each router initially has information about
its all neighbors. Then this information will be shared among nodes.
ALGORITHM:
1. Create a simulator object
2. Define different colors for different data flows
3. Open a nam trace file and define finish procedure then close the trace file, and execute nam on trace
file.
4. Create n number of nodes using for loop
5. Create duplex links between the nodes
6. Setup UDP Connection between n(0) and n(5)
7. Setup another UDP connection between n(1) and n(5)
8. Apply CBR Traffic over both UDP connections
9. Choose distance vector routing protocol to transmit data from sender to receiver.
10. Schedule events and run the program.
PROGRAM:
set ns [new Simulator]
set nr [open thro.tr w]
$ns trace-all $nr
set nf [open thro.nam w]
$ns namtrace-all $nf
proc finish { } {
global ns nr nf
$ns flush-trace
close $nf
close $nr
exec nam thro.nam &
exit 0
}
for { set i 0 } { $i < 12} { incr i 1 } {
set n($i) [$ns node]}
for {set i 0} {$i < 8} {incr i} {
$ns duplex-link $n($i) $n([expr $i+1]) 1Mb 10ms DropTail }
$ns duplex-link $n(0) $n(8) 1Mb 10ms DropTail
$ns duplex-link $n(1) $n(10) 1Mb 10ms DropTail
GRT INSTITUTE OF ENGINEERING AND TECHNOLOGY
$ns duplex-link $n(0) $n(9) 1Mb 10ms DropTail
$ns duplex-link $n(9) $n(11) 1Mb 10ms DropTail
$ns duplex-link $n(10) $n(11) 1Mb 10ms DropTail
$ns duplex-link $n(11) $n(5) 1Mb 10ms DropTail
set udp0 [new Agent/UDP]
$ns attach-agent $n(0) $udp0
set cbr0 [new Application/Traffic/CBR]
$cbr0 set packetSize_ 500
$cbr0 set interval_ 0.005
$cbr0 attach-agent $udp0
set null0 [new Agent/Null]
$ns attach-agent $n(5) $null0
$ns connect $udp0 $null0
set udp1 [new Agent/UDP]
$ns attach-agent $n(1) $udp1
set cbr1 [new Application/Traffic/CBR]
$cbr1 set packetSize_ 500
$cbr1 set interval_ 0.005
$cbr1 attach-agent $udp1
set null0 [new Agent/Null]
$ns attach-agent $n(5) $null0
$ns connect $udp1 $null0
$ns rtproto DV
$ns rtmodel-at 10.0 down $n(11) $n(5)
$ns rtmodel-at 15.0 down $n(7) $n(6)
$ns rtmodel-at 30.0 up $n(11) $n(5)
$ns rtmodel-at 20.0 up $n(7) $n(6)
$udp0 set fid_ 1
$udp1 set fid_ 2
$ns color 1 Red
$ns color 2 Green
$ns at 1.0 "$cbr0 start"
$ns at 2.0 "$cbr1 start"
$ns at 45 "finish"
$ns run
OUTPUT:
Prelab Questions
1. What is Routing?
2. Describe about the Design Goals of Routing
3. What is a distance vector routing protocol?
4. List the common characteristics of DVR
Post Lab Questions
1. Name several problems associated with distance vector protocols
2. What is counting-to-infinity problem, and how can it be controlled?
3. Describe about the various Routing Metrics
4. Compare connection oriented and connection less protocols.
5.What is MTU?
6.Differentiate Proactive and Reactive routing Protocols.
7.What are the different attributes for calculating the cost of a path?
RESULT:Thus the Distance vector Routing Algorithm was Simulated and studied.
Ex.No. 3
SIMULATION OF STOP AND WAIT PROTOCOL AND SLIDING WINDOW
PROTOCOL
AIM:
To Simulate and to study stop and Wait protocol
SOFTWARE REQUIREMENTS:
NS-2 Simulator
THEORY:
Stop and Wait is a reliable transmission flow control protocol. This protocol works only in Connection Oriented
(Point to Point) Transmission. The Source node has window size of ONE. After transmission of a frame the
transmitting (Source) node waits for an Acknowledgement from the destination node. If the transmitted frame
reaches the destination without error, the destination transmits a positive acknowledgement. If the transmitted
frame reaches the Destination with error, the receiver destination does not transmit an acknowledgement. If the
transmitter receives a positive acknowledgement it transmits the next frame if any. Else if its acknowledgement
receive timer expires, it retransmits the same frame.
1. Start with the window size of 1 from the transmitting (Source) node
2. After transmission of a frame the transmitting (Source) node waits for a reply (Acknowledgement) from
the receiving (Destination) node.
3. If the transmitted frame reaches the receiver (Destination) without error, the receiver (Destination)
transmits a Positive Acknowledgement.
4. If the transmitted frame reaches the receiver (Destination) with error, the receiver (Destination) do
not transmit acknowledgement.
5. If the transmitter receives a positive acknowledgement it transmits the next frame if any. Else if
the transmission timer expires, it retransmits the same frame again.
6. If the transmitted acknowledgment reaches the Transmitter (Destination) without error, the
Transmitter (Destination) transmits the next frame if any.
7. If the transmitted frame reaches the Transmitter (Destination) with error, the Transmitter
(Destination) transmits the same frame.
8. This concept of the Transmitting (Source) node waiting after transmission for a reply from the receiver
is known as STOP and WAIT.
ALGORITHM:
OUTPUT:
THEORY:
A sliding window protocol is a feature of packet-based data transmission protocols. Sliding window protocols
are used where reliable in-order delivery of packets is required, such as in the Data Link Layer (OSI model) as
well as in the Transmission Control Protocol (TCP).
Conceptually, each portion of the transmission (packets in most data link layers, but bytes in TCP) is assigned
a unique consecutive sequence number, and the receiver uses the numbers to place received packets in the
correct order, discarding duplicate packets and identifying missing ones. The problem with this is that there is
no limit on the size of the sequence number that can be required.
By placing limits on the number of packets that can be transmitted or received at any given time, a sliding
window protocol allows an unlimited number of packets to be communicated using fixed-size sequence
numbers. The term "window" on the transmitter side represents the logical boundary of the total number of
packets yet to be acknowledged by the receiver. The receiver informs the transmitter in each acknowledgment
packet the current maximum receiver buffer size (window boundary). The TCP header uses a 16 bit field to
report the receive window size to the sender. Therefore, the largest window that can be used is 216 = 64
kilobytes. In slow-start mode, the transmitter starts with low packet count and increases the number of packets
in each transmission after receiving acknowledgment packets from receiver. For every ack packet received, the
window slides by one packet (logically) to transmit one new packet. When the window threshold is reached, the
transmitter sends one packet for one ack packet received. If the window limit is 10 packets then in slow start
mode the transmitter may start transmitting one packet followed by two packets (before transmitting two
packets, one packet ack has to be received), followed by three packets and so on until 10 packets. But after
reaching 10 packets, further transmissions are restricted to one packet transmitted for one ack packet received.
In a simulation this appears as if the window is moving by one packet distance for every ack packet received.
On the receiver side also the window moves one packet for every packet received. The sliding window method
ensures that traffic congestion on the network is avoided. The application layer will still be offering data for
transmission to TCP without worrying about the network traffic congestion issues as the TCP on sender and
receiver side implement sliding windows of packet buffer. The window size may vary dynamically depending
on network traffic.
For the highest possible throughput, it is important that the transmitter is not forced to stop sending by the
sliding window protocol earlier than one round-trip delay time (RTT). The limit on the amount of data that it
can send before stopping to wait for an acknowledgment should be larger than the bandwidth-delay product of
the communications link. If it is not, the protocol will limit the effective bandwidth of the link.
OUTPUT:
VIVA QUESTIONS:
1.What is ARQ?
2.What is stop and wait protocol?
3.What is stop and wait ARQ?
4.What is usage of sequence number in reliable transmission?
5.What is sliding window?
RESULT:
Thus the Stop and Wait protocol and Sliding window Protocols are Simulated and studied
STUDY OF HIGH-LEVEL DATA LINK CONTROL
AIM:
To study the concept and different frames of HDLC protocol.
THEORY:
High-Level Data Link Control (HDLC) is a bit-oriented code-transparentsynchronous data link
layer protocol developed by the International Organization for Standardization (ISO) .
The original ISO standards for HDLC are:
1. ISO 3309 – Frame Structure
2. ISO 4335 – Elements of Procedure
3. ISO 6159 – Unbalanced Classes of Procedure
4. ISO 6256 – Balanced Classes of Procedure
The current standard for HDLC is ISO 13239, which replaces all of those standards.HDLC provides both
connection-oriented and connectionless service. HDLC can be used for point to multipoint connections, but is
now used almost exclusively to connect one device to another, using what is known asAsynchronous Balanced
Mode (ABM). The original master-slave modes Normal Response Mode (NRM) and Asynchronous Response
Mode (ARM) are rarely used.HDLC is based on IBM's SDLC protocol, which is the layer 2 protocol
for IBM's Systems Network Architecture (SNA). It was extended and standardized by the ITU as LAP,
while ANSI named their essentially identical version ADCCP.
Derivatives have since appeared in innumerable standards. It was adopted into the X.25 protocol stack
as LAPB, into the V.42protocol as LAPM, into the Frame Relay protocol stack as LAPF and into
the ISDN protocol stack as LAPD.HDLC was the inspiration for the IEEE 802.2 LLC protocol, and it is the
basis for the framing mechanism used with the PPP on synchronous lines, as used by many servers to connect to
a WAN, most commonly the Internet. A mildly different version is also used as the control channel for E-carrier
(E1) and SONET multichannel telephone lines. Some vendors, such as Cisco, implemented protocols such as
Cisco HDLC that used the low-level HDLC framing techniques but added a protocol field to the standard
HDLC header. More importantly, HDLC is the default encapsulation for serial interfaces on Cisco routers. It
has also been used on Tellabs DXX for destination of Trunk.
FRAMING
HDLC frames can be transmitted over synchronous or asynchronous serial communication links. Those links
have no mechanism to mark the beginning or end of a frame, so the beginning and end of each frame has to be
identified. This is done by using a frame delimiter, or flag, which is a unique sequence of bits that is guaranteed
not to be seen inside a frame. This sequence is '01111110', or, in hexadecimal notation, 0x7E. Each frame
begins and ends with a frame delimiter. A frame delimiter at the end of a frame may also mark the start of the
next frame. A sequence of 7 or more consecutive 1-bits within a frame will cause the frame to be aborted.
When no frames are being transmitted on a simplex or full-duplex synchronous link, a frame delimiter is
continuously transmitted on the link. Using the standard NRZI encoding from bits to line levels (0 bit =
transition, 1 bit = no transition), this generates one of two continuous waveforms, depending on the initial state:
This is used by modems to train and synchronize their clocks via phase-locked loops. Some protocols allow the
0-bit at the end of a frame delimiter to be shared with the start of the next frame delimiter, i.e.
'011111101111110'.
For half-duplex or multi-drop communication, where several transmitters share a line, a receiver on the line will
see continuous idling 1-bits in the inter-frame period when no transmitter is active.
Since the flag sequence could appear in user data, such sequences must be modified during transmission to keep
the receiver from detecting a false frame delimiter. The receiver must also detect when this has occurred so that
the original data stream can be restored before it is passed to higher layer protocols. This can be done using bit
stuffing, in which a "0" is added after the occurrence of every "11111" in the data. When the receiver detects
these "11111" in the data, it removes the "0" added by the transmitter.
ALGORITHM:
PROGRAM
OUTPUT:
VIVA QUESTIONS:
RESULT:
AIM:
To create scenario and study the performance of CSMA / CD protocol through simulation.
SOFTWARE REQUIREMENTS:
Ns-2
THEORY:
Ethernet is a LAN (Local area Network) protocol operating at the MAC (Medium Access Control) layer.
Ethernet has been standardized as per IEEE 802.3. The underlying protocol in Ethernet is known as the
CSMA / CD – Carrier Sense Multiple Access / Collision Detection. The working of the Ethernet protocol
is as explained below, A node which has data to transmit senses the channel. If the channel is idle then,
the data is transmitted. If the channel is busy then, the station defers transmission until the channel is
sensed to be idle and then immediately transmitted. If more than one node starts data transmission at the
same time, the data collides. This collision is heard by the transmitting nodes which enter into contention
phase. The contending nodes resolve contention using an algorithm called Truncated binary exponential
back off.
ALGORITHM:
PROGRAM:
CSMA/CA
OUTPUT:
CSMA/CD
VIVA QUESTIONS:
RESULT:
AIM:
To Simulate and to study of Go Back N protocol
SOFTWARE REQUIREMENTS:
1. NS-2 Simulator
THEORY:
Go Back N is a connection oriented transmission. The sender transmits the frames continuously. Each frame in
the buffer has a sequence number starting from 1 and increasing up to the window size. The sender has a
window i.e. a buffer to store the frames. This buffer size is the number of frames to be transmitted continuously.
The size of the window depends on the protocol designer.
OPERATIONS:
8. The source node retransmits all frames of window from the first error frame.
9. If the frames are errorless in the next transmission and if the acknowledgment is error free, the window
slides by the number of error-free frames being transmitted.
10.If the acknowledgment is transmitted with error, all the frames of window at source are retransmitted, and
window doesn’t slide.
11. This concept of repeating the transmission from the first error frame in the window is called as GOBACKN
transmission flow control protocol
OUTPUT:
Selective Repeat ARQ is a specific instance of the Automatic Repeat-reQuest (ARQ) Protocol. It may be used
as a protocol for the delivery and acknowledgement of message units, or it may be used as a protocol for the
delivery of subdivided message sub-units. When used as the protocol for the delivery of messages, the sending
process continues to send a number of frames specified by a window size even after a frame loss. Unlike Go-
Back-N ARQ, the receiving process will continue to accept and acknowledge frames sent after an initial error.
The receiver process keeps track of the sequence number of the earliest frame it has not received, and sends that
number with every ACK it sends. If a frame from the sender does not reach the receiver, the sender continues to
send subsequent frames until it has emptied its window. The receiver continues to fill its receiving window with
the subsequent frames, replying each time with an ACK containing the sequence number of the earliest missing
frame. Once the sender has sent all the frames in its window, it re-sends the frame number given by the ACKs,
and then continues where it left off. The size of the sending and receiving windows must be equal, and half the
maximum sequence number (assuming that sequence numbers are numbered from 0 to n-1) to avoid
miscommunication in all cases of packets being dropped. To understand this, consider the case when all ACKs
are destroyed. If the receiving window is larger than half the maximum sequence number, some, possibly even
all, of the packages that are resent after timeouts are duplicates that are not recognized as such. The sender
moves its window for every packet that is acknowledged.
Advantage over Go Back N:
1. Fewer retransmissions.
Disadvantages:
1. More complexity at sender and receiver
2. Receiver may receive frames out of sequence
VIVA QUESTIONS:
OUTPUT:
RESULT:
Thus the Go back N and Selective Repeat protocols were Simulated and studied.