Download Lecture 1 - Differential Equations

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project

Document related concepts

Derivative wikipedia , lookup

Multiple integral wikipedia , lookup

Function of several real variables wikipedia , lookup

Generalizations of the derivative wikipedia , lookup

Fundamental theorem of calculus wikipedia , lookup

Partial differential equation wikipedia , lookup

Transcript
Lecture 1 - Differential Equations
In this lecture, we will learn what are differential equations and see how they are applied to solving
problems in physics, biology, and other sciences.
Problem: A person is walking with velocity 5 miles/hour.
a) Where is the person after 2 hours?
b) Where is the person after t hours?
There is information missing from this problem! What is missing?
Well, we need to know where the person started walking from!
Draw a number-line with 0 in the middle to represent the road with the number marks representing mile
markers.
Say the person started at the −1 mile marker.
How do we know that the person is walking in the direction of the red arrow?
Velocity can be a positive or a negative quantity. If velocity is positive, this indicates that the object is
moving in the direction of increasing markers. If the velocity is negative, this indicates that the object is
moving in the direction of decreasing markers. Speed is the absolute value of velocity, therefore speed is
always a positive quantity. When you give the object’s speed instead of velocity, you lose the information
about direction.
Solution:
a) After 2 hours, the person is at the 9 mile marker.
b) After t hours, the person is at the 5t − 1 mile marker.
Congratulations! You just solved a differential equation!
To see what differential equations are about, let us express the problem using functions.
There are two functions we are interested in:
1) v(t)-velocity
What do we know about v(t) from the problem?
v(t) = 5 (miles/hour)
We call such functions “constant” because they do not depend on t.
2) l(t)-location
What do we know about l(t) from the problem?
l(0) = −1 (miles)
a) Find l(2).
Answer: l(2) = 9
b) Find l(t).
Answer: l(t) = 5t − 1
This problem can also be solved using Calculus. Let us review a bit about Calculus.
The subject of Calculus is about derivatives and integrals.
Given a function y = f (x), we can calculate derivative function y 0 .
dy
.
Other notations for the derivative function are f 0 (x) or
dx
The derivative function gives the slope of the tangent line to f (x) at x.
Example:
1
2
f (x) = x2
f 0 (x) = 2x.
For example, since f 0 (1) = 2, the slope of the tangent line at x = 1 is 2.
If f (x) expresses some physical relationship, then f 0 (x) represents the rate of change of the relationship.
dy
Hence the notation
(read: difference of y values/difference of x values)!
dx
Now we get back to our velocity problem and reformulate it using derivatives. The location of the walking
person walking is given by l(t). The rate at which the location of the person changes is, of course, the
velocity of the person v(t).
dl
miles/hour
v(t) =
dt
So dl = 5 (miles/hour). But how do we recover l(t) from this equation?
dt
This is where the second key concept of Calculus, the integral of a function comes in.
Given a function f (x), we can find an antiderivative function F (x), that is a function whose derivative is
f (x): F 0 (x) = f (x).
A function NEVER has a UNIQUE antiderivative function. If there is one antiderivative, then there are
infinitely many!
Example: Find 3 antiderivatives F (x) of f (x) = 2x.
Antiderivatives:
1) F (x) = x2
2) F (x) = x2 + 1
3) F (x) = x2 − 3
Any function of the form F (x) = x2 + C is an antiderivative of f (x) = 2x!
Also, antiderivatives of a function can differ only by a constant, so these are ALL the antiderivatives!
In order to pinpoint a particular antiderivative function, that is in order to determine C, we need to know
any single point on the function.
Example: Find the antiderivative F (x) of f (x) = 2x such that F (2) = 1.
F (x) = x2 + C
F (2) = 22 + C = 1
4+C =1
C = −3
F (x) = x2 − 3!
Antiderivatives are also called integrals. To integrate means to sum.
So what do antiderivatives have to do with SUMS?
If we want to find the area of a geometrical object such as a circle, a triangle, or a square, we can use a
formula. But for many problems, we need to be able to find the area of a shape bounded by a function f (x).
3
In Calculus, we learn to find such areas by taking the limit of approximations using sums of rectangles:
The area of each rectangle is f (xi ) · ∆x and the area under the curve is approximated by taking the sum of
the areas of all the rectangles. As you make ∆x (the width of the rectangles) smaller and smaller you get a
better and better approximation. So if you take the limit of these improving approximations as ∆x → 0,
you will get the exact area. We call this process “integrating f (x) from a to b”. The mathematical
notation we use is:
Z b
f (x) dx
a
R
This notation was chosen very cleverly! The symbol is a stylized letter S standing for sum. So we read
Rb
f (x) dx as “the sum from x = a to x = b of the areas f (x) · dx”, where dx is just another notation for
a
Rb
∆x. Understanding the notation is well and good, but in order to compute a f (x) dx, it looks like we
might need to compute lots of sums of areas and see what the limit is tending to. Knowing about
antiderivatives spares us the need to do such computations. Given a function f (x) and its antiderivative
F (x), it turns out that:
Z b
f (x) dx = F (b) − F (a)
a
So to find the area under the curve f (x) from x = a to x = b, we need to find ANY antiderivative function
F (x) and compute the difference F (b) − F (a). No areas or limits needed! So antiderivatives are used for
integrating.
Notation:
Rb
Definite integral: aR f (x) dx = F (b) − F (a) (answer is numerical!)
Indefinite integral: f (x) dx = F (x) (answer should contain C!)
2
R2
Example: 1 2x dx = x2 + C = 22 + C − (12 + C) = 4 + C − (1 + C) = 4 + C − 1 − C = 3.
1
4
The C’s will always cancel out so we might as well use the simplest antiderivative with C = 0!
If we can can find the exact expression for the integral F (x) of a function f (x), we can compute the area
under f (x). The relationship also works backwards: we can a use computation for the area under f (x) to
compute the the integral F (x).
2
Example: Find the integral F (x) of f (x) = e−x such that F (2) = 3.
Unfortunately we cannot apply Calculus to find the exact expression for this integral. The best we can do
is to numerically approximate F (x)!
For example, if we need to compute F (7):
R7
2
Step 1: Approximate 2 e−x dx ≈ n using sums of rectangles (a computer program could be very useful
here!).
R7
2
Step 2: 2 e−x dx = F (7) − F (2) = F (7) − 3 ≈ n.
Step 3: F (7) ≈ n + 3!!!
Thus, we succeeded in using areas to approximate the integral function!
Now we reviewed everything we will need to start talking about differential equations, so let us get back to
our first velocity problem!
We are given the information: v(t) = dl = 5 miles/hour.
dt
This statement is a differential equation.
A differential equation is an equation involving derivatives!
We are also given the information: l(0) = −1 miles.
This statement is an initial condition for a differential equation.
An initial condition is ANY point on the function whose derivatives we are given in the differential
equation.
The question is to findRl(t).
Using Calculus, l(t) = 5 dt = 5t + C.
l(0) = 5 · 0 + C = −1
C = −1
l(t) = 5t − 1
2
Problem: A person is walking with acceleration a(t) = 6 miles/hour .
a) Find the velocity v(t) and the location l(t) if v(0) = 1 mile/hour and l(0) = 0 miles.
b) Find where the person is after 2 hours.
Solution:
a) Acceleration is the rate of change of velocity: a(t) = dv .
dt
2
(This is why the units are miles/hour/hour = miles/hour .)
dv = 6
dt
R
v(t) = 6 dt = 6t + C.
v(0) = 1
v(0) = 6 ∗ 0 + C = 1 C = 1
v(t) = 6t + 1 miles/hour
R
dl = 6t + 1 l(t) = 6t + 1 dt = 3t2 + t + D
dt
l(0) = −1
l(0) = 3 ∗ 02 + 0 + D = 0
D=0
l(t) = 3t2 + t miles
b) l(2) = 3 ∗ 22 + 2 = 14 miles.
What is wrong with the following reasoning?
v(t) = 6t + 1 and so v(0) = 1 and v(1) = 7.
After 1 hour the person walked 1 mile and after another hour the person walked 7 miles. Therefore after
two hours the person walked 1+7=8 miles.
But in part (b) above we got the answer 14 miles!
5
The reasoning is false because in the first hour velocity steadily (the mathematical term is continuously)
increases from 1 mile/hour to 7 miles/hour. It does NOT stay 1 mile during the first hour and then
suddenly jump to 7 miles in the next hour. For example, after first half hour the velocity is already 4
miles/hour!
Remember that having negative velocity means that the person is moving in the direction of decreasing
markers. But what does it mean to have negative acceleration?
If acceleration is negative does it mean that the moving object is slowing down? Not always!
2
Suppose acceleration is −2 miles/hour , velocity is −5 miles/hour. Then after one hour the velocity will
increase to -7 miles/hour. So the person is actually speeding up!
Case 1: a(t) > 0, v(t) > 0 −→ object is speeding up
Case 2: a(t) > 0, v(t) < 0 −→ object is slowing down
Case 3: a(t) < 0, v(t) < 0 −→ object is speeding up
Case 4: a(t) < 0, v(t) > 0 −→ object is slowing down
2
Problem: The acceleration of a ball dropped off a cliff is given by a(t) = 9.8 − v(t)/5 m/s . Find v(t).
In the “cliff and ball” problems, the equations are always given with the assumption that the number-line
is placed as in the image above. The cliff is at the 0 marker, the positive direction is downward and the
negative direction is upward. This makes the velocity positive and the equations easier. Here is the
intuition behind the acceleration equation. The number 9.8 is the downward acceleration due to gravity.
But there is also something pushing the ball up: air resistance. Air resistance gets larger as the velocity
gets larger. (In mathematical terms, we say that air resistance is proportional to velocity.) Material hits
back with more force when you hit it with more force! So air resistance is 1/5 of velocity (experimentally
calculated).
dv = 9.8 − v(t)/5 miles/hour2
dt
R
v(t) = 9.8 − v(t)/5 dt.
But now we are stuck because we do not know what v(t) is in the first place! That is why we need to learn
about differential equations!
The first method we will learn to study differential equations will not give us an exact solution. Instead it
will give us a visual of what the solution looks like. So next we learn how to draw the direction field of a
6
differential equation. Because this is computationally very tedious, once we understand what a direction
field is we will use computer software to draw them for us.
Obviously we cannot plot v(t) because we have no idea what it is! But since we are given an equation for
a(t) = dv , we know the slopes of the tangent lines to every point on the graph of v(t). The direction
dt
field is a plot of these slopes!
Examples:
If v(t) = 10, then dv = 9.8 − 10/5 = 7.8. So the slope of the tangent line to the graph of v(t) wherever
dt
v(t) = 10 is 7.8. Using this calculation repeatedly, we make the table of values:
v(t) dv
dt
10 7.8
20 5.8
30 3.8
40 1.8
50 -0.2
60 -2.2
70 -4.2
A computer software uses such a table of values to generate a direction field. Each arrow represents a
tangent line with the slope calculated as in our table above. As in our table, we see that the tangent lines
have positive slope before v(t) = 50 and negative slopes afterwards.
By following the slopes of the tangent lines we can trace out the graph of v(t).
7
How did we know to use the range v(t) = 10 to v(t) = 70? We will see below.
Observations:
a) Different curves represent solutions based on different initial velocities.
b) If initial velocity is small, then it will increase until gravity and air resistance balance each other out.
c) If initial velocity is large, then it will decrease until gravity and air resistance balance each other out.
d) If we start with a certain initial velocity, then there is an immediate balance between gravity and air
resistance, so the velocity stays the same and the acceleration is 0!
Can we calculate this special initial velocity?
Yes! We solve the equation a(t) = 0!
0 = 9.8 − v(t)/5
v(t) = 49
The solution v(t) = 49 is called the equilibrium solution.
The equilibrium solution is the solution where the rate of change is equal 0.
Notice that as t → ∞, all solutions approach the equilibrium solution. So to make good observations about
the behavior of solutions from the direction field, it helps to pick the range around the equilibrium solution!
Problem: Mice and Owls
In the absence of predators, the mouse population increases at the rate proportional to the current
population p(t). (Remember “proportional” means “a multiple of”.)
dp
= rp(t) mice/month
dt
Experimentally it is determined that r is 0.5 1/month. Here is why the units for the quantity r is
“1/month”: the product of the units of r and the units of p(t) should give the units of the product rp(t).
The quantity p(t) is in units “mice” and the product rp(t) is in units “mice/month”. So units “ ” times
“mice” is “mice/month”. It is clear that “ ” should be “1/month”.
dp
= 0.5p(t) mice/month
dt
Several owls live in the neighborhood and they eat on average 15 mice a day.
dp
= 0.5p(t) − 450
dt
Why 450? Because 15 mice a day means 450 mice a month and our unit is month.
As before, we cannot yet find p(t), but we can plot a direction field and get an idea of what the solutions
behave like! To obtain the range for the plot, we look for the equilibrium solution(s) (there can be more
8
than one!). The equilibrium solution is where the rate of change of the population is 0: the number of
newly born mice exactly replaces the mice that are eaten.
0 = 0.5p(t) − 450
450 = 0.5p(t)
p(t) = 900.
Observations:
a) If the initial number of mice is under 900, the mice will all be eaten.
b) If the initial number of mice is over 900, the population will grow out of control.
Shortcomings of model:
a)The model is only useful for short term analysis. In the long run, more complications would have to be
taken into account. For example, as there are more mice to eat, there will be an increase in the owl
population and therefore an increase in the number of mice eaten, etc.
b) Differential equations are most effective in modeling continuous processes. A person walking will
continuously speed up, but obviously the mice are NOT being eaten continuously and they are NOT being
born continuously. The processes involved are the opposite of continuous, they are discrete.
Problem: A pond initially contains 1,000,000 gal of water and some amount of an undesirable chemical.
Water containing 0.01 g of this chemical per gallon flows into the pond at a rate of 300 gal/h. The mixture
flows out at the same rate, so the amount of water in the pond remains constant. Assume that the
chemical is uniformly distributed throughout the pond.
a) Write a differential equation for the amount of chemical in the pond at any time.
b) How much of the chemical will be in the pond after a very long time?
Solution:
a) Call c(t) the function for the number of grams of chemical in the pond at time t. We need to write an
equation for rate of change of amount of chemical in the pond dc g/h. There are two processes changing
dt
the amount of chemical. The water flowing in is increasing the amount of chemical in the pond and the
water flowing out is decreasing it. The water flowing in contains 0.01 g of the chemical per gallon and it
flows into the pond at the rate of 300 gal/h. Therefore the amount of chemical increases at the rate of
300 · 0.01 = 3 g/h. Based on the information so far: dc = 3 g/h. We are not done because we need to
dt
account for the amount of chemical carried out by the water leaving the pond. The water flows out of the
pond at the same rate that it flows in, namely 300 gal/h. As above, we need to multiply 300 by the amount
of chemical each gallon contains. The amount of chemical in the entire pond depends on t and is equal to
c(t). The number of gallons in the entire pond is 1,000,000. So the amount in every gallon is
9
c(t)/1, 000, 000. So the amount of chemical leaving the pond every hour is
300 · c(t)/1, 000, 000 = 3/10, 000c(t) g/h.
dc
= 3 − 3/10, 000c(t) g/gal
dt
b) To decide how much chemical will be in the pond after a long time, we will look for the equilibrium
solution and see if other solutions approach it as t → ∞. To find the equilibrium solution, we set the rate
of change equal to 0.
0 = 3 − 3/10, 000c(t)
3 = 3/10, 000c(t)
10, 000 = c(t)
b) We will use the direction field to determine what happens to the amount of chemical in the pond after a
long time. Let us try to predict what the direction field for this problem looks like by choosing values of
c(t) below and above the equilibrium solution and computing whether the slopes of the tangent lines are
positive or negative.
If c(t) = 9000, then dc = 3 − 3/10, 000 ∗ 9000 = 3 − 3/10 ∗ 9 = 0.3 (> 0).
dt
If c(t) = 11, 000, then dc = 3 − 3/10, 000 ∗ 11, 000 = 3 − 3/10 ∗ 11 = −0.3 (< 0)
dt
This gives us an idea of what the direction field looks like!
Here is the actual direction field:
After a very long time there will be 10, 000 g of chemical in the pond.
Direction fields can give us a great deal of information about a differential equation and it is always
possible to graph a direction field even if you know nothing about the solution! Below are a couple more
examples of what a direction field can look like.
10
Example:
dy
= y(4 − y)
dt
Observation:
A differential equation can have more than one equilibrium solution.
dy
Example:
= −2 + t − y
dt
Observation:
The equilibrium solution need not be constant.
dy
= 3 sin(t) + 1 + y
Example:
dt
11