Skip to content

Commit

Permalink
Removed weaBus.sol for OpenModelica.
Browse files Browse the repository at this point in the history
Removed the expandable connector sol from the expandable connector
weaBus as this construct does not work in OpenModelica.
Deleted the expandable connector SolarSubBus.
Renamed the following variables on the weather data bus:
sol.zen -> solZen
sol.dec -> solDec
sol.alt -> solAlt
  • Loading branch information
mwetter committed Oct 15, 2014
1 parent 88f87ce commit 95a7b11
Show file tree
Hide file tree
Showing 12 changed files with 54 additions and 104 deletions.
Expand Up @@ -41,7 +41,7 @@ equation
points={{1,30},{60,30},{60,14.8},{68,14.8}},
color={0,0,127},
smooth=Smooth.None));
connect(weaBus.sol.zen, altAng.zen) annotation (Line(
connect(weaBus.solZen, altAng.zen) annotation (Line(
points={{-60,10},{-40,10},{-40,30},{-22,30}},
color={255,204,51},
thickness=0.5,
Expand All @@ -50,7 +50,7 @@ equation
index=-1,
extent={{-6,3},{-6,3}}));
annotation ( Diagram(
graphics),
graphics),
experiment(StopTime=86400),
__Dymola_Commands(file="modelica://Buildings/Resources/Scripts/Dymola/BoundaryConditions/SolarGeometry/BaseClasses/Examples/WallSolarAzimuth.mos"
"Simulate and plot"),
Expand Down
24 changes: 9 additions & 15 deletions Buildings/BoundaryConditions/SolarGeometry/ZenithAngle.mo
Expand Up @@ -20,23 +20,16 @@ equation
1.16573e-15},{95.5,5.55112e-16},{110,5.55112e-16}},
color={0,0,127},
smooth=Smooth.None));
connect(weaBus.sol.dec, zen.decAng) annotation (Line(
points={{-102,5.55112e-16},{-60,5.55112e-16},{-60,5.4},{-2,5.4}},
connect(weaBus.solDec, zen.decAng) annotation (Line(
points={{-102,0},{-40,0},{-40,5.4},{-2,5.4}},
color={255,204,51},
thickness=0.5,
smooth=Smooth.None), Text(
string="%first",
index=-1,
extent={{-6,3},{-6,3}}));
connect(weaBus.sol.solHouAng, zen.solHouAng) annotation (Line(
points={{-102,5.55112e-16},{-60,5.55112e-16},{-60,-6},{-60,-6},{-60,-4.8},
{-2,-4.8}},
smooth=Smooth.None));
connect(weaBus.solHouAng, zen.solHouAng) annotation (Line(
points={{-102,0},{-40,0},{-40,-4.8},{-2,-4.8}},
color={255,204,51},
thickness=0.5,
smooth=Smooth.None), Text(
string="%first",
index=-1,
extent={{-6,3},{-6,3}}));
smooth=Smooth.None));
annotation (
defaultComponentName="zen",
Documentation(info="<html>
Expand All @@ -59,8 +52,9 @@ First implementation.
</li>
</ul>
</html>"),
Diagram(coordinateSystem(preserveAspectRatio=true,extent={{-100,-100},{100,
100}})),
Diagram(coordinateSystem(preserveAspectRatio=false,
extent={{-100,-100},{100,
100}}), graphics),
Icon(coordinateSystem(preserveAspectRatio=true, extent={{-100,-100},{100,
100}}), graphics={Text(
extent={{-150,110},{150,150}},
Expand Down
8 changes: 4 additions & 4 deletions Buildings/BoundaryConditions/SolarIrradiation/DiffusePerez.mo
Expand Up @@ -55,15 +55,15 @@ equation
points={{-75.5,-91},{-16,-91},{-16,-16},{-4.2,-16},{-4.2,-14.7}},
color={0,0,127},
smooth=Smooth.None));
connect(weaBus.sol.zen, skyCle.zen) annotation (Line(
connect(weaBus.solZen, skyCle.zen) annotation (Line(
points={{-100,5.55112e-16},{-86,5.55112e-16},{-86,17.6},{-62.8,17.6}},
color={0,0,127},
smooth=Smooth.None));
connect(weaBus.sol.zen, relAirMas.zen) annotation (Line(
connect(weaBus.solZen, relAirMas.zen) annotation (Line(
points={{-100,5.55112e-16},{-86,5.55112e-16},{-86,-40},{-80.8,-40}},
color={0,0,127},
smooth=Smooth.None));
connect(weaBus.sol.zen, briCoe.zen) annotation (Line(
connect(weaBus.solZen, briCoe.zen) annotation (Line(
points={{-100,5.55112e-16},{-86,5.55112e-16},{-86,-20},{-66,-20},{-66,-32},
{-40.8,-32},{-40.8,-32.4}},
color={0,0,127},
Expand Down Expand Up @@ -126,7 +126,7 @@ equation
string="%first",
index=-1,
extent={{-6,3},{-6,3}}));
connect(weaBus.sol.zen, HDifTil.zen) annotation (Line(
connect(weaBus.solZen, HDifTil.zen) annotation (Line(
points={{-100,5.55112e-16},{-86,5.55112e-16},{-86,-58},{-20,-58},{-20,
-8.4},{-4.2,-8.4}},
color={255,204,51},
Expand Down
17 changes: 0 additions & 17 deletions Buildings/BoundaryConditions/WeatherData/BaseClasses/package.mo
Expand Up @@ -3,23 +3,6 @@ package BaseClasses "Package with base classes for Buildings.BoundaryConditions.
extends Modelica.Icons.BasesPackage;



















annotation (preferredView="info", Documentation(info="<html>
<p>
This package contains base classes that are used to construct the models in
Expand Down
Expand Up @@ -11,12 +11,10 @@ ConvertRelativeHumidity
ConvertTime
EquationOfTime
LocalCivilTime
SolarSubBus
SolarTime
getAbsolutePath
getHeaderElementTMY3
getLatitudeTMY3
getLongitudeTMY3
getTimeZoneTMY3
Examples

81 changes: 28 additions & 53 deletions Buildings/BoundaryConditions/WeatherData/ReaderTMY3.mo
Expand Up @@ -194,9 +194,6 @@ block ReaderTMY3 "Reader for TMY3 weather data"
"Time zone";
Bus weaBus "Weather Data Bus" annotation (Placement(transformation(extent={{
294,-10},{314,10}}), iconTransformation(extent={{190,-10},{210,10}})));
BaseClasses.SolarSubBus solBus "Sub bus with solar position"
annotation (Placement(transformation(extent={{-2,-304},{18,-284}}),
iconTransformation(extent={{-2,-200},{18,-180}})));

parameter Buildings.BoundaryConditions.Types.SkyTemperatureCalculation
calTSky=Buildings.BoundaryConditions.Types.SkyTemperatureCalculation.TemperaturesAndSkyCover
Expand Down Expand Up @@ -738,55 +735,6 @@ equation
points={{-59,-216},{-40,-216},{-40,-270},{-32,-270}},
color={0,0,127},
smooth=Smooth.None));
connect(altAng.alt, solBus.alt) annotation (Line(
points={{-9,-270},{8,-270},{8,-294}},
color={0,0,127},
smooth=Smooth.None), Text(
string="%second",
index=1,
extent={{6,3},{6,3}}));
connect(zenAng.zen, solBus.zen) annotation (Line(
points={{-59,-216},{-40,-216},{-40,-294},{8,-294}},
color={0,0,127},
smooth=Smooth.None), Text(
string="%second",
index=1,
extent={{6,3},{6,3}}));
connect(solBus, weaBus.sol) annotation (Line(
points={{8,-294},{122,-294},{122,-292},{290,-292},{290,5.55112e-16},{304,
5.55112e-16}},
color={255,204,51},
thickness=0.5,
smooth=Smooth.None));

connect(decAng.decAng, solBus.dec) annotation (Line(
points={{-119,-210},{-100,-210},{-100,-294},{8,-294}},
color={0,0,127},
smooth=Smooth.None), Text(
string="%second",
index=1,
extent={{6,3},{6,3}}));
connect(solHouAng.solHouAng, solBus.solHouAng) annotation (Line(
points={{-119,-240},{-100,-240},{-100,-294},{8,-294}},
color={0,0,127},
smooth=Smooth.None), Text(
string="%second",
index=1,
extent={{6,3},{6,3}}));
connect(longitude.y, solBus.lon) annotation (Line(
points={{-119,-270},{-100,-270},{-100,-294},{8,-294}},
color={0,0,127},
smooth=Smooth.None), Text(
string="%second",
index=1,
extent={{6,3},{6,3}}));
connect(latitude.y, solBus.lat) annotation (Line(
points={{-159,-270},{-150,-270},{-150,-294},{8,-294}},
color={0,0,127},
smooth=Smooth.None), Text(
string="%second",
index=1,
extent={{6,3},{6,3}}));

// Connectors for wet bulb temperature.
// These are removed if computeWetBulbTemperature = false
Expand All @@ -811,6 +759,32 @@ equation
color={0,0,127},
smooth=Smooth.None));

connect(altAng.alt, weaBus.solAlt) annotation (Line(
points={{-9,-270},{8,-270},{8,-290},{290,-290},{290,0},{304,0}},
color={0,0,127},
smooth=Smooth.None));
connect(zenAng.zen, weaBus.solZen) annotation (Line(
points={{-59,-216},{-40,-216},{-40,-290},{290,-290},{290,0},{304,0}},
color={0,0,127},
smooth=Smooth.None));
connect(decAng.decAng, weaBus.solDec) annotation (Line(
points={{-119,-210},{-110,-210},{-110,-208},{-100,-208},{-100,-290},{290,
-290},{290,0},{304,0}},
color={0,0,127},
smooth=Smooth.None));
connect(solHouAng.solHouAng, weaBus.solHouAng) annotation (Line(
points={{-119,-240},{-108,-240},{-108,-238},{-100,-238},{-100,-290},{290,
-290},{290,0},{304,0}},
color={0,0,127},
smooth=Smooth.None));
connect(longitude.y, weaBus.lon) annotation (Line(
points={{-119,-270},{-100,-270},{-100,-290},{290,-290},{290,0},{304,0}},
color={0,0,127},
smooth=Smooth.None));
connect(latitude.y, weaBus.lat) annotation (Line(
points={{-159,-270},{-150,-270},{-150,-290},{290,-290},{290,0},{304,0}},
color={0,0,127},
smooth=Smooth.None));
annotation (
defaultComponentName="weaDat",
Icon(coordinateSystem(
Expand Down Expand Up @@ -1291,6 +1265,7 @@ First implementation.
</ul>
</html>"),
Diagram(coordinateSystem(preserveAspectRatio=false,
extent={{-200,-300},{300,300}}),
extent={{-200,-300},{300,
300}}),
graphics));
end ReaderTMY3;
Expand Up @@ -53,23 +53,23 @@ equation
string="%second",
index=1,
extent={{6,3},{6,3}}));
connect(weaBus.sol.alt, walSolAzi.alt) annotation (Line(
connect(weaBus.solAlt, walSolAzi.alt) annotation (Line(
points={{-34,34},{-32,34},{-32,34.8},{-2,34.8}},
color={255,204,51},
thickness=0.5,
smooth=Smooth.None), Text(
string="%first",
index=-1,
extent={{-6,3},{-6,3}}));
connect(weaBus.sol.alt, ove.alt) annotation (Line(
connect(weaBus.solAlt, ove.alt) annotation (Line(
points={{-34,34},{-70,34},{-70,-20},{60,-20},{60,12},{66,12}},
color={255,204,51},
thickness=0.5,
smooth=Smooth.None), Text(
string="%first",
index=-1,
extent={{-6,3},{-6,3}}));
annotation (Diagram(graphics),
annotation (
experiment(StopTime=86400),
__Dymola_Commands(file="modelica://Buildings/Resources/Scripts/Dymola/HeatTransfer/Windows/BaseClasses/Examples/Overhang.mos"
"Simulate and plot"),
Expand Down
4 changes: 2 additions & 2 deletions Buildings/HeatTransfer/Windows/BaseClasses/Overhang.mo
Expand Up @@ -173,15 +173,15 @@ equation
string="%first",
index=-1,
extent={{-6,3},{-6,3}}));
connect(weaBus.sol.zen, solAzi.zen) annotation (Line(
connect(weaBus.solZen, solAzi.zen) annotation (Line(
points={{-102,5.55112e-16},{-79,5.55112e-16},{-79,6},{-62,6}},
color={255,204,51},
thickness=0.5,
smooth=Smooth.None), Text(
string="%first",
index=-1,
extent={{-6,3},{-6,3}}));
connect(weaBus.sol.dec, solAzi.decAng) annotation (Line(
connect(weaBus.solDec, solAzi.decAng) annotation (Line(
points={{-102,5.55112e-16},{-92,5.55112e-16},{-92,1.22125e-15},{-82,
1.22125e-15},{-82,6.66134e-16},{-62,6.66134e-16}},
color={255,204,51},
Expand Down
Expand Up @@ -17,7 +17,7 @@ protected
annotation (Placement(transformation(extent={{60,50},{80,70}})));

equation
connect(weaBus.sol.alt, walSolAzi.alt) annotation (Line(
connect(weaBus.solAlt, walSolAzi.alt) annotation (Line(
points={{-100,5.55112e-16},{-80,5.55112e-16},{-80,-45.2},{-62,-45.2}},
color={255,204,51},
thickness=0.5,
Expand Down
6 changes: 3 additions & 3 deletions Buildings/HeatTransfer/Windows/FixedShade.mo
Expand Up @@ -85,7 +85,7 @@ protected
"Limiter to avoid that the fraction of sun-exposed window is below zero"
annotation (Placement(transformation(extent={{-10,-10},{10,10}})));
equation
connect(weaBus.sol.alt, walSolAzi.alt) annotation (Line(
connect(weaBus.solAlt, walSolAzi.alt) annotation (Line(
points={{-100,5.55112e-16},{-92,5.55112e-16},{-92,-76},{-82,-76},{-82,
-75.2}},
color={255,204,51},
Expand All @@ -107,7 +107,7 @@ equation
points={{-59,-80},{-54,-80},{-54,-56},{-42,-56}},
color={0,0,127},
smooth=Smooth.None));
connect(weaBus.sol.alt, sidFin.alt) annotation (Line(
connect(weaBus.solAlt, sidFin.alt) annotation (Line(
points={{-100,5.55112e-16},{-92,5.55112e-16},{-92,-64},{-42,-64}},
color={255,204,51},
thickness=0.5,
Expand Down Expand Up @@ -156,7 +156,7 @@ equation
points={{21,-80},{26,-80},{26,1},{30,1}},
color={0,0,127},
smooth=Smooth.None));
connect(weaBus.sol.alt, ove.alt) annotation (Line(
connect(weaBus.solAlt, ove.alt) annotation (Line(
points={{-100,5.55112e-16},{-92,5.55112e-16},{-92,46},{-42,46}},
color={255,204,51},
thickness=0.5,
Expand Down
2 changes: 1 addition & 1 deletion Buildings/HeatTransfer/Windows/Overhang.mo
Expand Up @@ -41,7 +41,7 @@ equation
string="%first",
index=-1,
extent={{-6,3},{-6,3}}));
connect(weaBus.sol.alt, ove.alt) annotation (Line(
connect(weaBus.solAlt, ove.alt) annotation (Line(
points={{-100,5.55112e-16},{-12,5.55112e-16},{-12,-4},{-2,-4}},
color={255,204,51},
thickness=0.5,
Expand Down
2 changes: 1 addition & 1 deletion Buildings/HeatTransfer/Windows/SideFins.mo
Expand Up @@ -20,7 +20,7 @@ equation
points={{-39,-50},{-20,-50},{-20,4},{-2,4}},
color={0,0,127},
smooth=Smooth.None));
connect(weaBus.sol.alt, fin.alt) annotation (Line(
connect(weaBus.solAlt, fin.alt) annotation (Line(
points={{-100,0},{-80,0},{-80,-4},{-2,-4}},
color={255,204,51},
thickness=0.5,
Expand Down

0 comments on commit 95a7b11

Please sign in to comment.