WSL/SLF GitLab Repository

Commit 0e68271e authored by Mathias Bavay's avatar Mathias Bavay
Browse files

Consider threshold solar elevation in static projection method for consistency...

Consider threshold solar elevation in static projection method for consistency with the non-static one
parent 01af7bb0
......@@ -97,10 +97,10 @@ double SunTrajectory::getHorizontalOnSlope(const double& slope_azi, const double
}
//usefull static methods
double SunTrajectory::projectHorizontalToSlope(const double& sun_azi, const double& sun_elev, const double& slope_azi, const double& slope_elev, const double& H_radiation)
double SunTrajectory::projectHorizontalToSlope(const double& sun_azi, const double& sun_elev, const double& slope_azi, const double& slope_elev, const double& H_radiation, const double& elev_threshold)
{// Project a horizontal radiation to a given slope
// Oke, T.R., Boundary Layer Climates. 2nd ed, 1987, Routledge, London, p345.
const double Z = (90.-sun_elev)*Cst::to_rad;
const double Z = (sun_elev>elev_threshold)? (90.-sun_elev)*Cst::to_rad : (90.-elev_threshold)*Cst::to_rad;
const double cosZ = cos(Z);
if(cosZ==0.) {
......
......@@ -65,7 +65,7 @@ class SunTrajectory {
static double getAngleOfIncidence(const double& sun_azi, const double& sun_elev,
const double& slope_azi, const double& slope_elev);
static double projectHorizontalToSlope(const double& sun_azi, const double& sun_elev,
const double& slope_azi, const double& slope_elev, const double& H_radiation);
const double& slope_azi, const double& slope_elev, const double& H_radiation, const double& elev_threshold);
static double projectSlopeToHorizontal(const double& sun_azi, const double& sun_elev,
const double& slope_azi, const double& slope_elev, const double& S_radiation);
static double projectHorizontalToBeam(const double& sun_elev, const double& H_radiation);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment