diff --git a/AixLib/BoundaryConditions/InternalGains/Examples/InternalGains/BaseClasses/PartialHumansExample.mo b/AixLib/BoundaryConditions/InternalGains/Examples/InternalGains/BaseClasses/PartialHumansExample.mo index d22e82f1c4..635f9db950 100644 --- a/AixLib/BoundaryConditions/InternalGains/Examples/InternalGains/BaseClasses/PartialHumansExample.mo +++ b/AixLib/BoundaryConditions/InternalGains/Examples/InternalGains/BaseClasses/PartialHumansExample.mo @@ -20,9 +20,12 @@ equation connect(heatFlowSensorConv.port_b,fixedTemp. port) annotation (Line(points={{52,19},{56,19},{56,14},{60,14}}, color={191,0,0})); connect(fixedTemp.port,heatFlowSensorRad. port_b) annotation (Line(points={{60,14},{56,14},{56,-8},{34,-8}}, color={191,0,0})); - connect(heatFlowSensorConv.Q_flow,sumQ_flows. u[1]) annotation (Line(points={{45,12},{46,12},{46,-50},{30,-50},{30,-61.9},{34,-61.9}}, color={0,0,127})); - connect(heatFlowSensorRad.Q_flow,sumQ_flows. u[2]) annotation (Line(points={{26,-16},{26,-66.1},{34,-66.1}}, color={0,0,127})); - connect(sumQ_flows.y,HeatOut) annotation (Line(points={{47.02,-64},{100,-64}},color={0,0,127})); + connect(heatFlowSensorConv.Q_flow,sumQ_flows. u[1]) annotation (Line(points={{45,11.3}, + {46,11.3},{46,-50},{30,-50},{30,-65.05},{34,-65.05}}, color={0,0,127})); + connect(heatFlowSensorRad.Q_flow,sumQ_flows. u[2]) annotation (Line(points={{26, + -16.8},{26,-62.95},{34,-62.95}}, color={0,0,127})); + connect(sumQ_flows.y,HeatOut) annotation (Line(points={{47.02,-64},{24,-64},{ + 24,0},{0,0}}, color={0,0,127})); connect(varTempRoom.port, humanIntGains.TRoom) annotation (Line(points={{-64,52},{-40,52},{-40,12.7},{-14.7,12.7}}, color={191,0,0})); connect(combiTimeTable.y[1], humanIntGains.uRel) annotation (Line(points={{-61,-16},{-40,-16},{-40,1},{-16,1}}, color={0,0,127})); connect(heatFlowSensorConv.port_a, humanIntGains.convHeat) annotation (Line(points={{38,19},{24,19},{24,8.8},{8.7,8.8}}, color={191,0,0})); diff --git a/AixLib/BoundaryConditions/InternalGains/Machines/MachinesDIN18599.mo b/AixLib/BoundaryConditions/InternalGains/Machines/MachinesDIN18599.mo index 8995bdf540..18ef3782e0 100644 --- a/AixLib/BoundaryConditions/InternalGains/Machines/MachinesDIN18599.mo +++ b/AixLib/BoundaryConditions/InternalGains/Machines/MachinesDIN18599.mo @@ -6,7 +6,7 @@ model MachinesDIN18599 "Heat flow due to machines based on DIN 18599 (number of gain(final k=nrPeople), gainSurfaces(final k=areaSurfaceMachinesTotal)); - parameter Integer activityType=2 "Machine activity" annotation(Dialog( compact = true, descriptionLabel = true), choices(choice=1 "low", choice = 2 "middle", choice = 3 "high", radioButtons = true)); + parameter AixLib.BoundaryConditions.InternalGains.Types.MachineActivity activityType=AixLib.BoundaryConditions.InternalGains.Types.MachineActivity.middle "Machine activity" annotation(Dialog( compact = true, descriptionLabel = true)); parameter Real nrPeople=1.0 "Number of people with machines" annotation(Dialog(descriptionLabel = true)); parameter Modelica.Units.SI.Area areaSurfaceMachinesTotal=max(1e-4, surfaceMachine*nrPeople) @@ -21,7 +21,9 @@ protected table=[1,50; 2,100; 3,150], columns={2}) annotation (Placement(transformation(extent={{-60,40},{-40,60}}))); - Modelica.Blocks.Sources.Constant activity(k=activityType) + Modelica.Blocks.Sources.Constant activity(k=if activityType==AixLib.BoundaryConditions.InternalGains.Types.MachineActivity.low then 1 + elseif activityType==AixLib.BoundaryConditions.InternalGains.Types.MachineActivity.middle then 2 + else 3) annotation (Placement(transformation(extent={{-90,40},{-70,60}}))); equation connect(activity.y, tableHeatOutput.u[1]) annotation (Line(points={{-69,50},{-62,50}}, color={0,0,127})); diff --git a/AixLib/BoundaryConditions/InternalGains/Types.mo b/AixLib/BoundaryConditions/InternalGains/Types.mo new file mode 100644 index 0000000000..926ec806f4 --- /dev/null +++ b/AixLib/BoundaryConditions/InternalGains/Types.mo @@ -0,0 +1,7 @@ +within AixLib.BoundaryConditions.InternalGains; +package Types + type MachineActivity = enumeration( + low "low", + middle "middle", + high "high") "Enumeration to define the machine activity"; +end Types; diff --git a/AixLib/BoundaryConditions/InternalGains/package.order b/AixLib/BoundaryConditions/InternalGains/package.order index 83e4e57d50..8fb73b7dc6 100644 --- a/AixLib/BoundaryConditions/InternalGains/package.order +++ b/AixLib/BoundaryConditions/InternalGains/package.order @@ -5,3 +5,4 @@ Machines Moisture Examples BaseClasses +Types diff --git a/AixLib/BoundaryConditions/WeatherData/Old/WeatherTRY/RadiationOnTiltedSurface/BaseClasses/PartialRadOnTiltedSurf.mo b/AixLib/BoundaryConditions/WeatherData/Old/WeatherTRY/RadiationOnTiltedSurface/BaseClasses/PartialRadOnTiltedSurf.mo index 5bc36fc8f9..846505b76c 100644 --- a/AixLib/BoundaryConditions/WeatherData/Old/WeatherTRY/RadiationOnTiltedSurface/BaseClasses/PartialRadOnTiltedSurf.mo +++ b/AixLib/BoundaryConditions/WeatherData/Old/WeatherTRY/RadiationOnTiltedSurface/BaseClasses/PartialRadOnTiltedSurf.mo @@ -1,7 +1,7 @@ within AixLib.BoundaryConditions.WeatherData.Old.WeatherTRY.RadiationOnTiltedSurface.BaseClasses; partial model PartialRadOnTiltedSurf - parameter Integer WeatherFormat = 1 "Format weather file" annotation (Dialog(group= - "Properties of Weather Data", compact = true, descriptionLabel = true), choices(choice = 1 "TRY", choice= 2 "TMY", radioButtons = true)); + parameter Boolean WeatherFormat = false "Format weather file: If checked TMY, else TRY" annotation (Dialog(group= + "Properties of Weather Data", descriptionLabel = true), choices(checkBox = true)); parameter Modelica.Units.NonSI.Angle_deg Latitude=49.5 "latitude of location" annotation (Dialog(group="Location Properties")); parameter Real GroundReflection=0.2 "ground reflection coefficient" diff --git a/AixLib/BoundaryConditions/WeatherData/Old/WeatherTRY/RadiationOnTiltedSurface/RadOnTiltedSurf_Liu.mo b/AixLib/BoundaryConditions/WeatherData/Old/WeatherTRY/RadiationOnTiltedSurface/RadOnTiltedSurf_Liu.mo index 52d5a86bba..f11fc2787c 100644 --- a/AixLib/BoundaryConditions/WeatherData/Old/WeatherTRY/RadiationOnTiltedSurface/RadOnTiltedSurf_Liu.mo +++ b/AixLib/BoundaryConditions/WeatherData/Old/WeatherTRY/RadiationOnTiltedSurface/RadOnTiltedSurf_Liu.mo @@ -48,10 +48,10 @@ equation R = R_help; // conversion of direct and diffuse horizontal radiation - if WeatherFormat == 1 then // TRY + if not WeatherFormat then // TRY InBeamRadHor = solarInput1; InDiffRadHor = solarInput2; - else // WeatherFormat == 2 , TMY then + else // WeatherFormat == true , TMY then InBeamRadHor = solarInput1 * cos_theta_z; InDiffRadHor = max(solarInput2-InBeamRadHor, 0); end if; diff --git a/AixLib/BoundaryConditions/WeatherData/Old/WeatherTRY/RadiationOnTiltedSurface/RadOnTiltedSurf_Perez.mo b/AixLib/BoundaryConditions/WeatherData/Old/WeatherTRY/RadiationOnTiltedSurface/RadOnTiltedSurf_Perez.mo index 82616f4158..8cfd077cdf 100644 --- a/AixLib/BoundaryConditions/WeatherData/Old/WeatherTRY/RadiationOnTiltedSurface/RadOnTiltedSurf_Perez.mo +++ b/AixLib/BoundaryConditions/WeatherData/Old/WeatherTRY/RadiationOnTiltedSurface/RadOnTiltedSurf_Perez.mo @@ -192,10 +192,10 @@ equation R = a / b; // conversion of direct and diffuse horizontal radiation - if WeatherFormat == 1 then // TRY + if not WeatherFormat then // TRY InBeamRadHor = solarInput1; InDiffRadHor = solarInput2; - else // WeatherFormat == 2 , TMY then + else // WeatherFormat == true , TMY then InBeamRadHor = solarInput1 * cos_theta_z; InDiffRadHor = max(solarInput2-InBeamRadHor, 0); end if; diff --git a/AixLib/BoundaryConditions/WeatherData/Old/WeatherTRY/Weather.mo b/AixLib/BoundaryConditions/WeatherData/Old/WeatherTRY/Weather.mo index 9e0f6a52a6..eb3acfeef5 100644 --- a/AixLib/BoundaryConditions/WeatherData/Old/WeatherTRY/Weather.mo +++ b/AixLib/BoundaryConditions/WeatherData/Old/WeatherTRY/Weather.mo @@ -25,16 +25,15 @@ model Weather "Complex weather model" replaceable model RadOnTiltedSurface = AixLib.BoundaryConditions.WeatherData.Old.WeatherTRY.RadiationOnTiltedSurface.RadOnTiltedSurf_Liu - constrainedby AixLib.BoundaryConditions.WeatherData.Old.WeatherTRY.RadiationOnTiltedSurface.BaseClasses.PartialRadOnTiltedSurf + constrainedby + AixLib.BoundaryConditions.WeatherData.Old.WeatherTRY.RadiationOnTiltedSurface.BaseClasses.PartialRadOnTiltedSurf "Model for calculating radiation on tilted surfaces" annotation(Dialog(group="Solar radiation on oriented surfaces", descriptionLabel = true), choicesAllMatching= true); parameter DataBase.Weather.SurfaceOrientation.SurfaceOrientationBaseDataDefinition SOD = DataBase.Weather.SurfaceOrientation.SurfaceOrientationData_N_E_S_W_Hor() "Surface orientation data" annotation(Dialog(group = "Solar radiation on oriented surfaces", descriptionLabel = true), choicesAllMatching = true); Utilities.Interfaces.SolarRad_out SolarRadiation_OrientedSurfaces[SOD.nSurfaces] annotation(Placement(transformation(extent = {{-10, -10}, {10, 10}}, rotation = 90, origin={50,96}), iconTransformation(extent = {{-10, -10}, {10, 10}}, rotation = 270, origin = {-78, -110}))); - parameter Integer Outopt = 2 "Output options" annotation(Dialog(tab = "Optional output vector", compact = true, descriptionLabel = true), choices(choice = 1 - "one vector", choice = 2 - "individual vectors", radioButtons = true)); + parameter Boolean outOpt = true "Output individual vectors instead of one vector [-]" annotation(Dialog(tab = "Optional output vector", descriptionLabel = true), choices(checkBox = true)); parameter Boolean Cloud_cover = false "Cloud cover [-] (TRY col 7)" annotation(Dialog(tab = "Optional output vector", descriptionLabel = true), choices(checkBox = true)); parameter Boolean Wind_dir = false "Wind direction [deg] (TRY col 8)" annotation(Dialog(tab = "Optional output vector", descriptionLabel = true), choices(checkBox = true)); parameter Boolean Wind_speed = false "Wind speed [m/s] (TRY col 9)" annotation(Dialog(tab = "Optional output vector", descriptionLabel = true), choices(checkBox = true)); @@ -52,24 +51,24 @@ model Weather "Complex weather model" Latitude=Latitude, DiffWeatherDataTime=DiffWeatherDataTime) annotation (Placement( transformation(extent={{-62,18},{-38,42}}))); - RadOnTiltedSurface RadOnTiltedSurf[SOD.nSurfaces](each Latitude = Latitude, each GroundReflection = GroundReflection, Azimut = SOD.Azimut, Tilt = SOD.Tilt, each WeatherFormat=1) annotation(Placement(transformation(extent = {{-2, 18}, {22, 42}}))); + RadOnTiltedSurface RadOnTiltedSurf[SOD.nSurfaces](each Latitude = Latitude, each GroundReflection = GroundReflection, Azimut = SOD.Azimut, Tilt = SOD.Tilt, each WeatherFormat=false) annotation(Placement(transformation(extent = {{-2, 18}, {22, 42}}))); Modelica.Blocks.Sources.CombiTimeTable WeatherData(fileName = Modelica.Utilities.Files.loadResource(fileName), columns = columns, offset = offset, table = [0, 0; 1, 1], startTime = scalar(startTime), tableName = tableName, tableOnFile = tableName <> "NoName", smoothness = smoothness, extrapolation = extrapolation) annotation(Placement(transformation(extent = {{-60, -70}, {-40, -50}}))); Modelica.Blocks.Routing.DeMultiplex3 deMultiplex(n3 = 9) annotation(Placement(transformation(extent = {{-26, -70}, {-6, -50}}))); - Modelica.Blocks.Interfaces.RealOutput WeatherDataVector[m] if Outopt == 1 and (Cloud_cover or Wind_dir or Wind_speed or Air_temp or Air_press or Mass_frac or Rel_hum or Sky_rad or Ter_rad) annotation(Placement(transformation(origin = {-1, -110}, extent = {{-10, -10}, {10, 10}}, rotation = 270))); - Modelica.Blocks.Interfaces.RealOutput CloudCover if Cloud_cover and Outopt == 2 "[0..8]" annotation(Placement(transformation(extent = {{114, 74}, {134, 94}}), iconTransformation(extent = {{150, 110}, {170, 130}}))); - Modelica.Blocks.Interfaces.RealOutput WindDirection(unit = "deg") if Wind_dir and Outopt == 2 + Modelica.Blocks.Interfaces.RealOutput WeatherDataVector[m] if outOpt == false and (Cloud_cover or Wind_dir or Wind_speed or Air_temp or Air_press or Mass_frac or Rel_hum or Sky_rad or Ter_rad) annotation(Placement(transformation(origin = {-1, -110}, extent = {{-10, -10}, {10, 10}}, rotation = 270))); + Modelica.Blocks.Interfaces.RealOutput CloudCover if Cloud_cover and outOpt "[0..8]" annotation(Placement(transformation(extent = {{114, 74}, {134, 94}}), iconTransformation(extent = {{150, 110}, {170, 130}}))); + Modelica.Blocks.Interfaces.RealOutput WindDirection(unit = "deg") if Wind_dir and outOpt "in deg [0...360]" annotation(Placement(transformation(extent = {{126, 52}, {146, 72}}), iconTransformation(extent = {{150, 80}, {170, 100}}))); - Modelica.Blocks.Interfaces.RealOutput WindSpeed(unit = "m/s") if Wind_speed and Outopt == 2 "in m/s" annotation(Placement(transformation(extent = {{126, 32}, {146, 52}}), iconTransformation(extent = {{150, 50}, {170, 70}}))); - Modelica.Blocks.Interfaces.RealOutput AirTemp(unit = "K") if Air_temp and Outopt == 2 + Modelica.Blocks.Interfaces.RealOutput WindSpeed(unit = "m/s") if Wind_speed and outOpt "in m/s" annotation(Placement(transformation(extent = {{126, 32}, {146, 52}}), iconTransformation(extent = {{150, 50}, {170, 70}}))); + Modelica.Blocks.Interfaces.RealOutput AirTemp(unit = "K") if Air_temp and outOpt "in Kelvin" annotation(Placement(transformation(extent = {{126, 14}, {146, 34}}), iconTransformation(extent = {{150, 20}, {170, 40}}))); - Modelica.Blocks.Interfaces.RealOutput AirPressure(unit = "Pa") if Air_press and Outopt == 2 "in Pa" annotation(Placement(transformation(extent = {{126, -8}, {146, 12}}), iconTransformation(extent = {{150, -10}, {170, 10}}))); - Modelica.Blocks.Interfaces.RealOutput WaterInAir if Mass_frac and Outopt == 2 + Modelica.Blocks.Interfaces.RealOutput AirPressure(unit = "Pa") if Air_press and outOpt "in Pa" annotation(Placement(transformation(extent = {{126, -8}, {146, 12}}), iconTransformation(extent = {{150, -10}, {170, 10}}))); + Modelica.Blocks.Interfaces.RealOutput WaterInAir if Mass_frac and outOpt "in kg/kg" annotation(Placement(transformation(extent = {{126, -24}, {146, -4}}), iconTransformation(extent = {{150, -40}, {170, -20}}))); - Modelica.Blocks.Interfaces.RealOutput RelHumidity if Rel_hum and Outopt == 2 + Modelica.Blocks.Interfaces.RealOutput RelHumidity if Rel_hum and outOpt "in percent" annotation(Placement(transformation(extent = {{126, -42}, {146, -22}}), iconTransformation(extent = {{150, -70}, {170, -50}}))); - Modelica.Blocks.Interfaces.RealOutput SkyRadiation(unit = "W/m2") if Sky_rad and Outopt == 2 "in W/m2" - annotation(Placement(transformation(extent = {{126, -62}, {146, -42}}), iconTransformation(extent = {{150, -100}, {170, -80}}))); - Modelica.Blocks.Interfaces.RealOutput TerrestrialRadiation(unit = "W/m2") if Ter_rad and Outopt == 2 "in W/m2" + Modelica.Blocks.Interfaces.RealOutput SkyRadiation(unit = "W/m2") if Sky_rad and outOpt "in W/m2" + annotation(Placement(transformation(extent = {{126, -62}, {146, -42}}), iconTransformation(extent = {{150, -100}, {170, -80}}))); + Modelica.Blocks.Interfaces.RealOutput TerrestrialRadiation(unit = "W/m2") if Ter_rad and outOpt "in W/m2" annotation(Placement(transformation(extent = {{126, -78}, {146, -58}}), iconTransformation(extent = {{150, -130}, {170, -110}}))); Modelica.Blocks.Math.Gain hPa_to_Pa(k = 100) if Air_press annotation(Placement(transformation(extent = {{26, -60}, {36, -50}}))); Modelica.Blocks.Math.Gain percent_to_unit(k = 0.01) if Rel_hum annotation(Placement(transformation(extent = {{26, -78}, {36, -68}}))); @@ -93,7 +92,7 @@ initial equation equation // cloud cover if Cloud_cover then - if Outopt == 1 then + if outOpt == false then connect(WeatherDataVector[PosWV[1]], deMultiplex.y3[1]); else connect(CloudCover, deMultiplex.y3[1]); @@ -101,7 +100,7 @@ equation end if; // wind direction if Wind_dir then - if Outopt == 1 then + if not outOpt then connect(WeatherDataVector[PosWV[2]], deMultiplex.y3[2]); else connect(WindDirection, deMultiplex.y3[2]); @@ -109,7 +108,7 @@ equation end if; // wind speed if Wind_speed then - if Outopt == 1 then + if not outOpt then connect(WeatherDataVector[PosWV[3]], deMultiplex.y3[3]); else connect(WindSpeed, deMultiplex.y3[3]); @@ -117,7 +116,7 @@ equation end if; // air temperature if Air_temp then - if Outopt == 1 then + if not outOpt then connect(deMultiplex.y3[4], from_degC.u); connect(WeatherDataVector[PosWV[4]], from_degC.y); else @@ -127,7 +126,7 @@ equation end if; // air pressure, conversion from hPa to Pa if Air_press then - if Outopt == 1 then + if not outOpt then connect(deMultiplex.y3[5], hPa_to_Pa.u); connect(WeatherDataVector[PosWV[5]], hPa_to_Pa.y); else @@ -137,7 +136,7 @@ equation end if; // mass fraction water in dry air, conversion from g/kg to kg/kg if Mass_frac then - if Outopt == 1 then + if not outOpt then connect(deMultiplex.y3[6], g_to_kg.u); connect(WeatherDataVector[PosWV[6]], g_to_kg.y); else @@ -147,7 +146,7 @@ equation end if; // rel. humidity, conversion from % to 0..1 if Rel_hum then - if Outopt == 1 then + if not outOpt then connect(deMultiplex.y3[7], percent_to_unit.u); connect(WeatherDataVector[PosWV[7]], percent_to_unit.y); else @@ -157,7 +156,7 @@ equation end if; // longwave sky radiation if Sky_rad then - if Outopt == 1 then + if not outOpt then connect(WeatherDataVector[PosWV[8]], deMultiplex.y3[8]); else connect(SkyRadiation, deMultiplex.y3[8]); @@ -165,7 +164,7 @@ equation end if; // longwave terrestric radiation if Ter_rad then - if Outopt == 1 then + if not outOpt then connect(WeatherDataVector[PosWV[9]], deMultiplex.y3[9]); else connect(TerrestrialRadiation, deMultiplex.y3[9]); diff --git a/AixLib/Fluid/Pools/BaseClasses/HeatTransferConduction.mo b/AixLib/Fluid/Pools/BaseClasses/HeatTransferConduction.mo index 33e58e2927..e1500a0602 100644 --- a/AixLib/Fluid/Pools/BaseClasses/HeatTransferConduction.mo +++ b/AixLib/Fluid/Pools/BaseClasses/HeatTransferConduction.mo @@ -40,8 +40,8 @@ model HeatTransferConduction AixLib.Utilities.HeatTransfer.HeatConvInside HeatConvWaterHorizontalInner( hCon_const=hConWaterHorizontal, A=AFloInt, - calcMethod=3, - surfaceOrientation=1) + calcMethod=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.Custom_hCon, + surfaceOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.vertical_wall) annotation (Placement(transformation( origin={-50,-20}, extent={{-10,-10},{10,10}}, @@ -49,8 +49,8 @@ model HeatTransferConduction AixLib.Utilities.HeatTransfer.HeatConvInside HeatConvWaterVerticalOuter( hCon_const=hConWaterVertical, A=AWalExt, - calcMethod=3, - surfaceOrientation=1) annotation (Placement(transformation( + calcMethod=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.Custom_hCon, + surfaceOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.vertical_wall) annotation (Placement(transformation( origin={-50,40}, extent={{-10,-10},{10,10}}, rotation=180))); @@ -64,8 +64,8 @@ model HeatTransferConduction AixLib.Utilities.HeatTransfer.HeatConvInside HeatConvWaterHorizontalOuter( hCon_const=hConWaterHorizontal, A=AFloExt, - calcMethod=3, - surfaceOrientation=1) annotation (Placement(transformation( + calcMethod=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.Custom_hCon, + surfaceOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.vertical_wall) annotation (Placement(transformation( origin={-50,-60}, extent={{-10,-10},{10,10}}, rotation=180))); @@ -95,8 +95,8 @@ model HeatTransferConduction AixLib.Utilities.HeatTransfer.HeatConvInside HeatConvWaterVerticalInner( hCon_const=hConWaterVertical, A=AWalInt, - calcMethod=3, - surfaceOrientation=1) annotation (Placement(transformation( + calcMethod=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.Custom_hCon, + surfaceOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.vertical_wall) annotation (Placement(transformation( origin={-50,80}, extent={{-10,-10},{10,10}}, rotation=180))); diff --git a/AixLib/ThermalZones/HighOrder/Components/Examples/Walls/OutsideWall.mo b/AixLib/ThermalZones/HighOrder/Components/Examples/Walls/OutsideWall.mo index 48ea1ff04c..5769a77d4a 100644 --- a/AixLib/ThermalZones/HighOrder/Components/Examples/Walls/OutsideWall.mo +++ b/AixLib/ThermalZones/HighOrder/Components/Examples/Walls/OutsideWall.mo @@ -16,7 +16,7 @@ model OutsideWall AixLib.ThermalZones.HighOrder.Components.WindowsDoors.BaseClasses.CorrectionSolarGain.CorGSimple, withSunblind=true, outside=true, - calcMethodOut=2, + calcMethodOut=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.ASHRAE_Fundamentals, Blinding=0.2, LimitSolIrr=100, TOutAirLimit=282.15, diff --git a/AixLib/ThermalZones/HighOrder/Components/Types/CalcMethodConvectiveHeatTransfer.mo b/AixLib/ThermalZones/HighOrder/Components/Types/CalcMethodConvectiveHeatTransfer.mo new file mode 100644 index 0000000000..e55fbece7e --- /dev/null +++ b/AixLib/ThermalZones/HighOrder/Components/Types/CalcMethodConvectiveHeatTransfer.mo @@ -0,0 +1,9 @@ +within AixLib.ThermalZones.HighOrder.Components.Types; +type CalcMethodConvectiveHeatTransfer = enumeration( + DIN_6946 + "DIN 6946", + ASHRAE_Fundamentals + "ASHRAE Fundamentals", + Custom_hCon + "Custom hCon (constant)") + "Calculation method for convective heat transfer coefficient at outside surface"; diff --git a/AixLib/ThermalZones/HighOrder/Components/Types/CalcMethodConvectiveHeatTransferInsideSurface.mo b/AixLib/ThermalZones/HighOrder/Components/Types/CalcMethodConvectiveHeatTransferInsideSurface.mo new file mode 100644 index 0000000000..7df64520e0 --- /dev/null +++ b/AixLib/ThermalZones/HighOrder/Components/Types/CalcMethodConvectiveHeatTransferInsideSurface.mo @@ -0,0 +1,11 @@ +within AixLib.ThermalZones.HighOrder.Components.Types; +type CalcMethodConvectiveHeatTransferInsideSurface = enumeration( + EN_ISO_6946_Appendix_A + "EN ISO 6946 Appendix A >>Flat Surfaces<<", + Bernd_Glueck + "By Bernd Glueck", + Custom_hCon + "Custom hCon (constant)", + ASHRAE140_2017 + "ASHRAE140-2017") + "Calculation method for convective heat transfer coefficient at inside surface"; diff --git a/AixLib/ThermalZones/HighOrder/Components/Types/CalcMethodRadiativeHeatTransfer.mo b/AixLib/ThermalZones/HighOrder/Components/Types/CalcMethodRadiativeHeatTransfer.mo new file mode 100644 index 0000000000..34f03b3ecd --- /dev/null +++ b/AixLib/ThermalZones/HighOrder/Components/Types/CalcMethodRadiativeHeatTransfer.mo @@ -0,0 +1,11 @@ +within AixLib.ThermalZones.HighOrder.Components.Types; +type CalcMethodRadiativeHeatTransfer = enumeration( + No_approx + "No approx", + Linear_wall_temp + "Linear approx at wall temp", + Linear_rad_temp + "Linear approx at rad temp", + Linear_constant_T_ref + "Linear approx at constant T_ref") + "Calculation method for radiation heat transfer"; diff --git a/AixLib/ThermalZones/HighOrder/Components/Types/InsideSurfaceOrientation.mo b/AixLib/ThermalZones/HighOrder/Components/Types/InsideSurfaceOrientation.mo new file mode 100644 index 0000000000..ffd46bfd8f --- /dev/null +++ b/AixLib/ThermalZones/HighOrder/Components/Types/InsideSurfaceOrientation.mo @@ -0,0 +1,8 @@ +within AixLib.ThermalZones.HighOrder.Components.Types; +type InsideSurfaceOrientation = enumeration( + vertical_wall + "vertical wall", + floor + "floor", + ceiling + "ceiling") "Inside Surface Orientation"; diff --git a/AixLib/ThermalZones/HighOrder/Components/Types/ThermalInsulationRegulation.mo b/AixLib/ThermalZones/HighOrder/Components/Types/ThermalInsulationRegulation.mo new file mode 100644 index 0000000000..8a0cc70c88 --- /dev/null +++ b/AixLib/ThermalZones/HighOrder/Components/Types/ThermalInsulationRegulation.mo @@ -0,0 +1,11 @@ +within AixLib.ThermalZones.HighOrder.Components.Types; +type ThermalInsulationRegulation = enumeration( + EnEV_2009 + "EnEV 2009", + EnEV_2002 + "EnEV 2002", + WSchV_1995 + "WSchV 1995", + WSchV_1984 + "WSchV 1984") + "Thermal Insulation Regulation"; diff --git a/AixLib/ThermalZones/HighOrder/Components/Types/package.order b/AixLib/ThermalZones/HighOrder/Components/Types/package.order index 5f1b35b639..223eb8d82a 100644 --- a/AixLib/ThermalZones/HighOrder/Components/Types/package.order +++ b/AixLib/ThermalZones/HighOrder/Components/Types/package.order @@ -2,3 +2,8 @@ selectorCoefficients CoeffTableEastWestWindow CoeffTableSouthWindow PartialCoeffTable +CalcMethodConvectiveHeatTransfer +CalcMethodRadiativeHeatTransfer +CalcMethodConvectiveHeatTransferInsideSurface +ThermalInsulationRegulation +InsideSurfaceOrientation diff --git a/AixLib/ThermalZones/HighOrder/Components/Walls/BaseClasses/ConvNLayerClearanceStar.mo b/AixLib/ThermalZones/HighOrder/Components/Walls/BaseClasses/ConvNLayerClearanceStar.mo index 6082f6e976..5a6d44088b 100644 --- a/AixLib/ThermalZones/HighOrder/Components/Walls/BaseClasses/ConvNLayerClearanceStar.mo +++ b/AixLib/ThermalZones/HighOrder/Components/Walls/BaseClasses/ConvNLayerClearanceStar.mo @@ -27,34 +27,25 @@ model ConvNLayerClearanceStar "Specific heat capacity" annotation (Dialog(group="Structure of wall layers")); // which orientation of surface? - parameter Integer surfaceOrientation "Surface orientation" annotation(Dialog(descriptionLabel = true, enable = if IsHConvConstant == true then false else true), choices(choice = 1 - "vertical", choice = 2 - "horizontal facing up", choice = 3 - "horizontal facing down", radioButtons = true)); - parameter Integer calcMethod=2 "Calculation method for convective heat transfer coefficient at inside surface" annotation (Dialog( - group="Convection", descriptionLabel=true), choices( - choice=1 "EN ISO 6946 Appendix A >>Flat Surfaces<<", - choice=2 "By Bernd Glueck", - choice=3 "Custom hCon (constant)", - choice=4 "ASHRAE140-2017", - radioButtons=true)); + parameter AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation surfaceOrientation + "Surface orientation" annotation(Dialog(descriptionLabel = true, enable = if IsHConvConstant == true then false else true)); + parameter AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface calcMethod= + AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.Bernd_Glueck + "Calculation method for convective heat transfer coefficient at inside surface" annotation (Dialog( + group="Convection", descriptionLabel=true)); parameter Modelica.Units.SI.CoefficientOfHeatTransfer hCon_const=2 "Constant convective heat transfer coefficient" - annotation (Dialog(group="Convection", enable=calcMethod == 1)); + annotation (Dialog(group="Convection", enable=calcMethod == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.EN_ISO_6946_Appendix_A)); - parameter Integer radCalcMethod=1 "Calculation method for radiation heat transfer" annotation ( + parameter AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodRadiativeHeatTransfer radCalcMethod= + AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodRadiativeHeatTransfer.No_approx + "Calculation method for radiation heat transfer" annotation ( Evaluate=true, - Dialog(group = "Radiation", compact=true), - choices( - choice=1 "No approx", - choice=2 "Linear approx at wall temp", - choice=3 "Linear approx at rad temp", - choice=4 "Linear approx at constant T_ref", - radioButtons=true)); + Dialog(group = "Radiation", compact=true)); parameter Modelica.Units.SI.Temperature T_ref= Modelica.Units.Conversions.from_degC(16) "Reference temperature for optional linearization" - annotation (Dialog(group="Radiation", enable=radCalcMethod == 4)); + annotation (Dialog(group="Radiation", enable=radCalcMethod == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodRadiativeHeatTransfer.Linear_constant_T_ref)); parameter Modelica.Units.SI.Temperature T0= Modelica.Units.Conversions.from_degC(16) "Initial temperature" diff --git a/AixLib/ThermalZones/HighOrder/Components/Walls/Wall.mo b/AixLib/ThermalZones/HighOrder/Components/Walls/Wall.mo index 827f23550b..009aba5309 100644 --- a/AixLib/ThermalZones/HighOrder/Components/Walls/Wall.mo +++ b/AixLib/ThermalZones/HighOrder/Components/Walls/Wall.mo @@ -4,9 +4,9 @@ model Wall //Type parameter parameter Boolean outside = true - "Choose if the wall is an outside or an inside wall" annotation(Dialog(group = "General Wall Type Parameter", compact = true), choices(choice = true - "Outside Wall", choice = false - "Inside Wall", radioButtons = true)); + "Choose if the wall is an outside wall (or an inside wall)" annotation ( + Dialog(group = "General Wall Type Parameter", compact = true), + choices(checkBox=true)); parameter Modelica.Fluid.Types.Dynamics energyDynamics=Modelica.Fluid.Types.Dynamics.DynamicFreeInitial "Type of energy balance: dynamic (3 initialization options) or steady state" @@ -25,68 +25,51 @@ model Wall // Surface parameters parameter Real solar_absorptance = 0.25 "Solar absorptance coefficient of outside wall surface" annotation(Dialog(tab = "Surface Parameters", group = "Outside surface", enable = outside)); - parameter Integer calcMethodOut=1 - "Calculation method for convective heat transfer coefficient at outside surface" annotation (Dialog( + parameter AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer calcMethodOut=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.DIN_6946 "Calculation method for convective heat transfer coefficient at outside surface" annotation (Dialog( tab="Surface Parameters", group="Outside surface", enable=outside, - compact=true), choices( - choice=1 "DIN 6946", - choice=2 "ASHRAE Fundamentals", - choice=3 "Custom hCon (constant)", - radioButtons=true)); + compact=true)); parameter Modelica.Units.SI.CoefficientOfHeatTransfer hConOut_const=25 "Custom convective heat transfer coefficient (just for manual selection, not recommended)" annotation (Dialog( tab="Surface Parameters", group="Outside surface", - enable=calcMethodOut == 3 and outside)); + enable=calcMethodOut == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.Custom_hCon and outside)); parameter DataBase.Surfaces.RoughnessForHT.PolynomialCoefficients_ASHRAEHandbook surfaceType = DataBase.Surfaces.RoughnessForHT.Brick_RoughPlaster() "Surface type of outside wall" annotation(Dialog(tab = "Surface Parameters", group = "Outside surface", enable= - calcMethodOut == 2 and outside), choicesAllMatching = true); - parameter Integer ISOrientation = 1 "Inside surface orientation" annotation(Dialog(tab = "Surface Parameters", group = "Inside surface", compact = true, descriptionLabel = true), choices(choice = 1 - "vertical wall", choice = 2 "floor", choice = 3 "ceiling", radioButtons = true)); + calcMethodOut == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.ASHRAE_Fundamentals and outside), choicesAllMatching = true); + parameter AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation ISOrientation = AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.vertical_wall "Inside surface orientation" annotation(Dialog(tab = "Surface Parameters", group = "Inside surface", compact = true, descriptionLabel = true)); parameter Boolean use_shortWaveRadIn=false "Use bus connector for incoming shortwave radiation" annotation (Evaluate=true, Dialog(tab="Surface Parameters", group="Inside surface")); parameter Boolean use_shortWaveRadOut=false "Use bus connector for outgoing shortwave radiation" annotation (Evaluate=true, Dialog(tab="Surface Parameters", group="Inside surface")); - parameter Integer radLongCalcMethod=1 "Calculation method for longwave radiation heat transfer" + parameter AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodRadiativeHeatTransfer radLongCalcMethod=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodRadiativeHeatTransfer.No_approx "Calculation method for longwave radiation heat transfer" annotation ( Evaluate=true, - Dialog(tab="Surface Parameters", group="Inside surface", compact=true), - choices( - choice=1 "No approx", - choice=2 "Linear approx at wall temp", - choice=3 "Linear approx at rad temp", - choice=4 "Linear approx at constant T_ref", - radioButtons=true)); + Dialog(tab="Surface Parameters", group="Inside surface", compact=true)); parameter Modelica.Units.SI.Temperature T_ref= Modelica.Units.Conversions.from_degC(16) "Reference temperature for optional linearization of longwave radiation" annotation (Dialog( tab="Surface Parameters", group="Inside surface", - enable=radLongCalcMethod == 4)); + enable=radLongCalcMethod == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodRadiativeHeatTransfer.Linear_constant_T_ref)); - parameter Integer calcMethodIn=1 + parameter AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface calcMethodIn=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.EN_ISO_6946_Appendix_A "Calculation method of convective heat transfer coefficient at inside surface" annotation (Dialog( tab="Surface Parameters", group="Inside surface", compact=true, - descriptionLabel=true), choices( - choice=1 "EN ISO 6946 Appendix A >>Flat Surfaces<<", - choice=2 "By Bernd Glueck", - choice=3 "Custom hCon (constant)", - choice=4 "ASHRAE140-2017", - radioButtons=true)); + descriptionLabel=true)); parameter Modelica.Units.SI.CoefficientOfHeatTransfer hConIn_const=2.5 "Custom convective heat transfer coefficient (just for manual selection, not recommended)" annotation (Dialog( tab="Surface Parameters", group="Inside surface", - enable=calcMethodIn == 3)); + enable=calcMethodIn == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.Custom_hCon)); // window parameters parameter Boolean withWindow=false "Choose if the wall has got a window (only outside walls)" annotation(Dialog(tab = "Window", group="Window", enable = outside)); @@ -170,7 +153,7 @@ parameter DataBase.Surfaces.RoughnessForHT.PolynomialCoefficients_ASHRAEHandbook Utilities.HeatTransfer.SolarRadToHeat SolarAbsorption(coeff = solar_absorptance, A=ANet) if outside annotation(Placement(transformation(origin={-37.5,90.5},extent={{-10.5,-10.5},{10.5,10.5}}))); AixLib.Utilities.Interfaces.SolarRad_in SolarRadiationPort if outside annotation(Placement(transformation(extent = {{-116, 79}, {-96, 99}}), iconTransformation(extent = {{-36, 100}, {-16, 120}}))); Modelica.Thermal.HeatTransfer.Interfaces.HeatPort_a port_outside annotation(Placement(transformation(extent = {{-108, -6}, {-88, 14}}), iconTransformation(extent = {{-31, -10}, {-11, 10}}))); - Modelica.Blocks.Interfaces.RealInput WindSpeedPort if outside and (calcMethodOut == 1 or calcMethodOut == 2) + Modelica.Blocks.Interfaces.RealInput WindSpeedPort if outside and (calcMethodOut == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.DIN_6946 or calcMethodOut == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.ASHRAE_Fundamentals) annotation(Placement(transformation(extent = {{-113, 54}, {-93, 74}}), iconTransformation(extent = {{-31, 78}, {-11, 98}}))); Sunblinds.Sunblind Sunblind( final n=1, @@ -253,7 +236,7 @@ equation //****************************************************************** if outside then connect(SolarRadiationPort, SolarAbsorption.solarRad_in) annotation(Line(points={{-106,89},{-48,89},{-48,88.4},{-48.105,88.4}}, color = {255, 128, 0})); - if calcMethodOut == 1 or calcMethodOut == 2 then + if calcMethodOut == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.DIN_6946 or calcMethodOut == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.ASHRAE_Fundamentals then connect(WindSpeedPort, heatTransfer_Outside.WindSpeedPort) annotation(Line(points={{-103,64},{-68,64},{-68,51},{-46,51}}, color = {0, 0, 127})); end if; connect(heatTransfer_Outside.port_a, port_outside) annotation(Line(points = {{-47, 58}, {-56, 58}, {-56, 4}, {-98, 4}}, color = {191, 0, 0})); diff --git a/AixLib/ThermalZones/HighOrder/Components/WindowsDoors/Door.mo b/AixLib/ThermalZones/HighOrder/Components/WindowsDoors/Door.mo index 07fa6396eb..5441d9cfc9 100644 --- a/AixLib/ThermalZones/HighOrder/Components/WindowsDoors/Door.mo +++ b/AixLib/ThermalZones/HighOrder/Components/WindowsDoors/Door.mo @@ -7,19 +7,13 @@ model Door "Simple door" parameter Modelica.Units.SI.Emissivity eps=0.9 "Emissivity of door material" annotation (Dialog(group="Radiation")); - parameter Integer radCalcMethod=1 "Calculation method for radiation heat transfer" annotation ( + parameter AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodRadiativeHeatTransfer radCalcMethod=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodRadiativeHeatTransfer.No_approx "Calculation method for radiation heat transfer" annotation ( Evaluate=true, - Dialog(group = "Radiation", compact=true), - choices( - choice=1 "No approx", - choice=2 "Linear approx at wall temp", - choice=3 "Linear approx at rad temp", - choice=4 "Linear approx at constant T_ref", - radioButtons=true)); + Dialog(group = "Radiation", compact=true)); parameter Modelica.Units.SI.Temperature T_ref= Modelica.Units.Conversions.from_degC(16) "Reference temperature for optional linearization" - annotation (Dialog(group="Radiation", enable=radCalcMethod == 4)); + annotation (Dialog(group="Radiation", enable=radCalcMethod == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodRadiativeHeatTransfer.Linear_constant_T_ref)); Modelica.Thermal.HeatTransfer.Interfaces.HeatPort_a port_a annotation(Placement(transformation(extent = {{-100, -10}, {-80, 10}}))); diff --git a/AixLib/ThermalZones/HighOrder/Components/WindowsDoors/Window_ASHRAE140.mo b/AixLib/ThermalZones/HighOrder/Components/WindowsDoors/Window_ASHRAE140.mo index 6bcc1f6db5..1ba31f16b7 100644 --- a/AixLib/ThermalZones/HighOrder/Components/WindowsDoors/Window_ASHRAE140.mo +++ b/AixLib/ThermalZones/HighOrder/Components/WindowsDoors/Window_ASHRAE140.mo @@ -20,10 +20,10 @@ model Window_ASHRAE140 Placement(transformation(extent={{-10,-20},{10,0}}))); Utilities.HeatTransfer.HeatConvOutside heatConv_outside( final A=windowarea, - calcMethod=2, + calcMethod=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.ASHRAE_Fundamentals, surfaceType=AixLib.DataBase.Surfaces.RoughnessForHT.Glass()) annotation (Placement(transformation(extent={{-66,-20},{-46,0}}))); Utilities.HeatTransfer.HeatConvInside heatConv_inside( - calcMethod=2, + calcMethod=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.Bernd_Glueck, hCon_const=2, final A=windowarea) annotation (Placement(transformation(extent={{68,-20},{48,2}}))); @@ -42,8 +42,8 @@ model Window_ASHRAE140 final energyDynamics=energyDynamics) annotation (Placement(transformation(extent={{18,-18},{38,2}}))); Modelica.Blocks.Sources.Constant constFixShoRadPar[6](k={WindowType.g,1 - - WindowType.g,0,sqrt(windowarea),sqrt(windowarea),0}) - if use_solarRadWinTrans + WindowType.g,0,sqrt(windowarea),sqrt(windowarea),0}) if + use_solarRadWinTrans "Parameteres used for the short radiaton models. See connections to check which array corresponds to which parameter" annotation (Placement(transformation(extent={{68,96},{78,106}}))); equation diff --git a/AixLib/ThermalZones/HighOrder/Examples/OFDHeatLoad.mo b/AixLib/ThermalZones/HighOrder/Examples/OFDHeatLoad.mo index f7fbf81950..7a159ea0c7 100644 --- a/AixLib/ThermalZones/HighOrder/Examples/OFDHeatLoad.mo +++ b/AixLib/ThermalZones/HighOrder/Examples/OFDHeatLoad.mo @@ -5,15 +5,10 @@ model OFDHeatLoad "Test environment to determine OFD's nominal heat load" parameter Integer nRooms = 11; parameter Integer nHeatedRooms = 10; - parameter Integer TIR=1 "Thermal Insulation Regulation" annotation (Dialog( + parameter AixLib.ThermalZones.HighOrder.Components.Types.ThermalInsulationRegulation TIR=AixLib.ThermalZones.HighOrder.Components.Types.ThermalInsulationRegulation.EnEV_2009 "Thermal Insulation Regulation" annotation (Dialog( group="Construction parameters", compact=true, - descriptionLabel=true), choices( - choice=1 "EnEV_2009", - choice=2 "EnEV_2002", - choice=3 "WSchV_1995", - choice=4 "WSchV_1984", - radioButtons=true)); + descriptionLabel=true)); replaceable package MediumAir = AixLib.Media.Air "Medium within the room"; @@ -57,9 +52,9 @@ model OFDHeatLoad "Test environment to determine OFD's nominal heat load" redeclare model CorrSolarGainWin = Components.WindowsDoors.BaseClasses.CorrectionSolarGain.CorGSimple, use_infiltEN12831=true, - n50=if TIR == 1 or TIR == 2 then 3 else if TIR == 3 then 4 else 6, + n50=if TIR == AixLib.ThermalZones.HighOrder.Components.Types.ThermalInsulationRegulation.EnEV_2009 or TIR == AixLib.ThermalZones.HighOrder.Components.Types.ThermalInsulationRegulation.EnEV_2002 then 3 else if TIR == AixLib.ThermalZones.HighOrder.Components.Types.ThermalInsulationRegulation.WSchV_1995 then 4 else 6, redeclare package Medium = MediumAir, - UValOutDoors=if TIR == 1 then 1.8 else 2.9, + UValOutDoors=if TIR == AixLib.ThermalZones.HighOrder.Components.Types.ThermalInsulationRegulation.EnEV_2009 then 1.8 else 2.9, upperFloor_Building(Corridor(T0_air=288.15), Bath(T0_air=297.15)), groundFloor_Building(Corridor(T0_air=288.15))) annotation (Placement(transformation(extent={{-14,-10},{42,46}}))); @@ -112,23 +107,25 @@ equation connect(groundTemp.port, wholeHouseBuildingEnvelope.groundTemp) annotation (Line(points={{-42,-90},{14,-90},{14,-10}}, color={191,0,0})); connect(varRad.solarRad_out[1], wholeHouseBuildingEnvelope.North) annotation ( - Line(points={{51,69.5833},{48,69.5833},{48,26.4},{43.68,26.4}}, color={ + Line(points={{51,69.5833},{48,69.5833},{48,28.64},{43.68,28.64}},color={ 255,128,0})); connect(varRad.solarRad_out[2], wholeHouseBuildingEnvelope.East) annotation ( - Line(points={{51,69.75},{48,69.75},{48,18},{43.68,18}}, color={255,128, + Line(points={{51,69.75},{48,69.75},{48,21.36},{43.68,21.36}}, + color={255,128, 0})); connect(varRad.solarRad_out[3], wholeHouseBuildingEnvelope.South) annotation ( - Line(points={{51,69.9167},{48,69.9167},{48,9.6},{43.68,9.6}}, color={255, + Line(points={{51,69.9167},{48,69.9167},{48,14.08},{43.68,14.08}}, + color={255, 128,0})); connect(varRad.solarRad_out[4], wholeHouseBuildingEnvelope.West) annotation ( - Line(points={{51,70.0833},{48,70.0833},{48,1.2},{43.68,1.2}}, color={255, + Line(points={{51,70.0833},{48,70.0833},{48,7.36},{43.68,7.36}},color={255, 128,0})); connect(varRad.solarRad_out[5], wholeHouseBuildingEnvelope.SolarRadiationPort_RoofN) annotation (Line(points={{51,70.25},{48,70.25},{48,43.2},{43.68,43.2}}, color= {255,128,0})); connect(varRad.solarRad_out[6], wholeHouseBuildingEnvelope.SolarRadiationPort_RoofS) - annotation (Line(points={{51,70.4167},{48,70.4167},{48,34.8},{43.68,34.8}}, + annotation (Line(points={{51,70.4167},{48,70.4167},{48,35.92},{43.68,35.92}}, color={255,128,0})); connect(heatStarToComb.portConvRadComb, wholeHouseBuildingEnvelope.heatingToRooms) annotation (Line(points={{-28,-20},{-26,-20},{-26,10},{-14,10},{-14,10.16}}, color={191,0,0})); connect(constAirEx.y, wholeHouseBuildingEnvelope.AirExchangePort) annotation ( diff --git a/AixLib/ThermalZones/HighOrder/Examples/OFD_1Jan.mo b/AixLib/ThermalZones/HighOrder/Examples/OFD_1Jan.mo index 63b2f880fb..038da5d6eb 100644 --- a/AixLib/ThermalZones/HighOrder/Examples/OFD_1Jan.mo +++ b/AixLib/ThermalZones/HighOrder/Examples/OFD_1Jan.mo @@ -3,15 +3,10 @@ model OFD_1Jan "OFD with TMC, TIR and TRY" extends Modelica.Icons.Example; - parameter Integer TIR=3 "Thermal Insulation Regulation" annotation (Dialog( + parameter AixLib.ThermalZones.HighOrder.Components.Types.ThermalInsulationRegulation TIR=AixLib.ThermalZones.HighOrder.Components.Types.ThermalInsulationRegulation.WSchV_1995 "Thermal Insulation Regulation" annotation (Dialog( group="Construction parameters", compact=true, - descriptionLabel=true), choices( - choice=1 "EnEV_2009", - choice=2 "EnEV_2002", - choice=3 "WSchV_1995", - choice=4 "WSchV_1984", - radioButtons=true)); + descriptionLabel=true)); replaceable package MediumAir = AixLib.Media.Air "Medium within the room"; @@ -52,10 +47,10 @@ model OFD_1Jan "OFD with TMC, TIR and TRY" redeclare model CorrSolarGainWin = Components.WindowsDoors.BaseClasses.CorrectionSolarGain.CorGSimple, use_infiltEN12831=true, - n50=if TIR == 1 or TIR == 2 then 3 else if TIR == 3 then 4 else 6, + n50=if TIR == AixLib.ThermalZones.HighOrder.Components.Types.ThermalInsulationRegulation.EnEV_2009 or TIR == AixLib.ThermalZones.HighOrder.Components.Types.ThermalInsulationRegulation.EnEV_2002 then 3 else if TIR == AixLib.ThermalZones.HighOrder.Components.Types.ThermalInsulationRegulation.WSchV_1995 then 4 else 6, withDynamicVentilation=true, redeclare package Medium = MediumAir, - UValOutDoors=if TIR == 1 then 1.8 else 2.9) annotation (Placement(transformation(extent={{-35,-49},{60,46}}))); + UValOutDoors=if TIR == AixLib.ThermalZones.HighOrder.Components.Types.ThermalInsulationRegulation.EnEV_2009 then 1.8 else 2.9) annotation (Placement(transformation(extent={{-35,-49},{60,46}}))); Modelica.Thermal.HeatTransfer.Sources.PrescribedTemperature tempOutside annotation (Placement(transformation(extent={{-4,53},{-16.5,66}}))); AixLib.ThermalZones.HighOrder.House.OFD_MiddleInnerLoadWall.EnergySystem.IdealHeaters.GroundFloor @@ -105,21 +100,20 @@ equation connect(tempOutside.T, Weather.AirTemp) annotation (Line(points={{-2.75,59.5}, {22,59.5},{22,75.8},{75.4,75.8}}, color={0,0,127})); connect(Weather.SolarRadiation_OrientedSurfaces[1], OFD.North) annotation ( - Line(points={{113.48,53.4},{113.48,12.75},{62.85,12.75}}, + Line(points={{113.48,53.4},{113.48,16.55},{62.85,16.55}}, color={255,128,0})); connect(Weather.SolarRadiation_OrientedSurfaces[2], OFD.East) annotation ( - Line(points={{113.48,53.4},{113.48,-1.5},{62.85,-1.5}}, color={255,128,0})); + Line(points={{113.48,53.4},{113.48,4.2},{62.85,4.2}}, color={255,128,0})); connect(Weather.SolarRadiation_OrientedSurfaces[3], OFD.South) annotation ( - Line(points={{113.48,53.4},{113.48,-15.75},{62.85,-15.75}}, - color={255,128,0})); + Line(points={{113.48,53.4},{113.48,-8.15},{62.85,-8.15}}, color={255,128,0})); connect(Weather.SolarRadiation_OrientedSurfaces[4], OFD.West) annotation ( - Line(points={{113.48,53.4},{113.48,-30},{62.85,-30}}, color={255,128, + Line(points={{113.48,53.4},{113.48,-19.55},{62.85,-19.55}}, color={255,128, 0})); connect(Weather.SolarRadiation_OrientedSurfaces[5], OFD.SolarRadiationPort_RoofN) annotation (Line(points={{113.48,53.4},{113.48,41.25},{62.85,41.25}}, color= {255,128,0})); connect(Weather.SolarRadiation_OrientedSurfaces[6], OFD.SolarRadiationPort_RoofS) - annotation (Line(points={{113.48,53.4},{113.48,27},{62.85,27}}, color= + annotation (Line(points={{113.48,53.4},{113.48,28.9},{62.85,28.9}}, color= {255,128,0})); connect(NaturalVentilation.y[1], OFD.AirExchangePort[1]) annotation (Line( points={{-74,69},{-78,69},{-78,20.0909},{-39.75,20.0909}}, color={0,0, diff --git a/AixLib/ThermalZones/HighOrder/House/OFD_MiddleInnerLoadWall/BuildingEnvelope/GroundFloorBuildingEnvelope.mo b/AixLib/ThermalZones/HighOrder/House/OFD_MiddleInnerLoadWall/BuildingEnvelope/GroundFloorBuildingEnvelope.mo index f40bbe96d2..c302454cc3 100644 --- a/AixLib/ThermalZones/HighOrder/House/OFD_MiddleInnerLoadWall/BuildingEnvelope/GroundFloorBuildingEnvelope.mo +++ b/AixLib/ThermalZones/HighOrder/House/OFD_MiddleInnerLoadWall/BuildingEnvelope/GroundFloorBuildingEnvelope.mo @@ -1,4 +1,4 @@ -within AixLib.ThermalZones.HighOrder.House.OFD_MiddleInnerLoadWall.BuildingEnvelope; +within AixLib.ThermalZones.HighOrder.House.OFD_MiddleInnerLoadWall.BuildingEnvelope; model GroundFloorBuildingEnvelope extends AixLib.ThermalZones.HighOrder.Rooms.BaseClasses.PartialRoomParams( @@ -355,7 +355,7 @@ model GroundFloorBuildingEnvelope extent={{-10,-10},{10,10}}, rotation=180, origin={110,-4}))); - Modelica.Blocks.Interfaces.RealInput WindSpeedPort if (calcMethodOut == 1 or calcMethodOut == 2) + Modelica.Blocks.Interfaces.RealInput WindSpeedPort if (calcMethodOut == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.DIN_6946 or calcMethodOut == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.ASHRAE_Fundamentals) annotation (Placement(transformation(extent={{-130,12},{-100,42}}))); Modelica.Blocks.Interfaces.RealInput AirExchangePort[5] "1: LivingRoom_GF, 2: Hobby_GF, 3: Corridor, 4: WC_Storage_GF, 5: Kitchen_GF" @@ -471,10 +471,10 @@ equation connect(Corridor.thermRoom, thermCorridor) annotation (Line(points={{64.8,-9},{64.8,-32},{90,-32},{90,100},{110,100},{110,110}}, color={191,0,0})); connect(Livingroom.AirExchangePort, AirExchangePort[1]) annotation (Line( - points={{-86.2,66.24},{-86.2,66},{-92,66},{-92,-15},{-115,-15}}, + points={{-86.2,66.24},{-86.2,66},{-92,66},{-92,-9},{-115,-9}}, color={0,0,127})); connect(Hobby.AirExchangePort, AirExchangePort[2]) annotation (Line(points={{85.9, - 68.68},{85.9,78},{86,78},{86,88},{-92,88},{-92,-9},{-115,-9}},color={ + 68.68},{85.9,78},{86,78},{86,88},{-92,88},{-92,-6},{-115,-6}},color={ 0,0,127})); connect(Kitchen.SolarRadiationPort_OW1, South) annotation (Line(points={{-83.9, -61.6},{-90,-61.6},{-90,-92},{90,-92},{90,26},{110,26}}, color={255, @@ -483,25 +483,25 @@ equation Line(points={{44,-10.9},{36,-10.9},{36,-92},{-34,-92},{-34,-48.8},{-46,-48.8}}, color={191,0,0})); - connect(Livingroom.ground, groundTemp[1]) annotation (Line(points={{-63.32, - 13.92},{-63.32,-8},{-32,-8},{-32,-88},{0,-88},{0,-108}}, + connect(Livingroom.ground, groundTemp[1]) annotation (Line(points={{-63.32,13.92}, + {-63.32,-8},{-32,-8},{-32,-88},{0,-88},{0,-104}}, color={191,0,0})); - connect(Hobby.ground, groundTemp[2]) annotation (Line(points={{66.14,29.44},{ - 66.14,26},{34,26},{34,-88},{0,-88},{0,-104}}, + connect(Hobby.ground, groundTemp[2]) annotation (Line(points={{66.14,29.44},{66.14, + 26},{34,26},{34,-88},{0,-88},{0,-102}}, color={191,0,0})); connect(Corridor.ground, groundTemp[3]) annotation (Line(points={{63.2,-26.86},{63.2,-34},{34,-34},{34,-88},{0,-88},{0,-100}}, color={191,0,0})); - connect(WC_Storage.ground, groundTemp[4]) annotation (Line(points={{64.14, - -37.44},{64.14,-34},{34,-34},{34,-88},{0,-88},{0,-96}}, + connect(WC_Storage.ground, groundTemp[4]) annotation (Line(points={{64.14,-37.44}, + {64.14,-34},{34,-34},{34,-88},{0,-88},{0,-98}}, color={191,0,0})); connect(Kitchen.ground, groundTemp[5]) annotation (Line(points={{-65.2,-21.92}, - {-65.2,-14},{-32,-14},{-32,-88},{0,-88},{0,-92}}, + {-65.2,-14},{-32,-14},{-32,-88},{0,-88},{0,-96}}, color={191,0,0})); connect(Corridor.AirExchangePort, AirExchangePort[3]) annotation (Line(points={{84,4.205},{86,4.205},{86,4},{88,4},{88,-90},{-92,-90},{-92,-3},{-115,-3}}, color={0,0,127})); connect(WC_Storage.AirExchangePort, AirExchangePort[4]) annotation (Line(points={{83.9, - -76.68},{88,-76.68},{88,-90},{-92,-90},{-92,3},{-115,3}}, color={0,0,127})); + -76.68},{88,-76.68},{88,-90},{-92,-90},{-92,0},{-115,0}}, color={0,0,127})); connect(Kitchen.AirExchangePort, AirExchangePort[5]) annotation (Line(points={{-86, - -74.24},{-92,-74.24},{-92,9},{-115,9}}, color={0,0,127})); + -74.24},{-92,-74.24},{-92,3},{-115,3}}, color={0,0,127})); connect(heatStarToCombHeaters.portConvRadComb, portConvRadRooms) annotation (Line(points={{0,-18},{0,0}}, color={191,0,0})); connect(Livingroom.starRoom, heatStarToCombHeaters[1].portRad) annotation (Line(points={{-58.48,44},{-58,44},{-58,30},{-16,30},{-16,-38},{-5,-38}}, color={0,0,0})); connect(Livingroom.thermRoom, heatStarToCombHeaters[1].portConv) annotation (Line(points={{-65.08,44},{-66,44},{-66,26},{-20,26},{-20,-44},{5,-44},{5,-38}}, color={191,0,0})); @@ -513,37 +513,37 @@ equation connect(WC_Storage.thermRoom, heatStarToCombHeaters[4].portConv) annotation (Line(points={{65.66,-60},{66,-60},{66,-44},{5,-44},{5,-38}}, color={191,0,0})); connect(Kitchen.starRoom, heatStarToCombHeaters[5].portRad) annotation (Line(points={{-60.8,-52},{-60,-52},{-60,-38},{-5,-38}}, color={0,0,0})); connect(Kitchen.thermRoom, heatStarToCombHeaters[5].portConv) annotation (Line(points={{-66.8,-52},{-66,-52},{-66,-44},{5,-44},{5,-38}}, color={191,0,0})); - connect(Livingroom.ports[1], portVent_in[1]) annotation (Line(points={{-65.355, - 11.52},{-58,11.52},{-58,-8},{-20,-8},{-20,-92},{94,-92},{94,-76},{104, - -76}}, + connect(Livingroom.ports[1], portVent_in[1]) annotation (Line(points={{-63.6775, + 11.52},{-58,11.52},{-58,-8},{-20,-8},{-20,-92},{94,-92},{94,-72},{104, + -72}}, color={0,127,255})); - connect(Livingroom.ports[2], portVent_out[1]) annotation (Line(points={{-58.645, - 11.52},{-58,11.52},{-58,-8},{-20,-8},{-20,-92},{104,-92}}, + connect(Livingroom.ports[2], portVent_out[1]) annotation (Line(points={{-60.3225, + 11.52},{-58,11.52},{-58,-8},{-20,-8},{-20,-88},{104,-88}}, color={0,127,255})); - connect(Hobby.ports[1], portVent_in[2]) annotation (Line(points={{67.8975,27.64}, - {40,27.64},{40,28},{20,28},{20,-92},{94,-92},{94,-72},{104,-72}}, + connect(Hobby.ports[1], portVent_in[2]) annotation (Line(points={{66.4487, + 27.64},{40,27.64},{40,28},{20,28},{20,-92},{94,-92},{94,-70},{104,-70}}, color={0,127,255})); - connect(Hobby.ports[2], portVent_out[2]) annotation (Line(points={{62.1025,27.64}, - {20,27.64},{20,-92},{94,-92},{94,-84},{104,-84},{104,-88}}, + connect(Hobby.ports[2], portVent_out[2]) annotation (Line(points={{63.5512, + 27.64},{20,27.64},{20,-92},{94,-92},{94,-84},{104,-84},{104,-86}}, color={0,127,255})); - connect(Corridor.ports[1], portVent_in[3]) annotation (Line(points={{65.05,-28.285}, + connect(Corridor.ports[1], portVent_in[3]) annotation (Line(points={{63.525,-28.285}, {40,-28.285},{40,-28},{20,-28},{20,-92},{94,-92},{94,-68},{104,-68}}, color={0,127,255})); - connect(Corridor.ports[2], portVent_out[3]) annotation (Line(points={{58.95,-28.285}, - {58.95,-32},{20,-32},{20,-92},{94,-92},{94,-84},{104,-84}}, + connect(Corridor.ports[2], portVent_out[3]) annotation (Line(points={{60.475,-28.285}, + {60.475,-32},{20,-32},{20,-92},{94,-92},{94,-84},{104,-84}}, color={0,127,255})); - connect(WC_Storage.ports[1], portVent_in[4]) annotation (Line(points={{65.8975, - -35.64},{62,-35.64},{62,-32},{20,-32},{20,-92},{94,-92},{94,-64},{104, - -64}}, + connect(WC_Storage.ports[1], portVent_in[4]) annotation (Line(points={{64.4487, + -35.64},{62,-35.64},{62,-32},{20,-32},{20,-92},{94,-92},{94,-66},{104, + -66}}, color={0,127,255})); - connect(WC_Storage.ports[2], portVent_out[4]) annotation (Line(points={{60.1025, - -35.64},{60.1025,-32},{20,-32},{20,-92},{94,-92},{94,-80},{104,-80}}, + connect(WC_Storage.ports[2], portVent_out[4]) annotation (Line(points={{61.5512, + -35.64},{61.5512,-32},{20,-32},{20,-92},{94,-92},{94,-82},{104,-82}}, color={0,127,255})); - connect(Kitchen.ports[1], portVent_in[5]) annotation (Line(points={{-67.05,-19.52}, - {-58,-19.52},{-58,-8},{-20,-8},{-20,-92},{94,-92},{94,-60},{104,-60}}, + connect(Kitchen.ports[1], portVent_in[5]) annotation (Line(points={{-65.525,-19.52}, + {-58,-19.52},{-58,-8},{-20,-8},{-20,-92},{94,-92},{94,-64},{104,-64}}, color={0,127,255})); - connect(Kitchen.ports[2], portVent_out[5]) annotation (Line(points={{-60.95,-19.52}, - {-58,-19.52},{-58,-8},{-20,-8},{-20,-92},{94,-92},{94,-76},{104,-76}}, + connect(Kitchen.ports[2], portVent_out[5]) annotation (Line(points={{-62.475,-19.52}, + {-58,-19.52},{-58,-8},{-20,-8},{-20,-92},{94,-92},{94,-80},{104,-80}}, color={0,127,255})); annotation (Icon(coordinateSystem(preserveAspectRatio=false, extent={{-100,-100}, {100,100}}), graphics={ diff --git a/AixLib/ThermalZones/HighOrder/House/OFD_MiddleInnerLoadWall/BuildingEnvelope/UpperFloorBuildingEnvelope.mo b/AixLib/ThermalZones/HighOrder/House/OFD_MiddleInnerLoadWall/BuildingEnvelope/UpperFloorBuildingEnvelope.mo index c6e4d64e8a..44fb890809 100644 --- a/AixLib/ThermalZones/HighOrder/House/OFD_MiddleInnerLoadWall/BuildingEnvelope/UpperFloorBuildingEnvelope.mo +++ b/AixLib/ThermalZones/HighOrder/House/OFD_MiddleInnerLoadWall/BuildingEnvelope/UpperFloorBuildingEnvelope.mo @@ -373,7 +373,7 @@ model UpperFloorBuildingEnvelope extent={{-10,-10},{10,10}}, rotation=180, origin={110,-36}))); - Modelica.Blocks.Interfaces.RealInput WindSpeedPort if (calcMethodOut == 1 or calcMethodOut == 2) + Modelica.Blocks.Interfaces.RealInput WindSpeedPort if (calcMethodOut == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.DIN_6946 or calcMethodOut == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.ASHRAE_Fundamentals) annotation (Placement(transformation(extent={{-130,10},{-100,40}}))); Modelica.Blocks.Interfaces.RealInput AirExchangePort[5] "1(6): Bedroom_UF, 2(7): Child1_UF, 3(8): Corridor_UF, 4(9): Bath_UF, 5(10): Child2_UF" @@ -542,45 +542,47 @@ equation connect(Children2.starRoom, heatStarToCombHeaters[5].portRad) annotation (Line(points={{-60.8,-52},{-60.8,-38},{-5,-38}}, color={0,0,0})); connect(Children2.thermRoom, heatStarToCombHeaters[5].portConv) annotation (Line(points={{-66.8,-52},{-66,-52},{-66,-36},{-18,-36},{-18,-42},{5,-42},{5,-38}}, color={191,0,0})); connect(AirExchangePort[1], Bedroom.AirExchangePort) annotation (Line(points={{-115, - -23},{-92,-23},{-92,68.24},{-84,68.24}}, color={0,0,127})); + -17},{-92,-17},{-92,68.24},{-84,68.24}}, color={0,0,127})); connect(AirExchangePort[2], Children1.AirExchangePort) annotation (Line(points={{-115, - -17},{-96,-17},{-96,88},{88,88},{88,68.68},{79.9,68.68}}, color={0,0,127})); + -14},{-96,-14},{-96,88},{88,88},{88,68.68},{79.9,68.68}}, color={0,0,127})); connect(AirExchangePort[3], Corridor.AirExchangePort) annotation (Line(points={{-115, -11},{-96,-11},{-96,88},{88,88},{88,4.205},{80,4.205}}, color={0,0,127})); - connect(AirExchangePort[4], Bath.AirExchangePort) annotation (Line(points={{-115,-5}, - {-96,-5},{-96,88},{88,88},{88,-76.68},{81.9,-76.68}}, color={0,0,127})); - connect(AirExchangePort[5], Children2.AirExchangePort) annotation (Line(points={{-115,1}, - {-92,1},{-92,-74.24},{-86,-74.24}}, color={0,0,127})); - connect(Bedroom.ports[1], portVent_in[1]) annotation (Line(points={{-65.05,13.52}, - {-58,13.52},{-58,-8},{-20,-8},{-20,-92},{94,-92},{94,-76},{104,-76}}, + connect(AirExchangePort[4], Bath.AirExchangePort) annotation (Line(points={{-115,-8}, + {-96,-8},{-96,88},{88,88},{88,-76.68},{81.9,-76.68}}, color={0,0,127})); + connect(AirExchangePort[5], Children2.AirExchangePort) annotation (Line(points={{-115,-5}, + {-92,-5},{-92,-74.24},{-86,-74.24}}, color={0,0,127})); + connect(Bedroom.ports[1], portVent_in[1]) annotation (Line(points={{-63.525,13.52}, + {-58,13.52},{-58,-8},{-20,-8},{-20,-92},{94,-92},{94,-72},{104,-72}}, color={0,127,255})); - connect(Bedroom.ports[2], portVent_out[1]) annotation (Line(points={{-58.95,13.52}, - {-58,13.52},{-58,-8},{-20,-8},{-20,-92},{104,-92}}, + connect(Bedroom.ports[2], portVent_out[1]) annotation (Line(points={{-60.475,13.52}, + {-58,13.52},{-58,-8},{-20,-8},{-20,-88},{104,-88}}, color={0,127,255})); - connect(Children1.ports[1], portVent_in[2]) annotation (Line(points={{61.8975, - 27.64},{40,27.64},{40,28},{20,28},{20,-92},{94,-92},{94,-72},{104,-72}}, + connect(Children1.ports[1], portVent_in[2]) annotation (Line(points={{60.4488, + 27.64},{40,27.64},{40,28},{20,28},{20,-92},{94,-92},{94,-70},{104,-70}}, color={0,127,255})); - connect(Children1.ports[2], portVent_out[2]) annotation (Line(points={{56.1025, - 27.64},{20,27.64},{20,-92},{94,-92},{94,-84},{104,-84},{104,-88}}, + connect(Children1.ports[2], portVent_out[2]) annotation (Line(points={{57.5512, + 27.64},{20,27.64},{20,-92},{94,-92},{94,-84},{104,-84},{104,-86}}, color={0,127,255})); - connect(Corridor.ports[1], portVent_in[3]) annotation (Line(points={{61.05,-28.285}, + connect(Corridor.ports[1], portVent_in[3]) annotation (Line(points={{59.525,-28.285}, {40,-28.285},{40,-28},{20,-28},{20,-92},{94,-92},{94,-68},{104,-68}}, color={0,127,255})); - connect(Corridor.ports[2], portVent_out[3]) annotation (Line(points={{54.95,-28.285}, - {54.95,-32},{20,-32},{20,-92},{94,-92},{94,-84},{104,-84}}, + connect(Corridor.ports[2], portVent_out[3]) annotation (Line(points={{56.475,-28.285}, + {56.475,-32},{20,-32},{20,-92},{94,-92},{94,-84},{104,-84}}, color={0,127,255})); - connect(Bath.ports[1], portVent_in[4]) annotation (Line(points={{63.8975,-35.64}, - {62,-35.64},{62,-32},{20,-32},{20,-92},{94,-92},{94,-64},{104,-64}}, + connect(Bath.ports[1], portVent_in[4]) annotation (Line(points={{62.4488, + -35.64},{62,-35.64},{62,-32},{20,-32},{20,-92},{94,-92},{94,-66},{104, + -66}}, color={0,127,255})); - connect(Bath.ports[2], portVent_out[4]) annotation (Line(points={{58.1025,-35.64}, - {58.1025,-32},{20,-32},{20,-92},{94,-92},{94,-80},{104,-80}}, + connect(Bath.ports[2], portVent_out[4]) annotation (Line(points={{59.5512, + -35.64},{59.5512,-32},{20,-32},{20,-92},{94,-92},{94,-82},{104,-82}}, color={0,127,255})); - connect(Children2.ports[1], portVent_in[5]) annotation (Line(points={{-67.05,-19.52}, - {-58,-19.52},{-58,-8},{-20,-8},{-20,-92},{94,-92},{94,-60},{104,-60}}, + connect(Children2.ports[1], portVent_in[5]) annotation (Line(points={{-65.525, + -19.52},{-58,-19.52},{-58,-8},{-20,-8},{-20,-92},{94,-92},{94,-64},{104, + -64}}, color={0,127,255})); - connect(Children2.ports[2], portVent_out[5]) annotation (Line(points={{-60.95, - -19.52},{-58,-19.52},{-58,-8},{-20,-8},{-20,-92},{94,-92},{94,-76},{104, - -76}}, + connect(Children2.ports[2], portVent_out[5]) annotation (Line(points={{-62.475, + -19.52},{-58,-19.52},{-58,-8},{-20,-8},{-20,-92},{94,-92},{94,-80},{104, + -80}}, color={0,127,255})); annotation (Icon(coordinateSystem(preserveAspectRatio=false, extent={{-100,-100}, diff --git a/AixLib/ThermalZones/HighOrder/House/OFD_MiddleInnerLoadWall/BuildingEnvelope/WholeHouseBuildingEnvelope.mo b/AixLib/ThermalZones/HighOrder/House/OFD_MiddleInnerLoadWall/BuildingEnvelope/WholeHouseBuildingEnvelope.mo index e9f0f6921f..381d81c263 100644 --- a/AixLib/ThermalZones/HighOrder/House/OFD_MiddleInnerLoadWall/BuildingEnvelope/WholeHouseBuildingEnvelope.mo +++ b/AixLib/ThermalZones/HighOrder/House/OFD_MiddleInnerLoadWall/BuildingEnvelope/WholeHouseBuildingEnvelope.mo @@ -192,7 +192,7 @@ model WholeHouseBuildingEnvelope alfa=1.5707963267949, replaceable package Medium = Medium) annotation (Placement(transformation(extent={{-22,44},{22,82}}))); - Modelica.Blocks.Interfaces.RealInput WindSpeedPort if (calcMethodOut == 1 or calcMethodOut == 2) + Modelica.Blocks.Interfaces.RealInput WindSpeedPort if (calcMethodOut == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.DIN_6946 or calcMethodOut == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.ASHRAE_Fundamentals) annotation (Placement( transformation(extent={{-128,66},{-100,94}}),iconTransformation(extent={{-120,60},{-100,80}}))); Modelica.Blocks.Interfaces.RealInput AirExchangePort[11] "1: LivingRoom_GF, 2: Hobby_GF, 3: Corridor_GF, 4: WC_Storage_GF, 5: Kitchen_GF, 6: Bedroom_UF, 7: Child1_UF, 8: Corridor_UF, 9: Bath_UF, 10: Child2_UF, 11: Attic" diff --git a/AixLib/ThermalZones/HighOrder/Rooms/ASHRAE140/EastWestFacingWindows.mo b/AixLib/ThermalZones/HighOrder/Rooms/ASHRAE140/EastWestFacingWindows.mo index c04d3d95d7..28e8452295 100644 --- a/AixLib/ThermalZones/HighOrder/Rooms/ASHRAE140/EastWestFacingWindows.mo +++ b/AixLib/ThermalZones/HighOrder/Rooms/ASHRAE140/EastWestFacingWindows.mo @@ -60,7 +60,7 @@ model EastWestFacingWindows "windows facing south and west" wallPar=wallTypes.groundPlate_upp_half, outside=false), ceiling( - ISOrientation=3, + ISOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.ceiling, withDoor=false, wallPar=wallTypes.roof, outside=true, diff --git a/AixLib/ThermalZones/HighOrder/Rooms/BaseClasses/PartialRoomParams.mo b/AixLib/ThermalZones/HighOrder/Rooms/BaseClasses/PartialRoomParams.mo index e4c1467448..3436ccb505 100644 --- a/AixLib/ThermalZones/HighOrder/Rooms/BaseClasses/PartialRoomParams.mo +++ b/AixLib/ThermalZones/HighOrder/Rooms/BaseClasses/PartialRoomParams.mo @@ -26,43 +26,32 @@ partial model PartialRoomParams "Partial model with base parameters that are nec //// Inner / Interior wall parameters // Heat convection - parameter Integer calcMethodIn=1 + parameter AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface calcMethodIn=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.EN_ISO_6946_Appendix_A "Calculation method of convective heat transfer coefficient at inside surface" annotation (Dialog( tab="Inner walls", group="Heat convection", compact=true, - descriptionLabel=true), choices( - choice=1 "EN ISO 6946 Appendix A >>Flat Surfaces<<", - choice=2 "By Bernd Glueck", - choice=3 "Custom hCon (constant)", - choice=4 "ASHRAE140-2017", - radioButtons=true)); + descriptionLabel=true)); parameter Modelica.Units.SI.CoefficientOfHeatTransfer hConIn_const=2.5 "Custom convective heat transfer coefficient (just for manual selection, not recommended)" annotation (Dialog( tab="Inner walls", group="Heat convection", - enable=(calcMethodIn == 3))); + enable=(calcMethodIn == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.Custom_hCon))); - parameter Integer radLongCalcMethod=1 "Calculation method for longwave radiation heat transfer" + parameter AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodRadiativeHeatTransfer radLongCalcMethod=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodRadiativeHeatTransfer.No_approx "Calculation method for longwave radiation heat transfer" annotation ( Evaluate=true, - Dialog(tab="Inner walls", group="Longwave radiation", compact=true), - choices( - choice=1 "No approx", - choice=2 "Linear approx at wall temp", - choice=3 "Linear approx at rad temp", - choice=4 "Linear approx at constant T_ref", - radioButtons=true)); + Dialog(tab="Inner walls", group="Longwave radiation", compact=true)); parameter Modelica.Units.SI.Temperature T_ref= Modelica.Units.Conversions.from_degC(16) "Reference temperature for optional linearization of longwave radiation" annotation (Dialog( tab="Inner walls", group="Longwave radiation", - enable=radLongCalcMethod == 4)); + enable=radLongCalcMethod == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodRadiativeHeatTransfer.Linear_constant_T_ref)); //// Outer / Exterior wall parameters //Window type @@ -81,23 +70,19 @@ partial model PartialRoomParams "Partial model with base parameters that are nec parameter Real solar_absorptance_OW(min=0, max=1)=0.6 "Solar absoptance outer walls " annotation (Dialog(tab="Outer walls", group="Solar absorptance", descriptionLabel=true)); // Heat convection - parameter Integer calcMethodOut=1 "Calculation method for convective heat transfer coefficient" + parameter AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer calcMethodOut=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.DIN_6946 "Calculation method for convective heat transfer coefficient" annotation (Dialog( tab="Outer walls", group="Heat convection", compact=true, - descriptionLabel=true), choices( - choice=1 "DIN 6946", - choice=2 "ASHRAE Fundamentals", - choice=3 "Custom hCon (constant)", - radioButtons=true)); - replaceable parameter DataBase.Surfaces.RoughnessForHT.PolynomialCoefficients_ASHRAEHandbook surfaceType=DataBase.Surfaces.RoughnessForHT.Brick_RoughPlaster() "Surface type of outside wall" annotation (Dialog(tab="Outer walls", group="Heat convection", enable=(calcMethodOut == 2))); + descriptionLabel=true)); + replaceable parameter DataBase.Surfaces.RoughnessForHT.PolynomialCoefficients_ASHRAEHandbook surfaceType=DataBase.Surfaces.RoughnessForHT.Brick_RoughPlaster() "Surface type of outside wall" annotation (Dialog(tab="Outer walls", group="Heat convection", enable=(calcMethodOut == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.ASHRAE_Fundamentals))); parameter Modelica.Units.SI.CoefficientOfHeatTransfer hConOut_const=25 "Custom convective heat transfer coefficient (just for manual selection, not recommended)" annotation (Dialog( tab="Outer walls", group="Heat convection", - enable=(calcMethodOut == 3))); + enable=(calcMethodOut == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.Custom_hCon))); // Sunblind parameter Boolean use_sunblind = false "Will sunblind become active automatically?" diff --git a/AixLib/ThermalZones/HighOrder/Rooms/OFD/Attic_Ro2Lf5.mo b/AixLib/ThermalZones/HighOrder/Rooms/OFD/Attic_Ro2Lf5.mo index 10809aac6a..6af319b29f 100644 --- a/AixLib/ThermalZones/HighOrder/Rooms/OFD/Attic_Ro2Lf5.mo +++ b/AixLib/ThermalZones/HighOrder/Rooms/OFD/Attic_Ro2Lf5.mo @@ -131,7 +131,7 @@ model Attic_Ro2Lf5 windowarea=windowarea_RO1, wall_length=length, wall_height=roof_width1, - ISOrientation=1, + ISOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.vertical_wall, redeclare final model WindowModel = WindowModel, redeclare final model CorrSolarGainWin = CorrSolarGainWin) annotation (Placement(transformation( @@ -162,7 +162,7 @@ model Attic_Ro2Lf5 withWindow=withWindow2, windowarea=windowarea_RO2, wall_length=length, - ISOrientation=1, + ISOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.vertical_wall, redeclare final model WindowModel = WindowModel, redeclare final model CorrSolarGainWin = CorrSolarGainWin) annotation (Placement(transformation( @@ -189,7 +189,7 @@ model Attic_Ro2Lf5 wall_length=room2_length, wall_height=room2_width, withWindow=false, - ISOrientation=2, + ISOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.floor, outside=false, redeclare final model WindowModel = WindowModel, redeclare final model CorrSolarGainWin = CorrSolarGainWin) @@ -217,7 +217,7 @@ model Attic_Ro2Lf5 wall_length=room1_length, wall_height=room1_width, withWindow=false, - ISOrientation=2, + ISOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.floor, outside=false, redeclare final model WindowModel = WindowModel, redeclare final model CorrSolarGainWin = CorrSolarGainWin) @@ -246,7 +246,7 @@ model Attic_Ro2Lf5 wall_length=room3_length, wall_height=room3_width, withWindow=false, - ISOrientation=2, + ISOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.floor, outside=false, redeclare final model WindowModel = WindowModel, redeclare final model CorrSolarGainWin = CorrSolarGainWin) @@ -274,7 +274,7 @@ model Attic_Ro2Lf5 wall_length=room4_length, wall_height=room4_width, withWindow=false, - ISOrientation=2, + ISOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.floor, outside=false, redeclare final model WindowModel = WindowModel, redeclare final model CorrSolarGainWin = CorrSolarGainWin) @@ -302,7 +302,7 @@ model Attic_Ro2Lf5 wall_length=room5_length, wall_height=room5_width, withWindow=false, - ISOrientation=2, + ISOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.floor, outside=false, redeclare final model WindowModel = WindowModel, redeclare final model CorrSolarGainWin = CorrSolarGainWin) @@ -331,7 +331,7 @@ model Attic_Ro2Lf5 door_height=0, door_width=0, windowarea=windowarea_RO1, - ISOrientation=1, + ISOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.vertical_wall, wall_length=sqrt(VerticalWall_Area), wall_height=sqrt(VerticalWall_Area), withWindow=false, @@ -359,7 +359,7 @@ model Attic_Ro2Lf5 door_height=0, door_width=0, windowarea=windowarea_RO1, - ISOrientation=1, + ISOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.vertical_wall, wall_length=sqrt(VerticalWall_Area), wall_height=sqrt(VerticalWall_Area), withWindow=false, @@ -408,7 +408,7 @@ model Attic_Ro2Lf5 extent={{-10,-10},{10,10}}, rotation=270, origin={-50,90}))); - Modelica.Blocks.Interfaces.RealInput WindSpeedPort if (calcMethodOut == 1 or calcMethodOut == 2) + Modelica.Blocks.Interfaces.RealInput WindSpeedPort if (calcMethodOut == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.DIN_6946 or calcMethodOut == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.ASHRAE_Fundamentals) annotation (Placement( transformation(extent={{-119.5,-10},{-99.5,10}}), iconTransformation( extent={{-119.5,10},{-99.5,30}}))); @@ -425,21 +425,21 @@ equation 255,128,0})); connect(SolarRadiationPort_RO2, roof2.SolarRadiationPort) annotation (Line( points={{48,100},{48,80},{71.75,80},{71.75,65.5}}, color={255,128,0})); - connect(roof1.WindSpeedPort, WindSpeedPort) annotation (Line(points={{-19.7333,64.25},{-19.7333,80},{-80,80},{-80,0},{-109.5,0}}, - color={0,0, + connect(roof1.WindSpeedPort, WindSpeedPort) annotation (Line(points={{ + -19.7333,64.25},{-19.7333,80},{-80,80},{-80,0},{-109.5,0}},color={0,0, 127})); connect(roof2.WindSpeedPort, WindSpeedPort) annotation (Line(points={{66.8,64.25},{66.8,80},{-80,80},{-80,0},{-109.5,0}}, color={0,0,127})); connect(floorRoom1.port_outside, thermRoom1) annotation (Line(points={{-60,-46.1},{-60,-90},{-90,-90}}, color={191,0,0})); - connect(floorRoom2.port_outside, thermRoom2) annotation (Line(points={{-29,-46.1},{-29,-90},{-50,-90}}, - color={191,0,0})); + connect(floorRoom2.port_outside, thermRoom2) annotation (Line(points={{-29, + -46.1},{-29,-90},{-50,-90}}, color={191,0,0})); connect(thermRoom3, floorRoom3.port_outside) annotation (Line(points={{-10,-90},{3,-90},{3,-46.1}}, color={191,0,0})); - connect(thermRoom4, floorRoom4.port_outside) annotation (Line(points={{30,-90},{38,-90},{38,-70},{35,-70},{35,-46.1}}, - color={191,0,0})); - connect(floorRoom5.port_outside, thermRoom5) annotation (Line(points={{69,-46.1},{69,-84},{72,-84},{72,-88},{70,-88},{70,-90}}, - color={191,0,0})); + connect(thermRoom4, floorRoom4.port_outside) annotation (Line(points={{30,-90}, + {38,-90},{38,-70},{35,-70},{35,-46.1}}, color={191,0,0})); + connect(floorRoom5.port_outside, thermRoom5) annotation (Line(points={{69, + -46.1},{69,-84},{72,-84},{72,-88},{70,-88},{70,-90}}, color={191,0,0})); connect(OW1.WindSpeedPort, WindSpeedPort) annotation (Line(points={{-81.2,-6.6},{-86,-6.6},{-86,0},{-109.5,0}}, color={0,0,127})); connect(OW1.SolarRadiationPort, SolarRadiationPort_OW1) annotation (Line( @@ -450,16 +450,22 @@ equation connect(OW2.SolarRadiationPort, SolarRadiationPort_OW2) annotation (Line( points={{90.2,3.25},{100,3.25},{100,-18},{110,-18}}, color={255,128,0})); connect(thermOutside, roof2.port_outside) annotation (Line(points={{-100,100},{-98,100},{-98,98},{-88,98},{-88,74},{47,74},{47,64.25}}, color={191,0,0})); - connect(thermOutside, roof1.port_outside) annotation (Line(points={{-100,100},{-88,100},{-88,74},{-41,74},{-41,64.25}}, color={191,0,0})); + connect(thermOutside, roof1.port_outside) annotation (Line(points={{-100,100}, + {-88,100},{-88,74},{-41,74},{-41,64.25}}, color={191,0,0})); connect(thermOutside, OW1.port_outside) annotation (Line(points={{-100,100},{-84,100},{-84,-22},{-81.2,-22}}, color={191,0,0})); connect(floorRoom1.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{-60,-42},{-60,-40},{-7,-40},{-7,-8}}, color={191,0,0})); - connect(floorRoom2.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{-29,-42},{-7,-42},{-7,-8}}, color={191,0,0})); - connect(floorRoom3.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{3,-42},{4,-42},{4,-38},{-7,-38},{-7,-8}}, color={191,0,0})); - connect(floorRoom4.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{35,-42},{36,-42},{36,-38},{-7,-38},{-7,-8}}, color={191,0,0})); - connect(floorRoom5.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{69,-42},{68,-42},{68,-38},{-7,-38},{-7,-8}}, color={191,0,0})); + connect(floorRoom2.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{-29,-42}, + {-7,-42},{-7,-8}}, color={191,0,0})); + connect(floorRoom3.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{3,-42}, + {4,-42},{4,-38},{-7,-38},{-7,-8}}, color={191,0,0})); + connect(floorRoom4.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{35,-42}, + {36,-42},{36,-38},{-7,-38},{-7,-8}}, color={191,0,0})); + connect(floorRoom5.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{69,-42}, + {68,-42},{68,-38},{-7,-38},{-7,-8}}, color={191,0,0})); connect(OW1.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{-73,-22},{-56,-22},{-56,-40},{-7,-40},{-7,-8}}, color={191,0,0})); - connect(roof1.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{-41,54},{-41,48},{-58,48},{-58,-22},{-56,-22},{-56,-40},{-7,-40},{-7,-8}}, color={191,0,0})); + connect(roof1.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{-41,54}, + {-41,48},{-58,48},{-58,-22},{-56,-22},{-56,-40},{-7,-40},{-7,-8}}, color={191,0,0})); connect(roof2.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{47,54},{48,54},{48,46},{-58,46},{-58,-22},{-56,-22},{-56,-40},{-7,-40},{-7,-8}}, color={191,0,0})); connect(OW2.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{81,-16},{76,-16},{76,-38},{-7,-38},{-7,-8}}, color={191,0,0})); connect(OW2.port_outside, thermOutside) annotation (Line(points={{89.2,-16},{94,-16},{94,100},{-100,100},{-100,100}}, color={191,0,0})); diff --git a/AixLib/ThermalZones/HighOrder/Rooms/OFD/Ow1IwL2IwS1Gr1Uf1.mo b/AixLib/ThermalZones/HighOrder/Rooms/OFD/Ow1IwL2IwS1Gr1Uf1.mo index e547679e45..017d3aec2c 100644 --- a/AixLib/ThermalZones/HighOrder/Rooms/OFD/Ow1IwL2IwS1Gr1Uf1.mo +++ b/AixLib/ThermalZones/HighOrder/Rooms/OFD/Ow1IwL2IwS1Gr1Uf1.mo @@ -187,7 +187,7 @@ model Ow1IwL2IwS1Gr1Uf1 wall_height=room_width, withWindow=false, withDoor=false, - ISOrientation=3, + ISOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.ceiling, redeclare final model WindowModel = WindowModel, redeclare final model CorrSolarGainWin = CorrSolarGainWin) annotation (Placement(transformation( @@ -216,7 +216,7 @@ model Ow1IwL2IwS1Gr1Uf1 wall_height=room_width, withWindow=false, withDoor=false, - ISOrientation=2, + ISOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.floor, redeclare final model WindowModel = WindowModel, redeclare final model CorrSolarGainWin = CorrSolarGainWin) annotation (Placement(transformation( origin={-27,-60}, @@ -254,7 +254,7 @@ model Ow1IwL2IwS1Gr1Uf1 annotation (Placement(transformation(extent={{34,-104},{54,-84}}))); Modelica.Thermal.HeatTransfer.Interfaces.HeatPort_a thermInsideWall2a annotation (Placement(transformation(extent={{80,20},{100,40}}))); - Modelica.Blocks.Interfaces.RealInput WindSpeedPort if (calcMethodOut == 1 or calcMethodOut == 2) + Modelica.Blocks.Interfaces.RealInput WindSpeedPort if (calcMethodOut == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.DIN_6946 or calcMethodOut == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.ASHRAE_Fundamentals) annotation (Placement( transformation(extent={{-119.5,-70},{-99.5,-50}}), iconTransformation( extent={{-109.5,-70},{-89.5,-50}}))); @@ -272,18 +272,18 @@ model Ow1IwL2IwS1Gr1Uf1 equation connect(thermInsideWall3, thermInsideWall3) annotation (Line(points={{44,-94},{44,-94}}, color={191,0,0})); - connect(inside_wall3.port_outside, thermInsideWall3) annotation (Line(points={{25,-64.25},{25,-77.375},{44,-77.375},{44,-94}}, - color={191,0,0})); + connect(inside_wall3.port_outside, thermInsideWall3) annotation (Line(points={{25, + -64.25},{25,-77.375},{44,-77.375},{44,-94}}, color={191,0,0})); connect(inside_wall2b.port_outside, thermInsideWall2b) annotation (Line( points={{64.15,-17},{77.225,-17},{77.225,-10},{90,-10}}, color={191,0,0})); connect(inside_wall2a.port_outside, thermInsideWall2a) annotation (Line( points={{64.15,23},{78.225,23},{78.225,30},{90,30}}, color={191,0,0})); - connect(inside_wall1.port_outside, thermInsideWall1) annotation (Line(points={{23,64.2502},{23,76.3751},{30,76.3751},{30,90}}, - color={191,0,0})); + connect(inside_wall1.port_outside, thermInsideWall1) annotation (Line(points={{23, + 64.2502},{23,76.3751},{30,76.3751},{30,90}}, color={191,0,0})); connect(Ceiling.port_outside, thermCeiling) annotation (Line(points={{-31,62.1},{-31,70},{90,70}}, color={191,0,0})); - connect(outside_wall1.WindSpeedPort, WindSpeedPort) annotation (Line(points={{-60.25,34.5333},{-80,34.5333},{-80,-60},{-109.5,-60}}, - color={0,0,127})); + connect(outside_wall1.WindSpeedPort, WindSpeedPort) annotation (Line(points={{-60.25, + 34.5333},{-80,34.5333},{-80,-60},{-109.5,-60}}, color={0,0,127})); connect(SolarRadiationPort_OW1, outside_wall1.SolarRadiationPort) annotation ( Line(points={{-99.5,60},{-80,60},{-80,39.6667},{-61.5,39.6667}}, color={ 255,128,0})); @@ -297,7 +297,8 @@ equation connect(inside_wall3.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{25,-54},{24,-54},{24,-48},{-7,-48},{-7,-8}}, color={191,0,0})); connect(inside_wall2b.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{58,-17},{56,-17},{56,-16},{50,-16},{50,-48},{-7,-48},{-7,-8}}, color={191,0,0})); connect(inside_wall2a.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{58,23},{56,23},{56,22},{50,22},{50,-48},{-7,-48},{-7,-8}}, color={191,0,0})); - connect(inside_wall1.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{23,54},{24,54},{24,44},{50,44},{50,-48},{-7,-48},{-7,-8}}, color={191,0,0})); + connect(inside_wall1.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{23,54}, + {24,54},{24,44},{50,44},{50,-48},{-7,-48},{-7,-8}}, color={191,0,0})); connect(Ceiling.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{-31,58},{-30,58},{-30,44},{50,44},{50,-48},{-7,-48},{-7,-8}}, color={191,0,0})); connect(outside_wall1.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{-50,14},{-44,14},{-44,44},{50,44},{50,-48},{-7,-48},{-7,-8}}, color={191,0,0})); connect(outside_wall1.port_outside, thermOutside) annotation (Line(points={{-60.25,14},{-78,14},{-78,100},{-100,100}}, color={191,0,0})); diff --git a/AixLib/ThermalZones/HighOrder/Rooms/OFD/Ow1IwL2IwS1Lf1At1Ro1.mo b/AixLib/ThermalZones/HighOrder/Rooms/OFD/Ow1IwL2IwS1Lf1At1Ro1.mo index c9081379a7..4e2ac62d9e 100644 --- a/AixLib/ThermalZones/HighOrder/Rooms/OFD/Ow1IwL2IwS1Lf1At1Ro1.mo +++ b/AixLib/ThermalZones/HighOrder/Rooms/OFD/Ow1IwL2IwS1Lf1At1Ro1.mo @@ -172,7 +172,7 @@ model Ow1IwL2IwS1Lf1At1Ro1 wall_height=room_width_short, withWindow=false, withDoor=false, - ISOrientation=3, + ISOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.ceiling, redeclare final model WindowModel = WindowModel, redeclare final model CorrSolarGainWin = CorrSolarGainWin) annotation (Placement(transformation( @@ -201,7 +201,7 @@ model Ow1IwL2IwS1Lf1At1Ro1 wall_height=room_width_long, withWindow=false, withDoor=false, - ISOrientation=2, + ISOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.floor, redeclare final model WindowModel = WindowModel, redeclare final model CorrSolarGainWin = CorrSolarGainWin) annotation (Placement(transformation( origin={-24,-60}, @@ -259,7 +259,7 @@ model Ow1IwL2IwS1Lf1At1Ro1 wall_height=roof_width, withWindow=withWindow3, windowarea=windowarea_RO, - ISOrientation=1, + ISOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.vertical_wall, redeclare final model WindowModel = WindowModel, redeclare final model CorrSolarGainWin = CorrSolarGainWin) annotation (Placement(transformation( @@ -271,7 +271,7 @@ model Ow1IwL2IwS1Lf1At1Ro1 iconTransformation(extent={{20,-100},{40,-80}}))); Modelica.Thermal.HeatTransfer.Interfaces.HeatPort_a thermInsideWall2a annotation (Placement(transformation(extent={{80,0},{100,20}}))); - Modelica.Blocks.Interfaces.RealInput WindSpeedPort if (calcMethodOut == 1 or calcMethodOut == 2) + Modelica.Blocks.Interfaces.RealInput WindSpeedPort if (calcMethodOut == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.DIN_6946 or calcMethodOut == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.ASHRAE_Fundamentals) annotation (Placement(transformation(extent={{-119.5,-70},{-99.5,-50}}), iconTransformation(extent={{-109.5,-60},{-89.5,-40}}))); Utilities.Interfaces.SolarRad_in SolarRadiationPort_OW1 annotation (Placement(transformation(extent={{-109.5,20},{-89.5,40}}))); @@ -292,8 +292,8 @@ model Ow1IwL2IwS1Lf1At1Ro1 iconTransformation(extent={{-20,80},{0,100}}))); equation - connect(outside_wall1.WindSpeedPort, WindSpeedPort) annotation (Line(points={{-60.25,38.2667},{-80,38.2667},{-80,-60},{-109.5,-60}}, - color={0,0,127})); + connect(outside_wall1.WindSpeedPort, WindSpeedPort) annotation (Line(points={{-60.25, + 38.2667},{-80,38.2667},{-80,-60},{-109.5,-60}}, color={0,0,127})); connect(outside_wall1.SolarRadiationPort, SolarRadiationPort_OW1) annotation ( Line(points={{-61.5,43.5833},{-80,43.5833},{-80,30},{-99.5,30}}, color={0, 0,0})); @@ -301,8 +301,8 @@ equation {{20,-64.2},{20,-74},{30,-74},{30,-90}}, color={191,0,0})); connect(thermInsideWall3, thermInsideWall3) annotation (Line(points={{30,-90},{30,-90}}, color={191,0,0})); - connect(Ceiling.port_outside, thermCeiling) annotation (Line(points={{28,62.1},{28,72},{92,72},{92,50},{90,50}}, - color={191,0,0})); + connect(Ceiling.port_outside, thermCeiling) annotation (Line(points={{28,62.1}, + {28,72},{92,72},{92,50},{90,50}}, color={191,0,0})); connect(inside_wall2b.port_outside, thermInsideWall2b) annotation (Line(points={{64.15,-20},{90,-20},{90,-30}}, color={191,0,0})); connect(inside_wall2a.port_outside, thermInsideWall2a) annotation (Line( @@ -311,20 +311,25 @@ equation annotation (Line(points={{-14,62.2},{-14,90},{-10,90}}, color={191,0,0})); connect(roof.SolarRadiationPort, SolarRadiationPort_Roof) annotation (Line( points={{72.6667,62.9},{72.6667,72},{74,72},{74,100}}, color={255,128,0})); - connect(roof.WindSpeedPort, WindSpeedPort) annotation (Line(points={{69.7333,62.15},{69.7333,72},{-80,72},{-80,-60},{-109.5,-60}}, - color={0,0,127})); + connect(roof.WindSpeedPort, WindSpeedPort) annotation (Line(points={{69.7333, + 62.15},{69.7333,72},{-80,72},{-80,-60},{-109.5,-60}},color={0,0,127})); connect(thermFloor, floor.port_outside) annotation (Line( points={{-6,-94},{-8,-94},{-8,-66},{-22,-66},{-22,-62.1},{-24,-62.1}}, color={191,0,0}, pattern=LinePattern.Dash)); connect(thermOutside, outside_wall1.port_outside) annotation (Line(points={{-100,100},{-78,100},{-78,17},{-60.25,17}}, color={191,0,0})); - connect(roof.port_outside, thermOutside) annotation (Line(points={{58,62.15},{58,76},{-62,76},{-62,100},{-100,100}}, color={191,0,0})); - connect(floor.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{-24,-58},{-24,-46},{-7,-46},{-7,-8}}, color={191,0,0})); + connect(roof.port_outside, thermOutside) annotation (Line(points={{58,62.15}, + {58,76},{-62,76},{-62,100},{-100,100}}, color={191,0,0})); + connect(floor.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{-24,-58}, + {-24,-46},{-7,-46},{-7,-8}}, color={191,0,0})); connect(inside_wall3.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{20,-56},{20,-46},{-7,-46},{-7,-8}}, color={191,0,0})); - connect(inside_wall2b.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{58,-20},{48,-20},{48,-46},{-7,-46},{-7,-8}}, color={191,0,0})); + connect(inside_wall2b.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{58,-20}, + {48,-20},{48,-46},{-7,-46},{-7,-8}}, color={191,0,0})); connect(inside_wall2a.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{58,19},{48,19},{48,-46},{-7,-46},{-7,-8}}, color={191,0,0})); - connect(roof.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{58,56},{58,50},{48,50},{48,-46},{-7,-46},{-7,-8}}, color={191,0,0})); - connect(Ceiling.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{28,58},{28,48},{48,48},{48,-46},{-7,-46},{-7,-8}}, color={191,0,0})); + connect(roof.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{58,56}, + {58,50},{48,50},{48,-46},{-7,-46},{-7,-8}}, color={191,0,0})); + connect(Ceiling.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{28,58}, + {28,48},{48,48},{48,-46},{-7,-46},{-7,-8}}, color={191,0,0})); connect(inner_wall1.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{-14,54},{-14,48},{48,48},{48,-46},{-7,-46},{-7,-8}}, color={191,0,0})); connect(outside_wall1.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{-50,17},{-44,17},{-44,48},{48,48},{48,-46},{-7,-46},{-7,-8}}, color={191,0,0})); annotation (Icon(graphics={ diff --git a/AixLib/ThermalZones/HighOrder/Rooms/OFD/Ow2IwL1IwS1Gr1Uf1.mo b/AixLib/ThermalZones/HighOrder/Rooms/OFD/Ow2IwL1IwS1Gr1Uf1.mo index a1f95093e3..c2acb4a664 100644 --- a/AixLib/ThermalZones/HighOrder/Rooms/OFD/Ow2IwL1IwS1Gr1Uf1.mo +++ b/AixLib/ThermalZones/HighOrder/Rooms/OFD/Ow2IwL1IwS1Gr1Uf1.mo @@ -225,7 +225,7 @@ model Ow2IwL1IwS1Gr1Uf1 wall_height=room_width, withWindow=false, withDoor=false, - ISOrientation=3, + ISOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.ceiling, redeclare final model WindowModel = WindowModel, redeclare final model CorrSolarGainWin = CorrSolarGainWin) annotation (Placement(transformation( @@ -254,7 +254,7 @@ model Ow2IwL1IwS1Gr1Uf1 withWindow=false, outside=false, withDoor=false, - ISOrientation=2, + ISOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.floor, redeclare final model WindowModel = WindowModel, redeclare final model CorrSolarGainWin = CorrSolarGainWin) annotation (Placement(transformation( origin={-29,-65}, @@ -264,7 +264,7 @@ model Ow2IwL1IwS1Gr1Uf1 annotation (Placement(transformation(extent={{20,-100},{40,-80}}))); Modelica.Thermal.HeatTransfer.Interfaces.HeatPort_a thermInsideWall1 annotation (Placement(transformation(extent={{80,0},{100,20}}))); - Modelica.Blocks.Interfaces.RealInput WindSpeedPort if (calcMethodOut == 1 or calcMethodOut == 2) + Modelica.Blocks.Interfaces.RealInput WindSpeedPort if (calcMethodOut == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.DIN_6946 or calcMethodOut == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.ASHRAE_Fundamentals) annotation (Placement(transformation(extent={{-119.5,-70},{-99.5,-50}}), iconTransformation(extent={{-109.5,-50},{-89.5,-30}}))); Utilities.Interfaces.SolarRad_in SolarRadiationPort_OW1 annotation (Placement(transformation(extent={{-109.5,20},{-89.5,40}}))); @@ -279,13 +279,14 @@ model Ow2IwL1IwS1Gr1Uf1 annotation (Placement(transformation(extent={{-16,-104},{4,-84}}))); equation - connect(outside_wall1.WindSpeedPort, WindSpeedPort) annotation (Line(points={{-60.25,33.4667},{-80,33.4667},{-80,-60},{-109.5,-60}}, - color={0,0,127})); + connect(outside_wall1.WindSpeedPort, WindSpeedPort) annotation (Line(points={{-60.25, + 33.4667},{-80,33.4667},{-80,-60},{-109.5,-60}}, color={0,0,127})); connect(thermInsideWall2, thermInsideWall2) annotation (Line(points={{30,-90},{30,-90}}, color={191,0,0})); connect(inside_wall1.port_outside, thermInsideWall1) annotation (Line(points={{64.3,5},{90,5},{90,10}}, color={191,0,0})); - connect(outside_wall2.WindSpeedPort, WindSpeedPort) annotation (Line(points={{40.2667,62.2502},{40.2667,70},{-80,70},{-80,-60},{-109.5,-60}}, + connect(outside_wall2.WindSpeedPort, WindSpeedPort) annotation (Line(points={{40.2667, + 62.2502},{40.2667,70},{-80,70},{-80,-60},{-109.5,-60}}, color={0,0,127})); connect(outside_wall2.SolarRadiationPort, SolarRadiationPort_OW2) annotation ( Line(points={{45.5833,63.5002},{45.5833,80.7501},{50.5,80.7501},{50.5,99}}, @@ -301,14 +302,18 @@ equation points={{-6,-94},{-6,-74},{-24,-74},{-24,-68.15},{-29,-68.15}}, color={191,0,0}, pattern=LinePattern.Dash)); - connect(outside_wall2.port_outside, thermOutside) annotation (Line(points={{19,62.2502},{19,76},{-56,76},{-56,100},{-100,100}}, color={191,0,0})); + connect(outside_wall2.port_outside, thermOutside) annotation (Line(points={{19, + 62.2502},{19,76},{-56,76},{-56,100},{-100,100}}, color={191,0,0})); connect(thermOutside, outside_wall1.port_outside) annotation (Line(points={{-100,100},{-78,100},{-78,10},{-60.25,10}}, color={191,0,0})); - connect(floor.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{-29,-62},{-30,-62},{-30,-44},{-7,-44},{-7,-8}}, color={191,0,0})); + connect(floor.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{-29,-62}, + {-30,-62},{-30,-44},{-7,-44},{-7,-8}}, color={191,0,0})); connect(inside_wall2.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{16,-56},{16,-44},{-7,-44},{-7,-8}}, color={191,0,0})); connect(inside_wall1.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{52,5},{42,5},{42,-44},{-7,-44},{-7,-8}}, color={191,0,0})); - connect(outside_wall2.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{19,52},{18,52},{18,38},{42,38},{42,-44},{-7,-44},{-7,-8}}, color={191,0,0})); - connect(Ceiling.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{-30,56},{-30,38},{42,38},{42,-44},{-7,-44},{-7,-8}}, color={191,0,0})); + connect(outside_wall2.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{19,52}, + {18,52},{18,38},{42,38},{42,-44},{-7,-44},{-7,-8}}, color={191,0,0})); + connect(Ceiling.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{-30,56}, + {-30,38},{42,38},{42,-44},{-7,-44},{-7,-8}}, color={191,0,0})); connect(outside_wall1.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{-50,10},{-40,10},{-40,38},{42,38},{42,-44},{-7,-44},{-7,-8}}, color={191,0,0})); annotation (Icon(coordinateSystem(preserveAspectRatio=false, extent={{-100,-100}, {100,100}}), graphics={ diff --git a/AixLib/ThermalZones/HighOrder/Rooms/OFD/Ow2IwL1IwS1Lf1At1Ro1.mo b/AixLib/ThermalZones/HighOrder/Rooms/OFD/Ow2IwL1IwS1Lf1At1Ro1.mo index 6a5412bf1f..5706264669 100644 --- a/AixLib/ThermalZones/HighOrder/Rooms/OFD/Ow2IwL1IwS1Lf1At1Ro1.mo +++ b/AixLib/ThermalZones/HighOrder/Rooms/OFD/Ow2IwL1IwS1Lf1At1Ro1.mo @@ -119,7 +119,7 @@ model Ow2IwL1IwS1Lf1At1Ro1 withDoor=withDoor2, wall_length=room_width_long, wall_height=0.5*(room_height_long + room_height_short + room_width_short/room_width_long*(room_height_long - room_height_short)), - ISOrientation=1, + ISOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.vertical_wall, U_door=U_door_OD2, eps_door=eps_door_OD2, redeclare final model WindowModel = WindowModel, @@ -206,7 +206,7 @@ model Ow2IwL1IwS1Lf1At1Ro1 wall_height=room_width_short, withWindow=false, withDoor=false, - ISOrientation=3, + ISOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.ceiling, redeclare final model WindowModel = WindowModel, redeclare final model CorrSolarGainWin = CorrSolarGainWin) annotation (Placement(transformation( @@ -235,7 +235,7 @@ model Ow2IwL1IwS1Lf1At1Ro1 wall_height=room_width_long, withWindow=false, withDoor=false, - ISOrientation=2, + ISOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.floor, redeclare final model WindowModel = WindowModel, redeclare final model CorrSolarGainWin = CorrSolarGainWin) annotation (Placement(transformation( origin={-27,-60}, @@ -275,7 +275,7 @@ model Ow2IwL1IwS1Lf1At1Ro1 annotation (Placement(transformation(extent={{20,-100},{40,-80}}))); Modelica.Thermal.HeatTransfer.Interfaces.HeatPort_a thermInsideWall1 annotation (Placement(transformation(extent={{80,0},{100,20}}))); - Modelica.Blocks.Interfaces.RealInput WindSpeedPort if (calcMethodOut == 1 or calcMethodOut == 2) + Modelica.Blocks.Interfaces.RealInput WindSpeedPort if (calcMethodOut == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.DIN_6946 or calcMethodOut == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.ASHRAE_Fundamentals) annotation (Placement(transformation(extent={{-119.5,-70},{-99.5,-50}}), iconTransformation(extent={{-109.5,-50},{-89.5,-30}}))); Utilities.Interfaces.SolarRad_in SolarRadiationPort_OW1 annotation (Placement(transformation(extent={{-109.5,20},{-89.5,40}}))); @@ -297,17 +297,18 @@ model Ow2IwL1IwS1Lf1At1Ro1 equation - connect(outside_wall1.WindSpeedPort, WindSpeedPort) annotation (Line(points={{-62.25,30.2667},{-80,30.2667},{-80,-60},{-109.5,-60}}, - color={0,0,127})); - connect(inside_wall2.port_outside, thermInsideWall2) annotation (Line(points={{32,-64.25},{32,-72},{30,-72},{30,-90}}, - color={191,0,0})); + connect(outside_wall1.WindSpeedPort, WindSpeedPort) annotation (Line(points={{-62.25, + 30.2667},{-80,30.2667},{-80,-60},{-109.5,-60}}, color={0,0,127})); + connect(inside_wall2.port_outside, thermInsideWall2) annotation (Line(points={{32, + -64.25},{32,-72},{30,-72},{30,-90}}, color={191,0,0})); connect(thermInsideWall2, thermInsideWall2) annotation (Line(points={{30,-90},{30,-90}}, color={191,0,0})); - connect(inside_wall1.port_outside, thermInsideWall1) annotation (Line(points={{66.25,4.00001},{90,4.00001},{90,10}}, - color={191,0,0})); + connect(inside_wall1.port_outside, thermInsideWall1) annotation (Line(points={{66.25, + 4.00001},{90,4.00001},{90,10}}, color={191,0,0})); connect(Ceiling.port_outside, thermCeiling) annotation (Line(points={{22,62.1},{22,70},{90,70}}, color={191,0,0})); - connect(outside_wall2.WindSpeedPort, WindSpeedPort) annotation (Line(points={{-7.73333,64.25},{-7.73333,70},{-80,70},{-80,-60},{-109.5,-60}}, + connect(outside_wall2.WindSpeedPort, WindSpeedPort) annotation (Line(points={{ + -7.73333,64.25},{-7.73333,70},{-80,70},{-80,-60},{-109.5,-60}}, color={0,0,127})); connect(SolarRadiationPort_OW1, outside_wall1.SolarRadiationPort) annotation ( Line(points={{-99.5,30},{-63.5,30},{-63.5,35.5833}}, color={255,128,0})); @@ -317,21 +318,28 @@ equation connect(roof.SolarRadiationPort, SolarRadiationPort_Roof) annotation (Line( points={{70.5833,62.8999},{70.5833,70},{74,70},{74,100}}, color={255,128, 0})); - connect(roof.WindSpeedPort, WindSpeedPort) annotation (Line(points={{67.4667,62.1499},{67.4667,70},{-80,70},{-80,-60},{-109.5,-60}}, + connect(roof.WindSpeedPort, WindSpeedPort) annotation (Line(points={{67.4667, + 62.1499},{67.4667,70},{-80,70},{-80,-60},{-109.5,-60}}, color={0,0,127})); connect(thermFloor, floor.port_outside) annotation (Line( points={{-6,-94},{-8,-94},{-8,-66},{-22,-66},{-22,-62.1},{-27,-62.1}}, color={191,0,0}, pattern=LinePattern.Dash)); - connect(outside_wall2.port_outside, thermOutside) annotation (Line(points={{-29,64.25},{-29,100},{-100,100}}, color={191,0,0})); - connect(roof.port_outside, thermOutside) annotation (Line(points={{55,62.1499},{55,72},{-29,72},{-29,100},{-100,100}}, color={191,0,0})); + connect(outside_wall2.port_outside, thermOutside) annotation (Line(points={{-29, + 64.25},{-29,100},{-100,100}}, color={191,0,0})); + connect(roof.port_outside, thermOutside) annotation (Line(points={{55,62.1499}, + {55,72},{-29,72},{-29,100},{-100,100}}, color={191,0,0})); connect(outside_wall1.port_outside, thermOutside) annotation (Line(points={{-62.25,9},{-76,9},{-76,100},{-100,100}}, color={191,0,0})); connect(floor.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{-27,-58},{-28,-58},{-28,-48},{-7,-48},{-7,-8}}, color={191,0,0})); - connect(inside_wall2.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{32,-54},{32,-48},{-6,-48},{-6,-28},{-7,-28},{-7,-8}}, color={191,0,0})); + connect(inside_wall2.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{32,-54}, + {32,-48},{-6,-48},{-6,-28},{-7,-28},{-7,-8}}, color={191,0,0})); connect(inside_wall1.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{56,4.00001},{54,4.00001},{54,4},{44,4},{44,-48},{-6,-48},{-6,-28},{-7,-28},{-7,-8}}, color={191,0,0})); - connect(roof.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{55,56},{54,56},{54,50},{44,50},{44,-48},{-6,-48},{-6,-28},{-7,-28},{-7,-8}}, color={191,0,0})); - connect(Ceiling.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{22,58},{22,50},{44,50},{44,-48},{-6,-48},{-6,-28},{-7,-28},{-7,-8}}, color={191,0,0})); - connect(outside_wall2.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{-29,54},{-30,54},{-30,50},{44,50},{44,-48},{-6,-48},{-6,-28},{-7,-28},{-7,-8}}, color={191,0,0})); + connect(roof.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{55,56}, + {54,56},{54,50},{44,50},{44,-48},{-6,-48},{-6,-28},{-7,-28},{-7,-8}}, color={191,0,0})); + connect(Ceiling.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{22,58}, + {22,50},{44,50},{44,-48},{-6,-48},{-6,-28},{-7,-28},{-7,-8}}, color={191,0,0})); + connect(outside_wall2.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{-29,54}, + {-30,54},{-30,50},{44,50},{44,-48},{-6,-48},{-6,-28},{-7,-28},{-7,-8}}, color={191,0,0})); connect(outside_wall1.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{-52,9},{-40,9},{-40,50},{44,50},{44,-48},{-6,-48},{-6,-28},{-7,-28},{-7,-8}}, color={191,0,0})); annotation (Icon(graphics={ Rectangle( diff --git a/AixLib/ThermalZones/HighOrder/Rooms/OFD/Ow2IwL2IwS1Gr1Uf1.mo b/AixLib/ThermalZones/HighOrder/Rooms/OFD/Ow2IwL2IwS1Gr1Uf1.mo index 7c0bf2cbaa..2713ffe7ed 100644 --- a/AixLib/ThermalZones/HighOrder/Rooms/OFD/Ow2IwL2IwS1Gr1Uf1.mo +++ b/AixLib/ThermalZones/HighOrder/Rooms/OFD/Ow2IwL2IwS1Gr1Uf1.mo @@ -229,7 +229,7 @@ model Ow2IwL2IwS1Gr1Uf1 wall_height=room_width, withWindow=false, withDoor=false, - ISOrientation=3, + ISOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.ceiling, redeclare final model WindowModel = WindowModel, redeclare final model CorrSolarGainWin = CorrSolarGainWin) annotation (Placement(transformation( @@ -258,7 +258,7 @@ model Ow2IwL2IwS1Gr1Uf1 wall_height=room_width, withWindow=false, withDoor=false, - ISOrientation=2, + ISOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.floor, redeclare final model WindowModel = WindowModel, redeclare final model CorrSolarGainWin = CorrSolarGainWin) annotation (Placement(transformation( @@ -297,7 +297,7 @@ model Ow2IwL2IwS1Gr1Uf1 annotation (Placement(transformation(extent={{20,-100},{40,-80}}))); Modelica.Thermal.HeatTransfer.Interfaces.HeatPort_a thermInsideWall1a annotation (Placement(transformation(extent={{80,20},{100,40}}))); - Modelica.Blocks.Interfaces.RealInput WindSpeedPort if (calcMethodOut == 1 or calcMethodOut == 2) + Modelica.Blocks.Interfaces.RealInput WindSpeedPort if (calcMethodOut == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.DIN_6946 or calcMethodOut == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.ASHRAE_Fundamentals) annotation (Placement(transformation(extent={{-119.5,-70},{-99.5,-50}}), iconTransformation(extent={{-109.5,-50},{-89.5,-30}}))); Utilities.Interfaces.SolarRad_in SolarRadiationPort_OW1 annotation (Placement(transformation(extent={{-109.5,20},{-89.5,40}}))); @@ -319,17 +319,18 @@ model Ow2IwL2IwS1Gr1Uf1 equation connect(thermInsideWall2, thermInsideWall2) annotation (Line(points={{30,-90},{30,-90}}, color={191,0,0})); - connect(WindSpeedPort, outside_wall2.WindSpeedPort) annotation (Line(points={{-109.5,-60},{-80,-60},{-80,74},{42.8,74},{42.8,64.25}}, - color={0,0,127})); - connect(outside_wall1.WindSpeedPort, WindSpeedPort) annotation (Line(points={{-58.25,36.2667},{-80,36.2667},{-80,-60},{-109.5,-60}}, - color={0,0,127})); + connect(WindSpeedPort, outside_wall2.WindSpeedPort) annotation (Line(points={{-109.5, + -60},{-80,-60},{-80,74},{42.8,74},{42.8,64.25}}, color={0,0,127})); + connect(outside_wall1.WindSpeedPort, WindSpeedPort) annotation (Line(points={{-58.25, + 36.2667},{-80,36.2667},{-80,-60},{-109.5,-60}}, color={0,0,127})); connect(outside_wall2.SolarRadiationPort, SolarRadiationPort_OW2) annotation ( Line(points={{47.75,65.5},{47.75,74},{50.5,74},{50.5,88},{50.5,101}}, color={255,128,0})); - connect(Ceiling.port_outside, thermCeiling) annotation (Line(points={{-30,64.15},{-30,64.15},{-30,74},{84,74},{84,70},{90,70}}, + connect(Ceiling.port_outside, thermCeiling) annotation (Line(points={{-30, + 64.15},{-30,64.15},{-30,74},{84,74},{84,70},{90,70}}, color={191,0,0})); - connect(inside_wall2.port_outside, thermInsideWall2) annotation (Line(points={{22,-64.2},{22,-77.3},{30,-77.3},{30,-90}}, - color={191,0,0})); + connect(inside_wall2.port_outside, thermInsideWall2) annotation (Line(points={{22, + -64.2},{22,-77.3},{30,-77.3},{30,-90}}, color={191,0,0})); connect(inside_wall1a.port_outside, thermInsideWall1a) annotation (Line( points={{64.15,24},{77.225,24},{77.225,30},{90,30}}, color={191,0,0})); connect(inside_wall1b.port_outside, thermInsideWall1b) annotation (Line( @@ -344,13 +345,16 @@ equation color={191,0,0}, pattern=LinePattern.Dash)); connect(outside_wall1.port_outside, thermOutside) annotation (Line(points={{-58.25,15},{-76,15},{-76,100},{-100,100}}, color={191,0,0})); - connect(outside_wall2.port_outside, thermOutside) annotation (Line(points={{23,64.25},{23,76},{-52,76},{-52,100},{-100,100}}, color={191,0,0})); + connect(outside_wall2.port_outside, thermOutside) annotation (Line(points={{23, + 64.25},{23,76},{-52,76},{-52,100},{-100,100}}, color={191,0,0})); connect(floor.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{-27,-58},{-26,-58},{-26,-48},{-7,-48},{-7,-8}}, color={191,0,0})); connect(inside_wall2.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{22,-56},{22,-46},{-6,-46},{-6,-42},{-7,-42},{-7,-8}}, color={191,0,0})); connect(inside_wall1b.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{58,-15},{54,-15},{54,-46},{-6,-46},{-6,-42},{-7,-42},{-7,-8}}, color={191,0,0})); - connect(inside_wall1a.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{58,24},{54,24},{54,-46},{-6,-46},{-6,-42},{-7,-42},{-7,-8}}, color={191,0,0})); + connect(inside_wall1a.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{58,24}, + {54,24},{54,-46},{-6,-46},{-6,-42},{-7,-42},{-7,-8}}, color={191,0,0})); connect(outside_wall2.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{23,54},{24,54},{24,46},{54,46},{54,-46},{-6,-46},{-6,-42},{-7,-42},{-7,-8}}, color={191,0,0})); - connect(Ceiling.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{-30,58},{-30,46},{54,46},{54,-46},{-6,-46},{-6,-42},{-7,-42},{-7,-8}}, color={191,0,0})); + connect(Ceiling.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{-30,58}, + {-30,46},{54,46},{54,-46},{-6,-46},{-6,-42},{-7,-42},{-7,-8}}, color={191,0,0})); connect(outside_wall1.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{-48,15},{-42,15},{-42,46},{54,46},{54,-46},{-6,-46},{-6,-42},{-7,-42},{-7,-8}}, color={191,0,0})); annotation (Icon(graphics={ Rectangle( diff --git a/AixLib/ThermalZones/HighOrder/Rooms/OFD/Ow2IwL2IwS1Lf1At1Ro1.mo b/AixLib/ThermalZones/HighOrder/Rooms/OFD/Ow2IwL2IwS1Lf1At1Ro1.mo index 3dcfbfe660..394181689d 100644 --- a/AixLib/ThermalZones/HighOrder/Rooms/OFD/Ow2IwL2IwS1Lf1At1Ro1.mo +++ b/AixLib/ThermalZones/HighOrder/Rooms/OFD/Ow2IwL2IwS1Lf1At1Ro1.mo @@ -209,7 +209,7 @@ model Ow2IwL2IwS1Lf1At1Ro1 wall_height=room_width_short, withWindow=false, withDoor=false, - ISOrientation=3) annotation (Placement(transformation( + ISOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.ceiling) annotation (Placement(transformation( origin={28,60}, extent={{1.99999,-10},{-1.99998,10}}, rotation=90))); @@ -237,7 +237,7 @@ model Ow2IwL2IwS1Lf1At1Ro1 wall_height=room_width_long, withWindow=false, withDoor=false, - ISOrientation=2) annotation (Placement(transformation( + ISOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.floor) annotation (Placement(transformation( origin={-24,-60}, extent={{-1.99999,-10},{1.99999,10}}, rotation=90))); @@ -325,7 +325,7 @@ model Ow2IwL2IwS1Lf1At1Ro1 Modelica.Thermal.HeatTransfer.Interfaces.HeatPort_a thermFloor annotation ( Placement(transformation(extent={{-16,-104},{4,-84}}), iconTransformation( extent={{-16,-104},{4,-84}}))); - Modelica.Blocks.Interfaces.RealInput WindSpeedPort if (calcMethodOut == 1 or calcMethodOut == 2) + Modelica.Blocks.Interfaces.RealInput WindSpeedPort if (calcMethodOut == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.DIN_6946 or calcMethodOut == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.ASHRAE_Fundamentals) annotation (Placement(transformation(extent={{-126,-74},{-99.5,-48}}), iconTransformation(extent={{-109.5,-60},{-89.5,-40}}))); @@ -344,28 +344,34 @@ equation points={{62.1,19},{84,19},{84,20},{90,20},{90,10}}, color={191,0,0})); connect(roof.SolarRadiationPort, SolarRadiationPort_Roof) annotation (Line( points={{74.5833,62.9},{74.5833,92},{74,92},{74,100}}, color={255,128,0})); - connect(Ceiling.port_outside, thermCeiling) annotation (Line(points={{28,62.1},{28,62.1},{28,74},{90,74},{90,50}}, - color={191,0,0})); + connect(Ceiling.port_outside, thermCeiling) annotation (Line(points={{28,62.1}, + {28,62.1},{28,74},{90,74},{90,50}}, color={191,0,0})); connect(outside_wall2.SolarRadiationPort, SolarRadiationPort_OW2) annotation ( Line(points={{5.25,65.8},{5.25,74},{44.5,74},{44.5,101}}, color={255,128,0})); - connect(thermFloor, floor.port_outside) annotation (Line(points={{-6,-94},{-8,-94},{-8,-70},{-24,-70},{-24,-62.1}}, color={191,0,0})); + connect(thermFloor, floor.port_outside) annotation (Line(points={{-6,-94},{-8, + -94},{-8,-70},{-24,-70},{-24,-62.1}}, color={191,0,0})); connect(outside_wall2.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{-25,52},{-25,40},{40,40},{40,-40},{-7,-40},{-7,-8}}, color={191,0,0})); - connect(roof.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{59,56},{59,40},{40,40},{40,-40},{-7,-40},{-7,-8}}, color={191,0,0})); - connect(Ceiling.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{28,58},{28,40},{40,40},{40,-40},{-7,-40},{-7,-8}}, color={191,0,0})); + connect(roof.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{59,56}, + {59,40},{40,40},{40,-40},{-7,-40},{-7,-8}}, color={191,0,0})); + connect(Ceiling.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{28,58}, + {28,40},{40,40},{40,-40},{-7,-40},{-7,-8}}, color={191,0,0})); connect(inside_wall1b.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{58,-19},{40,-19},{40,-40},{-7,-40},{-7,-8}}, color={191,0,0})); connect(inside_wall1a.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{58,19},{40,19},{40,-40},{-7,-40},{-7,-8}}, color={191,0,0})); - connect(inside_wall2.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{28,-56},{28,-40},{-6,-40},{-6,-8},{-7,-8}}, color={191,0,0})); + connect(inside_wall2.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{28,-56}, + {28,-40},{-6,-40},{-6,-8},{-7,-8}}, color={191,0,0})); connect(outside_wall1.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{-78,4},{-74,4},{-74,-40},{-7,-40},{-7,-8}}, color={191,0,0})); - connect(WindSpeedPort, outside_wall1.WindSpeedPort) annotation (Line(points={{-112.75,-61},{-96,-61},{-96,24.5333},{-88.25,24.5333}}, - color={0,0,127})); - connect(WindSpeedPort, roof.WindSpeedPort) annotation (Line(points={{-112.75,-61},{-96,-61},{-96,70},{71.4667,70},{71.4667,62.15}}, - color={0,0,127})); + connect(WindSpeedPort, outside_wall1.WindSpeedPort) annotation (Line(points={{-112.75, + -61},{-96,-61},{-96,24.5333},{-88.25,24.5333}}, color={0,0,127})); + connect(WindSpeedPort, roof.WindSpeedPort) annotation (Line(points={{-112.75, + -61},{-96,-61},{-96,70},{71.4667,70},{71.4667,62.15}}, color={0,0,127})); connect(WindSpeedPort, outside_wall2.WindSpeedPort) annotation (Line(points={{-112.75,-61},{-96,-61},{-96,70},{-0.8,70},{-0.8,64.3}}, color={0,0,127})); - connect(floor.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{-24,-58},{-24,-48},{-7,-48},{-7,-8}}, color={191,0,0})); + connect(floor.thermStarComb_inside, thermStar_Demux.portConvRadComb) annotation (Line(points={{-24,-58}, + {-24,-48},{-7,-48},{-7,-8}}, color={191,0,0})); connect(outside_wall1.port_outside, thermOutside) annotation (Line(points={{-88.25,4},{-94,4},{-94,100},{-100,100}}, color={191,0,0})); connect(outside_wall2.port_outside, thermOutside) annotation (Line(points={{-25,64.3},{-25,100},{-100,100}}, color={191,0,0})); - connect(roof.port_outside, thermOutside) annotation (Line(points={{59,62.15},{59,76},{-25,76},{-25,100},{-100,100}}, color={191,0,0})); + connect(roof.port_outside, thermOutside) annotation (Line(points={{59,62.15}, + {59,76},{-25,76},{-25,100},{-100,100}}, color={191,0,0})); annotation (Icon(graphics={ Rectangle( extent={{-80,80},{80,60}}, diff --git a/AixLib/ThermalZones/HighOrder/Rooms/RoomEmpiricalValidation/RoomTwinHouseN2.mo b/AixLib/ThermalZones/HighOrder/Rooms/RoomEmpiricalValidation/RoomTwinHouseN2.mo index beaf928c63..751f745933 100644 --- a/AixLib/ThermalZones/HighOrder/Rooms/RoomEmpiricalValidation/RoomTwinHouseN2.mo +++ b/AixLib/ThermalZones/HighOrder/Rooms/RoomEmpiricalValidation/RoomTwinHouseN2.mo @@ -35,24 +35,24 @@ model RoomTwinHouseN2 "N2" redeclare final DataBase.Walls.EmpiricalValidation.OW_E_TwinHouses wallPar, final solar_absorptance=0.23, - final calcMethodOut=1, - final calcMethodIn=1, + final calcMethodOut=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.DIN_6946, + final calcMethodIn=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.EN_ISO_6946_Appendix_A, final withWindow=true, final windowarea=1.89), wallWest( redeclare final DataBase.Walls.EmpiricalValidation.OW_W_TwinHouses wallPar, final solar_absorptance=0.23, - final calcMethodOut=1, - final calcMethodIn=1, + final calcMethodOut=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.DIN_6946, + final calcMethodIn=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.EN_ISO_6946_Appendix_A, final withWindow=true, final windowarea=3.78), wallSouth( redeclare final DataBase.Walls.EmpiricalValidation.OW_S_N_TwinHouses wallPar, final solar_absorptance=0.23, - final calcMethodOut=1, - final calcMethodIn=1, + final calcMethodOut=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.DIN_6946, + final calcMethodIn=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.EN_ISO_6946_Appendix_A, final withWindow=true, final windowarea=9.66, final withSunblind=true, @@ -63,8 +63,8 @@ model RoomTwinHouseN2 "N2" redeclare final DataBase.Walls.EmpiricalValidation.OW_S_N_TwinHouses wallPar, final solar_absorptance=0.23, - final calcMethodOut=1, - final calcMethodIn=1, + final calcMethodOut=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.DIN_6946, + final calcMethodIn=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.EN_ISO_6946_Appendix_A, final withWindow=true, final windowarea=1.89, final withDoor=true, @@ -72,17 +72,17 @@ model RoomTwinHouseN2 "N2" floor( final outside=false, redeclare DataBase.Walls.EmpiricalValidation.FL_TwinHouses wallPar, - final ISOrientation=2, + final ISOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.floor, final withWindow=false, final withDoor=false), ceiling( outside=false, redeclare DataBase.Walls.EmpiricalValidation.CE_TwinHouses wallPar, - final ISOrientation=3, + final ISOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.ceiling, final withWindow=false, final withDoor=false, - final calcMethodOut=1, - final calcMethodIn=1)); + final calcMethodOut=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.DIN_6946, + final calcMethodIn=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.EN_ISO_6946_Appendix_A)); Modelica.Thermal.HeatTransfer.Interfaces.HeatPort_a Therm_ground annotation (Placement(transformation(extent={{-36,-102},{-28,-94}}), @@ -116,8 +116,8 @@ model RoomTwinHouseN2 "N2" final WindowType=Type_Win, wall_length=2.6, wall_height=12.4, - calcMethodOut=1, - calcMethodIn=1, + calcMethodOut=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.DIN_6946, + calcMethodIn=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.EN_ISO_6946_Appendix_A, T0=TWalls_start) annotation (Placement(transformation(extent={{26,16},{30,40}}))); Components.Walls.Wall IW1( @@ -131,8 +131,8 @@ model RoomTwinHouseN2 "N2" final WindowType=Type_Win, wall_length=2.6, wall_height=11.6, - calcMethodOut=1, - calcMethodIn=1, + calcMethodOut=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.DIN_6946, + calcMethodIn=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.EN_ISO_6946_Appendix_A, T0=TWalls_start) annotation (Placement(transformation(extent={{40,-2},{44,22}}))); equation diff --git a/AixLib/ThermalZones/HighOrder/Rooms/RoomEmpiricalValidation/RoomWarehouse.mo b/AixLib/ThermalZones/HighOrder/Rooms/RoomEmpiricalValidation/RoomWarehouse.mo index 22aac90e0e..13a7061c25 100644 --- a/AixLib/ThermalZones/HighOrder/Rooms/RoomEmpiricalValidation/RoomWarehouse.mo +++ b/AixLib/ThermalZones/HighOrder/Rooms/RoomEmpiricalValidation/RoomWarehouse.mo @@ -47,12 +47,12 @@ model RoomWarehouse "Room model of Warehouse for Empirical validation" final outside=false, redeclare DataBase.Walls.EmpiricalValidation.FL_Warehouse wallPar, final solar_absorptance=0.3, - final ISOrientation=2, + final ISOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.floor, final withWindow=false, final withDoor=false), ceiling( redeclare DataBase.Walls.EmpiricalValidation.RO_Warehouse wallPar, - final ISOrientation=3, + final ISOrientation=AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.ceiling, final withWindow=true, final windowarea=60, final withDoor=false)); diff --git a/AixLib/ThermalZones/HighOrder/Validation/ASHRAE140/BaseClasses/PartialCase.mo b/AixLib/ThermalZones/HighOrder/Validation/ASHRAE140/BaseClasses/PartialCase.mo index 5228cbc821..bdb6d79b1a 100644 --- a/AixLib/ThermalZones/HighOrder/Validation/ASHRAE140/BaseClasses/PartialCase.mo +++ b/AixLib/ThermalZones/HighOrder/Validation/ASHRAE140/BaseClasses/PartialCase.mo @@ -18,7 +18,7 @@ partial model PartialCase "This is the base class from which the base cases will each GroundReflection= 0.2, each Latitude=sun.Latitude, each h= 1609, - each WeatherFormat=2) "N, E, S, W, Horz" + each WeatherFormat=true) "N, E, S, W, Horz" annotation (Placement(transformation(extent={{-102,41},{-74,69}}))); Modelica.Blocks.Sources.CombiTimeTable Solar_Radiation( @@ -41,21 +41,21 @@ partial model PartialCase "This is the base class from which the base cases will choices( choice(redeclare model Room = Rooms.ASHRAE140.SouthFacingWindows ( wallTypes=wallTypes, - calcMethodIn=4, + calcMethodIn=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.ASHRAE140_2017, Type_Win=windowParam, redeclare final model CorrSolarGainWin = CorrSolarGainWin, solar_absorptance_OW=solar_absorptance_OW, - calcMethodOut=2, + calcMethodOut=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.ASHRAE_Fundamentals, Win_Area=Win_Area, absInnerWallSurf=absInnerWallSurf) "Room with south facing window"), choice(redeclare model Room = Rooms.ASHRAE140.EastWestFacingWindows ( wallTypes=wallTypes, - calcMethodIn=4, + calcMethodIn=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.ASHRAE140_2017, Type_Win=windowParam, redeclare final model CorrSolarGainWin = CorrSolarGainWin, solar_absorptance_OW=solar_absorptance_OW, - calcMethodOut=2, + calcMethodOut=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.ASHRAE_Fundamentals, Win_Area=Win_Area, absInnerWallSurf=absInnerWallSurf) "Room with east and west facing window"))); @@ -66,11 +66,11 @@ partial model PartialCase "This is the base class from which the base cases will T0_air=294.15, TWalls_start=289.15, final wallTypes=wallTypes, - calcMethodIn=4, + calcMethodIn=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.ASHRAE140_2017, final Type_Win=windowParam, redeclare final model CorrSolarGainWin = CorrSolarGainWin, final solar_absorptance_OW=solar_absorptance_OW, - calcMethodOut=2, + calcMethodOut=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.ASHRAE_Fundamentals, final Win_Area=Win_Area, final absInnerWallSurf=absInnerWallSurf, final use_dynamicShortWaveRadMethod=false) diff --git a/AixLib/ThermalZones/HighOrder/Validation/ASHRAE140/Case620.mo b/AixLib/ThermalZones/HighOrder/Validation/ASHRAE140/Case620.mo index f6feef7f9b..70c1f984cc 100644 --- a/AixLib/ThermalZones/HighOrder/Validation/ASHRAE140/Case620.mo +++ b/AixLib/ThermalZones/HighOrder/Validation/ASHRAE140/Case620.mo @@ -7,10 +7,10 @@ model Case620 tableHeatOrTempMax=[620,4613,5944], redeclare model RoomModel = Rooms.ASHRAE140.EastWestFacingWindows ( wallTypes=wallTypes, - calcMethodIn=4, + calcMethodIn=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.ASHRAE140_2017, Type_Win=windowParam, solar_absorptance_OW=solar_absorptance_OW, - calcMethodOut=2, + calcMethodOut=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.ASHRAE_Fundamentals, Win_Area=Win_Area, absInnerWallSurf=absInnerWallSurf), Room(redeclare Components.Types.CoeffTableEastWestWindow coeffTableSolDistrFractions)); diff --git a/AixLib/ThermalZones/HighOrder/Validation/EmpiricalValidation/TwinHouseN2.mo b/AixLib/ThermalZones/HighOrder/Validation/EmpiricalValidation/TwinHouseN2.mo index f42a66b190..76570b5d06 100644 --- a/AixLib/ThermalZones/HighOrder/Validation/EmpiricalValidation/TwinHouseN2.mo +++ b/AixLib/ThermalZones/HighOrder/Validation/EmpiricalValidation/TwinHouseN2.mo @@ -9,7 +9,7 @@ model TwinHouseN2 energyDynamics=Modelica.Fluid.Types.Dynamics.FixedInitial, T0_air=303.15, TWalls_start=303.15, - calcMethodIn=1, + calcMethodIn=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.EN_ISO_6946_Appendix_A, redeclare model WindowModel = Components.WindowsDoors.Window_ASHRAE140, redeclare DataBase.WindowsDoors.Simple.WindowSimple_TwinHouses Type_Win, redeclare model CorrSolarGainWin = diff --git a/AixLib/Utilities/HeatTransfer/HeatConvInside.mo b/AixLib/Utilities/HeatTransfer/HeatConvInside.mo index 2792d64677..1ef4cfc6d3 100644 --- a/AixLib/Utilities/HeatTransfer/HeatConvInside.mo +++ b/AixLib/Utilities/HeatTransfer/HeatConvInside.mo @@ -5,33 +5,22 @@ model HeatConvInside */ extends Modelica.Thermal.HeatTransfer.Interfaces.Element1D; - parameter Integer calcMethod=2 "Calculation method for convective heat transfer coefficient" annotation ( + parameter AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface calcMethod=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.Bernd_Glueck "Calculation method for convective heat transfer coefficient" annotation ( Dialog(descriptionLabel=true), - choices( - choice=1 "EN ISO 6946 Appendix A >>Flat Surfaces<<", - choice=2 "By Bernd Glueck", - choice=3 "Custom hCon (constant)", - choice=4 "ASHRAE140-2017", - radioButtons=true), Evaluate=true); parameter Modelica.Units.SI.CoefficientOfHeatTransfer hCon_const=2.5 "Custom convective heat transfer coefficient" annotation (Dialog( - descriptionLabel=true, enable=if calcMethod == 3 then true else false)); + descriptionLabel=true, enable=if calcMethod == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.Custom_hCon then true else false)); parameter Modelica.Units.SI.TemperatureDifference dT_small=0.1 "Linearized function around dT = 0 K +/-" annotation (Dialog( - descriptionLabel=true, enable=if calcMethod == 1 or calcMethod == 2 or - calcMethod == 4 then true else false)); + descriptionLabel=true, enable=if calcMethod == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.EN_ISO_6946_Appendix_A or calcMethod == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.Bernd_Glueck or + calcMethod == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.ASHRAE140_2017 then true else false)); // which orientation of surface? - parameter Integer surfaceOrientation "Surface orientation" annotation ( - Dialog(descriptionLabel=true, enable=if calcMethod == 3 then false else true), - choices( - choice=1 "vertical", - choice=2 "horizontal facing up", - choice=3 "horizontal facing down", - radioButtons=true), + parameter AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation surfaceOrientation "Surface orientation" annotation ( + Dialog(descriptionLabel=true, enable=if calcMethod == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.Custom_hCon then false else true), Evaluate=true); parameter Modelica.Units.SI.Area A(min=Modelica.Constants.eps) "Area of surface"; @@ -50,10 +39,10 @@ equation // ++++++++++++++++EN ISO 6946 Appendix A >>Flat Surfaces<<++++++++++++++++ // upward heat flow: hCon = 5, downward heat flow: hCon = 0.7, horizontal heat flow: hCon = 2.5 - if calcMethod == 1 then + if calcMethod == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.EN_ISO_6946_Appendix_A then // floor (horizontal facing up) - if surfaceOrientation == 2 then + if surfaceOrientation == AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.floor then hCon = Modelica.Fluid.Utilities.regStep( x=port_b.T - port_a.T, y1=5, @@ -61,7 +50,7 @@ equation x_small=dT_small); // ceiling (horizontal facing down) - elseif surfaceOrientation == 3 then + elseif surfaceOrientation == AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.ceiling then hCon = Modelica.Fluid.Utilities.regStep( x=port_b.T - port_a.T, y1=0.7, @@ -78,11 +67,11 @@ equation // upward heat flow: hCon = 2*(posDiff^0.31) - equation 1.27, page 26 // downward heat flow: hCon = 0.54*(posDiff^0.31) - equation 1.28, page 26 // horizontal heat flow: hCon = 0.1.6*(posDiff^0.31) - equation 1.26, page 26 - elseif calcMethod == 2 then + elseif calcMethod == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.Bernd_Glueck then // floor (horizontal facing up) - if surfaceOrientation == 2 then + if surfaceOrientation == AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.floor then hCon = Modelica.Fluid.Utilities.regStep( x=port_b.T - port_a.T, y1=2*AixLib.Utilities.Math.Functions.regNonZeroPower(posDiff, 0.31, dT_small), @@ -91,7 +80,7 @@ equation // ceiling (horizontal facing down) - elseif surfaceOrientation == 3 then + elseif surfaceOrientation == AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.ceiling then hCon = Modelica.Fluid.Utilities.regStep( x=port_b.T - port_a.T, y1=0.54*AixLib.Utilities.Math.Functions.regNonZeroPower(posDiff, 0.31, dT_small), @@ -107,18 +96,18 @@ equation // ++++++++++++++++hCon_const++++++++++++++++ - elseif calcMethod == 3 then + elseif calcMethod == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.Custom_hCon then hCon = hCon_const; // ++++++++++++++++ASHRAE140-2017++++++++++++++++ // upward heat flow: hCon = 4.13, downward heat flow: hCon = 1, horizontal heat flow: hCon = 3.16 - elseif calcMethod == 4 then + elseif calcMethod == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransferInsideSurface.ASHRAE140_2017 then // floor (horizontal facing up) - if surfaceOrientation == 2 then + if surfaceOrientation == AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.floor then hCon = Modelica.Fluid.Utilities.regStep( x=port_b.T - port_a.T, y1=4.13, @@ -126,7 +115,7 @@ equation x_small=dT_small); // ceiling (horizontal facing down) - elseif surfaceOrientation == 3 then + elseif surfaceOrientation == AixLib.ThermalZones.HighOrder.Components.Types.InsideSurfaceOrientation.ceiling then hCon = Modelica.Fluid.Utilities.regStep( x=port_b.T - port_a.T, y1=1, diff --git a/AixLib/Utilities/HeatTransfer/HeatConvOutside.mo b/AixLib/Utilities/HeatTransfer/HeatConvOutside.mo index 1197ca0022..05968f6cd1 100644 --- a/AixLib/Utilities/HeatTransfer/HeatConvOutside.mo +++ b/AixLib/Utilities/HeatTransfer/HeatConvOutside.mo @@ -1,32 +1,27 @@ within AixLib.Utilities.HeatTransfer; model HeatConvOutside "Model for heat transfer at outside surfaces. Choice between multiple models" extends Modelica.Thermal.HeatTransfer.Interfaces.Element1D; - parameter Integer calcMethod=2 "Calculation method for convective heat transfer coefficient" annotation ( + parameter AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer calcMethod=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.ASHRAE_Fundamentals "Calculation method for convective heat transfer coefficient" annotation ( Evaluate=true, Dialog( group="Computational Models", compact=true, - descriptionLabel=true), - choices( - choice=1 "DIN 6946", - choice=2 "ASHRAE Fundamentals (convective + radiative)", - choice=3 "Custom hCon (constant)", - radioButtons=true)); + descriptionLabel=true)); parameter Modelica.Units.SI.Area A(min=0) "Area of surface" annotation (Dialog(group="Surface properties", descriptionLabel=true)); parameter Modelica.Units.SI.CoefficientOfHeatTransfer hCon_const=25 "Custom convective heat transfer coeffient" annotation (Dialog( group="Surface properties", descriptionLabel=true, - enable=calcMethod == 3)); + enable=calcMethod == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.Custom_hCon)); parameter DataBase.Surfaces.RoughnessForHT.PolynomialCoefficients_ASHRAEHandbook surfaceType = DataBase.Surfaces.RoughnessForHT.Brick_RoughPlaster() "Surface type" annotation(Dialog(group = "Surface properties", descriptionLabel = true, enable= - calcMethod == 2), choicesAllMatching = true); + calcMethod == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.ASHRAE_Fundamentals), choicesAllMatching = true); // Variables Modelica.Units.SI.CoefficientOfHeatTransfer hCon "Convection heat transfer coeffient"; - Modelica.Blocks.Interfaces.RealInput WindSpeedPort if calcMethod == 1 or calcMethod == 2 annotation(Placement(transformation(extent = {{-102, -82}, {-82, -62}}), iconTransformation(extent={{-100,-80},{-80,-60}}))); + Modelica.Blocks.Interfaces.RealInput WindSpeedPort if calcMethod == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.DIN_6946 or calcMethod == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.ASHRAE_Fundamentals annotation(Placement(transformation(extent = {{-102, -82}, {-82, -62}}), iconTransformation(extent={{-100,-80},{-80,-60}}))); protected Modelica.Blocks.Interfaces.RealInput WindSpeed_internal(unit="m/s"); @@ -35,9 +30,9 @@ equation port_a.Q_flow =hCon*A*(port_a.T - port_b.T); //Determine convection heat transfer coefficient hCon - if calcMethod == 1 then + if calcMethod == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.DIN_6946 then hCon = (4 + 4*WindSpeed_internal); - elseif calcMethod == 2 then + elseif calcMethod == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodConvectiveHeatTransfer.ASHRAE_Fundamentals then hCon = surfaceType.D + surfaceType.E*WindSpeed_internal + surfaceType.F*(WindSpeed_internal^2); else hCon = hCon_const; diff --git a/AixLib/Utilities/HeatTransfer/HeatToRad.mo b/AixLib/Utilities/HeatTransfer/HeatToRad.mo index 43840ff756..47b4daf4e5 100644 --- a/AixLib/Utilities/HeatTransfer/HeatToRad.mo +++ b/AixLib/Utilities/HeatTransfer/HeatToRad.mo @@ -10,15 +10,9 @@ model HeatToRad "Adaptor for approximative longwave radiation exchange with vari annotation(Evaluate=true, HideResult=true, choices(checkBox=true)); parameter Modelica.Units.SI.Area A=-1 "Fixed value of prescribed area" annotation (Dialog(enable=not use_A_in)); - parameter Integer radCalcMethod=1 "Calculation method for radiation heat transfer" annotation ( + parameter AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodRadiativeHeatTransfer radCalcMethod=AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodRadiativeHeatTransfer.No_approx "Calculation method for radiation heat transfer" annotation ( Evaluate=true, - Dialog(group = "Radiation exchange equation", compact=true), - choices( - choice=1 "No approx", - choice=2 "Linear approx at wall temp", - choice=3 "Linear approx at rad temp", - choice=4 "Linear approx at constant T_ref", - radioButtons=true)); + Dialog(group = "Radiation exchange equation", compact=true)); Modelica.Thermal.HeatTransfer.Interfaces.HeatPort_a convPort "Heat port for convective or conductive heat flow" annotation (Placement(transformation(extent={{-110,-10},{-90,10}}), iconTransformation(extent={{-110,-10},{-90,10}}))); @@ -41,11 +35,11 @@ equation convPort.Q_flow + radPort.Q_flow = 0; // To prevent negative solutions for T, the max() expression is used. // Negative solutions also occur when using max(T,0), therefore, 1 K is used. - if radCalcMethod == 1 then + if radCalcMethod == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodRadiativeHeatTransfer.No_approx then convPort.Q_flow = Modelica.Constants.sigma*eps*A_in_internal*(max(convPort.T, 1)*max(convPort.T, 1)*max(convPort.T, 1)*max(convPort.T, 1) - max(radPort.T, 1)*max(radPort.T, 1)*max(radPort.T, 1)*max(radPort.T, 1)); - elseif radCalcMethod == 2 then + elseif radCalcMethod == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodRadiativeHeatTransfer.Linear_wall_temp then convPort.Q_flow = Modelica.Constants.sigma*eps*A_in_internal*4*convPort.T*convPort.T*convPort.T*(convPort.T - radPort.T); - elseif radCalcMethod == 3 then + elseif radCalcMethod == AixLib.ThermalZones.HighOrder.Components.Types.CalcMethodRadiativeHeatTransfer.Linear_rad_temp then convPort.Q_flow = Modelica.Constants.sigma*eps*A_in_internal*4*radPort.T*radPort.T*radPort.T*(convPort.T - radPort.T); else convPort.Q_flow =Modelica.Constants.sigma*eps*A_in_internal*4*T_ref*T_ref*T_ref*(convPort.T - radPort.T); diff --git a/AixLib/package.mo b/AixLib/package.mo index db44fbca58..c04365c63f 100644 --- a/AixLib/package.mo +++ b/AixLib/package.mo @@ -6,7 +6,7 @@ package AixLib SDF(version="0.4.2"), Modelica_DeviceDrivers(version="2.1.1"), Modelica(version="4.0.0")), - version="1.3.2", + version="1.4.0", conversion(from( version="0.3.2", script="modelica://AixLib/Resources/Scripts/ConvertAixLib_from_0.3.2_to_0.4.mos",