18 175 lecture 30 markov chains
play

18.175: Lecture 30 Markov chains Scott Sheffield MIT 1 18.175 - PowerPoint PPT Presentation

18.175: Lecture 30 Markov chains Scott Sheffield MIT 1 18.175 Lecture 30 Outline Review what you know about finite state Markov chains Finite state ergodicity and stationarity More general setup 2 18.175 Lecture 30 Outline Review what you know


  1. 18.175: Lecture 30 Markov chains Scott Sheffield MIT 1 18.175 Lecture 30

  2. Outline Review what you know about finite state Markov chains Finite state ergodicity and stationarity More general setup 2 18.175 Lecture 30

  3. Outline Review what you know about finite state Markov chains Finite state ergodicity and stationarity More general setup 3 18.175 Lecture 30

  4. Markov chains � Consider a sequence of random variables X 0 , X 1 , X 2 , . . . each taking values in the same state space, which for now we take to be a finite set that we label by { 0 , 1 , . . . , M } . � Interpret X n as state of the system at time n . � Sequence is called a Markov chain if we have a fixed collection of numbers P ij (one for each pair i , j ∈ { 0 , 1 , . . . , M } ) such that whenever the system is in state i , there is probability P ij that system will next be in state j . � Precisely, P { X n +1 = j | X n = i , X n − 1 = i n − 1 , . . . , X 1 = i 1 , X 0 = i 0 } = P ij . � Kind of an “almost memoryless” property. Probability distribution for next state depends only on the current state (and not on the rest of the state history). 4 18.175 Lecture 30

  5. Simple example For example, imagine a simple weather model with two states: � � rainy and sunny. If it’s rainy one day, there’s a . 5 chance it will be rainy the � � next day, a . 5 chance it will be sunny. If it’s sunny one day, there’s a . 8 chance it will be sunny the � � next day, a . 2 chance it will be rainy. In this climate, sun tends to last longer than rain. � � Given that it is rainy today, how many days to I expect to � � have to wait to see a sunny day? Given that it is sunny today, how many days to I expect to � � have to wait to see a rainy day? Over the long haul, what fraction of days are sunny? � � 5 18.175 Lecture 30

  6. Matrix representation To describe a Markov chain, we need to define P ij for any � � i , j ∈ { 0 , 1 , . . . , M } . It is convenient to represent the collection of transition � � probabilities P ij as a matrix: ⎛ P 00 P 01 . . . P 0 M ⎞ P 10 P 11 . . . P 1 M ⎜ ⎟ ⎜ ⎟ · ⎜ ⎟ A = ⎜ ⎟ · ⎜ ⎟ ⎜ ⎟ · ⎝ ⎠ P M 0 P M 1 . . . P MM For this to make sense, we require P ij ≥ 0 for all i , j and � � M P ij = 1 for each i . That is, the rows sum to one. j =0 6 18.175 Lecture 30

  7. Transitions via matrices Suppose that p i is the probability that system is in state i at � � time zero. What does the following product represent? � � ⎛ . . . ⎞ P 00 P 01 P 0 M P 10 P 11 . . . P 1 M ⎜ ⎟ ⎜ ⎟ · ⎜ ⎟ p 0 p 1 . . . p M ⎜ ⎟ · ⎜ ⎟ ⎜ ⎟ · ⎝ ⎠ P M 0 P M 1 . . . P MM Answer: the probability distribution at time one. � � How about the following product? � � A n p 0 p 1 . . . p M Answer: the probability distribution at time n . � � 7 18.175 Lecture 30

  8. Powers of transition matrix ( n ) We write P for the probability to go from state i to state j � � ij over n steps. From the matrix point of view � � ( n ) ( n ) ( n ) ⎛ ⎞ n . . . P P P ⎛ . . . ⎞ P 00 P 01 P 0 M 00 01 0 M ( n ) ( n ) ( n ) P 10 P 11 . . . P 1 M P P . . . P ⎜ ⎟ ⎜ ⎟ 10 11 1 M ⎜ ⎟ ⎜ ⎟ · ⎜ · ⎟ ⎜ ⎟ = ⎜ ⎟ ⎜ ⎟ · ⎜ · ⎟ ⎜ ⎟ ⎜ ⎟ ⎜ ⎟ ⎜ ⎟ · · ⎝ ⎠ ⎝ ⎠ ( n ) ( n ) ( n ) P M 0 P M 1 . . . P MM . . . P P P M 0 M 1 MM If A is the one-step transition matrix, then A n is the n -step � � transition matrix. 8 18.175 Lecture 30

  9. Questions What does it mean if all of the rows are identical? � � Answer: state sequence X i consists of i.i.d. random variables. � � What if matrix is the identity? � � Answer: states never change. � � What if each P ij is either one or zero? � � Answer: state evolution is deterministic. � � 9 18.175 Lecture 30

  10. Simple example Consider the simple weather example: If it’s rainy one day, � � there’s a . 5 chance it will be rainy the next day, a . 5 chance it will be sunny. If it’s sunny one day, there’s a . 8 chance it will be sunny the next day, a . 2 chance it will be rainy. Let rainy be state zero, sunny state one, and write the � � transition matrix by . 5 . 5 A = . 2 . 8 Note that � � . 64 . 35 A 2 = . 26 . 74 . 285719 . 714281 Can compute A 10 = � � . 285713 . 714287 10 18.175 Lecture 30

  11. Does relationship status have the Markov property? In a relationship It’s complicated Single Married Engaged Can we assign a probability to each arrow? � � Markov model implies time spent in any state (e.g., a � � marriage) before leaving is a geometric random variable. Not true... Can we make a better model with more states? � � 11 18.175 Lecture 30

  12. Outline Review what you know about finite state Markov chains Finite state ergodicity and stationarity More general setup 12 18.175 Lecture 30

  13. Outline Review what you know about finite state Markov chains Finite state ergodicity and stationarity More general setup 13 18.175 Lecture 30

  14. Ergodic Markov chains Say Markov chain is ergodic if some power of the transition � � matrix has all non-zero entries. Turns out that if chain has this property, then � � π j := lim n →∞ P ( n ) exists and the π j are the unique ij M non-negative solutions of π j = π k P kj that sum to one. k =0 This means that the row vector � � π = π 0 π 1 . . . π M is a left eigenvector of A with eigenvalue 1, i.e., π A = π . We call π the stationary distribution of the Markov chain. � � One can solve the system of linear equations � � M π j = π k P kj to compute the values π j . Equivalent to k =0 considering A fixed and solving π A = π . Or solving ( A − I ) π = 0. This determines π up to a multiplicative constant, and fact that π j = 1 determines the constant. 14 18.175 Lecture 30

  15. Simple example . 5 . 5 If A = , then we know � � . 2 . 8 . 5 . 5 π A = π 0 π 1 = π 0 π 1 = π. . 2 . 8 This means that . 5 π 0 + . 2 π 1 = π 0 and . 5 π 0 + . 8 π 1 = π 1 and � � we also know that π 1 + π 2 = 1. Solving these equations gives π 0 = 2 / 7 and π 1 = 5 / 7, so π = 2 / 7 5 / 7 . Indeed, � � . 5 . 5 π A = 2 / 7 5 / 7 = 2 / 7 5 / 7 = π. . 2 . 8 Recall that � � . 285719 . 714281 2 / 7 5 / 7 π A 10 = ≈ = . 285713 . 714287 2 / 7 5 / 7 π 15 18.175 Lecture 30

  16. Outline Review what you know about finite state Markov chains Finite state ergodicity and stationarity More general setup 16 18.175 Lecture 30

  17. Outline Review what you know about finite state Markov chains Finite state ergodicity and stationarity More general setup 17 18.175 Lecture 30

  18. Markov chains: general definition Consider a measurable space ( S , S ). � � A function p : S × S → R is a transition probability if � � � For each x ∈ S , A → p ( x , A ) is a probability measure on S , S ). � For each A ∈ S , the map x → p ( x , A ) is a measurable function. Say that X n is a Markov chain w.r.t. F n with transition � � probability p if P ( X n +1 ∈ B |F n ) = p ( X n , B ). How do we construct an infinite Markov chain? Choose p and � � initial distribution µ on ( S , S ). For each n < ∞ write P ( X j ∈ B j , 0 ≤ j ≤ n ) = µ ( dx 0 ) p ( x 0 , dx 1 ) · · · B 0 B 1 p ( x n − 1 , dx n ) . B n Extend to n = ∞ by Kolmogorov’s extension theorem. 18 18.175 Lecture 30

  19. Markov chains Definition, again: Say X n is a Markov chain w.r.t. F n with � � transition probability p if P ( X n +1 ∈ B |F n ) = p ( X n , B ). Construction, again: Fix initial distribution µ on ( S , S ). For � � each n < ∞ write P ( X j ∈ B j , 0 ≤ j ≤ n ) = µ ( dx 0 ) p ( x 0 , dx 1 ) · · · B 0 B 1 p ( x n − 1 , dx n ) . ( ) B n Extend to n = ∞ by Kolmogorov’s extension theorem. Notation: Extension produces probability measure P µ on � � sequence space ( S 0 , 1 ,... , S 0 , 1 ,... ). Theorem: ( X 0 , X 1 , . . . ) chosen from P µ is Markov chain. � � Theorem: If X n is any Markov chain with initial distribution � � µ and transition p , then finite dim. probabilities are as above. 19 18.175 Lecture 30

  20. Examples Random walks on R d . � � i Branching processes: p ( i , j ) = P m =1 ξ m = j where ξ i are � � i.i.d. non-negative integer-valued random variables. Renewal chain. � � Card shuffling. � � Ehrenfest chain. � � 20 18.175 Lecture 30

  21. MIT OpenCourseWare http://ocw.mit.edu 18.175 Theory of Probability Spring 2014 For information about citing these materials or our Terms of Use, visit: http://ocw.mit.edu/terms.

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend