-
Notifications
You must be signed in to change notification settings - Fork 134
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
use -puny in denominator of scaling ratio for flux limiting #474
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have examined the code and this is indeed a bug that needs to be fixed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Prevents a possible NaN when abs(fbot+fside) = puny. Tested in a 5 year DTEST with round-off level differences.
Just want to add a note that this changes answers in all cases. |
Updates to Consortium/main include the following. More accurate calculation of areafact in remapping CICE-Consortium#849. This PR implements improvements to the areafact calculation for remapping. This PR will change baselines (as expected). As noted in the 6.5 release notes, this improves C-grid solutions Update Icepack, add snicar and snicartest tests CICE-Consortium#902. This PR includes an update to Icepack to use -puny when limiting fluxes (use -puny in denominator of scaling ratio for flux limiting CICE-Consortium/Icepack#474). This PR will change baselines (as expected). Update update_ocn_f implementation, Add cpl_frazil namelist CICE-Consortium#889. This PR adds a new name list configuration cpl_frazil to address an issue first noted in update_ocn_f problem CICE-Consortium/Icepack#390. In UWM the default configuration when coupled to FV3atm is ktherm=2 and update_ocn_f=true, meaning the salt and freshwater fluxes are computed in CICE and passed to MOM6. For this configuration, the default of cpl_frazil will be fresh_ice_corr. Testing has shown this PR alone does not change answers in UWM for either the ktherm=1 or ktherm=2 cases.
Fix the sign of puny in the denominator of the ratio used to scale heat fluxes
@njeffery
Bug fix tested in E3SM by @njeffery.
Bottom and lateral heat fluxes are limited by the total amount of heat available for melting, and all of these terms are negative. In particular, fbot+fside<0. Therefore the value of puny needed to keep the denominator from being too small should also be negative.