modelTwoWayTRV
Two way thermostatic radiator valve
Extends from IDEAS.Fluid.Interfaces.PartialTwoPortInterface (Partial model with two ports and declaration of quantities that are used by many models), IDEAS.Fluid.Actuators.BaseClasses.ValveParameters (Model with parameters for valves).
Information
Two way valve with thermostatic radiator knob.
This model assumes no hysteresis and an
ideal opening characteristic with a proportional band of P K.
The default value of riseTime has been set
to reflect the typical delay of radiator knobs.
Parameters
| Type | Name | Default | Description |
|---|---|---|---|
| Modelica.Units.SI.Temperature | TSet | 294.15 | Temperature set point |
| Modelica.Units.SI.Temperature | P | 2 | Proportional band of valve |
| Real | l | 0.0001 | Valve leakage, l=Kv(y=0)/Kv(y=1) |
| Modelica.Units.SI.MassFlowRate | m_flow_turbulent | deltaM*abs(m_flow_nominal) | Turbulent flow if |m_flow| >= m_flow_turbulent |
| Assumptions | |||
| Boolean | allowFlowReversal (from PartialTwoPort) | true | = false to simplify equations, assuming, but not enforcing, no flow reversal |
| Nominal condition | |||
| Modelica.Units.SI.MassFlowRate | m_flow_nominal (from PartialTwoPortInterface) | Nominal mass flow rate | |
| Modelica.Units.SI.PressureDifference | dpValve_nominal (from ValveParameters) | Nominal pressure drop of fully open valve, used if CvData=IDEAS.Fluid.Types.CvTypes.OpPoint | |
| Modelica.Units.SI.PressureDifference | dpFixed_nominal | 0 | Pressure drop of pipe and other resistances that are in series |
| Modelica.Units.SI.PressureDifference | dp_nominal | dpValve_nominal + dpFixed_nominal | Pressure drop at nominal mass flow rate |
| Advanced | |||
| Modelica.Units.SI.MassFlowRate | m_flow_small (from PartialTwoPortInterface) | 1E-4*abs(m_flow_nominal) | Small mass flow rate for regularization of zero flow |
| Boolean | from_dp | false | = true, use m_flow = f(dp) else dp = f(m_flow) |
| Boolean | homotopyInitialization | true | = true, use homotopy method |
| Boolean | linearized | false | = true, use linear relation between m_flow and dp for any flow rate |
| Advanced › Diagnostics | |||
| Boolean | show_T (from PartialTwoPortInterface) | false | = true, if actual temperature at port is computed |
| Flow Coefficient | |||
| IDEAS.Fluid.Types.CvTypes | CvData (from ValveParameters) | IDEAS.Fluid.Types.CvTypes.OpPoint | Selection of flow coefficient |
| Real | Kv (from ValveParameters) | Kv (metric) flow coefficient [m3/h/(bar)^(1/2)] | |
| Real | Cv (from ValveParameters) | Cv (US) flow coefficient [USG/min/(psi)^(1/2)] | |
| Modelica.Units.SI.Area | Av (from ValveParameters) | Av (metric) flow coefficient | |
| Pressure-flow linearization | |||
| Real | deltaM (from ValveParameters) | 0.02 | Fraction of nominal flow rate where linearization starts, if y=1 |
| Advanced › Nominal condition | |||
| Modelica.Units.SI.Density | rhoStd (from ValveParameters) | Inlet density for which valve coefficients are defined | |
| Dynamics › Actuator position | |||
| Boolean | use_strokeTime | true | Set to true to continuously open and close valve using strokeTime |
| Modelica.Units.SI.Time | strokeTime | 1200 | Time needed to fully open or close actuator |
| Modelica.Blocks.Types.Init | init | Modelica.Blocks.Types.Init.InitialOutput | Type of initialization (no init/steady state/initial state/initial output) |
| Real | y_start | 1 | Initial value of control signal |
Connectors
| Type | Name | Default | Description |
|---|---|---|---|
| Modelica.Fluid.Interfaces.FluidPort_a | port_a (from PartialTwoPort) | Fluid connector a (positive design flow direction is from port_a to port_b) | |
| Modelica.Fluid.Interfaces.FluidPort_b | port_b (from PartialTwoPort) | Fluid connector b (positive design flow direction is from port_a to port_b) | |
| Modelica.Blocks.Interfaces.RealInput | T | Temperature measurement | |
| Modelica.Blocks.Interfaces.RealOutput | y | Valve set point |
Components
| Type | Name | Default | Description |
|---|---|---|---|
| Modelica.Units.SI.MassFlowRate | m_flow (from PartialTwoPortInterface) | port_a.m_flow | Mass flow rate from port_a to port_b (m_flow > 0 is design flow direction) |
| Modelica.Units.SI.PressureDifference | dp (from PartialTwoPortInterface) | port_a.p - port_b.p | Pressure difference between port_a and port_b |
| Medium.ThermodynamicState | sta_a (from PartialTwoPortInterface) | if allowFlowReversal then Medium.setState_phX(port_a.p, noEvent(actualStream(port_a.h_outflow)), noEvent(actualStream(port_a.Xi_outflow))) else Medium.setState_phX(port_a.p, noEvent(inStream(port_a.h_outflow)), noEvent(inStream(port_a.Xi_outflow))) | Medium properties in port_a |
| Medium.ThermodynamicState | sta_b (from PartialTwoPortInterface) | if allowFlowReversal then Medium.setState_phX(port_b.p, noEvent(actualStream(port_b.h_outflow)), noEvent(actualStream(port_b.Xi_outflow))) else Medium.setState_phX(port_b.p, noEvent(port_b.h_outflow), noEvent(port_b.Xi_outflow)) | Medium properties in port_b |
| IDEAS.Fluid.Actuators.Valves.TwoWayLinear | val | Linear valve | |
| Modelica.Blocks.Sources.RealExpression | yExp | Smooth control signal |
Revisions
-
October 30, 2024, by Lucas Verleyen:
Updates according to IBPSA.
See #1383 (and IBPSA, #1926). -
March 31, 2020 by Filip Jorissen:
Revised implementation usingsmoothHeaviside. See #1022. -
October 26, 2018 by Filip Jorissen:
UsingsmoothLimitfor P controller. See #948. -
September 24, 2018 by Filip Jorissen:
Modified displayUnit of proportional band P to Kelvin to avoid displaying -271.15C. See #919. -
November 15, 2016 by Filip Jorissen:
First implementation.