21.04.2015 Views

The Computable Differential Equation Lecture ... - Bruce E. Shapiro

The Computable Differential Equation Lecture ... - Bruce E. Shapiro

The Computable Differential Equation Lecture ... - Bruce E. Shapiro

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

CHAPTER 9. DIFFERENTIAL ALGEBRAIC EQUATIONS 179<br />

2. We could solve 9.157 for E and eliminate E completely from the system, giving<br />

a system of three explicit ODE’s:<br />

A ′ = −αA(1 − X) + βX (9.139)<br />

B ′ = γX (9.140)<br />

X ′ = αA(1 − X) − (γ + β)X (9.141)<br />

<strong>The</strong>n the value of E can be computed from the constraint E = 1 − X after<br />

X is known. This is the method that is generally used to solve a semi-explicit<br />

system where we are able to solve for the constraints and reduce the system<br />

to an ODE.<br />

3. We can treat the system as a full implicit DAE as in 9.143 and use Newton’s<br />

method to extract y n at each step. This is the the only procedure that can be<br />

used for a fully implicit system, that is, a DAE where it is not clear how to<br />

separate the constraints from the ODEs, and so we will illustrate the procedure<br />

in detail.<br />

✬<br />

✩<br />

Algorithm 9.1. Fully Implicit DAE with Backward Euler<br />

To solve the fully implicit differential algebraic equation<br />

At each time step t n , solve<br />

F<br />

F(t, y, y ′ ) (9.142)<br />

(<br />

t n , y n , 1 )<br />

h (y n − y n−1 ) = 0 (9.143)<br />

for y n using Newton’s method<br />

y k+1<br />

n<br />

where the Jacobian J is<br />

= y k n − J −1 F<br />

(<br />

t n , y n , 1 )<br />

h (y n − y n−1 )<br />

J = 1 ∂F<br />

h ∂y ′ + ∂F<br />

∂y<br />

In general it is more efficient to calculate updates by solving<br />

(9.144)<br />

(9.145)<br />

J∆y = F (9.146)<br />

for ∆y, e.g., by Gaussian elimination on a sparse system, and updating<br />

y k+1<br />

n = y k n + ∆y (9.147)<br />

instead of inverting J.<br />

✫<br />

✪<br />

c○2007, B.E.<strong>Shapiro</strong><br />

Last revised: May 23, 2007<br />

Math 582B, Spring 2007<br />

California State University Northridge

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

Saved successfully!

Ooh no, something went wrong!