Coeb223 Formula Sheet For Final Exam
Coeb223 Formula Sheet For Final Exam
Coeb223 Formula Sheet For Final Exam
COEB223 / MATB324
True error:
True percent relative error:
100 %
=
100 %
Stopping criterion:
Terminate computation when a < s where s is the desired percent relative error
Taylor Series
Taylor series expansion
!" # = # + % # +
where remainder
/. =
# * # ,
.# # .
+
+ +
+ /.
2!
3!
!
0123#4#
.!"#!
.!"
or
/. = 5.!" #
Error propagation
For n independent variables x1, x2, , xn having errors 7", 7*, , 7. , the error in the
function f can be estimated via
:
:
:
= 9
9 7" + 9
9 7* + + 9
9 7.
:"
:*
:.
; =
Bisection
< + =
2
Formulation
; = =
False Position
!"
Secant
=
= #< = #
< # = #
!" =
Newton Raphson
#
#
# @" #
@" # #
""
A
*"
,"
"*
**
,*
",
*,
,,
|
|
|
""
C"
C* D F 0
C,
0
"*
**
0
",
*,
,,
|
|
|
C,,
,,
C"
C
*, ,
C* G * = *
**
C,
C"
"* *
", ,
" =
""
, =
LU decomposition
Decomposition
""
A *"
,"
"*
**
,*
",
1
*, D A*"
,,
,"
0
1
,*
Back Substitution
""
C"
0 I"
0D HI* J = HC* J A 0
0
1 I,
C,
"*
**
0
", "
"
I"
*, D H* J = HI* J H* J
,
,, ,
I,
Forward Substitution
Gauss-Seidel method
C"
"* *
", , O
=
""
M P
Q
K
K@" M K K@"
C*
*" "
*, ,
K
R
R 100% < S
* =
K
**
N
K
K
M
C,
," "
,* *
K
M
, =
,,
L
K@"
K
"
With relaxation,
K@"
Q =
Y +
"
where
Formulation
Z; = [Q
Y
" #*
" =
\"
Q Q
* #*
Y = Q
"
Polynomial
Regression
where
Z; = [Q
Y
"
* * #*
\"
Errors
Z;
Z^/` = a
2
* =
Z Z;
Z
where:
Z = [Q Qb#*
Z;
Z^/` = a
+ 1#
* =
Z Z;
Z
where:
Z = [Q Qb#*
Multiple
Linear
Regression
e
d
d[
d
d
*
c[
[
[ *
[ ,
[ *i
h
Y
,h
[ H "J =
h
*
fh
[ g
Q =
Y +
" " + +
m m
l[ Q O
M
M
[ Q
k
N
M[ * Q M
j
L
Q =
Y +
" " +
* *
where
* =
Z; = [Q
Y
" "
* * #*
by differentiating Sr with respect to each coefficients
and setting the partial derivatives equal to zero, we
have:
Newtons
divided
difference
interpolating
polynomial
[ "
[ "*
[ " *
[ * i
h
Y
[ " * h H
" J =
h
*
h
[ ** g
CY = Y #
C" = n" , Y o
C* = n* , " , Y o
C, = n, , * , " , Y o
Lagrange
interpolating
polynomial
l[ Q
O
M
M
[ " Q
k
N
M[ Q M
*
j
L
where
. # = [ p # #
\Y
Z Z;
Z
where:
\"
e
d
d[ "
d
d
c [ *
Z;
Z^/` = a
+ 1#
Z = [Q Qb#*
where,
p # = q
K\Y
Kr
K
K
Formulation
% # =
% # =
# @" #
First Derivative:
% # =
% # =
!" # #
First Derivative:
First Derivative
%
% # =
Errors
5#
5* #
5#
5* #
5* #
5f #
B. Numerical Integration
Method
Trapezoidal rule
Multiple-application
trapezoidal rule
Simpsons 1/3 rule
Multiple-application
Simpsons 1/3 rule
Gauss Quadrature
Gauss-Legendre
u C
#
# + C #
2
Formulation
C
#
wY # + 2 [ # + . #x
u
2
.@"
u C
#
\"
C
#
u
zY # + 4 [ # + 2
3
.@"
\",,,{,
u C
#
.@*
K\*,f,,
P" = 1.0000000
Y = 0.577350269
" = 0.577350269
PY = 0.5555556
P" = 0.8888889
P* = 0.5555556
}K ~ + . #
Y = 0.774596669
" = 0.0
* = 0.774596669
Change of variables:
=
C +
# + C
# X
2
C
I =
IX
2
Q !" = Q + "
Formulation
" = , Q #
1
1
Q !" = Q + " + *
2
2
" = , Q #
* = + , Q + " #
Q !" = Q + *
" = , Q #
1
1
* = + , Q + "
2
2
1
2
Q !" = Q + " + *
3
3
" = , Q #
3
3
* = + , Q + "
4
4
1
+ 2* + 2, + f #
6 "
" = , Q #
1
1
* = + , Q + "
2
2
1
1
, = + , Q + *
2
2
f = + , Q + , #
Q !" = Q +
Crank-Nicolson Method
Formulation
,K =
#*
<!"
<
V <!"
V <!"
@" + 1 + 2V #
!" =
V=
#*
<!"
V <!"
V <!"
@" + 21 + V #
!"
= V <@" + 21 V# < + V <!"
V=
#*