Title: Numerical Methods for Partial Differential Equations
1Numerical Methods for Partial Differential
Equations
- Introduction
- Finite difference method for first order
hyperbolic PDEs - Method of characteristics for first order
hyperbolic PDEs - Method of lines approach for first order
hyperbolic PDEs - Finite difference method for second order
elliptic PDEs - Finite element method for second order elliptic
PDEs - Weighted residuals method for second order
elliptic PDEs - Finite difference method for second order
parabolic PDEs
Slides adapted from Prof. Shang-Xu. Hu of ZJU,
Applied Numerical Computation Methods. 2000.5
21. Introduction to PDEs
- number of variables at least 2
- order the highest order of derivative
- characteristic
- using the first order PDE as an example
3(No Transcript)
4- types
- first order linear PDE
Advection Equation(AE)
second order linear PDE
5- solution methods
- Method of Finite Differences (MFD)
- Method of Characteristics (MOC)
- Method of Lines (MOL)
- Method of Finite Elements (MFE)
- Method of Weighled Residuals (MWR)
- Numerical questions
- Convergence
- When the steps approach to infinitely small,
will the numerical results coincide the
theoretical results? - Stability
- When the error is introduced at a certain
step, will this error be amplified or attenuated
after several steps of numerical computation?
62. Finite difference method for first order
hyperbolic PDEs
known as Advection Equation (AE)
v is the flow speed The analytical
solution is
To find a specific solution, we need two
auxiliary conditions
7 assuming the forcing function
is a Rump The solution of
is shown below.
Fig. 1. Propagation of the Wave Front
8 2.1 The simplest finite difference format
Fig. 2
9 The above method is called Forward Time Centered
Space FTCS representation In fact, this
method is not practical since it is an unstable
method Consider the numerical error r
Because the original PDE is linear, the
error propagation is by which is identical to
the original equation Independent Solutions of
Difference Equations
10 solutionauxiliary solution and
specific solution Auxiliary solution
Auxiliary solution composes of two independent
solutions
11 Finite difference solution
Let us use Operator Calculus to derive with
the Difference Operator
It is the same as the differential operator.It is
a linear operator. When applied to the linear
second order difference equation
Similar to the differential equation, its
auxiliary solution can be obtained as follows
12So, from
Two independent solutions are
(Eigenmode)
13The general form of the independent solution of
difference equation is given by
In our numerical error analysis problem of PDE
solution, clearly,
Substitute the independent solution into the
difference expression, we have,
So, we can get
142.2 Improved finite difference format
Fig. 3
Fig. 4
Courant Condition
15- The physical meaning
- Of Courant condition
- Waveform travels along
- The line xvt
- ?t knot selection
- when knot is on the line
- when knot is outside the line
- when knot is inside the line
- The Lax finite difference format can also be
written as - This can be regarded as the FTCS difference
format for the following PDE
Fig. 5
dissipative term Numerical Viscosity
163. Method of characteristics (MOC) for 1st order
hyperbolic PDEs
So, this has the same solution as the
original PDE.
is called the MOC equation.
On the characteristic curve, those satisfying
Are the solution of the original PDE.
173.1 Method of Characteristics (MOC)
Fig. 6
183.1 Method of Characteristics (MOC)
Fig. 7
19(No Transcript)
204 Method of lines (MOL) approach for first order
hyperbolic PDEs
Finite Difference PDE is completely discretized
as a set of difference equations. Using linear
algebra to solve. Method of lines PDE is partly
discretized as a set of ODEs and using ODE
numerical solution method to solve.
21Method of Lines (MOL)
Line space
Integration step
Fig. 8
225. Finite difference method for second order
elliptic PDEs
- known as the steady-state heat conduction
equation and general form is - Dirichlet problem
- Neumann problem
23u(x0,y)f1(y)
u(xm,y)f2(y)
Fig. 9
Laplace equation Dirichlet boundary condition
and Neumann boundary condition. Poisson equation
- Four (4) boundary conditions required. There are
3 types of boundary conditions - Dirichlet boundary condition
- Neumann boundary condition
- Mixed or hybrid boundary condition.
24 5.1 Finite difference of Laplace operator
Apply the above for Laplace operator
25Fig. 10
26Example Laplace equation with Dirichlet boundary
Fig. 11
27To increase the accuracy, we should use a denser
grid
Fig. 12
28Laplace equation with Dirichlet boundary
condition numerical solutions
- elimination method
- Direct iteration Liebmann method
- S.O.R. method
- Alternating direction iteration (A.D.I.) method
296 Finite element method for second order
elliptic PDEsFinite Elements Method (FEM)
Let us use Laplace equation Dirichlet problem as
an illustrative example Based on
Variational Principles Equivalence theorem The
solution of the above PDE will minimize the
following functional
Fig. 13
30Discretize D, usually using trangulation
method For each element use bivariate function
to approximate At three vertices, we can get
Then,
where
31UkWk
UiWi
UjWj
Fig. 14
32Therefore, where Now that the vertices
coordinates are specified, one can get Moreover,
33Functional minimization problem amounts
to with the following approximation The
minimum solution is from Therefore, we can
get That is
W is given on the boundary
n the number of inner knots
34For a more general situation The
functional to be minimized is We can similarly
do the discretization and get the finite element
solution
Fig. 15
358 Finite difference method for second order
parabolic PDEs
Dynamic diffusion equation For one dimensional
space When using finite difference to replace
the differentiation, there are many options,
e.g., So, We need We have some other easy
methods
36Explicit method We get or, Then, we have
Fig. 16
37Illustrative example where Compare the
numerical result with the following analytical
result
air
Saturated steam C2H5OH
Fig. 17
38Fig. 18
Number of time steps
Analytical Solutions Numerical Solutions
Analytical versus Numerical Solutions Diffusion
Dynamics
r?0.25
39Fig. 19
Number of time steps
Analytical Solutions Numerical Solutions
Analytical versus Numerical Solutions Diffusion
Dynamics
r?0.5
40Stability analysis of the explicit method
Therefore,
41 Therefore, we have