You are on page 1of 7

ADVANCED COMPUTATIONAL FLUID

DYNAMICS

Document Identifier : Solving example 4.3 on page 125[1]


Student : Huynh Van Tinh
Student Number : 20205079
School of : Mechanical and Automotive Engineering
Description : HW#3
Date (dd / mm / yyyy) : 01 / 04 / 2020

“Change your thoughts and you change your


world ”
- Norman Vincent Peale
ADVANCED COMPUTATIONAL FLUID DYNAMICS - HW#3

THE FINITE VOLUME METHOD FOR DIFFUSION PROBLEMS

A cylindrical fin with uniform crosssectional area A. The base is at a


temperature of 100°C (TB) and the end is insulated. The fin is exposed to an
ambient temperature of 20°C. Data: L = 1m, hP/(kA) = 25/m 2 (note that kA is
constant).
Insulated (zero heat flux
across this boundary)
TB

Tambient

Figure 1. The geometry for a cylindrical fin


1. Write the governing equation
One-dimensional heat transfer in this situation is governed by:

d  dT 
 kA  hP  T  T   0
dx  dx  (1)
where: h: the convective heat transfer coefficient
P: the perimeter
k: the thermal conductivity of the material
T∞: the ambient temperature
2. Set up grid (node) with 5 points and generate control volume

TB = 1000C 1 2 3 4 5 q=0

δx/2 δx δx δx/2

W w P e E

Figure 2. The grid used


3. Discretize the governing equation
The governing equation (1) can be written as:

d  dT  2
 n  T  T   0
dx  dx  (2)

© hvtinh97@gmail.com 1
ADVANCED COMPUTATIONAL FLUID DYNAMICS - HW#3

kA = constant, and n  (hP) / (kA)


2
where:
Integration of the above equation over a control volume gives

d  dT 
 dx  dx dV   n2  T  T  dV  0
V
V

 dT   dT  
  A A   n  TP  T  A x   0
2
 
 dx e  dx  w  (3)

4. Calculate the coefficients of algebraic equations and set up matrix form


Interior nodal points 2,3 and 4
Equation (3) become:

 TE  TP   TP  TW  
  x     x    n  TP  T   x   0
2

   
 1 1   1   1 
   TP    TW    TE  n2 xT  n2 xTP
x x  x  x  (4)

Using general form, we have: aPTP  a W TW  aETE  Su

Where:

aW aE aP SP Su
1/δx 1/δx aW + aE - SP -n2δx n2δxT∞
5 5 5 + 5 + 5 = 15 -5 5 . 20 = 100

Hence: 15T2 = 5T1 + 5T3 + 100


15T3 = 5T2 + 5T4 + 100 (*)
15T4 = 5T3 + 5T5 + 100
Boundary node 1
Equation (3) become:

 TE  TP   TP  TB  
  x     x / 2    n  TP  T   x   0
2

   
 1 2   1  2T
   n2 x  TP    TE  n2 xT  B
x x  x  x (5)

Using general form, we have: aPTP  a W TW  aETE  Su

© hvtinh97@gmail.com 2
ADVANCED COMPUTATIONAL FLUID DYNAMICS - HW#3

Where:

aW aE aP SP Su
2 2
0 1/δx aW + aE - SP - n δx - (2/δx) n δxT∞ + (2TB/ δx)
0 5 0 + 5 + 15 = 20 - 5 - 10 = -15 5 . 20 + 10.100 = 1100

Hence: 20T1 = 5T2 + 1100 (**)


Boundary node 5
Equation (3) become:

  TP  TW  
0    x    n  TP  T   x   0
2

  
 1   1 
  n2 x  TP    TW  n2 xT
x  x  (6)

Using general form, we have: aPTP  a W TW  aETE  Su

Where:

aW aE aP SP Su
2 2
1/δx 0 aW + aE - SP - n δx n δxT∞
5 0 5 + 0 + 5 = 10 -5 5 . 20 = 100
Hence: 10T5 = 5T4 + 100 (***)
From (*), (**) and (***):

  5T1  15T2  5T3  100



  5T2  15T3  5T4  100

  5T3  15T4  5T5  100
20T  5T  1100
 1 2

  5T4  10T5  100

The matrix form of the equation set is

 5 15  5 0 0   T1   100 
 0  5 15  5  
 0   T2   100 
 
 0 0  5 15  5  T3    100 
     
 20  5 0 0 0   T4  1100 
 0 0 0  5 10   T5   100 

5. Solve the matrix equation and get the solutions

© hvtinh97@gmail.com 3
ADVANCED COMPUTATIONAL FLUID DYNAMICS - HW#3

The resulting matrix equation can be solved with MATLAB software. Input
with this code:

Figure 3. Code for solving the matrix


The solution to the above system is

Figure 4. The solution


The solution matrix form is

 T1   64.23 
  36.91 
 T2   
 T3   26.50 
   
 T4   22.60 
T   21.30 
 5
Comparison the finite volume solution with analytical expression. The
maximum percentage error is around 6%. The analytical solution given by

T  T cosh n  L  x  

TB  T cosh(nL) (7)

Table 1
Nod Finite volume Analytical
Distance Percentage error
e solution solution
1 0.1 64.23 68.52 6.27
2 0.3 36.91 37.86 2.51
3 0.5 26.50 26.61 0.41
4 0.7 22.60 22.53 -0.31
5 0.9 21.30 21.21 -0.42

© hvtinh97@gmail.com 4
ADVANCED COMPUTATIONAL FLUID DYNAMICS - HW#3

6. Plot the solution


By MATLAB software, we can show the solution on line graph.

Figure 5. Plot the solution

© hvtinh97@gmail.com 5
ADVANCED COMPUTATIONAL FLUID DYNAMICS - HW#3

BIBLIOGRAPHY
[1] H K Versteeg and W Malalasekera, 2007. An Introduction to Computational
Fluid Dynamics (The Finite Volume Method). Second Edition. Pearson Education
Limited.

© hvtinh97@gmail.com 6

You might also like