diff --git a/.github/workflows/github-actions.yml b/.github/workflows/github-actions.yml
index 5ef21529a0..a3e0e3a432 100644
--- a/.github/workflows/github-actions.yml
+++ b/.github/workflows/github-actions.yml
@@ -6,14 +6,14 @@ on:
pull_request:
jobs:
build:
- runs-on: self-hosted
+ runs-on: blizz
steps:
- run: echo "🎉 The job was automatically triggered by a ${{ github.event_name }} event"
- run: echo "🐧 This job is now running on a ${{ runner.os }} server called tony-de-rekenpony hosted by The Sysis team at KU Leuven"
- run: echo "🔎 The name of your branch is ${{ github.ref }} and your repository is ${{ github.repository }}"
- run: echo "The following commands are used to remove files inside container to ensure cleanup and avoid permission errors"
- run: docker stop dymimg > /dev/null 2>&1 || true
- - run: docker run --name dymimg --detach=true --rm -v /home/actions-runner/_work/IDEAS/IDEAS:/home/developer/IDEAS -w /home/developer/IDEAS -it dymimg
+ - run: docker run --name dymimg --detach=true --rm -v /home/u0148284/actions-runner/_work/IDEAS/IDEAS:/home/developer/IDEAS -w /home/developer/IDEAS -it dymimg
- run: docker exec -t dymimg /bin/bash -c "rm -rf IDEAS && exit"
- run: docker stop dymimg > /dev/null 2>&1 || true
- name: Check out repository code
@@ -21,12 +21,12 @@ jobs:
with:
clean: true
- name: Change permissions of repository folder
- run: chmod -R 777 /home/actions-runner/_work
+ run: chmod -R 777 /home/u0148284/actions-runner/_work
- name: List of files in the repository
run: |
ls ${{ github.workspace }}
test:
- runs-on: self-hosted
+ runs-on: blizz
needs: build
defaults:
run:
@@ -93,4 +93,4 @@ jobs:
- name: Test IDEAS.Examples.Tutorial
run: make test-dymola PACKAGE=\"IDEAS.Examples.Tutorial\" INTERACTIVE=false
- name: Test IDEAS.Examples.TwinHouses
- run: make test-dymola PACKAGE=\"IDEAS.Examples.TwinHouses\" INTERACTIVE=false
\ No newline at end of file
+ run: make test-dymola PACKAGE=\"IDEAS.Examples.TwinHouses\" INTERACTIVE=false
diff --git a/.gitignore b/.gitignore
index 4baf7b6183..e99d8de1b0 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,33 +1,40 @@
-*.log
+# Files and folders below are ignored
+
*.aux
+*.bak-mo
+*.dll
+*.DS_Store
+*.exe
+*.exp
+*.fmu
+*.gz
*.idx
*.ilg
*.ind
-*.out
-*.gz
-*.toc
-*.dll
*.lib
-*.fmu
-*.xml
-*.txt
+*.log
*.mat
-*.exe
-*.exp
-*.rar
-*.bak-mo
-*.DS_Store
+/*.mm
+*.mof
*.mos~
+*.out
+*.rar
+*.toc
+*.txt
+*.xml
+systemScript.py
+.idea/
+/IDEAS backup
+/IDEAS/funnel_comp
+/IDEAS/Inputs
+/IDEAS/*.pyc
+/IDEAS/Resources/drawings.pptx
/Specifications/Specs.synctex
/Specifications/Specs.tcp
/Specifications/Specs.tps
-/IDEAS backup
+
+# The files below are not ignored (hence the "!")
!/Inputs/*.txt
!/IDEAS/Inputs/*.txt
!/IDEAS/Resources/strobe/*.txt
-!/IDEAS/Resources/ReferenceResults/Dymola/*txt
-/IDEAS/Resources/drawings.pptx
-/*.mm
-/IDEAS/*.pyc
-systemScript.py
-/IDEAS/Inputs
+!/IDEAS/Resources/ReferenceResults/Dymola/*.txt
diff --git a/IDEAS/Airflow/Multizone/BaseClasses/DoorDiscretized.mo b/IDEAS/Airflow/Multizone/BaseClasses/DoorDiscretized.mo
index b0b0e4bdcd..d6a29efe78 100644
--- a/IDEAS/Airflow/Multizone/BaseClasses/DoorDiscretized.mo
+++ b/IDEAS/Airflow/Multizone/BaseClasses/DoorDiscretized.mo
@@ -17,9 +17,9 @@ partial model DoorDiscretized
Modelica.Units.SI.Velocity vTop "Velocity at top of opening from A to B";
Modelica.Units.SI.Velocity vBot "Velocity at bottom of opening from A to B";
-protected
- parameter Modelica.Units.SI.Length dh=hOpe/nCom "Height of each compartment";
+ input Modelica.Units.SI.Length dh=hOpe/nCom "Height of each compartment";
+protected
parameter Medium.ThermodynamicState sta_default=Medium.setState_pTX(
T=Medium.T_default,
p=Medium.p_default,
@@ -28,11 +28,11 @@ protected
parameter Modelica.Units.SI.Density rho_default=Medium.density(sta_default)
"Density, used to compute fluid volume";
- parameter Real hAg[nCom](each unit="m2/s2")=
+ input Real hAg[nCom](each unit="m2/s2")=
{Modelica.Constants.g_n*(hA - (i - 0.5)*dh) for i in 1:nCom}
"Product g*h_i for each compartment";
- parameter Real hBg[nCom](each unit="m2/s2")=
+ input Real hBg[nCom](each unit="m2/s2")=
{Modelica.Constants.g_n*(hB - (i - 0.5)*dh) for i in 1:nCom}
"Product g*h_i for each compartment";
Modelica.Units.SI.AbsolutePressure pA[nCom](each nominal=101325)
@@ -118,6 +118,10 @@ using the model for a door that can be open or closed.
revisions="
-
+October 29, 2024, by Klaas De Jonge:
+Unprotected dh and changed prefixes of dh,hAg and hBg to input. This is for #1935.
+
+-
January 8, 2019, by Michael Wetter:
Moved parameter CD from
diff --git a/IDEAS/Airflow/Multizone/CrackOrOperableDoor.mo b/IDEAS/Airflow/Multizone/CrackOrOperableDoor.mo
index 1584fe4e01..9a0b7d28e0 100644
--- a/IDEAS/Airflow/Multizone/CrackOrOperableDoor.mo
+++ b/IDEAS/Airflow/Multizone/CrackOrOperableDoor.mo
@@ -1,12 +1,12 @@
within IDEAS.Airflow.Multizone;
model CrackOrOperableDoor
- "Door model using discretization along height coordinate"
+ "Infiltration or large opening model used for the embeded airflow implementation in IDEAS.Buildings.Components"
extends IDEAS.Fluid.Interfaces.PartialFourPortInterface(
redeclare final package Medium1 = Medium,
redeclare final package Medium2 = Medium,
final allowFlowReversal1=true,
final allowFlowReversal2=true,
- final m1_flow_nominal=10/3600*1.2,
+ final m1_flow_nominal=10/3600*rho_default,
final m2_flow_nominal=m1_flow_nominal,
final m1_flow_small=1E-4*abs(m1_flow_nominal),
final m2_flow_small=1E-4*abs(m2_flow_nominal));
@@ -26,37 +26,40 @@ model CrackOrOperableDoor
parameter BoundaryConditions.Types.InterZonalAirFlow interZonalAirFlowType
"Interzonal air flow type";
- parameter Modelica.Units.SI.PressureDifference dpCloRat(
- min=0,
- displayUnit="Pa") = 50 "Pressure drop at rating condition of closed door"
+ final parameter Modelica.Units.SI.PressureDifference dpCloRat(displayUnit="Pa")=50
+ "Pressure drop at rating condition of closed door"
annotation (Dialog(group="Rating conditions"));
- parameter Modelica.Units.SI.Length h_b1 "Height at port b1";
- parameter Modelica.Units.SI.Length h_b2 = 0 "Height at port b2";
- parameter Modelica.Units.SI.Length h_a1 = 0 "Height at port a1";
- parameter Modelica.Units.SI.Length h_a2 "Height at port a2";
+ parameter Modelica.Units.SI.Length h_b1 "Height at port b1 (hasCavity=false)";
+ parameter Modelica.Units.SI.Length h_b2 = 0 "Height at port b2(hasCavity=false)";
+ parameter Modelica.Units.SI.Length h_a1 = 0 "Height at port a1(hasCavity=false)";
+ parameter Modelica.Units.SI.Length h_a2 "Height at port a2(hasCavity=false)";
+
+ parameter SI.Length hA=(h_a1 + h_b2)/2
+ "Height of reference pressure at port a1 for opening (hasCavity=true) model";
+ parameter SI.Length hB=(h_a2 + h_b1)/2
+ "Height of reference pressure at port b1 for opening (hasCavity=true) model";
- parameter Real CDCloRat(min=0, max=1)=1
+ final parameter Real CDCloRat(min=0, max=1)=1
"Discharge coefficient at rating conditions of closed door"
annotation (Dialog(group="Rating conditions"));
parameter Modelica.Units.SI.Area A_q50 "Surface area for leakage computation (closed door)";
parameter Real q50(unit="m3/(h.m2)") "Surface air tightness";
- parameter Modelica.Units.SI.Area LClo(min=0) = q50*A_q50*1.2/3600 *(1.2/2/dpCloRat)^mClo/CDClo
- "Effective leakage area of closed door"
- annotation (Dialog(group="Closed door"));
+ final parameter Modelica.Units.SI.Area LClo(min=0) = ((q50*A_q50/3600)/(dpCloRat)^mClo)/(((dpCloRat)^(0.5-mClo))*sqrt(2/rho_default))
+ "Effective leakage area of internal wall (when door is fully closed)"
+ annotation (Dialog(group="Crack or Closed door"));
- parameter Real CDOpe=0.65 "Discharge coefficient of open door"
+ parameter Real CDOpe=0.78 "Discharge coefficient of open door"
annotation (Dialog(group="Open door"));
- parameter Real CDClo=0.65 "Discharge coefficient of closed door"
- annotation (Dialog(group="Closed door"));
+
parameter Real mOpe = 0.5 "Flow exponent for door of open door"
annotation (Dialog(group="Open door"));
- parameter Real mClo= 0.65 "Flow exponent for crack of closed door"
- annotation (Dialog(group="Closed door"));
+ parameter Real mClo= 0.65 "Flow exponent for crack or crack of closed door"
+ annotation (Dialog(group="Crack or Closed door"));
- parameter Integer nCom=if abs(hOpe) IDEAS.BoundaryConditions.Types.InterZonalAirFlow.TwoPorts and useDoor and use_y),
"In " +getInstanceName() + ": Cannot use a controllable door unless interZonalAirFlowType == TwoPorts.");
@@ -144,7 +189,7 @@ equation
connect(col_a1.port_b, port_a1) annotation (
Line(points = {{-60, 60}, {-100, 60}}, color = {0, 127, 255}));
connect(y, doo.y) annotation (
- Line(points={{-110,0},{-11,0}}, color = {0, 0, 127}));
+ Line(points={{-110,0},{-13,0}}, color = {0, 0, 127}));
connect(bou.ports[1], port_a2) annotation (
Line(points={{-1,-80},{100,-80},{100,-60}}, color = {0, 127, 255}));
if interZonalAirFlowType <> IDEAS.BoundaryConditions.Types.InterZonalAirFlow.TwoPorts then
@@ -152,23 +197,19 @@ equation
Line(points = {{-10, 60}, {-100, 60}}, color = {0, 127, 255}));
connect(point_m_flow1.port_b, port_b1) annotation (
Line(points = {{10, 60}, {100, 60}}, color = {0, 127, 255}));
- connect(doo.port_b1, port_b1) annotation (
- Line(points = {{10, 6}, {20, 6}, {20, 60}, {100, 60}}, color = {0, 127, 255}));
- connect(doo.port_a1, port_a1) annotation (
- Line(points = {{-10, 6}, {-20, 6}, {-20, 60}, {-100, 60}}, color = {0, 127, 255}));
end if;
connect(constOne.y, doo.y) annotation (
- Line(points={{-47.4,-14},{-32,-14},{-32,0},{-11,0}}, color = {0, 0, 127}));
+ Line(points={{-47.4,-14},{-32,-14},{-32,0},{-13,0}}, color = {0, 0, 127}));
connect(bou.ports[2], port_b2) annotation (
Line(points={{1,-80},{-100,-80},{-100,-60}}, color = {0, 127, 255}));
- connect(doo.port_a1, port_a1) annotation(
- Line(points = {{-10, 6}, {-30, 6}, {-30, 60}, {-100, 60}}, color = {0, 127, 255}));
- connect(doo.port_b1, port_b1) annotation(
- Line(points = {{10, 6}, {30, 6}, {30, 60}, {100, 60}}, color = {0, 127, 255}));
- connect(doo.port_b2, port_b2) annotation(
- Line(points = {{-10, -6}, {-20, -6}, {-20, -34}, {-100, -34}, {-100, -60}}, color = {0, 127, 255}));
- connect(doo.port_a2, port_a2) annotation(
- Line(points = {{10, -6}, {20, -6}, {20, -34}, {100, -34}, {100, -60}}, color = {0, 127, 255}));
+ connect(doo.port_a1, port_a1) annotation (
+ Line(points={{-12,6},{-30,6},{-30,60},{-100,60}}, color = {0, 127, 255}));
+ connect(doo.port_b1, port_b1) annotation (
+ Line(points={{8,6},{30,6},{30,60},{100,60}}, color = {0, 127, 255}));
+ connect(doo.port_b2, port_b2) annotation (
+ Line(points={{-12,-6},{-20,-6},{-20,-34},{-100,-34},{-100,-60}}, color = {0, 127, 255}));
+ connect(doo.port_a2, port_a2) annotation (
+ Line(points={{8,-6},{20,-6},{20,-34},{100,-34},{100,-60}}, color = {0, 127, 255}));
annotation(Documentation(info="
@@ -182,6 +223,10 @@ There is no support for open doors when using only a single fluid port.
revisions="
-
+October 30, 2024, by Klaas De Jonge:
+Changes for column heights,used default density and transition point to laminar flow at low dp.
+
+-
October 20, 2023 by Filip Jorissen:
First documented version.
@@ -189,4 +234,4 @@ First documented version.
"),
Diagram,
Icon(graphics={ Polygon(lineColor = {0, 0, 255}, pattern = LinePattern.None, fillPattern = FillPattern.Solid, points = {{-30, -10}, {-16, -8}, {-16, -14}, {-30, -16}, {-30, -10}}), Line(points = {{-54, 48}, {-36, 48}}), Line(points = {{-54, 20}, {-36, 20}}), Rectangle(fillColor = {255, 255, 255}, pattern = LinePattern.None, fillPattern = FillPattern.Solid, extent = {{-100, 100}, {100, -100}}), Line(points = {{-54, -58}, {-36, -58}}), Rectangle(lineColor = {0, 0, 255}, fillColor = {255, 128, 0}, pattern = LinePattern.None, fillPattern = FillPattern.Solid, extent = {{-46, -16}, {-20, -20}}), Rectangle(lineColor = {0, 0, 255}, fillColor = {85, 75, 55}, pattern = LinePattern.None, fillPattern = FillPattern.Solid, extent = {{-60, 80}, {60, -84}}), Rectangle(fillColor = {215, 215, 215}, fillPattern = FillPattern.Solid, extent = {{-54, 72}, {56, -84}}), Polygon(fillColor = {95, 95, 95}, fillPattern = FillPattern.Solid, points = {{56, 72}, {-36, 66}, {-36, -90}, {56, -84}, {56, 72}}), Rectangle(lineColor = {0, 0, 255}, fillColor = {255, 128, 0}, pattern = LinePattern.None, fillPattern = FillPattern.Solid, extent = {{-100, 2}, {-46, -2}}), Polygon(visible = false, origin = {75, 50}, rotation = 360, lineColor = {0, 128, 255}, fillColor = {0, 128, 255}, fillPattern = FillPattern.Solid, points = {{-5, 10}, {25, 10}, {-5, -10}, {-5, 10}}), Text(textColor = {0, 0, 127}, extent = {{-118, 34}, {-98, 16}}, textString = "y"), Line(points = {{-54, -6}, {-36, -6}}), Line(points = {{-54, -32}, {-36, -32}}), Polygon(visible = false, origin = {-79, -50}, rotation = 360, lineColor = {0, 128, 255}, fillColor = {0, 128, 255}, fillPattern = FillPattern.Solid, points = {{10, 10}, {-20, -10}, {10, -10}, {10, 10}}), Rectangle(lineColor = {0, 0, 255}, fillColor = {255, 128, 0}, pattern = LinePattern.None, fillPattern = FillPattern.Solid, extent = {{-46, 2}, {-40, -16}})}, coordinateSystem(extent = {{-100, -100}, {100, 100}})));
-end CrackOrOperableDoor;
\ No newline at end of file
+end CrackOrOperableDoor;
diff --git a/IDEAS/Airflow/Multizone/Examples/TrickleVentIDEAS.mo b/IDEAS/Airflow/Multizone/Examples/TrickleVentIDEAS.mo
index b7b4982b02..8d9850e881 100644
--- a/IDEAS/Airflow/Multizone/Examples/TrickleVentIDEAS.mo
+++ b/IDEAS/Airflow/Multizone/Examples/TrickleVentIDEAS.mo
@@ -2,27 +2,27 @@ within IDEAS.Airflow.Multizone.Examples;
model TrickleVentIDEAS
"Model with a trickle vent modelled using the models with flow based on tabulated data"
extends IDEAS.Airflow.Multizone.Examples.TrickleVent(west(nPorts=2), east(nPorts=2));
-
+
IDEAS.Airflow.Multizone.TrickleVent vent(
redeclare package Medium = Medium,
- dp_nominal = 10,
- m_flow_nominal = 0.02614,
- use_y = true)
- "Analytic trickle vent implementation" annotation(
+ dp_nominal = 10,
+ m_flow_nominal = 0.02614,
+ use_y = true)
+ "Analytic trickle vent implementation" annotation (
Placement(visible = true, transformation(origin = {20, -70}, extent = {{-10, 10}, {10, -10}}, rotation = 0)));
Modelica.Blocks.Sources.Ramp ramp(
- duration = 1e6,
- height = -1,
- offset = 1,
- startTime = 1592000)
- "Step control signal" annotation(
+ duration = 1e6,
+ height = -1,
+ offset = 1,
+ startTime = 1592000)
+ "Step control signal" annotation (
Placement(visible = true, transformation(origin = {-90, -88}, extent = {{-10, -10}, {10, 10}}, rotation = 0)));
equation
- connect(vent.port_a, east.ports[2]) annotation(
+ connect(vent.port_a, east.ports[2]) annotation (
Line(points = {{10, -70}, {-25, -70}, {-25, -30}, {-30, -30}}, color = {0, 127, 255}));
- connect(vent.port_b, west.ports[2]) annotation(
+ connect(vent.port_b, west.ports[2]) annotation (
Line(points = {{30, -70}, {65, -70}, {65, -30}, {70, -30}}, color = {0, 127, 255}));
- connect(ramp.y, vent.y) annotation(
+ connect(ramp.y, vent.y) annotation (
Line(points = {{-79, -88}, {20.5, -88}, {20.5, -82}, {20, -82}}, color = {0, 0, 127}));
annotation (__Dymola_Commands(file="modelica://IDEAS/Resources/Scripts/Dymola/Airflow/Multizone/Examples/TrickleVentIDEAS.mos"
"Simulate and plot"),
@@ -37,9 +37,7 @@ This model illustrates the use of the models
IDEAS.Airflow.Multizone.Table_V_flow
,
which is an analytic alternative to the table implementation of
-IDEAS.Airflow.Multizone.Table_m_flow for
-
-modelling self regulating inlet vents.
+IDEAS.Airflow.Multizone.Table_m_flow for modelling self regulating inlet vents.
", revisions="
@@ -50,4 +48,4 @@ First implementation.
"),
Diagram);
-end TrickleVentIDEAS;
\ No newline at end of file
+end TrickleVentIDEAS;
diff --git a/IDEAS/Airflow/Multizone/ReversibleDensityColumn.mo b/IDEAS/Airflow/Multizone/MediumColumnReversible.mo
similarity index 95%
rename from IDEAS/Airflow/Multizone/ReversibleDensityColumn.mo
rename to IDEAS/Airflow/Multizone/MediumColumnReversible.mo
index 96360c35bb..6da0ffca15 100644
--- a/IDEAS/Airflow/Multizone/ReversibleDensityColumn.mo
+++ b/IDEAS/Airflow/Multizone/MediumColumnReversible.mo
@@ -1,13 +1,13 @@
within IDEAS.Airflow.Multizone;
-model ReversibleDensityColumn
+model MediumColumnReversible
"Vertical shaft with no friction and no storage of heat and mass, reversible because it can handle negative column heights"
extends IDEAS.Airflow.Multizone.MediumColumn(
- h(min=-Modelica.Constants.inf),
+ h(min=-Modelica.Constants.inf),
final densitySelection = IDEAS.Airflow.Multizone.Types.densitySelection.fromBottom);
// by convention, port_b must be connected to a zone instead of a flow element
// h is allowed to be negative to accomodate for this convention
-
+
annotation (
Icon(graphics={
Line(
@@ -39,4 +39,4 @@ This makes port_a not nececarilly always the top port.
"));
-end ReversibleDensityColumn;
\ No newline at end of file
+end MediumColumnReversible;
diff --git a/IDEAS/Airflow/Multizone/Validation/LargeHorizontalOpening.mo b/IDEAS/Airflow/Multizone/Validation/LargeHorizontalOpening.mo
new file mode 100644
index 0000000000..e9066bc13e
--- /dev/null
+++ b/IDEAS/Airflow/Multizone/Validation/LargeHorizontalOpening.mo
@@ -0,0 +1,225 @@
+within IDEAS.Airflow.Multizone.Validation;
+model LargeHorizontalOpening
+ "Model to verify the flow when a cavity is horizontal and a small pressure difference exists"
+ extends Modelica.Icons.Example;
+ package Medium = IDEAS.Media.Specialized.Air.PerfectGas;
+
+ Orifice Opening_Orifice(
+ redeclare package Medium = Medium,
+ useDefaultProperties=false,
+ dp_turbulent=Opening_CrackOrOperableDoor.dp_turbulent_ope,
+ A=2,
+ CD=0.78) annotation (Placement(transformation(
+ extent={{10,-10},{-10,10}},
+ rotation=270,
+ origin={-118,-24})));
+
+ CrackOrOperableDoor Opening_CrackOrOperableDoor(
+ redeclare package Medium = Medium,
+ wOpe=1,
+ hOpe=2,
+ interZonalAirFlowType=IDEAS.BoundaryConditions.Types.InterZonalAirFlow.TwoPorts,
+ h_b1=0,
+ h_b2=0,
+ h_a1=0,
+ h_a2=0,
+ hA=-1.5,
+ hB=1.5,
+ A_q50=0,
+ q50=0,
+ useDoor=true,
+ use_y=false,
+ inc=0) annotation (Placement(transformation(
+ extent={{-10,-10},{10,10}},
+ rotation=90,
+ origin={60,-20})));
+ Modelica.Blocks.Math.Sum MF_Doormodel(nin=2, k={3600,3600})
+ annotation (Placement(transformation(extent={{4,14},{-16,34}})));
+ Modelica.Blocks.Math.Sum MF_Orifice(nin=1, k={3600})
+ annotation (Placement(transformation(extent={{-180,28},{-200,48}})));
+ Modelica.Units.SI.MassFlowRate OpeningflowDiff=abs(MF_Doormodel.y)-abs(MF_Orifice.y);
+
+protected
+ Fluid.Sensors.MassFlowRate MFsensor_Orifice(
+ redeclare package Medium = Medium) "Mass flow rate sensor" annotation (Placement(transformation(
+ extent={{-10,-10},{10,10}},
+ rotation=90,
+ origin={-118,36})));
+
+ Fluid.Sensors.MassFlowRate Ori_Mixingvol_MF2(
+ redeclare package Medium = Medium) "Mass flow rate sensor" annotation (Placement(transformation(
+ extent={{-10,-10},{10,10}},
+ rotation=90,
+ origin={40,24})));
+ Fluid.MixingVolumes.MixingVolume vol1(
+ redeclare package Medium = Medium,
+ massDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial,
+ T_start=293.15,
+ m_flow_nominal=1e-12,
+ allowFlowReversal=true,
+ V=15,
+ nPorts=4) "Pressure boundary" annotation (Placement(transformation(extent={{-10,10},
+ {10,-10}},
+ rotation=0,
+ origin={-18,-102})));
+ Fluid.MixingVolumes.MixingVolume vol(
+ redeclare package Medium = Medium,
+ massDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial,
+ T_start=293.15,
+ m_flow_nominal=1e-12,
+ allowFlowReversal=true,
+ V=15,
+ nPorts=4) "Pressure boundary" annotation (Placement(transformation(extent={{-10,-10},
+ {10,10}},
+ rotation=0,
+ origin={-20,68})));
+ MediumColumn col2(
+ redeclare package Medium = Medium,
+ h=1.5,
+ densitySelection=IDEAS.Airflow.Multizone.Types.densitySelection.fromTop)
+ annotation (Placement(transformation(extent={{-128,-4},{-108,16}})));
+ MediumColumn col3(
+ redeclare package Medium = Medium,
+ h=1.5,
+ densitySelection=IDEAS.Airflow.Multizone.Types.densitySelection.fromBottom)
+ annotation (Placement(transformation(extent={{-128,-64},{-108,-44}})));
+
+ Orifice ori2(
+ redeclare package Medium = Medium,
+ useDefaultProperties=false,
+ A=0.5,
+ CD=0.6) annotation (Placement(transformation(
+ extent={{10,-10},{-10,10}},
+ rotation=0,
+ origin={90,-148})));
+ MediumColumn col4(
+ redeclare package Medium = Medium,
+ h=1.5,
+ densitySelection=IDEAS.Airflow.Multizone.Types.densitySelection.fromBottom)
+ annotation (Placement(transformation(extent={{-60,80},{-40,100}})));
+ MediumColumn col5(
+ redeclare package Medium = Medium,
+ h=1.5,
+ densitySelection=IDEAS.Airflow.Multizone.Types.densitySelection.fromTop)
+ annotation (Placement(transformation(extent={{-4,-142},{16,-122}})));
+ Orifice ori3(
+ redeclare package Medium = Medium,
+ useDefaultProperties=false,
+ A=0.5,
+ CD=0.6) annotation (Placement(transformation(
+ extent={{-10,-10},{10,10}},
+ rotation=0,
+ origin={50,116})));
+ Modelica.Thermal.HeatTransfer.Sources.FixedTemperature fixedTemperature(T=293.15)
+ annotation (Placement(transformation(extent={{-172,58},{-152,78}})));
+ Fluid.Sensors.MassFlowRate Ori_Mixingvol_MF1(
+ redeclare package Medium = Medium) "Mass flow rate sensor" annotation (Placement(transformation(
+ extent={{-10,-10},{10,10}},
+ rotation=90,
+ origin={72,24})));
+ Fluid.Sources.Boundary_pT bouA1(
+ redeclare package Medium = Medium,
+ X={0,1},
+ p(displayUnit="Pa") = 101325,
+ T=278.15,
+ nPorts=2) "Pressure boundary" annotation (Placement(transformation(extent={{10,10},
+ {-10,-10}},
+ rotation=0,
+ origin={198,172})));
+ MediumColumn col11(
+ redeclare package Medium = Medium,
+ h=10,
+ densitySelection=IDEAS.Airflow.Multizone.Types.densitySelection.fromTop)
+ annotation (Placement(transformation(extent={{144,-80},{172,-52}})));
+ MediumColumn col12(
+ redeclare package Medium = Medium,
+ h=4,
+ densitySelection=IDEAS.Airflow.Multizone.Types.densitySelection.fromTop)
+ annotation (Placement(transformation(extent={{128,122},{156,150}})));
+
+initial equation
+ for i in 1:vol.nPorts loop
+ vol.ports[i].Xi_outflow = {0};
+ end for;
+ for i in 1:vol1.nPorts loop
+ vol1.ports[i].Xi_outflow = {0};
+ end for;
+
+equation
+
+ connect(col3.port_b, vol1.ports[1]) annotation (Line(points={{-118,-64},{-118,
+ -82},{-19.5,-82},{-19.5,-92}},
+ color={0,127,255}));
+ connect(col2.port_a, MFsensor_Orifice.port_a) annotation (Line(points={{-118,16},
+ {-118,26}}, color={0,127,255}));
+ connect(MFsensor_Orifice.port_b, vol.ports[1]) annotation (Line(points={{-118,46},
+ {-118,50},{-21.5,50},{-21.5,58}},
+ color={0,127,255}));
+ connect(vol.ports[2], col4.port_b)
+ annotation (Line(points={{-20.5,58},{-20.5,56},{-22,56},{-22,52},{-50,52},{-50,
+ 80}}, color={0,127,255}));
+ connect(vol1.ports[2], col5.port_a) annotation (Line(points={{-18.5,-92},{-18.5,
+ -90},{-16,-90},{-16,-82},{6,-82},{6,-122}},
+ color={0,127,255}));
+ connect(col5.port_b, ori2.port_b) annotation (Line(points={{6,-142},{6,-148},{
+ 80,-148}}, color={0,127,255}));
+ connect(col4.port_a, ori3.port_a) annotation (Line(points={{-50,100},{-50,116},
+ {40,116}}, color={0,127,255}));
+ connect(fixedTemperature.port, vol.heatPort)
+ annotation (Line(points={{-152,68},{-30,68}},color={191,0,0}));
+ connect(col11.port_a, bouA1.ports[1]) annotation (Line(points={{158,-52},{158,
+ 173},{188,173}}, color={0,127,255}));
+ connect(col12.port_a, bouA1.ports[2]) annotation (Line(points={{142,150},{142,
+ 171},{188,171}}, color={0,127,255}));
+ connect(Opening_CrackOrOperableDoor.port_a2, Ori_Mixingvol_MF1.port_a)
+ annotation (Line(points={{66,-10},{66,8},{72,8},{72,14}}, color={0,127,255}));
+ connect(Opening_CrackOrOperableDoor.port_b1, Ori_Mixingvol_MF2.port_a)
+ annotation (Line(points={{54,-10},{54,8},{40,8},{40,14}}, color={0,127,255}));
+ connect(Ori_Mixingvol_MF2.m_flow, MF_Doormodel.u[1]) annotation (Line(points={{29,24},
+ {18,24},{18,23.5},{6,23.5}}, color={0,0,127}));
+ connect(Ori_Mixingvol_MF1.m_flow, MF_Doormodel.u[2]) annotation (Line(points={{61,24},
+ {56,24},{56,40},{22,40},{22,24},{18,24},{18,24.5},{6,24.5}},
+ color={0,0,127}));
+ connect(MF_Orifice.u[1], MFsensor_Orifice.m_flow)
+ annotation (Line(points={{-178,38},{-154,38},{-154,36},{-129,36}},
+ color={0,0,127}));
+ connect(col3.port_a, Opening_Orifice.port_a) annotation (Line(points={{-118,-44},
+ {-118,-34}}, color={0,127,255}));
+ connect(Opening_Orifice.port_b, col2.port_b) annotation (Line(points={{-118,-14},
+ {-118,-4}}, color={0,127,255}));
+ connect(col12.port_b, ori3.port_b) annotation (Line(points={{142,122},{142,116},
+ {60,116}}, color={0,127,255}));
+ connect(col11.port_b, ori2.port_a) annotation (Line(points={{158,-80},{158,-148},
+ {100,-148}}, color={0,127,255}));
+ connect(fixedTemperature.port, vol1.heatPort) annotation (Line(points={{-152,68},
+ {-76,68},{-76,-102},{-28,-102}}, color={191,0,0}));
+ connect(Opening_CrackOrOperableDoor.port_a1, vol1.ports[3]) annotation (Line(
+ points={{54,-30},{54,-82},{-17.5,-82},{-17.5,-92}}, color={0,127,255}));
+ connect(Opening_CrackOrOperableDoor.port_b2, vol1.ports[4]) annotation (Line(
+ points={{66,-30},{66,-82},{-16.5,-82},{-16.5,-92}}, color={0,127,255}));
+ connect(Ori_Mixingvol_MF2.port_b, vol.ports[3]) annotation (Line(points={{40,34},
+ {40,52},{-19.5,52},{-19.5,58}}, color={0,127,255}));
+ connect(Ori_Mixingvol_MF1.port_b, vol.ports[4]) annotation (Line(points={{72,34},
+ {72,52},{-22,52},{-22,58},{-18.5,58}}, color={0,127,255}));
+ annotation (Diagram(
+ coordinateSystem(preserveAspectRatio=false, extent={{-200,-160},{220,200}})),
+ experiment(
+ StopTime=300,
+ Interval=10,
+ Tolerance=1e-09,
+ __Dymola_Algorithm="Cvode"),
+ __Dymola_Commands(file="modelica://IDEAS/Resources/Scripts/Dymola/Airflow/Multizone/Validation/LargeHorizontalOpening.mos"
+ "Simulate and Plot"),
+ Documentation(revisions="
+
+-
+October 30, 2024, by Klaas De Jonge:
+First implementation.
+
+
+
+", info="
+Differences in assumptions for density calculations linked to stack-effect airflow (internally for door component, external via density columns for orifice) can result in different pressure differences over the opening (10e-3). However, for large horizontal openings this can result in important differences in volume flow results. This example shows how two similar openings with other underlying modelling assumptions lead to noticeable differences in massflowrate.
+"),
+ Icon(coordinateSystem(extent={{-100,-100},{100,100}})));
+end LargeHorizontalOpening;
diff --git a/IDEAS/Airflow/Multizone/Validation/package.order b/IDEAS/Airflow/Multizone/Validation/package.order
index 3b0f6df5f3..afb70eafd3 100644
--- a/IDEAS/Airflow/Multizone/Validation/package.order
+++ b/IDEAS/Airflow/Multizone/Validation/package.order
@@ -1,4 +1,5 @@
DoorOpenClosed
+LargeHorizontalOpening
OneWayFlow
OpenDoorBuoyancyDynamic
OpenDoorBuoyancyPressureDynamic
diff --git a/IDEAS/Airflow/Multizone/package.order b/IDEAS/Airflow/Multizone/package.order
index 08612d5ffb..07a26438fe 100644
--- a/IDEAS/Airflow/Multizone/package.order
+++ b/IDEAS/Airflow/Multizone/package.order
@@ -9,10 +9,10 @@ DoorOperable
EffectiveAirLeakageArea
MediumColumn
MediumColumnDynamic
+MediumColumnReversible
Orifice
Point_m_flow
Points_m_flow
-ReversibleDensityColumn
Table_V_flow
Table_m_flow
TrickleVent
diff --git a/IDEAS/BoundaryConditions/Interfaces/PartialSimInfoManager.mo b/IDEAS/BoundaryConditions/Interfaces/PartialSimInfoManager.mo
index 5d57589e2e..aa0fd11797 100644
--- a/IDEAS/BoundaryConditions/Interfaces/PartialSimInfoManager.mo
+++ b/IDEAS/BoundaryConditions/Interfaces/PartialSimInfoManager.mo
@@ -43,9 +43,9 @@ partial model PartialSimInfoManager
parameter Boolean openSystemConservationOfEnergy=false
"Compute conservation of energy for open system" annotation (Evaluate=true,
Dialog(tab="Conservation of energy", enable=computeConservationOfEnergy));
- parameter Boolean use_port_1 = interZonalAirFlowType <> IDEAS.BoundaryConditions.Types.InterZonalAirFlow.None
+ final parameter Boolean use_port_1 = interZonalAirFlowType <> IDEAS.BoundaryConditions.Types.InterZonalAirFlow.None
"Whether port_1 of the propsbus connector should be used";
- parameter Boolean use_port_2 = interZonalAirFlowType == IDEAS.BoundaryConditions.Types.InterZonalAirFlow.TwoPorts
+ final parameter Boolean use_port_2 = interZonalAirFlowType == IDEAS.BoundaryConditions.Types.InterZonalAirFlow.TwoPorts
"Whether port_2 of the propsbus connector should be used";
parameter Boolean lineariseDymola=false "Linearises building model equations for Dymola linearisation approach"
annotation (Dialog(tab="Linearisation"));
@@ -104,6 +104,9 @@ partial model PartialSimInfoManager
annotation(Dialog(enable=interZonalAirFlowType<>
IDEAS.BoundaryConditions.Types.InterZonalAirFlow.None or unify_n50,group="Interzonal airflow"));
+ parameter Boolean use_sim_Cs =true "if checked, the default Cs of each surface in the building is sim.Cs"
+ annotation(choices(checkBox=true),Dialog(group="Wind"));
+
parameter Modelica.Units.SI.Length H=10 "Building or roof height"
annotation (Dialog(group="Wind"));
parameter Real A0=0.6 "Local terrain constant. 0.6 for Suburban,0.35 for Urban and 1 for Unshielded (Ashrae 1993) "
@@ -113,12 +116,9 @@ partial model PartialSimInfoManager
parameter Modelica.Units.SI.Length Hwind=10
"Height above ground of meteorological wind speed measurement"
annotation (Dialog(group="Wind"));
+ parameter Modelica.Units.SI.Length HPres=1 "Height above ground of meteorological atmospheric pressure measurement" annotation (Dialog(group="Wind"));
parameter Real Cs_coeff = (A0*A0)*((1/Hwind)^(2*a)) "Multiplication factor for Habs"
annotation(Dialog(group="Wind"));
- parameter Modelica.Units.SI.Length Hpres=1 "Height above ground of meteorological ambient pressure measurement"
- annotation(Dialog(group="Wind"));
- constant Modelica.Units.SI.Density rho_default = 1.2 "Default air density"
- annotation(Dialog(group="Wind"));
parameter Real Cs= Cs_coeff*(H^(2*a)) "Wind speed modifier" annotation(Dialog(group="Wind"));
@@ -584,10 +584,18 @@ equation