Cleaned up and improved generalization of mpas_isobaric_diagnostics code #1184
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This pull request includes a series of modifications that clean up the existing isobaric diagnostics interpolation code.
The existing isobaric diagnostics procedure comprises a number of variables at individual, specific pressure levels (e.g.,
temperature_200hPa
) and thus includes a significant amount of hard-coding, making it more tedious for users to modify.This modified version reduces (but does not eliminate) the need for hard-coding by prescribing a list of isobaric levels to which the variables are commonly interpolated, leading to variables of the form, e.g.,
temperature_isobaric
. These variables are also connected to anisobaric
diagnostic variable package and namelist config options (config_isobaric = .true.
) to make it easier for users to toggle on their calculations at runtime.Note: These additions of variable packages and namelist config options for the diagnostics procedures will be also applied in upcoming pull requests that include significant modifications and additions to the existing PV diagnostics package. The modified PV diagnostics package will also include features that extend the modified isobaric diagnostics code included here.
The specific changes included in this pull request are:
Adding an isobaric package definition to
Registry.xml
Adding a
config_isobaric
namelist option toRegistry_diagnostics.xml
Connecting the package variables to the namelist config option in a new script,
mpas_atm_diagnostics_packages.F
, which is called inmpas_atm_core_interface.F
Updating
Registry_isobaric.xml
to remove the existing highly specific variables (e.g.,temperature_200hPa
) and replacing them with more generalizable variables that include dimensions of multiple isobaric levels (e.g.,temperature_isobaric
)Updating
Registry.xml
to reflect these changed variables in the default diagnostics output streamUpdating
mpas_isobaric_diagnostics.F
with code that performs the interpolation of the new generalizable variables and removal of the interpolation of the former specific variablesAdding halo groups
'isobaric:pressure_p'
and'isobaric:vorticity'
tompas_atm_halos.F
and removing the previous halo field exchanges frommpas_isobaric_diagnostics.F
to reflect the new MPAS halo structureUpdating
mpas_atm_diagnostics_manager.F
to include calls to the new halo exchange procedure andconfigs
input arguments to the isobaric subroutine callsUpdating
mpas_atm_core.F
to include the halo exchange input arguments tompas_atm_diag_compute()