Professional Documents
Culture Documents
Numerical
Numerical
Iteration
Newton Raphson method for refining an approximate root x0 of f (x) = 0
xn+1 = xn
Particular case to find
Secant Method
xn+1 = xn f (xn )/
f (xn )
f 0 (xn )
N use xn+1 =
1
2
f (xn ) f (xn1 )
xn xn1
xn +
Interpolation
fn = fn+1 fn
fn = fn fn1
fn = fn+ 12 fn 21
1
fn =
fn+ 12 + fn 12
2
p(p 1) 2
p
fp = f0 + pf0 +
f0 + ... +
r f0
2!
r
where p =
x x0
h
n
X
yi `i (x)
i=1
where
`i (x) =
nj=1,j6=i (x xj )
nj=1,j6=i (xi xj )
N
xn
Numerical differentiation
Derivatives at a tabular point
1
1
f0 3 f0 + 5 f0 ...
6
30
1 4
1 6
2
2 00
h f0 = f0 f0 + f0 ...
12
90
1 2
1 3
1
1
0
hf0 = f0 f0 + f0 4 f0 + 5 f0 ...
2
3
4
5
11 4
5 5
2 00
2
3
h f0 = f0 f0 + f0 f0 + ...
12
6
Numerical Integration
hf00
Trapezium Rule
where
fi = f (x0 + ih), E =
x0 +h
f (x)dx '
x0
h
(f0 + f1 ) + E
2
h3 00
f (a), x0 < a < x0 + h
12
x0 +nh
x0
f (x)dx '
h
h2
h4 000
{f0 + 2f1 + 2f2 + ...2fn1 + fn } (fn0 f00 ) +
(f f0000 )...
2
12
720 n
where f00 = f 0 (x0 ), fn0 = f 0 (x0 + nh), etc
Z
Simpsons Rule
where
E=
x0 +2h
f (x)dx '
x0
h5 (4)
f (a)
90
h
(f0 + 4f1 + f2 ) + E
3
x0 +nh
x0
where
f (x)dx '
h
(f0 + 4f1 + 2f2 + 4f3 + 2f4 + ... + 2fn2 + 4fn1 + fn ) + E
3
E=
nh5 (4)
f (a).
180
x0 < a < x0 + nh
f (x)dx = 2f (0) + E
where
E=
2 00
f (a).
3
1<a<1
Gauss order 2.
Z
1
1
f (x)dx = f
+f
+E
3
3
1
1
where
E=
1 0v
f (a).
135
1<a<1
Differential Equations
To solve y 0 = f (x, y) given initial condition y0 at x0 , xn = x0 + nh.
Eulers forward method
yn+1 = yn + hf (xn , yn )
n = 0, 1, 2, ...
n = 0, 1, 2, ...
h
(f (xn , yn ) + f (xn + h, yn + hf (xn , yn ))).
2
h
(K1 + 2K2 + 2K3 + K4 )
6
where
K1
K2
K3
K4
f (xn , yn )
hK1
h
f xn + , yn +
2
2
hK2
h
f xn + , yn +
2
2
f (xn + h, yn + hK3 )
Chebyshev Polynomials
Tn (x) = cos n(cos1 x)
To (x) = 1
T1 (x) = x
sin n(cos1 x)
Tn0 (x)
Un1 (x) =
=
n
1 x2
Tm (Tn (x)) = Tmn (x).
Tn+1 (x) = 2xTn (x) Tn1 (x)
Z
Un+1 (x) =
Tn (x)dx
+ constant,
2
n+1
n1
f (x) =
where
n2
1
a0 T0 (x) + a1 T1 (x)...aj Tj (x) + ...
2
aj =
f (cos ) cos jd
0
R
and f (x)dx = constant +A1 T1 (x) + A2 T2 (x) + ...Aj Tj (x) + ...
where Aj = (aj1 aj+1 )/2j
j1
j0