AIAA 99-0934: A Second Law Based Unstructured Finite Volume Procedure For Generalized Flow Simulation

You might also like

Download as doc, pdf, or txt
Download as doc, pdf, or txt
You are on page 1of 24

AIAA 99-0934

A Second Law Based Unstructured Finite Volume


Procedure for Generalized Flow Simulation
A. Majumdar
Sverdrup Technology, Inc.
Huntsville, AL

37th AIAA Aerospace Sciences Meeting


Conference and Exhibit
January 11-14, 1999
Reno, NV

For permission to copy or republish, contact the American Institute of Aeronautics and Aeronautics
1801 Alexander Bell Drive, Suite 500, Reston, Virginia 20191-4344
A Second Law Based Unstructured Finite Volume Procedure for
Generalized Flow Simulation

Alok Majumdar
Sverdrup Technology
Huntsville, Alabama

ABSTRACT
An unstructured finite volume procedure has been developed for steady and transient thermo-fluid
dynamic analysis of fluid systems and components. The procedure is applicable for a flow network
consisting of pipes and various fittings where flow is assumed to be one dimensional. It can also be used
to simulate flow in a component by modeling a multi-dimensional flow using the same numerical scheme.
The flow domain is discretized into a number of interconnected control volumes located arbitrarily in
space. The conservation equations for each control volume account for the transport of mass, momentum
and entropy from the neighboring control volumes. In addition, they also include the sources of each
conserved variable and time dependant terms. The source term of the entropy equation contains entropy
generation due to heat transfer and fluid friction. Thermodynamic properties are computed from the
equation of state of a real fluid. The system of equations is solved by a hybrid numerical method, which
is a combination of simultaneous Newton-Raphson and successive substitution schemes. The paper also
describes the application and verification of the procedure by comparing its predictions with the
analytical and numerical solution of several benchmark problems.

1
NOMENCLATURE r Radius (ft)
S Momentum Source(lb f )
A Area (ft2) .

A Pump Characteristic Curve Coefficient S gen


Entropy generation rate (Btu/R-sec)
B Pump Characteristic Curve Coefficient s Entropy (Btu/lbm - R)
D Diameter (ft) T Temperature (R)
f Darcy Friction Factor u Longitudinal Velocity (ft/sec)
g Gravitational Acceleration (ft/sec 2 ) v Transverse Velocity (ft/sec)
gc Conversion Constant (=32.174 lbm-ft/lbf V Volume (ft3 )
-sec2 ) x Coordinate Direction
J Mechanical Equivalent of Heat (778 ft-lb f y Coordinate Direction
/Btu) z Compressibility Factor
Kf Flow Resistance Coefficient (lb f -sec2 /lbm2 Greek
-ft2) r Density (lbm/ft3 )
K Non-dimensional Rotating Flow Resistance q Angle Between Branch Flow Velocity Vector
Coefficient and Gravity Vector (deg),
L Length (ft) qn Angle Between Neighboring Branches
M Molecular Weight for
m Resident Mass (lbm) Computing Shear (deg)
.
w Angular Velocity (rad/sec)
m Mass Flow Rate (lbm/sec) e Absolute Roughness (in)
p Pressure (lbf / ft2 )
Q Heat Source (Btu/sec) e/D Relative Roughness
Re Reynolds Number m Viscosity (lb/ft-sec)
(Re =  uD /  ) g Specific Heat Ratio
R Gas Constant (lbf -ft/lbm-R) Dt Time Step (sec)
q Time (sec)
___________________________________________________________________
Copyright © American Institute of Aeronautics & Astronautics, Inc., 1997. All rights reserved
INTRODUCTION Since the publication of the original paper in
1972, there have been several developments
A numerical procedure capable of modeling reported to improve the numerical
fluid flow for both systems and components is performance of the original algorithm.
of significant importance in aerospace and Several general purpose computer programs
many other engineering industries. Although that have been developed based on these
separate numerical methods are available for procedures are increasingly being used for
performing system and component analysis, component analysis.
there are not many attempts to develop an
unified procedure applicable to both systems However, very few applications of the finite
and components. Hardy Cross1 developed a volume method have been reported for system
numerical method for calculating flow and analysis. Datta and Majumdar 3 used this
pressure distribution in a flow network. This solution algorithm to develop a calculation
method has been widely used in modeling water procedure for manifold flow systems.
distribution systems in municipalities. The However, this procedure cannot be used for
Hardy Cross method assumes an equilibrium simulating a flow network due to its
between pressure and friction forces in steady dependence on a structured co-ordinate
and incompressible flow. As a result it has not system. The purpose of this paper is to
been successfully used in unsteady and present a finite volume procedure based on an
compressible flow calculations where inertia unstructured co-ordinate system that can be
force is important. applied to analyze both systems and
components.
Patankar and Spalding 2 developed a finite
volume procedure to solve for Navier-Stokes MATHEMATICAL FORMULATION
equations in a structured co-ordinate system.
All finite volume procedures require solution are solved at all branches. This process of
of mass, momentum and energy conservation discretization allows the development of the
equations in a flow domain consisting of set of conservation equations in an
interconnected control volumes. For unstructured co-ordinate system. A schematic
turbulent flows, additional conservation of a typical flow network is shown in Figure
equations of turbulence parameters are solved 1.
to calculate enhanced momentum exchanges
due to turbulence. For reactive flows, specie Viscous Effect
conservation equations are solved in In conventional finite volume procedure,
conjunction with other conservation viscous effects are modeled by shear stress,
equations. The main characteristic features of which is expressed as a product of effective
the present method are the following: viscosity and local velocity gradient. In order
to calculate the velocity gradient accurately,
Unstructured Co-ordinate System the finite volume procedure requires a large
A flow domain is resolved into a network number of control volumes. It is not practical
consisting of nodes and branches. The nodes to use such a large mesh for a system level
are connected by branches. The nodes are calculation. Therefore in this method, the
classified into two categories: boundary and frictional effect is modeled in the momentum
internal nodes. At a boundary node, pressure equation by the following expression:
and temperature are known; at an internal . 2
node they are computed by solving p friction  K f m (1)
conservation equations. Each internal node where K f is a function of Reynolds
can be connected with an arbitrary number of
number, density, area and geometry of the
internal and boundary nodes. At each node
branch in consideration. However for multi-
mass and entropy conservation equations are
dimensional
solved in conjunction with the equation of
state. The momentum conservation equations

Notes:
Atmosphere
1) Number of Internal Nodes = 7 16
14.7 psia
2) Number of Branches = 12
3) Total Number of Equations = 7 x 4 + 12 = 40
4) Number of Equations Solved by Newton
25
Raphson Method = 7 + 12 = 19
5) Number of Equations Solved by Successive
Substitution Method = 3 x 7 = 21
47

Helium
151 psia 87 86
o
70 F
Atmosphere
14.7 psia 66 46

50
Legend
137 88
XX Branch

X Boundary Node 142


X Internal Node
67 63
Assumed Branch Flow Direction
49
Hydrogen
138 129
172 psia
58 25 o
Oxygen -174 F
550 psia
o
-60 F 48 68 60 23 23 22
Figure 1 - Schematic of a Flow System Consisting of Nodes and Branches

flows, viscous effects are modeled by


conventional shear stress method. Node
j=2
Thermodynamic Formulation
Entropy is calculated at every internal node
using a second law analysis 4 of the control
.
volume. The temperatures are then calculated mij
from pressure and entropy, and densities are
calculated from a modified virial equation of
state5. During each iteration cycle, thermo-
dynamic properties are calculated to ensure Node . Node . Node
mji mij
thermodynamic equilibrium prevails during j=1 i j=3
the course of attaining the solution.

Solution Scheme . . .
The system of equations is solved by a hybrid mji mij = - mji
numerical scheme, which is a combination of
the Newton-Raphson and successive sub-
stitution schemes. The equations which are
strongly coupled are solved by the Newton- Node
Raphson method. The equations which are k=2 j=4
weakly coupled are solved by the successive Figure 2- Schematic of Nodes, Branches and
substitution scheme. The successive sub- Indexing Practice
stitution scheme is also used to develop an
initial guess for the Newton-Raphson scheme Momentum Conservation Equation
to ensure numerical stability.
The flow rate in a branch is calculated from
GOVERNING EQUATIONS the momentum conservation equation
(Equation 3) which represents the balance of
Figure 2 displays a schematic showing fluid forces acting on a given branch. A
adjacent nodes, their connecting branches, typical branch configuration is shown in
and the indexing system used in this paper. Figure 3. Inertia, pressure, gravity, friction
In order to solve for the unknown variables, and centrifugal forces are considered in the
mass and entropy conservation equations and conservation equation. In addition to these
the equation of thermodynamic state are five forces, a source term S has been provided
written for each internal node and flow rate to represent any external momentum sources.
equations are written for each branch. For example, this external momentum source
term can be used to model a pump in a flow
Mass Conservation Equation system.

The two terms in the left hand side of the


m    m j  n . momentum equation represent the inertia of
  m ij (2)
 j1
the fluid. The first one is the time dependent
term and must be considered for unsteady
Equation 2 requires that, for the transient calculations. The second term is significant
formulation, the net mass flow from a given when there is a large change in area or
node must equate to the rate of change of mass density from branch to branch. The first term
in the control volume. In the steady state in the right hand side of the momentum
formulation, the left hand side of the equation is equation represents the pressure gradient in
zero. This implies that the total mass flow rate the branch. The pressures are located at the
into a node is equal to the total mass flow rate upstream and downstream face of a branch.
out of the node.
The second term represents the effect of
gravity. The gravity vector makes an angle
(q) with the assumed flow direction vector.
The third term represents the frictional effect.
Friction was modeled as a product of K f, the
area, and the square of the flow rate. K f is a
function of the fluid density in the branch and
the nature of the flow passage being modeled
by the branch. The calculation of Kf for
different types of flow passages is described
later in this paper. The fourth term in the
momentum equation represents the effect of
the centrifugal force. This term will be
present only when the branch is rotating as
shown in Figure 3. K rot is the factor
representing the fluid rotation. Krot is unity
when the fluid and the surrounding solid
surface rotate with the same speed. This term
also requires a knowledge of the distances of
the upstream and downstream faces of the
branch from the axis of rotation.

Node
j

Branch

.
mij

Node i
g

 ri rj
Axis of Rotation

Figure 3 - Schematic of a Branch Showing


Gravity and Rotation
.
mu mu mij
  u ij  u u  
gc gc (3)

 gVcos . .  K  A 22
pi pjA g Kfmij mij A 2 g r r  S rot 2 2
j i
c c
 ms      ms 


  . 
j  n j  n  MAX   mij ,0  Q
  .  .       . i
  MAX   mij ,0 s  MAX mij ,0 s      S ij , gen  (4)

j  1   j   i j  1 .  T
mij i
 
 

Entropy Conservation Equation The entropy conservation equation for node i,


shown in Figure 2, can be expressed
mathematically as shown in Equation 4.
the advective transport of entropy from
The entropy generation rate due to fluid fric- neighboring nodes. The second term
tion in a branch is expressed as represents the rate of entropy generation in
branches connected to the i th node. The third
 . 
3 term represents entropy change due to heat
.
mij pij ,viscous K f  mij  transfer.
.   (4a)
S ij , gen  
u Tu J u Tu J Equation of State

Equation 4 shows that for unsteady flow, the A modified virial equation of state is used to
rate of increase of entropy in the control calculate the density from the computed
volume is equal to the rate of entropy pressure and temperature at a given node.
transport into the control volume plus the rate
of entropy generation in all upstream i N j M

branches due to fluid friction plus the rate of


entropy added to the control volume due to
p 
i  1

Ai  T   i

j 
1
B j  T   2 j 1e  c (5)
2

heat transfer. The MAX operator in Equation Ai(T) and Bj(T) are polynomials in T and 1/T
4 reflects the use of an upwind differencing
scheme which has been extensively This equation was originally developed by
employed in the numerical solution of Benedict, Webb and Rubin (BWR) and later
Navier-Stokes equations in convection heat modified by Bender 5 . This equation was the
transfer and fluid flow applications. When basis of the computer code GASP developed
the flow direction is not known, this operator by Hendricks et al 6. This equation enabled
allows the transport of entropy only from its PVT calculations to be made in the liquid and
upstream neighbor. In other words, the vapor phases. The derived properties of
upstream neighbor influences its downstream enthalpy and entropy were also obtained.
neighbor but not vice versa. The first term in The
the right hand side of the equation represents
Table 1 - Mathematical Closure

Unknown Variables Available equations to solve


Pressure Mass Conservation Equation (Eqn. 2)
Flow rate Momentum Conservation Equation (Eqn.3)
Temperature Second Law of Thermodynamics (Eqn. 4)
Density Equation of State (Eqn. 5)
Mass (Unsteady Flow only) Compressibility Factor (Eqn 6)
demonstrate the problem of mathematical
present method uses the GASP computer code closure.
to compute density and other thermophysical
properties during iterative cycles of Multi-Dimensional Flow
computation. Multi-dimensional conservation equations
must account for the transport of mass,
Compressibility Factor momentum and entropy into and out of the
For unsteady flow, resident mass in a control control volume from all directions in space.
volume is calculated from the compressibility The scalar transport equations (i.e., mass and
factor assuming a thermodynamic equilibrium entropy conservation equations) can account
(Equation 6). for such transport because each internal node
can be connected with multiple neighboring
pV nodes located in space in any arbitrary
m (6) location (Figure 2). Equations 2 and 4
RTz
account for the transport of mass and entropy
respectively from all directions in space. On
Table 1 shows how each equation is used to
the other hand, the momentum conservation
calculate the unknown variables to
equation (Equation 3) is one dimensional.
Multi-dimensional momentum transport can Figure 4 represents a set of nodes and
be accounted for by incorporating two branches for which shear forces are
additional terms in the momentum equation. exchanged. Let branch 12 represent the
These terms include: (a) momentum transport branch for which the shear force is to be
due to shear, and (b) momentum transport due calculated. Branches N12 and S12 represent
to the transverse component of velocity. the parallel branches which will be used to
calculate the shear force on branch 12. Let
These two terms can be identified in the two- YS be the distance between branches 12 and
dimensional steady state Navier-Stokes S12, and let YN be the distance between
equation which can be expressed as: branches 12 and N12. Let AS be the shearing
  uu   vu area between branches 12 and S12 while AN
+ = is the shearing area between branches 12 and
x y N12.
(7)
p   2 u  2u 
-  g x    2  2  The shear force on a control volume can be
x  x y 
expressed as
The first term on the left hand side of
 2u u
Equation 7 corresponds to the inertia term in  2 V  
 x   y  z =
Equation 3. The second term on the left hand y  y 2
side of Equation 7 corresponds to the u u
transverse momentum exchange. The first  xz =  A (8)
y y shear
term on the right hand side of Equation 7
corresponds to the pressure term. The second
term on the right hand side of Equation 7 The finite volume formulation for shear for
corresponds to the gravity term. The third the i branch can be written as:
np i


term on the right hand side of the equation is u  u ij cosij - u i 
negligible (based on an order of magnitude  A    Aij 
argument). The fourth term on the right hand y Branch i shear  Yij 
j=1
side corresponds to the friction term in the nsi


one dimensional momentum conservation  u wall ik coswall ik - u i 
equation. For multi-dimensional flow, +  Aik  (9)
 y wall ik 
friction is modeled by shear force as k=1
discussed below. where i is the current branch, np is the
number of parallel branches to branch i, and
Momentum Transport Due to Shear ns is the number of parallel solid walls to
branch i
N12
N1 N2 12
1 2
AN YN

12
1 2 S1 S2
S12
AS YS S1 S2
S12
S1 S2
Figure 5 - Branch and Node Schematic for
Transverse Momentum Exchange
Figure 4 - Branch and Node Schematic for
Shear Exchange
Transverse Momentum Transport
The transverse momentum component of flow rates also appear in the entropy equation.
Equation 7 can be expressed in terms of a The governing equations to be solved are
force per unit volume. strongly coupled and nonlinear and therefore
they must be solved by an iterative method.
vu ( v u) There are two types of numerical methods
V  (  x)(  y)(  z) available to solve a set of non-linear coupled
y (  y)
algebraic equations: (1) the successive
= (  x)(  z)( vu) = m  trans u substitution method and (2) the Newton-
Raphson method. In the successive
(10) substitution method, each equation is
expressed explicitly to calculate one variable.
Figure 5 represents a set of nodes and The previously calculated variable is then
branches for which transverse momentum substituted into the other equations to
exchange will take place. Let branch 12 calculate another variable. In one iterative
represent the current branch which will cycle each equation is visited. The iterative
receive transverse momentum from the cycle is continued until the difference in the
surrounding branches. Branch S12 represents values of the variables in successive iterations
an adjacent parallel branch, while branches becomes negligible. The advantages of the
S1 and S2 represent the adjacent normal successive substitution method are its
branches. simplicity to program and its low code
overhead. The main limitation, however, is
The finite volume formulation for transverse finding an optimum order for visiting each
momentum for the ith branch can be written equation in the model. This visiting order,
as shown in equation 11. which is called the information flow diagram,
is crucial for convergence. Under-relaxation
  n ij
 (partial substitution) of variables is often

  
 1 
 
ui  max -   ijk cos ijk ,0 
m
mi
   n ij
 
  required  to obtain numerical stability.


vu  k =1  
V    (11)
y   n ij



i
  

j=1 
 
- uij cos ij  max 0,
 1
 m In the
 ijk cos ijk 
 Newton-Raphson method, the
 
 n ij 



  k =1 simultaneous
 solution of a set of non-linear
Detailed derivation of equation (9) and (11) equations is achieved through an iterative
appear in GFSSP User’s Manual. 7 guess and correction procedure. Instead of
solving for the variables directly, correction
SOLUTION PROCEDURE equations are constructed for all of the
variables. The intent of the correction
In the sample circuit shown in Figure 1, equations is to eliminate the error in each
pressures and temperatures are to be equation. The correction equations are
calculated for the 7 internal nodes; flow rates constructed in two steps: (1) the residual
are to be calculated in the 12 branches. The errors in all of the equations are estimated and
total number of equations can be evaluated (2) the partial derivatives of all of the
from the following relationship: Number of equations, with respect to each variable, are
equations = Number of internal nodes * calculated. The correction equations are then
Number of scalar transport equations + solved by the Gaussian elimination method.
Number of branches. Therefore, the total These corrections are then applied to each
number of equations to be solved is 40 (= 7 X variable, which completes one iteration cycle.
4 + 12). These iterative cycles of calculations are
repeated until the residual error in all of the
There is no explicit equation for pressure. equations is reduced to a specified limit. The
The pressures are implicitly computed from Newton-Raphson method does not require an
the mass conservation equation (Equation 2). information flow diagram. Therefore, it has
The flow rates are calculated from Equation improved convergence characteristics. The
3. The inertia and friction terms are nonlinear main limitation to the Newton-Raphson
in Equation 3. The pressures and mass flow method is its requirement for a large amount
rates appear in the flow rate equations. The of computer memory.
5. Calculate density and temperature from
The present formulation employs a novel the equation of state for calculated
numerical scheme, SASS (Simultaneous pressure and entropy at each internal
Adjustment with Successive Substitution) node. Viscosity is also computed
which is a combination of the successive from the thermophysical property
substitution and Newton-Raphson methods. correlation for calculated pressure
The mass and momentum conservation and temperature.
equations are solved by the Newton-Raphson 6. Calculate flow resistance parameter (K f)
method. The entropy conservation equations of each branch. Kf is a function of
are solved by the successive substitution density and viscosity.
method. The underlying principle for making 7. Calculate the maximum difference in
such a division was that the equations which values of entropy, density, and flow
are more strongly coupled are solved by the resistance parameters between
Newton-Raphson method. The equations successive iterations. Steps 3 to 7
which are not strongly coupled with the other constitute one iteration cycle.
set of equations are solved by the successive 8. Repeat steps 3 to 7 until the maximum
substitution method. Thus, the computer difference is less than the specified
memory requirement can be significantly convergence criterion. Steps 2 to 8
reduced while maintaining superior numerical constitute all operations required for
convergence characteristics. To improve the one time step.
convergence and stability of the numerical 9. Repeat steps 1 to 8 until final time is
scheme, the successive substitution method is reached.
used to provide an initial guess for pressure
and flow rate. Equations 2 and 3 are
rewritten such that pressures and flow rates
can be estimated at each node and branch.

In a typical unsteady calculation, the SAAS


procedure consists of the following steps:
COMPUTER PROGRAM

1. At the beginning of a new time step, The numerical procedure described in the
provide the initial solution of all previous sections was incorporated into a
dependant variables in the flow general purpose computer program named
domain e.g. pressure, resident mass, Generalized Fluid System Simulation
density and entropy at all internal Program (GFSSP) . The computer program
and boundary nodes, flow rates at all has three major parts. The first part consists
branches. of the subroutines for the preprocessor. The
2. Begin the outer iteration loop; the preprocessor allows the user to interactively
purpose of this loop is to calculate create the flow network model consisting of
entropy and density at all internal nodes and branches. All of the input
nodes and flow resistance in the specification, including the boundary
branches. conditions, are specified through the
3. Solve mass conservation equation preprocessor. The second major part of the
(Equation 2) in internal nodes, program consists of the subroutines that
momentum conservation equation in provide the initial conditions and then
branches (Equation 3) and equation develop and solve all of the conservation
of resident mass in internal nodes equations in the flow network. The third part
(Equation 6) by Newton Raphson of the program consists of the
method (Appendix - A). thermodynamic property programs, GASP
4. Solve entropy conservation equation by and WASP that provide the necessary
successive substitution method thermodynamic and thermophysical property
(Appendix - B). data required to solve the resulting system of
equations.
information necessary for the model. The
Figure 6 shows GFSSP’s process flow solver module reads the input data file and
diagram. The user runs the interactive produces the solution in conjunction with the
preprocessor to generate the input data file. thermodynamic property programs.
The input data file contains all the

Equation Fluid Property


Generator Programs

User

Equation
Solver
Preprocessor Solver and Property Module

Input Output
Data File

Figure 6 - GFSSP Process Flow Diagram

Receiving Reservoir

Pipe
150 ft
o w L = 1500 ft
Fl
Supply Reservoir D = 6 in.
 /D = 0.005
(WRT Gravity Vector) = 95.74


Water
Gravity Vector
Gate
Pump Valve

Figure 7 - Flow system consisting of a pump, valve and pipe line.


Pipe
L = 1500 ft
Pump Gate Valve D = 6 in.
Ao = 30888 K1 = 1000  /D = 0.005
Bo = -8.067E-04 K2 = 0.1 (WRT Gravity Vector) = 95.74

1 12 2 23 3 34 4

Supply Reservoir Pump Outlet Valve Outlet Receiving Reservoir


P = 14.7 psia Valve Inlet Pipe Inlet P = 14.7 psia
T = 60 F T = 60 F

Legend
XX Branch

X Boundary Node

X Internal Node
Figure 8 - Finite volume Model of Flow System Described in Example 1.

RESULTS
Where:
The feasibility, robustness and verification of p = Pressure rise, lbf/ft
the proposed method have been demonstrated .
by simulating five example problems. They m = Flow rate, lbm/sec
are:
The momentum source, S, in Equation 3 was
1. Flow system consisting of pump, valve then expressed as:
and pipe line.
2. Water distribution network. S  p A
3. Compressible flow through a converging-
diverging nozzle. Valve Model
4. Blow down of a pressurized tank. The resistance in branch 23 representing the
5. Recirculating flow in a square cavity. valve was computed by the two-K method of
Hooper8 . For this option, K f of Equation 3
Example 1 - Flow System Consisting of a
Pump, Valve and a Pipe Line was expressed as:
K1 / Re K   1  l / D
A problem commonly encountered in fluid Kf  (13)
2 g c u A 2
engineering is to match a pump’s
characteristics with the operating system’s
characteristics. The designer needs to know Where:
the flow rate in the system and the power K1 = K for the fitting at Re = 1;
consumed by the pump. The system Kµ = for the fitting at Re = µ
considered for this example is shown in D = Internal diameter of attached pipe, in.
Figure 7.
The constants K1 and Kµ for common fittings
The fluid system show in Figure 7 was and valves are listed in reference 8.
simulated with a finite volume model
consisting of four nodes and three branches as
shown in Figure 8.

Pump Model
The pump was modeled as a momentum Pipe Model
source in branch 12. The pump The resistance in branch 34 was computed
characteristics were expressed as: from the friction factor in the pipe line. The
resistance coefficient, K , for a pipe with
 2
D p = A0 + B0 m (12) length, L, diameter D, and surface roughness,
was expressed as:
It took 28 iterations to satisfy the convergence
8fL criterion. The solutions are shown in Tables
Kf  2 and 3. Table 2 show pressures,
u  D 5 g
2 temperatures, compressibility factors and
c density in nodes 2 and 3. It may be noted that
(14) water was treated as a compressible fluid and
the compressibility factor is very low as
Where ru is the density of the fluid at the expected.
upstream node of a given branch.
Table 2 shows Kf , pressure drop, flow rate,
The Darcy friction factor, f, is determined velocity, Reynolds number and Mach number
from the Colebrook Equation 9 which is in each branch. The predicted flow rate is
expressed as: 191 lbm/sec and the pump is supplying 214
1   2.51  psid pressure rise to meet the system
 2 log    (15) requirement. The predicted system and pump
f  3.7 D Re f  characteristics are shown in Figure 8 which
also provides verification of the predicted
Where e/D and Re are the surface roughness operating point shown in Table 3.
factor and Reynolds number respectively.

Table 2. Predicted Solution of Example 1 at Internal Nodes

INTERNAL NODES
NODE P(PSI) T(F) Z RHO EM(LBM) QUALITY
(LBM/FT^3)
2 0.2290E+03 0.6003E+02 0.1186E-01 0.6241E+02 0.0000E+00 0.0000E+00
3 0.2288E+03 0.6003E+02 0.1185E-01 0.6241E+02 0.0000E+00 0.0000E+00

Table 3. Predicted Solution of Example 1 at Branches


BRANCHES
BRANCH KFACTOR DELP FLOW RATE VELOCITY REYN. NO. MACH NO. ENTROPY GEN. LOST WORK
(LBF-S^2/(LBM-FT)^2) (PSI) (LBM/SEC) (FT/SEC) BTU/(R-SEC) LBF-FT/SEC
12 0.000E+00 -0.214E+03 0.191E+03 0.219E+01 0.241E+06 0.183E-02 0.000E+00 0.000E+00
23 0.764E-03 0.193E+00 0.191E+03 0.156E+02 0.644E+06 0.130E-01 0.210E-03 0.848E+02
34 0.591E+00 0.214E+03 0.191E+03 0.156E+02 0.644E+06 0.130E-01 0.162E+00 0.657E+05
Figure 9 - Fluid System Operating Point
300
Example 2 - Water Distribution Network

250 In Example 1 we analyzed a single line pipe


flow problem commonly encountered by
200
pipeline designers. In this example, we
consider an example associated with
multipath
Pressure (psid)

150

100
Pump Characteristics
Fluid System Characteristics

50
systems which are commonly known as flow
network. In general, water supply systems
are considered as flow networks, since nearly
0
0 500 1000 1500 2000 2500 3000 all such systems consist of many
Mass Flow Rate (lbm/s)
interconnecting pipes. A ten pipe
4
8 p
sia 3 4
5 p
sia 4
(commercial steel) distribution system is
shown in Figure 10.
5 6

1 2
5
0 p
sia

7 8

9
4
6ps
ia

Figure 10 - A Schematic of Water


Distribution Network
Table 4 - Water Distribution Network Branch Information

Branch Length (inches) Diameter (inches) Roughness


Factor
12 120 6 0.0018
25 2400 6 0.0018
27 2400 5 0.0018
57 1440 4 0.0018
53 120 5 0.0018
56 2400 4 0.0018
64 120 4 0.0018
68 1440 4 0.0018
78 2400 4 0.0018
89 120 5 0.0018

1.6
1.4 Q - GFSSP Solution (ft^3/sec)
1.2
Q - Hardy Cross Prediction (ft^3/sec)
1
Flowrate (ft^3/sec)

0.8
0.6
0.4
0.2
0
-0.2
-0.4
12 25 27 53 56 57 64 68 78 89
Branch Number

Figure 11 - A Flow Rate Comparison Between GFSSP and Hardy Cross Method Predictions
in this circuit simulate pipes. The length,
The system shown in Figure 10 is modeled by diameter and roughness factor of all branches
using 9 nodes and 10 branches as shown in are given in Table 4.
Figure 10. The fluid was assumed
incompressible. Nodes 1, 3, 4 and 9 are Figure 11 shows a comparison of flow rates
boundary nodes where the pressures are between the present predictions and the Hardy
prescribed. Node 1 represents the inlet Cross method. The comparison appears
boundary node. Nodes 3, 4 and 9 are outlet reasonable considering the fact that the Hardy
boundary nodes. All of the remaining nodes Cross method assumes a constant friction
(2, 5, 6, 7 and 8) are internal nodes where the factor in the branch while the present method
pressures are calculated. All of the branches computed the friction factor for each branch
during every iteration. Therefore, as the becomes choked when the flow velocity
flowrates change the friction factor also equals the local velocity of sound. The
changes. purpose of this example is to investigate how
accurately the present procedure can predict
Example 3 - Compressible Flow in a the choked flow rate in a converging-
Converging-Diverging Nozzle diverging nozzle.

In this example we will consider compressible The converging-diverging nozzle considered


flow in a converging-diverging nozzle to for this example is show in Figure 11. The
demonstrate the method’s capability to handle fluid considered was steam at 150 psia and
compressibility. One of the characteristics of 1000 F. The nozzle back pressure was varied
compressible flow in a duct is that the flow from 134 psia to 15 psia.
rate becomes independent of exit pressure
after reaching a threshold flow rate. This
threshold value is known as the choked flow
rate and it is a function of inlet pressure and
temperature. Flow in a confined duct

0.492 in. Flow 1.453 in.

Not to Scale
0.158 in.
6.142 in.

Figure 11 - Converging-Diverging Steam Nozzle Schematic

The fluid system show in Figure 12 was 134 0.258


simulated by seventeen nodes and sixteen 100 0.301
branches. Nodes 1 and 17 are the boundary 60 0.308
nodes representing the inlet and outlet of the 30 0.308
nozzle. All of the remaining nodes are 15 0.308
internal nodes connected in series. The outlet
boundary node pressures were varied to
The isentropic flow rate at the choked point
include 134, 100, 60, 30 and 15 psia. Table 5
was calculated to be 0.303 lbm/sec from the
lists the model predicted mass flow rates with
following relation:
varying exit pressures. As expected, the mass   + 1
flow rate increased as the exit pressure was  

 
  - 1

decreased until the pressure ratio decreased 2


.
 
gc 
below the critical pressure ratio. At this point m = A (16)

 + 1
and below, the mass flow rate remained throat
Pinlet
constant due to choking of the flow at the R Tinlet
nozzle throat.
Example 4 - Simulation of the Blow Down of
Table 5 - Predicted Mass Flow Rate with a Pressurized Tank
Varying Exit Pressure
In the previous examples we considered the
Pexit . simulation of steady state flow in a given
(psia) m (lbm/s) flow circuit. In this example we will employ
the capabilities of the unsteady flow history of the isentropic blow down process.
formulation to simulate the process of These predicted values will then be compared
blowing down a pressurized tank. with the analytical solution.

Consider a tank with an internal volume of 10 The physical schematic for Example 4 is
ft3 containing nitrogen gas at a pressure and shown in Figure 13(a) and a schematic of the
temperature of 100 psia and 80 F corresponding finite volume model is shown
respectively. The nitrogen is discharged into in Figure 13(b). The venting process can be
the atmosphere through an orifice with a 0.1 modeled with two nodes and one branch.
inch diameter until the pressure in the tank Node 1 is an internal node which represents
drops to 50 psia. The purpose of this example the tank.
is to determine the blow down time and the
pressure, mass flow rate and temperature

Tank
V = 10 ft3
Initial Conditions

pi = 100 psia d = 0.1 in 12


Ti = 80°F
Atmosphere
p = 14.7 psia 1 2
Figure 13- Physical Schematic (a) and GFSSP Model (b) for Venting Nitrogen Tank
Analytical Solution 13. Excellent agreement was observed
The differential equation governing an between twoBlow
solutions.
down of a nitrogen tank from 100 to 50 psia
isentropic blow down process can be written
as: 100

d  p / pi 
(1 3 ) / 2
 p 90 Volume = 10 cubic feet

  = Diameter = 0.1 inch


 pi  d 80

70
(   1) / 2 (  1)
A  2 
 g c pi  i   (17) 60

i V    1
Pressure (psia)

50

This is an initial value problem and the initial 40


conditions are: GFSSP
Isentropic
30
p
 = 0, 1 20
pi
10
The analytical solution for p / p i is given by 0
Moody10 as: 0 20 40 60 80 100 120 140 160

p Time (sec)

pi Figure 13 - Comparison of the Predicted
Pressure History by Finite Volume Method
 2  /(  1)
    1  2 
(  1) / 2 (  1)
 g c p i A  using GFSSP and the Analytical Solution
1      (18)
  2     1 i V 
 Example 5 - Recirculating flow in a Square
Cavity
The analytical and finite volume solutions
obtained by GFSSP are compared in Figure Flow in a square cavity is induced by moving
its top wall at a constant speed as shown in
Figure 15. The density of the fluid is uwall = 100 ft/sec
assumed constant at 1.00 lb m/ft3 , and the
viscosity of the fluid is assumed to be 1.00
lbm/(ft-sec). The bottom and side walls are
fixed. The top wall is moving to the right at a
constant speed of 100 ft/sec. The
corresponding Reynolds number for this
situation is Re = 100.

Due to the complexity of the flow field, an


analytical solution of this situation is not 12 inches
practical. Instead of an analytical solution, a
well known numerical solution by Odus
Burggraf11 was used as the benchmark
solution. Burggraf used a 51x51 grid in his
model of the square cavity.

12 inches

Figure 14 - Flow in a Shear Driven Square


Cavity

Top Wall Top Wall Top Wall Top Wall Top Wall Top Wall

7 714
14 1421
21 2128
28 2835 35 3542 42 4249 49

Side Wall 67 1314 2021 2728 3435 4142 4849 Side Wall

6 613
13 1320
20 2027
27 2734
34 3441
41 4148
48

Side Wall 56 1213 1920 2627 3334 4041 4748 Side Wall

5 512
12 1219
19 1926
26 2633
33 3340
40 4047
47

Side Wall 45 1112 1819 2526 3233 3940 4647 Side Wall

4 411
11 1118
18 1825
25 2532 32 3239
39 3946 46

Side Wall 34 1011 1718 2425 3132 3839 4546 Side Wall

3 310 10 1017 17 1724 24 2431 31 3138 38 3845 45

Side Wall 23 910 1617 2324 3031 3738 4445 Side Wall

2 29
9 916
16 1623 23 2330 30 3037 37 3744 44

Side Wall Side Wall


12 89 1516 2223 2930 3637 4344

1 18 8 815 15 1522 22 2229 29 2936 36 3643 43

Bottom Wall Bottom Wall Bottom Wall Bottom Wall Bottom Wall Bottom Wall

Figure 16 - Finite Volume Model of Flow in a Shear Driven Square Cavity


1
0.9
0.8

Dimensionless Height
0.7
0.6

0.5
0.4

0.3 GFSSP Prediction (7x7 Grid)


0.2
Burggraf's 51x51 Grid Prediction (1966)
0.1
0
-0.4 -0.2 0 0.2 0.4 0.6 0.8 1
Dimensionless Velocity

Figure 17 - Shear Driven Square Cavity Centerline Velocity Distribution

The finite volume model of the driven cavity which considers an one-dimensional
consists of 49 nodes (48 of which are internal) form for system level calculations.
and 84 branches. For numerical stability, one Fluid friction is calculated from the
node (Node 1) was assigned to be a boundary friction factor or loss coefficients.
node with an arbitrary pressure of 100 psi. A For component level analysis, the
unit depth (1 inch) was assumed for the multi-dimensional form of the
required areas. The model is shown momentum equation is used. Fluid
schematically in Figure 16. Modeling details friction is, then, calculated from the
are provided in GFSSP user’s manual. local velocity gradient and viscosity.
In addition, transverse transport of
Figure 16 shows a comparison between the momentum is also computed.
benchmark numerical solution and the finite 4. Thermodynamics and fluid dynamics of
volume predictions along a vertical plane at the flow is linked through entropy
the horizontal midpoint. As can be seen in and pressure. The second law
Figure 17, the results of this coarse grid formulation allows the calculation of
model compare very favorably with the entropy generation through heat and
benchmark numerical solution of Burggraf. fluid flow. All thermodynamic and
thermophysical properties are
CONCLUSIONS computed from local values of
pressure and entropy.
1. The present paper has described a 5. The system of equations is solved by a
generally applicable numerical novel numerical method which is a
method to perform thermo-fluid combination of successive
dynamic analysis of a fluid system or substitution and Newton Raphson
component. Methods. The method has
2. A novel unstructured co-ordinate system demonstrated a remarkable stability
has been used; this allows the for both system and component level
development of mass, momentum analysis.
and entropy conservation equations 6. The method has been incorporated into a
in a complex flow network defined general purpose computer program which
by interconnected nodes and is extensively being used in many
branches. aerospace engineering applications and
3. The method described here uses a the computer program, GFSSP, is
generalized momentum equation available through NASA/Marshall Space
Flight Center’s Technology Transfer Generalized Fluid System Simulation
Center. Program to Model Flow Distribution
in Fluid Networks”, Sverdrup
ACKNOWLEDGEMENT Technology Report No. 331-201-97-
005, Contract No. NAS8040836,
This work was performed under Task No. October, 1997.
371-401 for Contract No. NAS8-40836 with 8. Hooper, W.B., “The Two-K Method
Mr. Henry Stinson of Marshall Space Flight Predicts Head Losses in Pipe
Center as Task Manager. The author would Fittings.”, Chem. Engr., Aug. 24,
like to acknowledge the contribution of Mr. pp.97-100, 1981.
John W. Bailey, Paul Schallhorn and Todd 9. Colebrook, C.F., “Turbulent Flow in
Steadman of Sverdrup Technology in the Pipes, with Particular Reference to
development and testing of GFSSP. The the Transition Between the Smooth
author would also like to acknowledge the and Rough Pipe Laws”, J. Inst. Civil
comments and suggestion of Mr. Tom Engineering, London, vol. 11, pp.
Beasley of Sverdrup Technology during the 133-156, 1938-1939.
course of this work. 10. Moody, F.J., “Introduction to Unsteady
Thermofluid Mechanics”, John
REFERENCES Wiley, 1990.
11. Burggraf, O.R., “Analytical and
1. Hardy Cross, “Analysis of Flow in Numerical Studies of the Structure of
Networks of Conduits or Conductors:, Steady Separated Flows”, Journal of
Univ. Ill. Bull. 286, November 1936. Fluid Mechanics, Vol. 24, part I, pp. 113-
2. Patankar, S.V. and Spalding, D.B., “A 151, 1966.
Calculation Procedure for Heat,
Mass and Momentum Transfer in APPENDIX - A
Three-Dimensional Parabolic
Flows”, Int. J. Heat Mass Transfer, Newton-Raphson Method of Solving
Vol. 15, pp. 1787-1806, 1972. Coupled Nonlinear System of Algebraic
3. Datta, A.B. and Majumdar, A.K., “Flow Equations
Distribution in Parallel and Reverse
Flow Manifolds”, Int. J. Heat & The application of the Newton-Raphson
Fluid Flow, Vol. 2, No. 4, pp. 253- Method involves the following 7 steps:
262, 1980
4. Bejan, A., Entropy Generation Through 1. Develop the governing equations:
Heat and Fluid Flow, New
York,Wiley, 1982. The equations are expressed in the following
5. Bender, E., “Equations of State Exactly form:
Representing the Phase Behavior of
Pure Substances”, Proceedings of the
f 1( x , x 2 , x 3 ,....... x n)  0
1
Fifth Symposium on Thermophysical
Properties, ASME, pp. 227-235, f ( x , x , x ,....... x )  0
2 1 2 3 n (A-1)
1970.
6. Hendricks, R.C., Baron, A.K., and Peller, ........................................
I.C., “GASP - A Computer Code for
Calculating the Thermodynamic and f n ( x , x 2 , x 3 ,....... x n)  0
Transport Properties for Ten Fluids: 1
Parahydrogen, Helium, Neon,
Methane, Nitrogen, Carbon If there are n number of unknown variables,
Monoxide, Oxygen, Fluorine, Argon, there are n number of equations.
and Carbon Dioxide”, NASA TN D-
7808, February, 1975. 2. Guess a solution for the equations.
7. Majumdar, A.K., Bailey, J.W.,
Schallhorn, P., Steadman, T., “A
Guess x1* , x *2 , x *3 ,....... x *n as an initial  f 1  f 1  f 1 f 
 ........ 1   ' 
  x1  x 2  x 3  x n  x 1  R1 
solution for the governing equations
 
 f  f  f  f  x '  R 
3. Calculate the residuals of each equation.
 2 2 2 ........ 2  2  2
 
  x1  x 2  x 3  x n     
......................................     
When the guessed solutions are substituted
   
into Equation A-1, the right hand side of the

 f n   x 'n  R n
equation is not zero. The non-zero value is
 f  f  f
the residual.
 n n n  
........
  x1  x 2  x 3  x n 
f 1( x * , x *2 , x *3 ,....... x *n)  R1 ' , x ' , x ' ,....... x ' by
1 5. Solve for x1 2 3 n
f 2 ( x * , x *2 , x *3 ,....... x *n)  R 2 solving the simultaneous equations.
1
........................................ 6. Apply correction to each variable.

f n ( x * , x *2 , x *3 ,....... x *n)  R n 7. Iterate until the corrections become very


1 small.
(A-2)
APPENDIX - B
The intent of the solution scheme is to correct
x1* , x *2 , x *3 ,....... x *n with a set of Successive Substitution Method of Solving
Coupled Nonlinear System of Algebraic
corrections x1 ' , x ' , x ' ,....... x ' such that Equations
2 3 n
R1 , R 2 , R 3 ,........, R n are zero. The application of the successive substitution
method involves the following steps:
4. Develop a set of correction equations for
all variables. 1. Develop the governing equations:

First construct the matrix of influence


x1  f 1 ( x , x 2 , x 3 ,....... x n)
1
coefficients:
 f1  f1  f1  f1 x 2  f 2 ( x , x 2 , x 3 ,....... x n)
........ 1 (B-1)
 x1  x 2  x 3  xn ........................................
 f2 f2 f2 f2 x n  f n ( x , x 2 , x 3 ,....... x n)
........ 1
 x1  x 2  x 3  xn
...................................... If there are n number of unknown variables,
there are n number of equations.
 fn fn fn fn
........ 2. Guess a solution for the equations:
 x1  x 2  x 3  xn

Then construct the set of simultaneous Guess x1* , x *2 , x *3 ,....... x *n as an initial


equations for corrections: solution for the governing equations.

3. Compute new values of


x1 , x 2 , x 3 ,....... x n by substituting
x1* , x *2 , x *3 ,....... x *n
in the right hand side of Equation B-1.
4. Under-relax the computed new value:
x   1    x*   x
where a is the under-relaxation
parameter.

5. Replace x1* , x *2 , x *3 ,....... x *n with the


computed value of
x1 , x 2 , x 3 ,....... x n
from Step 4.

6. Repeat Steps 3 to 5 convergence.

You might also like