# Pressure Compensator Valve (TL)

**Libraries:**

Simscape /
Fluids /
Thermal Liquid /
Valves & Orifices /
Pressure Control Valves

## Description

The Pressure Compensator Valve (TL) block represents a pressure compensator in a thermal liquid network, such as a pressure relief valve or pressure reducing valve. Use this block to maintain the pressure at the valve based on signals from another part of the system.

The pressure differential between ports **X** and **Y**
is the control pressure, *P _{control}*. When this value
meets or exceeds the set pressure, the valve area opens or closes depending on the

**Valve specification**parameter. The pressure regulation range begins at the set pressure,

*P*.

_{set}### Pressure Control

The block regulates pressure when *P _{control}*
exceeds

*P*and continues to regulate the pressure until

_{set}*P*, the sum of

_{max}*P*and the pressure regulation range. The

_{set}**Set pressure differential**parameter defines the constant regulation range.

### Conservation of Mass

The block conserves mass such that

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

The block calculates the mass flow rate through the valve as

$$\dot{m}=\frac{{C}_{d}{A}_{valve}\sqrt{2\overline{\rho}}}{\sqrt{P{R}_{loss}\left(1-{\left(\frac{{A}_{valve}}{{A}_{port}}\right)}^{2}\right)}}\frac{\Delta p}{{\left[\Delta {p}^{2}+\Delta {p}_{crit}^{2}\right]}^{1/4}},$$

where:

*C*is the value of the_{d}**Discharge coefficient**parameter.*A*is the instantaneous valve open area._{valve}*A*is the value of the_{port}**Cross-sectional area at ports A and B**parameter.$$\overline{\rho}$$ is the average fluid density.

*Δp*is the valve pressure difference*p*–_{A}*p*._{B}

The critical pressure difference,
*Δp _{crit}*, is the pressure differential specified
by the

**Critical Reynolds number**parameter,

*Re*. This parameter represents the flow regime transition point between laminar and turbulent flow. The block finds the critical pressure difference as

_{crit}

$$\Delta {p}_{crit}=\frac{\pi}{8{A}_{valve}\overline{\rho}}{\left(\frac{\mu {\mathrm{Re}}_{crit}}{{C}_{d}}\right)}^{2},$$

where *μ* is the dynamic viscosity of the thermal liquid.

The pressure loss, *PR _{loss}*, describes the
reduction of pressure in the valve due to a decrease in area. The block calculates the
pressure loss as:

$$P{R}_{loss}=\frac{\sqrt{1-{\left(\frac{{A}_{valve}}{{A}_{port}}\right)}^{2}\left(1-{C}_{d}^{2}\right)}-{C}_{d}\frac{{A}_{valve}}{{A}_{port}}}{\sqrt{1-{\left(\frac{{A}_{valve}}{{A}_{port}}\right)}^{2}\left(1-{C}_{d}^{2}\right)}+{C}_{d}\frac{{A}_{valve}}{{A}_{port}}}.$$

The pressure recovery describes the positive pressure change in the valve due to an
increase in area. When you clear the **Pressure recovery** check box, the
block sets *PR _{loss}* to 1.

The block calculates *A _{valve}* using the opening
parameterization and the valve opening dynamics.

### Valve Opening Parameterization

When you set **Opening parameterization** to
`Linear`

, the valve area for normally open valves is

$${A}_{valve}=\widehat{p}\left({A}_{leak}-{A}_{max}\right)+{A}_{max},$$

where *A _{leak}* is the value of the

**Leakage Area**parameter and

*A*is the value of the

_{max}**Maximum opening area**parameter. This figure shows how the block controls the opening area for a normally open valve using the linear parameterization.

For normally closed valves, the block uses

$${A}_{valve}=\widehat{p}\left({A}_{max}-{A}_{leak}\right)+{A}_{leak}.$$

This figure show how the block controls the opening area for a normally closed valve using the linear parameterization.

The normalized pressure, $$\widehat{p}$$, is

$$\widehat{p}=\frac{{p}_{control}-{p}_{set}}{{p}_{max}-{p}_{set}}.$$

When the valve is in a near-open or near-closed
position in the linear parameterization, you can maintain numerical robustness in your
simulation by adjusting the **Smoothing factor** parameter. If the
**Smoothing factor** parameter is nonzero, the block smoothly saturates
the control pressure between *p _{set}* and

*p*. For more information, see Numerical Smoothing.

_{max}When you set **Opening parameterization** to ```
Tabulated
data
```

, *A _{leak}* and

*A*are the first and last parameters of the

_{max}**Opening area vector**parameter, respectively. The block calculates the opening area as

$${A}_{valve}=tablelookup\left({p}_{control,TLU,ref},{A}_{TLU},{p}_{control},interpolation=linear,extrapolation=nearest\right),$$

where:

*p*=_{control,TLU,ref}*p*+_{TLU}*p*._{offset}*p*is the_{TLU}**Pressure differential vector**parameter.*p*is an internal pressure offset that causes the valve to start closing when_{offset}*p*=_{control,TLU,ref}*p*._{set}*A*is the_{TLU}**Opening area vector**parameter.

This figure demonstrates how the block controls the opening area for a normally open valve using the tabulated data parameterization.

This figure demonstrates how the block controls the opening area for a normally closed valve using the tabulated data parameterization.

### Opening Dynamics

When you select **Opening dynamics**, the block introduces a control
pressure lag where *p _{control}* becomes the dynamic
control pressure,

*p*. The block calculates the instantaneous change in dynamic control pressure based on the

_{dyn}**Opening time constant**parameter,

*τ*:

$${\dot{p}}_{dyn}=\frac{{p}_{control}-{p}_{dyn}}{\tau}.$$

By default, the block clears the **Opening dynamics**
check box. When **Opening parameterization** is
`Linear`

, a nonzero value for the **Smoothing
factor** parameter provides additional numerical stability when the orifice is in
near-closed or near-open position.

The block calculates the steady-state dynamics according to the **Opening
parameterization** parameter based on the control pressure,
*p _{control}*.

### Energy Balance

The energy conservation equation in the valve is

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

where:

*ϕ*is the energy flow rate into the valve through port_{A}**A**.*ϕ*is the energy flow rate into the valve through port_{B}**B**.

## Ports

### Conserving

## Parameters

## Extended Capabilities

## Version History

**Introduced in R2023a**