# Temperature Control Valve (TL)

Temperature control valve in a thermal liquid network

**Libraries:**

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

## Description

The Temperature Control Valve (TL) block models an orifice with a thermostat as a flow control mechanism. The thermostat contains a temperature sensor and a black-box opening mechanism—one whose geometry and mechanics matter less than its effects. The sensor responds with a slight delay, captured by a first-order time lag, to variations in temperature.

When the sensor reads a temperature in excess of a preset activation value, the
opening mechanism actuates and the valve begins to open or close, depending on the
operation mode specified by the **Valve operation** parameter. The
change in opening area continues up to the limit of the temperature range of the valve,
beyond which the opening area is a constant. Within the temperature range, the opening
area is a linear function of temperature.

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 abrupt opening area changes at the zero and maximum ball positions.

### Mass Balance

The mass conservation equation in the valve is

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

where:

$${\dot{m}}_{A}$$ is the mass flow rate into the valve through port

**A**.$${\dot{m}}_{B}$$ is the mass flow rate into the valve through port

**B**.

### Momentum Balance

The momentum conservation equation in the valve is

$${p}_{A}-{p}_{B}=\frac{\dot{m}\sqrt{{\dot{m}}^{2}+{\dot{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:

*p*and_{A}*p*are the pressures at port_{B}**A**and port**B**.$$\dot{m}$$ is the mass flow rate.

$${\dot{m}}_{cr}$$ is the critical mass flow rate,

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

*ρ*is the average liquid density._{Avg}*C*is the value of the_{d}**Discharge coefficient**parameter.*S*is the value of the**Cross-sectional area at ports A and B**parameter.*S*is the valve opening area._{R}*PR*is the pressure ratio,_{Loss}$$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)}.$$

### 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**.

### Valve Opening Area

The valve opening area calculation is based on the linear expression

$${S}_{Linear}=\left(\frac{{S}_{End}-{S}_{Start}}{{T}_{Range}}\right)\left({T}_{Sensor}-{T}_{Activation}\right)+{S}_{Start},$$

where:

*S*is the linear valve opening area._{Linear}*S*is the valve opening area at the beginning of the temperature actuation range. This area depends on the_{Start}**Valve operation**parameter setting:$${S}_{Start}=\{\begin{array}{ll}{S}_{Leak},\hfill & \text{Valveopensaboveactivationtemperature}\hfill \\ {S}_{Max},\hfill & \text{Valveclosesaboveactivationtemperature}\hfill \end{array}$$

*S*is the valve opening area at the end of the temperature actuation range. This area depends on the_{End}**Valve operation**parameter setting:$${S}_{End}=\{\begin{array}{ll}{S}_{Max},\hfill & \text{Valveopensaboveactivationtemperature}\hfill \\ {S}_{Leak},\hfill & \text{Valveclosesaboveactivationtemperature}\hfill \end{array}$$

*S*is the value of the_{Max}**Maximum opening area**parameter.*S*is the value of the_{Leak}**Leakage area**parameter.*T*is the value of the_{Range}**Temperature regulation range**parameter.*T*is the value of the_{Activation}**Activation temperature**parameter*T*is the sensor temperature reading._{Sensor}When

**Temperature sensing**is`Valve inlet temperature`

,*T*is the average temperature inside the valve._{Sensor}When

**Temperature sensing**is`Thermal liquid sensing port`

,*T*is the temperature of the thermal liquid network where it connects to port_{Sensor}**T**.When

**Temperature sensing**is`Thermal sensing port`

,*T*is the temperature of the thermal network where it connects to port_{Sensor}**T**.

The valve model accounts for a first-order lag in the measured valve temperature through the differential equation

$$\frac{d}{dt}\left({T}_{Sensor}\right)=\frac{{T}_{Avg}-{T}_{Sensor}}{\tau},$$

where:

*T*is the arithmetic average of the valve port temperatures,_{Avg}$${T}_{Avg}=\frac{{T}_{A}+{T}_{B}}{2},$$

where

*T*and_{A}*T*are the temperatures at ports_{B}**A**and**B**.*τ*is the value of the**Sensor time constant**parameter.

When the valve is in a near-open or near-closed
position 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 valve
area between *S _{Leak}* and

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

_{Max}### Variables

To set the priority and initial target values for the block variables prior to simulation, use
the **Initial Targets** section in the block dialog box or
Property Inspector. For more information, see Set Priority and Initial Target for Block Variables.

Nominal values provide a way to specify the expected magnitude of a variable in a model.
Using system scaling based on nominal values increases the simulation robustness. Nominal
values can come from different sources, one of which is the **Nominal
Values** section in the block dialog box or Property Inspector. For more
information, see Modify Nominal Values for a Block Variable.

## Examples

## Ports

### Conserving

## Parameters

## Extended Capabilities

## Version History

**Introduced in R2016a**