# Constructing a probability transition matrix with given system. Help in enumerating the states.

If the weather can either be sunny or rainy on a particular day, and the probability of sun on any particular day depends on the weather in the previous two days, assume the following is true: $$P[\text{sun today}] = \begin{cases} \frac{1}{6} \text{ if }r = 2 \\ \frac{1}{3} \text{ if }r = 1 \\ \frac{1}{2} \text{ if }r = 0 \\ \end{cases}$$ where $r$ is the number of rainy days in the previous two days.

What is the PTM of this Markov chain?

I'm not sure how to enumerate the states of this chain.

• Will be easier both for you to understand and for others to answer if you include the definitions in the question. – mathreadler Oct 3 '16 at 21:56
• A hint is that you can represent the space of one yes/no event on two consecutive days as two-bit binary number. – mathreadler Oct 3 '16 at 22:11
• Following @mathreadler's suggestion, you have a 4-state chain and a $4 \times 4$ transition matrix P. State space might be $\{00, 01, 10, 11\}.$ where 1=sun and 0=rain, and 00 means two rainy days in a row. – BruceET Oct 3 '16 at 23:08

You consider two recent days and each day has two possibilities. Therefore, you have four states. Let R represent rainy and S sunny. So the states are: RR, RS, SR, SS.
So for instance if you are in the state RR, you go to state RS with probability $\frac{1}{6}$ and remain in that state with probability $1-\frac{1}{6}$. Hence the transtion matrix becomes
$\hspace{6.75cm}$RR$\hspace{5mm}$ RS$\hspace{4mm}$ SR$\hspace{4mm}$ SS $$\begin{bmatrix} 1-\frac{1}{6}&\frac{1}{6} & 0 & 0\\ 0&0 & 1-\frac{1}{3} & \frac{1}{3}\\ 1-\frac{1}{3}&\frac{1}{3} & 0 & 0\\ 0&0 & 1-\frac{1}{2} & \frac{1}{2} \end{bmatrix}$$
• Hi I got $\begin{bmatrix} \frac{5}{6} & \frac{1}{6} & 0 & 0 \\ 0 & 0 & \frac{4}{6} & \frac {2}{6} \\ \frac{4}{6} & \frac{2}{6} & 0 & 0 \\ 0 & 0 & \frac{1}{2} & \frac{1}{2} \end{bmatrix}$ – MoronicHero Oct 3 '16 at 23:45