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

Wrap MPAS longitude values to [0,2pi) range #23

Closed

Conversation

gdicker1
Copy link

This commit addresses issues that were seen when using ncdata with longitudes in the [-pi, pi] range in cases with full physics. This would cause the atmosphere to become unphysical and runs to fail. This change is made just after the longitude values are read to ensure they are correct for the remainder of execution.

This duplicates ESCOMP/CAM #1095 for EarthWorks

This commit addresses issues that were seen when using ncdata with
longitudes in the [-pi, pi] range in cases with full physics.  This
would cause the atmosphere to become unphysical and runs to fail. This
change is made just after the longitude values are read to ensure they
are correct for the remainder of execution.
NOTE: this is before the 'aux_cam' tests have been run
@gdicker1 gdicker1 changed the title Mpas loncell wrapto2pi Wrap MPAS longitude values to [0,2pi) range Jul 18, 2024
Previous versions of the lonCell_arr adjustment used an explicit loop. Without this loop, the nCells variable and the routine to fetch it are no longer needed.
Makes code consistent with CAM coding standards: 'All variables of type
real must have a specified kind, including literals.'
This commit also extends the comment that was with this code block,
includes an if condition so valid values aren't modified, uses kinds and
constants (pi) that are already used in the new file, and updates the
ChangeLog so the correct file is referenced.
Conform to CAM Coding Standards: 'Use symbolic numerical comparison
operators (e.g., ==, /=, <, >=) not old character versions (e.g.,
.eq.).'
@gdicker1
Copy link
Author

This PR is replaced by #33 which will bring in the same changes

@gdicker1 gdicker1 closed this Sep 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request upstream Related to the upstream repo (ESCOMP/CAM)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant