0

Consider $\int_{1}^{2m} \frac{1}{y} d y$. Show that the integral can be calculated using Trapezoid Rule with maximum error $$\frac{\left(2^{m}-1\right) h^{2}}{12}$$ for a given step length $h$.


Answer The error is given by $E = -f^{\prime \prime}(\xi) \frac{h^{3}}{6},\xi\in(1,2^m)$.

It must be the case that $\xi = 1$, but this is problematic because $\xi\in(1,2^m)$ and not $\xi\in[1,2^m)$. This means that the maximum error is actually not $\frac{\left(2^{m}-1\right) h^{2}}{12}$, but the maximum error is less than $\frac{\left(2^{m}-1\right) h^{2}}{12}$!

Also, I'm not sure what "for a given step length $h$" means?

Sorry
  • 1,028

2 Answers2

1

I am not sure what the boundaries are, I suppose you mean to integrate from $1$ to $2^m$ and not $1$ to $2m$? I also suppose you use $f(y)=\frac{1}{y}$.

In that case, the error is given by: $$-\frac{(2^m-1)h^2}{12}f''(\xi)$$ for suitable $\xi\in(1,2^m)$.

Now since $f''(\xi) = \frac{2}{\xi^3}$, this would lead to an error of $$E=-\frac{2\cdot(2^m-1)h^2}{12\xi^3}$$

Now we can choose $\xi$ such that $\frac{2}{\xi^3}=1$ so that $\xi=2^{\frac{1}{3}}$ which is about $1.26<2^m$ assuming $m>0$ (else the integral would be simply $0$ as you would integrate from $1$ to $1$).

So for this $\xi$ we have that the absolute error is bounded above $$|E|\leq\frac{(2^m-1)h^2}{12}$$

Marc
  • 1,198
0

If we apply the trapezoidal rule to the integral $\int_1^{2^m}\frac 1y dy$ (you must have a typo, the upper limit should be $2^m$), the error is given by $$ -\frac{(2^m -1) h^2}{12} f''(\xi), \quad \xi \in (1, 2^m) $$

where $h$ stands for the distance between consecutive integration nodes (this is the composite rule).

Now, since $|f''(\xi)| = \frac{2}{\xi^3} \leq 2$, you have that the absolute error is bounded by $$ \frac{(2^m-1) h^2}{6}. $$

PierreCarre
  • 20,974
  • 1
  • 18
  • 34