Presentation is loading. Please wait.

Presentation is loading. Please wait.

# 5 1 Victor S. Frost Dan F. Servey Distinguished Professor Electrical Engineering and Computer Science University of Kansas 2335 Irving Hill Dr. Lawrence,

Similar presentations


Presentation on theme: "# 5 1 Victor S. Frost Dan F. Servey Distinguished Professor Electrical Engineering and Computer Science University of Kansas 2335 Irving Hill Dr. Lawrence,"— Presentation transcript:

1 # 5 1 Victor S. Frost Dan F. Servey Distinguished Professor Electrical Engineering and Computer Science University of Kansas 2335 Irving Hill Dr. Lawrence, Kansas 66045 Phone: (785) 864-4833 FAX:(785) 864-7789 e-mail: frost@eecs.ku.edu http://www.ittc.ku.edu/ How to cope with last hop impairments? Part 2 ARQ #5 All material copyright 2006 Victor S. Frost, All Rights Reserved

2 # 5 2 How to cope with last hop impairments? Techniques for coping with noise –Forward error detection/correction coding –Automatic Repeat reQuest (ARQ) –Co-existance or modifications to end-to-end protocols Techniques for coping with multipath fading  fading mitigation techniques, e.g., –Equalizers –Diversity –RAKE receivers –OFDM

3 # 5 3 ARQ ARQ is used for both –Flow control –Error control For access networks the main issue is error control

4 # 5 4 Error and Flow Control Protocol 1: The Unrestricted Simplex Protocol Assumptions –One directional information flow –Infinite buffers –No errors –Network Layer always has a packet to sendNetworkLayerNetworkLayer Data Link Layer Layer

5 # 5 5 Error and Flow Control Protocol 2: The Simplex Stop & Wait Protocol: Assumptions One directional information flow No errors Network Layer always has a packet to send Finite receive buffers –Finite buffer means that there must be some way to stop the transmitter from sending when the buffer is full

6 # 5 6 Error and Flow Control Protocol 2: The Simplex Stop & Wait Protocol NetworkLayerNetworkLayer Data Link Layer Layer ACKChannel Ack Packet Assume Network Layer always has data to send Frame Ready Packet

7 # 5 7 Error and Flow Control Protocol 2: The Simplex Stop & Wait Protocol NetworkLayerNetworkLayer Data Link Layer Layer ACKChannel Ack Packet Assume Network Layer always has data to send Frame Ready Packet

8 # 5 8 Error and Flow Control Protocol 2: The Simplex Stop & Wait Protocol NetworkLayerNetworkLayer Data Link Layer Layer ACKChannel Ack Packet Assume Network Layer always has data to send Frame Ready Packet

9 # 5 9 Error and Flow Control Protocol 3: The Simplex Protocol for a Noisy Channel Assumptions –One directional information flow –Network Layer always has a packet to send –Finite receive buffers –Allow errors Data link protocols must address –When to retransmit –What to retransmit

10 # 5 10 Error and Flow Control Protocol 3: The Simplex Protocol for a Noisy Channel Timeout to determine when to retransmitt Example: –Assume a 1 ms propagation time –Assume a.1 ms receiver packet processing time –Timeout interval >2.1 ms If no acknowledgment received in 2.1 ms then, –Packet in error –Acknowledgment lost

11 # 5 11 Error and Flow Control Protocol 3: The Simplex Protocol for a Noisy Channel –Timeout interval too short Duplicate packets –Timeout interval too long Reduced throughput

12 # 5 12 Error and Flow Control Protocol 3: The Simplex Protocol for a Noisy Channel Sequence numbers are used to determine what to retransmitt –Transmitter assigns a number to each frame –Receiver keeps track of the expected frame number –How to deal with out of sequence frames, i.e., if the received sequence number does not match what is expected, The frame is dumped (for some DLC protocols) Frame stored

13 # 5 13 Error and Flow Control Protocol 3: One Simplex Protocol for a Noisy Channel

14 # 5 14 Error and Flow Control Sliding Window Protocols: Assumptions Two directional information flow Network Layer always has a packet to send Finite receive buffers Finite number of bits/sequence number Piggybacking –Put Acknowledgments in reverse traffic flow –Increases protocol efficiency –Reduces interrupts

15 # 5 15 Error and Flow Control Sliding Window Protocols: Advantage  pipeline Why called sliding window –Assume 2 bits/Sequence number –Possible frame numbers 0, 1, 2, 3 0, 1, 2, 3, 0, 1, 2, 3, 0, 1, 2, 3, 0, 1, 2, 3, 0, 1, 2, 3, 0, 1, 2, 3 Receive ack and advance window

16 # 5 16 Error and Flow Control Sliding Window Protocols: A B A to B Data Traffic B to A Ack Traffic B to A Data Traffic A to B Ack Traffic Frame A->B Frame B->A ACK A->B ACK B->A

17 # 5 17 Error and Flow Control Sliding Window Protocols Transmitter keeps a list of sequence #’s it can use –Sending window Receiver keeps a list of sequence #’s it will accept –Receiving window n = # bits/(sequence number)

18 # 5 18 Error and Flow Control Sliding Window Protocols Sequence numbers in range 0...2 n -1 This allows N=2 n -1 packets to be sent before getting and acknowledgment Requires N=2 n -1 packets buffers

19 # 5 19 Error and Flow Control Sliding Window Protocols: How many frames can be pipelined: Problem if max # frames in pipeline = 2 n Assume that # frames in pipeline  2 n Assume n = 3, Node A sends 0...7 (8 frames) Node B receives 0...7 ok and sends Ack First Ack gets lost Packet 0 of Node A times out Node B receives another packet 0, expects a packet 0, but this is a duplicate Thus: # frames in pipline <= 2 n -1

20 # 5 20 Error and Flow Control Sliding Window Protocols: How many frames can be pipelined (1) Now with # frames in pipline = N= 2 n -1 –0....6 (7 frames) Node A sends 0...6 Node B receives 0...6 ok Node B sends Ack Ack gets lost

21 # 5 21 Error and Flow Control Sliding Window Protocols: How many frames can be pipelined (2) Node A times out Node A retransmitts 0...6 But Node B is expecting frame #7 Node ignores 0...6 (often will send a RR frame explicitly telling Node A it is expecting Frame #7)

22 # 5 22 Error and Flow Control Focus on which frames to retransmit Pipeline: send up to N frames before receiving an acknowledgment

23 # 5 23 Error and Flow Control Example Distance between nodes = 1 km Frame length = 1000 bits Capacity = 150 Mb/s No errors Delay-bandwidth product –Assume free space –  1000m/c = 3.33 us – 2  R= 1000 bits

24 # 5 24 Error and Flow Control Example Case 1: Stop and Wait (N=1) –Frame transmission time = 6.66us –Propagation time = 3.33us –Transmit frame at t=0, –At 6.66 us + 3.33us frame received –At 6.66us + 6.66us the acknowledgment is received, therefore transmitted 1000 bits in 6.66us + 6.66us –Effective transmission rate is 1000/13.3us ~ 75Mb/s –Efficiency: (75Mb/s)/(150Mb/s) ~ 50.0% efficient

25 # 5 25 Error and Flow Control Example Case 2: Stop and Wait (N=1) –Reduce capacity to 1.5 Mb/s –Frame transmission time = 666us –Propagation time = 3.33us –Transmit frame at t=0, –At 666 us + 3.33us frame received –At 666us + 6.66us the acknowledgment is received, therefore transmitted 1000 bits in 666us + 6.66us –Effective transmission rate is 1000/672us ~ 1.488 Mb/s –Efficiency: (1.488Mb/s)/(1.50Mb/s) ~ 99.2% efficient

26 # 5 26 Error and Flow Control Example Case 3: Stop and Wait (N=1) –Capacity to 150 Mb/s –Frame transmission time = 6.66us –WAN: D=1000km Propagation time = 3333us –Transmit frame at t=0, –At 6.66 us + 3333us frame received –At 6.66us + 6666us the acknowledgment is received, therefore transmitted 1000 bits in 6.66us + 6666us –Effective transmission rate is 1000/6672us ~.149Mb/s –Efficiency: (.149Mb/s)/(150Mb/s) ~ 0.1% efficient

27 # 5 27 Error and Flow Control Example Case 4: Sliding window (N=1023) –Capacity to 150 Mb/s –Frame transmission time = 6.66us –WAN: D=1000km Propagation time = 3333us –Transmit frame at t=0, –Note 2  R = 999,900 bits or in frames 999.9 frames –Since time to transmit 1023 frames > 999.9 Always have a sequence number to use Never have to wait for ACK –Efficiency  100%

28 # 5 28 Error and Flow Control Example 6.66us 3333us Frame # 1,000 Ack for Frame 1

29 # 5 29 Error and Flow Control Go-Back-N Protocol (1) Problem: If there is an error or lost frame then what rules are used to determine the frames to retransmit. Go-back-N –Retransmit all frames transmitted after the erred frame –The receiver ignores all out-of sequence frames

30 # 5 30 Error and Flow Control Go-Back-N Protocol (2) Example: Transmit 1,2,3,4,5 and frame 2 is in error then 3, 4, and 5 are received out of sequence and retransmit 2,3,4,5

31 # 5 31 Error and Flow Control Selective Repeat Receiver accepts out of sequence frames Requires buffers in receiver and transmitter Requires extra processing to deliver packets in order to the Network Layer

32 # 5 32 Error and Flow Control Other Enhancements Negative Acknowledgment –When an out-of-sequence frame is received the receiver sends a NAK frame to the transmitter, the NAK frame contains the sequence number of the expected data frame. –NAK enables faster error recovery, without a NAK time-out must be used to learn about errors.

33 # 5 33 Error and Flow Control Sliding Window Protocols: Piggyback ACKS A B A to B Data Traffic B to A Ack Traffic B to A Data Traffic A to B Ack Traffic Frame A->B Frame B->A: ACK A->B Reverse traffic is used to Piggyback ACKS

34 # 5 34 Error and Flow Control Other Enhancements: Acknowledgment timer If there is light (or no) reverse traffic then ACKS may not be sent. An acknowledgment timer is used to insure ACKS are sent. Upon receipt of a frame an AckTimer is started. If reverse traffic arrives before the AckTimer fires then piggyback the ACK. If the AckTimer fires then send a supervisory ACK frame.

35 # 5 35 Error and Flow Control Performance Definition for effective rate

36 # 5 36 Error and Flow Control Performance Length of data packet (bits) = D Number of overhead bits/packet = n o Link Rate (b/s) = R Length of Ack Packet (bits)= n a Frame size = n f = D+ n o One-way propagation delay =  Processing time (in receiver and transmitter) = t proc

37 # 5 37 Error and Flow Control Performance-Stop & Wait Effective rate and efficiency for simplex stop-and-wait protocol –t ack = n a /R –t f = n f /R –Time to transmit one frame = t o t o = 2  + t f + t ack + 2 t proc = 2(  + t proc ) + (n a + n f )/R

38 # 5 38 Error and Flow Control Performance-Stop & Wait R eff = (n f - n o )/ t o Efficiency = R eff /R =

39 # 5 39 Error and Flow Control Performance-Stop & Wait: Limiting Case Define 2tR = Delay-Bandwidth Product For fixed DLL parameters As Delay-Bandwidth Product  Efficiency 

40 # 5 40 Error and Flow Control Performance-Stop & Wait Example –Frame size = 1024 bytes –Overhead = Ack = 8 bytes –  = 50 ms Case 1: R=30 Kb/s  Efficiency = 73% Case 2: R=1.5 Mb/s  Efficiency = 5%

41 # 5 41 Error and Flow Control Performance-Sliding Window Protocol Case 1: Large window –Window Size = N –Transmit N packet and wait for Ack –Making the same assumption as before –First Ack arrives at sender at:

42 # 5 42 Error and Flow Control Performance-Sliding Window Protocol Case 1: Large window –If time to transmit N packets > time to get first ack Or Nn f / R > 2  + n f / R Then channel is always busy sending packets Efficiency = (n f - n o )/ n f

43 # 5 43 Error and Flow Control Performance-Sliding Window Protocol Case 2: Small Window –If time to transmit N packets < time to get first ack Or Nn f / R < 2  + n f / R Then channel is Not always busy sending packets: Time is wasted waiting for an Ack

44 # 5 44 Error and Flow Control Performance-Sliding Window Protocol Time to send one window = Nn f / R Number of bits sent = Nn f Time to send Nn f bits = 2  + n f / R Effective rate = Nn f /(2  + n f / R ) Efficiency = Nn f /(2  R + n f ) = N /(2  R/ n f + 1)

45 # 5 45 Error and Flow Control Performance-Sliding Window Protocol Example: –Frame size = 1024 bytes –Overhead = Ack = 0 bytes –  = 1 ms –Rate = 40 Mb/s Case 1: N = 12  Efficiency = 100%  Mb/s Case 2: N = 8  Efficiency = ~75%  Mb/s Case 3: N = 4  Efficiency = ~ 37%  Mb/s Note you can control the rate by changing N

46 # 5 46 With bit errors Let p = Probability of a bit error Assume bits errors are random Let P f = Probability of a frame error P f = 1 - (1-p) n f If p << 1 then P f = pn f

47 # 5 47 Stop and Wait Performance The Probability that it takes 1 transmission to send a frame = 1- P f The Probability that it takes 2 transmission to send a frame = P f (1- P f ) The Probability that it takes 2 transmission to send a frame = P f P f (1- P f )

48 # 5 48 Stop and Wait Performance Without errors t o = 2  + t f + t ack + 2 t proc = 2(  + t proc ) + (n a + n f )/R ~ 2  + n f /R With Errors t o = (2  + n f /R)/ (1- P f )  with errors  (1- P f )  without errors

49 # 5 49 Stop and Wait Performance Stop and wait Capacity = 2 Mb/s Frame size= 512 bits Propagation time = 10us Efficiency without errors = 0.92

50 # 5 50 Performance of Sliding Window Assume Go-Back-N Assume large window case Assume P f frame loss probability, then time to deliver a frame is: –t f if first frame transmission succeeds (1 – P f ) –t f + W s t f /(1-P f ) if the first transmission does not succeed P f Modified from: Leon-Garcia & Widjaja: Communication Networks

51 # 5 51 Performance of Sliding Window Assume Selective repeat Assume P f frame loss probability, then number of transmissions required to deliver a frame is: –t f / (1-P f ) Modified from: Leon-Garcia & Widjaja: Communication Networks

52 # 5 52 Error and Flow Control With Errors 10 -9 10 -8 10 -7 10 -6 10 -5 10 -4 10 -3 10 -2 10 -1 p Delay-Bandwidth product = 10, 100 Modified from: Leon-Garcia & Widjaja: Communication Networks

53 # 5 53 Impact of ARQ Increase delay  wait for successful retransmission Increase the delay variation Reduce the effective throughput Significantly reduces the probability of an errored packet reaching upper layers especially when combined with FEC. Practical issue: The link layer will only try to send a packet for so long, eventually it will time out and let high layers deal with the problem; therefore higher layers can still see losses

54 # 5 54 Other actions to cope with errors Adaptive power control –In CDMA system this increases the interference to other users –Used in fixed wireless deployments Adaptive bit rate: via measurements the system knows to reduce its transmission rate to decrease BER, e.g., adapt the modulation scheme Combine FEC with ARQ: Save the errored packet and ask for retransmission

55 # 5 55 Rate adaptation techniques Basic idea: change the modulation and coding scheme during the communication to adapt to the changing link conditions, e.g., radio environment *From: Dealing with the EDGE Evolution, Terry Locke, Si Nguyen, and Dominique Moreuil, Nortel Networks CommsDesign.com Sep 24, 2002 * GPRS=General Packet Radio Service GSM=Global System for Mobile Communications EDGE= Enhanced date rates for GSM Evolution CS=Coding Scheme MCS=Modulation and Coding Scheme ModeIEEE802.11b Mb/s IEEE802.11a Mb/s 116 229 35.512 41118 524 636 748 856

56 # 5 56 Hybrid ARQ: Incremental Redundancy Goal: transmit a packet of J information bits Add CRC to the J information bits to create a J + c packet Use a 1/n convolution code get n(J+c) bits Puncture the 1/n convolutional code* to get a rate 1 code (save all n bits) Send the J+c bits *Need to use special Convolutional codes: Rate Compatible Codes (RCPC)

57 # 5 57 Hybrid ARQ: Incremental Redundancy At receiver pad with random bits to get the n(J+c) bits Use Viterbi decoding Check CRC –If checks then accept packet and send ACK –Else save received bits and send NACK The sender now sends transmitters next J+c bits At receiver now have rate 2/n code Use Viterbi decoding Check CRC –If checks then accept packet and send ACK –Else save received bits and send NACK Continue until sent all n(J+c) bits

58 # 5 58 Hybrid ARQ: Incremental Redundancy Hybrid ARQ or Incremental Redundancy From: Incremental Redundancy in EGPRS, Feb, 2005 www.wirelessdesignmag.com Rate 1/3 means 3 coded bits for each information bit Each retransmission adds redundancy that will improve the probability of correct reception

59 # 5 59 Hybrid ARQ: Incremental Redundancy Advantage: If mobile is close to BS then lost of power and first packet (rate =1) will be needed As the mobile moves away from the BS there is less power and this scheme automatically compensates by sending additional redundancy bits.

60 # 5 60 References Leon-Garcia & Widjaja: Communication Networks, McGraw Hill, 2004 Dealing with the EDGE Evolution, Terry Locke, Si Nguyen, and Dominique Moreuil, Nortel Networks CommsDesign.com Sep 24, 2002 More….


Download ppt "# 5 1 Victor S. Frost Dan F. Servey Distinguished Professor Electrical Engineering and Computer Science University of Kansas 2335 Irving Hill Dr. Lawrence,"

Similar presentations


Ads by Google