229k views
2 votes
Make a markov chain model for a rat wandering througl1 tl1e fol- lowing maze if, at the end of each period, the rat is equally l~kely to leave its current room through any of the doorways. the center room i an absorbing state. (it never stays in the same room.) i ii 53 ii 4 (b) if the rat starts in room 4, what is the expected number of times it will be in room 2? (c) if the rat starts in room 4, what is the expected rounds until ab- sorption?

User Jvasak
by
8.3k points

1 Answer

3 votes

Final answer:

To create a Markov chain model for a rat wandering through a maze, we need to determine the transition probabilities between each room. The expected number of times the rat will be in a specific room can be calculated using the transition probabilities and expected number of visits to that room starting from different states. Similarly, the expected rounds until absorption can be calculated by finding the expected number of rounds to reach the absorbing state starting from each transient state and taking the average.

Step-by-step explanation:

To create a Markov chain model, we need to first determine the transition probabilities between each room. Since the rat is equally likely to leave its current room through any of the doorways, the transition probabilities will be the same for each room. Let's represent each room as a state, with the center room as an absorbing state (state 0) and the other rooms as transient states (states 1, 2, 3, and 4).

The transition probability matrix for the Markov chain model is as follows:

State0123401000010.250.250.250.25020.250.250.250.25030.250.250.250.25040.250.250.250.250

(b) To find the expected number of times the rat will be in room 2 if it starts in room 4, we need to determine the expected number of visits to room 2 before absorption. Since room 4 is a transient state, the expected number of times the rat will be in room 2 can be calculated using the formula:

E(X|4,2) = 1 + Σ(P(4,i) * E(X|i,2))

where P(4,i) represents the transition probability from state 4 to state i, and E(X|i,2) represents the expected number of visits to room 2 starting from state i. Using the probabilities from the transition matrix, we can calculate the expected number of times the rat will be in room 2 starting from room 4.

(c) To find the expected rounds until absorption if the rat starts in room 4, we can calculate the expected number of rounds it takes for the rat to reach the absorbing state (center room). This can be done by calculating the expected number of rounds to absorption starting from each transient state (rooms 1, 2, 3, and 4) and taking the average. The expected rounds until absorption starting from room 4 can be calculated using the formula:

E(X|4,0) = 1 + Σ(P(4,i) * E(X|i,0))

where P(4,i) represents the transition probability from state 4 to state i, and E(X|i,0) represents the expected rounds until absorption starting from state i. Using the probabilities from the transition matrix, we can calculate the expected rounds until absorption starting from room 4.

User Jerin Joseph
by
8.1k points