Skip to content
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

Rescale volo and clean up the unit descriptions of 17 variables #820

Open
wants to merge 4 commits into
base: dev/gfdl
Choose a base branch
from

Conversation

Hallberg-NOAA
Copy link
Member

This PR consists of four commits that correct the descriptions of the units or purpose of some variables. Specifically this PR:

  • uses rescaled units for the calculation of the volo diagnostic
  • renames a local variable to masked_area for greater clarity
  • replaces the unused real placeholder element in file_OBC_CS with a logical placeholder
  • corrects the syntax or substance of the descriptions of the units of 14 variables.

All solutions and output are bitwise identical, and no interfaces are changed. The specific commits in this PR include:

  • 1b142bad1 Switched the placeholder element of file_OBC_CS
  • 320a62fd6 Fix the syntax or substance in 10 comment units
  • 69ba88dc2 Rename masked_area in compute_global_grid_integral
  • f83539457 Calculate volo in scaled units

  Calculate the volo diagnostic in scaled units using the tmp_scale argument to
global_area_integral and undo this scaling with a conversion argument on its
register_scalar_field call.  Also corrected the units in the comments describing
the mass_celland masso variables in calculate_diagnostic_fields.  All answers
are bitwise identical.
  Renamed the internal variable tmpForSumming to masked_area in
compute_global_grid_integrals and corrected the description of its units from
[m2] to [L2 ~> m2].  All answers are bitwise identical.
  Corrected incorrect syntax in the descriptions of 4 positions variables in
write energy, 1 reused position variable in set_grid_metrics_from_mosaic and 1
position variable in bkgnd_mixing_CS.  Also added the unscaled units to the
comments documenting two lines of calculations in wave_speeds, and added the
scaled units to two variables related to the ice-shelf surface mass balance.
Only comments are changed and all answers are bitwise identical.
  Replaced the unused real tide_flow element of the file_OBC_CS type with the
logical OBC_file_used element to more clearly reflect that this placeholder
element is only here to avoid having a completely empty type.  The actual value
of this element is irrelevant, but some compilers require that all Fortran types
have at least one element.  This change eliminates a meaningless hard-coded real
variable with undefined units and a misleading name and replaces it with a
logical variable named to reflect its actual purpose.  All answers are bitwise
identical.
@Hallberg-NOAA Hallberg-NOAA added documentation Improvements or additions to documentation refactor Code cleanup with no changes in functionality or results labels Jan 31, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation refactor Code cleanup with no changes in functionality or results
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants