Computational Modelling of Steady Diffusion Process: Prof. Nilanjan Chakraborty E-Mail
Computational Modelling of Steady Diffusion Process: Prof. Nilanjan Chakraborty E-Mail
Chapter 1
Computational modelling of
steady diffusion process
Lecture 1: Solving 2D Steady Heat Conduction Equation
Qx = kA
x
T
q x = k
x
or
q = kT = k grad (T )
where
SI Units:
T = grad (T ) =
k W/m.K
T T T
k
i+
j+
x
y
z
qx and q W/m2
2
.
Qx Watt
E st = Q x + Q y + Q z (Q x + dQ x ) (Q y + dQ y ) (Q z + dQ z ) + E g
T
= qxyz
Qx = (yz )q x = k (yz )
x
Q x + dQ x = (yz )(q x + dq x )
q x + dq x = q x + x
q x
= qx +
x
x
Q y = (xz )q y = k (xz )
y
Qz = (xy )q z = k (xy )
z
Est = C (xyz )
t
E = qxyz
g
E st = Q x + Q y + Q z (Q x + dQ x ) (Q y + dQ y ) (Q z + dQ z ) + E g
E = q yz + q xz + q xy
st
q x q y q z
T
C
=
+ q
z
t
x
y
According to Fouriers law of heat conduction
T
q x = k
x
T
q y = k
y
T
q z = k
z
T
T T T
+ k
+ q
C
+ k
= k
t x x y y z z
7
Generalised conduction
equation in Cartesian
co-ordinates.
T T T T
+ k
+ q
C
= k
+ k
t x x y y z z
In vector notation the same equation is given by:
T
C
= .(kT ) + q
t
or
T
C
= div(k grad (T )) + q
t
2T 2T 2T
T
= k 2 +
+
+ q
C
2
2
y
z
t
x
The above equation can be rewritten as:
2T 2T 2T q
1 T
+
+
+
=
2
2
2
x
y
z
k t
where
Thermal diffusivity
8
k
C
2T 2T 2T q
1 T
+
+ =
2 +
2
2
y
z k t
x
For steady state
T
=0
t
For 2D problem
T
=0
z
2T 2T q
+ =0
2 +
2
y k
x
or
q
T + =0
k
2
2 (_) 2 (_)
(_) =
+
2
y 2
x
2
Laplace operator
2T
2T
q
+
=
2
2
y
k
x
2T =
or
q
k
2T
2T
+
=0
2
2
x
y
2T = 0
or
S
Tw
Tp
TE
Tp
TN
TS
11
T
1 2T
1 3T
2
3
4
x +
T ( x + x ) = T ( x ) +
x
x
O
x
(
)
(
)
(
)
2
3
x x
6 x x
2 x x
T ( x x ) = T ( x )
(1)
T
1 T
1T
2
3
4
x +
x
x
O
x
(
)
(
)
(
)
2
3
x x
2 x x
6 x x
2
(2)
P
x
T ( x + x ) = TE
T ( x x ) = TW
T ( x ) = TP
2T
x 2
=
x
T ( x + x ) + T ( x x ) 2T ( x )
2
+
O
(
x
)
2
( x )
2T
x 2
=
P
TE + TW 2TP
2
+
O
x
(
)
2
( x )
13
T
T ( y + y ) = T ( y ) +
y
1 2T
y +
2
2
y
1 3T
( y ) +
3
6
y
T
T ( y y ) = T ( y )
y
1 2T
y +
2
2
y
y
1 3T
( y )
3
6
y
y
( y ) 3 + O ( y 4 )
T ( y + y ) = TN
T ( y y ) = TS
T ( y ) = TP
2T
y 2
=
y
T ( y + y ) + T ( y y ) 2T ( y )
2
+
O
y
(
)
2
( y )
2T
y 2
=
P
(3)
(4)
N
y
( y ) 3 + O ( y 4 )
TN + TS 2TP
2
+
O
y
(
)
2
( y )
14
2T
x 2
T + TW 2TP
2
= E
+
O
(
x
)
2
( x )
Truncation error
2T
y 2
T + TS 2TP
2
= N
+
O
y
(
)
2
( y )
Discretised form of
2T
2T
q
+
=
2
y 2
k
x
Truncation error
TE + TW 2TP TN + TS 2TP
q
2
2
+
+ O ( x ) + O ( y ) =
2
2
( x )
( y )
k
TE + TW 2TP TN + TS 2TP
q
=
+
For small values of x and y:
k
( x ) 2
( y ) 2
For x = y = :
q 2
TE + TW + TN + TS 4TP + = 0
k
15
q 2
TE + TW + TN + TS 4TP + = 0
k
P
y
4TP = TE + TW + TN + TS +
q 2
a PT p = anbTnb + b
a PTP = a E TE + aW TW + a N TN + aS TS + b
q
a P = 4, a E = 1, aW = 1, a N = 1, aS = 1 and b = 2
k
16
Discretised form of
2T
2T
+
=0
2
2
y
x
W
TE + TW 2TP TN + TS 2TP
+
=0
2
2
( x )
( y )
P
y
For x = y = :
S
TE + TW + TN + TS 4TP = 0
The above discretised equation can be written as:
a PT p = anbTnb + b
where
a P = 4, a E = 1, aW = 1, a N = 1, aS = 1 and
17
b=0
a PT p = anbTnb + b
W
Rules
1. The discretisation coefficients aP, aE, aW ,
aN, aS have to be positive or zero.
a P a E + aW + a N + aS
or a P anb
Explanation:
1. If temperature increases in the neighbouring nodes, temperature will
increase in node P.
2. The second criterion satisfies isothermal condition. The inequality holds
when there is a source term which depends on temperature.
18
T
1 2T
2
3
x +
T ( x + x) = T ( x) +
x
O
x
(
)
(
)
2
x x
2 x x
T
x
T
x
T ( x + x) T ( x)
+ O ( x)
x
TE TP
+ O ( x)
x
T
q = k
x
T TP
q = k E
+ O ( x)
x
19
T TE
q = k P
T
P
T
T ( y y ) = T ( y )
y
T
y
T
y
T ( y ) T ( y y )
+ O ( y )
y
TP TS
+ O ( y )
y
1 2T
2
3
y +
y
O
y
(
)
(
)
2
2 y x
y
T
k
y
= h(TP T )
P
+ O ( y )
P
TS TP
(
)
h
T
T
k
=
For small y the boundary condition is given by:
P
y
h(TP T ) = k
T
y
T TS
= k P
y
20
-20 oC
Discretised form
T1
T2
T3
T4
T5
T6
x= 0.05m
T1 = 50
T1 2T2 + T3 = 0
T2 2T3 + T4 = 0
T3 2T4 + T5 = 0
T4 2T5 + T6 = 0
T6 = 20
1 0 0
1 -2 1
0 1 -2
0 0 1
0 0 0
0 0 0
0 0 0
0 0 0
1 0 0
-2 1 0
1 -2 1
0 01
Tri-diagonal matrix
21
T1
T2
T3
T4
T5
T6
50
0
= 0
0
0
-20
0
0
d iTi + eiTi +1 = f i
(i)
(ii)
d i 1Ti 1 + ei 1Ti = f i 1
Ti 1 = ( f i ei 1Ti ) / d i 1
(iii)
f i 1 ei 1Ti
li
d i 1
e
f
ai li i 1 Ti + uiTi +1 = bi li i 1
d i 1
d i 1
+ aiTi + uiTi +1 = bi
ei 1
;
d i = ai li
d i 1
ei = ui
f i 1
f i = bi li
d i 1
22
-20 oC
Discretised form
T1
T2
T3
T4
T5
T6
Analytical solution
T ( x) = 280 x + 50
x= 0.05m
T1 = 50
T1
T1 2T2 + T3 = 0
T2
T2 2T3 + T4 = 0
T3
T3 2T4 + T5 = 0
T4
T4 2T5 + T6 = 0
T5
T6 = 20
T6
50
36
= 22
8
-6
-20
T1
T2
T3
T4
T5
T6
50
36
22
= 8
-6
-20
The numerical scheme is second order accurate and the actual profile is linear so the
numerical scheme here gives exact solution because there is no error due to truncation of
higher order terms.
23
0
1
0
0
100
100
100
100
100
For point 1:
T2 + 100 + 0 + T4 4T1 = 0
0
For point 4:
For point 2:
For point 3:
T3 + T1 + 0 + T5 4T2 = 0
For point 5:
For point 6:
T6 + T4 + T2 + 100 4T5 = 0
0 + T5 + T3 + 100 4T6 = 0
100
100
0
1
0
0
T2 + 100 + 0 + T4 4T1 = 0
T3 + T1 + 0 + T5 4T2 = 0
0 + T2 + 0 + T6 4T3 = 0
100
100
100
0 + T5 + T3 + 100 4T6 = 0
One can solve the above set of equations by calculator. However we have 6
equations but in the actual problem we might have 1000 equations. As direct
Matrix inversion is a computationally expensive process the system of
equation is solved by iterative numerical methods. One such method is
Gauss Seidel Iteration scheme.
25
a PT p = anbTnb + b
It is necessary to make sure that coefficients aP, aE, aW , aN, aS follow
the Golden rules of discretisation.
2. Make an initial guess about the unknowns.
3. Recast the equation in the following manner:
Tp =
k
a
a
a
b
a
(k )
(k )
( k 1)
( k 1)
+ W TW
+ N TN + E TE
+ S TS
aP
aP
aP
aP
aP
where k and k -1 are iteration counts and are not exponents. For initial
guess k = 0.
4. Check whether a prescribed convergence criterion is satisfied:
TP
(k )
TP
( k 1)
<
is a small number
0
1
100
0
0
4T1 = T2 + 100 + T4
4T2 = T3 + T1 + T5
4T3 = T2 + T6
100
100
100
100
4T4 = T5 + T1 + 200
4T5 = T6 + T4 + T2 + 100
100
4T6 = T5 + T3 + 100
(0)
T1
(1)
T2
(1)
= 60, T2
= (T2
(0)
(0)
= (T3
(0)
= 50, T3
+ 100 + T4
+ T1
(1)
= 50, T4
(0)
(0)
+ T5
(0)
= 80, T5
(0)
= 70 and T6
(0)
= 50
(0)
The process is repeated till T6 using most recent values. When improved values of T1 to
T6 are obtained the whole process is repeated until convergence
27
1st iteration
2nd iteration
3rd iteration
4th iteration
T1 = 60
57.5
56.6
54.7
54.0
T2 = 50
44.4
37.3
35.7
35.1
T3 = 50
23.6
21.4
20.7
20.4
T4 = 80
T5 = 70
T6 = 50
81.9
81.4
80.4
80.0
69.0
66.7
65.8
65.4
48.2
47.0
46.6
46.5
x / 2
Q
N
y / 2
W
P
q
Q
W
TE + TW + TN + TS 4TP +
29
q 2
=0
k
Q
E
Q
S
For x = y = :
Q
W
Q
N
Q
E
= h( x.1)(T T )
Q
N
y / 2
= k TS TP ( x.1)
Q
S
y
Q
S
= k TE TP y .1
Q
E
x 2
S
x / 2
= k TW TP y .1
Q
W
x 2
For x = y = :
(TE + TW + 2TS ) + 2
h
h
q 2
T 4 + 2
TP + = 0
k
k
k
30
Q
W
Q
N
Q
E
h
Q
S
= h x .1(T T )
Q
N
P
2
= k TS TP x .1
Q
S
y 2
= h y .1(T T )
Q
E
P
2
y / 2
y
= k TW TP y .1
Q
W
x 2
x / 2
From energy balance method:
+Q
+Q
+Q
+ q xy .1 = 0
Q
N
S
E
W
For x = y = :
h
h
q 2
=0
T +
(TW + TS ) 2 + 2
TP + 2
k
k
2k
31
N
Q
N
W QW
T h
Q
E
Q
S
= h x .1(T T ) + k x .1 TN TP
Q
N
P
2 y
2
= h y .1(T T ) + k y .1 TE TP
Q
E
P
2 x
2
= k TW TP ( y.1)
Q
W
x
= k TS TP ( x.1)
Q
S
y
y / 2
S
x / 2
From energy balance method:
+Q
+Q
+Q
+ q 3xy .1 = 0
Q
N
S
E
W
For x = y = :
3q 2
h
h
32
EXAMPLE
The cross-section of a water-cooled component is illustrated below. The wall is
symmetrical about AB. The faces AF and EF are maintained at 200o C whilst face ED is
well insulated. For faces BC and CD, which are exposed to water at 20o C, the convective
heat transfer coefficient is 500 W/m2K. As shown in the figure a 10 mm square mesh of
nodal points is employed in a finite difference analysis of the two-dimensional, steadystate, temperature distribution. The thermal conductivity of the material is 0.25 W/mK.
(a) Derive discretised equations for nodes 1 to 7 based on energy balance method.
(b) Determine the temperatures at nodes 1 to 7.
(c) Calculate the rate of convective heat transfer from the component per metre depth into
the page.
200o C
F
1
200o C
4
6
2
5
3
C
20mm
h = 500 W/m2K
T= 20oC
10mm
7
30mm
30mm
D
33
Epilogue
You will need to understand this part to understand the rest of the
module. Please devote time on this material.
And