0% found this document useful (0 votes)
60 views

Unit 10 (Partial Differential Equations)

The document discusses numerical methods for solving partial differential equations. It covers the Laplace equation, solution techniques like the Liebmann method, and applying these techniques to examples like finding the temperature at points on a heated plate. The key topics covered are partial differential equations, the Laplace equation, finite difference methods, and iterative techniques like the Liebmann/Gauss-Seidel method for solving PDEs numerically.

Uploaded by

ebrahim5936
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
60 views

Unit 10 (Partial Differential Equations)

The document discusses numerical methods for solving partial differential equations. It covers the Laplace equation, solution techniques like the Liebmann method, and applying these techniques to examples like finding the temperature at points on a heated plate. The key topics covered are partial differential equations, the Laplace equation, finite difference methods, and iterative techniques like the Liebmann/Gauss-Seidel method for solving PDEs numerically.

Uploaded by

ebrahim5936
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 37

Numerical Methods (CISE-301)

Unit-10
(Partial Differential Equations)
Dr. Muhammad Majid Gulzar (CIE-KFUPM)
Contents (Unit-10):
1) The Laplace Equation (Sec 29.1)

2) Solution Technique (Sec 29.2)

3) The Heat-Conduction Equation (Sec 30.1)

4) Explicit Methods (Sec 30.2)

5) A Simple Implicit Method (Sec 30.3)

Dr. Muhammad Majid Gulzar (CIE-KFUPM)


Partial Differential Equations:
 Derivative = Slope

Derivatives

Ordinary Derivatives Partial Derivatives


𝑑𝑑𝑑𝑑 𝜕𝜕𝜕𝜕
𝑑𝑑𝑑𝑑 𝜕𝜕𝜕𝜕
v is a function of one u is a function of more than one
independent variable independent variable

Dr. Muhammad Majid Gulzar (CIE-KFUPM)


Partial Differential Equations:
 Derivative = Slope
Differential Equations

Partial Differential Equations


Ordinary Differential Equations
𝑑𝑑 2 𝑣𝑣 𝜕𝜕 2 𝑢𝑢 𝜕𝜕 2 𝑢𝑢
+ 6𝑡𝑡𝑡𝑡 = 1 − =0
𝑑𝑑𝑡𝑡 2 𝜕𝜕𝑦𝑦 2 𝜕𝜕𝑥𝑥 2
Involve one or more Ordinary derivatives of
unknown functions Involve one or more Partial derivatives of
unknown functions

Dr. Muhammad Majid Gulzar (CIE-KFUPM)


Partial Differential Equations:
 Partial Differential Equations (PDE) is an equation that involves partial derivatives of an
unknown function of two or more independent variables

𝜕𝜕 2 𝑢𝑢 𝜕𝜕 2 𝑢𝑢
+ 2𝑥𝑥𝑥𝑥 2 + 𝑢𝑢 = 1
𝜕𝜕𝑥𝑥 2 𝜕𝜕𝑦𝑦

3
𝜕𝜕 2 𝑢𝑢 𝜕𝜕 3 𝑢𝑢
+6 = 𝑥𝑥
𝜕𝜕𝑥𝑥 2 𝜕𝜕𝑥𝑥𝜕𝜕𝑦𝑦 2

Dr. Muhammad Majid Gulzar (CIE-KFUPM)


Partial Differential Equations:
 PDE solution can be represented in 3 ways

Different curves are used for different Three dimensional plot of the function The axis represent the independent
values of one of the independent 𝑇𝑇(𝑥𝑥, 𝑡𝑡) variables and the value of the function is
variable displayed at grid points

Temperature at 𝑇𝑇(𝑥𝑥1 , 𝑡𝑡1 )


different values 𝑇𝑇 = 5.2

𝑡𝑡1
𝑥𝑥1

Dr. Muhammad Majid Gulzar (CIE-KFUPM)


Partial Differential Equations:
𝜕𝜕 2 𝑢𝑢 𝜕𝜕 2 𝑢𝑢 𝜕𝜕 2 𝑢𝑢
 PDE linear, 2nd order equations can be expresses as 𝐴𝐴 2 + 𝐵𝐵 + 𝐶𝐶 2 + 𝐷𝐷 = 0
𝜕𝜕𝑥𝑥 𝜕𝜕𝑥𝑥𝜕𝜕𝑦𝑦 𝜕𝜕𝑦𝑦

Dr. Muhammad Majid Gulzar (CIE-KFUPM)


The Laplace Equation (Sec 29.1)
The Laplace Equation:
 Heated plate as our fundamental context for deriving and solving the elliptic PDE will be
utilize

 Finite-difference solution to Elliptic equation is

Laplace Equation

Poisson Equation

Here, 𝑓𝑓(𝑥𝑥, 𝑦𝑦) is a function describing the sources or sinks of heat

Dr. Muhammad Majid Gulzar (CIE-KFUPM)


Solution Technique (Sec 29.2)
Solution Technique:
 The Laplacian Difference Equation
 A grid used for the finite-difference solution of elliptic PDEs in two independent variables such as the
Laplace equation

Laplace Equation

Dr. Muhammad Majid Gulzar (CIE-KFUPM)


Solution Technique:
 The Laplacian Difference Equation

𝑇𝑇𝑖𝑖,𝑗𝑗+1

𝑇𝑇𝑖𝑖−1,𝑗𝑗 𝑇𝑇𝑖𝑖,𝑗𝑗 𝑇𝑇𝑖𝑖+1,𝑗𝑗

𝑇𝑇𝑖𝑖,𝑗𝑗−1

Dr. Muhammad Majid Gulzar (CIE-KFUPM)


Solution Technique:
 To uniquely specify a solution to the PDE, a set of boundary conditions are needed

𝜕𝜕 2 𝑢𝑢(𝑥𝑥, 𝑡𝑡) 𝜕𝜕𝜕𝜕(𝑥𝑥, 𝑡𝑡)


− =0 𝑡𝑡
𝜕𝜕𝑥𝑥 2 𝜕𝜕𝜕𝜕

Region of
𝑢𝑢(0, 𝑡𝑡) = 0 interest

𝑢𝑢(1, 𝑡𝑡) = 0
1 𝑥𝑥
𝑢𝑢(𝑥𝑥, 0) = sin( 𝜋𝜋𝜋𝜋)

Dr. Muhammad Majid Gulzar (CIE-KFUPM)


Solution Technique:
 It is required to determine the steady state temperature at all points of a heated sheet of
metal. The edges of the sheet are kept at constant temperature 100,50, 0 and 75 degrees.

100

The sheet is divided by 5 × 5 grids 75 50

Dr. Muhammad Majid Gulzar (CIE-KFUPM)


Solution Technique: Known
To be determined

𝑇𝑇1,4 = 100 𝑇𝑇2,4 = 100 𝑇𝑇3,4 = 100

𝑇𝑇1,3 𝑇𝑇2,3 𝑇𝑇3,3


𝑇𝑇0,3 = 75 𝑇𝑇4,3 = 50

𝑇𝑇1,2 𝑇𝑇2,2 𝑇𝑇3,2


𝑇𝑇0,2 = 75 𝑇𝑇4,2 = 50

𝑇𝑇1,1 𝑇𝑇2,1 𝑇𝑇3,1


𝑇𝑇0,1 = 75 𝑇𝑇4,1 = 50

𝑇𝑇1,0 = 0 𝑇𝑇2,0 = 0 𝑇𝑇3,0 = 0

Dr. Muhammad Majid Gulzar (CIE-KFUPM)


Solution Technique: Known
To be determined

𝑇𝑇1,4 = 100 𝑇𝑇2,4 = 100 𝑇𝑇1,4 = 100 𝑇𝑇2,4 = 100 𝑇𝑇3,4 = 100

𝑇𝑇1,3 𝑇𝑇2,3 𝑇𝑇1,3 𝑇𝑇2,3 𝑇𝑇3,3


𝑇𝑇0,3 = 75

𝑇𝑇1,2 𝑇𝑇2,2 𝑇𝑇1,2 𝑇𝑇2,2 𝑇𝑇3,2


𝑇𝑇0,2 = 75

𝑇𝑇0,3 + 𝑇𝑇1,4 + 𝑇𝑇1,2 + 𝑇𝑇2,3 + −4𝑇𝑇1,3 = 0 𝑇𝑇1,3 + 𝑇𝑇2,4 + 𝑇𝑇3,3 + 𝑇𝑇2,2 − 4𝑇𝑇2,3 = 0
75 + 100 + 𝑇𝑇1,2 + 𝑇𝑇2,3 + −4𝑇𝑇1,3 = 0 𝑇𝑇1,3 + 100 + 𝑇𝑇3,3 + 𝑇𝑇2,2 − 4𝑇𝑇2,3 = 0

Dr. Muhammad Majid Gulzar (CIE-KFUPM)


Solution Technique:
Node (1,1)

Dr. Muhammad Majid Gulzar (CIE-KFUPM)


Solution Technique:

4 −1 0 −1 𝑇𝑇11 75
−1 4 −1 0 −1 𝑇𝑇21 0
0 −1 4 0 0 −1 𝑇𝑇31 50
−1 0 0 4 −1 0 −1 𝑇𝑇12 75
−1 0 −1 4 −1 0 −1 𝑇𝑇22 = 0
−1 0 −1 4 0 0 −1 𝑇𝑇32 50
−1 0 0 4 −1 0 𝑇𝑇13 175
−1 0 −1 4 −1 𝑇𝑇23 100
−1 0 −1 4 𝑇𝑇33 150

Dr. Muhammad Majid Gulzar (CIE-KFUPM)


Solution Technique:
 The Liebmann Method
 Most numerical solutions of the Laplace equation involve systems that are much larger in size.

 For example, a 10 × 10 grid involves 100 linear algebraic equations.

 Notice that there are a maximum of 5 unknown terms per line in the previous solution.

 For larger-sized grids, this means that a significant number of the terms will be zero.

 When applied to such sparse systems, full-matrix elimination methods waste great amounts of
computer memory storing these zeros.

 For this reason, approximate methods provide a viable approach for obtaining solutions for elliptical
equations.

Dr. Muhammad Majid Gulzar (CIE-KFUPM)


Solution Technique:
 The Liebmann Method

𝑗𝑗 = 1 𝑡𝑡𝑡𝑡 𝑛𝑛
𝑖𝑖 = 1 𝑡𝑡𝑡𝑡 𝑚𝑚

Overrelaxation is sometimes employed to accelerate the rate of convergence by applying the given formula after each iteration

𝜆𝜆 is a weighting factor that is set between 1 and 2

Stopping Criterion

Dr. Muhammad Majid Gulzar (CIE-KFUPM)


Solution Technique (Example):
Use Liebmann’s method (Gauss-Seidel) to solve for the temperature of the heated plate for the given
figure. Employ overrelaxation with a value of 1.5 for the weighting factor and iterate to 𝜀𝜀𝑠𝑠 = 1%.

Node (1,1)

Node (2,1)

Node (3,1)

Dr. Muhammad Majid Gulzar (CIE-KFUPM)


Solution Technique (Example):

2nd Iteration

9th Iteration

Dr. Muhammad Majid Gulzar (CIE-KFUPM)


Solution Technique:
 Secondary Variables
 Temperature is considered to be the primary variable in the heated-plate problem.

 For this case, as well as for other problems involving PDEs, secondary variables may also be of
interest. As a matter of fact, in certain engineering contexts, the secondary variable may actually be
more important.

 For the heated plate, a secondary variable is the rate of heat flux across the plate’s surface.

Dr. Muhammad Majid Gulzar (CIE-KFUPM)


Solution Technique (Example):
Determine the distribution of heat flux of the heated plate for the given temperature values and
figure. Assume that the plate is 40 × 40 𝑐𝑐𝑐𝑐 and is made out of aluminum 𝑘𝑘 ′ = 0.49 𝑐𝑐𝑐𝑐𝑐𝑐/𝑠𝑠.𝑐𝑐𝑐𝑐.℃ .

Node (1,1)

Dr. Muhammad Majid Gulzar (CIE-KFUPM)


The Heat-Conduction Equation (Sec 30.1)
The Heat-Conduction Equation:
 The heat-conduction equation consider the amount of heat stored in the element over a
unit time period Δ𝑡𝑡.

 Finite-difference solution to Parabolic equation is

Dr. Muhammad Majid Gulzar (CIE-KFUPM)


Explicit Methods (Sec 30.2)
Explicit Methods:
 The heat-conduction equation requires approximations for the 2nd derivative in space and
the 1st derivative in time.

 Laplace equation by a centered finite-divided difference

 Forward finite-divided difference is used to approximate the time derivative

This equation provides an explicit means to compute values at each node for a future
time based on the present values at the node and its neighbors.
Dr. Muhammad Majid Gulzar (CIE-KFUPM)
Explicit Methods (Example):
Use the explicit method to solve for the temperature distribution of a long, thin rod with a length of
10 𝑐𝑐𝑐𝑐 and the given values: 𝑘𝑘 ′ = 0.49 𝑐𝑐𝑐𝑐𝑐𝑐/(𝑠𝑠. 𝑐𝑐𝑐𝑐. °𝐶𝐶), ∆𝑥𝑥 = 2 𝑐𝑐𝑐𝑐 and ∆𝑡𝑡 = 0.1 𝑠𝑠. At 𝑡𝑡 = 0, the
temperature of the rod is zero and the boundary conditions are fixed for all times at 𝑇𝑇 0 = 100℃
and 𝑇𝑇 10 = 50℃. Note that the rod is aluminum with 𝐶𝐶 = 0.2174 𝑐𝑐𝑐𝑐𝑐𝑐/(𝑔𝑔. ℃) and 𝜌𝜌 = 2.7 𝑔𝑔/𝑐𝑐𝑐𝑐3 .
Therefore, 𝑘𝑘 = 0.49/(2.7 × 0.2174) = 0.835 𝑐𝑐𝑐𝑐2 /𝑠𝑠 and 𝜆𝜆 = 0.835(0.1)/(2)2 = 0.020875.

𝑡𝑡 = 0.1 𝑠𝑠

𝑡𝑡 = 0.2 𝑠𝑠

Dr. Muhammad Majid Gulzar (CIE-KFUPM)


Explicit Methods (Class Activity):
Use the explicit method to solve for the temperature distribution of a long, thin rod with a length of
10 𝑐𝑐𝑐𝑐 and the given values: 𝑘𝑘 ′ = 0.49 𝑐𝑐𝑐𝑐𝑐𝑐/(𝑠𝑠. 𝑐𝑐𝑐𝑐. °𝐶𝐶), ∆𝑥𝑥 = 2 𝑐𝑐𝑐𝑐 and ∆𝑡𝑡 = 0.1 𝑠𝑠. The rod is
initially at 50℃ and the derivative at 𝑥𝑥 = 0 is equal to 1 and at 𝑥𝑥 = 10 is equal to 0. Note that the
rod is aluminum with 𝐶𝐶 = 0.2174 𝑐𝑐𝑐𝑐𝑐𝑐/(𝑔𝑔. ℃) and 𝜌𝜌 = 2.7 𝑔𝑔/𝑐𝑐𝑐𝑐3 . Therefore, 𝑘𝑘 = 0.49/(2.7
× 0.2174) = 0.835 𝑐𝑐𝑐𝑐2 /𝑠𝑠 and 𝜆𝜆 = 0.835(0.1)/(2)2 = 0.020875.

"0" Node

This introduces an exterior node at 𝑖𝑖 = −1. The derivative boundary condition can be used to eliminate this node

Dr. Muhammad Majid Gulzar (CIE-KFUPM)


Explicit Methods (Class Activity):

𝑛𝑛𝑡𝑡𝑡 Node

Dr. Muhammad Majid Gulzar (CIE-KFUPM)


Explicit Methods (Class Activity):

Dr. Muhammad Majid Gulzar (CIE-KFUPM)


A Simple Implicit Method (Sec 30.3)
A Simple Implicit Method:
 In explicit method, we approximate the spatial derivative at time level 𝑙𝑙

 In implicit method, the spatial derivative is approximated at an advanced time level 𝑙𝑙 + 1

𝑖𝑖 = 0

𝑖𝑖 = 𝑚𝑚
Dr. Muhammad Majid Gulzar (CIE-KFUPM)
A Simple Implicit Method (Example):
Use the simple implicit finite-difference approximation to solve for the temperature distribution of a
long, thin rod with a length of 10 𝑐𝑐𝑐𝑐 and the given values: 𝑘𝑘 ′ = 0.49 𝑐𝑐𝑐𝑐𝑐𝑐/(𝑠𝑠. 𝑐𝑐𝑐𝑐. °𝐶𝐶), ∆𝑥𝑥 = 2 𝑐𝑐𝑐𝑐
and ∆𝑡𝑡 = 0.1 𝑠𝑠. At 𝑡𝑡 = 0, the temperature of the rod is zero and the boundary conditions are fixed
for all times at 𝑇𝑇 0 = 100℃ and 𝑇𝑇 10 = 50℃ . Note that the rod is aluminum with 𝐶𝐶
= 0.2174 𝑐𝑐𝑐𝑐𝑐𝑐/(𝑔𝑔. ℃) and 𝜌𝜌 = 2.7 𝑔𝑔/𝑐𝑐𝑐𝑐3 . Therefore, 𝑘𝑘 = 0.49/(2.7 × 0.2174) = 0.835 𝑐𝑐𝑐𝑐2 /𝑠𝑠
and 𝜆𝜆 = 0.835(0.1)/(2)2 = 0.020875.

𝑡𝑡 = 0.1 𝑡𝑡 = 0.2

Dr. Muhammad Majid Gulzar (CIE-KFUPM)


Improvements of Euler’s Method (Class Activity):
 Comparison

Dr. Muhammad Majid Gulzar (CIE-KFUPM)

You might also like