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.
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.
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$.