Rigid conduit for fluid flow in thermal liquid systems

Thermal Liquid/Elements

The Pipe (TL) block represents a pipeline segment with a fixed volume of liquid. The liquid experiences pressure losses and heating due to viscous friction and conductive heat transfer through the pipe wall. Viscous friction follows from the Darcy-Weisbach law, while the heat exchange coefficient follows from Nusselt number correlations. Heat transfer can occur in an unsteady manner.

The block includes parameters to account for the dynamic compressibility and inertia of liquid in a pipe. However, by default the block treats liquid flow through the pipe as steady and liquid mass within the pipe as constant. In this mode, the momentum and mass equations of this block are in their steady states. The liquid behaves as if it were incompressible. Pressure waves due to liquid inertia are absent in the pipe.

Depending on the effects you include, the block can function in three configurations: resistive tube, resistive tube with dynamic compressibility, and pipeline segment. The table summarizes the effects present in each configuration.

Configuration | Dynamic Compressibility | Flow Inertia | Thermal Dynamics |
---|---|---|---|

Resistive tube | Off | Off | On |

Resistive tube with dynamic compressibility | On | Off | On |

Pipeline segment | On | On | On |

The configuration to use depends on the relevant effects the model must capture. The pipeline segment configuration provides the greatest accuracy. However, this configuration also increases model complexity, raising the simulation computational cost and challenging the convergence to a numerical solution in rapid transient processes. As the simplest in the list, the resistive tube configuration provides a good starting point in a model. This is the default configuration of the block.

The block dialog box does not have a **Source code** link.
To view the source code for the various block configurations, open
the following files in the MATLAB^{®} editor:

Resistive tube —

`pipe_resistive.ssc`

Resistive tube with dynamic compressibility —

`pipe_resistive_compressibility.ssc`

Resistive tube —

`pipe_resistive_compressibility_inertia.ssc`

Use the Pipe block in the resistive tube configuration when:

Thermal dynamic effects are important but flow dynamic effects, which have a smaller time scale, are not.

Liquid mass in the pipe is a negligible fraction of the total liquid mass in the system.

The resistive tube configuration is the recommended starting point for this block, even if fluid dynamic compressibility and flow inertia are important in your model. The simulation results using this configuration provides reasonable initial conditions for more advanced configurations in which fluid dynamic compressibility and flow inertia are important—e.g. resistive tube with dynamic compressibility and pipeline segment configurations.

Use this block in the resistive tube with dynamic compressibility configuration when:

Thermal dynamic effects are important but flow dynamic effects, which have a smaller time scale, are not.

Liquid mass in the pipe is not negligible with respect to the total liquid mass in the system

Use this block in the pipeline segment configuration when the characteristic time of the thermal liquid system is close to the liquid compressibility time scale:

$$\tau =\frac{L}{a},$$

*τ*is the characteristic time of the thermal liquid system*L*is the characteristic pipe length*a*is the speed of sound in the liquid.

The mass conservation equation for the pipe is

$${\dot{m}}_{\text{A}}+{\dot{m}}_{\text{B}}=\{\begin{array}{cc}0,& \text{if}\text{\hspace{0.17em}}\text{fluid}\text{\hspace{0.17em}}\text{dynamic}\text{\hspace{0.17em}}\text{compressibility}\text{\hspace{0.17em}}\text{is}\text{\hspace{0.17em}}\text{'off'}\\ V\rho \left(\frac{1}{\beta}\frac{dp}{dt}+\alpha \frac{dT}{dt}\right),& \text{if}\text{\hspace{0.17em}}\text{fluid}\text{\hspace{0.17em}}\text{dynamic}\text{\hspace{0.17em}}\text{compressibility}\text{\hspace{0.17em}}\text{is}\text{\hspace{0.17em}}\text{'on'}\end{array}$$

$${\dot{m}}_{\text{A}}$$ and $${\dot{m}}_{\text{B}}$$ are the mass flow rates through ports A and B.

*V*is the pipe fluid volume.*ρ*is the thermal liquid density in the pipe.*β*is the isothermal bulk modulus in the pipe.*α*is the isobaric thermal expansion coefficient in the pipe.*p*is the thermal liquid pressure in the pipe.*T*is the thermal liquid temperature in the pipe.

The momentum conservation equation for the half pipe adjacent to port A is

$$A\left({p}_{A}-p\right)+{F}_{\text{v,A}}=\{\begin{array}{cc}0,& \text{if}\text{\hspace{0.17em}}\text{flow}\text{\hspace{0.17em}}\text{inertia}\text{\hspace{0.17em}}\text{is}\text{\hspace{0.17em}}\text{'off'}\\ \frac{L}{2}{\ddot{m}}_{\text{A}},& \text{if}\text{\hspace{0.17em}}\text{flow}\text{\hspace{0.17em}}\text{inertia}\text{\hspace{0.17em}}\text{is}\text{\hspace{0.17em}}\text{'on'}\end{array}$$

$$A\left({p}_{B}-p\right)+{F}_{\text{v,B}}=\{\begin{array}{cc}0,& \text{if}\text{\hspace{0.17em}}\text{flow}\text{\hspace{0.17em}}\text{inertia}\text{\hspace{0.17em}}\text{is}\text{\hspace{0.17em}}\text{'off'}\\ \frac{L}{2}{\ddot{m}}_{\text{B}},& \text{if}\text{\hspace{0.17em}}\text{flow}\text{\hspace{0.17em}}\text{inertia}\text{\hspace{0.17em}}\text{is}\text{\hspace{0.17em}}\text{'on'}\end{array}$$

*A*is the pipe cross-sectional area.*p*,*p*_{A}, and*p*_{B}are the liquid pressures in the pipe, at port A, and port B.*F*_{v,A}and*F*_{v,B}are the viscous dissipation forces between the pipe volume center and ports A and B.

The viscous friction force for the half pipe adjacent to port A is

$${F}_{\text{v,A}}=\{\begin{array}{cc}-\lambda {\nu}_{\text{A,u}}\left(\frac{L+{L}_{\text{Eq}}}{\text{2}}\right)\frac{{\dot{m}}_{\text{A}}}{2{D}^{2}},& \text{if}\text{\hspace{0.17em}}{\text{Re}}_{\text{A}}<{\text{Re}}_{\text{l}}\\ -{f}_{\text{A}}\left(\frac{L+{L}_{\text{Eq}}}{2}\right)\frac{{\dot{m}}_{\text{A}}\left|{\dot{m}}_{\text{A}}\right|}{2{\rho}_{\text{A,u}}DA},& {\text{ifRe}}_{\text{A}}\ge {\text{Re}}_{\text{t}}\end{array}$$

$${F}_{\text{v,B}}=\{\begin{array}{cc}-\lambda {\nu}_{\text{B,u}}\left(\frac{L+{L}_{\text{Eq}}}{2}\right)\frac{{\dot{m}}_{\text{B}}}{2{D}^{2}},& \text{if}\text{\hspace{0.17em}}{\text{Re}}_{\text{B}}<{\text{Re}}_{\text{l}}\\ -{f}_{\text{B}}\left(\frac{L+{L}_{\text{Eq}}}{2}\right)\frac{{\dot{m}}_{\text{B}}\left|{\dot{m}}_{\text{B}}\right|}{2{\rho}_{\text{B,u}}DA},& \text{if}\text{\hspace{0.17em}}{\mathrm{Re}}_{\text{B}}\ge {\mathrm{Re}}_{\text{t}}\end{array}$$

*ρ*_{A,u}and*ρ*_{B,u}are the upwind liquid densities at ports A and B.*λ*is the pipe shape factor.*ν*_{A,u},*ν*_{B,u}are the upwind dynamic viscosities at inlets A and B.*L*_{Eq}is the aggregate equivalent length of the local pipe resistances.*D*is the hydraulic diameter of the pipe.*f*_{A}and*f*_{B}are the Darcy friction factors in the pipe halves adjacent to inlets A and B.Re

_{A}and*Re*_{B}are the Reynolds numbers at ports A and B.Re

_{l}is the largest Reynolds number at which laminar flow can occur.Re

_{t}is the smallest Reynolds number at which turbulent flow can occur.

The block smooths the transition between laminar and
turbulent flow regimes (Re_{l} <
Re < Re_{t}) based on
the Reynolds numbers

$${\mathrm{Re}}_{\text{A}}=\frac{D{\dot{m}}_{\text{A}}}{A{\mu}_{\text{A,u}}},$$

$${\mathrm{Re}}_{\text{B}}=\frac{D{\dot{m}}_{\text{B}}}{A{\mu}_{\text{B,u}}},$$

*μ*_{A,u}and*μ*_{B,u}are the upwind dynamic viscosities at inlets A and B.

The Darcy friction factors follow from the Haaland approximation for the turbulent regime:

$$f=\frac{1}{{\left[-1.8{\mathrm{log}}_{10}\left(\frac{6.9}{\mathrm{Re}}+{\left(\frac{1}{3.7}\frac{r}{D}\right)}^{1.11}\right)\right]}^{2}},$$

*f*is the Darcy friction factor.*r*is the pipe surface roughness.

The energy conservation equation for the pipe is

$$V\frac{d\left(\rho u\right)}{dt}={\varphi}_{\text{A}}+{\varphi}_{\text{B}}+{Q}_{H},$$

*Φ*_{A}and*Φ*_{B}are the total energy flow rates into the pipe through ports A and B.*Q*_{H}is the heat flow rate into the pipe through the pipe wall.

The heat flow rate into the pipe through the pipe wall is

$${Q}_{H}=h\left({T}_{\text{W}}-T\right)PL,$$

*Q*_{H}is the heat flow rate.*h*is the convective heat transfer coefficient.*T*,*T*_{W}are the liquid and pipe wall temperatures.*P*is the pipe cross-section perimeter, defined in terms of the hydraulic diameter:$$P=\frac{4A}{D}.$$

The heat transfer coefficient follows from the definition of the Nusselt number:

$$\text{Nu}=\frac{hD}{k},$$

`3.66`

is commonly used for circular pipes with
constant wall temperature. For turbulent flows, the Nusselt number
is computed from the Gnielinski equation:$$Nu=\frac{\left(f/8\right)\left({\mathrm{Re}}_{D}-1000\right)\mathrm{Pr}}{1+12.7{\left(f/8\right)}^{1/2}\left({\mathrm{Pr}}^{2/3}-1\right)},$$

where *f * is the Darcy friction factor, *Re* the
Reynolds number, and *Pr* the Prandtl number. The
Prandtl number is computed from the fluid properties specified in
the Thermal Liquid Settings (TL) block:

$$\mathrm{Pr}=\frac{{c}_{p}\mu}{k},$$

where:

*c*is the specific heat_{p}*μ*is the dynamic viscosity*k*is the thermal conductivity

For the transitional region between laminar and turbulent flow regimes, the block computes the Nusselt number using the expression:

$$Nu=N{u}_{L}+\left(N{u}_{T}-N{u}_{L}\right)\frac{Re-R{e}_{L}}{{\mathrm{Re}}_{T}-R{e}_{L}}.$$

The pipe wall is rigid.

The flow is fully developed.

The effect of gravity is negligible.

Heat transfer is calculated with respect to the temperature of the fluid volume in the pipe. To model temperature gradient due to heat transfer along a long pipe, connect multiple Pipe (TL) blocks in series.

**Pipe length**Enter the longitudinal length of the pipe. This is the length of the pipe along the direction of flow. The default value is

`5`

m.**Cross-sectional area**Enter the cross-sectional area of the pipe. This is the area of the pipe normal to the direction of flow. The default value is

`0.01`

m^2.**Hydraulic diameter**Enter the hydraulic diameter of the pipe. This is the diameter of a cylindrical pipe with the same cross-sectional area. The default value is

`0.1128`

m.

**Aggregate equivalent length of local resistances**Enter the combined length of all local resistances present in the pipe. Local resistances include bends, fittings, armatures, and pipe inlets and outlets. The effect of the local resistances is to increase the effective length of the pipe segment. The default value is

`1`

m.**Internal surface absolute roughness**Enter the absolute roughness of the internal surface of the pipe. This roughness equals the average height of surface defects inside the pipe. The block uses the absolute roughness to determine pressure losses in the turbulent flow regime. The default value is

`1.5e-5`

m, corresponding to drawn tubing.**Laminar flow upper Reynolds number limit**Enter the Reynolds number above which flow begins to transition from laminar to turbulent. This number equals the maximum Reynolds number corresponding to fully developed laminar flow. The default value is

`2000`

.**Turbulent flow lower Reynolds number limit**Enter the Reynolds number below which flow begins to transition from turbulent to laminar. This number equals to the minimum Reynolds number corresponding to fully developed turbulent flow. The default value is

`4000`

.**Shape factor for laminar flow viscous friction**Enter the shape factor of the pipe. This parameter encodes the effect of pipe geometry on the viscous friction losses incurred in the laminar regime. The appropriate value to use depends on the cross-sectional shape of the pipe.

Typical values include

`56`

for a square cross section,`62`

for a rectangular cross section, and`96`

for a concentric annulus cross section [1]. The default value, corresponding to a circular cross section, is`64`

.**Nusselt number for laminar flow heat transfer**Enter the Nusselt number for heat transfer in the laminar regime. The appropriate value to use depends on the pipe geometry and thermal boundary conditions. The default value is

`3.66`

, corresponding to a circular pipe cross section and constant wall temperature.

**Fluid dynamic compressibility**Select whether to account for the dynamic compressibility of the liquid. Dynamic compressibility gives the liquid density a dependence on pressure and temperature, impacting the transient response of the system at small time scales. Selecting

`On`

displays the additional parameter**Initial fluid pressure in the pipe**. The default setting is`Off`

.**Fluid inertia**Select whether to account for the flow inertia of the liquid. Flow inertia gives the liquid a resistance to changes in mass flow rate. Selecting

`On`

displays the additional parameter**Initial mass flow rate oriented from A to B**. The default setting is`Off`

.**Initial liquid temperature**Enter the liquid temperature in the pipe at time zero. The default value is

`293.15`

K.**Initial liquid pressure**Enter the liquid pressure in the pipe at time zero. This parameter appears only when

**Fluid dynamic compressibility**is`On`

. The default value is`1`

atm.**Initial mass flow rate oriented from A to B**Enter the mass flow rate from port A to port B at time zero. This parameter is visible only when

**Flow inertia**is`On`

. The default value is`0.1`

kg/s.

The block has two thermal liquid conserving ports, A and B, and one thermal conserving port, W.

[1] White, F.M., *Viscous Fluid Flow*,
McGraw-Hill, 1991

Was this topic helpful?