MATH 20: PROBABILITY Markov Chain Xingru Chen xingru.chen.gr@dartmouth.edu XC 2020
Random Walk 4 1 3 5 2 A ra walk is a mathematical object, known as a stochastic or random process, random that describes a path that consists of a succession of random steps on some β¦ mathematical space such as the integers. XC 2020
Markov Chain 2 4 1 5 3 XC 2020
Specifying a Markov Chain Β§ We describe a Markov chain as follows: We have a set of states, π = π‘ ! , π‘ " , β― , π‘ # . Β§ The process starts in one of π‘ " these states and moves successively from one state to π‘ $ another. Each move is called a step. π‘ ! π‘ % π‘ # XC 2020
Β§ If the chain is currently in state π‘ ! , then it moves to state π‘ " at the π !" next step with a probability π‘ " π $" denoted by π !" . π‘ $ Β§ The probability π !" does not π "& π &" depend upon which states the π‘ ! chain was in before the current state. Β§ These probabilities are called π‘ % transition probabilities. π %& π‘ # XC 2020
Β§ The process can remain in the state it is in, and this occurs with probability π !! . π‘ " π !! π‘ $ π‘ ! π‘ % π %% π‘ # XC 2020
Β§ An initial probability distribution, de fi ned on π , speci fi es the starting state. Usually this is done by specifying a particular state as the starting state. π£ = π£ # π£ $ π£ % π£ & π£ ' π£ " π£ $ 0 1 0 0 0 π‘ $ π£ ! π‘ & ) ( π£ ! = 1 π‘ # !(# π£ % π£ # π‘ ' π‘ % XC 2020
THE LAND OF OZ the Land of Oz is blessed by many things, but Β§ not by good weather. They never have two nice days in a row. If they Β§ have a nice day, they are just as likely to have snow as rain the next day. If they have snow or rain, they have an even Β§ chance of having the same the next day. If there is change from snow or rain, only half Β§ of the time is this a change to a nice day. XC 2020
They never have two nice days in a row. If they have a nice day, they are just as likely to Β§ have snow as rain the next day. 1 1 2 2 XC 2020
If they have snow or rain, they have an even chance of having the same the next day. Β§ 1 1 2 2 1 1 2 2 XC 2020
If there is change from snow or rain, only half of the time is this a change to a nice day. Β§ 1 1 2 2 1 1 4 4 1 1 2 2 XC 2020
If there is change from snow or rain, only half of the time is this a change to a nice day. Β§ 1 1 2 2 1 1 4 4 1 4 1 1 1 2 2 4 XC 2020
R N S β R 1 1 Β§ N 2 2 S 1 1 4 4 1 4 1 1 1 2 2 4 XC 2020
R N S β ) ) ) R 1 1 Β§ * + + N 2 2 S 1 1 4 4 1 4 1 1 1 2 2 4 XC 2020
R N S β ) ) ) R * + + 1 1 Β§ N ) ) 0 2 2 * * S 1 1 4 4 1 4 1 1 1 2 2 4 XC 2020
R N S ) ) ) β * + + R 1 1 Β§ ) ) N 0 2 2 * * S ) ) ) + + * 1 1 4 4 1 4 1 1 1 2 2 4 XC 2020
Β§ States: Β§ π‘ ! : rain Β§ π‘ " : nice 1 1 Β§ π‘ & : snow 2 2 ! ! ! " $ $ ! ! 1 1 Β§ π = 0 " " 4 4 ! ! ! $ $ " 1 4 1 1 1 2 2 4 XC 2020
Transition Matrix Β§ The entries in the fi rst row of the matrix π in the example represent the probabilities for the various kinds of weather following a rainy day. Β§ Similarly, the entries in the second and third rows represent the probabilities for the various kinds of weather following nice and snowy days, respectively. Β§ Such a square array is called the matrix of transition probabilities, or the transition matrix. 1 1 2 2 1 1 1 1 1 2 4 4 4 4 1 1 π = 0 1 2 2 4 1 1 1 4 4 2 1 1 1 2 2 4 XC 2020
1 1 2 2 1 1 1 Β§ States: 1 1 2 4 4 4 4 Β§ π‘ ! : rain 1 1 π = 0 Β§ π‘ " : nice 1 2 2 4 Β§ π‘ & : snow 1 1 1 4 4 2 1 1 1 2 2 4 the probability that, given the chain is in state π today, it οΌ will be in state π tomorrow XC 2020
1 1 2 2 1 1 1 Β§ States: 1 1 2 4 4 4 4 Β§ π‘ ! : rain 1 1 π = 0 Β§ π‘ " : nice 1 2 2 4 Β§ π‘ & : snow 1 1 1 4 4 2 1 1 1 2 2 4 the probability that, given the chain is in (!) = π '( οΌ state π today, it will be in state π π '( tomorrow the probability that, given the chain is in (") = β― οΌ state π today, it will be in state π the day π '( after tomorrow XC 2020
1 1 2 2 1 1 1 Β§ States: 1 1 2 4 4 4 4 Β§ π‘ ! : rain 1 1 π = 0 Β§ π‘ " : nice 1 2 2 4 Β§ π‘ & : snow 1 1 1 4 4 2 1 1 1 2 2 4 οΌ β¦ (") = β― π !& Day 0 Day 1 Day 2 β¦ XC 2020
1 1 2 2 1 1 1 Β§ States: 1 1 2 4 4 Β§ π‘ # : rain 1 1 4 4 π = 0 Β§ π‘ $ : nice 2 2 1 Β§ π‘ % : snow 1 1 1 4 4 4 2 1 1 1 2 2 4 π ## π #% π #$ π $% β¦ (") π !& = π !! π !& + π !" π "& + π !& π && π #% π %% Day 0 Day 1 Day 2 β¦ XC 2020
1 1 1 ($) = π ## π #% + π #$ π $% + π #% π %% π #% Β§ States: 2 4 4 π ## π #$ π #% Β§ π‘ # : rain 1 1 π $# π $$ π $% π = = 0 Β§ π‘ $ : nice 2 2 π %# π %$ π %% Β§ π‘ % : snow 1 1 1 π ## π #$ π #% π #% 4 4 2 π $% π %% π !! π !# π ## π #$ π #% π ## π #$ π #% π !" π "# π $ = π $# π $$ π $% π $# π $$ π $% β¦ 2 π %# π %$ π %% π %# π %$ π %% ($) π !# π ## π #% = β¦ Day 0 Day 1 Day 2 XC 2020
π !! π !# ($) = π ## π #% + π #$ π $% + π #% π %% π !" π "# π #% β¦ % = ( π #, π ,% ,(# π !# π ## β¦ Day 0 Day 1 Day 2 π !! π !# π !" π "# ($) = π ## π #% + π #$ π $% + β― + π #- π -% π #% β¦ - β¦ π !β― π β―# = ( π #, π ,% ,(# π !& π &# β¦ Day 0 Day 1 Day 2 XC 2020
π !! π !# π ## π #$ π #% π ## π #$ π #% π $ = π $# π $$ π $% π $# π $$ π $% π !" π "# 2 β¦ π %# π %$ π %% π %# π %$ π %% ($) π #% π !# π ## = β¦ Day 0 Day 1 Day 2 π ## π #$ π #% ) π ) = π $# π $$ π $% οΌ β¦ β¦ οΌ π %# π %$ π %% ()) π #% Day 0 Day 1 Day 2 Day β¦ Day n β¦ = XC 2020
Transition Matrix Β§ Let π be the transition matrix of a Markov chain. π + gives Β§ The ππ th entry π '( of the matrix the probability that the Markov chain, starting in state π‘ ' , will be in state π‘ ( after π steps. π ## π #$ π #% ) π ) = π $# π $$ π $% οΌ β¦ β¦ οΌ π %# π %$ π %% ()) π #% Day 0 Day 1 Day 2 Day β¦ Day n β¦ = XC 2020
π !# π£ ! Β§ Starting states: the probability that Β§ Β§ rain: π£ # π "# the chain is in state Β§ nice: π£ $ β¦ π£ " π‘ ( after π steps: Β§ snow: π£ % π = 3 Β§ π£ # π ## π = 1 Β§ π£ = π£ ! π£ " π£ & Day 0 Day 1 β¦ (#) = π£ # π #% + π£ $ π $% + π£ % π %% π£ % Transition matrix: Β§ π !! π !" π !# π !" π !# π "! π "" π "# π = π ## π #$ π #% π #! π #" π ## π "! π #! π£ # π£ $ π£ % 1 1 1 π $# π $$ π $% π %# π %$ π %% 2 4 4 π "# 1 1 = 0 2 2 1 1 1 π #" (#) = π£π π£ (#) = π£ # (#) (#) π£ $ π£ % 4 4 2 π "" π ## XC 2020
π !# (#) = π£ # π #% + π£ $ π $% + π£ % π %% π£ ! π£ % the probability Β§ π "# that the chain is β¦ π£ " in state π‘ ( after (#) = π£ # π #, + π£ $ π $, + π£ % π %, π£ , π steps: π£ # π ## π = 1 Β§ (#) = π£π π£ (#) = π£ # (#) (#) π£ $ π£ % Day 0 Day 1 β¦ # (") = π !! π !# + π !" π "# + π !# π ## = . π !! π !# π !( π (# π !# π£ ! (+! π !" the probability Β§ (") = π£ ! π !# (") + π£ " π "# (") + π£ # π ## π "# (") π£ # that the chain is β¦ π£ " in state π‘ ( after π !# π steps: (") = π£ ! π !( (") + π£ " π "( (") + π£ # π #( (") π£ ( π£ # π ## π = 2 Β§ (") = π£π " π£ (") = π£ ! (") (") π£ " π£ # β¦ Day 0 Day 1 Day 2 XC 2020
Recommend
More recommend