Numerical Methods For ODE - NCSU

2y ago
26 Views
2 Downloads
844.07 KB
18 Pages
Last View : 13d ago
Last Download : 3m ago
Upload by : Cannon Runnels
Transcription

Numerical Methods for ODE“Mathematics is an experimental science, and definitions do not come first, butlater on,” Oliver Heaviside

Initial Versus Boundary Value ProblemsInitial Value Problems (IVP):Boundary Value Problems (BVP):

Numerical Methods for IVP: Euler’s MethodInitial Value Problem:Notation:Taylor Series:Euler’s Method:Accuracy: Local truncation errorGlobal truncation errorAssumptions:

Euler and Implicit Euler MethodsNote:Euler’s Method: Left EndpointImplicit Euler: Right EndpointStability: Apply method toForward EulerImplicit Euler

Runge-Kutta-Feylberg Methods4th Order Runge-Kutta:Accuracy: Local Truncation error is 4th-order if u(t) has five continuous derivatives.Runge-Kutta-Feylberg: Use R-K method with 5th order truncation error to estimatelocal error in 4th order R-K method to choose appropriate stepsize.

MATLAB ODE RoutinesAlgorithms: From the MATLAB ODE documentation ode45 is based on an explicit Runge-Kutta (4,5) formula, the Dormand-Prince pair. It is a one-step solver in computing y(tn), it needs only the solution at the immediately preceding time point, y(tn-1). In general,ode45 is the best function to apply as a "first try" for most problems. ode23 is an implementation of an explicit Runge-Kutta (2,3) pair of Bogacki and Shampine. It may be moreefficient than ode45 at crude tolerances and in the presence of moderate stiffness. Like ode45, ode23 is aone-step solver. ode113 is a variable order Adams-Bashforth-Moulton PECE solver. It may be more efficient than ode45 atstringent tolerances and when the ODE file function is particularly expensive to evaluate. ode113 is amultistep s olver - it normally needs the solutions at several preceding time points to compute the currentsolution. The above algorithms are intended to solve nonstiff systems. If they appear to be unduly slow, try using oneof the stiff solvers below. ode15s is a variable order solver based on the numerical differentiation formulas (NDFs). Optionally, ituses the backward differentiation formulas (BDFs, also known as Gear's method) that are usually lessefficient. Like ode113, ode15s is a multistep solver. Try ode15s when ode45 fails, or is very inefficient, andyou suspect that the problem is stiff, or when solving a differential-algebraic problem. ode23s is based on a modified Rosenbrock formula of order 2. Because it is a one-step solver, it may bemore efficient than ode15s at crude tolerances. It can solve some kinds of stiff problems for which ode15s isnot effective. ode23t is an implementation of the trapezoidal rule using a "free" interpolant. Use this solver if the problemis only moderately stiff and you need a solution without numerical damping. ode23t can solve DAEs. ode23tb is an implementation of TR-BDF2, an implicit Runge-Kutta formula with a first stage that is atrapezoidal rule step and a second stage that is a backward differentiation formula of order two. Byconstruction, the same iteration matrix is used in evaluating both stages. Like ode23s, this solver may bemore efficient than ode15s at crude tolerances.

MATLAB ODE Routines: From the DocumentationSolverProblem TypeOrder ofAccuracyWhen to Useode45NonstiffMediumMost of the time. This should be the firstsolver you try.ode23NonstiffLowFor problems with crude error tolerancesor for solving moderately stiff problems.ode113NonstiffLow to HighFor problems with stringent errortolerances or for solving computationallyintensive problems.ode15sStiffLow toMediumIf ode45 is slow because the problem isstiffode23sStiffLowIf using crude error tolerances to solvestiff systems and the mass matrix isconstant.ode23tModerately StiffLowFor moderately stiff problems if you needa solution without numerical damping.ode23tbStiffLowIf using crude error tolerances to solvestiff systems.

Example 1Problem:Analytic Solution:Euler’s Method:4th Order R-K:Similarly,What is going on?

Example 2Experimental Beam Data:Voltage InputVoltage Input (Zoomed View)Lumped Model:Notes: Initial conditions? Experimental input How will ODE solvers accommodate the experimental input? How can you test numerical codes?Displacement

Example 3Feedback Control Design:State Estimator:Feedback Control:Issues: Estimator must be integrated inreal time!Implementation:(Nature) Observations are available only atdiscrete times

Numerical Methods for BVP: Finite DifferencesProblem:Grid:Note: N interior grid pointsCentered Difference Formulas: (From Taylor expansions)System:

Finite Difference Method for BVPFinite Difference System: DefineforMatrix System:and consider

Galerkin MethodsBoris Galerkin: 1871-1945; Mathematician and EngineerConsideron inner product spacespanandFor finite dimensional spaces,spanfindthat satisfiesEmploywhich yieldsTerminology: weight or test functions forbasis, trial or shape functions

Galerkin MethodsRayleigh-Ritz: TakesoWhen A is symmetric and positive definite, this is the R-R method andsolution is equivalent to that obtained by minimizingwith respect toFinite Element: Employ piecewise polynomials for the test and trial functions.Operator A does not have to be symmetric.Least Squares: TakeCollocation: Takeso

Finite Element Method for BVPProblem:Assumptions:Weak Formulation:Grid:Linear Basis:

Finite Element Method for BVPApproximate Solution:System:Matrix System:Integrals: Gaussian quadrature; e.g., 2 ptReference: Smith, Chapter 8

Error EstimatesLinear Splines:Cubic Splines:

Finite Difference Versus Galerkin MethodsGalerkin (Finite Element) Advantageous: Model derived using energy principles Complicated geometries Natural boundary conditions Coupled systems or multiphysics problems Rigorous error analysis in various normsFinite Difference Advantageous: Easier to program for certain problems Error analysis based on Taylor theory

MATLAB ODE Routines Algorithms: From the MATLAB ODE documentation ode45 is based on an explicit Runge-Kutta (4,5) formula, the Dormand-Prince pair. It is a one-step solver - in computing y(tn), it needs only the s

Related Documents:

The linear ODE is called homogeneous if g(x) 0, nonhomogeneous, otherwise. If an ODE is not of the above form, we call it a non-linear ODE. 1.1 First-order linear ODE The general form of a rst-order linear ODE is y0 p(x)y g(x): The basic principle to solve a rst-order linear ODE is to make left hand side a derivative of an

Bruksanvisning för bilstereo . Bruksanvisning for bilstereo . Instrukcja obsługi samochodowego odtwarzacza stereo . Operating Instructions for Car Stereo . 610-104 . SV . Bruksanvisning i original

Hill, David Brooks 215C Architecture dbhill@ncsu.edu * Hipp, Aaron Jordan 5124 Parks, Recreation & Tourism Mgt jahipp@ncsu.edu Leung, Yu-Fai Jordan 5107 Parks, Recreation & Tourism Mgt leung@ncsu.edu Machado, Gustavo Vet School Research Bldg R450 Population Health & Biology gmachad@ncsu.edu * Ma

NCSU), Reza Ghiladi (Metalloenzyme Chemistry, NCSU), Hou-min Chang (Lignin Chemistry, NCSU), and Ewellyn Capanema (NMR/Lignin Chemistry, NCSU). Others are listed in Management Plan A-2. Collaborators for the outreach/education program are Thomas Easley (NCSU), Valerie Brown-Schild

dignified. Collin‟s „‟Ode to Evening‟‟, Shelley‟s „‟Ode to the West Wind‟‟, Keats „‟Ode to a Nightingale„‟ and „‟Ode on a Grecian Urn‟‟ are the successful imitations of this form in the English language. Irregular

10 tips och tricks för att lyckas med ert sap-projekt 20 SAPSANYTT 2/2015 De flesta projektledare känner säkert till Cobb’s paradox. Martin Cobb verkade som CIO för sekretariatet för Treasury Board of Canada 1995 då han ställde frågan

service i Norge och Finland drivs inom ramen för ett enskilt företag (NRK. 1 och Yleisradio), fin ns det i Sverige tre: Ett för tv (Sveriges Television , SVT ), ett för radio (Sveriges Radio , SR ) och ett för utbildnings program (Sveriges Utbildningsradio, UR, vilket till följd av sin begränsade storlek inte återfinns bland de 25 största

Rules and Regulations of Internet Banking Terms and Conditions governing the Internet Banking Service of ICICI Bank UK 1. Definitions: In this document the following words and phrases shall have the meanings as set below unless the context indicates otherwise: "Account(s)" refers to the user's current account, savings account, term deposit account, credit card account, home loan account .