Skip to main content

Section 7.5 Modeling with differential equations

We have seen several ways that differential equations arise in the natural world, from the growth of a population to the temperature of a cup of coffee. In this section, we look more closely at how differential equations give us a natural way to describe various phenoma. As we'll see, the key is to understand the different factors that cause a quantity to change.

Preview Activity 7.5.1.

Any time that the rate of change of a quantity is related to the amount of a quantity, a differential equation naturally arises. In the following two problems, we see two such scenarios; for each, we want to develop a differential equation whose solution is the quantity of interest.

  1. Suppose you have a bank account in which money grows at an annual rate of 3%.

    1. If you have $10,000 in the account, at what rate is your money growing?

    2. Suppose that you are also withdrawing money from the account at $1,000 per year. What is the rate of change in the amount of money in the account? What are the units on this rate of change?

  2. Suppose that a water tank holds 100 gallons and that a salty solution, which contains 20 grams of salt in every gallon, enters the tank at 2 gallons per minute.

    1. How much salt enters the tank each minute?

    2. Suppose that initially there are 300 grams of salt in the tank. How much salt is in each gallon at this point in time?

    3. Finally, suppose that evenly mixed solution is pumped out of the tank at the rate of 2 gallons per minute. How much salt leaves the tank each minute?

    4. What is the total rate of change in the amount of salt in the tank?

Subsection 7.5.1 Developing a differential equation

Preview Activity 7.5.1 demonstrates the kind of thinking we will be doing in this section. In each of the two examples we considered, there is a quantity, such as the amount of money in the bank account or the amount of salt in the tank, that is changing due to several factors. The governing differential equation states that the total rate of change is the difference between the rate of increase and the rate of decrease.

Example 7.5.1.

In the Great Lakes region, rivers flowing into the lakes carry a great deal of pollution in the form of small pieces of plastic averaging 1 millimeter in diameter. In order to understand how the amount of plastic in Lake Michigan is changing, construct a model for how this type pollution has built up in the lake.

Solution.

First, some basic facts about Lake Michigan.

  • The volume of the lake is \(5\cdot10^{12}\) cubic meters.

  • Water flows into the lake at a rate of \(5\cdot10^{10}\) cubic meters per year. It flows out of the lake at the same rate.

  • Each cubic meter flowing into the lake contains roughly \(3\cdot10^{-8}\) cubic meters of plastic pollution.

Let's denote the amount of pollution in the lake by \(P(t)\text{,}\) where \(P\) is measured in cubic meters of plastic and \(t\) in years. Our goal is to describe the rate of change of this function; so we want to develop a differential equation describing \(P(t)\text{.}\)

First, we will measure how \(P(t)\) increases due to pollution flowing into the lake. We know that \(5\cdot10^{10}\) cubic meters of water enters the lake every year and each cubic meter of water contains \(3\cdot10^{-8}\) cubic meters of pollution. Therefore, pollution enters the lake at the rate of

\begin{equation*} \left(5\cdot 10^{10} \frac{m^3 \text{ water} }{\text{year} }\right) \left(3\cdot10^{-8} \frac{m^3 \text{ plastic} }{m^3 \text{ water} } \right) = 1.5\cdot 10^3 \text{cubic m of plastic per year}\text{.} \end{equation*}

Second, we will measure how \(P(t)\) decreases due to pollution flowing out of the lake. If the total amount of pollution is \(P\) cubic meters and the volume of Lake Michigan is \(5\cdot 10^{12}\) cubic meters, then the concentration of plastic pollution in Lake Michigan is

\begin{equation*} \frac{P}{5\cdot10^{12}} \text{cubic m of plastic per cubic m of water}\text{.} \end{equation*}

Since \(5\cdot10^{10}\) cubic meters of water flow out each year 1 , then the plastic pollution leaves the lake at the rate of

\begin{equation*} \left(\frac{P}{5\cdot10^{12}} \frac{m^3 \text{ plastic} }{m^3 \text{ water} } \right) \left(5\cdot10^{10} \frac{m^3 \text{ water} }{\text{year} } \right)=\frac{P}{100} \text{cubic m of plastic per year}\text{.} \end{equation*}

The total rate of change of \(P\) is thus the difference between the rate at which pollution enters the lake and the rate at which pollution leaves the lake; that is,

\begin{align*} \frac{dP}{dt} =\mathstrut \amp 1.5\cdot10^{3}-\frac{P}{100}\\ =\mathstrut \amp \frac{1}{100}(1.5\cdot10^{5} - P)\text{.} \end{align*}

We have now found a differential equation that describes the rate at which the amount of pollution is changing. To understand the behavior of \(P(t)\text{,}\) we apply some of the techniques we have recently developed.

Because the differential equation is autonomous, we can sketch \(dP/dt\) as a function of \(P\) and then construct a slope field, as shown in Figure 7.5.2 and Figure 7.5.3.

Figure 7.5.2. Plot of \(\frac{dP}{dt}\) vs. \(P\) for \(\frac{dP}{dt} = \frac{1}{100}(1.5\cdot10^{5} - P)\text{.}\)
Figure 7.5.3. Plot of the slope field for \(\frac{dP}{dt} = \frac{1}{100}(1.5\cdot10^{5} - P)\text{.}\)

These plots both show that \(P=1.5\cdot10^5\) is a stable equilibrium. Therefore, we should expect that the amount of pollution in Lake Michigan will stabilize near \(1.5\cdot10^5\) cubic meters of pollution.

Next, assuming that there is initially no pollution in the lake, we will solve the initial value problem

\begin{equation*} \frac{dP}{dt} = \frac{1}{100}(1.5\cdot10^{5} - P), \ P(0) = 0\text{.} \end{equation*}

Separating variables, we find that

\begin{equation*} \frac1{1.5\cdot10^5-P} \frac{dP}{dt} = \frac1{100}\text{.} \end{equation*}

Integrating with respect to \(t\text{,}\) we have

\begin{equation*} \int \frac1{1.5\cdot10^5-P} \frac{dP}{dt}~dt = \int \frac1{100}~dt\text{,} \end{equation*}

and thus changing variables on the left and antidifferentiating on both sides, we find that

\begin{align*} \int \frac{dP}{1.5\cdot10^5-P} =\mathstrut \amp \int \frac1{100}~dt\\ -\ln|1.5\cdot10^5 - P| =\mathstrut \amp \frac1{100}t + C \end{align*}

Finally, multiplying both sides by \(-1\) and using the definition of the logarithm, we find that

\begin{equation} 1.5\cdot10^5 - P = C e^{-t/100}\text{.}\tag{7.5.1} \end{equation}

This is a good time to determine the constant \(C\text{.}\) Since \(P = 0\) when \(t=0\text{,}\) we have

\begin{equation*} 1.5\cdot 10^5 - 0 = Ce^0 = C\text{,} \end{equation*}

so \(C=1.5\cdot10^5\text{.}\)

Using this value of \(C\) in Equation (7.5.1) and solving for \(P\text{,}\) we arrive at the solution

\begin{equation*} P(t) = 1.5\cdot10^5(1-e^{-t/100})\text{.} \end{equation*}

Superimposing the graph of \(P\) on the slope field we saw in Figure 7.5.3, we see, as shown in Figure 7.5.4

We see that, as expected, the amount of plastic pollution stabilizes around \(1.5\cdot10^5\) cubic meters.

Figure 7.5.4. The solution \(P(t)\) and the slope field for the differential equation \(\frac{dP}{dt} = \frac{1}{100}(1.5\cdot10^{5} - P)\text{.}\)

There are many important lessons to learn from Example 7.5.1. Foremost is how we can develop a differential equation by thinking about the “total rate = rate in - rate out” model. In addition, we note how we can bring together all of our available understanding (plotting \(\frac{dP}{dt}\) vs. \(P\text{,}\) creating a slope field, solving the differential equation) to see how the differential equation describes the behavior of a changing quantity.

We can also explore what happens when certain aspects of the problem change. For instance, let's suppose we are at a time when the plastic pollution entering Lake Michigan has stabilized at \(1.5\cdot10^5\) cubic meters, and that new legislation is passed to prevent this type of pollution entering the lake. So, there is no longer any inflow of plastic pollution to the lake. How does the amount of plastic pollution in Lake Michigan now change? For example, how long does it take for the amount of plastic pollution in the lake to halve?

Resetting \(t=0\) at this time, we now have the initial value problem

\begin{equation*} \frac{dP}{dt} = -\frac{1}{100}P, \ P(0) = 1.5\cdot10^5\text{.} \end{equation*}

It is a straightforward and familiar exercise to find that the solution to this equation is \(P(t) = 1.5\cdot10^5 e^{-t/100}\text{.}\) The time that it takes for half of the pollution to flow out of the lake is given by \(T\) where \(P(T) = 0.75\cdot10^5\text{.}\) Thus, we must solve the equation

\begin{equation*} 0.75\cdot10^5 = 1.5\cdot10^5e^{-T/100}\text{,} \end{equation*}

or

\begin{equation*} \frac12 = e^{-T/100}\text{.} \end{equation*}

It follows that

\begin{equation*} T = -100\,\ln\left(\frac12\right) \approx 69.3 \text{years.} \end{equation*}

In the upcoming activities, we explore some other natural settings in which differential equations model changing quantities.

Activity 7.5.2.

Suppose you have a bank account that grows by 5% every year. Let \(A(t)\) be the amount of money in the account in year \(t\text{.}\)

  1. What is the rate of change of \(A\) with respect to \(t\text{?}\)

  2. Suppose that you are also withdrawing $10,000 per year. Write a differential equation that expresses the total rate of change of \(A\text{.}\)

  3. Sketch a slope field for this differential equation, find any equilibrium solutions, and identify them as either stable or unstable. Write a sentence or two that describes the significance of the stability of the equilibrium solution.

  4. Suppose that you initially deposit $100,000 into the account. How long does it take for you to deplete the account?

  5. What is the smallest amount of money you would need to have in the account to guarantee that you never deplete the money in the account?

  6. If your initial deposit is $300,000, how much could you withdraw every year without depleting the account?

Hint.
  1. Small hints for each of the prompts above.

Activity 7.5.3.

A dose of morphine is absorbed from the bloodstream of a patient at a rate proportional to the amount in the bloodstream.

  1. Write a differential equation for \(M(t)\text{,}\) the amount of morphine in the patient's bloodstream, using \(k\) as the constant proportionality.

  2. Assuming that the initial dose of morphine is \(M_0\text{,}\) solve the initial value problem to find \(M(t)\text{.}\) Use the fact that the half-life for the absorption of morphine is two hours to find the constant \(k\text{.}\)

  3. Suppose that a patient is given morphine intravenously at the rate of 3 milligrams per hour. Write a differential equation that combines the intravenous administration of morphine with the body's natural absorption.

  4. Find any equilibrium solutions and determine their stability.

  5. Assuming that there is initially no morphine in the patient's bloodstream, solve the initial value problem to determine \(M(t)\text{.}\) What happens to \(M(t)\) after a very long time?

  6. To what rate should a doctor reduce the intravenous rate so that there is eventually 7 milligrams of morphine in the patient's bloodstream?

Hint.
  1. Small hints for each of the prompts above.

Subsection 7.5.2 Summary

  • Differential equations arise in a situation when we understand how various factors cause a quantity to change.

  • We may use the tools we have developed so far—slope fields, Euler's methods, and our method for solving separable equations—to understand a quantity described by a differential equation.

Exercises 7.5.3 Exercises

1. Mixing problem.

A tank contains \(1060\) L of pure water. A solution that contains \(0.09\) kg of sugar per liter enters the tank at the rate \(7\) L/min. The solution is mixed and drains from the tank at the same rate.

(a) How much sugar is in the tank at the beginning?

\(y(0) =\) (include units)

(b) With \(S\) representing the amount of sugar (in kg) at time t (in minutes) write a differential equation which models this situation.

\(S' = f(t,S) =\) .

Note: Make sure you use a capital S, (and don't use S(t), it confuses the computer). Don't enter units for this function.

(c) Find the amount of sugar (in kg) after t minutes.

\(S(t) =\) (function of t)

(d) Find the amount of the sugar after 30 minutes.

\(S(30)=\) (include units)

2. Mixing problem.

A tank contains \(50\) kg of salt and \(2000\) L of water. A solution of a concentration \(0.0125\) kg of salt per liter enters a tank at the rate \(5\) L/min. The solution is mixed and drains from the tank at the same rate.

(a) What is the concentration of our solution in the tank initially?

concentration = (kg/L)

(b) Find the amount of salt in the tank after 4 hours.

amount = (kg)

(c) Find the concentration of salt in the solution in the tank as time approaches infinity.

concentration = (kg/L)

3. Population growth problem.

A bacteria culture starts with \(320\) bacteria and grows at a rate proportional to its size. After \(3\) hours there will be \(960\) bacteria.

(a) Express the population after \(t\) hours as a function of \(t\text{.}\)

population: (function of t)

(b) What will be the population after \(6\) hours?

(c) How long will it take for the population to reach \(1970\) ?

4. Radioactive decay problem.

An unknown radioactive element decays into non-radioactive substances. In \(420\) days the radioactivity of a sample decreases by \(30\) percent.

(a) What is the half-life of the element?

half-life: (days)

(b) How long will it take for a sample of \(100\) mg to decay to \(98\) mg?

time needed: (days)

5. Investment problem.

A young person with no initial capital invests \(k\) dollars per year in a retirement account at an annual rate of return \(0.06\text{.}\) Assume that investments are made continuously and that the return is compounded continuously.

Determine a formula for the sum \(S(t)\) -- (this will involve the parameter \(k\)):

\(S(t) =\)

What value of \(k\) will provide \(2513000\) dollars in \(50\) years?

\(k =\)

6.

Congratulations, you just won the lottery! In one option presented to you, you will be paid one million dollars a year for the next 25 years. You can deposit this money in an account that will earn 5% each year.

  1. Set up a differential equation that describes the rate of change in the amount of money in the account. Two factors cause the amount to grow—first, you are depositing one millon dollars per year and second, you are earning 5% interest.

  2. If there is no amount of money in the account when you open it, how much money will you have in the account after 25 years?

  3. The second option presented to you is to take a lump sum of 10 million dollars, which you will deposit into a similar account. How much money will you have in that account after 25 years?

  4. Do you prefer the first or second option? Explain your thinking.

  5. At what time does the amount of money in the account under the first option overtake the amount of money in the account under the second option?

7.

When a skydiver jumps from a plane, gravity causes her downward velocity to increase at the rate of \(g\approx 9.8\) meters per second squared. At the same time, wind resistance causes her velocity to decrease at a rate proportional to the velocity.

  1. Using \(k\) to represent the constant of proportionality, write a differential equation that describes the rate of change of the skydiver's velocity.

  2. Find any equilibrium solutions and decide whether they are stable or unstable. Your result should depend on \(k\text{.}\)

  3. Suppose that the initial velocity is zero. Find the velocity \(v(t)\text{.}\)

  4. A typical terminal velocity for a skydiver falling face down is 54 meters per second. What is the value of \(k\) for this skydiver?

  5. How long does it take to reach 50% of the terminal velocity?

8.

During the first few years of life, the rate at which a baby gains weight is proportional to the reciprocal of its weight.

  1. Express this fact as a differential equation.

  2. Suppose that a baby weighs 8 pounds at birth and 9 pounds one month later. How much will he weigh at one year?

  3. Do you think this is a realistic model for a long time?

9.

Suppose that you have a water tank that holds 100 gallons of water. A briny solution, which contains 20 grams of salt per gallon, enters the tank at the rate of 3 gallons per minute.

At the same time, the solution is well mixed, and water is pumped out of the tank at the rate of 3 gallons per minute.

  1. Since 3 gallons enters the tank every minute and 3 gallons leaves every minute, what can you conclude about the volume of water in the tank.

  2. How many grams of salt enters the tank every minute?

  3. Suppose that \(S(t)\) denotes the number of grams of salt in the tank in minute \(t\text{.}\) How many grams are there in each gallon in minute \(t\text{?}\)

  4. Since water leaves the tank at 3 gallons per minute, how many grams of salt leave the tank each minute?

  5. Write a differential equation that expresses the total rate of change of \(S\text{.}\)

  6. Identify any equilibrium solutions and determine whether they are stable or unstable.

  7. Suppose that there is initially no salt in the tank. Find the amount of salt \(S(t)\) in minute \(t\text{.}\)

  8. What happens to \(S(t)\) after a very long time? Explain how you could have predicted this only knowing how much salt there is in each gallon of the briny solution that enters the tank.

You have attempted of activities on this page.
and we assume that each cubic meter of water that flows out carries with it the plastic pollution it contains