15.11.2014 Views

MATLAB Mathematics - SERC - Index of

MATLAB Mathematics - SERC - Index of

MATLAB Mathematics - SERC - Index of

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Initial Value Problems for ODEs and DAEs<br />

Examples: Solving Explicit ODE Problems<br />

This section uses the van der Pol equation<br />

2<br />

y′′ 1 – µ ( 1 – y 1 ) y′ 1 + y 1 = 0<br />

to describe the process for solving initial value ODE problems using the ODE<br />

solvers.<br />

• “Example: Solving an IVP ODE (van der Pol Equation, Nonstiff)” on page 5-9<br />

describes each step <strong>of</strong> the process. Because the van der Pol equation is a<br />

second-order equation, the example must first rewrite it as a system <strong>of</strong> first<br />

order equations.<br />

• “Example: The van der Pol Equation, m = 1000 (Stiff)” on page 5-12<br />

demonstrates the solution <strong>of</strong> a stiff problem.<br />

• “Evaluating the Solution at Specific Points” on page 5-15 tells you how to<br />

evaluate the solution at specific points.<br />

Note See “Basic ODE Solver Syntax” on page 5-7 for more information.<br />

Example: Solving an IVP ODE (van der Pol Equation, Nonstiff)<br />

This example explains and illustrates the steps you need to solve an initial<br />

value ODE problem:<br />

1 Rewrite the problem as a system <strong>of</strong> first-order ODEs. Rewrite the<br />

van der Pol equation (second-order)<br />

2<br />

y′′ 1 – µ ( 1 – y 1 ) y′ 1 + y 1 = 0<br />

where µ > 0 is a scalar parameter, by making the substitution y′ 1 = y 2 . The<br />

resulting system <strong>of</strong> first-order ODEs is<br />

y′ 1 = y 2<br />

y′ 2 =<br />

2<br />

µ ( 1 – y 1 )y 2 – y 1<br />

See “Working with Higher Order ODEs” on page 5-5 for more information.<br />

5-9

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!