计算物理学概论 Introduction to Computational Physics PHYS105

0

这是一份liverpool利物浦大学PHYS1042的成功案例

计算物理学概论 Introduction to Computational Physics PHYS105

$$
f^{\prime}\left(x_{0} \pm h\right)=\frac{\mp f\left(x_{0} \pm h\right) \pm f\left(x_{0}\right)}{h}+O(h)
$$
and if we stop the Taylor expansion at that point our function becomes,
$$
f(x)=f_{0}+\frac{f_{h}-f_{0}}{h} x+O\left(x^{2}\right) .
$$
for $x=x_{0}$ to $x=x_{0}+h$ and
$$
f(x)=f_{0}+\frac{f_{0}-f_{-h}}{h} x+O\left(x^{2}\right),
$$
for $x=x_{0}-h$ to $x=x_{0}$. The error goes like $O\left(x^{2}\right)$. If we then evaluate the integral we obtain
$$
\int_{-h}^{+h} f(x) d x=\frac{h}{2}\left(f_{h}+2 f_{0}+f_{-h}\right)+O\left(h^{3}\right),
$$

英国论文代写Viking Essay为您提供作业代写代考服务

PHYS105 COURSE NOTES :

$$
f(x)=f_{0}+\frac{f_{h}-f_{-h}}{2 h} x+\frac{f_{h}-2 f_{0}+f_{-h}}{h^{2}} x^{2}+O\left(x^{3}\right)
$$
Inserting this formula in the integral we obtain
$$
\int_{-h}^{+h} f(x) d x=\frac{h}{3}\left(f_{h}+4 f_{0}+f_{-h}\right)+O\left(h^{5}\right)
$$