-
Notifications
You must be signed in to change notification settings - Fork 84
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
361 additions
and
361 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,132 +1,132 @@ | ||
within IBPSA.Examples.Tutorial.SimpleHouse; | ||
model SimpleHouse4 "Heating model" | ||
extends SimpleHouse3; | ||
|
||
parameter Modelica.Units.SI.HeatFlowRate QHea_flow_nominal=3000 | ||
"Nominal capacity of heating system"; | ||
parameter Modelica.Units.SI.MassFlowRate mWat_flow_nominal=0.1 | ||
"Nominal mass flow rate for water loop"; | ||
parameter Boolean use_constantHeater=true | ||
"To enable/disable the connection between the constant source and heater"; | ||
|
||
IBPSA.Fluid.HeatExchangers.Radiators.RadiatorEN442_2 rad( | ||
redeclare package Medium = MediumWater, | ||
T_a_nominal=333.15, | ||
T_b_nominal=313.15, | ||
energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial, | ||
allowFlowReversal=false, | ||
Q_flow_nominal=QHea_flow_nominal) "Radiator" | ||
annotation (Placement(transformation(extent={{140,-140},{160,-120}}))); | ||
IBPSA.Fluid.HeatExchangers.HeaterCooler_u heaWat( | ||
redeclare package Medium = MediumWater, | ||
m_flow_nominal=mWat_flow_nominal, | ||
energyDynamics=Modelica.Fluid.Types.Dynamics.SteadyState, | ||
allowFlowReversal=false, | ||
dp_nominal=5000, | ||
Q_flow_nominal=QHea_flow_nominal) "Heater for water circuit" | ||
annotation (Placement(transformation(extent={{60,-140},{80,-120}}))); | ||
IBPSA.Fluid.Movers.FlowControlled_m_flow pum( | ||
redeclare package Medium = MediumWater, | ||
use_inputFilter=false, | ||
m_flow_nominal=mWat_flow_nominal, | ||
energyDynamics=Modelica.Fluid.Types.Dynamics.SteadyState, | ||
allowFlowReversal=false, | ||
nominalValuesDefineDefaultPressureCurve=true, | ||
inputType=IBPSA.Fluid.Types.InputType.Constant) "Pump" | ||
annotation (Placement(transformation(extent={{160,-190},{140,-170}}))); | ||
IBPSA.Fluid.Sources.Boundary_pT bouWat(redeclare package Medium = MediumWater, nPorts=1) | ||
"Pressure bound for water circuit" annotation (Placement(transformation( | ||
extent={{-10,-10},{10,10}}, | ||
origin={20,-180}))); | ||
Modelica.Blocks.Sources.Constant conHea(k=1) | ||
annotation (Placement(transformation(extent={{80,-110},{60,-90}}))); | ||
equation | ||
connect(heaWat.port_b,rad. port_a) annotation (Line(points={{80,-130},{140,-130}}, | ||
color={0,127,255})); | ||
connect(rad.port_b, pum.port_a) annotation (Line(points={{160,-130},{175,-130}, | ||
{175,-180},{160,-180}}, color={0,127,255})); | ||
connect(heaWat.port_a, pum.port_b) annotation (Line(points={{60,-130},{39.75,-130}, | ||
{39.75,-180},{140,-180}}, color={0,127,255})); | ||
connect(rad.heatPortCon, zon.heatPort) annotation (Line(points={{148,-122.8},{ | ||
148,40},{160,40}}, color={191,0,0})); | ||
connect(rad.heatPortRad, walCap.port) annotation (Line(points={{152,-122.8},{152, | ||
1.77636e-15},{160,1.77636e-15}}, color={191,0,0})); | ||
if use_constantHeater then | ||
connect(conHea.y, heaWat.u) annotation (Line(points={{59,-100},{40,-100},{40,-124}, | ||
{58,-124}}, color={0,0,127})); | ||
end if; | ||
connect(bouWat.ports[1], pum.port_b) | ||
annotation (Line(points={{30,-180},{140,-180}},color={0,127,255})); | ||
annotation (Diagram(coordinateSystem(preserveAspectRatio=false, extent={{-220, | ||
-220},{220,220}})), | ||
experiment(Tolerance=1e-6, StopTime=1e+06), | ||
Documentation(revisions="<html> | ||
<ul> | ||
<li> | ||
September 4, 2023, by Jelger Jansen:<br/> | ||
First implementation. | ||
</li> | ||
</ul> | ||
</html>", info="<html> | ||
<p> | ||
The wall temperature (and therefore the room temperature) is quite low. | ||
In this step a heating system is added to resolve this. It consists of a radiator, a pump and a heater. | ||
The radiator has a nominal power of <i>3 kW</i> for an inlet and outlet temperature of the radiator of <i>60°C</i> | ||
and <i>40°C</i>, and a room air and radiative temperature of <i>20°C</i>. | ||
The pump has a (nominal) mass flow rate of <i>0.1 kg/s</i>. | ||
Since the heating system uses water as a heat carrier fluid, | ||
the media for the models in the heating circuit should be set to <i>MediumWater</i>. | ||
</p> | ||
<h4>Required models</h4> | ||
<ul> | ||
<li> | ||
<a href=\"modelica://IBPSA.Fluid.HeatExchangers.Radiators.RadiatorEN442_2\"> | ||
IBPSA.Fluid.HeatExchangers.Radiators.RadiatorEN442_2</a> | ||
</li> | ||
<li> | ||
<a href=\"modelica://IBPSA.Fluid.HeatExchangers.HeaterCooler_u\"> | ||
IBPSA.Fluid.HeatExchangers.HeaterCooler_u</a> | ||
</li> | ||
<li> | ||
<a href=\"modelica://IBPSA.Fluid.Movers.FlowControlled_m_flow\"> | ||
IBPSA.Fluid.Movers.FlowControlled_m_flow</a> | ||
</li> | ||
<li> | ||
<a href=\"modelica://IBPSA.Fluid.Sources.Boundary_pT\"> | ||
IBPSA.Fluid.Sources.Boundary_pT</a> | ||
</li> | ||
<li> | ||
<a href=\"modelica://Modelica.Blocks.Sources.Constant\"> | ||
Modelica.Blocks.Sources.Constant</a> | ||
</li> | ||
</ul> | ||
<h4>Connection instructions</h4> | ||
<p> | ||
The radiator contains one port for convective heat transfer and one for radiative heat transfer. | ||
Connect both in a reasonable way. Since the heating system uses water as a heat carrier fluid, | ||
the media for the models should be set to <i>MediumWater</i>. | ||
</p> | ||
<p> | ||
The <code>Boundary_pT</code> model needs to be used to set an absolute pressure somewhere in the system. | ||
Otherwise the absolute pressure in the system is undefined. | ||
Pressure difference modelling may be disregarded in the heating circuit | ||
since the chosen pump sets a fixed mass flow rate regardless of the pressure drop. | ||
</p> | ||
<p> | ||
Set the heater input to 1, meaning that it will produce 1 times its nominal power. | ||
</p> | ||
<h4>Reference result</h4> | ||
<p> | ||
The result of the air temperature is plotted in the figure below. | ||
The temperature rises very steeply since the wall is relatively well insulated (<i>k=0.04 W/(m*K)</i>) | ||
and the heater is not disabled when it becomes too warm. | ||
</p> | ||
<p align=\"center\"> | ||
<img alt=\"Air temperature as function of time.\" | ||
src=\"modelica://IBPSA/Resources/Images/Examples/Tutorial/SimpleHouse/result4.png\" width=\"1000\"/> | ||
</p> | ||
</html>"), | ||
__Dymola_Commands(file= | ||
"modelica://IBPSA/Resources/Scripts/Dymola/Examples/Tutorial/SimpleHouse/SimpleHouse4.mos" | ||
"Simulate and plot")); | ||
end SimpleHouse4; | ||
within IBPSA.Examples.Tutorial.SimpleHouse; | ||
model SimpleHouse4 "Heating model" | ||
extends SimpleHouse3; | ||
|
||
parameter Modelica.Units.SI.HeatFlowRate QHea_flow_nominal=3000 | ||
"Nominal capacity of heating system"; | ||
parameter Modelica.Units.SI.MassFlowRate mWat_flow_nominal=0.1 | ||
"Nominal mass flow rate for water loop"; | ||
parameter Boolean use_constantHeater=true | ||
"To enable/disable the connection between the constant source and heater"; | ||
|
||
IBPSA.Fluid.HeatExchangers.Radiators.RadiatorEN442_2 rad( | ||
redeclare package Medium = MediumWater, | ||
T_a_nominal=333.15, | ||
T_b_nominal=313.15, | ||
energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial, | ||
allowFlowReversal=false, | ||
Q_flow_nominal=QHea_flow_nominal) "Radiator" | ||
annotation (Placement(transformation(extent={{140,-140},{160,-120}}))); | ||
IBPSA.Fluid.HeatExchangers.HeaterCooler_u heaWat( | ||
redeclare package Medium = MediumWater, | ||
m_flow_nominal=mWat_flow_nominal, | ||
energyDynamics=Modelica.Fluid.Types.Dynamics.SteadyState, | ||
allowFlowReversal=false, | ||
dp_nominal=5000, | ||
Q_flow_nominal=QHea_flow_nominal) "Heater for water circuit" | ||
annotation (Placement(transformation(extent={{60,-140},{80,-120}}))); | ||
IBPSA.Fluid.Movers.FlowControlled_m_flow pum( | ||
redeclare package Medium = MediumWater, | ||
use_inputFilter=false, | ||
m_flow_nominal=mWat_flow_nominal, | ||
energyDynamics=Modelica.Fluid.Types.Dynamics.SteadyState, | ||
allowFlowReversal=false, | ||
nominalValuesDefineDefaultPressureCurve=true, | ||
inputType=IBPSA.Fluid.Types.InputType.Constant) "Pump" | ||
annotation (Placement(transformation(extent={{160,-190},{140,-170}}))); | ||
IBPSA.Fluid.Sources.Boundary_pT bouWat(redeclare package Medium = MediumWater, nPorts=1) | ||
"Pressure bound for water circuit" annotation (Placement(transformation( | ||
extent={{-10,-10},{10,10}}, | ||
origin={20,-180}))); | ||
Modelica.Blocks.Sources.Constant conHea(k=1) | ||
annotation (Placement(transformation(extent={{80,-110},{60,-90}}))); | ||
equation | ||
connect(heaWat.port_b,rad. port_a) annotation (Line(points={{80,-130},{140,-130}}, | ||
color={0,127,255})); | ||
connect(rad.port_b, pum.port_a) annotation (Line(points={{160,-130},{175,-130}, | ||
{175,-180},{160,-180}}, color={0,127,255})); | ||
connect(heaWat.port_a, pum.port_b) annotation (Line(points={{60,-130},{39.75,-130}, | ||
{39.75,-180},{140,-180}}, color={0,127,255})); | ||
connect(rad.heatPortCon, zon.heatPort) annotation (Line(points={{148,-122.8},{ | ||
148,40},{160,40}}, color={191,0,0})); | ||
connect(rad.heatPortRad, walCap.port) annotation (Line(points={{152,-122.8},{152, | ||
1.77636e-15},{160,1.77636e-15}}, color={191,0,0})); | ||
if use_constantHeater then | ||
connect(conHea.y, heaWat.u) annotation (Line(points={{59,-100},{40,-100},{40,-124}, | ||
{58,-124}}, color={0,0,127})); | ||
end if; | ||
connect(bouWat.ports[1], pum.port_b) | ||
annotation (Line(points={{30,-180},{140,-180}},color={0,127,255})); | ||
annotation (Diagram(coordinateSystem(preserveAspectRatio=false, extent={{-220, | ||
-220},{220,220}})), | ||
experiment(Tolerance=1e-6, StopTime=1e+06), | ||
Documentation(revisions="<html> | ||
<ul> | ||
<li> | ||
September 4, 2023, by Jelger Jansen:<br/> | ||
First implementation. | ||
</li> | ||
</ul> | ||
</html>", info="<html> | ||
<p> | ||
The wall temperature (and therefore the room temperature) is quite low. | ||
In this step a heating system is added to resolve this. It consists of a radiator, a pump and a heater. | ||
The radiator has a nominal power of <i>3 kW</i> for an inlet and outlet temperature of the radiator of <i>60°C</i> | ||
and <i>40°C</i>, and a room air and radiative temperature of <i>20°C</i>. | ||
The pump has a (nominal) mass flow rate of <i>0.1 kg/s</i>. | ||
Since the heating system uses water as a heat carrier fluid, | ||
the media for the models in the heating circuit should be set to <i>MediumWater</i>. | ||
</p> | ||
<h4>Required models</h4> | ||
<ul> | ||
<li> | ||
<a href=\"modelica://IBPSA.Fluid.HeatExchangers.Radiators.RadiatorEN442_2\"> | ||
IBPSA.Fluid.HeatExchangers.Radiators.RadiatorEN442_2</a> | ||
</li> | ||
<li> | ||
<a href=\"modelica://IBPSA.Fluid.HeatExchangers.HeaterCooler_u\"> | ||
IBPSA.Fluid.HeatExchangers.HeaterCooler_u</a> | ||
</li> | ||
<li> | ||
<a href=\"modelica://IBPSA.Fluid.Movers.FlowControlled_m_flow\"> | ||
IBPSA.Fluid.Movers.FlowControlled_m_flow</a> | ||
</li> | ||
<li> | ||
<a href=\"modelica://IBPSA.Fluid.Sources.Boundary_pT\"> | ||
IBPSA.Fluid.Sources.Boundary_pT</a> | ||
</li> | ||
<li> | ||
<a href=\"modelica://Modelica.Blocks.Sources.Constant\"> | ||
Modelica.Blocks.Sources.Constant</a> | ||
</li> | ||
</ul> | ||
<h4>Connection instructions</h4> | ||
<p> | ||
The radiator contains one port for convective heat transfer and one for radiative heat transfer. | ||
Connect both in a reasonable way. Since the heating system uses water as a heat carrier fluid, | ||
the media for the models should be set to <i>MediumWater</i>. | ||
</p> | ||
<p> | ||
The <code>Boundary_pT</code> model needs to be used to set an absolute pressure somewhere in the system. | ||
Otherwise the absolute pressure in the system is undefined. | ||
Pressure difference modelling may be disregarded in the heating circuit | ||
since the chosen pump sets a fixed mass flow rate regardless of the pressure drop. | ||
</p> | ||
<p> | ||
Set the heater input to 1, meaning that it will produce 1 times its nominal power. | ||
</p> | ||
<h4>Reference result</h4> | ||
<p> | ||
The result of the air temperature is plotted in the figure below. | ||
The temperature rises very steeply since the wall is relatively well insulated (<i>k=0.04 W/(m*K)</i>) | ||
and the heater is not disabled when it becomes too warm. | ||
</p> | ||
<p align=\"center\"> | ||
<img alt=\"Air temperature as function of time.\" | ||
src=\"modelica://IBPSA/Resources/Images/Examples/Tutorial/SimpleHouse/result4.png\" width=\"1000\"/> | ||
</p> | ||
</html>"), | ||
__Dymola_Commands(file= | ||
"modelica://IBPSA/Resources/Scripts/Dymola/Examples/Tutorial/SimpleHouse/SimpleHouse4.mos" | ||
"Simulate and plot")); | ||
end SimpleHouse4; |
Oops, something went wrong.