# Pressure Reducing Valve (G)

Valve for restricting flow when at excessive pressure

**Library:**Simscape / Fluids / Gas / Valves & Orifices / Pressure Control Valves

## Description

The Pressure Reducing Valve (G) block models a valve
that constricts so as to maintain a preset gauge pressure at its outlet (port
**B**). The normally open valve begins to close when the outlet
pressure, measured against atmospheric pressure, rises above the valve pressure setting.
The opening area falls with the pressure drop down to a minimum—a point at which the
valve is fully closed and only leakage flow remains.

The relationship between the opening area and the pressure drop depends on the parameterization of the valve. That relationship can take the form of a linear analytical expression or of a (generally nonlinear) tabulated function.

The flow can be laminar or turbulent, and it can reach (up to) sonic speeds. This happens at the vena contracta, a point just past the throat of the valve where the flow is both its narrowest and fastest. The flow then chokes and its velocity saturates, with a drop in downstream pressure no longer sufficing to increase its velocity. Choking occurs when the back-pressure ratio hits a critical value characteristic of the valve. Supersonic flow is not captured by the block.

### Control and Other Pressures

The pressure at the outlet serves as the control signal of the valve. The greater its rise over the pressure setting of the same, the smaller its opening area becomes. For use in the block calculations, its value is defined as:

$${p}_{\text{Ctl}}={p}_{\text{B}},$$

where *p* is instantaneous pressure. The
subscript `Ctl`

denotes the control value and the subscript
**B** that at the port. Both are determined during simulation
as absolute pressures. The pressure setting of the valve is likewise computed as:

$${P}_{\text{Set}}={P}_{\text{B,Set}}+{P}_{\text{Atm}},$$

where *P* is a constant pressure parameter. The
subscript `Set`

denotes the valve setting, with the subscript
`B,Set`

being that specified in the block as a gauge pressure
at the outlet (port **B**). The subscript `Atm`

denotes the atmospheric value (specified in the Gas Properties (G) block of
the model). For the maximum pressure of the valve:

$${P}_{\text{Max}}={P}_{\text{Set}}+\Delta P,$$

where *ΔP* refers specifically to the pressure
regulation range of the valve, obtained as a constant from the block parameter of
the same name. The subscript `Max`

denotes the maximum
value.

### Control Pressure Overshoot

The degree to which the control pressure exceeds the pressure setting determines how much the valve will close. The pressure overshoot is expressed here as a fraction of the (width of the) pressure regulation range:

$$\widehat{p}=\frac{{p}_{\text{Ctl}}-{p}_{\text{Set}}}{\Delta P}.$$

The fraction—technically, the overshoot, *normalized*—is
`0`

in the fully closed valve and `1`

in the
fully open valve. If the calculation should return a value outside of these bounds,
the nearest of the two is used instead. (In other words, the fraction is
*saturated* at `0`

and
`1`

.)

**Numerical Smoothing**

The normalized (and saturated) control pressure overshoot spans three regions.
Below the pressure setting of the valve, its value is a constant zero. Above the
maximum pressure—the sum of the pressure setting and the pressure regulation
range—it is `1`

. In between, it varies, as a linear function of
the control pressure measurement,
*p*_{Ctl}.

The transitions between the regions are sharp and their slopes discontinuous.
These pose a challenge to variable-step solvers (the sort commonly used with
Simscape models). To precisely capture discontinuities, referred to in some
contexts as *zero crossing events*, the solver must reduce
its time step, pausing briefly at the time of the crossing in order to recompute
its Jacobian matrix (a representation of the dependencies between the state
variables of the model and their time derivatives).

This solver strategy is efficient and robust when discontinuities are present. It makes the solver less prone to convergence errors—but it can considerably extend the time needed to finish the simulation run, perhaps excessively so for practical use in real-time simulation. An alternative approach, used here, is to remove the discontinuities altogether.

**Normalized pressure overshoot with sharp transitions**

The block removes the discontinuities by smoothing them over a specified time scale. The smoothing, which adds a slight distortion to the control pressure overshoot, ensures that the valve eases into its limiting positions rather than snap (abruptly) into them. The smoothing is optional: you can disable it by setting its time scale to zero. The shape and scale of the smoothing, when applied, derives in part from the cubic polynomials:

$${\lambda}_{\text{L}}=3{\overline{p}}_{\text{L}}^{2}-2{\overline{p}}_{\text{L}}^{3}$$

and

$${\lambda}_{\text{R}}=3{\overline{p}}_{\text{R}}^{2}-2{\overline{p}}_{\text{R}}^{3},$$

where

$${\overline{p}}_{\text{L}}=\frac{\widehat{p}}{\Delta {p}^{*}}$$

and

$${\overline{p}}_{\text{R}}=\frac{\widehat{p}-\left(1-\Delta {p}^{*}\right)}{\Delta {p}^{*}}.$$

In the equations:

*ƛ*_{L}is the smoothing expression for the transition from the maximally closed position.*ƛ*_{R}is the smoothing expression for the transition from the fully open position.*Δp*^{*}is the (unitless) characteristic width of the pressure smoothing region:$$\Delta {p}^{*}={f}^{*}\frac{1}{2},$$

where

*f*^{*}is a smoothing factor valued between`0`

and`1`

and obtained from the block parameter of the same name.When the smoothing factor is

`0`

, the control pressure overshoot stays in its original form—no smoothing applied—and its transitions remain abrupt. When it is`1`

, the smoothing spans the whole of the pressure regulation range (with the control pressure overshoot taking the shape of an*S*-curve).At intermediate values, the smoothing is limited to a fraction of that range. A value of

`0.5`

, for example, will smooth the transitions over a quarter of the pressure regulation range on each side (for a total smooth region of half the regulation range).

The smoothing adds two new regions to the control pressure overshoot—one for the smooth transition on the left, another for that on the right, giving a total of five regions. These are expressed in the piecewise function:

$${\widehat{p}}^{*}=\{\begin{array}{ll}0,\hfill & \widehat{p}\le 0\hfill \\ \widehat{p}{\lambda}_{\text{L}},\hfill & \widehat{p}<\Delta {P}^{*}\hfill \\ \widehat{p},\hfill & \widehat{p}\le 1-\Delta {P}^{*}\hfill \\ \widehat{p}\left(1-{\lambda}_{\text{R}}\right)+{\lambda}_{\text{R}},\hfill & \widehat{p}<1\hfill \\ 1\hfill & \widehat{p}\ge 1\hfill \end{array},$$

where the asterisk indicates a smoothed variable. The figure shows the effect of smoothing on the sharpness of the transitions.

### Sonic Conductance

As the normalized control pressure varies during simulation, so does the mass flow rate through the valve. The relationship between the two variables, however, is indirect. The mass flow rate is defined in terms of the valve's sonic conductance and it is this quantity that the normalized inlet pressure determines.

Sonic conductance, if you are unfamiliar with it, describes the ease with which a gas will flow when it is choked—when its velocity is at its theoretical maximum (the local speed of sound). Its measurement and calculation are covered in detail in the ISO 6358 standard (on which this block is based).

Only one value is commonly reported in valve data sheets: one taken at steady
state in the fully open position. This is the same specified in the **Sonic
conductance at maximum flow** parameter when the **Valve
parameterization** setting is ```
Sonic
conductance
```

. For values across the opening range of the valve,
this maximum is scaled by the normalized pressure overshoot:

$$C=\left({C}_{\text{Max}}-{C}_{\text{Min}}\right)\widehat{p}+{C}_{\text{Min}},$$

where *C* is sonic conductance and the
subscripts `Max`

and `Min`

denote its values in
the fully open and fully closed valve.

**Other Parameterizations**

Because sonic conductance may not be available (or the most convenient choice
for your model), the block provides several equivalent parameterizations. Use
the **Valve parameterization** drop-down list to select the
best for the data at hand. The parameterizations are:

`Restriction area`

`Sonic conductance`

`Cv coefficient (USCS)`

`Kv coefficient (SI)`

The parameterizations differ only in the data that they require of you. Their
mass flow rate calculations are still based on sonic conductance. If you select
a parameterization other than `Sonic conductance`

, then
the block converts the alternate data—the (computed) opening area or a
(specified) flow coefficient—into an equivalent sonic conductance.

**Flow Coefficients**

The flow coefficients measure what is, at bottom, the same quantity—the flow rate through the valve at some agreed-upon temperature and pressure differential. They differ only in the standard conditions used in their definition and in the physical units used in their expression:

*C*_{v}is measured at a generally accepted temperature of`60 ℉`

and pressure drop of`1 PSI`

; it is expressed in imperial units of`US gpm`

. This is the flow coefficient used in the model when the**Valve parameterization**block parameter is set to`Cv coefficient (USCS)`

.*K*_{v}is measured at a generally accepted temperature of`15 ℃`

and pressure drop of`1 bar`

; it is expressed in metric units of`m`

. This is the flow coefficient used in the model when the^{3}/h**Valve parameterization**block parameter is set to`Kv coefficient (SI)`

.

**Sonic Conductance Conversions**

If the valve parameterization is set to ```
Cv Coefficient
(USCS)
```

, the sonic conductance is computed at the maximally
closed and fully open valve positions from the **Cv coefficient (SI) at
maximum flow** and **Cv coefficient (SI) at leakage
flow** block parameters:

$$C=\left(4\times {10}^{-8}{C}_{\text{v}}\right){m}^{3}/(sPa),$$

where *C*_{v} is the
flow coefficient value at maximum or leakage flow. The subsonic index,
*m*, is set to `0.5`

and the critical
pressure ratio, *b*_{cr}, is set to
`0.3`

. (These are used in the mass flow rate calculations
given in the Momentum Balance section.)

If the `Kv coefficient (SI)`

parameterization is used
instead, the sonic conductance is computed at the same valve positions
(maximally closed and fully open) from the **Kv coefficient (USCS) at
maximum flow** and **Kv coefficient (USCS) at leakage
flow** block parameters:

$$C=\left(4.758\times {10}^{-8}{K}_{\text{v}}\right){m}^{3}/(sPa),$$

where *K*_{v} is the
flow coefficient value at maximum or leakage flow. The subsonic index,
*m*, is set to `0.5`

and the critical
pressure ratio, *b*_{cr}, is set to
`0.3`

.

For the `Restriction area`

parameterization, the
sonic conductance is computed (at the same valve positions) from the
**Maximum opening area**, and **Leakage
area** block parameters:

$$C=\left(0.128\times 4S/\pi \right)L/(sbar),$$

where *S* is the opening area at maximum or
leakage flow. The subsonic index, *m*, is set to
`0.5`

while the critical pressure ratio,
*b*_{cr} is computed from the expression:

$$0.41+0.272{\left[\frac{\widehat{p}\left({S}_{\text{Max}}-{S}_{\text{Leak}}\right)+{S}_{\text{Leak}}}{S}\right]}^{0.25}.$$

### Momentum Balance

The causes of those pressure losses incurred in the passages of the valve are ignored in the block. Whatever their natures—sudden area changes, flow passage contortions—only their cumulative effect is considered during simulation. This effect is assumed to reflect entirely in the sonic conductance of the valve (or in the data of the alternate valve parameterizations).

**Mass Flow Rate**

When the flow is choked, the mass flow rate is a function of the sonic conductance of the valve and of the thermodynamic conditions (pressure and temperature) established at the inlet. The function is linear with respect to pressure:

$${\dot{m}}_{\text{ch}}=C{\rho}_{\text{0}}{p}_{\text{in}}\sqrt{\frac{{T}_{\text{0}}}{{T}_{\text{in}}}},$$

where:

*C*is the sonic conductance inside the valve. Its value is obtained from the block parameter of the same name or by conversion of other block parameters (the exact source depending on the**Valve parameterization**setting).*ρ*is the gas density, here at standard conditions (subscript`0`

), obtained from the**Reference density**block parameter.*p*is the absolute gas pressure, here corresponding to the inlet (`in`

).*T*is the gas temperature at the inlet (`in`

) or at standard conditions (`0`

), the latter obtained from the**Reference temperature**block parameter.

When the flow is subsonic, and therefore no longer choked, the mass flow rate becomes a nonlinear function of pressure—both that at the inlet as well as the reduced value at the outlet. In the turbulent flow regime (with the outlet pressure contained in the back-pressure ratio of the valve), the mass flow rate expression is:

$${\dot{m}}_{\text{tur}}=C{\rho}_{\text{0}}{p}_{\text{in}}\sqrt{\frac{{T}_{\text{0}}}{{T}_{\text{in}}}}{\left[1-{\left(\frac{{p}_{\text{r}}-{b}_{\text{cr}}}{1-{b}_{\text{cr}}}\right)}^{2}\right]}^{m},$$

where:

*p*_{r}is the back-pressure ratio, or that between the outlet pressure (*p*_{out}) and the inlet pressure (*p*_{in}):$${P}_{\text{r}}=\frac{{p}_{\text{out}}}{{p}_{\text{in}}}$$

*b*_{cr}is the critical pressure ratio at which the flow becomes choked. Its value is obtained from the block parameter of the same name or by conversion of other block parameters (the exact source depending on the**Valve parameterization**setting).*m*is the*subsonic index*, an empirical coefficient used to more accurately characterize the behavior of subsonic flows. Its value is obtained from the block parameter of the same name or by conversion of other block parameters (the exact source depending on the**Valve parameterization**setting).

When the flow is laminar (and still subsonic), the mass flow rate expression changes to:

$${\dot{m}}_{\text{lam}}=C{\rho}_{\text{0}}{p}_{\text{in}}\left[\frac{1-{p}_{\text{r}}}{1-{b}_{\text{lam}}}\right]\sqrt{\frac{{T}_{\text{0}}}{{T}_{\text{in}}}}{\left[1-{\left(\frac{{b}_{\text{lam}}-{b}_{\text{cr}}}{1-{b}_{\text{cr}}}\right)}^{2}\right]}^{m}$$

where *b*_{lam} is the
critical pressure ratio at which the flow transitions between laminar and
turbulent regimes (obtained from the **Laminar flow pressure
ratio** block parameter). Combining the mass flow rate expressions
into a single (piecewise) function, gives:

$$\dot{m}=\{\begin{array}{ll}{\dot{m}}_{\text{lam}},\hfill & {b}_{\text{lam}}\le {p}_{\text{r}}<1\hfill \\ {\dot{m}}_{\text{tur}},\hfill & {b}_{\text{cr}}\le {p}_{\text{r}}<{p}_{\text{lam}}\hfill \\ {\dot{m}}_{\text{ch}},\hfill & {p}_{\text{r}}<{b}_{\text{Cr}}\hfill \end{array},$$

with the top row corresponding to subsonic and laminar flow, the middle row to subsonic and turbulent flow, and the bottom row to choked (and therefore sonic) flow.

### Mass Balance

The volume of fluid inside the valve, and therefore the mass of the same, is assumed to be very small and it is, for modeling purposes, ignored. As a result, no amount of gas can accumulate there. By the principle of conservation of mass, the mass flow rate into the valve through one port must therefore equal that out of the valve through the other port:

$${\dot{m}}_{A}+{\dot{m}}_{B}=0,$$

where $$\dot{m}$$ is defined as the mass flow rate *into* the
valve through port **A** or **B**. Note that in
this block the flow can reach but not exceed sonic speeds.

### Energy Balance

The valve is modeled as an adiabatic component. No heat exchange can occur between
the gas and the wall that surrounds it. No work is done on or by the gas as it
traverses from inlet to outlet. With these assumptions, energy can flow by advection
only, through ports **A** and **B**. By the
principle of conservation of energy, the sum of the port energy flows must then
always equal zero:

$${\varphi}_{\text{A}}+{\varphi}_{\text{B}}=0,$$

where *ϕ* is defined as the energy flow rate
*into* the valve through one of the ports
(**A** or **B**).

## Ports

### Conserving

## Parameters

## Extended Capabilities

**Introduced in R2018b**