Numerical Methods for Scientific Computing II: Homework 1 Solutions, Assignments of Mathematics

Solutions to homework 1 of the math 572: numerical methods for scientific computing ii course, focusing on euler's method and error analysis. Topics include finding the exact solution of a differential equation, computing numerical solutions using euler's method, and evaluating error functions.

Typology: Assignments

Pre 2010

Uploaded on 09/17/2009

koofers-user-boh
koofers-user-boh 🇺🇸

10 documents

1 / 1

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
MATH 572 Numerical Methods for Scientific Computing II Winter 2005
hw#1 due: Tuesday, January 25
0. Write a brief description of your scientific interests and/or reasons for taking this course.
If you work in a lab or research group, please give your supervisor’s name and describe
briefly the project you’re working on. (1 paragraph is fine)
1. Consider the problem y0=ay +b, y(0) = y0, where a, b are constants and a6= 0. Find
the exact solution y(t). Let unbe the numerical solution at time t=nh given by Euler’s
method. Find an expression for unand show that limn→∞ un=y(t).
2. Consider the problem y0=y2, y(0) = 1.
a) Compute y(1) using Euler’s method with stepsize h= 0.1,0.05,0.025,0.0125. Present
the results in a table with the following information.
column 1: h
column 2: un
column 3: unyn
column 4: (unyn)/h
b) Find the principal error function E(t) and evaluate E(1). Compare with column 4.
c) Perform Richardson extrapolation on the values in column 2.
3. The numerical solution of the problem y0=f(y), y(0) = y0by Euler’s method has
an asymptotic expansion of the form un=yn+hEn+h2Dn+O(h3) as h0, where
En=E(tn), Dn=D(tn) for certain functions E(t), D(t).
a) The equation for E(t) was given in class. Find the equation for D(t).
b) Consider the problem y0=y, y0= 1. In class we showed that E(t) = t
2et. Find D(t).
c) Compute y(1) using Euler’s method with stepsize h= 0.1,0.05,0.025,0.0125. Present
the results in a table with the following data.
column 1: h
column 2: un
column 3: unyn
column 4: (unyn)/h
column 5: un(yn+hEn)
column 6: (un(yn+hEn))/h2
Evaluate E(1), D(1) and compare with the results in the table.
4. Let y0=f(y), where f(y) is bounded and satisfies a Lipschitz condition. In class it
was shown that an explicit 1-step method of the form un+1 =un+hF (un, h) converges if
F(u, h) satisfies two conditions: (a) |F(u, h)f(u)| Ch, (b) |F(u, h)F(v, h)|
e
L|uv|,
for 0 hh0, where h0, C,
e
Lare positive constants. Find F(u, h) for the midpoint rule
and show that it satisfies these two conditions.

Partial preview of the text

Download Numerical Methods for Scientific Computing II: Homework 1 Solutions and more Assignments Mathematics in PDF only on Docsity!

MATH 572 Numerical Methods for Scientific Computing II Winter 2005 hw#1 due: Tuesday, January 25

  1. Write a brief description of your scientific interests and/or reasons for taking this course. If you work in a lab or research group, please give your supervisor’s name and describe briefly the project you’re working on. (1 paragraph is fine)
  2. Consider the problem y′^ = ay + b, y(0) = y 0 , where a, b are constants and a 6 = 0. Find the exact solution y(t). Let un be the numerical solution at time t = nh given by Euler’s method. Find an expression for un and show that limn→∞ un = y(t).
  3. Consider the problem y′^ = −y^2 , y(0) = 1. a) Compute y(1) using Euler’s method with stepsize h = 0. 1 , 0. 05 , 0. 025 , 0 .0125. Present the results in a table with the following information. column 1: h column 2: un column 3: un − yn column 4: (un − yn)/h b) Find the principal error function E(t) and evaluate E(1). Compare with column 4. c) Perform Richardson extrapolation on the values in column 2.
  4. The numerical solution of the problem y′^ = f (y), y(0) = y 0 by Euler’s method has an asymptotic expansion of the form un = yn + hEn + h^2 Dn + O(h^3 ) as h → 0, where En = E(tn), Dn = D(tn) for certain functions E(t), D(t). a) The equation for E(t) was given in class. Find the equation for D(t). b) Consider the problem y′^ = y, y 0 = 1. In class we showed that E(t) = − 2 t et. Find D(t). c) Compute y(1) using Euler’s method with stepsize h = 0. 1 , 0. 05 , 0. 025 , 0 .0125. Present the results in a table with the following data. column 1: h column 2: un column 3: un − yn column 4: (un − yn)/h column 5: un − (yn + hEn) column 6: (un − (yn + hEn))/h^2 Evaluate E(1), D(1) and compare with the results in the table.
  5. Let y′^ = f (y), where f (y) is bounded and satisfies a Lipschitz condition. In class it was shown that an explicit 1-step method of the form un+1 = un + hF (un, h) converges if F (u, h) satisfies two conditions: (a) |F (u, h)−f (u)| ≤ Ch, (b) |F (u, h)−F (v, h)| ≤ L˜|u−v|, for 0 ≤ h ≤ h 0 , where h 0 , C, L˜ are positive constants. Find F (u, h) for the midpoint rule and show that it satisfies these two conditions.