Upload
others
View
31
Download
0
Embed Size (px)
Citation preview
Introduction to Differential Equations
● Introduction● What is a differential equation?● Malthusian growth and other examples
● Some applications● Radioactive decay
● Classification of differential equations● Summary
Introduction
● Differential equations frequently arise in modeling situations
● They describe population growth, chemical reactions, heat exchange, motion (all classical physics built on diff. eq's.), ... etc.
● Continuous analogue of discrete dynamical systems
What is a Differential Equation
● A differential equation is any equation of some unknown function that involves some derivative of the unknown function
● Classical example is Newton's law of motion● The mass of an object times its acceleration is
equal to the sum of the forces acting on it (“F=ma”)● Acceleration a is the first derivative of velocity
(a=d/dt v) and the second derivative of position (a=d2/dt2 x)
● F=m d2/dt2 x is an example of a diff. Eq's.
● More generally, diff. eq's. can be used to model
the temporal evolution of any system
Example: Malthusian Growth
● Discrete Malthusian growth, population Pn at
time n with growth rate r:
● Rearrange the above equation
● Note: change in population between the (n+1)st time and nth time is proportional to r times the size of the population at time n.
(E.g. a fraction r of individuals has an offspring)
Pn+1=Pn+r Pn
Pn+1−Pn=r Pn
... or Interest on Savings ...
● Could also understand
● Pn as the amount of savings we have at time n
● r as the interest rate
● The previous equation then just says that savings next year are equal to savings this year plus interest
Malthusian Growth (2)
● Let P(t) be the size of the population at time t● Assume that r is the rate of change per unit time per
individual in the population● Let ∆t be a small interval of time, then change in
population between t and t+∆t satisfies:
● The equation can be rearrange to give:
P(t+Δ t)−P(t )=Δ t rP (t)
P (t+Δ t)−P (t)Δ t
=rP(t )
Malthusian Growth (3)
● Discrete model was given by
● Left hand side should remind of the definition of a derivative. Take the limit of very small intervals of time ∆t -> 0:
● This is the continuous Malthusian growth model
in the form of a differential equation
P (t+Δ t)−P (t)Δ t
=rP(t )
limΔ t→ 0
P (t+Δ t)−P (t)Δ t
=dP (t)
dt=rP( t)
Solving Differential Equations
● Solving the discrete system
means finding a function Pn that satisfies the
above equation and meets some initial condition for P
0 and allows to answer the
question: “If we have population P0 at time zero
what is the size of the population Pn at time n?”
● This can be done easily ... seminar.
Pn+1=Pn+r Pn
Solving Differential Equations
● Solving
means finding a function x(t) that obeys the equation and meets some initial condition at time zero, e.g. x(0)=x
0.
● (So from some local rule how to progress in time from t to t+dt we find the global behaviour x(t) of the system)
dx (t)dt
=f ( x , t)
Slope fields ...
● dy(x)/dx is slope of y at position x. Hence f(y, x) defines a slope or direction field
● We look for a function
y(x) that is tangent to
the slope field at every
point
y
x
Slope field for dy/dx=x2-x-2 (from wikipedia)
Solving Malthusian Growth
● The differential equation for continuous Malthusian growth is
● Let c be an arbitrary constant and let's try a solution of the form
● Differentiating: i.e.
dP(t )dt
=rP (t) , P(0)=P0
P(t )=cer t
(*)
ddt
c er t=c r e
rt
ddt
P(t )=r P( t)
Solving Malthusian Growth (2)
● Hence solve the differential equation (*)● This is a family of solutions (parametrized by c), we
need to find the member of this family which obeys the initial condition P(0)=P
0.
● Hence the solution to the initial value problem is:
(e.g. exponential growth)
P(t )=cer t
P(t )=cer t→P(0)=cer 0=c=P0
→c=P0
P(t )=P0 er t
Example
● Consider the Malthusian growth model
with P(0)=100
● Find the solution and determine how long it takes for the population to double
dP(t )dt
=0.02 P(t )
Applications of Differential Equations
● Radioactive decay: Let R(t) be the amount of some radioactive substance at time t.● Radioactive substances transition into another state
at a rate k proportional to the amount of substance present
● The differential equation is:
● With initial condition R(0)=R0.
● In analogy to Malthusian growth:
dR( t)dt
=−kR (t )
R( t)=R0 e−k t
Harmonic Oscillator
● A Hooke's law spring exerts a force that is proportional to the displacement of the spring
● Newton's law of motion
F=ma=-cx● The simplest spring-mass
problem is
with
d2
dt 2 x+k2 x=0
k 2=c /m
A Swinging Pendulum
● A pendulum is a mass attached at one point that it swings freely under the influence of gravity ● Newton's law of motion
gives
● Where
d2
dt 2 Θ+ω2sin (Θ)=0
ω2=g/m
gravitationalconstant
mass of bob
Logistic Growth
● Most populations limited by food, space, or waste-build up and hence cannot grow according to Malthusian growth● Logistic growth model has a Malthusian growth
term and a term limiting growth due to crowding
● Where P is population size, r the (Malthusian) growth rate, and M the carrying capacity
● Will discuss solutions later
dPdt
=r P(1−P /M )
Lotka-Volterra Predator Prey Model
● Population of prey (x) and predator (y) interacting in an ecosystem
● System of differential equations for x and y
● No explicit solutions, but will discuss this system later
ddt
x=ax−bxy
ddt
y=−cy+dxy
Classification of Differential Equations
● Order of a differential equation● Is determined by the highest derivative in the
equation● E.g. Malthusian or logistic growth are 1st order,
Harmonic osci is 2nd order● Lotka-Volterra is a first order system of differential
equations
● Higher order equations can be transformed into systems of first order equations by introducing new variables
Transforming higher order ODEs to Systems of First order ODEs
● E.g. Harmonic oscillator:
● Introduce y=dx/dt:
● Resulting in a system of two first order ODEs● -> Sufficient to deal with systems of first order
ODEs!
d2
dt 2 x+k2 x=0
dx /dt= y
dy /dt=d2/dt 2 x=−kx2
Linear vs. Nonlinear
● A differential equation is linear if the unknown dependent variable and its derivatives only appear in a linear manner● Logistic growth and radioactive decay and harmonic
osci are linear equations● Pendulum and Lotka-Volterra are nonlinear
(Non)Autonmous Equations
● A differential equation is autonomous it does not explicitely depend on time● E.g.:
● All given examples in this lecture (Malthusian and logistic growth, harmonic osci, LV are autonomous)
● Non-autonomous equations can be transformed into systems of autonomous equations by including time as an independent variable
ddt
x=x autonomous
ddt
x=xt (non-)autonomous
Nonautonomous -> autonomous
● For example:
is non-autonomous. Include y=t and write:
● Is a system of two autonomous equations!
ddt
x=xt
ddt
y=1
ddt
x=xy
Transformations
● These trivial transformations● Higher order -> system of first order ODEs● Non-autonomous -> system of autonomous ODEs
are important as often ● Theory is only given for systems of first order ODEs● (Numerical) solvers often assume systems of first
order autonomous ODEs
Partial Differential Equations
● Differential equations can have unknown functions of multiple variables and their derivatives
● E.g. Heat equation
● Often solved numerically: finite difference methods, etc.
∂
∂ tu−α ∇
2u=0
uxx+u yy+uzz Temperature fieldThermal diffusivity
Summary
● You should remember:● What a differential equation is ● What solving a diff eq. means and how to verify if a
function is a solution to a diff. eq.● Classifications of differential equations and● Important tricks to transform diff. Eq's into systems
of first order ODEs