Using Taylor expansion to derive error formula for midpoint rule

1k Views Asked by At

The formula for local midpoint rule in the interval [-h/2, h/2]

I cannot seem to find an answer to how this is done anywhere (including my course notes).

Any help is appreciated.

2

There are 2 best solutions below

0
On BEST ANSWER

Set $$g(h)=\int_{-h/2}^{h/2}f(x)dx-hf(0)$$ and compute $$ g(0)=0\\ g'(h)=\frac12(f(h/2)+f(-h/2))-f(0)\implies g'(0)=0\\ $$ etc. to find the Taylor expansion of $g$.

0
On

Put $f(x)=f(0)+xf'(0)+x^2f''(0)/2+... $ so $\int_{-h/2}^{h/2}f(x)dx =hf(0)+h^3f''(0)/(2*3*8)+... $.