DOC PREVIEW
TRINITY CSCI 2323 - Differential Equations

This preview shows page 1-2-3 out of 8 pages.

Save
View full document
View full document
Premium Document
Do you want full access? Go Premium and unlock all 8 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 8 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 8 pages.
Access to all documents
Download any document
Ad free experience
Premium Document
Do you want full access? Go Premium and unlock all 8 pages.
Access to all documents
Download any document
Ad free experience

Unformatted text preview:

1Differential Equations9-28-20052Opening Discussion■What did we talk about last class?■Let's talk a bit about the first project.■What do you know about differential equations?3What are ODEs?■Ordinary differential equations are extremely common in science. The idea is that we have functions that tell us the derivatives of values instead of telling us the values themselves.■In a math class you learn various techniques to solve ODEs. The simplest ODEs can be solved simply by integrating them.■Numerically, we can approximate the function by “following the slope” since it is the slope that we are given.˙x1= f1t , x1,x2,... , xn˙x2= f2t , x1,x2,... , xn...˙xn= fnt , x1,x2,... , xn4ODEs in Matlab■Matlab has a number of build in ODE solvers. All of these deal with systems of linear ODEs. That means that we have a set of equations of the form where the first derivative of a value is equal to some function.■In general, any ODE of any order (those involving higher derivatives) can be converted to a system of first order ODEs by using variables to represent the higher order derivatives.■Unless you have a reason to use something else, you will typically solve your ODEs with the ode45 function. This function uses a 4th to 5th order Runga-Kutta method.5Euler's Method■Just to help you see how we solve differential equations on a computer, we should look at Euler's method. This is a first order method that you shouldn't use unless you have nothing better to use. It has the advantage of being simple and fast.■Given the system of equations mentioned before, Euler's method would say the x values are as follows.x1tt =x1t t∗ f1t , x1,x2,... , xnx2tt =x2t t∗ f2t , x1,x2,... , xn...xntt =xnt t∗ fnt , x1,x2,... , xn6Using the ode Functions■In order to use ode45 of other ODE solving functions, we must define our function in an m-file because we want to pass a handle to it into the ode function. This function should return the derivatives as a column vector.■If we don't use any return values the function will simply show a plot. A single return value returns a structure. Having two return values gives us the times as well as the arrays of values at each time. That can then be plotted as we see fit.7Examples■ODEs abound in physics. The simplest ones involve solving the paths of particles interacting through a force like gravity or having masses on springs.■Population biology can also be expressed as differential equations. Consider things like predator-prey models where how quickly a population changes depends on how much food it has, how many there are now, and how many predators there are.8Reminders■You don't have anything due until next


View Full Document

TRINITY CSCI 2323 - Differential Equations

Documents in this Course
Load more
Download Differential Equations
Our administrator received your request to download this document. We will send you the file to your email shortly.
Loading Unlocking...
Login

Join to view Differential Equations and access 3M+ class-specific study document.

or
We will never post anything without your permission.
Don't have an account?
Sign Up

Join to view Differential Equations 2 2 and access 3M+ class-specific study document.

or

By creating an account you agree to our Privacy Policy and Terms Of Use

Already a member?