Summary
Horizon shading accounts for beam irradiance losses when the sun is blocked by distant terrain features, trees, buildings, or other obstructions beyond the solar array field. Users define a horizon profile as a series of - pairs describing the apparent horizon line around the site. At each timestep, the algorithm compares the solar position to the interpolated horizon elevation at that azimuth and determines whether the sun is visible. When sunrise or sunset occurs within a timestep and the sun passes behind the horizon, fractional shading is calculated based on the duration of obstruction.Inputs
| Name | Symbol | Units | Description |
|---|---|---|---|
| Horizon Profile | degrees | List of azimuth-elevation pairs defining horizon | |
| Solar Zenith Angle | degrees | Angle between sun and vertical | |
| Solar Azimuth Angle | degrees | Sun’s compass direction (0° = north) | |
| Solar Elevation Angle | degrees | Sun altitude above horizon () | |
| Timestamp | — | Current time step | |
| Previous/Next Timestamps | — | Adjacent time steps for interpolation | |
| Previous/Next Solar Positions | — | degrees | Solar positions at adjacent time steps |
| Sunrise/Sunset Time | — | — | Times when sun crosses horizon (if in interval) |
Outputs
| Name | Symbol | Units | Description |
|---|---|---|---|
| Horizon Shading Factor | — | Unshaded fraction of beam irradiance (0-1) | |
| Traverse Time | — | Time when sun clears horizon obstruction | |
| Shading Duration | minutes | Duration sun is behind horizon within timestep |
Detailed Description
Horizon Profile Definition
The horizon profile is a user-defined list of obstruction elevations at specified azimuths around the site: where:- is the azimuth direction (0° to 360°, 0° = north, 90° = east)
- is the elevation angle of the obstruction at that azimuth (degrees above horizon)
Horizon Elevation Interpolation
For each timestep, the algorithm determines the horizon elevation at the current solar azimuth by linear interpolation: Find Bounding Azimuths: Locate indices and such that: Interpolate Elevation: Special handling for azimuth wraparound at 0°/360°.Sun Visibility Determination
The algorithm checks if the sun is blocked by comparing solar elevation to horizon elevation: Fully Visible: If , the sun is above the horizon obstruction: Fully Blocked: If and the sun remains blocked for the entire timestep: Partial Blocking: If sunrise/sunset occurs within the timestep and the sun crosses behind or emerges from the horizon obstruction, fractional shading is calculated.Fractional Shading Calculation
When the sun transitions across the horizon during a timestep, the algorithm calculates the traverse time and shading duration. Sun Direction Determination: Determine if the sun is rising () or setting () by comparing solar elevations at adjacent timesteps. Azimuth at Lowest Elevation Time: If sunrise/sunset occurs in the current timestep, the lowest solar elevation time is the sunrise or sunset time. The solar azimuth at this time is interpolated: For sunrise: For sunset: where is the lowest elevation time (sunrise or sunset). Traverse Time Calculation: Starting from the lowest elevation time, iterate forward (sunrise) or backward (sunset) in 1-minute increments:- Interpolate solar elevation and azimuth at each minute
- Interpolate horizon elevation at that solar azimuth
- Stop when solar elevation exceeds horizon elevation
Application to Beam Irradiance
The horizon shading factor is applied to beam irradiance after near-field (row-to-row) shading: where:- is the plane-of-array beam irradiance
- is the near-field shading factor
- is the horizon shading factor
Edge Cases
High Peak Elevation: If the highest peak elevation in the horizon profile is less than or equal to the lowest solar elevation during the day, no horizon shading occurs for that day. Continuous Blocking: If the sun remains below the horizon obstruction for multiple consecutive timesteps, for all affected timesteps. No Sunrise/Sunset in Interval: If the timestep does not include sunrise or sunset, the algorithm interpolates solar elevation at the lowest elevation time within or near the interval and performs the same traverse time calculation.References
- Marion, B. (2021). Numerical verification of pvlib single-axis tracking shading algorithms. IEEE Journal of Photovoltaics, 11(1), 184–190.
- Stein, J. S., Hansen, C. W., & Reno, M. J. (2012). The Sandia Array Performance Model (SAPM). SAND2012-2389, Sandia National Laboratories.