Skip to content

Commit f359aae

Browse files
committed
Add Modelica.Constants.eps instead of 0.001 since it is nicer #1575
1 parent 094c1be commit f359aae

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

IBPSA/Electrical/DC/Sources/Validation/BaseClasses/partialPVValidation.mo

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,13 +27,13 @@ partial model partialPVValidation
2727
//Approximation of diffuse horizontal irradiation still necessary because
2828
//the validation data does not contain this information so far
2929
// Erbs diffuse fraction relation
30-
Real k_t(final unit="1", start=0.5)=if HGloHor <= 0.01
30+
Real k_t(final unit="1", start=0.5)=if HGloHor <= Modelica.Constants.eps
3131
then 0
3232
else min(1, max(0, (HGloHor/(GSC*(1 + 0.033*
3333
cos(360*(Modelica.Constants.pi/180)*cloTim/24/60/60/365)*
3434
(cos(lat)*cos(solDec)*cos(solHouAng) + sin(lat)*sin(solDec)))))))
3535
"Clearness index; factor needed for Erbs diffuse fraction relation";
36-
Modelica.Units.SI.Irradiance HDifHor=if HGloHor <= 0.01
36+
Modelica.Units.SI.Irradiance HDifHor=if HGloHor <= Modelica.Constants.eps
3737
then 0
3838
elseif k_t <= 0.22
3939
then (HGloHor)*(1.0 - 0.09*k_t)

0 commit comments

Comments
 (0)