model RadiatorEN442_2
"Test model for radiator"
extends Modelica.Icons.Example;
package Medium =
Buildings.Media.ConstantPropertyLiquidWater "Medium model";
parameter Modelica.SIunits.Temperature TRoo = 20+273.15
"Room temperature";
parameter Modelica.SIunits.Power Q_flow_nominal = 500
"Nominal power";
parameter Modelica.SIunits.Temperature T_a_nominal=273.15 + 40
"Radiator inlet temperature at nominal condition";
parameter Modelica.SIunits.Temperature T_b_nominal = 273.15+30
"Radiator outlet temperature at nominal condition";
parameter Modelica.SIunits.MassFlowRate m_flow_nominal=
Q_flow_nominal/(T_a_nominal-T_b_nominal)/Medium.cp_const
"Nominal mass flow rate";
parameter Modelica.SIunits.Pressure dp_nominal = 3000
"Pressure drop at m_flow_nominal";
Buildings.Fluid.Sources.Boundary_pT sou(
nPorts=2,
redeclare package Medium = Medium,
use_p_in=true,
T=T_a_nominal);
Fluid.FixedResistances.FixedResistanceDpM res2(
redeclare package Medium = Medium,
m_flow_nominal=m_flow_nominal,
dp_nominal=dp_nominal);
Fluid.FixedResistances.FixedResistanceDpM res1(
redeclare package Medium = Medium,
m_flow_nominal=m_flow_nominal,
dp_nominal=dp_nominal);
Buildings.Fluid.Sources.Boundary_pT sin(
redeclare package Medium = Medium,
nPorts=2,
p(displayUnit="Pa") = 300000,
T=T_b_nominal)
"Sink";
inner Modelica.Fluid.System system;
Buildings.Fluid.HeatExchangers.Radiators.RadiatorEN442_2 rad1(
redeclare
package Medium =
Medium,
T_a_nominal=T_a_nominal,
T_b_nominal=T_b_nominal,
Q_flow_nominal=Q_flow_nominal,
TAir_nominal=TRoo)
"Radiator";
Buildings.Fluid.HeatExchangers.Radiators.RadiatorEN442_2 rad2(
redeclare package Medium = Medium,
energyDynamics=Modelica.Fluid.Types.Dynamics.SteadyState,
T_a_nominal=T_a_nominal,
T_b_nominal=T_b_nominal,
Q_flow_nominal=Q_flow_nominal,
TAir_nominal=TRoo)
"Radiator";
Buildings.HeatTransfer.Sources.FixedTemperature TBCCon1(T=TRoo);
Buildings.HeatTransfer.Sources.FixedTemperature TBCCon2(T=TRoo);
Modelica.Blocks.Sources.Step step(
startTime=3600,
offset=300000 + dp_nominal,
height=-dp_nominal);
Buildings.HeatTransfer.Sources.FixedTemperature TBCRad2(T=TRoo);
Buildings.HeatTransfer.Sources.FixedTemperature TBCRad1(T=TRoo);
equation
connect(sou.ports[1], rad1.port_a);
connect(sou.ports[2], rad2.port_a);
connect(rad1.port_b, res1.port_a);
connect(rad2.port_b, res2.port_a);
connect(res1.port_b, sin.ports[1]);
connect(res2.port_b, sin.ports[2]);
connect(step.y, sou.p_in);
connect(TBCRad2.port, rad2.heatPortRad);
connect(TBCRad1.port, rad1.heatPortRad);
connect(TBCCon2.port, rad2.heatPortCon);
connect(TBCCon1.port, rad1.heatPortCon);
end RadiatorEN442_2;