Elliptic Equations Laplace
Transcript of Elliptic Equations Laplace
1
Computational Fluid Dynamics - Prof. V. Esfahanian
1
Chapter 6
Elliptic EquationsFinite-Difference Method
First Session Contents:
1) Elliptic Equations
2) Dirichlet & Neumann Boundary Conditions
3) Iterative Methods (Jacobi, Gauss-Seidel, SOR)
4) Block Iterative Methods
5) ADI Method
2
Laplace equation is a good example for elliptic equations
Ideal fluid flow
Magnetic potential field
Electromagnetic potential field
Stress-strain analysis in solid elasticity
Applications
Elliptic Equations
3
Laplace equation is a good example for elliptic equations
Ideal fluid flow
Magnetic potential field
Electromagnetic potential field
Stress-strain analysis in solid elasticity
Applications
Non-homogenous form of the Laplace equation is called Poison Equation
Sink
Source
Elliptic Equations
4
Fourier Law
is the boundary of domain
is the boundary of sub-domain
If there is no sink or source in Ω,
the net heat flux passing ω should be zero
Elliptic Equations
2
Computational Fluid Dynamics - Prof. V. Esfahanian
5
Divergence Theorem
If is continuous in Ω, it should be zero:
k = const.
Elliptic Equations
6
Consider a source term in Ω
<0 Sink
>0 Source
Using Divergence theorem we have:
k = const.
Elliptic Equations
7
Elliptic Equations
8
Using central difference we have
Using uniform mesh and operator theory we have
Dirichlet Boundary Condition
3
Computational Fluid Dynamics - Prof. V. Esfahanian
9
Hint:
When fm,n is zero (Laplace equation),
um,n is equal to the average of neighbor values
Considering the above equation for all grid points (MxN),
a set of algebraic equations is achieved as follows
Dirichlet Boundary Condition
10
A is a square matrix of order MxN
U and b are a column vector of order MxN
Dirichlet Boundary Condition
11
For dirichlet boundary condition,
internal grid points are
Example
12
Example
4
Computational Fluid Dynamics - Prof. V. Esfahanian
13
Example
14
Comments:
Matrices U and b have the same order
Matrix b is affected by boundary conditions and source terms
Matrix A is square and has 5 non-zero elements in each row
Matrix A is called Bounded matrix
Matrix A is a block tridiagonal matrix (number of diagonal blocks
are equal to grid points in y direction and order of each block is
equal to grid points in x direction)
AU=b has a unique solution because A does not have any
zero eigenvalue.
Example
15
Neumann Boundary Condition
16
Ghost point
Neumann Boundary Condition
5
Computational Fluid Dynamics - Prof. V. Esfahanian
17
In the above equation, T.E. is O(h2)
Using central difference method for the boundary conditions,
the overall T.E. is O(h2)
To discretize Newman boundary conditions, using central
difference method, we need the ghost points.
Neumann Boundary Condition
18
Neumann Boundary Condition
19
Neumann Boundary Condition
20
Neumann Boundary Condition
Hint: Matrix A is Singular. The sum of values in each row is equal to zero
6
Computational Fluid Dynamics - Prof. V. Esfahanian
21
Compatibility Condition
The net heat flux is zero
22
The net heat flux is zero
If u is a solution then u+c is also a solution
If U is a solution then U+cI is also a solution
Compatibility Condition
23
Element boundary
Volume boundary
Example
24
Example
7
Computational Fluid Dynamics - Prof. V. Esfahanian
25
Example
26
Compatibility Equation
Example
27
Iterative Methods
Tx=b
Using numerical methods, the governing PDEs convert to system of algebraic
equations as follow:
Using Gauss-Jordan elimination, the above system of equations can be solved.
In difference numerical methods, the rank of matrix T is equal to the grid points
In 3-D problems, for a 20x20x20 grid, the rank of matrix T is 8000. Therefore,
the traditional elimination methods are not efficient and iterative methods can be
used due to lower computational cost and higher efficiency. 28
Laplace Equation
Iterative Methods
8
Computational Fluid Dynamics - Prof. V. Esfahanian
29
In a computer program 𝑗 → ∞ is not defined
To show the effect of variation in each iteration we have
Iterative Methods
30
For each 𝛼 and 𝛽
The minimum rate of convergence occurs when 𝑢 is closed to 1
Speed of convergence
Jacobi Iteration Method
31
For large value of N, rate of convergence is low
Suppose that
𝑁 ≫ 1 →𝜋
𝑁≪ 1
Number of iterations ∝ 𝑁2
Jacobi Iteration Method
32
Guass-Seidel
Jacobi
Guass-Seidel Iteration Method
9
Computational Fluid Dynamics - Prof. V. Esfahanian
33
Speed of convergence
Guass-Seidel Iteration Method
34
≈ 1≈1
2
For a square
Guass-Seidel Iteration Method
35
≈ 1≈1
2
For a square
Gauss-Seidel
Jacobi
Guass-Seidel Iteration Method
36
The gauss-Seidel iteration method can be written as
variation of two iteration
The experiments show that the speed of
convergence can be increased by
reducing/increasing this value
Successive Over Relaxation (SOR)
10
Computational Fluid Dynamics - Prof. V. Esfahanian
37
The Gauss-Seidel method with relation factor is called SOR method
The above equation can be written as follow
Successive Over Relaxation (SOR)
38
Speed of convergence
Shows the rate of convergence
Successive Over Relaxation (SOR)
39
≈ 1≈𝜔
2
For a square
The value of is minimum when
Successive Over Relaxation (SOR)
40
for a square we have
Gauss-Seidel
Jacobi
SOR
≈ 𝑁2
≈ 𝑁2
≈ 𝑁
There is not a general way to obtain 𝝎
Successive Over Relaxation (SOR)
11
Computational Fluid Dynamics - Prof. V. Esfahanian
41
Example
42
Jacobi Method
Gauss-Seidel Method
SOR
Convergence criterion
Example
43
Grid points
Grid points
Example
44
Iteration Iteration Method
Jacobi
Gauss-Seidel
SORfor for
Example
12
Computational Fluid Dynamics - Prof. V. Esfahanian
45
Grid points Grid points
Example
46
Jacobi
Method
Example
47
Grid points
Example
48
Block Iterative Methods
All the above equations can be solved by
Tri-Diagonal Matrix Algorithm (TDMA)
Jacobi Method
Gauss-Seidel Method
SOR
13
Computational Fluid Dynamics - Prof. V. Esfahanian
49
ADI MethodConsider the 2-D unsteady heat equation
Using Crank-Nicolson method we have:
The above equation has 5 unknowns
50
In this case, the
coefficient matrix
is pentadiagonal
The Thomas
algorithm (TDMA)
can not be used
There are some
numerical methods to
solve the above problem
which are not as efficient
as TDMA
Using ADI method,
we can use the
TDMA for 2-D
problems
ADI Method
51
Step 1 t → ∆t
2
𝜕2𝑇
𝜕𝑥2
𝜕2𝑇
𝜕𝑦2
is discretized implicitly
is discretized explicitly
ADI Method
52
ADI Method
14
Computational Fluid Dynamics - Prof. V. Esfahanian
53
Step 2 t + ∆t
2→ t+∆t
𝜕2𝑇
𝜕𝑥2
𝜕2𝑇
𝜕𝑦2
is discretized explicitly
is discretized implicitly
ADI Method
54
ADI Method
𝑛 +1
2
𝑛 + 1
55
1)
2)
1) 2)
ADI Method (Amplification Factor)
56
ADI Method (Amplification Factor)
15
Computational Fluid Dynamics - Prof. V. Esfahanian
57
ADI Method (Amplification Factor)