Skip to content

Commit

Permalink
Corrected pressure drop calculation of solar collector
Browse files Browse the repository at this point in the history
This corrects a bug in the implementation of the solar collector pressure drop for parallel collectors. This is for #3597
  • Loading branch information
mwetter committed Dec 11, 2023
1 parent 8785739 commit 5cdd811
Show file tree
Hide file tree
Showing 5 changed files with 45 additions and 10 deletions.
7 changes: 7 additions & 0 deletions Buildings/Fluid/SolarCollectors/ASHRAE93.mo
Original file line number Diff line number Diff line change
Expand Up @@ -180,6 +180,13 @@ capacity of copper.
</html>", revisions="<html>
<ul>
<li>
December 11, 2023, by Michael Wetter:<br/>
Corrected implementation of pressure drop calculation for the situation where the collectors are in parallel,
e.g., if <code>sysConfig == Buildings.Fluid.SolarCollectors.Types.SystemConfiguration.Parallel</code>.<br/>
This is for
<a href=\"https://github.com/lbl-srg/modelica-buildings/issues/3597\">Buildings, #3597</a>.
</li>
<li>
September 16, 2021, by Michael Wetter:<br/>
Changed <code>lat</code> from being a parameter to an input from weather bus.<br/>
This is for
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ model PartialSolarCollector "Partial model for solar collectors"
extends Buildings.Fluid.Interfaces.LumpedVolumeDeclarations;
extends Buildings.Fluid.Interfaces.TwoPortFlowResistanceParameters(final dp_nominal = dp_nominal_final);
extends Buildings.Fluid.Interfaces.PartialTwoPortInterface(
final m_flow_nominal=perPar.mperA_flow_nominal*perPar.A);
final m_flow_nominal=m_flow_nominal_final);

constant Boolean homotopyInitialization = true "= true, use homotopy method"
annotation(HideResult=true);
Expand Down Expand Up @@ -125,9 +125,14 @@ protected
"Partial performance data"
annotation(choicesAllMatching=true);

Modelica.Blocks.Interfaces.RealInput shaCoe_internal
Modelica.Blocks.Interfaces.RealInput shaCoe_internal
"Internally used shading coefficient";

final parameter Modelica.Units.SI.MassFlowRate m_flow_nominal_final(
displayUnit="kg/s") = if sysConfig == Buildings.Fluid.SolarCollectors.Types.SystemConfiguration.Parallel
then nPanels_internal*perPar.mperA_flow_nominal*perPar.A else perPar.mperA_flow_nominal*perPar.A
"Nominal mass flow rate through the system of collectors";

final parameter Modelica.Units.SI.PressureDifference dp_nominal_final(
displayUnit="Pa") = if sysConfig == Buildings.Fluid.SolarCollectors.Types.SystemConfiguration.Series
then nPanels_internal*perPar.dp_nominal else perPar.dp_nominal
Expand Down Expand Up @@ -242,6 +247,13 @@ CEN 2006, European Standard 12975-1:2006, European Committee for Standardization
revisions="<html>
<ul>
<li>
December 11, 2023, by Michael Wetter:<br/>
Corrected implementation of pressure drop calculation for the situation where the collectors are in parallel,
e.g., if <code>sysConfig == Buildings.Fluid.SolarCollectors.Types.SystemConfiguration.Parallel</code>.<br/>
This is for
<a href=\"https://github.com/lbl-srg/modelica-buildings/issues/3597\">Buildings, #3597</a>.
</li>
<li>
September 16, 2021, by Michael Wetter:<br/>
Changed <code>lat</code> from being a parameter to an input from weather bus.<br/>
This is for
Expand Down
9 changes: 8 additions & 1 deletion Buildings/Fluid/SolarCollectors/EN12975.mo
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,13 @@ capacity of copper.
</html>", revisions="<html>
<ul>
<li>
December 11, 2023, by Michael Wetter:<br/>
Corrected implementation of pressure drop calculation for the situation where the collectors are in parallel,
e.g., if <code>sysConfig == Buildings.Fluid.SolarCollectors.Types.SystemConfiguration.Parallel</code>.<br/>
This is for
<a href=\"https://github.com/lbl-srg/modelica-buildings/issues/3597\">Buildings, #3597</a>.
</li>
<li>
September 16, 2021, by Michael Wetter:<br/>
Changed <code>lat</code> from being a parameter to an input from weather bus.<br/>
This is for
Expand All @@ -134,7 +141,7 @@ First implementation.
</html>"),
Icon(coordinateSystem(preserveAspectRatio=false, extent={{-100,-100},{100,
100}}),
graphics={
graphics={
Rectangle(
extent={{-84,100},{84,-100}},
lineColor={27,0,55},
Expand Down
13 changes: 11 additions & 2 deletions Buildings/Fluid/SolarCollectors/Examples/Tubular.mo
Original file line number Diff line number Diff line change
Expand Up @@ -38,14 +38,15 @@ model Tubular "Example showing the use of Tubular"
Modelica.Blocks.Sources.Sine sine(
f=3/86400,
offset=101325,
amplitude=-1.5*solCol.dp_nominal)
amplitude=-0.1*solCol.dp_nominal)
annotation (Placement(transformation(extent={{-100,-20},{-80,0}})));
Buildings.Fluid.Sources.Boundary_pT sou(
redeclare package Medium = Medium,
T=273.15 + 10,
nPorts=1,
use_p_in=true,
p(displayUnit="Pa")) "Inlet for water flow" annotation (Placement(
p(displayUnit="Pa")) "Inlet for water flow"
annotation (Placement(
transformation(
extent={{10,-10},{-10,10}},
rotation=180,
Expand Down Expand Up @@ -92,6 +93,14 @@ equation
revisions="<html>
<ul>
<li>
December 11, 2023, by Michael Wetter:<br/>
Changed design flow rate. This is due to correction for the
implementation of the pressure drop calculation for the situation where collectors are in parallel,
e.g., if <code>sysConfig == Buildings.Fluid.SolarCollectors.Types.SystemConfiguration.Parallel</code>.<br/>
This is for
<a href=\"https://github.com/lbl-srg/modelica-buildings/issues/3597\">Buildings, #3597</a>.
</li>
<li>
September 16, 2021, by Michael Wetter:<br/>
Removed parameter assignment for <code>lat</code>.<br/>
This is for
Expand Down
Loading

0 comments on commit 5cdd811

Please sign in to comment.