Networking Theory and Fundamentals - Lecture 4 & 5 doc

41 219 0
Networking Theory and Fundamentals - Lecture 4 & 5 doc

Đang tải... (xem toàn văn)

Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống

Thông tin tài liệu

1 TCOM 501: Networking Theory & Fundamentals Lectures 4 & 5 February 5 and 12, 2003 Prof. Yannis A. Korilis 4&5-2 Topics  Markov Chains  M/M/1 Queue  Poisson Arrivals See Time Averages  M/M/* Queues  Introduction to Sojourn Times 4&5-3 The M/M/1 Queue  Arrival process: Poisson with rate λ  Service times: iid, exponential with parameter µ  Service times and interarrival times: independent  Single server  Infinite waiting room  N(t): Number of customers in system at time t (state) 0 1 n+1n2 λ µ λ µ λ µ λ µ 4&5-4 Exponential Random Variables  Proof: 00 00 00 0 () 00 {} (,) (1 ) () 1 y XY y xy y yx yy yy P X Y f x y dx dy e e dx dy e e dx dy eedy ed y ed y λµ µλ µλ µλµ λµ µλ µ µ µλµ λµ µλ λµ λµ ∞ ∞ −− ∞ −− ∞ −− ∞∞ −−+ <= = =⋅ = == =−= = −+ = + =− = ++ ∫∫ ∫∫ ∫∫ ∫ ∫∫ () () { min { , }} { , } {}{} {min{ , } } 1 tt t t PXYtPXtYt PX tPY t ee e PXYte λµ λµ λµ −− −+ −+ >= > >= = >>= = =⇒ ≤=−  X: exponential RV with parameter λ  Y: exponential RV with parameter µ  X, Y: independent Then: 1. min{X, Y}: exponential RV with parameter λ+µ 2. P{X<Y} = λ/(λ+µ) [Exercise 3.12] 4&5-5 M/M/1 Queue: Markov Chain Formulation  Jumps of {N(t): t ≥ 0} triggered by arrivals and departures {N(t): t ≥ 0} can jump only between neighboring states Assume process at time t is in state i: N(t) = i ≥ 1  X i : time until the next arrival – exponential with parameter λ  Y i : time until the next departure – exponential with parameter µ  T i =min{X i ,Y i }: time process spends at state i  T i : exponential with parameter ν i = λ+µ  P i,i+1 =P{X i < Y i }= λ/(λ+µ), P i,i-1 =P{Y i < X i }= µ/(λ+µ)  P 01 =1, and T 0 is exponential with parameter λ {N(t): t ≥ 0} is a continuous-time Markov chain with ,1 ,1 ,1 ,1 ,0 ,1 0, | | 1 ii i ii ii i ii ij qP i qP i qij ν λ νµ ++ −− = =≥ = =≥ =−> 4&5-6 M/M/1 Queue: Stationary Distribution 0 1 n+1n2 λ µ λ µ λ µ λ µ  Birth-death process → DBE  Normalization constant  Stationary distribution 1 11 0 nn n nn n pp pp p p µ λ λ ρρ µ − −− =⇒ ==== 00 01 11 1 1, if 1 n n nn pp p ρρρ ∞∞ ==  =⇔ + =⇔ =− <   ∑∑ (1 ), 0,1, n n pn ρρ =− = 4&5-7 The M/M/1 Queue  Average number of customers in system  Little’s Theorem: average time in system  Average waiting time and number of customers in the queue – excluding service 1 00 0 2 (1 ) (1 ) 1 (1 ) (1 ) 1 nn n nn n Nnp n n N ρ ρρρρ ρλ ρρ ρρµλ ∞∞ ∞ − == = ==− =− ⇒= − = = −−− ∑∑ ∑ λµλµ λ λλ − = − == 11N T ρ ρ λ λµ ρ µ − == − =−= 1 and 1 2 WNTW Q 4&5-8 The M/M/1 Queue 0 2 4 6 8 10 0 0.2 0.4 0.6 0.8 1 ρ N  ρ=λ/µ: utilization factor  Long term proportion of time that server is busy  ρ=1-p 0 : holds for any M/G/1 queue  Stability condition: ρ<1 Arrival rate should be less than the service rate 4&5-9 M/M/1 Queue: Discrete-Time Approach  Focus on times 0, δ, 2δ,… (δ arbitrarily small)  Study discrete time process N k = N(δk) Show that transition probabilities are  Discrete time Markov chain, omitting o(δ) lim { ( ) } lim { } k tk PNt n PN n →∞ →∞ == = 00 ,1 ,1 1() 1(), 1 ( ), 0 ( ), 0 ( ), || 1 ii ii ii ij P Pi Pi Pi P i j λ δοδ λδ µδ ο δ λδ ο δ µδ ο δ οδ + − =− + =− − + ≥ =+ ≥ =+ ≥ =−> 0 1 n+1n2 λ δ µ δ λ δ λ δ µ δ λ δ µ δ µ δ 1 λ δµδ −− 1 λ δµδ − − 1 λ δµδ − −1 λ δ − 4&5-10 M/M/1 Queue: Discrete-Time Approach 0 1 n+1n2 λ δ µ δ λ δ λ δ µ δ λ δ µ δ µ δ 1 λ δµδ −− 1 λ δµδ − − 1 λ δµδ − −1 λ δ −  Discrete-time birth-death process → DBE:  Taking the limit δ→0: Done! 1 10 [()]π [()]π () () ππ π () () nn n nn µ δοδ λδοδ λδ οδ λδ οδ µδ ο δ µδ ο δ − − +=+ ⇒   ++ ===   ++   " 00 00 0 () lim π lim lim π () nn nn p p δδ δ λδ ο δ λ µδ ο δ µ →→ →   + =⇒=   +   [...]... system at a given time t depends only on the arrivals (and associated service times) before t Since the arrival processes before arrival times and random times are identical, so is the state of the system they see 4& 5- 1 9 Arrivals that Do not See Time-Averages Example 1: Non-Poisson arrivals IID inter-arrival times, uniformly distributed between in 2 and 4 sec Service times deterministic 1 sec Upon arrival:... system N = λT = PQ ρ (1 − ρ ) + cρ 4& 5- 3 1 M/M/∞ Queue: Infinite-Server System λ λ 0 1 λ 2 µ 2µ λ n nµ n+1 (n + 1)µ Infinite number of servers – no queueing Stationary distribution: (λ / µ ) n − λ / µ pn = e , n = 0,1, n! Poisson with rate λ/µ Average number of customers & average delay: N= λ , µ T= N λ = 1 µ The results hold for an M/G/∞ queue 4& 5- 3 2 M/M/c/c Queue: c-Server Loss System λ λ 0 1 µ λ 2... t →∞ t →∞ 4& 5- 1 8 PASTA Theorem: Intuitive Proof ta and tr: randomly selected arrival and observation times, respectively The arrival processes prior to ta and tr respectively are stochastically identical The probability distributions of the time to the first arrival before ta and tr are both exponentially distributed with parameter λ Extending this to the 2nd, 3rd, etc arrivals before ta and tr establishes.. . 4& 5- 1 1 Transition Probabilities? Ak: number of customers that arrive in Ik=(kδ, (k+1)δ] Dk: number of customers that depart in Ik=(kδ, (k+1)δ] Transition probabilities Pij depend on conditional probabilities: Q(a,d | n) = P{Ak=a, Dk=d | Nk-1=n} Calculate Q(a,d | n) using arrival and departure statistics Use Taylor expansion e-λδ= 1- δ+o(δ), e-µδ= 1- δ+o(δ), to express as a function... arbitrary time 4& 5- 2 1 M/M/* Queues Poisson arrival process Interarrival times: iid, exponential Service times: iid, exponential Service times and interarrival times: independent N(t): Number of customers in system at time t (state) {N(t): t ≥ 0} can be modeled as a continuous-time Markov chain Transition rates depend on the characteristics of the system PASTA Theorem always holds 4& 5- 2 2 M/M/1/K Queue... property (necessary and sufficient condition) 4& 5- 1 6 PASTA Theorem Doesn’t PASTA apply for all arrival processes? Deterministic arrivals every 10 sec Deterministic service times 9 sec Upon arrival: system is always empty a1=0 Average time with one customer in system: p1=0.9 0 1 9 10 20 30 30 “Customer” averages need not be time averages Randomization does not help, unless Poisson! 39 4& 5- 1 7 PASTA Theorem:... time, what is the probability that N(t)=i? Answer: Poisson Arrivals See Time Averages! 4& 5- 1 5 PASTA Theorem Steady-state probabilities: pn = lim P{N (t ) = n} t →∞ Steady-state probabilities upon arrival: an = lim P{N (t − ) = n | arrival at t} t →∞ Lack of Anticipation Assumption (LAA): Future inter-arrival times and service times of previously arrived customers are independent Theorem: In a queueing... 1 customer: p1= α 4& 5- 2 0 Distribution after Departure Steady-state probabilities after departure: d n = lim P{ X (t + ) = n | departure at t} t →∞ Under very general assumptions: N(t) changes in unit increments limits an and exist dn an = dn, n=0,1,… In steady-state, system appears stochastically identical to an arriving and departing customer Poisson arrivals + LAA: an arriving and a departing customer... Generalize: Truncating a Markov chain λ K-1 µ K µ 4& 5- 2 4 Truncating a Markov Chain {X(t): t ≥ 0} continuous-time Markov chain with stationary distribution {pi: i=0,1,…} S a subset of {0,1,…}: set of states; Observe process only in S Eliminate all states not in S Set q ji = qij = 0, j ∈ S , i ∉ S {Y(t): t ≥ 0}: resulting truncated process; If irreducible: Continuous-time Markov chain Stationary distribution... k  pn = , n = 0,1, , c ∑ n !  k =0 k !    Probability of blocking (using PASTA): (λ / µ ) c  c (λ / µ ) k  pc = ∑ c !  k =0 k !    −1 Erlang-B Formula: used in telephony and circuit-switching Results hold for an M/G/c/c queue 4& 5- 3 3 M/M/∞ and M/M/c/c Queues (proof) λ 0 λ λ 1 µ 2 ( nµ ) pn = λ pn −1 ⇒ pn = λ λ λ pn −1 = pn −2 = nµ nµ ( n − 1) µ (λ / µ ) n ⇒ pn = p0 , n = 0,1, n! Normalizing: . 1 TCOM 50 1: Networking Theory & Fundamentals Lectures 4 & 5 February 5 and 12, 2003 Prof. Yannis A. Korilis 4& amp; 5- 2 Topics  Markov Chains  M/M/1 Queue . lim i i tt Tt pPNti t →∞ →∞ === 4& amp; 5- 1 5 PASTA Theorem  Steady-state probabilities:  Steady-state probabilities upon arrival:  Lack of Anticipation Assumption (LAA): Future inter-arrival times and service. ∑ λµλµ λ λλ − = − == 11N T ρ ρ λ λµ ρ µ − == − =−= 1 and 1 2 WNTW Q 4& amp; 5- 8 The M/M/1 Queue 0 2 4 6 8 10 0 0.2 0 .4 0.6 0.8 1 ρ N  ρ=λ/µ: utilization factor  Long term proportion of time that server is busy  ρ=1-p 0 : holds for

Ngày đăng: 22/07/2014, 18:22

Từ khóa liên quan

Tài liệu cùng người dùng

  • Đang cập nhật ...

Tài liệu liên quan