-
Notifications
You must be signed in to change notification settings - Fork 45
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
Inconsistent stellar_irradiance
and downwelling shortwave flux
#21
Comments
Somewhat related, the solar constant probably shouldn't be hard-coded into the RRTMG docstring if it comes from the constants dictionary. Can you create a minimal model which reproduces the downwelling shortwave flux, or at the least put your model on pastebin or somewhere, so we can see exactly what you mean by "the downwelling shortwave flux calculated"? |
Also use_solar_constant_from_fortran should specify a default value in the docstring (it's False). |
Hello Lukas, I think I have seen this behaviour myself. I will see why this is the case in the next couple |
@mcgibbon will fix these, thanks! |
Thanks for the quick response! @mcgibbon I will try my best to create a minimal working example tomorrow 😉 Maybe I can avoid using our model and reproduce the issue in pure CliMT. @JoyMonteiro Thanks! Let me know if I can - besides creating a test case - help you |
import climt
rad = climt.RRTMGShortwave()
state = climt.get_default_state([rad])
tend, diag = rad(state) reproduces the issue. |
@mcgibbon looked at the docstring. The hardcoded values are present to inform the user of the internal fortran constants used by RRTMGShortwave. They are not used if @lkluft OK, I figured this out. The shortwave code uses the day of year to scale the solar constant with. The default value of time (in if you change the time, for example import climt
from datetime import timedelta
rad = climt.RRTMGShortwave()
state = climt.get_default_state([rad])
state['time'] += timedelta(days=80) # Close to equinox
tend, diag = rad(state) Then the TOA downwelling radiation is close to what is specified by Recognising the fact that this is a valid RRTMG option that was not yet exposed at the python level, Thanks for finding this! |
Thank you very much for the quick fix! The new option works like a charm! |
Description
First of all thanks for the awesome work you are doing! 👍
I am using CliMT as a wrapper for RRTMG to calculate radiative fluxes and heatingrates. For my calculations I need to change the
stellar_irradiance
to different values (working together with Sally, #19 ). While doing so I found a disagreement between thestellar_irradiance
and the downwelling shortwave flux at the top of the atmosphere. For a zenith angle of 0 degree both values should be exactly the same.What I Did
When using the CliMT default state the
stellar_irradiance
is set to1367.0
but the downwelling shortwave flux calculated is1414.91
which seems odd. I found that the factor of1.035
between both values is consistent when using otherstellar_irradiance
values, too. This may point to an issue with the normalisation of the irradiance?Unfortunately our calls to CliMT are deeply embedded in our model setup which makes it hard to copy and paste the affected code. My test simulation basically consists of a standard atmosphere without any aerosols or CFCs.
It would be really cool if you could reproduce the bug. Even if not you may have some ideas what could cause this behaviour. I am happy to provide further information when needed!
Cheers,
Lukas
The text was updated successfully, but these errors were encountered: