Error Estimation for Gauss Quadrature

842 Views Asked by At

I have an equation $$ \int_{0}^{1}sin(x)dx $$ and I want to find the error estimation for Gaussian quadrature using the above equation. I saw this formula for finding the error of the gaussian quadrature $$ \frac{(b-a)^{2n+1}(n!)^{4}}{(2n+1)(2n!)^{2}}\frac{f^{2n}(x)}{(2n!)} $$ For $n=2$ and by change of interval, i get this $$ \frac{(1)^{5}(2!)^{4}}{(5)(4!)^{2}} $$ Now the part I never get, i read some books online and they say $$ \max_{-1\leq x\leq 1}\frac{|f^{2n}(x)|}{(2n)!} $$ whiles others say $$ \frac{\max_{a\leq x\leq b}|f^{2n}(x)|}{(2n)!} $$ Which should I use. Please I need some clarity here.

Now if I use both cases, I never get the book's error. the books with this example obtain an error of $6.4180e-003$. How do they get it. Please I need explanation. Thanks.

1

There are 1 best solutions below

11
On

Can you provide one of the references for those books? Using the error formula you mention, the error can be bounded by

$$ \frac{(1-0)^{2\cdot 2+1}(2!)^4}{(2\cdot 2+1)(2\cdot 2)!^3 } |\sin 1| \approx1.94785\times 10^{-4}.$$

In this case, since you can compute the exact value of the integral, you can also compute the actual error, $1.09882\times 10^{-4}$, which is consistent with the error bound.