Information
This package contains models that validate the pipe models against measured data
from real district heating networks.
Extends from Modelica.Icons.ExamplesPackage (Icon for packages containing runnable examples).
Package Content
Name |
Description |
FlowReversal
|
Simple example of plug flow pipe with flow reversal |
MSLAIT
|
Validation pipe against data from Austrian Institute of Technology with standard library components |
MSLAIT2Nodes
|
Smaller discretisation. Validation pipe against data from Austrian Institute of Technology with standard library components |
PlugFlowAIT
|
Validation pipe against data from Austrian Institute of Technology |
PlugFlowULg
|
Validation against data from Université de Liège |
TransportWaterAir
|
Validation model, one having water and the other air |
Data
|
Experimental data for verification of pipe models |
Simple example of plug flow pipe with flow reversal
Information
Validation model in which water flows into the pipe and then the flow is reversed.
Extends from Modelica.Icons.Example (Icon for runnable examples).
Modelica definition
model FlowReversal
extends Modelica.Icons.Example;
package Medium =
Buildings.Media.Water ;
Modelica.Blocks.Sources.Step m_flow(
height=-4,
offset=2,
startTime=50) ;
Sources.Boundary_pT sin(
redeclare package Medium = Medium,
nPorts=1,
p(displayUnit="Pa") = 101325,
T=313.15) ;
Buildings.Fluid.FixedResistances.PlugFlowPipe pip(
redeclare package Medium = Medium,
nPorts=1,
dIns=0.05,
kIns=0.028,
cPip=500,
thickness=0.0032,
rhoPip=8000,
m_flow_nominal=2,
initDelay=true,
length=200,
v_nominal=2,
T_start_in=293.15,
T_start_out=293.15) ;
Buildings.Fluid.Sources.MassFlowSource_T sou(
nPorts=1,
redeclare package Medium = Medium,
m_flow=0,
use_m_flow_in=true,
T=303.15) ;
Buildings.Fluid.Sensors.TemperatureTwoPort senTemOut(
redeclare package Medium = Medium,
tau=0,
T_start=323.15,
m_flow_nominal=2)
;
Buildings.Fluid.Sensors.TemperatureTwoPort senTemIn(
redeclare package Medium = Medium,
tau=0,
T_start=323.15,
m_flow_nominal=2)
;
equation
connect(pip.ports_b[1], senTemOut.port_a);
connect(senTemOut.port_b, sin.ports[1]);
connect(sou.ports[1], senTemIn.port_a);
connect(senTemIn.port_b, pip.port_a);
connect(m_flow.y, sou.m_flow_in);
end FlowReversal;
Validation pipe against data from Austrian Institute of Technology with standard library components
Information
The example contains
experimental data from a real district heating network.
This data is used to validate this library's
Buildings.Fluid.FixedResistances.PlugFlowPipe in
Buildings.Fluid.FixedResistances.Validation.PlugFlowPipes.PlugFlowAIT.
This model compares its performance with the original Modelica Standard Library
pipes, using one discretization element per unit length of pipe.
For a coarser discretization, please refer to
MSLAIT2Nodes.
Note that these three models are identical, except for the pipe model that is used:
This comparison between different discretization levels and pipe models is made
to check the influence of the discretization and pipe model on computation time
and simulation accuracy.
The pipes' temperatures are not initialized, thus results of outflow
temperature before approximately the first 10000 seconds should not be considered.
Test bench schematic
Calibration
To calculate the length specific thermal resistance R
of the
pipe, the thermal resistance of the surrounding ground is added.
R=1/(0.208)+1/(2 lambda_g Modelica.Constants.pi) log(1/0.18)
Where the thermal conductivity of the ground lambda_g
= 2.4 W/(m K).
Extends from Modelica.Icons.Example (Icon for runnable examples).
Parameters
Type | Name | Default | Description |
Boolean | allowFlowReversal | false | = true to allow flow reversal, false restricts to design direction (port_a -> port_b) |
ThermalResistance | R | 1/(2*kIns*Modelica.Constants... | Thermal resistance of main pipes [K/W] |
ThermalResistance | R80 | 1/(2*0.024*Modelica.Constant... | Thermal resistance of service pipes [K/W] |
ThermalConductivity | kIns | 0.024 | Heat conductivity of pipe insulation material [W/(m.K)] |
Length | dIns | 0.045 | Thickness of pipe insulation [m] |
Diameter | diameter | 0.089 | Outer diameter of pipe [m] |
MassFlowRate | m_flow_nominal | 1 | Nominal mass flow rate, used for regularization near zero flow [kg/s] |
Time | tauHeaTra | 6500 | Time constant for heat transfer, default 20 minutes [s] |
Modelica definition
model MSLAIT
extends Modelica.Icons.Example;
Fluid.Sources.MassFlowSource_T Point1(
redeclare package Medium = Medium,
use_T_in=true,
use_m_flow_in=true,
nPorts=1) ;
package Medium =
Buildings.Media.Water;
Fluid.Sources.MassFlowSource_T Point4(
redeclare package Medium = Medium,
use_m_flow_in=true,
nPorts=1) ;
Fluid.Sources.MassFlowSource_T Point3(
redeclare package Medium = Medium,
use_m_flow_in=true,
nPorts=1) ;
Fluid.Sources.MassFlowSource_T Point2(
redeclare package Medium = Medium,
use_m_flow_in=true,
nPorts=1) ;
Modelica.Blocks.Sources.CombiTimeTable DataReader(
tableOnFile=true,
tableName="dat",
columns=2:pipeDataAIT151218.nCol,
fileName=pipeDataAIT151218.filNam)
;
Data.PipeDataAIT151218 pipeDataAIT151218 ;
Modelica.Blocks.Sources.RealExpression m_flow_p3(y=-DataReader.y[7])
;
Modelica.Blocks.Sources.RealExpression m_flow_p2(y=-DataReader.y[6])
;
Modelica.Blocks.Sources.RealExpression T_p1(y=DataReader.y[1])
;
Buildings.Fluid.Sources.Boundary_pT ExcludedBranch(
redeclare package Medium = Medium,
nPorts=1) ;
Buildings.HeatTransfer.Sources.PrescribedTemperature
prescribedTemperature ;
parameter Boolean allowFlowReversal=false
;
Modelica.Fluid.Pipes.DynamicPipe pip0(
nParallel=1,
diameter=0.0825,
redeclare package Medium = Medium,
use_HeatTransfer=true,
length=20,
redeclare model HeatTransfer =
Modelica.Fluid.Pipes.BaseClasses.HeatTransfer.IdealFlowHeatTransfer,
nNodes=20,
redeclare model FlowModel =
Modelica.Fluid.Pipes.BaseClasses.FlowModels.NominalTurbulentPipeFlow (
dp_nominal(displayUnit="Pa") = 10*pip0.length, m_flow_nominal=0.3),
energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial,
T_start=293.15) ;
inner Modelica.Fluid.System system;
parameter Modelica.SIunits.ThermalResistance R=
1/(2*kIns*Modelica.Constants.pi)*
log(0.18/0.0899) + 1/(2*2.4*Modelica.Constants.pi)*
log(2/0.18)
;
parameter Modelica.SIunits.ThermalResistance R80=
1/(2*0.024*Modelica.Constants.pi)*
log(0.07/0.0337) + 1/(2*2.4*Modelica.Constants.pi)*
log(2/0.07)
;
Modelica.Thermal.HeatTransfer.Components.ThermalResistor res0[pip0.nNodes](
each R=
R) ;
Modelica.Thermal.HeatTransfer.Components.ThermalCollector col0(m=pip0.nNodes)
;
Modelica.Fluid.Pipes.DynamicPipe pip1(
nParallel=1,
diameter=0.0825,
redeclare package Medium = Medium,
use_HeatTransfer=true,
redeclare model HeatTransfer =
Modelica.Fluid.Pipes.BaseClasses.HeatTransfer.IdealFlowHeatTransfer,
length=115,
nNodes=115,
redeclare model FlowModel =
Modelica.Fluid.Pipes.BaseClasses.FlowModels.NominalTurbulentPipeFlow (
m_flow_nominal=0.3, dp_nominal=10*pip1.length),
energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial,
T_start=293.15) ;
Modelica.Thermal.HeatTransfer.Components.ThermalCollector col1(m=pip1.nNodes)
;
Modelica.Thermal.HeatTransfer.Components.ThermalResistor res1[pip1.nNodes](
each R=
R) ;
Modelica.Fluid.Pipes.DynamicPipe pip2(
nParallel=1,
redeclare package Medium = Medium,
use_HeatTransfer=true,
redeclare model HeatTransfer =
Modelica.Fluid.Pipes.BaseClasses.HeatTransfer.IdealFlowHeatTransfer,
length=76,
nNodes=76,
redeclare model FlowModel =
Modelica.Fluid.Pipes.BaseClasses.FlowModels.NominalTurbulentPipeFlow (
dp_nominal=10*pip2.length, m_flow_nominal=0.3),
diameter=0.0337 - 2*0.0032,
energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial,
T_start=293.15) ;
Modelica.Thermal.HeatTransfer.Components.ThermalCollector col2(m=pip2.nNodes)
;
Modelica.Thermal.HeatTransfer.Components.ThermalResistor res2[pip2.nNodes](
each R=
R80) ;
Modelica.Fluid.Pipes.DynamicPipe pip3(
nParallel=1,
redeclare package Medium = Medium,
use_HeatTransfer=true,
redeclare model HeatTransfer =
Modelica.Fluid.Pipes.BaseClasses.HeatTransfer.IdealFlowHeatTransfer,
length=38,
nNodes=38,
redeclare model FlowModel =
Modelica.Fluid.Pipes.BaseClasses.FlowModels.NominalTurbulentPipeFlow (
dp_nominal=10*pip3.length, m_flow_nominal=0.3),
diameter=0.0337 - 2*0.0032,
energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial,
T_start=293.15) ;
Modelica.Thermal.HeatTransfer.Components.ThermalCollector col3(m=pip3.nNodes)
;
Modelica.Thermal.HeatTransfer.Components.ThermalResistor res3[pip3.nNodes](
each R=
R80) ;
Modelica.Fluid.Pipes.DynamicPipe pip4(
nParallel=1,
redeclare package Medium = Medium,
use_HeatTransfer=true,
redeclare model HeatTransfer =
Modelica.Fluid.Pipes.BaseClasses.HeatTransfer.IdealFlowHeatTransfer,
length=29,
nNodes=29,
redeclare model FlowModel =
Modelica.Fluid.Pipes.BaseClasses.FlowModels.NominalTurbulentPipeFlow (
dp_nominal=10*pip4.length, m_flow_nominal=0.3),
diameter=0.0337 - 2*0.0032,
energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial,
T_start=293.15) ;
Modelica.Thermal.HeatTransfer.Components.ThermalCollector col4(m=pip4.nNodes)
;
Modelica.Thermal.HeatTransfer.Components.ThermalResistor res4[pip4.nNodes](
each R=
R80) ;
Modelica.Fluid.Pipes.DynamicPipe pip5(
nParallel=1,
diameter=0.0825,
redeclare package Medium = Medium,
use_HeatTransfer=true,
redeclare model HeatTransfer =
Modelica.Fluid.Pipes.BaseClasses.HeatTransfer.IdealFlowHeatTransfer,
length=20,
nNodes=20,
redeclare model FlowModel =
Modelica.Fluid.Pipes.BaseClasses.FlowModels.NominalTurbulentPipeFlow (
dp_nominal=10*pip5.length, m_flow_nominal=0.3),
energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial,
T_start=293.15) ;
Modelica.Thermal.HeatTransfer.Components.ThermalCollector col5(m=pip5.nNodes)
;
Modelica.Thermal.HeatTransfer.Components.ThermalResistor res5[pip5.nNodes](
each R=
R) ;
parameter Modelica.SIunits.ThermalConductivity kIns=0.024
;
parameter Modelica.SIunits.Length dIns=0.045
;
parameter Modelica.SIunits.Diameter diameter=0.089
;
Fluid.Sensors.TemperatureTwoPort
senTem_p2(
redeclare package Medium = Medium,
m_flow_nominal=m_flow_nominal,
transferHeat=true,
tauHeaTra=tauHeaTra) ;
Fluid.Sensors.TemperatureTwoPort
senTem_p3(
redeclare package Medium = Medium,
m_flow_nominal=m_flow_nominal,
transferHeat=true,
tauHeaTra=tauHeaTra) ;
Fluid.Sensors.TemperatureTwoPort senTemIn_p2(
redeclare package Medium = Medium,
m_flow_nominal=m_flow_nominal,
transferHeat=true,
tauHeaTra=tauHeaTra) ;
Fluid.Sensors.TemperatureTwoPort
senTem_p1(
redeclare package Medium = Medium,
m_flow_nominal=m_flow_nominal,
transferHeat=true,
tauHeaTra=tauHeaTra) ;
Fluid.Sensors.TemperatureTwoPort
senTem_p4(
redeclare package Medium = Medium,
m_flow_nominal=m_flow_nominal,
transferHeat=true,
tauHeaTra=tauHeaTra) ;
parameter Modelica.SIunits.MassFlowRate m_flow_nominal=1
;
parameter Modelica.SIunits.Time tauHeaTra=6500
;
Fluid.Sources.MassFlowSource_T Point5(
redeclare package Medium = Medium,
use_m_flow_in=true,
nPorts=1) ;
Modelica.Blocks.Sources.RealExpression m_flow_p4(y=-DataReader.y[8])
;
Modelica.Blocks.Logical.Switch switch
;
Modelica.Blocks.Sources.RealExpression m_flow_zero(y=0)
;
Modelica.Blocks.Logical.LessThreshold lessThreshold(threshold=-0.001)
;
Modelica.Blocks.Logical.Switch switch1
;
equation
connect(m_flow_p3.y, Point3.m_flow_in);
connect(Point2.m_flow_in, m_flow_p2.y);
connect(T_p1.y, Point1.T_in);
connect(DataReader.y[5], Point1.m_flow_in);
connect(DataReader.y[9], prescribedTemperature.T);
connect(pip0.port_b, ExcludedBranch.ports[1]);
connect(pip4.port_a, pip1.port_b);
connect(pip5.port_a, pip1.port_b);
connect(pip1.port_a, pip0.port_b);
connect(pip2.port_b, senTem_p2.port_a);
connect(senTem_p2.port_b, Point2.ports[1]);
connect(senTem_p3.port_a, pip3.port_b);
connect(senTem_p3.port_b, Point3.ports[1]);
connect(pip3.port_a, pip5.port_b);
connect(senTemIn_p2.port_a, pip5.port_b);
connect(senTemIn_p2.port_b, pip2.port_a);
connect(pip4.port_b, senTem_p4.port_a);
connect(senTem_p4.port_b, Point4.ports[1]);
connect(senTem_p1.port_a, Point1.ports[1]);
connect(senTem_p1.port_b, pip0.port_a);
connect(Point5.ports[1], senTem_p4.port_a);
connect(pip2.heatPorts, res2.port_a);
connect(res2.port_b, col2.port_a);
connect(pip5.heatPorts, res5.port_a);
connect(res5.port_b, col5.port_a);
connect(res4.port_a, pip4.heatPorts);
connect(res4.port_b, col4.port_a);
connect(pip3.heatPorts, res3.port_a);
connect(res3.port_b, col3.port_a);
connect(res1.port_a, pip1.heatPorts);
connect(res1.port_b, col1.port_a);
connect(pip0.heatPorts, res0.port_a);
connect(res0.port_b, col0.port_a);
connect(col2.port_b, col5.port_b);
connect(col5.port_b, col4.port_b);
connect(col0.port_b, prescribedTemperature.port);
connect(col3.port_b, prescribedTemperature.port);
connect(col4.port_b, prescribedTemperature.port);
connect(m_flow_zero.y,switch. u3);
connect(switch.u1,m_flow_p4. y);
connect(Point4.m_flow_in,switch. y);
connect(switch.u2,lessThreshold. y);
connect(lessThreshold.u,m_flow_p4. y);
connect(lessThreshold.y,switch1. u2);
connect(m_flow_p4.y,switch1. u3);
connect(m_flow_zero.y,switch1. u1);
connect(switch1.y, Point5.m_flow_in);
connect(col1.port_b, prescribedTemperature.port);
end MSLAIT;
Smaller discretisation. Validation pipe against data from Austrian Institute of Technology with standard library components
Information
The example contains
experimental data from a real district heating network.
This data is used to validate this library's
plug flow pipe model
in
Buildings.Fluid.FixedResistances.Validation.PlugFlowPipes.PlugFlowAIT.
Note that these three models are identical, except for the pipe model that is used:
This comparison between different discretization levels and pipe models is made
to check the influence of the discretization and pipe model on computation time
and simulation accuracy.
The pipes' temperatures are not initialized, thus results of outflow temperature
before approximately the first 10000 seconds should not be considered.
Test bench schematic
Calibration
To calculate the length specific thermal resistance R
of the pipe,
the thermal resistance of the surrounding ground is added.
R=1/(0.208)+1/(2 lambdag Modelica.Constants.pi) log(1/0.18)
Where the thermal conductivity of the ground lambda_g
= 2.4 W/(m K).
Extends from Modelica.Icons.Example (Icon for runnable examples).
Parameters
Type | Name | Default | Description |
Boolean | allowFlowReversal | false | = true to allow flow reversal, false restricts to design direction (port_a -> port_b) |
Real | R | 1/(2*kIns*Modelica.Constants... | Thermal resistance per unit length of main pipes [(m.K)/W] |
Real | R80 | 1/(2*0.024*Modelica.Constant... | Thermal resistance per unit length of service pipes [(m.K)/W] |
ThermalConductivity | kIns | 0.024 | Heat conductivity [W/(m.K)] |
Length | dIns | 0.045 | Thickness of pipe insulation [m] |
Diameter | diameter | 0.089 | Outer diameter of pipe [m] |
MassFlowRate | m_flow_nominal | 1 | Nominal mass flow rate, used for regularization near zero flow [kg/s] |
Time | tauHeaTra | 6500 | Time constant for heat transfer, default 20 minutes [s] |
Modelica definition
model MSLAIT2Nodes
extends Modelica.Icons.Example;
Fluid.Sources.MassFlowSource_T Point1(
redeclare package Medium = Medium,
use_T_in=true,
use_m_flow_in=true,
nPorts=1);
package Medium =
Buildings.Media.Water;
Fluid.Sources.MassFlowSource_T Point4(
redeclare package Medium = Medium,
use_m_flow_in=true,
nPorts=1) ;
Fluid.Sources.MassFlowSource_T Point3(
redeclare package Medium = Medium,
use_m_flow_in=true,
nPorts=1) ;
Fluid.Sources.MassFlowSource_T Point2(
redeclare package Medium = Medium,
use_m_flow_in=true,
nPorts=1) ;
Modelica.Blocks.Sources.CombiTimeTable DataReader(
tableOnFile=true,
tableName="dat",
columns=2:pipeDataAIT151218.nCol,
fileName=pipeDataAIT151218.filNam)
;
Data.PipeDataAIT151218 pipeDataAIT151218 ;
Modelica.Blocks.Sources.RealExpression m_flow_p3(y=-DataReader.y[7])
;
Modelica.Blocks.Sources.RealExpression m_flow_p4(y=-DataReader.y[8])
;
Modelica.Blocks.Sources.RealExpression m_flow_p2(y=-DataReader.y[6])
;
Modelica.Blocks.Sources.RealExpression T_p1(y=DataReader.y[1])
;
Buildings.Fluid.Sources.Boundary_pT ExcludedBranch(
redeclare package Medium = Medium,
nPorts=1) ;
Buildings.HeatTransfer.Sources.PrescribedTemperature
prescribedTemperature ;
parameter Boolean allowFlowReversal=false
;
Modelica.Fluid.Pipes.DynamicPipe pip0(
nParallel=1,
diameter=0.0825,
redeclare package Medium = Medium,
use_HeatTransfer=true,
length=20,
redeclare model HeatTransfer =
Modelica.Fluid.Pipes.BaseClasses.HeatTransfer.IdealFlowHeatTransfer,
redeclare model FlowModel =
Modelica.Fluid.Pipes.BaseClasses.FlowModels.NominalTurbulentPipeFlow (
dp_nominal(displayUnit="Pa") = 10*pip0.length, m_flow_nominal=0.3),
nNodes=2,
energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial,
T_start=293.15) ;
inner Modelica.Fluid.System system;
parameter Real R(unit="(m.K)/W")=1/(2*kIns*Modelica.Constants.pi)
*
log(0.18/0.0899) + 1/(2*2.4*Modelica.Constants.pi)*
log(2/0.18) ;
parameter Real R80(unit="(m.K)/W")=1/(2*0.024*Modelica.Constants.pi)
*
log(0.07/0.0337) + 1/(2*2.4*Modelica.Constants.pi)*
log(2/0.07) ;
Modelica.Thermal.HeatTransfer.Components.ThermalResistor res0[pip0.nNodes](
each R=
2*R/pip0.length) ;
Modelica.Thermal.HeatTransfer.Components.ThermalCollector col0(m=pip0.nNodes)
;
Modelica.Fluid.Pipes.DynamicPipe pip1(
nParallel=1,
diameter=0.0825,
redeclare package Medium = Medium,
use_HeatTransfer=true,
redeclare model HeatTransfer =
Modelica.Fluid.Pipes.BaseClasses.HeatTransfer.IdealFlowHeatTransfer,
length=115,
redeclare model FlowModel =
Modelica.Fluid.Pipes.BaseClasses.FlowModels.NominalTurbulentPipeFlow (
m_flow_nominal=0.3, dp_nominal=10*pip1.length),
nNodes=2,
energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial,
T_start=293.15) ;
Modelica.Thermal.HeatTransfer.Components.ThermalCollector col1(m=pip1.nNodes)
;
Modelica.Thermal.HeatTransfer.Components.ThermalResistor res1[pip1.nNodes](
each R=
2*R/pip1.length) ;
Modelica.Fluid.Pipes.DynamicPipe pip2(
nParallel=1,
redeclare package Medium = Medium,
use_HeatTransfer=true,
redeclare model HeatTransfer =
Modelica.Fluid.Pipes.BaseClasses.HeatTransfer.IdealFlowHeatTransfer,
length=76,
redeclare model FlowModel =
Modelica.Fluid.Pipes.BaseClasses.FlowModels.NominalTurbulentPipeFlow (
dp_nominal=10*pip2.length, m_flow_nominal=0.3),
diameter=0.0337 - 2*0.0032,
nNodes=2,
energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial,
T_start=293.15) ;
Modelica.Thermal.HeatTransfer.Components.ThermalCollector col2(m=pip2.nNodes)
;
Modelica.Thermal.HeatTransfer.Components.ThermalResistor res2[pip2.nNodes](
each R=
2*R80/pip2.length) ;
Modelica.Fluid.Pipes.DynamicPipe pip3(
nParallel=1,
redeclare package Medium = Medium,
use_HeatTransfer=true,
redeclare model HeatTransfer =
Modelica.Fluid.Pipes.BaseClasses.HeatTransfer.IdealFlowHeatTransfer,
length=38,
redeclare model FlowModel =
Modelica.Fluid.Pipes.BaseClasses.FlowModels.NominalTurbulentPipeFlow (
dp_nominal=10*pip3.length, m_flow_nominal=0.3),
diameter=0.0337 - 2*0.0032,
nNodes=2,
energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial,
T_start=293.15) ;
Modelica.Thermal.HeatTransfer.Components.ThermalCollector col3(m=pip3.nNodes)
;
Modelica.Thermal.HeatTransfer.Components.ThermalResistor res3[pip3.nNodes](
each R=
2*R80/pip3.length) ;
Modelica.Fluid.Pipes.DynamicPipe pip4(
nParallel=1,
redeclare package Medium = Medium,
use_HeatTransfer=true,
redeclare model HeatTransfer =
Modelica.Fluid.Pipes.BaseClasses.HeatTransfer.IdealFlowHeatTransfer,
length=29,
redeclare model FlowModel =
Modelica.Fluid.Pipes.BaseClasses.FlowModels.NominalTurbulentPipeFlow (
dp_nominal=10*pip4.length, m_flow_nominal=0.3),
diameter=0.0337 - 2*0.0032,
nNodes=2,
energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial,
T_start=293.15) ;
Modelica.Thermal.HeatTransfer.Components.ThermalCollector col4(m=pip4.nNodes)
;
Modelica.Thermal.HeatTransfer.Components.ThermalResistor res4[pip4.nNodes](
each R=
2*R80/pip4.length) ;
Modelica.Fluid.Pipes.DynamicPipe pip5(
nParallel=1,
diameter=0.0825,
redeclare package Medium = Medium,
use_HeatTransfer=true,
redeclare model HeatTransfer =
Modelica.Fluid.Pipes.BaseClasses.HeatTransfer.IdealFlowHeatTransfer,
length=20,
redeclare model FlowModel =
Modelica.Fluid.Pipes.BaseClasses.FlowModels.NominalTurbulentPipeFlow (
dp_nominal=10*pip5.length, m_flow_nominal=0.3),
nNodes=2,
energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial,
T_start=293.15) ;
Modelica.Thermal.HeatTransfer.Components.ThermalCollector col5(m=pip5.nNodes)
;
Modelica.Thermal.HeatTransfer.Components.ThermalResistor res5[pip5.nNodes](
each R=
2*R/pip5.length) ;
parameter Modelica.SIunits.ThermalConductivity kIns=0.024
;
parameter Modelica.SIunits.Length dIns=0.045
;
parameter Modelica.SIunits.Diameter diameter=0.089
;
Fluid.Sensors.TemperatureTwoPort
senTem_p2(
redeclare package Medium = Medium,
m_flow_nominal=m_flow_nominal,
transferHeat=true,
tauHeaTra=tauHeaTra) ;
Fluid.Sensors.TemperatureTwoPort
senTem_p3(
redeclare package Medium = Medium,
m_flow_nominal=m_flow_nominal,
transferHeat=true,
tauHeaTra=tauHeaTra) ;
Fluid.Sensors.TemperatureTwoPort senTemIn_p2(
redeclare package Medium = Medium,
m_flow_nominal=m_flow_nominal,
transferHeat=true,
tauHeaTra=tauHeaTra) ;
Fluid.Sensors.TemperatureTwoPort senTem_p1(
redeclare package Medium = Medium,
m_flow_nominal=m_flow_nominal,
transferHeat=true,
tauHeaTra=tauHeaTra) ;
Fluid.Sensors.TemperatureTwoPort senTem_p4(
redeclare package Medium = Medium,
m_flow_nominal=m_flow_nominal,
transferHeat=true,
tauHeaTra=tauHeaTra) ;
parameter Modelica.SIunits.MassFlowRate m_flow_nominal=1
;
parameter Modelica.SIunits.Time tauHeaTra=6500
;
Modelica.Blocks.Logical.Switch switch
;
Modelica.Blocks.Sources.RealExpression m_flow_zero(y=0)
;
Modelica.Blocks.Logical.LessThreshold lessThreshold(threshold=-0.001)
;
Fluid.Sources.MassFlowSource_T Point5(
redeclare package Medium = Medium,
use_m_flow_in=true,
nPorts=1) ;
Modelica.Blocks.Logical.Switch switch1
;
equation
connect(m_flow_p3.y, Point3.m_flow_in);
connect(Point2.m_flow_in, m_flow_p2.y);
connect(T_p1.y, Point1.T_in);
connect(DataReader.y[5], Point1.m_flow_in);
connect(DataReader.y[9], prescribedTemperature.T);
connect(pip0.port_b, ExcludedBranch.ports[1]);
connect(pip4.port_a, pip1.port_b);
connect(pip5.port_a, pip1.port_b);
connect(pip1.port_a, pip0.port_b);
connect(pip2.port_b, senTem_p2.port_a);
connect(senTem_p2.port_b, Point2.ports[1]);
connect(senTem_p3.port_a, pip3.port_b);
connect(senTem_p3.port_b, Point3.ports[1]);
connect(pip3.port_a, pip5.port_b);
connect(senTemIn_p2.port_a, pip5.port_b);
connect(senTemIn_p2.port_b, pip2.port_a);
connect(pip4.port_b, senTem_p4.port_a);
connect(senTem_p4.port_b, Point4.ports[1]);
connect(senTem_p1.port_a, Point1.ports[1]);
connect(senTem_p1.port_b, pip0.port_a);
connect(m_flow_zero.y,switch. u3);
connect(switch.u1, m_flow_p4.y);
connect(Point4.m_flow_in, switch.y);
connect(switch.u2, lessThreshold.y);
connect(lessThreshold.u, m_flow_p4.y);
connect(Point5.m_flow_in,switch1. y);
connect(lessThreshold.y, switch1.u2);
connect(m_flow_p4.y, switch1.u3);
connect(m_flow_zero.y, switch1.u1);
connect(Point5.ports[1], senTem_p4.port_a);
connect(pip2.heatPorts, res2.port_a);
connect(res2.port_b, col2.port_a);
connect(col5.port_a, res5.port_b);
connect(res5.port_a, pip5.heatPorts);
connect(res4.port_a, pip4.heatPorts);
connect(res4.port_b, col4.port_a);
connect(col2.port_b, col5.port_b);
connect(col5.port_b, col4.port_b);
connect(pip1.heatPorts, res1.port_a);
connect(res1.port_b, col1.port_a);
connect(col4.port_b, col1.port_b);
connect(pip0.heatPorts, res0.port_a);
connect(res0.port_b, col0.port_a);
connect(col1.port_b, col0.port_b);
connect(col0.port_b, prescribedTemperature.port);
connect(pip3.heatPorts, res3.port_a);
connect(res3.port_b, col3.port_a);
connect(col3.port_b, prescribedTemperature.port);
end MSLAIT2Nodes;
Validation pipe against data from Austrian Institute of Technology
Information
The example contains
experimental data from a real district heating network.
The pipes' temperatures are not initialized. Therefore, results of
outflow temperature before approximately the first 10000 seconds should not be
considered.
Note that these three models are identical, except for the pipe model that is used:
This comparison between different discretization levels and pipe models is made
to check the influence of the discretization and pipe model on computation time
and simulation accuracy.
Test bench schematic
Calibration
To calculate the length specific thermal resistance R
of the pipe,
the thermal resistance of the surrounding ground is added, which yields
R=1/(0.208)+1/(2 lambda_g Modelica.Constants.pi) log(1/0.18),
where the thermal conductivity of the ground lambda_g
= 2.4 W/(m K).
Extends from Modelica.Icons.Example (Icon for runnable examples).
Parameters
Type | Name | Default | Description |
Length | Lcap | 1 | Length over which transient effects typically take place [m] |
Real | R80 | 1/(2*0.024*Modelica.Constant... | Thermal resistance per unit length of service pipes [(m.K)/W] |
Boolean | pipVol | true | Flag to decide whether volumes are included at the end points of the pipe |
Boolean | allowFlowReversal | true | = true to allow flow reversal, false restricts to design direction (port_a -> port_b) |
MassFlowRate | m_flow_nominal | 1 | Nominal mass flow rate, used for regularization near zero flow [kg/s] |
Time | tauHeaTra | 6500 | Time constant for heat transfer, default 20 minutes [s] |
Length | thickness | 0.0032 | Pipe wall thickness [m] |
Modelica definition
model PlugFlowAIT
extends Modelica.Icons.Example;
package Medium =
Buildings.Media.Water;
parameter Modelica.SIunits.Length Lcap=1
;
parameter Real R80(unit="(m.K)/W")=1/(2*0.024*Modelica.Constants.pi)
*
log(0.07/0.0337) + 1/(2*2.4*Modelica.Constants.pi)*
log(2/0.07) ;
parameter Boolean pipVol=true
;
parameter Boolean allowFlowReversal=true
;
parameter Modelica.SIunits.MassFlowRate m_flow_nominal=1
;
parameter Modelica.SIunits.Time tauHeaTra=6500
;
parameter Modelica.SIunits.Length thickness=0.0032 ;
Fluid.Sources.MassFlowSource_T Point1(
redeclare package Medium = Medium,
use_T_in=true,
use_m_flow_in=true,
nPorts=1) ;
Fluid.Sources.MassFlowSource_T Point4(
redeclare package Medium = Medium,
use_m_flow_in=true,
nPorts=1) ;
Fluid.Sources.MassFlowSource_T Point3(
nPorts=1,
redeclare package Medium = Medium,
use_m_flow_in=true) ;
Fluid.Sources.MassFlowSource_T Point2(
redeclare package Medium = Medium,
use_m_flow_in=true,
nPorts=1) ;
PlugFlowPipe pip1(
redeclare package Medium = Medium,
dh=0.0825,
dIns=0.045,
kIns=0.024,
length=115,
allowFlowReversal=allowFlowReversal,
nPorts=2,
m_flow_nominal=0.3,
R=1/(2*0.024*Modelica.Constants.pi)*
log(0.18/0.0899) + 1/(2*2.4*Modelica.Constants.pi)
*
log(2/0.18),
thickness=thickness,
cPip=500,
rhoPip=8000,
initDelay=false,
m_flow_start=0) ;
PlugFlowPipe pip4(
dh = 0.0337 - 2*0.0032,
redeclare package Medium = Medium,
length=29,
dIns=0.045,
kIns=0.024,
allowFlowReversal=allowFlowReversal,
m_flow_nominal=0.3,
thickness=thickness,
nPorts=2,
R=R80,
cPip=500,
rhoPip=8000,
initDelay=false,
m_flow_start=0) ;
PlugFlowPipe pip5(
redeclare package Medium = Medium,
length=20,
dh=0.0825,
kIns=0.024,
dIns=0.045,
allowFlowReversal=allowFlowReversal,
nPorts=2,
m_flow_nominal=0.3,
R=1/(2*0.024*Modelica.Constants.pi)*
log(0.18/0.0899) + 1/(2*2.4*Modelica.Constants.pi)
*
log(2/0.18),
thickness=thickness,
cPip=500,
rhoPip=8000,
initDelay=false,
m_flow_start=0) ;
PlugFlowPipe pip2(
redeclare package Medium = Medium,
length=76,
dIns=0.045,
kIns=0.024,
allowFlowReversal=allowFlowReversal,
nPorts=1,
m_flow_nominal=0.3,
thickness=thickness,
dh=0.0337 - 2*0.0032,
R=R80,
cPip=500,
rhoPip=8000,
initDelay=false,
m_flow_start=0) ;
PlugFlowPipe pip3(
redeclare package Medium = Medium,
length=38,
dIns=0.045,
kIns=0.024,
allowFlowReversal=allowFlowReversal,
nPorts=1,
m_flow_nominal=0.3,
thickness=thickness,
dh=0.0337 - 2*0.0032,
R=R80,
cPip=500,
rhoPip=8000,
initDelay=false,
m_flow_start=0) ;
Modelica.Blocks.Sources.CombiTimeTable DataReader(
tableOnFile=true,
tableName="dat",
columns=2:pipeDataAIT151218.nCol,
fileName=pipeDataAIT151218.filNam)
;
Data.PipeDataAIT151218 pipeDataAIT151218 ;
Modelica.Blocks.Sources.RealExpression m_flow_p3(y=-DataReader.y[7])
;
Modelica.Blocks.Sources.RealExpression m_flow_p4(y=-DataReader.y[8])
;
Modelica.Blocks.Sources.RealExpression m_flow_p2(y=-DataReader.y[6]);
Modelica.Blocks.Sources.RealExpression T_p1(y=DataReader.y[1])
;
Fluid.Sensors.TemperatureTwoPort senTem_p3(
redeclare package Medium = Medium,
m_flow_nominal=m_flow_nominal,
transferHeat=true,
tauHeaTra=tauHeaTra) ;
Fluid.Sensors.TemperatureTwoPort senTem_p2(
redeclare package Medium = Medium,
m_flow_nominal=m_flow_nominal,
transferHeat=true,
tauHeaTra=tauHeaTra) ;
Fluid.Sensors.TemperatureTwoPort senTem_p4(
redeclare package Medium = Medium,
m_flow_nominal=m_flow_nominal,
transferHeat=true,
tauHeaTra=tauHeaTra) ;
Fluid.Sensors.TemperatureTwoPort senTem_p1(
redeclare package Medium = Medium,
m_flow_nominal=m_flow_nominal,
transferHeat=true,
tauHeaTra=tauHeaTra) ;
PlugFlowPipe pip0(
redeclare package Medium = Medium,
dh=0.0825,
dIns=0.045,
kIns=0.024,
length=20,
allowFlowReversal=allowFlowReversal,
nPorts=2,
m_flow_nominal=0.3,
R=1/(2*0.024*Modelica.Constants.pi)*
log(0.18/0.0899) + 1/(2*2.4*Modelica.Constants.pi)
*
log(2/0.18),
thickness=thickness,
cPip=500,
rhoPip=8000,
initDelay=false,
m_flow_start=0) ;
Buildings.Fluid.Sources.Boundary_pT ExcludedBranch(
redeclare package Medium = Medium,
nPorts=1) ;
Buildings.HeatTransfer.Sources.PrescribedTemperature
prescribedTemperature ;
Fluid.Sensors.TemperatureTwoPort senTemIn_p2(
redeclare package Medium = Medium,
m_flow_nominal=m_flow_nominal,
transferHeat=true,
tauHeaTra=tauHeaTra) ;
Modelica.Blocks.Logical.Switch switch
;
Modelica.Blocks.Sources.RealExpression m_flow_zero(y=0)
;
Modelica.Blocks.Logical.LessThreshold lessThreshold(threshold=-0.001)
;
Modelica.Blocks.Logical.Switch switch1
;
Fluid.Sources.MassFlowSource_T Point5(
redeclare package Medium = Medium,
use_m_flow_in=true,
nPorts=1)
;
equation
connect(m_flow_p3.y, Point3.m_flow_in);
connect(Point2.m_flow_in, m_flow_p2.y);
connect(T_p1.y, Point1.T_in);
connect(DataReader.y[5], Point1.m_flow_in);
connect(DataReader.y[9], prescribedTemperature.T);
connect(pip4.heatPort, pip1.heatPort);
connect(pip1.heatPort, pip0.heatPort);
connect(pip1.heatPort, pip2.heatPort);
connect(pip5.heatPort, pip2.heatPort);
connect(pip3.heatPort, pip2.heatPort);
connect(prescribedTemperature.port, pip0.heatPort);
connect(senTem_p2.port_b, Point2.ports[1]);
connect(Point3.ports[1], senTem_p3.port_b);
connect(senTem_p4.port_b, Point4.ports[1]);
connect(Point1.ports[1], senTem_p1.port_b);
connect(senTem_p1.port_a, pip0.port_a);
connect(switch.u1, m_flow_p4.y);
connect(m_flow_zero.y, switch.u3);
connect(switch.y, Point4.m_flow_in);
connect(switch.u2, lessThreshold.y);
connect(lessThreshold.u, m_flow_p4.y);
connect(pip1.port_a, pip0.ports_b[1]);
connect(pip1.ports_b[1], pip4.port_a);
connect(pip5.port_a, pip1.ports_b[2]);
connect(pip4.ports_b[1], senTem_p4.port_a);
connect(Point5.ports[1], pip4.ports_b[2]);
connect(pip5.ports_b[1], senTemIn_p2.port_b);
connect(pip3.port_a, pip5.ports_b[2]);
connect(senTemIn_p2.port_a, pip2.port_a);
connect(pip2.ports_b[1], senTem_p2.port_a);
connect(pip3.ports_b[1], senTem_p3.port_a);
connect(ExcludedBranch.ports[1], pip0.ports_b[2]);
connect(switch1.y, Point5.m_flow_in);
connect(m_flow_p4.y, switch1.u3);
connect(m_flow_zero.y, switch1.u1);
connect(lessThreshold.y, switch1.u2);
end PlugFlowAIT;
Validation against data from Université de Liège
Information
The example contains
experimental data from a real district heating network.
This model compares the results with the original Modelica Standard Library pipes.
The pipes' temperatures are not initialized. Therefore, results of
outflow temperature before approximately the first 10000 seconds should not be
considered.
Test bench schematic
Calibration
There are some uncertainties about the heat loss coefficient between pipe and
surrounding air as well as regarding the heat conductivity of the insulation
material.
With the
given data, the length specific thermal resistance is R = 2.164
((m K)/W), calculated as follows:
R=((1/(2*pipe.kIns)*log((0.0603+2*pipe.dIns)/(0.0603)))+1/(5*(0.0603+2*pipe.dIns)))/Modelica.Constants.pi
U = 1/R = 0.462 W/(m K)
Extends from Modelica.Icons.Example (Icon for runnable examples).
Parameters
Type | Name | Default | Description |
MassFlowRate | m_flow_nominal | 1 | Nominal mass flow rate, used for regularization near zero flow [kg/s] |
Temperature | T_start_in | pipeDataULg.T_start_in + 273... | Initial temperature at pipe inlet [K] |
Temperature | T_start_out | pipeDataULg.T_start_out + 27... | Initial temperature at pipe outlet [K] |
SpecificHeatCapacity | cp_default | Medium.specificHeatCapacityC... | Heat capacity of medium [J/(kg.K)] |
ThermodynamicState | sta_default | Medium.setState_pTX(T=Medium... | Default medium state |
PipeDataULg151202 | pipeDataULg | redeclare Data.PipeDataULg15... | Measurement dataset from ULg (use Change Class... to choose from different experiments) |
Modelica definition
model PlugFlowULg
extends Modelica.Icons.Example;
package Medium =
Buildings.Media.Water;
parameter Modelica.SIunits.MassFlowRate m_flow_nominal=1
;
parameter Modelica.SIunits.Temperature T_start_in=pipeDataULg.T_start_in + 273.15
;
parameter Modelica.SIunits.Temperature T_start_out=pipeDataULg.T_start_out + 273.15
;
parameter Modelica.SIunits.SpecificHeatCapacity cp_default=
Medium.specificHeatCapacityCp(state=sta_default)
;
parameter Medium.ThermodynamicState sta_default=
Medium.setState_pTX(
T=Medium.T_default,
p=Medium.p_default,
X=Medium.X_default) ;
Fluid.Sources.MassFlowSource_T WaterCityNetwork(
redeclare package Medium = Medium,
m_flow=1.245,
use_m_flow_in=true,
nPorts=1) ;
Fluid.HeatExchangers.Heater_T Boiler(
redeclare package Medium = Medium,
m_flow_nominal=1,
dp_nominal=0) ;
Fluid.Sources.Boundary_pT Sewer1(
redeclare package Medium = Medium,
nPorts=1) ;
Fluid.Sensors.TemperatureTwoPort senTem_out(
redeclare package Medium = Medium,
m_flow_nominal=m_flow_nominal,
tau=0,
T_start=T_start_out) ;
Fluid.Sensors.TemperatureTwoPort senTem_in(
redeclare package Medium = Medium,
m_flow_nominal=m_flow_nominal,
tau=0,
T_start=T_start_in) ;
Modelica.Blocks.Sources.CombiTimeTable DataReader(
tableOnFile=true,
tableName="dat",
fileName=pipeDataULg.filNam,
columns=2:pipeDataULg.nCol,
extrapolation=Modelica.Blocks.Types.Extrapolation.HoldLastPoint)
;
Modelica.Blocks.Math.UnitConversions.From_degC Tout
;
Buildings.HeatTransfer.Sources.FixedTemperature TBou(T=295.15)
;
Modelica.Blocks.Math.UnitConversions.From_degC Tin
;
replaceable Data.PipeDataULg151202 pipeDataULg
constrainedby
Data.BaseClasses.PipeDataULg
;
Modelica.Blocks.Math.Gain gain(k=1)
;
PlugFlowPipe pipe(
redeclare package Medium = Medium,
dh=0.05248,
length=39,
dIns(displayUnit="mm") = 0.013,
kIns=0.04,
m_flow_nominal=m_flow_nominal,
thickness=3.9e-3,
T_start_out=T_start_out,
T_start_in=T_start_in,
R=((1/(2*pipe.kIns)*
log((0.0603/2 + pipe.dIns)/(0.0603/2))) + 1/(5*(0.0603
+ 2*pipe.dIns)))/Modelica.Constants.pi,
nPorts=1,
initDelay=true,
m_flow_start=pipeDataULg.m_flowIni,
cPip=500,
rhoPip=8000) ;
Fluid.Sensors.EnthalpyFlowRate senEntOut(
redeclare package Medium = Medium,
m_flow_nominal=m_flow_nominal) ;
Modelica.Blocks.Math.Add heatLossSim(k1=-1)
;
Modelica.Blocks.Continuous.Integrator eneLosInt ;
Fluid.Sensors.EnthalpyFlowRate senEntIn(
redeclare package Medium = Medium,
m_flow_nominal=m_flow_nominal) ;
Modelica.Blocks.Math.Add delT(k2=-1)
;
Modelica.Blocks.Math.Product heaLosMea
;
Modelica.Blocks.Math.Gain gain3(k=cp_default) ;
Modelica.Blocks.Math.Feedback heaLosDiff
;
Modelica.Blocks.Sources.Constant Tamb(k=273 + 18)
;
equation
connect(DataReader.y[3], Tout.u);
connect(DataReader.y[5], Tin.u);
connect(DataReader.y[1], gain.u);
connect(senTem_in.port_a, Boiler.port_b);
connect(Boiler.port_a, WaterCityNetwork.ports[1]);
connect(gain.y, WaterCityNetwork.m_flow_in);
connect(Tin.y, Boiler.TSet);
connect(Sewer1.ports[1], senTem_out.port_b);
connect(senTem_out.port_a, senEntOut.port_b);
connect(senEntOut.port_a, pipe.ports_b[1]);
connect(pipe.port_a, senEntIn.port_b);
connect(senTem_in.port_b, senEntIn.port_a);
connect(TBou.port, pipe.heatPort);
connect(gain.y, gain3.u);
connect(heaLosMea.y, heaLosDiff.u2);
connect(heatLossSim.y, heaLosDiff.u1);
connect(heaLosDiff.y, eneLosInt.u);
connect(delT.u1, Tin.y);
connect(Tout.y, delT.u2);
connect(heaLosMea.u1, gain3.y);
connect(heaLosMea.u2, delT.y);
connect(heatLossSim.u2, senEntIn.H_flow);
connect(heatLossSim.u1, senEntOut.H_flow);
end PlugFlowULg;
Validation model, one having water and the other air
Information
Validation model in which a step input is applied to
the transport of air and water with a species concentration.
Extends from Modelica.Icons.Example (Icon for runnable examples).
Parameters
Type | Name | Default | Description |
Length | length | 20 | Pipe length [m] |
Modelica definition
model TransportWaterAir
extends Modelica.Icons.Example;
package MediumW =
Buildings.Media.Water ;
package MediumA =
Buildings.Media.Air(extraPropertiesNames={"CO2"})
;
parameter Modelica.SIunits.Length length=20 ;
Modelica.Blocks.Sources.Step Tin(
startTime=100,
height=10,
offset=273.15 + 20)
;
Sources.Boundary_pT sin(
redeclare package Medium = MediumW,
T=273.15 + 10,
nPorts=1,
p(displayUnit="Pa") = 101325) ;
Buildings.Fluid.FixedResistances.PlugFlowPipe pip(
redeclare package Medium = MediumW,
nPorts=1,
dIns=0.05,
kIns=0.028,
m_flow_nominal=1,
cPip=500,
thickness=0.0032,
initDelay=true,
m_flow_start=1,
rhoPip=8000,
length=length,
T_start_in=293.15,
T_start_out=293.15) ;
Buildings.Fluid.Sources.MassFlowSource_T sou(
nPorts=1,
redeclare package Medium = MediumW,
use_T_in=true,
m_flow=1) ;
Buildings.Fluid.Sensors.TemperatureTwoPort senTemOutW(
redeclare package Medium = MediumW,
m_flow_nominal=1,
tau=0,
T_start=323.15) ;
Buildings.Fluid.Sensors.TemperatureTwoPort senTemIn(
redeclare package Medium = MediumW,
m_flow_nominal=1,
tau=0,
T_start=323.15) ;
Sources.Boundary_pT sin1(
T=273.15 + 10,
nPorts=1,
p(displayUnit="Pa") = 101325,
redeclare package Medium = MediumA)
;
PlugFlowPipe duc(
nPorts=1,
dIns=0.05,
kIns=0.028,
m_flow_nominal=1,
cPip=500,
thickness=0.0032,
initDelay=true,
m_flow_start=1,
rhoPip=8000,
redeclare package Medium = MediumA,
length=length,
T_start_in=293.15,
T_start_out=293.15) ;
Sources.MassFlowSource_T sou1(
nPorts=1,
use_T_in=true,
redeclare package Medium = MediumA,
use_X_in=true,
use_C_in=true,
m_flow=1) ;
Sensors.TemperatureTwoPort senTemOutA(
m_flow_nominal=1,
tau=0,
redeclare package Medium = MediumA,
T_start=323.15)
;
Sensors.TemperatureTwoPort senTemIn1(
m_flow_nominal=1,
tau=0,
T_start=323.15,
redeclare package Medium = MediumA)
;
Modelica.Blocks.Sources.Step XiIn[2](
each startTime=100,
height={0.01, -0.01},
offset={0.01,0.99}) ;
Modelica.Blocks.Sources.Step CIn[1](
each startTime=100,
each height=0.01,
each offset=1E-3) ;
equation
connect(Tin.y, sou.T_in);
connect(pip.ports_b[1], senTemOutW.port_a);
connect(senTemOutW.port_b, sin.ports[1]);
connect(sou.ports[1], senTemIn.port_a);
connect(senTemIn.port_b, pip.port_a);
connect(duc.ports_b[1],senTemOutA. port_a);
connect(senTemOutA.port_b, sin1.ports[1]);
connect(sou1.ports[1], senTemIn1.port_a);
connect(senTemIn1.port_b, duc.port_a);
connect(sou1.X_in, XiIn.y);
connect(sou1.C_in, CIn.y);
connect(Tin.y, sou1.T_in);
end TransportWaterAir;