Mathematical Computing

Similar documents
DIFFERENTIAL EQUATIONS

DIFFERENTIAL EQUATIONS

DIFFERENTIAL EQUATIONS

DIFFERENTIAL EQUATIONS

DIFFERENTIAL EQUATIONS

. For each initial condition y(0) = y 0, there exists a. unique solution. In fact, given any point (x, y), there is a unique curve through this point,

First Order ODEs, Part I

(1 + 2y)y = x. ( x. The right-hand side is a standard integral, so in the end we have the implicit solution. y(x) + y 2 (x) = x2 2 +C.

Lecture 19: Solving linear ODEs + separable techniques for nonlinear ODE s

1.1 Motivation: Why study differential equations?

VANDERBILT UNIVERSITY. MATH 2300 MULTIVARIABLE CALCULUS Practice Test 1 Solutions

Introduction to Differential Equations

Ordinary Differential Equations

Math 212-Lecture 8. The chain rule with one independent variable

Math 5198 Mathematics for Bioscientists

and verify that it satisfies the differential equation:

The integrating factor method (Sect. 1.1)

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

Chain Rule. MATH 311, Calculus III. J. Robert Buchanan. Spring Department of Mathematics

Lecture 2. Introduction to Differential Equations. Roman Kitsela. October 1, Roman Kitsela Lecture 2 October 1, / 25

z 2 = 1 4 (x 2) + 1 (y 6)

2.12: Derivatives of Exp/Log (cont d) and 2.15: Antiderivatives and Initial Value Problems

Math 308, Sections 301, 302, Summer 2008 Review before Test I 06/09/2008

Math 341 Fall 2008 Friday December 12

Ma 221 Final Exam 18 May 2015

First-Order ODEs. Chapter Separable Equations. We consider in this chapter differential equations of the form dy (1.1)

Chapter1. Ordinary Differential Equations

Chapter 1: Introduction

Fourth Order RK-Method

Computational Neuroscience. Session 1-2

Definition of differential equations and their classification. Methods of solution of first-order differential equations

21-256: Partial differentiation

Problem set 7 Math 207A, Fall 2011 Solutions

These notes are based mostly on [3]. They also rely on [2] and [1], though to a lesser extent.

ENGI 4430 PDEs - d Alembert Solutions Page 11.01

Exam 3 MATH Calculus I

Math 23: Differential Equations (Winter 2017) Midterm Exam Solutions

Solving First Order PDEs

Separable Differential Equations

Math 180, Final Exam, Fall 2007 Problem 1 Solution

MATH 251 Examination II April 7, 2014 FORM A. Name: Student Number: Section:

Problem 1 In each of the following problems find the general solution of the given differential

Degree Master of Science in Mathematical Modelling and Scientific Computing Mathematical Methods I Thursday, 12th January 2012, 9:30 a.m.- 11:30 a.m.

Scientific Computing: An Introductory Survey

Lecture 13 - Wednesday April 29th

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

Mathematics 22: Lecture 7

Solving systems of first order equations with ode Systems of first order differential equations.

Math 310 Introduction to Ordinary Differential Equations Final Examination August 9, Instructor: John Stockie

1 Partial differentiation and the chain rule

ENGI Partial Differentiation Page y f x

APPLICATIONS OF FD APPROXIMATIONS FOR SOLVING ORDINARY DIFFERENTIAL EQUATIONS

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

JUST THE MATHS UNIT NUMBER INTEGRATION APPLICATIONS 10 (Second moments of an arc) A.J.Hobson

y0 = F (t0)+c implies C = y0 F (t0) Integral = area between curve and x-axis (where I.e., f(t)dt = F (b) F (a) wheref is any antiderivative 2.

Math 225 Differential Equations Notes Chapter 1

An Introduction to Partial Differential Equations

Green Lab. MAXIMA & ODE2. Cheng Ren, Lin. Department of Marine Engineering National Kaohsiung Marine University

The first order quasi-linear PDEs

Partial Differential Equations

Real Analysis III. (MAT312β) Department of Mathematics University of Ruhuna. A.W.L. Pubudu Thilan

On linear and non-linear equations.(sect. 2.4).

1+t 2 (l) y = 2xy 3 (m) x = 2tx + 1 (n) x = 2tx + t (o) y = 1 + y (p) y = ty (q) y =

Review for the First Midterm Exam

Practice Problems for Final Exam

First Order Differential Equations and Applications

Lecture 8: Calculus and Differential Equations

Lecture 8: Calculus and Differential Equations

(1) Rate of change: A swimming pool is emptying at a constant rate of 90 gal/min.

ODES Package. Aleksas Domarkas. November 18, 2013

The Fundamental Theorem of Calculus: Suppose f continuous on [a, b]. 1.) If G(x) = x. f(t)dt = F (b) F (a) where F is any antiderivative

Solving First Order PDEs

Differential equations

Lecture 2. Classification of Differential Equations and Method of Integrating Factors

1. Solve the boundary-value problems or else show that no solutions exist. y (x) = c 1 e 2x + c 2 e 3x. (3)

LAURENTIAN UNIVERSITY UNIVERSITÉ LAURENTIENNE

MATH 19520/51 Class 5

Chapter 2. First-Order Partial Differential Equations. Prof. D. C. Sanyal

(a) x cos 3x dx We apply integration by parts. Take u = x, so that dv = cos 3x dx, v = 1 sin 3x, du = dx. Thus

z x = f x (x, y, a, b), z y = f y (x, y, a, b). F(x, y, z, z x, z y ) = 0. This is a PDE for the unknown function of two independent variables.

Entrance Exam, Differential Equations April, (Solve exactly 6 out of the 8 problems) y + 2y + y cos(x 2 y) = 0, y(0) = 2, y (0) = 4.

Calculus for the Life Sciences II Assignment 6 solutions. f(x, y) = 3π 3 cos 2x + 2 sin 3y

MTH4100 Calculus I. Week 6 (Thomas Calculus Sections 3.5 to 4.2) Rainer Klages. School of Mathematical Sciences Queen Mary, University of London

Additional Homework Problems

6x 2 8x + 5 ) = 12x 8

Math 232, Final Test, 20 March 2007

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

MATH 353 LECTURE NOTES: WEEK 1 FIRST ORDER ODES

Chapter 4: Higher-Order Differential Equations Part 3

Name: SOLUTIONS Date: 11/9/2017. M20550 Calculus III Tutorial Worksheet 8

APPM 2360: Final Exam 10:30am 1:00pm, May 6, 2015.

First order Partial Differential equations

Differential Equations Class Notes

APPLIED MATHEMATICS. Part 1: Ordinary Differential Equations. Wu-ting Tsai

(A) Opening Problem Newton s Law of Cooling

Math 222 Spring 2013 Exam 3 Review Problem Answers

Solutions to Math 53 Math 53 Practice Final

M343 Homework 3 Enrique Areyan May 17, 2013

Preparation for the Final

First-Order Differential Equations

Transcription:

IMT2b2β Department of Mathematics University of Ruhuna A.W.L. Pubudu Thilan

Differential Equations

Types of Differential Equations Differential equations can basically be classified as ordinary differential equation and partial differential equation.

Types of Differential Equations Ordinary Differential Equations (ODEs) A differential equation that contains only one independent variable is considered an ordinary differential equation. Eg: dy dx = x + 2 y = x 2 1 d 2 u dx 2 + du dx = x + 1 These types of differential equations can be either linear or nonlinear. An ordinary differential equation is linear if it is written in the following general form: a n (x) dn y dx n + a n 1(x) dn 1 y dx n 1 +... + a 1(x)y + a 0 (x) = f (x).

Types of Differential Equations Partial Differential Equations (PDEs) A differential equation that contains only two or more independent variables is considered a partial differential equation. Eg: 2 z x 2 + 2 z y 2 = 1 R u = 3w 2 R w 5v R v.

Types of Differential Equations Order of a Differential Equation The order of any differential equation is the highest order of the derivative present in the equation. d2 u dx 2 + du dx = x + 1 ODE of oder 2. y + 3xy + 6 x y = 1 x 3 ODE of oder 3. x 2 dy dx R u + 3yx = sin x x = 3w 2 R w 5v R v ODE of oder 1. PDE of oder 1.

Ordinary Differential Equations An ordinary differential equation is an equation where the unknown is not a number but a function. First-order ODEs contain first derivatives and can be written as y = f (x, y). Second-order ODEs contain first and second derivatives and can be written as y = f (x, y, y ).

Ordinary Differential Equations Represent ODEs in Maxima There are two ways to represent ordinary differential equations in Maxima. The first way is to represent the derivatives by: diff(y,x,1) dy diff(y,x,2) d2 y dx dx 2 The second way is to write y(x) explicitly as a function of x: diff(y(x),x,1) dy diff(y(x),x,2) d2 y dx dx 2

Ordinary Differential Equations Solving first-oder ODEs Using Maxima Routine ode2 can be used to solve first-order ODEs. y = f(x, y) ode2(eqn,y,x). It takes three arguments: an ODE given by eqn, the dependent variable y, and the independent variable x. The function tries various integration methods to find an analytic solution.

Ordinary Differential Equations Solving First-Oder ODEs Using Maxima Cont... When successful, it returns either an explicit or implicit solution for the dependent variable. %c is used to represent the integration constant of first-order equations. If routine ode2 cannot obtain a solution for whatever reason, it returns false. Routine ode2 stores information about the method used to solve the differential equations in variable method.

Ordinary Differential Equations Solving First-Oder ODEs Using Maxima Examples (i) dy dx = x + 2 (ii) y = x 2 1 (iii) x 2 dy dx + 3yx = sin x x (iv) dy dt = y(k y) (v) dy dx + 11xy = x 3 y 3 (vi) dy dt = y

Ordinary Differential Equations Solving Second-Oder ODEs Using Maxima Routine ode2 can also be used to solve second-order differential equations. y = f(x, y, y ) ode2(eqn,y,x). It takes three arguments: an ODE given by eqn, the dependent variable y, and the independent variable x. When successful, it returns either an explicit or implicit solution for the dependent variable. In this case the two integration constants are represented by %k1 and %k2.

Ordinary Differential Equations Solving Second-Oder ODEs Using Maxima Examples (i) y + y 6y = 0 (ii) 3 d2 y dx 2 + dy dx y = 0 (iii) 4y + 12y + 9y = 0 (iv) y 6y + 13y = 0

Initial Value Problems of First-Order An initial-value problem for the first-order consists of finding a solution y of the differential equation that also satisfies initial condition of the form: Where y 0 is given constant. y(x 0 ) = y 0.

Initial Value Problems of First-Order Solving Initial Value Problems of First-Oder ODEs Using Maxima Initial value problems of first order can be solved by routine ic1. y = f(x, y) sol : ode2(eqn, y, x) sol, y(x 0 ) = y 0 ic1(sol, x = x 0, y = y 0 ) It takes a general solution to the equation as found by ode2 as its first argument. The second argument x 0 gives an initial value for the independent in the form x = x 0 and the third argument y 0 gives the initial value for the dependent variable in the form y = y 0.

Initial Value Problems of First-Order Solving initial value problems of first-oder ODEs using Maxima Example Find the solution of the initial value problem: x 2 dy dx sin x + 3yx =, y(π) = 0. x

Initial Value Problems of Second-Order An initial-value problem for the second-order consists of finding a solution y of the differential equation that also satisfies initial conditions of the form: y(x 0 ) = y 0 y (x 0 ) = y 1. Where y 0 and y 1 are given constants.

Initial Value Problems of Second-Order Solving Initial Value Problems of Second-Oder ODEs Using Maxima Initial value problems of second order can be solved by routine ic2. y = f(x, y, y ) sol : ode2(eqn, y, x) sol y(x 0 ) = y 0 ic2(sol, x = x 0, y = y 0, diff(y, x) = y 1 ) y (x 0 ) = y 1 ic2 has an additional forth argument y 1 that gives the initial value of the first derivative of the dependent variable with respect to the independent variable in the form diff(y,x)= y 1.

Initial Value Problems of Second-Order Solving Initial Value Problems of Second-Oder ODEs Using Maxima Examples (i) Solve the initial-value problem: y + y(y ) 3 = 0 y(0) = 0 y (0) = 2. (ii) Solve the initial-value problem: y + y 6y = 0 y(0) = 1 y (0) = 0.

Linear System of ODEs desolve(eqn, y) desolve([eqn 1,..., eqn n], [y 1,.., y n]) The function desolve, solves systems of linear ordinary differential equations using Laplace transform. Here the eqn s are differential equations in the dependent variables y 1,..., y n. The functional dependence of y 1,..., y n on an independent variable, for instance x, must be explicitly indicated in the variables and its derivatives.

Linear System of ODEs Example Solve the following system of linear ODEs. x (t) = x(t) 2y(t) y (t) = x(t) + y(t)

Linear System of ODEs Example Correct Syntax for desolve Following would not be the correct way to define two equations: eqn1 : eqn2 : diff (x, t) = x 2 y; diff (y, t) = x + y; The correct way would be: eqn1 : diff (x(t), t) = x(t) 2 y(t); eqn2 : diff (y(t), t) = x(t) + y(t); The call to the function desolve would then be: desolve([eqn1, eqn2], [x(t), y(t)]);

Linear System of ODEs with Initial Conditions If initial conditions are known, they can be supplied by using atvalue. Notice that the conditions must be given before the equations are solved.

Linear System of ODEs with Initial Conditions Example Solve following systems of linear ODEs with given initial conditions. x (t) = x(t) 2y(t) x(0) = 1 y (t) = x(t) + y(t) y(0) = 1

Thank You