Skip to content

Third option to remove low solar elevation artifact in clearsky.ineichen #1064

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
martinherrerias opened this issue Sep 23, 2020 · 1 comment

Comments

@martinherrerias
Copy link

martinherrerias commented Sep 23, 2020

See #435 and #459 for context.

One way to remove the artifacts while introducing less bias is to clip the airmass_absolute values to the point where the exponential correction becomes problematic. Something like:

airmass_critical = (cg2*(fh1+fh2*(tl-1))/0.018).^1.25
airmass_clipped = np.fmin(airmass_absolute, airmass_critical)
ghi = (np.exp(-cg2*airmass_clipped*(fh1 + fh2*(tl - 1)) + 0.01*airmass_clipped**1.8))
...
ghi = cg1 * dni_extra * cos_zenith * tl / tl * np.fmax(ghi, 0)

airmass_critical is a minimum for the combined exponential terms, which shoot up afterwards. Loosely:
airmass_critical = argmin(f(x)), for f = exp(-cg2*x*(fh1 + fh2*(tl - 1)) + 0.01*x^1.8))

This threshold starts at AM = 2.6 (for turbidity = 1 and altitude = 0), equivalent to ~22.5° solar elevation, and goes up to O(10) for higher turbidities and altitudes. For most cases, it corresponds to solar elevation angles below the 4° cutting threshold of the CIE 1994 quality control guidelines that Ineichen & Perez seem to have used, i.e. they probably didn't see beyond it.

Clipping at the minimum makes the adjustment smooth (C1), and leaves the results of the model untouched for most operating conditions.

clearsky_ineichen

Originally posted by @martinherrerias in #435 (comment)

@martinherrerias
Copy link
Author

@mikofski, there is no reference for this fix, and I also had no plans of publishing it. I take comfort in the fact that the proposed correction falls between the two (already published) versions of the model, but @adriesse is right to point out that actually none of the models is validated for very low solar elevations.

martinherrerias added a commit to martinherrerias/pvlib-python that referenced this issue Sep 23, 2020
…n clearsky.ineichen, allowing explicit enable/disable of original correction
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant