Download ARQ Modeling (1)

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the work of artificial intelligence, which forms the content of this project

Document related concepts

Asynchronous Transfer Mode wikipedia , lookup

Cracking of wireless networks wikipedia , lookup

Internet protocol suite wikipedia , lookup

Recursive InterNetwork Architecture (RINA) wikipedia , lookup

Wake-on-LAN wikipedia , lookup

Serial digital interface wikipedia , lookup

IEEE 802.11 wikipedia , lookup

Deep packet inspection wikipedia , lookup

RapidIO wikipedia , lookup

CAN bus wikipedia , lookup

IEEE 1355 wikipedia , lookup

UniPro protocol stack wikipedia , lookup

Transcript
Error/Flow Control Modeling
(ARQ Modeling)
Data Link Layer
 Data Link Layer provides a
service for Network Layer
(transfer of data from the
network layer of a sender to
the network layer of a
receiver)
 Data Link Layer uses the
Physical Layer to transmit
bits of Data Link Frames
over the physical medium
© Tallal Elshabrawy
Network
LLC
MAC
Physical
2
Data Link Layer Functions
 Framing (Grouping Bits into Frames)
 Error Control
 Flow Control
 Medium Access Control
© Tallal Elshabrawy
3
Bit Errors in Communication Systems
 At the physical layer, bit errors are inevitable to
occur with small but non zero probability, example:
 Bit error probability in the order of 10-6 for systems using copper
wires
 Bit error probability in the order of 10-9 for modern optical fiber
systems
 High bit error probability in the order of 10-3 for wireless
transmission systems
 Some services are tolerant to relatively high bit error rates
such as digital speech transmission
 Some applications must experience error-free
communications such as electronic funds transfer
© Tallal Elshabrawy
4
Error Control
 Error Control is a system
to deal with errors that
occur due to disturbances
on the physical channel.
 Components of an error
control system:
Data
Frame 0
Timer
 Timers
© Tallal Elshabrawy
No Errors
0
1
1
Errors
No Errors
Detection/
Correction
ACK
Frame is Good
 Error Correction and
Detection
 Acknowledgement (ACK) &
Non- Acknowledgement
Control Messages (NAK)
Receiver
Sender
1
Detection/
Correction
1
Detection/
Correction
ACK
Frame is Good
5
Error Control Mechanisms
 Forward Error Correction (FEC)
 Detection of erroneous frames or packets
 Processing of received frame bits in attempt to correct
the errors
 Automatic Retransmission reQuest (ARQ)
 Detection of erroneous frames or packets
 Retransmission of erroneous frames with the hope that
no errors would occur in the next attempt
© Tallal Elshabrawy
6
Automatic Repeat reQuest (ARQ) Protocols
Purpose: to ensure a sequence of information
packets is delivered in order and without errors or
duplications despite transmission errors & losses
(Error Control & Flow Control)
© Tallal Elshabrawy
7
Modeling of Stop and Wait Protocol
Stop-and-Wait ARQ
 Stop after Transmitting a Packet
 Wait for an Acknowledgement
Packet
Information Frame
CRC
H
Transmitter
Error Free
Packet
Receiver
H CRC
ACK
H
CRC
© Tallal Elshabrawy
: Header
: Cyclic Redundancy Check
(Error Detection)
9
Stop-and-Wait ARQ Operation
Machine B
Machine A
Physical Channel
First Packet-Bit
enters Channels
Last Packet-Bit
enters Channels
Channel
is Idle
First Packet-Bit
arrives at B
Last Packet-Bit
arrives at B
Processing Time for
Error Detection
Last ACK-Bit
Arrives at A
© Tallal Elshabrawy
10
Stop-and-Wait ARQ Operation
Machine B
Machine A
Physical Channel
© Tallal Elshabrawy
11
Stop-and-Wait ARQ Modeling
Machine A
Assumptions
 𝑳𝒂 ≪ 𝑳𝒑𝒌 , 𝒕𝒂 ≪ 𝒕𝒑𝒌 ⇒ 𝒕𝒂 ≈ 𝟎
Machine B
Physical Channel
 𝒕𝒑𝒓𝒐𝒄 ↓↓ ⇒ 𝒕𝒑𝒓𝒐𝒄 ≈ 𝟎
 Forward Channel BER 𝝐
 Backward Channel (i.e.,
ACK/NAK) is Error Free
 Infinite number of
retransmissions
© Tallal Elshabrawy
12
Stop-and-Wait ARQ Markov Model
Model Details
 State 𝒔𝒌 corresponds to 𝒌
retransmissions of a given
packet
 The time step is equal to 𝒕𝟎
 Transition probabilities are
governed by probability of
packet error 𝒑𝒆
 𝒑𝒆 = 𝟏 − 𝟏 − 𝝐
 𝒑𝒆 = 𝟏 − 𝟏 −
𝑳𝒑𝒌
𝑳𝒑𝒌
𝑳
𝝐 + 𝒑𝒌 𝝐𝟐 − ⋯
𝟏
𝟐
 For 𝝐𝑳𝒑𝒌 ≪ 𝟏 ⇒ 𝒑𝒆 ≈ 𝝐𝑳𝒑𝒌
 Define 𝝅𝒌 as the probability of 𝒔𝒌
 Define 𝜹𝒌𝒋 as the transition
probability from 𝒔𝒌 to 𝒔𝒋
© Tallal Elshabrawy
13
Stop-and-Wait ARQ Markov Model
𝚫=
𝟏 − 𝒑𝒆
𝟏 − 𝒑𝒆
𝟏 − 𝒑𝒆
⋮
𝒑𝒆
𝟎
𝟎
⋮
𝟎
𝒑𝒆
𝟎
⋮
𝟎
𝟎
𝒑𝒆
⋮
…
…
…
⋱
At steady State
𝚷×𝚫=𝚷
With boundary condition
∞
𝝅𝒌 = 𝟏
𝒌=𝟎
Solving:
𝚷 = 𝟏 − 𝒑𝒆 × 𝟏 𝒑𝒆
© Tallal Elshabrawy
𝒑𝟐𝒆
…
14
Stop-and-Wait ARQ Performance
Average number of
retransmissions per packet 𝑵𝒓𝒕
𝑷𝒓 𝑵𝒓𝒕 = 𝟎 = 𝟏 − 𝒑𝒆
𝑷𝒓 𝑵𝒓𝒕 = 𝟏 = 𝒑𝒆 × 𝟏 − 𝒑𝒆
𝑷𝒓 𝑵𝒓𝒕 = 𝟐 = 𝒑𝟐𝒆 × 𝟏 − 𝒑𝒆
⋮
∞
𝑵𝒓𝒕 = 𝑬 𝑵𝒓𝒕 =
𝒌=𝟎
∞
∞
𝒌 × 𝟏 − 𝒑𝒆 × 𝒑𝒌𝒆
𝑵𝒓𝒕 =
𝒌=𝟎
∞
𝒌 × 𝒑𝒌𝒆
𝑵𝒓𝒕 = 𝟏 − 𝒑𝒆 ×
𝒌 × 𝟏 − 𝒑𝒆 × 𝒑𝒌𝒆
𝑵𝒓𝒕 =
𝒌=𝟎
𝑵𝒓𝒕
𝒌 𝑷𝒓 𝑵𝒓𝒕 = 𝒌
𝒑𝒆
=
𝟏 − 𝒑𝒆
© Tallal Elshabrawy
𝒌=𝟎
𝑵𝒓𝒕 = 𝟏 − 𝒑𝒆 × 𝒑𝒆 + 𝟐𝒑𝟐𝒆 + 𝟑𝒑𝟑𝒆 + ⋯
𝒑𝒆 + 𝒑𝟐𝒆 + 𝒑𝟑𝒆 + ⋯
𝑵𝒓𝒕 = 𝟏 − 𝒑𝒆 ×
+ 𝒑𝟐𝒆 +𝒑𝟑𝒆 + ⋯
+𝒑𝟑𝒆 + ⋯
𝒑𝒆
𝒑𝟐𝒆
𝒑𝟑𝒆
𝑵𝒓𝒕 = 𝟏 − 𝒑𝒆 ×
+
+
+⋯
𝟏 − 𝒑𝒆 𝟏 − 𝒑𝒆 𝟏 − 𝒑𝒆
𝒑𝒆
𝑵𝒓𝒕 = 𝟏 − 𝒑𝒆 ×
𝟏 − 𝒑𝒆 𝟐
𝒑𝒆
𝑵𝒓𝒕 =
𝟏 − 𝒑𝒆
15
Stop-and-Wait ARQ Efficiency
Efficiency measures number of
transmissions required to send
one packet 𝜼
𝟏
𝜼=
𝒑𝒆 = 𝟏 − 𝒑𝒆
𝟏+
𝟏 − 𝒑𝒆
For 𝒑𝒆 ≪ 𝟏 & 𝝐𝑳𝒑𝒌 ≪ 𝟏
𝜼 = 𝟏 − 𝒑𝒆 ≈ 𝟏 − 𝝐𝑳𝒑𝒌
Efficiency Decreases with:
 Increase in BER
 Increase in Packet Size
Notes
 The efficiency is expressed in terms of the time step 𝑡0
 The closed form solution presents a simple equation in terms of 𝝐, 𝑳𝒑𝒌
© Tallal Elshabrawy
16
Stop-and-Wait ARQ Throughput
Throughput measures the
percentage of time slots that are
utilized for successful
transmissions
∞
𝑻𝒉 =
𝝅𝒌 × 𝑷𝒓 𝑺𝒖𝒄𝒄. 𝑻𝒙 𝒂𝒕 𝒔𝒌
𝒌=𝟎
∞
𝑻𝒉 = 𝟏 − 𝒑𝒆 ×
𝝅𝒌 = 𝟏 − 𝒑𝒆
𝒌=𝟎
Notes
 Throughput does not care how many attempts have been done to successfully transmit a packet
 Throughput measures the channel utilization for successful transmission
 Efficiency rather measures the delay of a given packet
 Both efficiency and throughput represent two faces of the same coin
© Tallal Elshabrawy
17
Stop-and-Wait ARQ Simplified Model
State 𝒔𝟎 corresponds to new transmission
and State 𝒔𝒓𝒕 corresponds to a
retransmission state.
𝟏 − 𝒑𝒆
𝒑𝒆
𝑠0
At steady State
𝟏 − 𝒑𝒆 𝒑𝒆
𝟏 − 𝒑𝒆 𝒑𝒆
With boundary condition
𝝅𝟎 + 𝝅𝒓𝒕 = 𝟏
𝚷 = 𝝅𝟎
𝝅𝒓𝒕 ×
𝒑𝒆
𝑠𝑟𝑡
𝟏 − 𝒑𝒆
𝚷 = 𝝅𝟎
𝚫=
𝝅𝒓𝒕
𝟏 − 𝒑𝒆
𝟏 − 𝒑𝒆
𝒑𝒆
𝒑𝒆
Solving:
𝝅𝟎 = 𝟏 − 𝒑𝒆
𝝅𝒓𝒕 = 𝒑𝒆
𝑻𝒉 = 𝟏 − 𝒑𝒆
© Tallal Elshabrawy
18