Error/Flow Control Modeling (ARQ Modeling)
Modeling of Go Back N
© Tallal Elshabrawy 3
Limitation of Stop & Wait Protocol
Inefficiency of Stop-and-Wait because the channel is left idle without use until an acknowledgement is received
Potential Solution: Allowing the transmitter to continue sending enough frames
so that the channel is kept busy while the transmitter is waiting for an acknowledgement
Machine A Machine B
Physical Channel
First Frame-Bit enters Channel
Last Frame-Bit enters Channel
First Frame-Bit arrives at B
Last Frame-Bit arrives at B
Last ACK-Bit Arrives at A
Processing Time
Channel is Idle
© Tallal Elshabrawy 4
Go-Back-N ARQ Protocol Sender Receiver
An outstanding frame:It is a frame that has beentransmitted and is yet to beacknowledged
Fr_0
Fr_1
Fr_2
Fr_3
Fr_4
Fr_5
Fr_6
ACK_1
ACK_2
ACK_3
Fr_3
Fr_4
Fr_5
Fr_6
Fr_7
Fr_8
ACK_4
ACK_5
ACK_6
ACK_7
ACK_8
Example Go Back 4
At this Point there are WS=4 Outstanding Frames. So,GO-BACK-4
Out of Sequence Frames. So, do not accept them
© Tallal Elshabrawy 5
Go-Back-N Basics
Transmit without waiting for ACK
Each frame received correctly is acknowledged with a sequence number corresponding to the NEXT frame expected
The receiver discards all out of sequence packets
If number of outstanding frames is WS: Go-Back-N
© Tallal Elshabrawy 6
What does WS Represent?
WS is called the sending window size
Each frame must be buffered (stored) until a valid ACK arrives (in case retransmission is needed)
WS represents the maximum number of frames that may be outstanding (i.e., stored) simultaneously
© Tallal Elshabrawy 7
Sliding Window Concept
Sender Receiver
Fr_0
Fr_1
Fr_2
Fr_3
Fr_4
Fr_5
Fr_6
ACK_1
ACK_2
ACK_3
Example Go Back 4Sending Window
Frame Sequences that are allowed to be sentOutstanding Frame Sequences
Fr_0
Fr_1
Fr_2
Fr_3
Go Back N is an example of what is called a sliding window protocol
An ACK received means that all previous frames have been received correctly (previous ACKs were lost or receiver chose not to send them)
© Tallal Elshabrawy 8
Sliding Window Concept
Sender Receiver
Fr_0
Fr_1
Fr_2
Fr_3
Fr_4
Fr_5
Fr_6
ACK_1
ACK_2
ACK_3
Example Go Back 4Sending Window
Frame Sequences that are allowed to be sentOutstanding Frame Sequences
Fr_0
Fr_1
Fr_2
Fr_3
Go Back N is an example of what is called a sliding window protocol
An ACK received means that all previous frames have been received correctly (previous ACKs were lost or receiver chose not to send them)
© Tallal Elshabrawy 9
Sliding Window Concept
Sender Receiver
Fr_0
Fr_1
Fr_2
Fr_3
Fr_4
Fr_5
Fr_6
ACK_1
ACK_2
ACK_3
Example Go Back 4Sending Window
Frame Sequences that are allowed to be sentOutstanding Frame Sequences
Fr_0
Fr_1
Fr_2
Fr_3
Go Back N is an example of what is called a sliding window protocol
An ACK received means that all previous frames have been received correctly (previous ACKs were lost or receiver chose not to send them)
© Tallal Elshabrawy 10
Sliding Window Concept
Sender Receiver
Fr_0
Fr_1
Fr_2
Fr_3
Fr_4
Fr_5
Fr_6
ACK_1
ACK_2
ACK_3
Example Go Back 4Sending Window
Frame Sequences that are allowed to be sentOutstanding Frame Sequences
Fr_0
Fr_1
Fr_2
Fr_3
Go Back N is an example of what is called a sliding window protocol
An ACK received means that all previous frames have been received correctly (previous ACKs were lost or receiver chose not to send them)
© Tallal Elshabrawy 11
Sliding Window Concept
Sender Receiver
Fr_0
Fr_1
Fr_2
Fr_3
Fr_4
Fr_5
Fr_6
ACK_1
ACK_2
ACK_3
Example Go Back 4Sending Window
Frame Sequences that are allowed to be sentOutstanding Frame Sequences
Fr_1
Fr_2
Fr_3
Fr_4
Go Back N is an example of what is called a sliding window protocol
An ACK received means that all previous frames have been received correctly (previous ACKs were lost or receiver chose not to send them)
© Tallal Elshabrawy 12
Sliding Window Concept
Sender Receiver
Fr_0
Fr_1
Fr_2
Fr_3
Fr_4
Fr_5
Fr_6
ACK_1
ACK_2
ACK_3
Example Go Back 4Sending Window
Frame Sequences that are allowed to be sentOutstanding Frame Sequences
Fr_2
Fr_3
Fr_4
Fr_5
Go Back N is an example of what is called a sliding window protocol
An ACK received means that all previous frames have been received correctly (previous ACKs were lost or receiver chose not to send them)
© Tallal Elshabrawy 13
Sliding Window Concept
Sender Receiver
Fr_0
Fr_1
Fr_2
Fr_3
Fr_4
Fr_5
Fr_6
ACK_1
ACK_2
ACK_3
Example Go Back 4Sending Window
Frame Sequences that are allowed to be sentOutstanding Frame Sequences
Fr_3
Fr_4
Fr_5
Fr_6
Go Back N is an example of what is called a sliding window protocol
An ACK received means that all previous frames have been received correctly (previous ACKs were lost or receiver chose not to send them)
© Tallal Elshabrawy 14
Sliding Window Concept
Sender Receiver
Fr_0
Fr_1
Fr_2
Fr_3
Fr_4
Fr_5
Fr_6
ACK_1
ACK_2
ACK_3
Example Go Back 4Sending Window
Frame Sequences that are allowed to be sentOutstanding Frame Sequences
Fr_4
Fr_5
Fr_6
Fr_7ACK_4
Transmitter has nothing to send
Go Back N is an example of what is called a sliding window protocol
An ACK received means that all previous frames have been received correctly (previous ACKs were lost or receiver chose not to send them)
© Tallal Elshabrawy
Go-Back-N ARQ Modeling
15
Machine A Machine B
Physical Channel
Assumptions
Forward Channel BER
Backward Channel (i.e., ACK/NAK) is Error Free
Infinite number of retransmissions
© Tallal Elshabrawy
Go-Back-N ARQ Markov Model
16
Model DetailsThe time step is equal to
Probability of packet error
ForDefine as the probability of Define as the transition
probability from to
𝒔𝟏 𝒔𝟐 𝒔𝟑 𝒔𝑵𝟏 𝟏 𝒔𝑵 −𝟏
𝟏
𝟏−𝒑𝒆
𝒑𝒆
𝚷=[𝝅𝟏 𝝅𝟐 𝝅𝟑 … 𝝅𝑵 ]
𝚫=[𝜹𝟏 ,𝟏 𝜹𝟏 ,𝟐 … 𝜹𝟏 ,𝑵 −𝟏 𝜹𝟏,𝑵
𝜹𝟐 ,𝟏 𝜹𝟐 ,𝟐 … 𝜹𝟐 ,𝑵 −𝟏 𝜹𝟐,𝑵
⋮ ⋮ ⋮ ⋮ ⋮𝜹𝑵 −𝟏 ,𝟏 𝜹𝑵−𝟏 ,𝟐 … 𝜹𝑵−𝟏,𝑵 −𝟏 𝜹𝑵 −𝟏 ,𝑵
𝜹𝑵 ,𝟏 𝜹𝑵 ,𝟐 … 𝜹𝑵 ,𝑵−𝟏 𝜹𝑵 ,𝑵
]
© Tallal Elshabrawy
Go-Back-N ARQ Markov Model
17
𝚷=[𝝅𝟏 𝝅𝟐 𝝅𝟑 … 𝝅𝑵 ]
𝚫=[𝟎 𝟏 𝟎 … 𝟎 𝟎𝟎 𝟎 𝟏 … 𝟎 𝟎⋮ ⋮ ⋮ ⋮ ⋮ ⋮𝟎 𝟎 𝟎 … 𝟎 𝟏𝒑𝒆 𝟎 𝟎 … 𝟎 𝟏−𝒑𝒆
]At steady State
With boundary condition
Solving:
𝒔𝟏 𝒔𝟐 𝒔𝟑 𝒔𝑵𝟏 𝟏 𝒔𝑵 −𝟏
𝟏
𝟏−𝒑𝒆
𝒑𝒆
© Tallal Elshabrawy
Go-Back-N ARQ Throughput
18
Throughput measures the percentage of time slots that are utilized for successful transmissions 𝒔𝟏 𝒔𝟐 𝒔𝟑 𝒔𝑵
𝟏 𝟏 𝒔𝑵 −𝟏𝟏
𝟏−𝒑𝒆
𝒑𝒆
© Tallal Elshabrawy
S/W and GBN Comparison
19
0 0.1 0.2 0.3 0.4 0.50.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
0.9
1Throughput of S/W and GBN
Probability of Packet Error pe
Th
rou
gh
pu
t
S/W t0/t
pk=4
S/W t0/t
pk=2
GBN t0/t
pk=4
GBN t0/t
pk=2