# Ball Valve (TL)

Flow control valve actuated by longitudinal motion of ball element

## Library

Thermal Liquid/Valves/Flow Control Valves

## Description

The Ball Valve (TL) block models the flow reduction due to a ball valve in a thermal liquid network. The valve consists of a ball on a perforated seat with a cylindrical or conical shape. The valve opens when the ball undergoes a positive displacement from its seat, allowing fluid to flow through the seat perforation.

Ball Valve Seat Types

A smoothing function allows the valve opening area to change smoothly between the fully closed and fully open positions. The smoothing function does this by removing the curve discontinuities at the zero and maximum ball positions. The figure shows the effect of smoothing on the valve opening area curve.

Opening-Area Curve Smoothing

### Valve Opening Area

The block computes the valve opening area directly from valve geometry parameters. The calculation depends on the parameter setting. If the valve seat is set to `Sharp-edged`, the valve opening area is based on the geometrical expression:

`$A=\pi {r}_{o}\left(1-{\left(\frac{{r}_{b}}{{d}_{OB}}\right)}^{2}\right){d}_{OB}\left(h\right),$`
where:

• S is the valve opening area.

• ro is the valve orifice radius.

• rb is the valve ball radius.

• dOB(h) is the distance between the center of the ball (point O in the figure) and the edge of the orifice (point B). This distance is a function of the valve lift (h).

Valve Parameters

If the valve seat is set to `Conical`, the valve opening area is based on the geometrical expression:
`$A=\pi {r}_{b}\mathrm{sin}\left(\theta \right)h+\frac{\pi }{2}\mathrm{sin}\left(\frac{\theta }{2}\right)\mathrm{sin}\left(\theta \right){h}^{2},$`
where:

• θ is the angle between the conical seat wall and centerline.

The valve opening expressions introduce undesirable discontinuities at the fully open and fully closed positions. The block eliminates these discontinuities using polynomial expressions that smooth the transitions to and from the fully open and fully closed positions. The valve smoothing expressions are

`${\lambda }_{L}=3{\overline{h}}_{L}^{2}-2{\overline{h}}_{L}^{3}$`
and
`${\lambda }_{R}=3{\overline{h}}_{R}^{2}-2{\overline{h}}_{R}^{3}$`
where:
`${\overline{h}}_{L}=\frac{h}{\Delta {h}_{smooth}}$`
and
`$\overline{h}=\frac{h-\left({h}_{max}-\Delta {h}_{smooth}\right)}{{h}_{max}-\left({h}_{max}-\Delta {h}_{smooth}\right)}$`
In the equations:

• λL is the smoothing expression for the fully closed portion of the valve opening curve.

• λR is the smoothing expression applied to the fully open portion of the valve opening curve.

• hMax is the maximum valve lift.

• Δhsmooth is the valve lift smoothing region:

`$\Delta {h}_{smooth}={f}_{smooth}\frac{{h}_{Max}}{2}$`
where fsmooth is a smoothing factor between 0 and 1.

The smoothed valve opening area is given by the piecewise conditional expression

`${S}_{R}=\left\{\begin{array}{ll}{S}_{Leak},\hfill & h\le 0\hfill \\ {S}_{Leak}\left(1-{\lambda }_{L}\right)+\left(A+{S}_{Leak}\right){\lambda }_{L},\hfill & h<\Delta {h}_{smooth}\hfill \\ A+{S}_{Leak},\hfill & h\le {h}_{Max}-\Delta {h}_{smooth}\hfill \\ \left(A+{S}_{Leak}\right)\left(1-{\lambda }_{R}\right)+\left({S}_{Leak}+{S}_{Max}\right){\lambda }_{R},\hfill & h<{h}_{Max}\hfill \\ {S}_{Leak}+{S}_{Max},\hfill & h\ge {h}_{Max}\hfill \end{array},\text{\hspace{0.17em}}$`
where:

• SR is the smoothed valve opening area.

• SLeak is the valve leakage area.

• SMax is the maximum valve opening area:

`${S}_{Max}=\pi {r}_{o}^{2}$`

### Mass Balance

The mass conservation equation in the valve is

`${\stackrel{˙}{m}}_{A}+{\stackrel{˙}{m}}_{B}=0,$`
where:

• ${\stackrel{˙}{m}}_{A}$ is the mass flow rate into the valve through port A.

• ${\stackrel{˙}{m}}_{B}$ is the mass flow rate into the valve through port B.

### Energy Balance

The energy conservation equation in the valve is

`${\varphi }_{A}+{\varphi }_{B}=0,$`
where:

• ϕA is the energy flow rate into the valve through port A.

• ϕB is the energy flow rate into the valve through port B.

### Momentum Balance

The momentum conservation equation in the valve is

`${p}_{A}-{p}_{B}=\frac{\stackrel{˙}{m}\sqrt{{\stackrel{˙}{m}}^{2}+{\stackrel{˙}{m}}_{cr}^{2}}}{2{\rho }_{Avg}{C}_{d}^{2}{S}^{2}}\left[1-{\left(\frac{{S}_{R}}{S}\right)}^{2}\right]P{R}_{Loss},$`
where:

• pA and pB are the pressures at port A and port B.

• $\stackrel{˙}{m}$ is the mass flow rate.

• ${\stackrel{˙}{m}}_{cr}$ is the critical mass flow rate:

`${\stackrel{˙}{m}}_{cr}={\mathrm{Re}}_{cr}{\mu }_{Avg}\sqrt{\frac{\pi }{4}{S}_{R}}.$`

• ρAvg is the average liquid density.

• Cd is the discharge coefficient.

• S is the valve inlet area.

• PRLoss is the pressure ratio:

`$P{R}_{Loss}=\frac{\sqrt{1-{\left({S}_{R}/S\right)}^{2}\left(1-{C}_{d}^{2}\right)}-{C}_{d}\left({S}_{R}/S\right)}{\sqrt{1-{\left({S}_{R}/S\right)}^{2}\left(1-{C}_{d}^{2}\right)}+{C}_{d}\left({S}_{R}/S\right)}.$`

## Parameters

### Parameters Tab

Valve seat specification

Choice of valve seat geometry. Options include `Sharp-edged` and `Conical`. The default setting is `Sharp-edged`.

Cone angle

Angle formed by the sides of the conical seat. This parameter is active only when the Valve seat specification parameter is active. The default value is `120` deg.

Ball diameter

Diameter of the spherical control member. The default value is `0.01` m.

Orifice diameter

Diameter of the valve opening. The default value is `7e-3` m.

Ball displacement offset

Control member offset from the zero position. The control member displacement is the sum of the input signal S and the displacement offset specified. The default value is `0` m.

Leakage area

Area through which fluid can flow in the fully closed valve position. This area accounts for leakage between the valve inlets. The default value is `1e-12` m^2.

Smoothing factor

Portion of the opening-area curve to smooth expressed as a fraction. Smoothing eliminates discontinuities at the minimum and maximum flow valve positions. The smoothing factor must be between `0` and `1`. Enter a value of `0` for zero smoothing. Enter a value of `1` for full-curve smoothing. The default value is `0.01`.

Cross-sectional area at ports A and B

Area normal to the direction of flow at the valve inlets. This area is assumed the same for all the inlets. The default value is `0.01` m^2.

Characteristic longitudinal length

Distance traversed by the fluid between the valve inlets. The default value is `0.1` m^2.

Discharge coefficient

Ratio of the actual mass flow rate through the valve to its ideal, or theoretical, value. The discharge coefficient accounts for the effects of valve geometry. The value must be between `0` and `1`.

Critical Reynolds number

Reynolds number at which flow transitions between laminar and turbulent regimes. Flow is laminar below this number and turbulent above it. The default value is `12`.

### Variables Tab

Mass flow rate into port A

Mass flow rate into the component through port A at the start of simulation. The default value is ```1 kg/s```.

## Ports

• A — Thermal liquid conserving port representing valve inlet A

• B — Thermal liquid conserving port representing valve inlet B

• S — Physical signal input port for the control member displacement