Back to homeMathematics · AP Precalculus · Change subject
Start for free
Parametric Functions, Vectors, and Matrices · Vectors and Matrices

Matrices for Modeling Situations

Practise this section (12)

Every Friday, your friend group orders pizza from either Tony's or Slice House. Nobody is perfectly loyal: some Tony's fans try Slice House, and some Slice House fans switch back. If these habits never change, will one shop eventually win most of the customers? Or will the split settle at some fixed balance? Matrices let you answer this without simulating week after week.

Transition Matrices

A state vector lists how many people (or what proportion) are in each state at a given time. For the two pizza shops, let $T_n$ and $S_n$ be the numbers of customers of Tony's and Slice House in week $n$:

$$\mathbf{x}_n=\begin{bmatrix}T_n\\ S_n\end{bmatrix}$$

Each week, people stay or switch. A transition matrix $M$ stores all of those percentages, so that

$$\mathbf{x}_{n+1}=M\,\mathbf{x}_n .$$ Transition diagram: from Tony's (T), 20% switch to Slice House (S) and 80% stay; from S, 30% switch to T and 70% stay. The percentages leaving each state add up to 100%. T S 20% switch to S 30% switch to T 80% stay 70% stay Transition diagram: from Tony's (T), 20% switch to Slice House (S) and 80% stay; from S, 30% switch to T and 70% stay. The percentages leaving each state add up to 100%.

Why must a column sum to 1? Everyone who starts in state $j$ ends up somewhere, either staying or moving, so the proportions must add up to 100%.

Unsure about the theory?Ask about anything you don't understand in this section and the AI will explain it using these notes.
Practice★☆☆Not started
Each month, 90% of the customers of streaming service A stay with A and 10% switch to service B. Of the customers of service B, 80% stay and 20% switch to A. Write the…

Each month, 90% of the customers of streaming service A stay with A and 10% switch to service B. Of the customers of service B, 80% stay and 20% switch to A. Write the transition matrix $M$ so that $\begin{bmatrix}A_{n+1}\\ B_{n+1}\end{bmatrix}=M\begin{bmatrix}A_n\\ B_n\end{bmatrix}$, and check that each column sums to 1.

Solve
Practice★☆☆Not started
For a transition matrix, each column gives the proportions of one state that move to each state. Which of these matrices could be a transition matrix? Explain for each…

For a transition matrix, each column gives the proportions of one state that move to each state. Which of these matrices could be a transition matrix? Explain for each one.

$M_1=\begin{bmatrix}0.7 & 0.4\\ 0.3 & 0.6\end{bmatrix}$, $M_2=\begin{bmatrix}0.5 & 0.5\\ 0.4 & 0.6\end{bmatrix}$, $M_3=\begin{bmatrix}0.8 & 0.1\\ 0.3 & 0.9\end{bmatrix}$

Solve
Practice★☆☆Not started
In the matrix $M=\begin{bmatrix}0.9 & 0.2\\ 0.1 & 0.8\end{bmatrix}$, the first column is for customers of A and the second for customers of B. Explain in words what the…

In the matrix $M=\begin{bmatrix}0.9 & 0.2\\ 0.1 & 0.8\end{bmatrix}$, the first column is for customers of A and the second for customers of B. Explain in words what the entries $0.2$ and $0.1$ represent. Then explain why the total number of customers does not change from month to month.

Solve

Predicting the Next Step

Take next week's number of Tony's customers, $T_{n+1}$. It comes from two groups: Tony's customers who stay (80% of $T_n$) and Slice House customers who switch over (30% of $S_n$):

$$T_{n+1}=0.8\,T_n+0.3\,S_n ,\qquad S_{n+1}=0.2\,T_n+0.7\,S_n .$$

These two equations are exactly the rows of the matrix product $M\mathbf{x}_n$. Each row of $M$ is multiplied by the column vector (row times column, then add).

Unsure about the theory?Ask about anything you don't understand in this section and the AI will explain it using these notes.
Practice★☆☆Not started
Using the transition matrix $M=\begin{bmatrix}0.9 & 0.2\\ 0.1 & 0.8\end{bmatrix}$ for services A and B, suppose there are 600 customers of A and 400 customers of B this…

Using the transition matrix $M=\begin{bmatrix}0.9 & 0.2\\ 0.1 & 0.8\end{bmatrix}$ for services A and B, suppose there are 600 customers of A and 400 customers of B this month. How many customers will each service have next month?

Solve

Powers of the Matrix

To look two weeks ahead, apply $M$ twice:

$$\mathbf{x}_2=M\mathbf{x}_1=M(M\mathbf{x}_0)=M^2\mathbf{x}_0 .$$

In general, $\mathbf{x}_n=M^n\mathbf{x}_0$: the state $n$ steps ahead needs only the starting state and one matrix power. For large $n$, use the matrix feature of your graphing calculator.

What does an entry of $M^n$ mean? It is the proportion that starts in state $j$ and is in state $i$ after $n$ steps. Here is a 3-state example.

Unsure about the theory?Ask about anything you don't understand in this section and the AI will explain it using these notes.
Practice★★☆Not started
Using $M=\begin{bmatrix}0.9 & 0.2\\ 0.1 & 0.8\end{bmatrix}$, compute $M^2$. Then use it to find how many customers each service has two months from now if the current…

Using $M=\begin{bmatrix}0.9 & 0.2\\ 0.1 & 0.8\end{bmatrix}$, compute $M^2$. Then use it to find how many customers each service has two months from now if the current state is $\begin{bmatrix}600\\ 400\end{bmatrix}$.

Solve
Practice★★★Not started
Students choose pizza (P), salad (S), or a sandwich (W) for lunch each day. The transition matrix, with columns indicating yesterday's choice in the order P, S, W, is…

Students choose pizza (P), salad (S), or a sandwich (W) for lunch each day. The transition matrix, with columns indicating yesterday's choice in the order P, S, W, is

$M=\begin{bmatrix}0.6 & 0.2 & 0.3\\ 0.3 & 0.7 & 0.3\\ 0.1 & 0.1 & 0.4\end{bmatrix}$.

Today 200 students chose P, 100 chose S, and 100 chose W.

(a) Find tomorrow's state vector and show the total is unchanged.

(b) Find the proportion of salad-eaters today who will choose pizza two days from now.

(c) Explain why every column of $M$ must sum to 1.

Solve

Steady State

Keep going with the pizza shops: $\mathbf{x}_0=\begin{bmatrix}500\\300\end{bmatrix}$ gives Tony's customers $500,\ 490,\ 485,\ 482.5,\ 481.25,\ 480.625,\dots$

Tony's customers by week (0 to 5): they drop from 500 to 480.6, more and more slowly, approaching the dashed steady-state line at 480, because the difference is cut in half each week. 0 1 2 3 4 5 week Tony's customers (500 at week 0) steady state: 480 Tony's customers by week (0 to 5): they drop from 500 to 480.6, more and more slowly, approaching the dashed steady-state line at 480, because the difference is cut in half each week.

The numbers level off. The gap above 480 goes $20,\ 10,\ 5,\ 2.5,\dots$ and is cut in half each week. After many weeks the state barely changes. That limiting state is the steady state.

To find $\mathbf{s}$, solve $M\mathbf{s}=\mathbf{s}$ together with $a+b=1$.

Notice that the long-run shares do not depend on the starting counts, only on $M$ and on the total. You can confirm this with a calculator: $M^n$ for large $n$ has both columns close to $\mathbf{s}$.

Unsure about the theory?Ask about anything you don't understand in this section and the AI will explain it using these notes.
Practice★★☆Not started
For $M=\begin{bmatrix}0.9 & 0.2\\ 0.1 & 0.8\end{bmatrix}$, a steady-state vector $\mathbf{s}=\begin{bmatrix}a\\ b\end{bmatrix}$ satisfies $M\mathbf{s}=\mathbf{s}$ with…

For $M=\begin{bmatrix}0.9 & 0.2\\ 0.1 & 0.8\end{bmatrix}$, a steady-state vector $\mathbf{s}=\begin{bmatrix}a\\ b\end{bmatrix}$ satisfies $M\mathbf{s}=\mathbf{s}$ with $a+b=1$. Find $\mathbf{s}$ by hand and interpret it as long-run market shares.

Solve
Practice★★☆Not started
Each year 5% of city residents move to the suburbs, and 3% of suburban residents move to the city; everyone else stays. This year 400,000 people live in the city and…

Each year 5% of city residents move to the suburbs, and 3% of suburban residents move to the city; everyone else stays. This year 400,000 people live in the city and 600,000 in the suburbs.

(a) Write the transition matrix, with the city as the first state.

(b) Find the populations next year.

(c) Find the long-run proportion of the population that lives in the city.

Solve
Practice★★★Not started
(Calculator active) Services A and B have transition matrix $M=\begin{bmatrix}0.9 & 0.2\\ 0.1 & 0.8\end{bmatrix}$ and the initial state is…

(Calculator active) Services A and B have transition matrix $M=\begin{bmatrix}0.9 & 0.2\\ 0.1 & 0.8\end{bmatrix}$ and the initial state is $\begin{bmatrix}600\\ 400\end{bmatrix}$.

(a) Use $M^{12}$ to find the number of customers of each service after 12 months.

(b) Compare this with the steady state and explain what the result shows about how fast the system settles.

(c) After a promotion, the proportion of B customers who switch to A each month drops to $0.1$, with A's retention still 0.9. Write the new matrix, find its steady state, and say whether A's long-run share is larger or smaller than before.

Solve

Building and Tuning a Model

Real problems often give you data instead of percentages, or leave an unknown entry to be found. Two habits help: divide each group's counts by that group's total to get a column, and use the fact that columns sum to 1.

Sometimes the unknown controls the steady state. Here is a general pattern.

To judge a claim like "we will eventually hold more than half the customers," find the steady state and compare it with 0.5. Use the long-run share, not the share after one month.

Unsure about the theory?Ask about anything you don't understand in this section and the AI will explain it using these notes.
Practice★★☆Not started
The transition matrix for two gyms is $M=\begin{bmatrix}p & 0.3\\ 1-p & 0.7\end{bmatrix}$. One month the state is $\begin{bmatrix}100\\ 200\end{bmatrix}$ and the next…

The transition matrix for two gyms is $M=\begin{bmatrix}p & 0.3\\ 1-p & 0.7\end{bmatrix}$. One month the state is $\begin{bmatrix}100\\ 200\end{bmatrix}$ and the next month it is $\begin{bmatrix}150\\ 150\end{bmatrix}$.

(a) Find $p$ and check it using the second entry.

(b) Find the state one more month later.

Solve
Practice★★★Not started
A survey of one month's switching among 1,000 customers records: of 400 customers of service A, 340 stay and 60 switch to B; of 600 customers of service B, 480 stay and…

A survey of one month's switching among 1,000 customers records: of 400 customers of service A, 340 stay and 60 switch to B; of 600 customers of service B, 480 stay and 120 switch to A.

(a) Write the transition matrix, with A as the first state, and the state vector after one month.

(b) Find the steady-state proportions.

(c) The marketing team of service A says it will eventually hold more than half the customers. Evaluate that claim.

Solve
Practice★★★Not started
Services A and B have transition matrix $M=\begin{bmatrix}1-p & 0.3\\ p & 0.7\end{bmatrix}$, where $p$ is the proportion of A's customers who switch to B each month. (a)…

Services A and B have transition matrix $M=\begin{bmatrix}1-p & 0.3\\ p & 0.7\end{bmatrix}$, where $p$ is the proportion of A's customers who switch to B each month.

(a) Find $p$ so that the steady state splits customers equally between A and B.

(b) Find $p$ so that A holds 75% of customers in the long run.

(c) Describe how the long-run share of A changes as $p$ increases, and explain why this makes sense.

Solve

Summary

Back to the start: for Tony's and Slice House, $\mathbf{s}=\begin{bmatrix}0.6\\0.4\end{bmatrix}$. In the long run Tony's wins with 60% of the customers, and the split settles after only a few weeks.

Can't find your problem here?

The AI checks one of your exercises: paste the problem with your answer or take a photo of it.

See all the exercises in this section