diff --git a/IDEAS/Airflow/Multizone/CrackOrOperableDoor.mo b/IDEAS/Airflow/Multizone/CrackOrOperableDoor.mo index 9a0b7d28e0..adce24abc8 100644 --- a/IDEAS/Airflow/Multizone/CrackOrOperableDoor.mo +++ b/IDEAS/Airflow/Multizone/CrackOrOperableDoor.mo @@ -151,7 +151,7 @@ model CrackOrOperableDoor hOpe=hOpe, dpCloRat=dpCloRat, LClo=LClo, - vZer=vZer*MFtrans*rho_default) + vZer=MFtrans/(rho_default*doo.wOpe*doo.hOpe)) if useDoor and interZonalAirFlowType == IDEAS.BoundaryConditions.Types.InterZonalAirFlow.TwoPorts annotation ( Placement(visible = true, transformation(origin={-2,0}, extent = {{-10, -10}, {10, 10}}, rotation = 0))); IDEAS.Fluid.Sources.Boundary_pT bou( diff --git a/IDEAS/Buildings/Components/InternalWall.mo b/IDEAS/Buildings/Components/InternalWall.mo index 8002eb5a7a..7db33a1320 100644 --- a/IDEAS/Buildings/Components/InternalWall.mo +++ b/IDEAS/Buildings/Components/InternalWall.mo @@ -81,7 +81,7 @@ model InternalWall "interior opaque wall between two zones" "Discharge coefficient of cavity" annotation(Dialog(group="Cavity or open door",tab="Advanced")); final parameter Real hzone_b(fixed=false); - final parameter Real hfloor_b(fixed=false); + final parameter Real hAbs_floor_b(fixed=false); parameter Modelica.Units.SI.Length hRelSurfBot_b=if @@ -146,16 +146,23 @@ protected initial equation hzone_b = propsBus_b.hzone; - hfloor_b = propsBus_b.hfloor; + hAbs_floor_b = propsBus_b.hfloor; QTra_design=U_value*A*(TRefZon - TRef_b) "TRefZon is the reference temperature for heat loss calculations of the zone connected to propsbus_a, TRef_b is the reference temperature for heat loss calculations of the zone connected to propsBus_b"; + if sim.interZonalAirFlowType == IDEAS.BoundaryConditions.Types.InterZonalAirFlow.None and hasCavity == true then + assert(IDEAS.Utilities.Math.Functions.isAngle(incInt, IDEAS.Types.Tilt.Wall), "In " + getInstanceName() + ": Cavities without airflow are only supported for vertical walls, but inc=" + String(incInt) + ". The model is not accurate.", level = AssertionLevel.warning); + end if; + + if sim.interZonalAirFlowType <> IDEAS.BoundaryConditions.Types.InterZonalAirFlow.None and IDEAS.Utilities.Math.Functions.isAngle(inc,0) then + assert(hAbs_floor_a IDEAS.BoundaryConditions.Types.InterZonalAirFlow.None and IDEAS.Utilities.Math.Functions.isAngle(inc,Modelica.Constants.pi) then + assert(hAbs_floor_a>hAbs_floor_b, getInstanceName()+ " is a floor, but the floor of the zone at probsbus_a (hfloor="+String(hAbs_floor_a) +") does not lie below the floor of zone at probsbus_b (hfloor="+String(hAbs_floor_b) +"), this should be fixed",level=AssertionLevel.error); + end if; + equation connect(constOne.y, crackOrOperableDoor.y); -//assert(IDEAS.Utilities.Math.Functions.isAngle(inc,0) and hAbs_floor_a>hfloor_b, getInstanceName()+ "is a ceiling, but the floor of the zone at probsbus_b lies above the floor of zone at probsbus_a, this is probably a mistake",level=AssertionLevel.warning); -//assert(IDEAS.Utilities.Math.Functions.isAngle(inc,Modelica.Constants.pi) and hAbs_floor_a