Computational
Engineering
Galerkin Method
Yijian Zhan
Ning Ma
Galerkin Method
Engineering problems: differential
equations with boundary conditions.
Generally denoted as: D(U)=0; B(U)=0
Our task: to find the function U which
satisfies the given differential equations
and boundary conditions.
Reality: difficult, even impossible to solve
the problem analytically
Galerkin
Method
In practical cases we often apply
approximation.
One of the approximation methods:
Galerkin Method, invented by Russian
mathematician Boris Grigoryevich Galerkin.
Galerkin
Method
Related
knowledge
Inner product of functions
Basis of a vector space of functions
Galerkin
Method
Inner
product
Inner product of two functions in a certain
domain:
b
f , f (x)g(x)dx
a
g
shows the inner
product of f(x) and g(x) on the interval [ a,
b ].
*Onfe, gim 0portant property:
If
other;
orthogonality
, f and g are orthogonal to each
**If for arbitrary w(x),
w, f
=0, f(x)
Galerkin
Method
Basis of a
space
V: a function space
Basis of V: a set of linear independent
functions {i (x)}i 0
( x)
Any
could be uniquely
V
functionf
written as the linear combination of the
basis:
f ( x) c j j ( x)
j 0
Galerkin
Method
Weighted residual
methods
A weighted residual method uses a finite
number of
( x)}ni 0 .
functions{i
The differential equation of the problem is
D(U)=0 on the boundary B(U), for example:
D(U ) L(U ( x)) f ( x)
on B[U]=[a,b].
where L is a differential operator and f
is a given function. We have to solve the
D.E. to obtain U.
Galerkin
method
Step 1.
Weighted
residual
Introduce a trial solution of U:
U u(
x)
0 ( x) c j j ( x)
j 1
to replace U(x)
j ( : finite number of basis functions
x)
cj
: unknown coefficients
* Residual is defined as:
R( x) D[u( x)] L[u( x)] f ( x)
Galerkin
Method
Step 2.
Weighted
residual
Choose arbitrary weight functions w(x),
let: w, R(x) w, D(u) b w(x){D[u(x)]}dx 0
a
With the concepts of inner product and
orthogonality, we have:
The inner product of the weight function
and the residual is zero, which means that
the trial function partially satisfies the
problem.
So, our goal: to construct such u(x)
Galerkin
Method
Weighted
residual
Step 3.
Galerkin weighted residual method:
choose weight function w from the basis
functions j , then
n
w, R j [D(u)]dx j ( x){D[0 ( x) c j j (
a
x)]}dx 0
b
j 1
These are a set of n-order linear
equations. Solve it, obtain all of thec
.
j coefficients
Galerkin Method
Weighted residual
Step 4.
n
The trial solutionu( x) 0 ( x) c j j ( x)
j 1
is the approximation solution we want.
Galerkin Method
Example
Solve the differential equation:
D( y( x)) y ''( x) y( x) 2x(1 x) 0
with the boundary condition:
y(0) 0, y(1) 0
Galerkin Method
Example
Step 1.
Choose trial functiony:(
x)
We make n=3, and
0 0,
1 x( x 1),
2 x 2 ( x 1) 2
3 x 3 ( x 1)3
0 ( x) cii ( x)
i 1
Galerkin Method
Example
Step 2.
The weight functions are the same as
the basis functioins
Step 3.
Substitute the trial function y(x) into
b
w, R j [D(u)]dx j ( x){D[0 ( x) c j j (
x)]}dx 0
j 1
Galerkin Method
Example
Step 4.
i=1,2,3; we have three equations with
three unknown coefficc1,ice2n, ct3s
1
3c1 5c2 4c3
0
15 10 84 315
1 5c1 11c2
61c3
0
70 84 630 13860
1
4c
61c2
73c3
0
315 315 13860 60060
Galerkin Method
Example
Step 5.
Solve this linear equation set, get:
1370
0.18521
c1
7397
50688
c2
0.185203
273689
132
c3
0.00626989
21053
Obtain the approximation solution
3
y( x) cii (x)
i 1
Galerkin Method Example
Galerkin solution
Analytic solution
0.06
0.06
0.05
0.05
0.04
0.04
0.03
0.03
0.02
0.02
O.O~
0.2
0.4
0.6
0.8
0.2
0.4
0.6
0.8
References
1. O. C. Zienkiewicz, R. L. Taylor, Finite
Element Method, Vol 1, The Basis, 2000
2. Galerkin method, Wikipedia:
[Link]