CHAPTER 1 More Differential Equations

A very common type of differential equation is the differential equations of the form \frac{dy}{dt} = ky + l, where both k and l are allowed to be functions of t. Such a differential equation is called linear (because y occurs only to the first power) and, if l ≠ 0, nonhomogeneous. If l = 0, then it is called a linear homogeneous differential equation.

The homogeneous differential equation \frac{dy}{dt} = k(t)y is of the type solved in the last section by separation of variables. However, if l(t) is not zero (and not a constant multiple

of k(t)), then the nonhomogeneous differential equation \frac{dy}{dt} = k(t)y +l(t)y cannot be solved by separation of variables. The method used to solve such a differential equation will not be covered in Math 125 (but you will get it in the next course that you take on differential equations). In this chapter our interest is not in solving these differential equations, but rather in setting them up correctly.

Example 1.1. In Example 18.2 of the last section, suppose that the water pumped into the container is not fresh, but rather has a concentration of 0.4 gm/liter. Find a differential equation for the amount of salt in the water at time t.

As we saw in the last section, the differential equation for the amount of salt y(t) is

\frac{dy}{dt} = r_{1}k − \frac{ry}{V_{0} + (r_{1} − r)t} = 5 · 0.4 − \frac{3y}{100 + 2t} = −\frac{3}{100 + 2t}y + 2,

i.e., our function k(t) is −3/(100 + 2t) and our function l(t) is 2.

Example 1.2. (Heating/cooling with sinusoidal ambient temperature.)

In Newton’s law of cooling we no longer assume that the ambient temperature is constant. Suppose we are interested in the temperature y(t) inside an unheated building under the assumption that the outside temperature is varying sinusoidally between its warmest value in mid-afternoon and its coldest value some time after midnight. For simplicity, we shall choose t = 0 to be the time at which the temperature reaches its average value D (some time in mid-morning). Then when t = 6 it reaches its maximum D + A, when t = 12 it’s back to D, when t = 18 it reaches its minimum D − A, and finally when t = 24 it comes back to D and repeats the temperature values of the day before. The formula for such a sinusoidal function is b(t) = A sin(αt) + D, where in this case α = 2π/24 = π/12 (24 is the period of the sinusoidal function). According to Newton’s law of cooling, we have

\frac{dy}{dt} = −k(y − b) = −k (y − (A sin(αt) + D)) ,

where the constants A and D depend on the range of oscillation of the outside temperature, α = π/12, and k depends on the particular building (the better insulated the building is, the smaller k is). This is a differential equation of the form dy/dt = k(t)y + l(t), where the constant −k is playing the role of k(t), and the function k (A sin(αt) + D) is playing the role of l(t).

Without going through the method of solution, we will give the result — the function y(t) that satisfies this differential equation. Here y(t) is written in terms of t and the constants k, A, D, and y_{0}. It turns out to be convenient to introduce a new constant θ, which is the angle constructed using α as the opposite side and k as the adjacent side (i.e., θ =Arctan(α/k)). See the diagram at the right.

θ k α

It can be shown that

y(t) = D + (y_{0} − D + A sin θ cos θ)e^{−kt} + A cos θ sin(αt − θ).

For large t, the exponential decay term in the formula for y(t) becomes negligible. If we drop that term we obtain the “steady state” solution, which does not depend on our initial value for the building’s temperature. Thus, we arrive at the following formula for the steady state temperature function of the building:

y(t) = D + (A cos θ) sin(αt − θ), where θ = Arctan(α/k) and α = π/12.

The practical interpretation of this formula is that the building’s insulation has two effects:

(1) to decrease the magnitude of temperature oscillation around D, namely by a factor of cos θ = k/\sqrt{k^{2} + α^{2}}, and (2) to cause a “phase shift” of θ (equivalent to a “delay” of 12θ/π hours if θ is measured in radians, or θ/15 hours if θ is measured in degrees).

The practical meaning of the steady state solution is as follows. Suppose that the house is heated to a high temperature y_{0}, and then at time t = 0 the heat is turned off. For a while, the house cools off to the range in which the outside temperature is oscillating (around D). If t is small, then the term

(y_{0} − D + \frac{Akα}{k^{2} + α^{2}} ) e^{−kt}

is important, since it describes this cooling process. But after a while the outside temperature “takes over,” and the inside temperature no longer depends to any significant extent on what the initial inside temperature y_{0} was. As the exponential decay (“cooling”) term becomes negligible, the inside temperature can be described by the steady state solution, which is a purely sinusoidal function, as we have seen.

In Example 2 we admittedly adopted a somewhat unrealistic simplifying assumption to the effect that the outside temperature varies sinusoidally day in and day out. Nevertheless, from a qualitative point of view our solution reveals phenomena that do occur in practice, namely, the decrease in magnitude of oscillation and the phase shift which are caused by the building’s insulation. This explains why on a hot summer day the inside of a house remains hot long after the outside temperature has dropped to a comfortable level.

Homework 1.

1. In Example 18.2, show that the solution given satisfies the initial condition y(0) = y_{0} and also the differential equation. You will have to use the trig formulas for sin(A ± B), cos(A ± B), and also the triangle relating α, k, and θ.

2. In Example 18.2, (a) find a formula for the initial temperature which would cause the building’s temper-

ature function y(t) immediately to equal the steady state function;

(b) explain what happens to the phase shift (time delay) and the oscillation amplitude of the steady state function if the building is very well-insulated (k is near 0) and if the building is very poorly insulated (k is large);

(c) find an approximate formula in terms of k for the time delay in the steady state function if the building is very well-insulated and if it is very poorly insulated (note: the units of k are time^{−1}); (d) if the outside temperature oscillates between 70^{∘}F and 90^{∘}F, reaching 90^{∘}F at 3 p.m., while the inside temperature oscillates between 75^{∘}F and 85^{∘}F, determine when the inside of the building is hottest, and draw a graph of both the outside and inside steady state temperature functions.

3. In Problem 18(b) of the first problem set on differential equations, suppose that the immigration I is only 2 million people/year at time t = 0, but that it increases steadily each year by 250000 people/year. As before, suppose that the country’s population is 300 million at time t = 0, and the death rate exceeds the birth rate by 1%. Write a differential equation for the population function.

4. Suppose that a cup of coffee at temperature y_{0} is brought into a room whose temperature is b at time t = 0 but is increasing at the rate a (in ^{∘}F/min). Let k denote the constant of proportionality in Newton’s law. Find a differential equation for the temperature function y(t).

5. In Problem 6 of the last problem set, suppose that, instead of fresh water, water with 2 gm/liter of salt is entering the vat. As before, the vat contains 100 liters with y_{0} grams of salt at time t = 0, water comes into the vat at 2 + 0.5t liters/min and leaves the vat at 2 liters/min. Give the differential equation satisfied by y(t).

6. Suppose that a vat contains V liters of water and y(t) grams of salt. Water is coming into the vat at constant rate r liters/min and leaving at the same rate. The concentration of salt at time t = 0 is k gm/liters, but this concentration is increasing steadily at α gm/liter each minute. Write a differential equation for y(t).

7. The normal mean temperature in Fairbanks, Alaska is closely approximated by the sinusoidal function

37 sin (\frac{2π}{365}(t − 101)) + 25,

where t is the number of days from the beginning of the year. This formula gives the expected average daily temperature during the t-th day (obtained by averaging the temperature on the t-th day over a 30-year period).^{1}

Suppose that on April 11 you sell a building in Fairbanks (so take April 11, rather than the beginning of the year, to be t = 0). As part of the purchase agreement, you are required to pay for electricity to keep the building heated to 65^{∘}F for the first 4 years. The cost of heating the building is known to be $0.50 for each degree-day below 65^{∘}, and this cost is not expected to change during the 4-year period. That is, at any time t the rate at which the heating bill accumulates is equal to $0.50 times (65 − current temperature). To cover your obligation to pay for heating you leave an amount y_{0} of money with the electric company. The electric company agrees to pay interest k (compounded continuously) on the money, and also each day deduct the heating cost for that day. (We make the simplifying assumption that this is a continuous process, rather than something that happens once a day. In the same way, when writing the above formula for the temperature function in Fairbanks we suppose that t is a continuous variable.)

1This formula for the temperature in Fairbanks is taken from an article by B. M. Lando and C. A. Lando in the September 1977 issue of The Mathematics Teacher.

(a) Write a differential equation for the amount of your money the electric company has at time t.

(b) If k = 0, i.e., if the electric company pays no interest on the money you deposited with them, how much should you leave with them to cover the 4 years’ heating cost?

(c) Now suppose that k is 9\frac{1}{8}% annual interest (i.e., k = 0.09125 yr^{−1} — but be careful to use consistent time units). Find a formula for y(t) in terms of t and the constant y_{0}.

(d) In the situation of part (c), how much money should you leave with the electric company to exactly cover the heating cost for 4 years?

8. At time t = 0 a vat contains 100 liters of water with y_{0} grams of salt. At that time you start letting water flow out of the vat at a rate r(t) that depends on time: the rate starts at 12 liters/min at time t = 0, and it decreases at a liters/min^{2} (until it reaches 0, at which point the experiment stops). There is no water coming into the vat, but someone is sprinkling salt into the water at the rate l gm/min.

(a) Write formulas for r(t) and the volume V (t).

(b) Find the differential equation satisfied by the amount y(t) of salt at time t. (The constants a and l should appear in your differential equation.)

9. At time t = 0 we have x_{0} grams of radioactive substance A and y_{0} grams of radioactive substance B. The former has half-life H_{1}, and so has radioactive decay constant k_{1} = (ln 2)/H_{1}; the latter has a different half-life H_{2} and decay constant k_{2} = (ln 2)/H_{2}. The substance A decays into the substance B, which then, in turn, decays into some nonradioactive substance.

(a) Find a formula for the amount x(t) of A at time t.

(b) Find a differential equation satisfied by the amount y(t) of B at time t.

10. The diagram at the right shows two vats, the first containing V liters of water and the second containing W liters of water. Water with k gm/liter of impurity is entering the first vat at constant rate r, water is passing from the first vat to the second vat at the same rate, and water is leaving the second vat also at rate r. Let x(t) be the amount of impurity in the first vat at time t, and let y(t) be the amount in the second vat at time t.

(a) Find a formula for x(t).

(b) Find a differential equation satisfied by y(t).