1
$\begingroup$

Find the error of the approximation for $\int_{-1}^1 f(x) dx$ for

a. $f(1) + f(-1)$

b. $\frac{2}{3}(f(-1) + f(0) + f(1))$

c. $f(\frac{-1}{\sqrt{3}}) + f(\frac{1}{\sqrt{3}})$

To me it looks like part a is an approximation using the Trapezoid Rule. It also looks like part b is an approximation using Simpson's Rule. And c also looks like an approximation, but I'm not 100% sure which one. I think that part c is an approximation using the Midpoint Rule.

Starting with Part A

According to my book, the error term for the Trapezoidal Rule is defined as $\int_{x_0}^{x_1}f(x) dx = \frac{h}{2}(y_0 + y_1) - \frac{h^3}{12} f''(c)$. I know that the error term in this equation is $\frac{h^3}{12}f''(c)$, but since $f(x)$ is not defined, then how am I supposed to find the error of approximation?

Additionally, the above-mentioned formula is only for the basic Trapezoidal Rule, there is also the Composite Trapezoidal Rule which is defined as $\int_a^b f(x) dx = \frac{h}{2}(y_0 + y_m + 2 \sum_{i=1}^{m-1} y_i) - \frac{(b-a)h^2}{12}f''(c)$. Since the Composite Trapezoidal Rule is just the Basic Trapezoidal Rule applied over more than one interval, then how am I supposed to know whether to this problem is referring to the basic or composite rule?

I assume that if I am able to solve part a, then b and c should follow using Simpson's Rule and the Midpoint Rule respectively.

Additionally, I'm not sure that my thought process is even correct, so if there is another method in which this should be done, then please feel free to explain that instead.

$\endgroup$
  • $\begingroup$ Your guesses for b) and c) are wrong, b) is not a named method and c) is (probably) a Gauß integration method. Use Taylor expansions. Using $f''(c)$ or $\|f''\|_\infty$ in the error estimate is acceptable and expected. $\endgroup$ – LutzL Dec 19 '16 at 10:31
  • $\begingroup$ The Taylor expansion for $f(x)$ is $f(x) + x f'(x) + \frac{1}{2} x^2 f''(x) + \frac{1}{6}x^3 f^{(3)}(c) $. What do I do with this? $\endgroup$ – user3370201 Dec 19 '16 at 17:20
  • $\begingroup$ You have some errors in the formula. The values and derivatives of $f$ should be evaluated at $0$, only $c$ depends on $x$. Then you can apply all formulas to the Taylor polynomial. $\endgroup$ – LutzL Dec 19 '16 at 19:56
2
$\begingroup$

a) is indeed the trapezoid formula with error bound $\frac23\|f''\|_\infty$.

b) is a combination of the trapezoidal and midpoint method and as it is not the Simpson method (coefficients proportional to $[1,4,1]$),it is also of order $2$.

c) is also a symmetric formula and thus of even error order. As it is exact for $f(t)=t^2$ and has obviously an error for $f(t)=(3t^2-1)^2$, it is of error order 4, and thus in the family of Gauß' quadrature methods.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.