Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue1389 detailed house #1404

Open
wants to merge 25 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 16 commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
5c189a7
Create DetailedHouse package and move example models 1-10 into this p…
LoneMeertens Dec 23, 2024
eafe84d
Rename Example 1-10 to DetailedHouse
LoneMeertens Dec 23, 2024
bb83413
Add documentation to new DetailedHouse package
LoneMeertens Dec 23, 2024
d1f32cb
Add image that is a representation of final model
LoneMeertens Dec 23, 2024
821d676
Fix icon sizes
LoneMeertens Dec 23, 2024
8b1630c
Added required models for each DetailedHouse step
LoneMeertens Dec 23, 2024
a98260a
Add more detailed information to the models
LoneMeertens Dec 23, 2024
235aa1b
update naming in reference results (scripts + results)
lucasverleyen Dec 24, 2024
18247d4
test {} for tutorial unit tests
lucasverleyen Dec 24, 2024
2d0e130
revert commit partially
lucasverleyen Dec 24, 2024
a587fcf
restore commit
lucasverleyen Dec 24, 2024
79109b7
remove old file name
lucasverleyen Dec 24, 2024
d6ad814
Change order of Tutorial packages (alphabetical)
jelgerjansen Jan 2, 2025
faff981
For order of Examples package
jelgerjansen Jan 2, 2025
8cca500
Correct reference to mos file in __Dymola_Commands
jelgerjansen Jan 2, 2025
e8f49c5
Fix typo mos file DetailedHouse3
jelgerjansen Jan 2, 2025
7a73f8a
Change diagram coordinate system for DetailedHouse6 to capture the he…
jelgerjansen Jan 2, 2025
65fab4c
put dimensions in italic
LoneMeertens Jan 2, 2025
1e37f37
fixing documentation and syntax suggestions
LoneMeertens Jan 2, 2025
08a2250
Add result plot for DetailedHous1-5
LoneMeertens Jan 2, 2025
16fde4a
Include connection instructions and reference result section in detai…
LoneMeertens Jan 3, 2025
bee17d3
Adding plots of reference results detailed house 6-10
LoneMeertens Jan 8, 2025
9407eb5
Adding reference results and connecting instruction complete for Deta…
LoneMeertens Jan 9, 2025
9d4c306
default zone height of 2.8m used in DetailedHouse1 instead of equalli…
LoneMeertens Jan 9, 2025
8795021
Resolve open comments related to documentation
LoneMeertens Jan 10, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
within IDEAS.Examples.Tutorial;
model Example1 "First example model containing one zone"
within IDEAS.Examples.Tutorial.DetailedHouse;
model DetailedHouse1 "First example model containing one zone"
extends Modelica.Icons.Example;
package Medium = IDEAS.Media.Air "Air medium";

parameter Modelica.Units.SI.Length l=8 "Zone length";
parameter Modelica.Units.SI.Length w=4 "Zone width";
parameter Modelica.Units.SI.Length h=2.7 "Zone height";


//SimInfoManager must be 'inner' at the top level
inner IDEAS.BoundaryConditions.SimInfoManager sim
annotation (Placement(transformation(extent={{-100,80},{-80,100}})));
Expand Down Expand Up @@ -113,12 +112,38 @@ equation
Tolerance=1e-06,
__Dymola_Algorithm="Lsodar"),
__Dymola_Commands(file=
"Resources/Scripts/Dymola/Examples/Tutorial/Example1.mos"
"Resources/Scripts/Dymola/Examples/Tutorial/DetailedHouse/DetailedHouse1.mos"
"Simulate and plot"),
Documentation(info="<html>
<p>
This first example file instantiates a simple building model.
This first example file instantiates a simple building model that consists of one zone, four walls,
a window, a floor and a ceiling. The zone dimensions are 8 m (with walls oriented
LoneMeertens marked this conversation as resolved.
Show resolved Hide resolved
north and south) by 4 m, and the window measures 3 m by 1.4 m. Use the default
zone height of 2.8 m. Apply double glazing and a heavy wall, which provide high thermal mass.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not very specific. Should we refer to the exact types?

</p>
<h4>Required models</h4>
<ul>
<li>
<a href=\"modelica://IDEAS.BoundaryConditions.SimInfoManager\">
IDEAS.BoundaryConditions.SimInfoManager</a>
</li>
<li>
<a href=\"modelica://IDEAS.Buildings.Components.Zone\">
IDEAS.Buildings.Components.Zone</a>
</li>
<li>
<a href=\"modelica://IDEAS.Buildings.Components.OuterWall\">
IDEAS.Buildings.Components.OuterWall</a>
</li>
<li>
<a href=\"modelica://IDEAS.Buildings.Components.Window\">
IDEAS.Buildings.Components.Window</a>
</li>
<li>
<a href=\"modelica://IDEAS.Buildings.Components.SlabOnGround\">
IDEAS.Buildings.Components.SlabOnGround</a>
</li>
</ul>
</html>", revisions="<html>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can update the revision history of each model, with a reference to this pull request or the issue

<ul>
<li>
Expand All @@ -127,4 +152,4 @@ First implementation for the IDEAS crash course.
</li>
</ul>
</html>"));
end Example1;
end DetailedHouse1;
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
within IDEAS.Examples.Tutorial;
model Example10 "Speeding up the code"
extends Example9(
within IDEAS.Examples.Tutorial.DetailedHouse;
model DetailedHouse10 "Speeding up the code"
extends DetailedHouse9(
fanRet(
energyDynamics=Modelica.Fluid.Types.Dynamics.SteadyState, use_riseTime=
false),
Expand Down Expand Up @@ -49,7 +49,11 @@ record HeavyWall "BESTEST heavy wall with idealized wood layer"
IDEAS.Buildings.Validation.Data.Materials.ConcreteBlock(d=0.10)});

end HeavyWall;
annotation (experiment(
annotation (
__Dymola_Commands(file=
"Resources/Scripts/Dymola/Examples/Tutorial/DetailedHouse/DetailedHouse10.mos"
"Simulate and plot"),
experiment(
StartTime=10000000,
StopTime=11000000,
__Dymola_NumberOfIntervals=5000,
Expand Down Expand Up @@ -80,8 +84,5 @@ First implementation for the IDEAS crash course.
<p>
Tuning model and solver for computation time
LoneMeertens marked this conversation as resolved.
Show resolved Hide resolved
</p>
</html>"),
__Dymola_Commands(file=
"Resources/Scripts/Dymola/Examples/Tutorial/Example10.mos"
"Simulate and plot"));
end Example10;
</html>"));
end DetailedHouse10;
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
within IDEAS.Examples.Tutorial;
model Example2 "Adding closed screens"
extends Example1(window(redeclare Buildings.Components.Shading.Screen shaType));
within IDEAS.Examples.Tutorial.DetailedHouse;
model DetailedHouse2 "Adding closed screens"
extends DetailedHouse1(
window(redeclare Buildings.Components.Shading.Screen shaType));
LoneMeertens marked this conversation as resolved.
Show resolved Hide resolved
Modelica.Blocks.Sources.Constant const(k=1)
annotation (Placement(transformation(extent={{-100,-60},{-80,-40}})));
equation
Expand All @@ -12,6 +13,17 @@ equation
This second example file extends the first example and adds a solar shading screen to the window model.
Compare the simulation outputs to see the impact on the zone temperature.
</p>
<h4>Required models</h4>
<ul>
<li>
<a href=\"modelica://Modelica.Blocks.Sources.Constant\">
Modelica.Blocks.Sources.Constant</a>
</li>
<li>
<a href=\"modelica://IDEAS.Buildings.Components.Shading.Screen\">
IDEAS.Buildings.Components.Shading.Screen</a>
</li>
</ul>
</html>", revisions="<html>
<ul>
<li>
Expand All @@ -21,12 +33,12 @@ First implementation for the IDEAS crash course.
</ul>
</html>"),
__Dymola_Commands(file=
"Resources/Scripts/Dymola/Examples/Tutorial/Example2.mos"
"Resources/Scripts/Dymola/Examples/Tutorial/DetailedHouse/DetailedHouse2.mos"
"Simulate and plot"),
experiment(
StartTime=10000000,
StopTime=11000000,
__Dymola_NumberOfIntervals=5000,
Tolerance=1e-06,
__Dymola_Algorithm="Lsodar"));
end Example2;
end DetailedHouse2;
50 changes: 50 additions & 0 deletions IDEAS/Examples/Tutorial/DetailedHouse/DetailedHouse3.mo
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
within IDEAS.Examples.Tutorial.DetailedHouse;
model DetailedHouse3 "Adding occupant and lighting"
extends DetailedHouse2(
zone(
redeclare replaceable Buildings.Components.Occupants.Fixed occNum(nOccFix=1),
redeclare Buildings.Components.OccupancyType.OfficeWork occTyp,
redeclare Buildings.Components.RoomType.Office rooTyp,
redeclare Buildings.Components.LightingType.LED ligTyp,
redeclare Buildings.Components.LightingControl.OccupancyBased ligCtr));
annotation (
Documentation(revisions="<html>
<ul>
<li>
September 18, 2019 by Filip Jorissen:<br/>
First implementation for the IDEAS crash course.
</li>
</ul>
</html>", info="<html>
<p>
This example extends the second example by adding an occupant and lighting model.
Based on the selected options, the system automatically calculates zone heat gains,
relative humidity, and CO2 concentration. The model implements a continuous occupancy
of one person and LED lighting for the zone. The lighting operates when occupants are present.
</p>
<h4>Required models</h4>
<ul>
<li>
<a href=\"modelica://IDEAS.Buildings.Components.Occupants.Fixed\">
IDEAS.Buildings.Components.Occupants.Fixed</a>
</li>
<li>
<a href=\"modelica://IDEAS.Buildings.Components.LightingType.LED\">
IDEAS.Buildings.Components.LightingType.LED</a>
</li>
<li>
<a href=\"modelica://IDEAS.Buildings.Components.LightingControl.OccupancyBased\">
IDEAS.Buildings.Components.LightingControl.OccupancyBased</a>
</li>
</ul>
</html>"),
__Dymola_Commands(file=
"Resources/Scripts/Dymola/Examples/Tutorial/DetailedHouse/DetailedHouse3.mos"
"Simulate and plot"),
experiment(
StartTime=10000000,
StopTime=11000000,
__Dymola_NumberOfIntervals=5000,
Tolerance=1e-06,
__Dymola_Algorithm="Lsodar"));
end DetailedHouse3;
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
within IDEAS.Examples.Tutorial;
model Example4 "Including custom occupant schedule"
extends Example3(zone(redeclare OccSched occNum(k=2)));
within IDEAS.Examples.Tutorial.DetailedHouse;
model DetailedHouse4 "Including custom occupant schedule"
extends DetailedHouse3(
zone(redeclare OccSched occNum(k=2)));

protected
model OccSched "Simple occupancy schedule"
Expand Down Expand Up @@ -28,15 +29,31 @@ First implementation for the IDEAS crash course.
</html>", info="<html>
<p>
This example extends the third example by adding a
custom occupancy model that uses an occupancy schedule.
custom occupancy model that uses an occupancy schedule e that returns an
LoneMeertens marked this conversation as resolved.
Show resolved Hide resolved
occupancy of two during office hours and zero otherwise.
</p>
<h4>Required models</h4>
<ul>
<li>
<a href=\"modelica://IDEAS.Buildings.Components.Occupants.BaseClasses.PartialOccupants\">
IDEAS.Buildings.Components.Occupants.BaseClasses.PartialOccupants</a>
</li>
<li>
<a href=\"modelica://IDEAS.Utilities.Time.CalendarTime\">
IDEAS.Utilities.Time.CalendarTime</a>
</li>
<li>
<a href=\"modelica://Modelica.Blocks.Sources.RealExpression\">
Modelica.Blocks.Sources.RealExpression</a>
</li>
</ul>
</html>"),
__Dymola_Commands(file="Resources/Scripts/Dymola/Examples/Tutorial/Example4.mos"
__Dymola_Commands(file="Resources/Scripts/Dymola/Examples/Tutorial/DetailedHouse/DetailedHouse4.mos"
"Simulate and plot"),
experiment(
StartTime=10000000,
StopTime=11000000,
__Dymola_NumberOfIntervals=5000,
Tolerance=1e-06,
__Dymola_Algorithm="Lsodar"));
end Example4;
end DetailedHouse4;
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
within IDEAS.Examples.Tutorial;
model Example5 "New model with 2 coupled zones"
within IDEAS.Examples.Tutorial.DetailedHouse;
model DetailedHouse5 "New model with 2 coupled zones"
extends Modelica.Icons.Example;
replaceable package Medium = IDEAS.Media.Air "Air medium";

Expand Down Expand Up @@ -78,14 +78,34 @@ First implementation for the IDEAS crash course.
</html>", info="<html>
<p>
This example demonstrates the use of the RectangularZoneTemplate.
The one-zone implementation with one window of example 1 is repeated here as
The one-zone implementation with one window of <a href=\"modelica://IDEAS.Examples.Tutorial.DetailedHouse.DetailedHouse1\">
IDEAS.Examples.Tutorial.DetailedHouse.DetailedHouse1</a> is repeated here as
a two-zone implementation with two windows that are north and south oriented.
Note the different temperature responses of the zones.
</p>
</html>"), experiment(
<h4>Required models</h4>
<ul>
<li>
<a href=\"modelica://IDEAS.BoundaryConditions.SimInfoManager\">
IDEAS.BoundaryConditions.SimInfoManager</a>
</li>
<li>
<a href=\"modelica://IDEAS.Buildings.Components.RectangularZoneTemplate\">
IDEAS.Buildings.Components.RectangularZoneTemplate</a>
</li>
<li>
Construction and glazing records from <a href=\"modelica://IDEAS.Examples.Tutorial.DetailedHouse.DetailedHouse1\">
IDEAS.Examples.Tutorial.DetailedHouse.DetailedHouse1</a>
</li>
</ul>
</html>"),
__Dymola_Commands(file=
"Resources/Scripts/Dymola/Examples/Tutorial/DetailedHouse/DetailedHouse5.mos"
"Simulate and plot"),
experiment(
StartTime=10000000,
StopTime=11000000,
__Dymola_NumberOfIntervals=5000,
Tolerance=1e-06,
__Dymola_Algorithm="Lsodar"));
end Example5;
end DetailedHouse5;
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
within IDEAS.Examples.Tutorial;
model Example6 "Extension of example 5 that adds a heating system"
extends Example5;
within IDEAS.Examples.Tutorial.DetailedHouse;
model DetailedHouse6
"Extension of example 5 that adds a heating system"
extends DetailedHouse5;
package MediumWater = IDEAS.Media.Water "Water Medium";

Fluid.HeatPumps.ScrollWaterToWater heaPum(
Expand Down Expand Up @@ -153,13 +154,16 @@ equation
-30},{184,-30},{184,0}}, color={0,127,255}));
connect(rad.port_b, heaPum.port_a1) annotation (Line(points={{50,-20},{50,-30},
{184,-30},{184,0}}, color={0,127,255}));
annotation (Diagram(coordinateSystem(extent={{-100,-100},{300,100}},
annotation (Diagram(coordinateSystem(extent={{-100,-100},{100,100}},
initialScale=0.1), graphics={Text(
extent={{138,98},{224,90}},
lineColor={28,108,200},
textString="This sets the absolute pressure only"), Line(points={{126,
86},{134,92}}, color={28,108,200})}), Icon(coordinateSystem(
extent={{-100,-100},{300,100}}, initialScale=0.1)),
extent={{-100,-100},{100,100}}, initialScale=0.1)),
__Dymola_Commands(file=
"Resources/Scripts/Dymola/Examples/Tutorial/DetailedHouse/DetailedHouse6.mos"
"Simulate and plot"),
experiment(
StartTime=10000000,
StopTime=11000000,
Expand All @@ -173,8 +177,48 @@ September 18, 2019 by Filip Jorissen:<br/>
First implementation for the IDEAS crash course.
</li>
</ul>
</html>"),
__Dymola_Commands(file=
"Resources/Scripts/Dymola/Examples/Tutorial/Example6.mos"
"Simulate and plot"));
end Example6;
</html>",
info="<html>
<p>
This model extends <a href=\"modelica://IDEAS.Examples.Tutorial.DetailedHouse.DetailedHouse5\">
IDEAS.Examples.Tutorial.DetailedHouse.DetailedHouse5</a> by adding a HVAC system.
The system consists of a water-water heat pump, radiators, a storage tank, circulation
pumps and a low temperature heat source for the heat pump.
</p>
<h4>Required models</h4>
<ul>
<li>
<a href=\"modelica://IDEAS.Fluid.HeatPumps.ScrollWaterToWater\">
IDEAS.Fluid.HeatPumps.ScrollWaterToWater</a>
</li>
<li>
<a href=\"modelica://IDEAS.Fluid.HeatExchangers.Radiators.RadiatorEN442_2\">
IDEAS.Fluid.HeatExchangers.Radiators.RadiatorEN442_2</a>
</li>
<li>
<a href=\"modelica://IDEAS.Fluid.Actuators.Valves.TwoWayTRV\">
IDEAS.Fluid.Actuators.Valves.TwoWayTRV</a>
</li>
<li>
<a href=\"modelica://IDEAS.Fluid.Movers.FlowControlled_dp\">
IDEAS.Fluid.Movers.FlowControlled_dp</a>
</li>
<li>
<a href=\"modelica://IDEAS.Fluid.Sources.Boundary_pT\">
IDEAS.Fluid.Sources.Boundary_pT</a>
</li>
<li>
<a href=\"modelica://IDEAS.Fluid.Storage.Stratified\">
IDEAS.Fluid.Storage.Stratified</a>
</li>
<li>
<a href=\"modelica://Modelica.Blocks.Sources.IntegerConstant\">
Modelica.Blocks.Sources.IntegerConstant</a>
</li>
<li>
<a href=\"modelica://Modelica.Blocks.Continuous.Integrator\">
Modelica.Blocks.Continuous.Integrator</a>
</li>
</ul>
</html>"));
end DetailedHouse6;
Loading