-
Notifications
You must be signed in to change notification settings - Fork 60
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
*+Add forcing%tau_mag_gustless & tau_mag opt args #445
*+Add forcing%tau_mag_gustless & tau_mag opt args #445
Conversation
Codecov Report
@@ Coverage Diff @@
## dev/gfdl #445 +/- ##
============================================
- Coverage 38.06% 38.04% -0.02%
============================================
Files 269 269
Lines 77133 77175 +42
Branches 14233 14254 +21
============================================
+ Hits 29358 29361 +3
- Misses 42456 42493 +37
- Partials 5319 5321 +2
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
Added the new tau_mag_gustless element to the forcing type, and set this array in set_derived_forcing_fields if it is associated. Also added new tau_mag optional arguments to the public routines allocate_forcing_by_group() and allocate_mech_forcing_by_group(), with similar mandatory arguments added to the private subroutines get_forcing_groups() and get_mech_forcing_groups(). Tests for an associated pointer were added before all calls setting the ustar, tau_mag or ustar_gustless arrays, preparing for these ustar pointers only to be set when the model is run in Boussinesq mode when the ustar actually make sense. Also use specific volume derivatives to calculate non-Boussinesq mode buoyancy fluxes in calculateBuoyancy_Flux1d, leaving the Boussinesq buoyancy flux calculations unchanged. All answers are bitwise identical in Boussinesq mode, but there is a new element in a transparent type and new optional arguments publicly visible subroutines, and answers will change in non-Boussinesq cases that depend on the surface buoyancyFlux that is returned by calculateBuoyancy_Flux1d.
aa504f3
to
abfb009
Compare
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.
These changes all look good
Gaea regression: https://gitlab.gfdl.noaa.gov/ogrp/MOM6/-/pipelines/20260 ✔️ |
Added the name to the do_taumag argument in a call to allocate_forcing_type in allocate_forcing_by_ref to account for the fact that there are unused wave-related optional arguments in this interface. When this was omitted in the current code, the wrong arrays are being allocated during rotation tests with resultant segmentation faults in those tests. This commit corrects a bug that was recently added with MOM6 dev/gfdl PR #445.
Added the new tau_mag_gustless element to the forcing type, and set this array in set_derived_forcing_fields if it is associated. Also added new tau_mag optional arguments to the public routines allocate_forcing_by_group() and allocate_mech_forcing_by_group(), with similar mandatory arguments added to the private subroutines get_forcing_groups() and get_mech_forcing_groups(). Tests for an associated pointer were added before all calls setting the ustar, tau_mag or ustar_gustless arrays, preparing for these ustar pointers only to be set when the model is run in Boussinesq mode when the ustar actually make sense.
Also use specific volume derivatives to calculate non-Boussinesq mode buoyancy fluxes in calculateBuoyancy_Flux1d, leaving the Boussinesq buoyancy flux calculations unchanged.
All answers are bitwise identical in Boussinesq mode, but there is a new element in a transparent type and new optional arguments publicly visible subroutines, and answers will change in non-Boussinesq cases that depend on the surface buoyancyFlux that is returned by calculateBuoyancy_Flux1d.