Upload
sathish-kumar
View
213
Download
0
Embed Size (px)
Citation preview
7/28/2019 COE540_5 (1)
1/57
1
King Fahd University of
Petroleum & MineralsComputer Engineering Dept
COE 540Computer Networks
Term 082
Courtesy of:
Dr. Ashraf S. Hasan Mahmoud
7/28/2019 COE540_5 (1)
2/57
2
Queuing Model
Consider the following system:
A(t)number of arrivals in (0, t]
D(t)number of departures in (0, t]
N(t)number of customers in system in (0,t]
Siservice time for ith customer
Tiduration of time spent in system for ith
customerWiduration of time spent waiting for service for ith customer
Wi = TiSi= DiAiSi
Queueing System
ith customer
arrives at time Ai
ith customer
departs at time Di
A(t) N(t) = A(t)D(t) D(t)
Ti = DiAi
7/28/2019 COE540_5 (1)
3/57
3
Example 1: Queueing System
Problem: A data communication line delivers a block ofinformation every 10 microseconds. A decoder checkseach block for errors and corrects the errors if necessary.It takes 1 microsecond to determine whether the blockhas any errors. If the block has one error it takes 5microseconds to correct it and if it has more than 1 error
it takes 20 microseconds to correct the error. Blocks waitin the queue when the decoder falls behind. Suppose thatthe decoder is initially empty and that the number oferrors in the first 10 blocks are: 0, 1, 3, 1, 0, 4, 0, 1, 0, 0.
a) Plot the number of blocks in the decoder as a function oftime.
b) Find the mean number of blocks in the decoder
c) What percent of the time is the decoder empty?
7/28/2019 COE540_5 (1)
4/57
4
Example 1: Queueing System
contd
Solution:Interarrival time = 10 sec
Service time = 1 if no errors
1+5 if 1 error
1+20 if more than 1 errorThe queue parameters (A, S, D, and W) are shown
below:
Block #: 1 2 3 4 5 6 7 8 9 10
Arrivals: 10 20 30 40 50 60 70 80 90 100Errors: 0 1 3 1 0 4 0 1 0 0Service: 1 6 21 6 1 21 1 6 1 1Departs: 11 26 51 57 58 81 82 88 91 101
Waiting: 0 0 0 11 7 0 11 2 0 0
7/28/2019 COE540_5 (1)
5/57
5
Example 1: Queueing System
contd
Solution:Using the previous results and knowing that
N(t) = A(t) D(t)One can produce the following results
The following Matlab code can be used tosolve this queue system (Note the codeis general it solves any systemprovided the Arrivals vector A, and theservice vector S)
Average no of customers in system = 0.950Average customer waiting time = 3.100 microsecMaximum simulation time = 101.000 microsecDuration server busy = 65.000 microsecServer utilization = 0.6436Server idle = 0.3564
0 20 40 60 80 100 1200
1
2
3
4
5
6
7
8
9
10Queue sysystem simulation
Noofcustomers
Time
A(t)D(t)N(t)
( )
1
1Average # of customers
A t
i
i
Tt
7/28/2019 COE540_5 (1)
6/57
6
Example 1: Queueing System
contd0001 %
0002 % Problem 9.3 - Leon Garcia's book0003 clear all0004 A = [10:10:100];0005 Errors = [0 1 3 1 0 4 0 1 0 0];0006 S = zeros(size(A));0007 D = zeros(size(A));0008 %0009 % this loop to computes service times0010 for i=1:length(A);0011 if (Errors(i)==0) S(i) = 1;0012 else0013 if (Errors(i)==1) S(i) = 6;0014 else
0015 S(i) = 21;0016 end0017 end0018 %0019 % this section computes the departure time forthe ith user0020 if (i>1) % this is not the first user0021 if (D(i-1) < A(i)) D(i) = A(i) + S(i);0022 else0023 D(i) = D(i-1) + S(i);0024 end0025 else0026 D(i) = A(i)+S(i);
0027 end0028 %0029 % compute waiting time0030 W(i) = D(i) - A(i) - S(i);0031 end0032 %
0033 % Compute N(t)
0034 T = []; % time axis0035 T(1) = 0; % time origin0036 N = []; % number of cutomers0037 N(1) = 0; % initial condition0038 k = 2; % place for next insert0039 A_max = A(length(A)); % last arrival instant0040 i = 1; % index for arrivals0041 j = 1; % index for departures0042 t = 0; % system time00430044while (t < A_max)0045 t = min(A(i), D(j));0046 if (t == A(i))
0047 N(k) = N(k-1) + 1;0048 T(k) = t;0049 k = k + 1;0050 i = i + 1; % get next arrival0051 else% departure occurs0052 N(k) = N(k-1) - 1;0053 T(k) = t;0054 k = k + 1;0055 j = j + 1; % get next departure0056 end0057 end0058 %0059 % record remaining departure instants
0060 for i=j:1:length(D)0061 t = D(i);0062 N(k) = N(k-1) - 1;0063 T(k) = t;0064 k = k + 1;0065 end00660067 k = k - 1; % decrement k to get real size of N and T0068 %0069 % compute means0070 MeanW = mean(W);0071 T_Intervales = T(2:k)-T(1:k-1);0072 MeanN = sum(N(1:k-1).*T_Intervales) / T(k);0073 IdleDurationsIndex = find(N(1:k-1) ~= 0);0074 Utilization = sum(T_Intervales(IdleDurationsIndex))/T(k);0075 %
7/28/2019 COE540_5 (1)
7/57
7
Example 1: Queueing System
contd
0076 % Display results0077 fprintf('Block #: '); fprintf('%3d ', [1:1:length(A)]); fprintf('\n');0078 fprintf('Arrivals: '); fprintf('%3d ', A); fprintf('\n');0079 fprintf('Errors: '); fprintf('%3d ', Errors); fprintf('\n');0080 fprintf('Service: '); fprintf('%3d ', S); fprintf('\n');0081 fprintf('Departs: '); fprintf('%3d ', D); fprintf('\n');0082 fprintf('Waiting: '); fprintf('%3d ', W); fprintf('\n');0083 fprintf('\n\n');0084 fprintf('Average no of customers in system = %7.3f\n', MeanN);0085 fprintf('Average customer waiting time = %7.3f microsec\n', MeanW);0086 fprintf('Maximum simulation time = %7.3f microsec\n', T(k));0087 fprintf('Duration server busy = %7.3f microsec\n', ...0088 sum(T_Intervales(IdleDurationsIndex)));0089 fprintf('Server utilization = %7.4f\n', Utilization);0090 fprintf('Server idle = %7.4f\n',1.0-Utilization);0091 %0092 % Plot results0093 figure(1)0094 h = stairs(T, N); grid0095 set(h, 'LineWidth', 3);0096 xlabel('Time');0097 ylabel('No of customers in system, N(t)');00980099 figure(2);0100 [AT, AA] = stairs(A, cumsum(ones(size(A))));0101 [DT, DD] = stairs(D, cumsum(ones(size(D))));0102 [NT, NN] = stairs(T, N);
0103 h = plot(AT, AA, '-', DT, DD,'--r', NT, NN,'-.'); grid0104 set(h, 'LineWidth', 3);0105 title('Queue sysystem simulation');0106 ylabel('No of customers');0107 xlabel('Time');0108 legend('A(t)', 'D(t)', 'N(t)', 0);01090110 figure(3);0111 h = stem(W); grid0112 set(h, 'LineWidth', 3);0113 ylabel('Waiting time');0114 xlabel('Customer index');0115 LegendStr = ['MeanW = ' num2str(MeanW)];
0116 legend(LegendStr, 0);
7/28/2019 COE540_5 (1)
8/57
8
0 5 10 15 20 250
1
2
3
4
5
6
7
8A(t) and D(t) for a queueing system
time
Number of Customers in System
Blue curve:A(t)
Red curve:D(t)
Total timespent in thesystem for all
customers =area inbetween twocurves
T1
T2
T3
7/28/2019 COE540_5 (1)
9/57
9
Littles Formula
Littles formula:
E[N] = E[T]
i.e. For systems reaching steady state, the averagenumber of customers in the system = averagearrival rate average time spent in the system
Holds for many service disciplines and for systemswith arbitrary number of servers. It holds formany interpretations of the system as well.
7/28/2019 COE540_5 (1)
10/57
10
Example 2:
Problem: Let Ns(t) be the number ofcustomers being served at time t, and lett denote the service time. If wedesignate the set of servers to be thesystem then Littles formula becomes:
E[Ns] = E[t]Where E[Ns] is the average number of busy
servers for a system in the steady state.
7/28/2019 COE540_5 (1)
11/57
11
Example 2: contd
Note: for a single server Ns(t) can be either 0 or 1 E[Ns]represents the portion of time the server is busy. If p0 =Prob[Ns(t) = 0], then we have
1 - p0 = E[Ns] = E[t], Orp0 = 1 - E[t]
The quantity E[t] is defined as the utilization for a singleserver. Usually, it is given the symbol r
r = E[t]For a c-server system, we define the utilization (the fraction of
busy servers) to be
r = E[t] / c
7/28/2019 COE540_5 (1)
12/57
12
Example 3: Applications on Littles
Formula
Refer to the slides for Dr. Waheed.
The slides have 8 good examples!
7/28/2019 COE540_5 (1)
13/57Courtesy of Dr. Abdul Waheed
Queueing Jargons
Queueing system
Customers
Queue(s) (waiting room)
Server(s)
Kendalls notation Standard notation to describe queueing containing single queue:
X/Y/m/n/y/SD
InterArrival process
Service processServers #
Queue capacity
Population size
X/Y/m/n/y/SDService discipline
7/28/2019 COE540_5 (1)
14/57
Courtesy of Dr. Abdul Waheed
Common Distributions
G = general distribution of inter-arrival times or service times
GI = general distribution of inter-arrival time with the restrictionthat they are independent
M = negative exponential distribution (Poisson arrivals)
D = deterministic arrivals or fixed length service
M/M/1? M/D/1?
7/28/2019 COE540_5 (1)
15/57
Courtesy of Dr. Abdul Waheed
General Characteristics of NetworkQueuing Models
Customer population Generally assumed to be infinite arrival rate is persistent
Queue size
Infinite, therefore no loss Finite, more practical, but often immaterial
Dispatching discipline FIFO typical
LIFO Relative/Preferential, based on QoS
Processor sharing (PS) discipline Useful for modeling multiprogramming
7/28/2019 COE540_5 (1)
16/57
16
Queue System and Parameters
Queueing system with m servers When m = 1 single server system
Input: arrival statistics (rate ), service statistics (rate ),number of customers (m), buffer size
Output: E[N], E[T], E[Nq], E[W], Prob[buffer size = x],Prob[W
7/28/2019 COE540_5 (1)
17/57
17
The M/M/1 Queue
Consider m-server system wherecustomers arrive according to a Poissonprocess of rate inter-arrival times are iid exponential r.v.
with mean 1/ Assume the service times are iid
exponential r.v. with mean 1/m Assume the inter-arrival times and
service times are independent Assume the system can accommodate
unlimited number of customers
7/28/2019 COE540_5 (1)
18/57
18
The M/M/1 Queuecontd
What is the steady state pmf of N(t), thenumber of customers in the system?
What is the PDF of T, the total customerdelay in the system?
7/28/2019 COE540_5 (1)
19/57
19
The M/M/1 Queuecontd
Consider the transition rate diagram for M/M/1system
Note: System state number of customers in systems is rate of customer arrivals
m is rate of customer departure
0 1
l
m
l
m
2 3
l
m
j j+1
l
mm
l l
m
7/28/2019 COE540_5 (1)
20/57
20
The M/M/1 QueueDistribution of
Number of Customers
Writing the global balance equations forthis Markov chain and solving forProb[N(t) = j], yields (refer to previousexample)
pj = Prob[N(t) = j]
= (1-r)rjfor r = /m < 1Note that for r = 1 arrival rate = service
rate m
7/28/2019 COE540_5 (1)
21/57
21
The M/M/1 QueueExpected
Number of Customers
The mean number of customers is givenby
E[N] = j Prob[N(t) = j]j=0
= r/(1-r)Note: Nhas geometric distribution withp= (1-r) (i.e.pj= Prob[N(t)
= j] =p(1-p)j = (1-r)rjfor j = 0, 1, ) E[N] = (1-p)/p= r/(1-r)
7/28/2019 COE540_5 (1)
22/57
22
The M/M/1 QueueMean Customer
Delay
The mean total customer delay in thesystem is found using Littles formula
E[T] = E[N]/ = /[ (1- )]= 1/ (1-)
= 1/()
7/28/2019 COE540_5 (1)
23/57
23
The M/M/1 QueueMean Queueing
Time
The mean waiting time in queue is givenby
E[W] = E[T] E[t]= [1/()] E[t]= [(1/ )/(1r)] E[t]= [E[t]/(1r)] E[t]= [r/(1r)] E[t]
Note: E[t] = mean service time for a customer = 1/
7/28/2019 COE540_5 (1)
24/57
24
The M/M/1 QueueMean Number in
Queue
Again we employ Littles formula:
E[Nq] = E[W]
= r2 / (1-r)Remember:
server utilization r = /m = 1-p0All previous quantities E[N], E[T], E[W], and
E[Nq] as r 1
7/28/2019 COE540_5 (1)
25/57
25
Scaling Effect for M/M/1 Queues
Consider a queue of arrival rate whoseservice rate is m r = /m, The expected delay E[T] is given by
E[T] = (1/m) / (1-r) If the arrival rate increases by a factor of
K, then we either1. Have K queueing systems, each with a
server of rate m2. Have one queueing system with a server of
rate Km Which of the two options will perform
better?
7/28/2019 COE540_5 (1)
26/57
26
Example 4: Scaling Effect for M/M/1
Queues
Example: K = 2: M/M/1 and M/M/2systems with the same arrival rate andthe same maximum processing rate
Case1:
K independent
queueing systems
2
2Case 2:ONE queueing
system
7/28/2019 COE540_5 (1)
27/57
27
Example 4: Scaling Effect for M/M/1
Queuescontd
Case 1: K queueing systems Identical systems
E[T] is the same for all E[T] = (1/m) / (1-r)
Case 2: 1 queueing system with server of rateKm r for this system = (K) /(Km) = /m same as the
original system
E[T] = (1/(Km)) / (1-r) = (1/K) E[T]
Therefore, the second option will provide a lesstotal delay figure significant delayperformance improvement!
7/28/2019 COE540_5 (1)
28/57
28
M/M/1/KFinite Capacity Queue
Consider an M/M/1 with finite capacity K<
For this queue there can be at most Kcustomers in the system
1 being served
K-1 waiting
A customer arriving while the system hasK customers is BLOCKED (does not wait)!
7/28/2019 COE540_5 (1)
29/57
29
M/M/1/KFinite Capacity Queue
contd
Transition rate diagram for this queueingsystem is given by:
N(t) - A continuous-time Markov chainwhich takes on the values from the set {0,
1, , K}
0 1
l
m
l
m
2 3
l
m
K-1 K
l
mm
l
7/28/2019 COE540_5 (1)
30/57
30
M/M/1/KFinite Capacity Queue
contd
The global balance equations: p0 = mp1
( + m)pj = pj-1 + mpj+1 for j=1, 2, , K-1m pK= pK-1
Prob[N(t) = j] = pj j=0,1, , K; r
7/28/2019 COE540_5 (1)
31/57
31
M/M/1/KMean Number of
Customers
Mean number of customers, E[N] is givenby:
K
j
jtNjNE0
])(Pr[][
)
12/
11
1
1 1
1
r
rr
r
r
r
K
KK
K
7/28/2019 COE540_5 (1)
32/57
32
M/M/1/KBlocking Rate
A customer arriving while the system isin state K is BLOCKED (does not wait)!
Therefore, rate of blocking, b, is given by
b = pK
The actual (i.e. serviced) arrival rate into the
system is a given
a = - b
= (1 - pK)
7/28/2019 COE540_5 (1)
33/57
33
M/M/1/KBlocking Ratecontd
Queueing System
a: actual
(serviced) arrivals
b: blocked (not
serviced) arrivals
: total
arrivals
7/28/2019 COE540_5 (1)
34/57
34
M/M/1/KMean Delay
The mean total delay E[T] is given by
E[T] = E[N] / a
7/28/2019 COE540_5 (1)
35/57
35
Multi-Server Systems: M/M/c
The transition rate diagram for a multi-server M/M/c queue is as follows:
Departure rate = km when k servers are busy We can show that the service time for a
customer finding k servers busy isexponentially distributed with mean 1/(k)
0 1
l
m
c-1 c
l
cm
j j+1
l
cmcm
l l
cm
l
2m (c-1)m
l
7/28/2019 COE540_5 (1)
36/57
36
Multi-Server Systems: M/M/c
contd
Writing the global balance equations: p0 = mp1jm pj = pj-1 for j=1, 2, , ccm pj = pj-1 for j= c, c+1,
pj= (a
j/j!) p0 (forj=1, 2, , c) andpj= (rj-c/c!) ac p0 (forj=c, c+1, )
where a = /m and r = a/c From this we note that the probability of system being in
state c, pc, is given by
pc = ac/c! p0
Note this distribution is the
same as that for M/M/1 when
you set c to 1.
7/28/2019 COE540_5 (1)
37/57
37
Multi-Server Systems: M/M/c
contd
To find p0, we resort to the fact that pj = 1
The probability that an arriving customer has to wait
Prob[W > 0] = Prob[N c]
= pc + r pc+1 + r2pc+2+ = pc/(1-r)
Question: What is Prob[W>0] for M/M/1 system?
11
0
01
1
!!
r
c
j
cj
c
a
j
ap
Erlang-C
formula
7/28/2019 COE540_5 (1)
38/57
38
Multi-Server Systems: M/M/c
contd
The mean number of customers in queue(waiting):
)
cj
q jtNcjNE ])(Pr[][
)
cj
c
cjpcj r
) cp2
1 r
r
]0Pr[1
Wr
r
7/28/2019 COE540_5 (1)
39/57
39
Multi-Server Systems: M/M/c
contd
The mean waiting time in queue:
The mean total delay in system:
The mean number of customers insystem:
l/][][ qNEWE
][][][ tEWETE
m/1][ WE
][][ TENE l
aNE q ][ Why?
7/28/2019 COE540_5 (1)
40/57
40
Example 5:
A company has a system with four privatetelephone lines connecting two of its sites.Suppose that requests for these lines arriveaccording to a Poisson process at rate of one
call every 2 minutes, and suppose that calldurations are exponentially distributed withmean 4 minutes. When all lines are busy, thesystem delays (i.e. queues) call requests until aline becomes available.
Find the probability of having to wait for a line.
What is the average waiting time for anincoming call?
7/28/2019 COE540_5 (1)
41/57
41
Example 5: contd
Solution: = , 1/m = 4, c = 4 a = /m = 2
r = a/c = p0 = {1+2+2
2/2!+23/3!+24/4! (1/(1-r))}-1= 3/23
pc = ac
/c! p0= 24/4! X 3/23
(1) Prob[W > 0] = pc/(1-)= 24/4! 3/23 1/(1-1/2)= 4/23
0.17
(2) To find E[W], find E[Nq] E[Nq] = /(1- ) * Prob[W>0] = 0.1739E[W] = E[Nq]/ = 0.35 min
7/28/2019 COE540_5 (1)
42/57
42
Multi-Server Systems: M/M/c/c
The transition rate diagram for a multi-server with no waiting room (M/M/c/c)queue is as follows:
Departure rate = k when k servers are
busy
0 1
l
m
c-1 c
l
cm
l
2m (c-1)m
l
7/28/2019 COE540_5 (1)
43/57
43
PMF for Number of Customers for
M/M/c/c
Writing the global balanceequations, one can show:
pj= aj/j! p0 (forj=0, 1, , c)
where a = / (the offered load)
To find p0, we resort to the fact that pj
= 1 1
0
0!
c
j
j
j
ap
7/28/2019 COE540_5 (1)
44/57
44
Erlang-B Formula
Erlang-B formula is defined as theprobability that all servers are busy:
cpcN
]Pr[
2
/ !
1 / 2! ... / !
c
c
a c
a a a c
E t d N b f t i
7/28/2019 COE540_5 (1)
45/57
45
Expected Number of customers in
M/M/c/c
The actual arrival rate intothesystem:
Average total delay figure:
Average number of customers:
)1( ca p ll
][][ tETE Why?
][][ tl ENE a
7/28/2019 COE540_5 (1)
46/57
46
Example 6:
A company has a system with fourprivate telephone lines connecting two ofits sites. Suppose that requests for theselines arrive according to a Poisson
process at rate of one call every 2minutes, and suppose that call durationsare exponentially distributed with mean4 minutes. When all lines are busy, the
system BLOCKS the incoming call andgenerates a busy signal.
Find the probability of being blocked.
7/28/2019 COE540_5 (1)
47/57
47
Example 6:
Solution: = 1/2, 1/ = 4, c = 4 a = / = 2
= a/c = 1/2
ac/c!pc = ------------------------------------
1 + a + a2/2! + a3/3! + a4/4!
24/4!
= ------------------------------------ = 9.5%1 + 2 + 22/2! + 23/3! + 24/4!
Therefore, the probability of being blocked is 0.095.
7/28/2019 COE540_5 (1)
48/57
48
M/G/1 Queues
Poisson arrival process (i.e. exponentialr.v. interarrival times)
Service time: general distribution ft(x) For M/M/1, ft(x) = me-mx for x > 0
The state of the M/G/1 system at time tis specified by
1. N(t)2. The remaining (residual) service time of the
customer being served
7/28/2019 COE540_5 (1)
49/57
49
The Residual Service Time
Mean residual time (see example andderivation in Chapter 9 of Garciastextbook) is given by
E[t2]E[R] = ---------
2E[t]
7/28/2019 COE540_5 (1)
50/57
50
Mean Waiting Time in M/G/1
The waiting time of a customer is thesum of the residual service time R of thecustomer (if any) found in service andthe Nq(t)= k-1 service time of the
customers (if any) found in queue
E[W] = E[R] + E[Nq] E[t]= E[R] + E[W]E[t]= E[R] + r E[W]
7/28/2019 COE540_5 (1)
51/57
51
Mean Waiting Time in M/G/1contd
But residual service time R (as observedby an arriving customers) is either 0 is the server is free
R if the server is busy
Therefore, mean of R is given by
E[R] = 0 P[N(t)=0] + E[R](1-P[N(t)=0])= E[t2]/(2E[t]) r= E[t2]/2
7/28/2019 COE540_5 (1)
52/57
52
Mean Waiting Time in M/G/1contd
Substituting back, yields
E[t2]E[W] = ----------
2(1-r)(2tE[t]2)
= ----------------
2(1-r)r (1 + Ct2)
= ---------------- E[t]2(1-r)
Note:
- E[t2
] = 2
t+E[t]2
- C2t = 2
t/E[t]2
= coefficient of variation
of the service time
Pollaczek-Khinchin (P-K)
Mean Value Formula
7/28/2019 COE540_5 (1)
53/57
53
Mean Delay in M/G/1contd
The mean waiting time, E[T] is found byadding mean service time to E[W]:
E[T] = E[t] + E[W]r (1 + Ct2)
= E[t] + ---------------- E[t]2(1-r)
7/28/2019 COE540_5 (1)
54/57
54
Example 7:
Problem: Compare E[W] for M/M/1 and M/D/1systems.
Answer:
M/M/1: service time, t, is exponential r.v. withparameter m
E[t] = 1/m , E[t2] = 2/m2 , 2t= 1/m2 , C2t= 1M/D/1: service time, t, is constant with value t =
1/m E[t] = 1/m , E[t2] = 1/m2 , 2t= 0 , C2t= 0
7/28/2019 COE540_5 (1)
55/57
55
Example 7: contd
Answer: contdSubstitute in P-K mean value formula
M/M/1:E[t2] r
E[WM/M/1] = ---------- = ---------- E[t]2(1-r) (1-r)
M/D/1: E[t2] rE[WM/D/1] = ---------- = ---------- E[t]
2(1-r) 2 (1-r)1
= -- E[WM/M/1]2
The waiting time in an
M/D/1 queue is half of
that of an M/M/1 system
7/28/2019 COE540_5 (1)
56/57
56
Example 8:
Problem: Assume traffic is arriving at the inputport of a router according to a Poisson arrivalprocess of rate = 100 packets/sec. If thetraffic distribution is as follows:30% of packets are 512 Bytes long,
50% of packets are 1024 Bytes long,20% of packets are 4096 Bytes longIf the transmit speed of the router output portis 1.5 Mb/s
a) What is the average packet transmit time?
b) What is the average packet waiting time beforetransmit?
c) What is the average buffer size in the router?
7/28/2019 COE540_5 (1)
57/57
Example 8: contd
Solution:a) Average packet size,
E[L] = 0.3512 + 0.51024 + 0.24096= 1484.8 Bytes
average transmit time = E[L]/R = 1484.88/1.5106 =0.0079 sec
b) E[L2] = 0.3(5128)2 + 0.5(10248)2 + 0.2x(40968)2 =2.5334e+008 Bits2
E[t2] = E[L2]/R2 = 1.1259e-004 sec2 = E[t] = 0.7919E[W] = () E[t2] /(1-)
= 0.0271 sec
c) E[Nq] = E[W]
= 2.705 packet