From 3faa58e1ef4e46d05b6eef5056fdfdadf6b747f2 Mon Sep 17 00:00:00 2001 From: Bill Skamarock Date: Fri, 17 Oct 2025 13:30:56 -0600 Subject: [PATCH 1/2] Implement option to turn off microphysics tendencies above a specified height This commit provides the capability of turning off use of the microphysics tendency above a user-specified height. This change alleviates some instabilities encountered in deep-domain MPAS simulations (model tops above the stratopause). The changes include: (1) addition of a namelist variable specifying the height above which the microphysics tendencies are to be ignored, and an integer variable that is set when the integration starts specifying the level based on that height. (2) additions to src/core_atmosphere/physics/mpas_atmphys_init.F to set the level based on the namelist-specified height. (3) changes in src/core_atmosphere/physics/mpas_atmphys_interface.F that disable the microphysics tendency updates above the specified level. --- src/core_atmosphere/Registry.xml | 8 +++ .../physics/mpas_atmphys_init.F | 21 +++++++- .../physics/mpas_atmphys_interface.F | 54 +++++++++++++++++-- 3 files changed, 77 insertions(+), 6 deletions(-) diff --git a/src/core_atmosphere/Registry.xml b/src/core_atmosphere/Registry.xml index 4281c40bba..b0bd5e9e31 100644 --- a/src/core_atmosphere/Registry.xml +++ b/src/core_atmosphere/Registry.xml @@ -1599,6 +1599,9 @@ + + @@ -2215,6 +2218,11 @@ description="number of microphysics time-steps per physics time-steps" possible_values="Positive integers"/> + + Date: Mon, 9 Feb 2026 18:15:50 -0700 Subject: [PATCH 2/2] Move 'mp_top_level' from mesh pool to tend_physics pool in the atmosphere core This commit moves the 'mp_top_level' variable from the 'mesh' pool to the 'tend_physics' pool in the atmosphere core. The mp_top_level variable holds the level above which microphysics tendencies are to be ignored, and it is therefore naturally associated with physics tendencies. --- src/core_atmosphere/Registry.xml | 6 +++--- src/core_atmosphere/mpas_atm_core.F | 4 +++- src/core_atmosphere/physics/mpas_atmphys_init.F | 5 +++-- src/core_atmosphere/physics/mpas_atmphys_interface.F | 3 ++- 4 files changed, 11 insertions(+), 7 deletions(-) diff --git a/src/core_atmosphere/Registry.xml b/src/core_atmosphere/Registry.xml index b0bd5e9e31..de255ecac5 100644 --- a/src/core_atmosphere/Registry.xml +++ b/src/core_atmosphere/Registry.xml @@ -1599,9 +1599,6 @@ - - @@ -3427,6 +3424,9 @@ + + diff --git a/src/core_atmosphere/mpas_atm_core.F b/src/core_atmosphere/mpas_atm_core.F index f7d04a1f0c..67b6f53c37 100644 --- a/src/core_atmosphere/mpas_atm_core.F +++ b/src/core_atmosphere/mpas_atm_core.F @@ -390,6 +390,7 @@ subroutine atm_mpas_init_block(dminfo, stream_manager, block, mesh, dt) type (mpas_pool_type), pointer :: state type (mpas_pool_type), pointer :: diag type (mpas_pool_type), pointer :: tend + type (mpas_pool_type), pointer :: tend_physics type (mpas_pool_type), pointer :: sfc_input type (mpas_pool_type), pointer :: diag_physics type (mpas_pool_type), pointer :: diag_physics_noahmp @@ -566,6 +567,7 @@ subroutine atm_mpas_init_block(dminfo, stream_manager, block, mesh, dt) if (moist_physics) then !initialization of some input variables in registry: call mpas_pool_get_subpool(block % structs, 'tend', tend) + call mpas_pool_get_subpool(block % structs, 'tend_physics', tend_physics) call mpas_pool_get_subpool(block % structs, 'diag_physics', diag_physics) call mpas_pool_get_subpool(block % structs, 'diag_physics_noahmp', diag_physics_noahmp) call mpas_pool_get_subpool(block % structs, 'ngw_input', ngw_input) @@ -576,7 +578,7 @@ subroutine atm_mpas_init_block(dminfo, stream_manager, block, mesh, dt) call physics_run_init(block % configs, mesh, state, clock, stream_manager) !initialization of all physics: - call physics_init(dminfo, stream_manager, clock, block % configs, mesh, diag, tend, state, 1, & + call physics_init(dminfo, stream_manager, clock, block % configs, mesh, diag, tend, tend_physics, state, 1, & diag_physics, diag_physics_noahmp, ngw_input, atm_input, sfc_input, output_noahmp) endif #endif diff --git a/src/core_atmosphere/physics/mpas_atmphys_init.F b/src/core_atmosphere/physics/mpas_atmphys_init.F index c9d9e21542..5183f5a974 100644 --- a/src/core_atmosphere/physics/mpas_atmphys_init.F +++ b/src/core_atmosphere/physics/mpas_atmphys_init.F @@ -80,7 +80,7 @@ module mpas_atmphys_init !================================================================================================================= - subroutine physics_init(dminfo,stream_manager,clock,configs,mesh,diag,tend,state,time_lev,diag_physics, & + subroutine physics_init(dminfo,stream_manager,clock,configs,mesh,diag,tend,tend_physics,state,time_lev,diag_physics, & diag_physics_noahmp,ngw_input,atm_input,sfc_input,output_noahmp) !================================================================================================================= @@ -99,6 +99,7 @@ subroutine physics_init(dminfo,stream_manager,clock,configs,mesh,diag,tend,state type(mpas_pool_type),intent(inout):: state type(mpas_pool_type),intent(inout):: diag type(mpas_pool_type),intent(inout):: tend + type(mpas_pool_type),intent(inout):: tend_physics type(mpas_pool_type),intent(inout):: diag_physics type(mpas_pool_type),intent(inout):: diag_physics_noahmp type(mpas_pool_type),intent(inout):: ngw_input @@ -242,7 +243,7 @@ subroutine physics_init(dminfo,stream_manager,clock,configs,mesh,diag,tend,state call mpas_pool_get_dimension(mesh,'nVertLevels',nVertLevels ) call mpas_pool_get_array(mesh,'rdzw' ,rdzw ) call mpas_pool_get_array(mesh,'dzu' ,dzu ) - call mpas_pool_get_array(mesh,'mp_top_level',mp_top_level) + call mpas_pool_get_array(tend_physics,'mp_top_level',mp_top_level) currTime = mpas_get_clock_time(clock,MPAS_NOW,ierr) call mpas_get_time(curr_time=currTime,DoY=julday,ierr=ierr) diff --git a/src/core_atmosphere/physics/mpas_atmphys_interface.F b/src/core_atmosphere/physics/mpas_atmphys_interface.F index ae35879732..535819ffc8 100644 --- a/src/core_atmosphere/physics/mpas_atmphys_interface.F +++ b/src/core_atmosphere/physics/mpas_atmphys_interface.F @@ -824,7 +824,8 @@ subroutine microphysics_to_MPAS(configs,mesh,state,time_lev,diag,diag_physics,te call mpas_pool_get_array(mesh,'zz' ,zz ) call mpas_pool_get_array(mesh,'zgrid',zgrid) - call mpas_pool_get_array(mesh,'mp_top_level',mp_top_level) + + call mpas_pool_get_array(tend_physics,'mp_top_level',mp_top_level) call mpas_pool_get_array(diag,'exner' ,exner ) call mpas_pool_get_array(diag,'exner_base' ,exner_b )