MATH3203 Lecture 1 Mathematical Modelling and ODEs

Similar documents
Lecture 20/Lab 21: Systems of Nonlinear ODEs

Mathematical Methods - Lecture 9

Dynamical Systems and Chaos Part II: Biology Applications. Lecture 6: Population dynamics. Ilya Potapov Mathematics Department, TUT Room TD325

1.2. Introduction to Modeling. P (t) = r P (t) (b) When r > 0 this is the exponential growth equation.

CHAPTER 4. Introduction to the. Heat Conduction Model

Scientific Computing: An Introductory Survey

Introduction to Partial Differential Equations

Introduction and some preliminaries

13 PDEs on spatially bounded domains: initial boundary value problems (IBVPs)

Math 5587 Lecture 2. Jeff Calder. August 31, Initial/boundary conditions and well-posedness

INTRODUCTION TO PDEs

MATH 425, FINAL EXAM SOLUTIONS

Chapter 2 Boundary and Initial Data

All living organisms are limited by factors in the environment

1. Differential Equations (ODE and PDE)

and verify that it satisfies the differential equation:

An Introduction to Numerical Methods for Differential Equations. Janet Peterson

Chapter 18. Remarks on partial differential equations

Infinite series, improper integrals, and Taylor series

Lecture Introduction

An Introduction to Partial Differential Equations

Lecture 9 Approximations of Laplace s Equation, Finite Element Method. Mathématiques appliquées (MATH0504-1) B. Dewals, C.

Lecture 6: Introduction to Partial Differential Equations

1.2. Introduction to Modeling

First-Order Ordinary Differntial Equations: Classification and Linear Equations. David Levermore Department of Mathematics University of Maryland

1.1. Bacteria Reproduce like Rabbits. (a) A differential equation is an equation. a function, and both the function and its

MA 777: Topics in Mathematical Biology

Chapter 3 Second Order Linear Equations

Systems of Ordinary Differential Equations

Student Background Readings for Bug Dynamics: The Logistic Map

Final: Solutions Math 118A, Fall 2013

Partial Differential Equations - part of EM Waves module (PHY2065)

1.1 Motivation: Why study differential equations?

A review of stability and dynamical behaviors of differential equations:

The integrating factor method (Sect. 1.1)

Dispersion relations, linearization and linearized dynamics in PDE models

FIRST-ORDER ORDINARY DIFFERENTIAL EQUATIONS I: Introduction and Analytic Methods David Levermore Department of Mathematics University of Maryland

DUHAMEL S PRINCIPLE FOR THE WAVE EQUATION HEAT EQUATION WITH EXPONENTIAL GROWTH or DECAY COOLING OF A SPHERE DIFFUSION IN A DISK SUMMARY of PDEs

A NUMERICAL STUDY ON PREDATOR PREY MODEL

Mathématiques appliquées (MATH0504-1) B. Dewals, Ch. Geuzaine

Math 3B: Lecture 14. Noah White. February 13, 2016

Coordinate Curves for Trajectories

Chapter1. Ordinary Differential Equations

1 (t + 4)(t 1) dt. Solution: The denominator of the integrand is already factored with the factors being distinct, so 1 (t + 4)(t 1) = A

Differential Equations Spring 2007 Assignments

MATH 353 LECTURE NOTES: WEEK 1 FIRST ORDER ODES

3 Single species models. Reading: Otto & Day (2007) section 4.2.1

6.0 INTRODUCTION TO DIFFERENTIAL EQUATIONS

Math 5587 Midterm II Solutions

Class Meeting # 1: Introduction to PDEs

FIRST-ORDER SYSTEMS OF ORDINARY DIFFERENTIAL EQUATIONS III: Autonomous Planar Systems David Levermore Department of Mathematics University of Maryland

Introduction. Chapter What is this book about?

The first order quasi-linear PDEs

UNIVERSITY OF MANITOBA

Lecture 8: Ordinary Differential Equations

Partial Differential Equations

Lecture 3. Dynamical Systems in Continuous Time

CLASSIFICATION AND PRINCIPLE OF SUPERPOSITION FOR SECOND ORDER LINEAR PDE

AM 205: lecture 14. Last time: Boundary value problems Today: Numerical solution of PDEs

Introduction to Biomathematics. Problem sheet

Math 342 Partial Differential Equations «Viktor Grigoryan

Introduction to multiscale modeling and simulation. Explicit methods for ODEs : forward Euler. y n+1 = y n + tf(y n ) dy dt = f(y), y(0) = y 0

Intermediate Differential Equations. John A. Burns

Final Project Descriptions Introduction to Mathematical Biology Professor: Paul J. Atzberger. Project I: Predator-Prey Equations

Introduction LECTURE 1

Analysis III (BAUG) Assignment 3 Prof. Dr. Alessandro Sisto Due 13th October 2017

MATH 251 Final Examination August 14, 2015 FORM A. Name: Student Number: Section:

6 Non-homogeneous Heat Problems

Math 251 December 14, 2005 Final Exam. 1 18pt 2 16pt 3 12pt 4 14pt 5 12pt 6 14pt 7 14pt 8 16pt 9 20pt 10 14pt Total 150pt

BOUNDARY-VALUE PROBLEMS IN RECTANGULAR COORDINATES

Fundamentals of Dynamical Systems / Discrete-Time Models. Dr. Dylan McNamara people.uncw.edu/ mcnamarad

REVISION: POPULATION ECOLOGY 01 OCTOBER 2014

Math 256: Applied Differential Equations: Final Review

Math 4263 Homework Set 1

Lecture 10. (2) Functions of two variables. Partial derivatives. Dan Nichols February 27, 2018

Science One Math. October 23, 2018

Q ( q(m, t 0 ) n) S t.

Math 251 December 14, 2005 Answer Key to Final Exam. 1 18pt 2 16pt 3 12pt 4 14pt 5 12pt 6 14pt 7 14pt 8 16pt 9 20pt 10 14pt Total 150pt

1.1. Bacteria Reproduce like Rabbits. (a) A differential equation is an equation. a function, and both the function and its

Math 215/255 Final Exam, December 2013

Dispersion relations, stability and linearization

2015 Holl ISU MSM Ames, Iowa. A Few Good ODEs: An Introduction to Modeling and Computation

MATH 100 Introduction to the Profession

ENGI 9420 Lecture Notes 8 - PDEs Page 8.01

The method of lines (MOL) for the diffusion equation

Math Ordinary Differential Equations

Linear algebra for MATH2601: Theory

Global Stability Analysis on a Predator-Prey Model with Omnivores

Lecture 19: Heat conduction with distributed sources/sinks

Dynamical Systems: Lecture 1 Naima Hammoud

INTERPRETING POPULATION DYNAMICS GRAPH

ORDINARY DIFFERENTIAL EQUATION: Introduction and First-Order Equations. David Levermore Department of Mathematics University of Maryland

Introduction of Partial Differential Equations and Boundary Value Problems

MA 138 Calculus 2 for the Life Sciences Spring 2016 Final Exam May 4, Exam Scores. Question Score Total

Differential equations, comprehensive exam topics and sample questions

Concepts in Theoretical Physics. John D Barrow. Lecture 1: Equations in Physics, Simplicity, and Chaos

LECTURE # 0 BASIC NOTATIONS AND CONCEPTS IN THE THEORY OF PARTIAL DIFFERENTIAL EQUATIONS (PDES)

Partial Differential Equations

THE WAVE EQUATION. F = T (x, t) j + T (x + x, t) j = T (sin(θ(x, t)) + sin(θ(x + x, t)))

Motivation and Goals. Modelling with ODEs. Continuous Processes. Ordinary Differential Equations. dy = dt

Transcription:

MATH3203 Lecture 1 Mathematical Modelling and ODEs Dion Weatherley Earth Systems Science Computational Centre, University of Queensland February 27, 2006 Abstract Contents 1 Mathematical Modelling 2 1.1 Definition of a mathematical model...................... 2 1.2 The mathematical modelling recipe...................... 2 2 A simple mathematical model - the Malthus population model 3 3 A refined model - the logistic equation 3 4 Further refinements - predator-prey and beyond 4 5 From ODEs to PDEs 5 5.1 Definition of a partial derivative and some useful tips............ 6 5.2 A simple PDE model - the 1D heat equation................. 7 5.3 Some definitions of PDE types and order................... 7 5.4 Linear vs. nonlinear.............................. 8 5.5 Arbitrary functions vs. arbitrary constants.................. 8 1

1 Mathematical Modelling (From Chapter 1, Applied Differential Equations, J.D. Logan, Springer, 2004.) Many important concepts of Mathematics were developed in the framework of physical science. For example, calculus has its origins in efforts to describe the motion of bodies. Indeed one of the inventors of calculus was Newton. Mathematical equations provide a language in which to formulate concepts in physics - Maxwell s equations describe electrodynamical phenomena, Newton s equations describe mechanical systems, Schrodinger s equation describes quantum phenomena etc. Over the years mathematicians and scientists have extended these connections to almost every field of mathematics and science, resulting in the birth of the field of mathematical modelling. 1.1 Definition of a mathematical model A mathematical model is an equation or set of equations whose solution describes the physical behaviour of a related physical system. Formulation of the equations is based on experimentation, physical observations and intuition. A mathematical model is always a simplified description, or caricature, of physical reality expressed in mathematical terms. 1.2 The mathematical modelling recipe The recipe for mathematical modelling of a physical system, is essentially a corrollary for the scientific method: 1. experimentation and physical observations 2. selection of the relevant physical variables 3. formulation of equations governing the inter-dependance of these variables 4. solution of the equations via analysis and numerical simulation 5. validation of the mathematical model via comparison with observations The last step, validation, involves comparison of simulation results and solutions with physical observations to ascertain whether the model describes the physical phenomenon. Since the mathematical model is invariably a simplification, there are alaways discrepancies between model solutions and physical observations. These discrepancies motivate refinement of the model, so the recipe above is repeated ad infinitum. Refinement of the mathematical model eventually results in a set of equations that are not amiable to analytical solution, particularly when nonlinear terms are included. Numerical simulation provides an avenue for solving nonlinear equations but requires considerable care to ensure that the numerical solution is a valid solution of the equations. This course aims to provide basic skills in the use of numerical simulation to solve mathematical models and analyse the results. The first module introduces partial differential equations, their application in mathematical modelling, and one of the most common numerical solution methods, explicit finite differences. The second module provides skills in computer visualisation of simulation results in both 2- and 3D. In the third module, a number of other numerical solution methods will be discussed, and finally there will be some discussion of the use of parallel supercomputers for numerical simulation. 2

2 A simple mathematical model - the Malthus population model As an example of mathematical modelling in action, we shall consider a physical system governed by a 1D Ordinary Differential Equation (ODE). A typical model in population ecology is the Malthus model. Its aim is to model the growth of a population of organisms (could be people, animals, bacteria, viruses etc.). The conjecture underlying the model is that the rate of increase of a population is proportional to the size of the population. This conjecture is expressed mathematically as: du = ru, t > 0, (1) dt where U = U(t) is the population at some time t and the real number r is a given physical parameter representing the growth rate. Physical parameters typically are measurable quantities. In this case, by observing the population we could measure r. In mathematical modelling parlance, U(t) is the state variable and the time-evolution of the state variable is governed by equation 1. ODEs are suitable for modelling the evolution of one or more state variables that depend only each other and one independant variable (usually time). In this course we will focus predominantly upon PDE models, in which state variables depend on two or more independant variables (usually 1 or more space variables and possibly time). At this point, we have completed steps 1-3 of the mathematical modelling recipe. Next is solution of the model equations via analysis and/or numerical simulation. Solution of the model involves finding an expression for the state variable U(t), that is a function of the independant variable and possibly some other known or measurable quantities. In the case of equation 1, the solution may be obtained analytically (by inspection): U(t) = U 0 e rt, t > 0, (2) where U 0 represents the population size at time t = 0. Having successfully completed step 4, it is time to validate the mathematical model, by comparison with physical observation and experimentation. The Malthus model predicts exponential growth of the population. While this accurately models the beginning stages of growth of some populations, the model fails at some time in the time-history of the population. Why does the model fail? It fails because the model does not account for other factors that affect the growth of a population. For example, competition for resources, predation and/or disease etc. 3 A refined model - the logistic equation The Malthus equation accurately describes the initial stages of population growth but fails thereafter. Specifically, observations of real populations show that populations often stabilise after the initial growth period and the size of the population does not continue to increase exponentially. In other words, the population reaches a steady-state where the growth rate approximately balances the mortality rate. 3

The logistic equation was introduced as a refinement to the malthus model. The additional conjecture it embodies is that their is some finite maximum carrying capacity for the population, K. This carrying capacity is another physical parameter, that can be measured via physical observations. Let N(t) be the size of the population at time t. The logistic equation is: dn rn(k N) =, t > 0, (3) dt K where r is the Malthusian growth rate. By dividing both sides by K and setting U(t) =, we obtain the more common form of the logistic equation: N(t) K du = ru(1 U), t > 0. (4) dt Now we have entered the realm of nonlinear differential equations. This ODE is nonlinear because it involves a nonlinear function of the state variable, namely U 2. In most cases, nonlinear equations cannot be solved analytically and numerical methods must be applied. In this case, an analytical solution can be found, namely: U(t) = 1 1 + ( 1 U 0 1 ), t > 0, (5) e rt where again, U 0 is the initial population size, at t = 0. What happens as t? U(t) 1 i.e. N(t) K, the population size approaches the carrying capacity, K. Thus, the logistic model satisfies the physical observation that populations often reach a constant size, after an initial period of exponential growth. 4 Further refinements - predator-prey and beyond One might be tempted to close the book on population ecology at this point...problem solved. However, comparison with physical observations (step 5 again) shows that this logistic equation is only applicable if the ecosystem consists of only a single species with a constant supply of nutrients e.g. bacteria in petri dish supplied with a constant amount of glucose. Suppose we are interested in modelling an ecosystem containing two species, one of which predates solely upon the other species as its source of nutrients. Let s also suppose the prey has a constant supply of nutrients. In this case, the carrying capacity of the predator species will depend upon the population of the prey species. Furthermore, the growth rate of the prey species will depend upon the population of the predator species. Mathematically, we can express this as a set of two coupled equations. Let U 1 (t) and U 2 (t) represent the population of the prey and predators respectively. The prey population might be governed by a modified logistic equation in which the growth rate is governed by the current population of the predator species: du 1 dt = (r 1 p 12 U 2 ) U 1(K 1 U 1 ) K 1, t > 0, (6) where p 1 2 is a physical parameter defining the death rate of prey per unit predator population and K 1 is the carrying capacity of the prey, thanks to the constant food supply. The predator population may be described by another modified logistic equation: 4

du 2 dt = r 2 U 2 (K 21 U 1 U 2 ) K 21 U 1, t > 0, (7) where now the carrying capacity depends upon the prey population and a physical parameter (K 21 ) defining the carrying capacity per unit prey population. As the prey population increases, the carrying capacity of the predator population increases and vice versa. We now have quite a complicated model for our ecosystem involving two state variables (U 1 and U 2 ) whose evolution are coupled to each other, as well as upon the independant variable, time. We will not attempt to examine the solution of this mathematical model. Indeed it is quite a complicated problem with a number of different solutions depending upon the values of the physical parameters and the initial populations of predators and prey. One such solution is a stable ecosystem in which the populations of both predators and prey fluctuate about some mean value. Another solution is mass extinction: the predators increase in number too rapidly, eat all the prey, then die of starvation. Despite the complicated nature of the mathematical model and its solution space, these coupled equations are quite readily studied, particularly with the aid of numerical simulations in which various physical parameters may be tried systematically and the numerical solutions analysed. We may also wish to go a step further and consider a mathematical model for an ecosystem consisting of a number of different species, many of which are prey of some species and predators of others. Careful definition of the evolution equation for each species and the coupling coefficients between the species, allows us to formulate a mathematical model which is a system of coupled differential equations, of the form: du α = f α (t, U β ; r β, K αβ, p αβ ), t > 0, α, β = 1, 2,..., N (8) dt where N is the number of different species in the ecosystem. Such systems of coupled differential equations are quite common in the sciences. If the functions f α have certain properties, chiefly linearity or weak nonlinearity, the system may be described as a matrix equation of the form: U = FU (9) where F is an NxN matrix defining the coupling between each of the elements of the vector U representing the populations of each species. The matrix may be sparsely occupied (i.e. most elements are zero), diagonal, tri-diagonal, banded or densely populated. Depending upon the structure of the matrix, different numerical solution methods must be employed to solve the equations. As we shall see later, many partial differential equation models may be expressed as systems of equations of this form. We shall discuss some of the numerical methods for solving such equations later in the course. 5 From ODEs to PDEs The population ecology examples demonstrate the power of ODEs for mathematical modelling of physical systems. However, in all the cases examined, the solutions are simply functions of a single independant variable representing time. From our own experience, physical systems often evolve not only in time but also in at least three spatial dimensions. For example, if one observes a cloud over a period of an hour, its shape (or spatial 5

structure) will change in addition to the cloud floating slowly across the sky as a single bank. We could model the cloud as a spherical body moving at constant velocity using an ODE but this model would not capture much of the cloud dynamics we can observe. Partial differential equation models permit one to model state variables that depend on more than one independant variable. Often these independant variables are time and one or more spatial dimensions or in so-called steady-state problems, two or more spatial dimensions only. Suppose we make some physical observations of a phenomenon (step 1) and select a single relevant state variable (step 2) that varies both spatially and temporally. For simplicity, let s assume that the physical system can be described one-dimensionally i.e. the state variable U = U(x, t). We now formulate an equation describing the evolution of the state variable (step 3). On physical grounds, we are likely to summise that the form of this equation will involve the time rate-of-change of the state variable and also the spatial rate-of-change (or gradient) of the state variable. 5.1 Definition of a partial derivative and some useful tips The definition of a partial differential is of use in formulating such equations. For a function of two indendant variables (x and t) we can define two partial differentials, namely: and: δu δt = lim U(x, t + t) U(x, t) t 0 t (10) δu δx = lim U(x + x, t) U(x, t). (11) x 0 x Recalling the definition of the total derivative of a function of a single variable, one can see that these two defines imply that we compute partial derivatives with respect to one independant variable by treating the other independant variable as a constant parameter. Hence, most of the tricks learnt to compute total derivatives can be directly applied to computing partial derivatives e.g. or, U(x, t) = Axt 2, δu δt = 2Axt, δu δx = At2. (12) U(x, t) = A sin(x)e rt δu, δt = ra δu sin(x)e rt, δx = A cos(x)e rt. (13) To avoid lawsuits because of MATH3203-induced RSI, we will employ a shorthand notation to represent derivatives: U t = δu δt, U x = δu δx We can also define higher order partial derivatives: (14) U tt = δ ( ) δu = δ2 U δt δt δt, 2 (15) U xx = δ ( ) δu = δ2 U δx δx δx, 2 (16) 6

and U tx = δ δt ( ) δu, (17) δx If U(x, t) is a sufficiently well-behaved function (i.e. continuous or piece-wise continuous etc.), a useful identity that is valid more often than not is U tx = U xt i.e. the order in which the partial derivatives are computed is unimportant. 5.2 A simple PDE model - the 1D heat equation Having dispensed with the preliminaries, we can now begin using PDEs for mathematical modelling. Consider the problem of determining the temperature of a laterally insulated metal bar of length l and unit cross-sectional area, whose two ends are maintained at a constant temperature of zero degrees and whose temperature initially varies along the bar and is given by a fixed function φ(x). Let s represent the temperature in the bar as U = U(x, t), our state variable for this problem defined for interval t > 0 and for the domain 0 < x < l. The equation governing the evolution of temperature is called the heat equation and it has the form: U t = ku xx, (18) which is a partial differential equation i.e. an equation involving various partial derivatives of the state variable U. The constant k is called the thermal diffusivity and as its name suggests, it is a physical parameter determining the rate at which temperature diffuses along the bar. The thermal diffusivity can be determined in terms of the density, specific heat and thermal conductivity of the metal, all of which can be measured in laboratory experiments. We can also express the other information in the original problem via additional constraints: U(0, t) = 0, U(l, t) = 0, t > 0, (19) which are called boundary conditions because they impose conditions on the state variable on the boundary of the spatial domain. We can also write an initial condition, expressing the initial temperature along the bar: U(x, 0) = φ(x), 0 < x < l. (20) The set of three equations (the PDE and and auxillary conditions) defines the mathematical model for heat flow in the bar. Such problems are called initial boundary value problems in PDE parlance. 5.3 Some definitions of PDE types and order Some physical systems do not depend upon time, but rather only spatial variables. Such models are called steady state or equilibrium models. For example, Laplace s equation in 3D has the form: U xx + U yy + U zz = 0 (x, y, z) Ω, (21) 7

where Ω is a specified spatial domain. If we also specify a time-independant function on the boundary δω of the domain, e.g. U(x, y, z) = f(x, y, z), (x, y, z) δω, (22) we have a boundary value problem. Solving Laplace s equation as defined in the two equations above is also known as solving the Dirichlet problem. In general, a PDE in one spatial variable and time is an equation of the form: G(x, t, U, U x, U t, U xx, U tt, U xt,...) = 0, x Ω, t I, (23) where I is a given time interval (typically t > 0). The order of a PDE is the order of highest derivative that appears in the equation. A PDE model is a PDE supplemented with initial and boundary conditions as appropriate, and the model may also contain one or more physical parameters. PDEs are classified according to their order and other properties. For example, a PDE is linear if the function G is a linear function of the state variable U and all its derivative, otherwise the PDE is nonlinear. A linear equation is homogeneous if every term involves U or some derivative of U i.e. there is no explicit time-dependance. 5.4 Linear vs. nonlinear The partitioning of PDEs into linear and nonlinear is quite significant. Solutions of linear equations superimpose. Suppose f(x, t) and g(x, t) are both solutions of a given linear PDE. Then all linear combinations (A f f(x, t) + A g g(x, t)) of these two solutions are also solutions of the PDE, where A f, A g are constant coefficients. This is a very significant advantage for solving linear PDEs. If we are able to find a set of particular solutions of the PDE, we can construct all other solutions as linear combinations of these. Nonlinear equations do not share this property of superposition and are usually much harder to solve and the solutions more difficult to analyze. It is common in mathematical modelling to attempt to approximate a nonlinear phenomenon in nature with a linear model. While these linear models provide insight into the nature of the phenomenon, often they are insufficient to describe some of the important aspects and one must introduce nonlinear terms to the model. Usually nonlinear models cannot be solved by hand, so numerical methods must be devised. This course will largely ignore nonlinear equations and focus on the basis tools for numerical solutions of PDEs. 5.5 Arbitrary functions vs. arbitrary constants Whereas the solutions of ODEs often involve arbitrary constants, often called integration constants, the solutions of PDEs are often arbitrary functions. Consider the following PDE: u x = t sin(x) (24) This equation can be solved by direct integration. We integrate both size with respect to x, holding t fixed: infty u x δx = infty t sin(x) (25) 8

u(x, t) = t cos(x) + φ(t) (26) where φ is an arbitrary function. Notice that integration with respect to one independant variable results in an arbitrary function of the other independant variables, not an arbitrary constant as in ODEs. This last equation defines the general solution of the PDE. One can check that it is a solution for any differentiable function φ(t) by substituting it back into the original PDE. In summary, PDEs have arbitrary functions in their general solutions; the number of arbitrary functions usually agrees with the order of the equation. 9

References 10