0
  1. Use a Taylor series expansion to compute an error estimate in approximating the derivative of the function $f:\mathbb R\to\mathbb R$ using the formula $$ f'(x_0) \approx \frac{f(x_0-2h)-4f(x_0-h)+3f(x_0)}{2h} $$

So $\left|f '(x_0)-G_h(x_0)\right| ≤ ch^p$ where $G_h(x_0)= \frac{f(x_0-2h)-4f(x_0-h)+3f(x_0)}{2h}$

\begin{align} f(x_0-h) &= f(x_0)-hf '(x_0)+\frac{h^2}{2}f ''(x_0)-\frac{h^3}{3!}f '''(\varepsilon) \\ -4f(x_0-h) &= -4f(x_0)+4hf '(x_0)-2h^2f ''(x_0)-\frac{h^3}{3!}f '''(\varepsilon)+\frac{4h^3}{3!}f '''(\varepsilon) \\ f(x_0-2h) &= f(x_0)-2hf '(x_0)+\frac{4h^2}{2}f ''(x_0)-\frac{8h^3}{3!}f '''(\varepsilon_1) \\ 2hG_h(x_0) &= 2hf '(x_0)+\frac{2h^3}{3}f'''(\varepsilon)-\frac{2h^3}{3}f'''(\varepsilon_1) \\ \left|G_h(x_0)-f '(x_0)\right| &= h^2\left|\frac{1}{3}f'''(\varepsilon)-\frac{2}{3}f'''(\varepsilon_1)\right| \end{align}

so $p=2$ and $c=\max \left|f'''(\varepsilon_1) \right|$

In the second last line, was the $2hG_h(x_0)$ step done to make the algebra simpler?

kennytm
  • 7,495
stackdsewew
  • 1,047

1 Answers1

1

Simplicity is subjective and varies from person to person. However, if the computation was to be done on blackboard, then I would choose to expand $2hG_h(x_0)$ rather than $G_h(x_0)$, so that I would not waste the space associated with a long fraction where the nominator is trivial and all the computational work takes place in the denominator.

Important details are omitted in the above calculation. Depending on expected outcome of the class, a student could lose a significant amount of points. Specifically, there is no mention of the fact that the function must be three times differentiable before Taylor's theorem can be applied to produce $\epsilon$ and $\epsilon_1$. There is no statement recording that $\epsilon$ is in the interval between $x_0$ and $x_0-h$ and that $\epsilon_1$ is in the interval between $x_0$ and $x_0-2h$. While Taylor expansions are mentioned in the problem description, it would be appropriate to invoke Taylor's theorem explicitly in the solution. While $h>0$ is the standard choice, there is no harm in eliminating any doubt.

Finally, the given value of $c$ should be adjusted. We are interested only in small $h$, so there is no harm in limiting ourselves to $0 < h \leq h_0$ for some choice of $h_0 >0$. In this case \begin{equation} c = \max \{ f^{(3)}(x) \: | \: x \in [x_0 - 2h_0,x_0] \}. \end{equation} There is still one catch! We need $f^{(3)}$ to be continuous or it might not assume its maximum value on the interval $[x_0-2h,x_0]$.

Carl Christian
  • 12,583
  • 1
  • 14
  • 37