Starting from:

$29.99

Conference 4 Numerical Differentiation: Optimal Step Size

Conference 4
Numerical Differentiation: Optimal Step Size
Numerical Integration: Trapezoid Rule
Numerical Dierentiation: Optimal Step Size
In class, the optimal step size h for the centered dierence approximation of f
0
(x0) with O(h
2
) error
was derived. Write a matlab program and create a graph that shows this theoretically optimal h
matches with the computations for the function f(x) = x
2
ln(x) at x0 = 2.
Numerical Dierentiation: Optimal Step Size
a. Derive the ve-point midpoint approximation of f
0
(x0).
b. Find the optimal h that minimizes both the computational and truncation (Taylor) error in the
ve-point midpoint approximation of f
0
(x0).
c. For the function f(x) = x
2
ln(x) evaluated at the point x0 = 2, show that this theoretically
optimal h actually matches with the computations.
Numerical Integration: Trapezoid Rule
a. Evaluate using the trapezoid rule with x0 = −1/4, x1 = 1/4.
Z 1/4
−1/4
cos2
(x) dx .
b. What is the actual error of the approximation in part a?
c. What is the theoretical upper bound on the error of the approximation in part a?
Numerical Integration: Trapezoid Rule
Assuming that the interval [a, b] is divided evenly by the points a = x0 < x1 < ... < xN = b with
step size h, develop a composite trapezoid rule for approximating R b
a
f(x) dx.

More products