diff --git a/IBPSA/Airflow/Multizone/BaseClasses/Door.mo b/IBPSA/Airflow/Multizone/BaseClasses/Door.mo new file mode 100644 index 0000000000..ff629a94be --- /dev/null +++ b/IBPSA/Airflow/Multizone/BaseClasses/Door.mo @@ -0,0 +1,125 @@ +within IBPSA.Airflow.Multizone.BaseClasses; +partial model Door + "Partial door model for bi-directional flow" + extends IBPSA.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 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)); + + replaceable package Medium = + Modelica.Media.Interfaces.PartialMedium "Medium in the component" + annotation (choices( + choice(redeclare package Medium = IBPSA.Media.Air "Moist air"))); + + parameter Modelica.SIunits.Length wOpe=0.9 "Width of opening" + annotation (Dialog(group="Geometry")); + parameter Modelica.SIunits.Length hOpe=2.1 "Height of opening" + annotation (Dialog(group="Geometry")); + + parameter Modelica.SIunits.PressureDifference dp_turbulent( + min=0, + displayUnit="Pa") = 0.01 + "Pressure difference where laminar and turbulent flow relation coincide" + annotation(Dialog(tab="Advanced")); + + Modelica.SIunits.VolumeFlowRate VAB_flow(nominal=0.001) + "Volume flow rate from A to B if positive"; + Modelica.SIunits.VolumeFlowRate VBA_flow(nominal=0.001) + "Volume flow rate from B to A if positive"; + + input Modelica.SIunits.Velocity vAB(nominal=0.01) "Average velocity from A to B"; + input Modelica.SIunits.Velocity vBA(nominal=0.01) "Average velocity from B to A"; + +protected + final parameter Modelica.SIunits.Area AOpe = wOpe*hOpe "Open aperture area"; + + constant Real conTP = IBPSA.Media.Air.dStp*Modelica.Media.IdealGases.Common.SingleGasesData.Air.R + "Conversion factor for converting temperature difference to pressure difference"; + + parameter Medium.ThermodynamicState sta_default=Medium.setState_pTX( + T=Medium.T_default, + p=Medium.p_default, + X=Medium.X_default); + + parameter Modelica.SIunits.Density rho_default=Medium.density(sta_default) + "Density"; + + Modelica.SIunits.VolumeFlowRate VABp_flow(nominal=0.001) + "Volume flow rate from A to B if positive due to static pressure difference"; + Modelica.SIunits.MassFlowRate mABt_flow(nominal=0.001) + "Mass flow rate from A to B if positive due to buoyancy"; + +equation + // Net flow rate + port_a1.m_flow = (rho_default * VABp_flow/2 + mABt_flow); + port_b2.m_flow = (rho_default * VABp_flow/2 - mABt_flow); + + // Average velocity (using the whole orifice area) + VAB_flow = (max(port_a1.m_flow, 0) + max(port_b2.m_flow, 0))/rho_default; + VBA_flow = (max(port_a2.m_flow, 0) + max(port_b1.m_flow, 0))/rho_default; + + // Energy balance (no storage, no heat loss/gain) + port_a1.h_outflow = inStream(port_b1.h_outflow); + port_b1.h_outflow = inStream(port_a1.h_outflow); + port_a2.h_outflow = inStream(port_b2.h_outflow); + port_b2.h_outflow = inStream(port_a2.h_outflow); + + // Mass balance (no storage) + port_a1.m_flow = -port_b1.m_flow; + port_a2.m_flow = -port_b2.m_flow; + + port_a1.Xi_outflow = inStream(port_b1.Xi_outflow); + port_b1.Xi_outflow = inStream(port_a1.Xi_outflow); + port_a2.Xi_outflow = inStream(port_b2.Xi_outflow); + port_b2.Xi_outflow = inStream(port_a2.Xi_outflow); + + // Transport of trace substances + port_a1.C_outflow = inStream(port_b1.C_outflow); + port_b1.C_outflow = inStream(port_a1.C_outflow); + port_a2.C_outflow = inStream(port_b2.C_outflow); + port_b2.C_outflow = inStream(port_a2.C_outflow); + + annotation ( + Icon(graphics={ + Rectangle( + extent={{-60,80},{60,-84}}, + lineColor={0,0,255}, + pattern=LinePattern.None, + fillColor={85,75,55}, + fillPattern=FillPattern.Solid), + Rectangle( + extent={{-54,72},{56,-84}}, + lineColor={0,0,0}, + fillColor={215,215,215}, + fillPattern=FillPattern.Solid), + Polygon( + points={{56,72},{-36,66},{-36,-90},{56,-84},{56,72}}, + lineColor={0,0,0}, + fillColor={95,95,95}, + fillPattern=FillPattern.Solid), + Polygon( + points={{-30,-10},{-16,-8},{-16,-14},{-30,-16},{-30,-10}}, + lineColor={0,0,255}, + pattern=LinePattern.None, + fillColor={0,0,0}, + fillPattern=FillPattern.Solid)}), + Documentation(info=" +

+This is a partial model for the bi-directional air flow through a door. +

+", +revisions=" + +")); +end Door; diff --git a/IBPSA/Airflow/Multizone/BaseClasses/DoorDiscretized.mo b/IBPSA/Airflow/Multizone/BaseClasses/DoorDiscretized.mo index d6ffc0eb59..087a534f30 100644 --- a/IBPSA/Airflow/Multizone/BaseClasses/DoorDiscretized.mo +++ b/IBPSA/Airflow/Multizone/BaseClasses/DoorDiscretized.mo @@ -5,7 +5,9 @@ partial model DoorDiscretized parameter Integer nCom=10 "Number of compartments for the discretization"; - parameter Modelica.SIunits.PressureDifference dp_turbulent(min=0) = 0.01 + parameter Modelica.SIunits.PressureDifference dp_turbulent( + min=0, + displayUnit="Pa") = 0.01 "Pressure difference where laminar and turbulent flow relation coincide. Recommended: 0.01"; Modelica.SIunits.PressureDifference dpAB[nCom](each nominal=1) @@ -93,7 +95,12 @@ equation lineColor={0,0,255}, pattern=LinePattern.None, fillColor={0,0,0}, - fillPattern=FillPattern.Solid)}), + fillPattern=FillPattern.Solid), + Line(points={{-54,48},{-36,48}}, color={0,0,0}), + Line(points={{-54,20},{-36,20}}, color={0,0,0}), + Line(points={{-54,-6},{-36,-6}}, color={0,0,0}), + Line(points={{-54,-58},{-36,-58}}, color={0,0,0}), + Line(points={{-54,-32},{-36,-32}}, color={0,0,0})}), Documentation(info="

This is a partial model for the bi-directional air flow through a door. diff --git a/IBPSA/Airflow/Multizone/BaseClasses/package.order b/IBPSA/Airflow/Multizone/BaseClasses/package.order index eff4802baa..b5aba95f32 100644 --- a/IBPSA/Airflow/Multizone/BaseClasses/package.order +++ b/IBPSA/Airflow/Multizone/BaseClasses/package.order @@ -1,3 +1,4 @@ +Door DoorDiscretized ErrorControl PowerLawResistance diff --git a/IBPSA/Airflow/Multizone/DoorOpen.mo b/IBPSA/Airflow/Multizone/DoorOpen.mo new file mode 100644 index 0000000000..f03486160e --- /dev/null +++ b/IBPSA/Airflow/Multizone/DoorOpen.mo @@ -0,0 +1,212 @@ +within IBPSA.Airflow.Multizone; +model DoorOpen + "Door model for bi-directional air flow between rooms" + extends IBPSA.Airflow.Multizone.BaseClasses.Door( + final vAB = VAB_flow/AOpe, + final vBA = VBA_flow/AOpe); + + parameter Real CD=0.65 "Discharge coefficient" + annotation (Dialog(group="Orifice characteristics")); + + parameter Real m = 0.5 "Flow coefficient" + annotation (Dialog(group="Orifice characteristics")); + + +protected + constant Real gamma(min=1) = 1.5 + "Normalized flow rate where dphi(0)/dpi intersects phi(1)"; + constant Real a = gamma + "Polynomial coefficient for regularized implementation of flow resistance"; + parameter Real b = 1/8*m^2 - 3*gamma - 3/2*m + 35.0/8 + "Polynomial coefficient for regularized implementation of flow resistance"; + parameter Real c = -1/4*m^2 + 3*gamma + 5/2*m - 21.0/4 + "Polynomial coefficient for regularized implementation of flow resistance"; + parameter Real d = 1/8*m^2 - gamma - m + 15.0/8 + "Polynomial coefficient for regularized implementation of flow resistance"; + + parameter Real kVal=CD*AOpe*sqrt(2/rho_default) "Flow coefficient, k = V_flow/ dp^m"; + parameter Real kT = rho_default * CD * AOpe/3 * + sqrt(Modelica.Constants.g_n /(Medium.T_default*conTP) * hOpe) + "Constant coefficient for buoyancy driven air flow rate"; + + parameter Modelica.SIunits.MassFlowRate m_flow_turbulent= + kVal * rho_default * sqrt(dp_turbulent) + "Mass flow rate where regularization to laminar flow occurs for temperature-driven flow"; + +equation + // Air flow rate due to static pressure difference + VABp_flow = IBPSA.Airflow.Multizone.BaseClasses.powerLawFixedM( + k=kVal, + dp=port_a1.p-port_a2.p, + m=m, + a=a, + b=b, + c=c, + d=d, + dp_turbulent=dp_turbulent); + // Air flow rate due to buoyancy + // Because powerLawFixedM requires as an input a pressure difference pa-pb, + // we convert Ta-Tb by multiplying it with rho*R, and we divide + // above the constant expression by (rho*R)^m on the right hand-side of kT. + // Note that here, k is for mass flow rate, whereas in powerLawFixedM, it is for volume flow rate. + // We can use m=0.5 as this is from Bernoulli. + mABt_flow = IBPSA.Fluid.BaseClasses.FlowModels.basicFlowFunction_dp( + k=kT, + dp=conTP*(Medium.temperature(state_a1_inflow)-Medium.temperature(state_a2_inflow)), + m_flow_turbulent=m_flow_turbulent); + + annotation (defaultComponentName="doo", +Documentation(info=" +

+Model for bi-directional air flow through a large opening such as a door. +

+

+In this model, the air flow is composed of two components, +a one-directional bulk air flow +due to static pressure difference in the adjoining two thermal zones, and +a two-directional airflow due to temperature-induced differences in density +of the air in the two thermal zones. +Although turbulent air flow is a nonlinear phenomenon, +the model is based on the simplifying assumption that these two +air flow rates can be superposed. +(Superposition is only exact for laminar flow.) +This assumption is made because +it leads to a simple model and because there is significant uncertainty +and assumptions anyway in such simplified a model for bidirectional flow through a door. +

+

Main equations

+

+The air flow rate due to static pressure difference is +

+

+ V̇ab,p = CD w h (2/ρ0)0.5 Δpm, +

+

+where + is the volumetric air flow rate, +CD is the discharge coefficient, +w and h are the width and height of the opening, +ρ0 is the mass density at the medium default pressure, temperature and humidity, +m is the flow exponent and +Δp = pa - pb is the static pressure difference between +the thermal zones. +For this model explanation, we will assume pa > pb. +For turbulent flow, m=1/2 and for laminar flow m=1. +

+

+The air flow rate due to temperature difference in the thermal zones is +ab,t for flow from thermal zone a to b, +and +ba,t for air flow rate from thermal zone b to a. +The model has two air flow paths to allow bi-directional air flow. +The mass flow rates at these two air flow paths are +

+

+ ṁa1 = ρ0   (+V̇ab,p/2 +   V̇ab,t), +

+

+and, similarly, +

+

+ V̇ba = ρ0   (-V̇ab,p/2 +   V̇ba,t), +

+

+where we simplified the calculation by using the density ρ0. +To calculate ba,t, we again use the density ρ0 +and because of this simplification, we can write +

+

+ ṁab,t = -ṁba,t = ρ0   V̇ab,t + = -ρ0   V̇ba,t, +

+

+from which follows that the neutral height, e.g., the height where the air flow rate due to flow +induced by temperature difference is zero, is at h/2. +Hence, +

+

+V̇ab,t = CD0h/2 w v(z) dz, +

+

+where v(z) is the velocity at height z. From the Bernoulli equation, we obtain +

+

+v(z) = (2 g z Δρ ⁄ ρ0)1/2. +

+

+The density difference can be written as +

+

+ Δρ = ρab + ≈ ρ0 (Tb - Ta) ⁄ T0, +

+

+where we used +ρa = p0 /(R Ta) and +Ta Tb ≈ T02. +Substituting this expression into the integral and integrating from 0 to z yields +

+

+V̇ab,t = 1⁄3 CD w h +(g h ⁄ (R T0 ρ0))1/2 Δp1/2. +

+

+The above equation is equivalent to (6) in Brown and Solvason (1962). +

Main assumptions

+

+The main assumptions are as follows: +

+ +

+From these assumptions follows that the neutral height for buoyancy-driven air flow is at half of the height +of the opening. +

+

Notes

+

+For a more detailed model, use + +IBPSA.Airflow.Multizone.DoorDiscretizedOpen. +

+

References

+ +", +revisions=" + +")); +end DoorOpen; diff --git a/IBPSA/Airflow/Multizone/DoorOperable.mo b/IBPSA/Airflow/Multizone/DoorOperable.mo new file mode 100644 index 0000000000..c67781e56c --- /dev/null +++ b/IBPSA/Airflow/Multizone/DoorOperable.mo @@ -0,0 +1,187 @@ +within IBPSA.Airflow.Multizone; +model DoorOperable + "Door model for bi-directional air flow between rooms that can be open or closed" + extends IBPSA.Airflow.Multizone.BaseClasses.Door( + final vAB = VAB_flow/A, + final vBA = VBA_flow/A); + + parameter Real CDOpe=0.65 "Discharge coefficient of open door" + annotation (Dialog(group="Open door")); + + parameter Real mOpe = 0.5 "Flow exponent for door of open door" + annotation (Dialog(group="Open door")); + + parameter Modelica.SIunits.Area LClo(min=0) + "Effective leakage area of closed door" + annotation (Dialog(group="Closed door")); + + parameter Real mClo= 0.65 "Flow exponent for crack of closed door" + annotation (Dialog(group="Closed door")); + + parameter Modelica.SIunits.PressureDifference dpCloRat(min=0, + displayUnit="Pa") = 4 + "Pressure drop at rating condition of closed door" + annotation (Dialog(group="Closed door rating conditions")); + + parameter Real CDCloRat(min=0, max=1)=1 + "Discharge coefficient at rating conditions of closed door" + annotation (Dialog(group="Closed door rating conditions")); + + Modelica.Blocks.Interfaces.RealInput y(min=0, max=1, unit="1") + "Opening signal, 0=closed, 1=open" + annotation (Placement(transformation(extent={{-120,-10},{-100,10}}), iconTransformation(extent={{-120,-10},{-100,10}}))); + +protected + parameter Real gamma(min=1) = 1.5 + "Normalized flow rate where dphi(0)/dpi intersects phi(1)"; + parameter Real[2] a = {gamma, gamma} + "Polynomial coefficient for regularized implementation of flow resistance"; + parameter Real b[2] = {1/8*m^2 - 3*gamma - 3/2*m + 35.0/8 for m in {mOpe, mClo}} + "Polynomial coefficient for regularized implementation of flow resistance"; + parameter Real c[2] = {-1/4*m^2 + 3*gamma + 5/2*m - 21.0/4 for m in {mOpe, mClo}} + "Polynomial coefficient for regularized implementation of flow resistance"; + parameter Real d[2] = {1/8*m^2 - gamma - m + 15.0/8 for m in {mOpe, mClo}} + "Polynomial coefficient for regularized implementation of flow resistance"; + + parameter Modelica.SIunits.Area AClo = LClo * dpCloRat^(0.5-mClo) "Closed area"; + parameter Real kVal[2]={ + CDOpe *AOpe*sqrt(2/rho_default), + CDCloRat*AClo*sqrt(2/rho_default)} + "Flow coefficient, k = V_flow/ dp^m"; + + parameter Real kT = rho_default * CDOpe * AOpe/3 * + sqrt(Modelica.Constants.g_n /(Medium.T_default*conTP) * hOpe) + "Constant coefficient for buoyancy driven air flow rate"; + + parameter Modelica.SIunits.MassFlowRate m_flow_turbulent= + kVal[1] * rho_default * sqrt(dp_turbulent) + "Mass flow rate where regularization to laminar flow occurs for temperature-driven flow"; + + Modelica.SIunits.VolumeFlowRate VABpOpeClo_flow[2](each nominal=0.001) + "Volume flow rate from A to B if positive due to static pressure difference"; + Modelica.SIunits.VolumeFlowRate VABp_flow(nominal=0.001) + "Volume flow rate from A to B if positive due to static pressure difference"; + + Modelica.SIunits.Area A "Current opening area"; +equation + // Air flow rate due to static pressure difference + VABpOpeClo_flow = IBPSA.Airflow.Multizone.BaseClasses.powerLawFixedM( + k=kVal, + dp=port_a1.p-port_a2.p, + m={mOpe, mClo}, + a=a, + b=b, + c=c, + d=d, + dp_turbulent=dp_turbulent); + VABp_flow = y*VABpOpeClo_flow[1] + (1-y)*VABpOpeClo_flow[2]; + A = y*AOpe + (1-y)*AClo; + // Air flow rate due to buoyancy + // Because powerLawFixedM requires as an input a pressure difference pa-pb, + // we convert Ta-Tb by multiplying it with rho*R, and we divide + // above the constant expression by (rho*R)^m on the right hand-side of kT. + mABt_flow = y*IBPSA.Fluid.BaseClasses.FlowModels.basicFlowFunction_dp( + k=kT, + dp=conTP*(Medium.temperature(state_a1_inflow)-Medium.temperature(state_a2_inflow)), + m_flow_turbulent=m_flow_turbulent); + + annotation (defaultComponentName="doo", +Documentation(info=" +

+Model for bi-directional air flow through a large opening such as a door which can be opened or closed +based on the control input signal y. +

+

+For the control input signal y=1, this model is identical to + +IBPSA.Airflow.Multizone.DoorOpen, and for +y=0, the door is assumed to be closed and the air flow rate is +set to the air flow rate through the crack posed by the open door, clo. +

+The air flow rate for the closed door is computed as +

+

+ V̇clo = kclo ΔpmClo, +

+

+where +clo is the volume flow rate, +kclo is a flow coefficient and +mClo is the flow exponent. +The flow coefficient is +

+

+kclo = Lclo CDCloRat ΔpRat(0.5-mClo) (2/ρ0)0.5, +

+

+where +Lclo is the effective air leakage area, +CDCloRat is the discharge coefficient at the reference condition, +ΔpRat is the pressure drop at the rating condition, and +ρ0 is the mass density at the medium default pressure, temperature and humidity. +

+

+The effective air leakage area Lclo can be obtained, for example, +from the ASHRAE fundamentals (ASHRAE, 1997, p. 25.18). In +the ASHRAE fundamentals, the effective air leakage area is +based on a reference pressure difference of ΔpRat = 4 Pa and a discharge +coefficient of CDCloRat = 1. +A similar model is also used in the CONTAM software (Dols and Walton, 2002). +Dols and Walton (2002) recommend to use for the flow exponent +mClo=0.6 to mClo=0.7 if the flow exponent is not +reported with the test results. +

+

+For the open door, the air flow rate +ope is computed as described in + +IBPSA.Airflow.Multizone.DoorOpen +with the parameters CDOpe and mOpe. +

+

+The actual air flow rate is computed as +

+

+V̇clo = (y-1) V̇clo + y V̇ope, +

+

+where y ∈ [0, 1] is the control signal. +Note that for values of y that are different from 0 and +1, the model simply interpolates the air flow rate between a fully open +and a fully closed door. In practice, the air flow rate would likely increase quickly if the +door is slightly opened, and hence we do not claim that the model is accurate for +values other than y = 0 and y = 1. +

+

References

+ +", +revisions=" + +")); +end DoorOperable; diff --git a/IBPSA/Airflow/Multizone/Examples/OneOpenDoor.mo b/IBPSA/Airflow/Multizone/Examples/OneOpenDoor.mo index e724b684e0..68e349f1c6 100644 --- a/IBPSA/Airflow/Multizone/Examples/OneOpenDoor.mo +++ b/IBPSA/Airflow/Multizone/Examples/OneOpenDoor.mo @@ -4,8 +4,8 @@ model OneOpenDoor "Model with one open and one closed door" package Medium = Modelica.Media.Air.SimpleAir; - IBPSA.Airflow.Multizone.DoorDiscretizedOpen dooOpe(redeclare package Medium - = Medium) "Discretized door" + IBPSA.Airflow.Multizone.DoorDiscretizedOpen dooOpe( + redeclare package Medium = Medium) "Discretized door" annotation (Placement(transformation(extent={{10,-8},{30,12}}))); IBPSA.Fluid.MixingVolumes.MixingVolume volA( diff --git a/IBPSA/Airflow/Multizone/Validation/DoorOpenClosed.mo b/IBPSA/Airflow/Multizone/Validation/DoorOpenClosed.mo new file mode 100644 index 0000000000..09a7f704bb --- /dev/null +++ b/IBPSA/Airflow/Multizone/Validation/DoorOpenClosed.mo @@ -0,0 +1,125 @@ +within IBPSA.Airflow.Multizone.Validation; +model DoorOpenClosed + "Validation model for the operable door and the door that is always open" + extends Modelica.Icons.Example; + + package Medium = IBPSA.Media.Air "Medium model"; + + Fluid.Sources.Boundary_pT bouA( + redeclare package Medium = Medium, + p(displayUnit="Pa") = 101330, + T=294.15, + nPorts=5) "Boundary condition at side a" annotation (Placement( + transformation( + extent={{-10,-10},{10,10}}, + rotation=0, + origin={-70,0}))); + + Fluid.Sources.Boundary_pT bouB( + redeclare package Medium = Medium, + p(displayUnit="Pa") = 101325, + T=293.15, + nPorts=5) "Boundary condition at side b" + annotation (Placement(transformation(extent={{10,-10},{-10,10}}, + rotation=0, + origin={80,0}))); + + IBPSA.Airflow.Multizone.DoorOpen doo( + redeclare package Medium = Medium) + "Open door that is always open" + annotation (Placement(transformation(extent={{-20,40},{0,60}}))); + + EffectiveAirLeakageArea lea( + redeclare package Medium = Medium, + m=0.65, + dp_turbulent=0.01, + L=20*1E-4) "Leakage flow element" + annotation (Placement(transformation(extent={{-20,10},{0,30}}))); + DoorOperable dooOpeClo( + redeclare package Medium = Medium, + LClo=20*1E-4) + "Operable door" + annotation (Placement(transformation(extent={{-20,-40},{0,-20}}))); + Modelica.Blocks.Sources.Step yDoo(startTime=0.5) "Door opening signal" + annotation (Placement(transformation(extent={{-80,-40},{-60,-20}}))); + Fluid.Sensors.MassFlowRate senMasFlo1(redeclare package Medium = Medium) + "Mass flow rate sensor" + annotation (Placement(transformation(extent={{10,-12},{30,8}}))); + Fluid.Sensors.MassFlowRate senMasFlo2( + redeclare package Medium = Medium) + "Mass flow rate sensor" + annotation (Placement(transformation(extent={{30,-46},{50,-26}}))); + Modelica.Blocks.Math.Add mNet_flow(y(final unit="kg/s")) + "Net air flow rate from A to B through the operable door" + annotation (Placement(transformation(extent={{60,32},{80,52}}))); + Modelica.Blocks.Sources.Step yDooCom( + height=-1, + offset=1, + startTime=0.5) "Outputs 1 if door is closed" + annotation (Placement(transformation(extent={{-80,-90},{-60,-70}}))); + Modelica.Blocks.Math.Product mNetClo_flow(y(final unit="kg/s")) + "Mass flow rate if door is closed" + annotation (Placement(transformation(extent={{0,-90},{20,-70}}))); +equation + connect(bouA.ports[1], doo.port_a1) annotation (Line(points={{-60,3.2},{-40,3.2}, + {-40,56},{-20,56}}, color={0,127,255})); + connect(bouA.ports[2], doo.port_b2) annotation (Line(points={{-60,1.6},{-38,1.6}, + {-38,44},{-20,44}}, color={0,127,255})); + connect(bouA.ports[3], lea.port_a) annotation (Line(points={{-60,0},{-36,0},{-36, + 20},{-20,20}}, color={0,127,255})); + connect(bouA.ports[4], dooOpeClo.port_a1) annotation (Line(points={{-60,-1.6}, + {-36,-1.6},{-36,-24},{-20,-24}}, color={0,127,255})); + connect(bouA.ports[5], dooOpeClo.port_b2) annotation (Line(points={{-60,-3.2}, + {-40,-3.2},{-40,-36},{-20,-36}}, color={0,127,255})); + connect(doo.port_b1, bouB.ports[1]) annotation (Line(points={{0,56},{50,56},{50, + 3.2},{70,3.2}}, color={0,127,255})); + connect(doo.port_a2, bouB.ports[2]) annotation (Line(points={{0,44},{48,44},{48, + 1.6},{70,1.6}}, color={0,127,255})); + connect(lea.port_b, bouB.ports[3]) annotation (Line(points={{0,20},{46,20},{46, + 0},{70,0}}, color={0,127,255})); + connect(yDoo.y, dooOpeClo.y) + annotation (Line(points={{-59,-30},{-21,-30}}, color={0,0,127})); + connect(dooOpeClo.port_b1, senMasFlo1.port_a) annotation (Line(points={{0,-24}, + {6,-24},{6,-2},{10,-2}}, color={0,127,255})); + connect(senMasFlo1.port_b, bouB.ports[4]) + annotation (Line(points={{30,-2},{70,-2},{70,-1.6}}, color={0,127,255})); + connect(dooOpeClo.port_a2,senMasFlo2. port_a) + annotation (Line(points={{0,-36},{30,-36}}, color={0,127,255})); + connect(senMasFlo2.port_b, bouB.ports[5]) annotation (Line(points={{50,-36},{62, + -36},{62,-3.2},{70,-3.2}}, color={0,127,255})); + connect(senMasFlo1.m_flow, mNet_flow.u1) + annotation (Line(points={{20,9},{20,48},{58,48}}, color={0,0,127})); + connect(senMasFlo2.m_flow, mNet_flow.u2) + annotation (Line(points={{40,-25},{40,36},{58,36}}, color={0,0,127})); + connect(yDooCom.y, mNetClo_flow.u2) annotation (Line(points={{-59,-80},{-32, + -80},{-32,-86},{-2,-86}}, color={0,0,127})); + connect(mNet_flow.y, mNetClo_flow.u1) annotation (Line(points={{81,42},{94,42}, + {94,-60},{-12,-60},{-12,-74},{-2,-74}}, color={0,0,127})); + annotation ( + __Dymola_Commands(file="modelica://IBPSA/Resources/Scripts/Dymola/Airflow/Multizone/Validation/DoorOpenClosed.mos" + "Simulate and plot"), + experiment( + StopTime=1, + Tolerance=1e-06), + Documentation(info=" +

+This model validates the door model that takes as an input a signal +that determines whether the door is open or closed. +In this validation, the instance dooOpeClo is either open or closed, +depending on its input signal y. +If the door is open, its air flow rate is identical to the air flow rate of the +instance doo. +If the door is closed, its air flow rate is identical to the air flow rate of the +instance lea. +

+", revisions=" + +"), + Diagram(coordinateSystem(extent={{-100,-100},{100,100}})), + Icon(coordinateSystem(extent={{-100,-100},{80,100}}))); +end DoorOpenClosed; diff --git a/IBPSA/Airflow/Multizone/Validation/OpenDoorBuoyancyDynamic.mo b/IBPSA/Airflow/Multizone/Validation/OpenDoorBuoyancyDynamic.mo new file mode 100644 index 0000000000..e30ce7a2d2 --- /dev/null +++ b/IBPSA/Airflow/Multizone/Validation/OpenDoorBuoyancyDynamic.mo @@ -0,0 +1,115 @@ +within IBPSA.Airflow.Multizone.Validation; +model OpenDoorBuoyancyDynamic + "Model with open door and buoyancy driven flow only" + extends Modelica.Icons.Example; + + package Medium = IBPSA.Media.Air "Medium model"; + + IBPSA.Airflow.Multizone.DoorOpen doo( + redeclare package Medium = Medium) + "Door" annotation (Placement(transformation(extent={{-10,-10},{10,10}}))); + + IBPSA.Fluid.Sources.Boundary_pT bou( + redeclare package Medium = Medium, + nPorts=1) "Pressure boundary" + annotation (Placement(transformation(extent={{-50,18},{-30,38}}))); + + Fluid.MixingVolumes.MixingVolume bouA( + redeclare package Medium = Medium, + T_start=292.15, + V=2.5*5*5, + energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial, + massDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial, + m_flow_nominal=0.01, + nPorts=3) "Boundary condition at side a" annotation (Placement( + transformation( + extent={{10,-10},{-10,10}}, + rotation=90, + origin={-40,0}))); + + IBPSA.Fluid.MixingVolumes.MixingVolume bouB( + redeclare package Medium = Medium, + T_start=294.15, + V=2.5*5*5, + energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial, + massDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial, + m_flow_nominal=0.01, + nPorts=2) "Boundary condition at side b" + annotation (Placement(transformation(extent={{-10,-10},{10,10}}, + rotation=270, + origin={40,0}))); + DoorDiscretizedOpen dooDis( + forceErrorControlOnFlow=false, + redeclare package Medium = Medium, + vZer=0.000001) "Door" + annotation (Placement(transformation(extent={{-10,-80},{10,-60}}))); + Fluid.Sources.Boundary_pT bou1( + redeclare package Medium = Medium, + nPorts=1) "Pressure boundary" + annotation (Placement(transformation(extent={{-50,-50},{-30,-30}}))); + Fluid.MixingVolumes.MixingVolume bouADis( + redeclare package Medium = Medium, + T_start=292.15, + V=2.5*5*5, + energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial, + massDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial, + m_flow_nominal=0.01, + nPorts=3) "Boundary condition at side a" annotation (Placement( + transformation( + extent={{10,-10},{-10,10}}, + rotation=90, + origin={-40,-70}))); + Fluid.MixingVolumes.MixingVolume bouBDis( + redeclare package Medium = Medium, + T_start=294.15, + V=2.5*5*5, + energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial, + massDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial, + m_flow_nominal=0.01, + nPorts=2) "Boundary condition at side b" annotation (Placement( + transformation( + extent={{-10,-10},{10,10}}, + rotation=270, + origin={40,-70}))); +equation + connect(doo.port_b1, bouB.ports[1]) + annotation (Line(points={{10,6},{20,6},{20,2},{30,2}}, color={0,127,255})); + connect(doo.port_a2, bouB.ports[2]) annotation (Line(points={{10,-6},{20,-6}, + {20,-2},{30,-2}},color={0,127,255})); + connect(doo.port_a1, bouA.ports[1]) annotation (Line(points={{-10,6},{-20,6}, + {-20,2.66667},{-30,2.66667}}, + color={0,127,255})); + connect(doo.port_b2, bouA.ports[2]) annotation (Line(points={{-10,-6},{-18,-6}, + {-18,-8.88178e-16},{-30,-8.88178e-16}}, color={0,127,255})); + connect(bou.ports[1], bouA.ports[3]) + annotation (Line(points={{-30,28},{-30,-2.66667}}, color={0,127,255})); + connect(bou1.ports[1], bouADis.ports[1]) + annotation (Line(points={{-30,-40},{-30,-67.3333}}, color={0,127,255})); + connect(dooDis.port_a1, bouADis.ports[2]) annotation (Line(points={{-10,-64}, + {-20,-64},{-20,-70},{-30,-70}}, color={0,127,255})); + connect(dooDis.port_b2, bouADis.ports[3]) annotation (Line(points={{-10,-76}, + {-20,-76},{-20,-72.6667},{-30,-72.6667}}, color={0,127,255})); + connect(dooDis.port_b1, bouBDis.ports[1]) annotation (Line(points={{10,-64},{ + 20,-64},{20,-68},{30,-68}}, color={0,127,255})); + connect(dooDis.port_a2, bouBDis.ports[2]) annotation (Line(points={{10,-76},{ + 22,-76},{22,-72},{30,-72}}, color={0,127,255})); + annotation ( + __Dymola_Commands(file="modelica://IBPSA/Resources/Scripts/Dymola/Airflow/Multizone/Validation/OpenDoorBuoyancyDynamic.mos" + "Simulate and plot"), + experiment( + StopTime=14400, + Tolerance=1e-08), + Documentation(info=" +

+This model validates the door model for the situation where there is only buoyancy-driven air flow. +Initially the volume is at a different temperature than the pressure source, leading to an airflow that eventually decays to zero. +

+", revisions=" + +")); +end OpenDoorBuoyancyDynamic; diff --git a/IBPSA/Airflow/Multizone/Validation/OpenDoorBuoyancyPressureDynamic.mo b/IBPSA/Airflow/Multizone/Validation/OpenDoorBuoyancyPressureDynamic.mo new file mode 100644 index 0000000000..a1d863a913 --- /dev/null +++ b/IBPSA/Airflow/Multizone/Validation/OpenDoorBuoyancyPressureDynamic.mo @@ -0,0 +1,114 @@ +within IBPSA.Airflow.Multizone.Validation; +model OpenDoorBuoyancyPressureDynamic + "Model with open door and buoyancy and pressure driven flow" + extends Modelica.Icons.Example; + + package Medium = IBPSA.Media.Air "Medium model"; + + IBPSA.Airflow.Multizone.DoorOpen doo(redeclare package Medium = Medium) + "Door" annotation (Placement(transformation(extent={{-10,-10},{10,10}}))); + + IBPSA.Fluid.Sources.Boundary_pT bou( + redeclare package Medium = Medium, + nPorts=1) "Pressure boundary" + annotation (Placement(transformation(extent={{-50,-46},{-30,-26}}))); + + Fluid.MixingVolumes.MixingVolume bouA( + redeclare package Medium = Medium, + T_start=292.15, + V=2.5*5*5, + energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial, + massDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial, + m_flow_nominal=0.01, + nPorts=3) "Boundary condition at side a" annotation (Placement( + transformation( + extent={{-10,-10},{10,10}}, + rotation=90, + origin={-40,0}))); + + IBPSA.Fluid.MixingVolumes.MixingVolume bouB( + redeclare package Medium = Medium, + T_start=294.15, + p_start=101320, + V=2.5*5*5, + energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial, + massDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial, + m_flow_nominal=0.01, + nPorts=2) "Boundary condition at side b" + annotation (Placement(transformation(extent={{-10,-10},{10,10}}, + rotation=270, + origin={40,0}))); + DoorDiscretizedOpen dooDis(redeclare package Medium = Medium) "Door" + annotation (Placement(transformation(extent={{-10,66},{10,86}}))); + Fluid.Sources.Boundary_pT bouDis(redeclare package Medium = Medium, nPorts=1) + "Pressure boundary" + annotation (Placement(transformation(extent={{-50,30},{-30,50}}))); + Fluid.MixingVolumes.MixingVolume bouADis( + redeclare package Medium = Medium, + T_start=292.15, + V=2.5*5*5, + energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial, + massDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial, + m_flow_nominal=0.01, + nPorts=3) "Boundary condition at side a" annotation (Placement( + transformation( + extent={{-10,-10},{10,10}}, + rotation=90, + origin={-40,76}))); + Fluid.MixingVolumes.MixingVolume bouBDis( + redeclare package Medium = Medium, + T_start=294.15, + p_start=101320, + V=2.5*5*5, + energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial, + massDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial, + m_flow_nominal=0.01, + nPorts=2) "Boundary condition at side b" annotation (Placement( + transformation( + extent={{-10,-10},{10,10}}, + rotation=270, + origin={40,76}))); +equation + connect(doo.port_b1, bouB.ports[1]) + annotation (Line(points={{10,6},{20,6},{20,2},{30,2}}, color={0,127,255})); + connect(doo.port_a2, bouB.ports[2]) annotation (Line(points={{10,-6},{20,-6}, + {20,-2},{30,-2}},color={0,127,255})); + connect(doo.port_a1, bouA.ports[1]) annotation (Line(points={{-10,6},{-20,6},{ + -20,-2.66667},{-30,-2.66667}}, + color={0,127,255})); + connect(doo.port_b2, bouA.ports[2]) annotation (Line(points={{-10,-6},{-20,-6}, + {-20,-4.44089e-16},{-30,-4.44089e-16}}, color={0,127,255})); + connect(bou.ports[1], bouA.ports[3]) + annotation (Line(points={{-30,-36},{-30,2.66667}}, color={0,127,255})); + + + connect(dooDis.port_b1, bouBDis.ports[1]) annotation (Line(points={{10,82},{ + 20,82},{20,78},{30,78}}, color={0,127,255})); + connect(dooDis.port_a2, bouBDis.ports[2]) annotation (Line(points={{10,70},{ + 20,70},{20,74},{30,74}}, color={0,127,255})); + connect(dooDis.port_a1, bouADis.ports[1]) annotation (Line(points={{-10,82},{ + -20,82},{-20,73.3333},{-30,73.3333}}, color={0,127,255})); + connect(dooDis.port_b2, bouADis.ports[2]) annotation (Line(points={{-10,70},{ + -20,70},{-20,76},{-30,76}}, color={0,127,255})); + connect(bouDis.ports[1], bouADis.ports[3]) + annotation (Line(points={{-30,40},{-30,78.6667}}, color={0,127,255})); + annotation ( + __Dymola_Commands(file="modelica://IBPSA/Resources/Scripts/Dymola/Airflow/Multizone/Validation/OpenDoorBuoyancyPressureDynamic.mos" + "Simulate and plot"), + experiment( + StopTime=14400, + Tolerance=1e-08), + Documentation(info=" +

+This model validates the door model for the situation where there is air flow due to buoyancy and static pressure difference. +Initially the volumes are at a different temperatures and pressure, leading to an airflow that eventually decays to zero. +

+", revisions=" + +")); +end OpenDoorBuoyancyPressureDynamic; diff --git a/IBPSA/Airflow/Multizone/Validation/OpenDoorPressure.mo b/IBPSA/Airflow/Multizone/Validation/OpenDoorPressure.mo new file mode 100644 index 0000000000..84c4560f4a --- /dev/null +++ b/IBPSA/Airflow/Multizone/Validation/OpenDoorPressure.mo @@ -0,0 +1,96 @@ +within IBPSA.Airflow.Multizone.Validation; +model OpenDoorPressure + "Model with one open door and only pressure-driven flow" + extends Modelica.Icons.Example; + + package Medium = IBPSA.Media.Air "Medium model"; + + IBPSA.Airflow.Multizone.DoorOpen doo( + redeclare package Medium = Medium) + "Door" annotation (Placement(transformation(extent={{-10,-10},{10,10}}))); + + Fluid.Sources.Boundary_pT bouA( + redeclare package Medium = Medium, + p(displayUnit="Pa") = 101325, + nPorts=4) "Boundary condition at side a" annotation (Placement( + transformation( + extent={{-10,-10},{10,10}}, + rotation=0, + origin={-40,0}))); + + Fluid.Sources.Boundary_pT bouB( + redeclare package Medium = Medium, + use_p_in=true, + p(displayUnit="Pa"), + nPorts=4) "Boundary condition at side b" + annotation (Placement(transformation(extent={{10,-10},{-10,10}}, + rotation=0, + origin={40,0}))); + + DoorDiscretizedOpen dooDis( + redeclare package Medium = Medium, + hA=2.1/2, + hB=2.1/2) "Door" + annotation (Placement(transformation(extent={{-10,-40},{10,-20}}))); + Modelica.Blocks.Sources.TimeTable bouPre( + table=[ + 0.0,0; + 1,0; + 1,5; + 2,5; + 2,10; + 3,10; + 3,15; + 4,15; + 4,20; + 5,20; + 5,25; + 6,25; + 6,30; + 7,30; + 7,35; + 8,35; + 8,40; + 24,40], + timeScale=3600, + offset=101325-20) "Pressure boundary condition" + annotation (Placement(transformation(extent={{86,-2},{66,18}}))); +equation + connect(doo.port_b1, bouB.ports[1]) + annotation (Line(points={{10,6},{20,6},{20,3},{30,3}}, color={0,127,255})); + connect(doo.port_a2, bouB.ports[2]) annotation (Line(points={{10,-6},{20,-6}, + {20,1},{30,1}}, color={0,127,255})); + connect(doo.port_a1, bouA.ports[1]) annotation (Line(points={{-10,6},{-20,6}, + {-20,3},{-30,3}}, color={0,127,255})); + connect(doo.port_b2, bouA.ports[2]) annotation (Line(points={{-10,-6},{-20,-6}, + {-20,1},{-30,1}}, color={0,127,255})); + connect(bouA.ports[3], dooDis.port_a1) annotation (Line(points={{-30,-1},{-22, + -1},{-22,-24},{-10,-24}}, color={0,127,255})); + connect(bouA.ports[4], dooDis.port_b2) annotation (Line(points={{-30,-3},{-24, + -3},{-24,-36},{-10,-36}}, color={0,127,255})); + connect(dooDis.port_b1, bouB.ports[3]) annotation (Line(points={{10,-24},{22, + -24},{22,-1},{30,-1}}, color={0,127,255})); + connect(dooDis.port_a2, bouB.ports[4]) annotation (Line(points={{10,-36},{24, + -36},{24,-3},{30,-3}}, color={0,127,255})); + connect(bouPre.y, bouB.p_in) + annotation (Line(points={{65,8},{52,8}}, color={0,0,127})); + annotation ( + __Dymola_Commands(file="modelica://IBPSA/Resources/Scripts/Dymola/Airflow/Multizone/Validation/OpenDoorPressure.mos" + "Simulate and plot"), + experiment( + StopTime=28800, + Interval=600, + Tolerance=1e-06), + Documentation(info=" +

+This model validates the door model for the situation where there is only pressure-driven air flow. +

+", revisions=" + +")); +end OpenDoorPressure; diff --git a/IBPSA/Airflow/Multizone/Validation/OpenDoorTemperature.mo b/IBPSA/Airflow/Multizone/Validation/OpenDoorTemperature.mo new file mode 100644 index 0000000000..dbf8e453b4 --- /dev/null +++ b/IBPSA/Airflow/Multizone/Validation/OpenDoorTemperature.mo @@ -0,0 +1,94 @@ +within IBPSA.Airflow.Multizone.Validation; +model OpenDoorTemperature + "Model with one open door and only temperature-driven flow" + extends Modelica.Icons.Example; + + package Medium = IBPSA.Media.Air "Medium model"; + + IBPSA.Airflow.Multizone.DoorOpen doo( + redeclare package Medium = Medium) + "Door" annotation (Placement(transformation(extent={{-10,-10},{10,10}}))); + + Fluid.Sources.Boundary_pT bouA( + redeclare package Medium = Medium, + nPorts=4) "Boundary condition at side a" annotation (Placement( + transformation( + extent={{-10,-10},{10,10}}, + rotation=0, + origin={-40,0}))); + + Fluid.Sources.Boundary_pT bouB( + redeclare package Medium = Medium, + use_T_in=true, + nPorts=4) "Boundary condition at side b" + annotation (Placement(transformation(extent={{10,-10},{-10,10}}, + rotation=0, + origin={40,0}))); + + DoorDiscretizedOpen dooDis( + redeclare package Medium = Medium, + hA=2.1/2, + hB=2.1/2) "Door" + annotation (Placement(transformation(extent={{-10,-40},{10,-20}}))); + Modelica.Blocks.Sources.TimeTable bouTem( + table=[ + 0.0,0; + 1,0; + 1,5; + 2,5; + 2,10; + 3,10; + 3,15; + 4,15; + 4,20; + 5,20; + 5,25; + 6,25; + 6,30; + 7,30; + 7,35; + 8,35; + 8,40; + 24,40], + timeScale=3600, + offset=273.15) "Temperature boundary condition" + annotation (Placement(transformation(extent={{86,-6},{66,14}}))); +equation + connect(doo.port_b1, bouB.ports[1]) + annotation (Line(points={{10,6},{20,6},{20,3},{30,3}}, color={0,127,255})); + connect(doo.port_a2, bouB.ports[2]) annotation (Line(points={{10,-6},{20,-6}, + {20,1},{30,1}}, color={0,127,255})); + connect(doo.port_a1, bouA.ports[1]) annotation (Line(points={{-10,6},{-20,6}, + {-20,3},{-30,3}}, color={0,127,255})); + connect(doo.port_b2, bouA.ports[2]) annotation (Line(points={{-10,-6},{-20,-6}, + {-20,1},{-30,1}}, color={0,127,255})); + connect(bouA.ports[3], dooDis.port_a1) annotation (Line(points={{-30,-1},{-22, + -1},{-22,-24},{-10,-24}}, color={0,127,255})); + connect(bouA.ports[4], dooDis.port_b2) annotation (Line(points={{-30,-3},{-24, + -3},{-24,-36},{-10,-36}}, color={0,127,255})); + connect(dooDis.port_b1, bouB.ports[3]) annotation (Line(points={{10,-24},{22, + -24},{22,-1},{30,-1}}, color={0,127,255})); + connect(dooDis.port_a2, bouB.ports[4]) annotation (Line(points={{10,-36},{24, + -36},{24,-3},{30,-3}}, color={0,127,255})); + connect(bouTem.y, bouB.T_in) + annotation (Line(points={{65,4},{52,4}}, color={0,0,127})); + annotation ( + __Dymola_Commands(file="modelica://IBPSA/Resources/Scripts/Dymola/Airflow/Multizone/Validation/OpenDoorTemperature.mos" + "Simulate and plot"), + experiment( + StopTime=28800, + Interval=600, + Tolerance=1e-06), + Documentation(info=" +

+This model validates the door model for the situation where there is only temperature-driven air flow. +

+", revisions=" + +")); +end OpenDoorTemperature; diff --git a/IBPSA/Airflow/Multizone/Validation/ThreeRoomsContam.mo b/IBPSA/Airflow/Multizone/Validation/ThreeRoomsContam.mo index 6685073d89..90aee916cd 100644 --- a/IBPSA/Airflow/Multizone/Validation/ThreeRoomsContam.mo +++ b/IBPSA/Airflow/Multizone/Validation/ThreeRoomsContam.mo @@ -12,25 +12,30 @@ model ThreeRoomsContam nPorts=5, m_flow_nominal=0.001, energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial) + "Air volume east room" annotation (Placement(transformation(extent={{80,-20},{100,0}}))); IBPSA.Airflow.Multizone.Orifice oriOutBot( redeclare package Medium = Medium, A=0.01, - m=0.5) annotation (Placement(transformation(extent={{142,-90},{162,-70}}))); + m=0.5) "Orifice at bottom of facade" + annotation (Placement(transformation(extent={{142,-90},{162,-70}}))); IBPSA.Airflow.Multizone.MediumColumn colOutTop( redeclare package Medium = Medium, h=1.5, densitySelection=IBPSA.Airflow.Multizone.Types.densitySelection.fromBottom) + "Medium column for bottom floor outside air" annotation (Placement(transformation(extent={{191,-8},{211,12}}))); IBPSA.Airflow.Multizone.Orifice oriOutTop( redeclare package Medium = Medium, A=0.01, - m=0.5) annotation (Placement(transformation(extent={{141,10},{161,30}}))); + m=0.5) "Orifice at top of facade" + annotation (Placement(transformation(extent={{141,10},{161,30}}))); IBPSA.Airflow.Multizone.MediumColumn colEasInTop( redeclare package Medium = Medium, h=1.5, densitySelection=IBPSA.Airflow.Multizone.Types.densitySelection.fromBottom) + "Medium column for bottom floor" annotation (Placement(transformation(extent={{121,-10},{141,10}}))); IBPSA.Fluid.Sources.Boundary_pT volOut( redeclare package Medium = Medium, @@ -43,21 +48,25 @@ model ThreeRoomsContam redeclare package Medium = Medium, h=1.5, densitySelection=IBPSA.Airflow.Multizone.Types.densitySelection.fromTop) + "Medium column for bottom floor" annotation (Placement(transformation(extent={{122,-70},{142,-50}}))); IBPSA.Airflow.Multizone.MediumColumn colOutBot( redeclare package Medium = Medium, h=1.5, densitySelection=IBPSA.Airflow.Multizone.Types.densitySelection.fromTop) + "Medium column for bottom floor outside air" annotation (Placement(transformation(extent={{190,-68},{210,-48}}))); IBPSA.Airflow.Multizone.MediumColumn colWesBot( redeclare package Medium = Medium, h=1.5, densitySelection=IBPSA.Airflow.Multizone.Types.densitySelection.fromBottom) + "Medium column for bottom floor" annotation (Placement(transformation(extent={{-70,9},{-50,29}}))); IBPSA.Airflow.Multizone.Orifice oriWesTop( redeclare package Medium = Medium, m=0.5, - A=0.01) annotation (Placement(transformation( + A=0.01) "Orifice between top and bottom west floor" + annotation (Placement(transformation( origin={-60,49}, extent={{-10,-10},{10,10}}, rotation=270))); @@ -66,18 +75,17 @@ model ThreeRoomsContam redeclare package Medium = Medium, h=1.5, densitySelection=IBPSA.Airflow.Multizone.Types.densitySelection.fromTop) + "Medium column for top floor" annotation (Placement(transformation(extent={{-70,71},{-50,91}}))); - IBPSA.Airflow.Multizone.DoorDiscretizedOperable dooOpeClo( + + replaceable DoorOpen dooOpeClo( redeclare package Medium = Medium, - LClo=20*1E-4, wOpe=1, hOpe=2.2, - CDOpe=0.78, - CDClo=0.78, - nCom=10, - hA=3/2, - hB=3/2, - dp_turbulent(displayUnit="Pa") = 0.01) "Discretized door" + dp_turbulent(displayUnit="Pa") = 0.01, + CD=0.78, + m=0.5) constrainedby Fluid.Interfaces.PartialFourPortInterface + "Door" annotation (Placement(transformation(extent={{-1,-55},{19,-35}}))); IBPSA.Fluid.MixingVolumes.MixingVolume volWes( redeclare package Medium = Medium, @@ -86,18 +94,19 @@ model ThreeRoomsContam V=2.5*5*5, m_flow_nominal=0.001, energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial) + "Air volume west floor" annotation (Placement(transformation(extent={{-90,-30},{-70,-10}}))); - Modelica.Blocks.Sources.Constant open(k=1) annotation (Placement( - transformation(extent={{-40,-21},{-20,-1}}))); IBPSA.Airflow.Multizone.MediumColumn col1EasBot( redeclare package Medium = Medium, h=1.5, densitySelection=IBPSA.Airflow.Multizone.Types.densitySelection.fromBottom) + "Medium column for bottom floor" annotation (Placement(transformation(extent={{100,9},{120,29}}))); IBPSA.Airflow.Multizone.Orifice oriEasTop( redeclare package Medium = Medium, m=0.5, - A=0.01) annotation (Placement(transformation( + A=0.01) "Orifice between top and bottom east floor" + annotation (Placement(transformation( origin={110,49}, extent={{-10,-10},{10,10}}, rotation=90))); @@ -105,6 +114,7 @@ model ThreeRoomsContam redeclare package Medium = Medium, h=1.5, densitySelection=IBPSA.Airflow.Multizone.Types.densitySelection.fromTop) + "Medium column for top floor" annotation (Placement(transformation(extent={{100,71},{120,91}}))); IBPSA.Fluid.MixingVolumes.MixingVolume volTop( redeclare package Medium = Medium, @@ -113,6 +123,7 @@ model ThreeRoomsContam nPorts=2, m_flow_nominal=0.001, energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial) + "Air volume top floor" annotation (Placement(transformation(extent={{-20,120},{0,140}}))); Modelica.Thermal.HeatTransfer.Sources.FixedTemperature TTop(T=293.15) @@ -134,8 +145,6 @@ model ThreeRoomsContam "Thermal conductor" annotation (Placement(transformation(extent={{50,-20},{70,0}}))); equation - connect(open.y, dooOpeClo.y) annotation (Line(points={{-19,-11},{-14,-11},{ - -14,-45},{-2,-45}}, color={0,0,255})); connect(volWes.ports[1], dooOpeClo.port_b2) annotation (Line( points={{-82.6667,-30},{-82.6667,-51},{-1,-51}}, color={0,127,255})); @@ -242,9 +251,10 @@ The model implements the configuration shown below.

\"Configuration

-This model has been used for a comparative model validation between CONTAM and -the Buildings library. -See Wetter (2006) for details of the validation. +For the model that has been used for a comparative model validation between CONTAM and +the Buildings library in Wetter (2006), see + +IBPSA.Airflow.Multizone.Validation.ThreeRoomsContamDiscretizedDoor.

References

@@ -256,6 +266,10 @@ Proc. of the 5th International Modelica Conference, p. 431-440. Vienna, Austria, ", revisions="