From cba91e4e46a4a0d611620d10680e1dce5b92ecbd Mon Sep 17 00:00:00 2001 From: "Xiaqiong.Zhou" Date: Tue, 23 Apr 2024 15:01:59 -0500 Subject: [PATCH 1/7] Point dycore to personal branch --- .gitmodules | 4 ++-- atmos_cubed_sphere | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.gitmodules b/.gitmodules index 22c723ac1..a32a46cd3 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,7 +1,7 @@ [submodule "atmos_cubed_sphere"] path = atmos_cubed_sphere - url = https://github.com/NOAA-GFDL/GFDL_atmos_cubed_sphere - branch = dev/emc + url = https://github.com/XiaqiongZhou-NOAA/GFDL_atmos_cubed_sphere + branch = hydro [submodule "ccpp/framework"] path = ccpp/framework url = https://github.com/NCAR/ccpp-framework diff --git a/atmos_cubed_sphere b/atmos_cubed_sphere index 97114888f..aabfdccae 160000 --- a/atmos_cubed_sphere +++ b/atmos_cubed_sphere @@ -1 +1 @@ -Subproject commit 97114888f529c2df70ed4a350fd2428df74839ff +Subproject commit aabfdccae440da7389195762601db7fcc09f6f11 From 2bdfa00b6010d37b05ddaecd783950c66ed2724e Mon Sep 17 00:00:00 2001 From: "Xiaqiong.Zhou" Date: Tue, 23 Apr 2024 15:14:26 -0500 Subject: [PATCH 2/7] Remove -DUSE_COND and -DMOIST_CAPPA compiling flags for hydrostatic runs; Fix the issue to write out omga and geopotential height for inline post --- CMakeLists.txt | 9 +++++++- ccpp/CMakeLists.txt | 4 +++- io/post_fv3.F90 | 51 +++++++++++++++++++++++++++++++-------------- 3 files changed, 46 insertions(+), 18 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index c310110ca..a497fd3bb 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -37,6 +37,9 @@ set(USE_GFSL63 ON) if(MOVING_NEST) set(MOVING_NEST ON) endif() +if(HYDRO) + set(HYDRO ON) +endif() add_subdirectory(atmos_cubed_sphere) target_compile_definitions(fv3 PRIVATE BYPASS_BREED_SLP_INLINE) @@ -61,7 +64,11 @@ if(NOT PARALLEL_NETCDF) endif() if(MOVING_NEST) - list(APPEND _fv3atm_defs_private MOVING_NEST MOIST_CAPPA USE_COND) + list(APPEND _fv3atm_defs_private MOVING_NEST) + if (NOT HYDRO) + list(APPEND _fv3atm_defs_private MOIST_CAPPA USE_COND) + endif() + if(DEBUG) list(APPEND _fv3atm_defs_private DEBUG) endif() diff --git a/ccpp/CMakeLists.txt b/ccpp/CMakeLists.txt index ee2b9c8b2..53f9f0023 100644 --- a/ccpp/CMakeLists.txt +++ b/ccpp/CMakeLists.txt @@ -84,8 +84,10 @@ endif(CCPP_32BIT) #------------------------------------------------------------------------------ # Add model-specific flags for C/C++/Fortran preprocessor +if (NOT HYDRO) add_definitions(-DMOIST_CAPPA -DUSE_COND -DNEMS_GSM) -add_definitions(-DINTERNAL_FILE_NML) +endif() +add_definitions(-DINTERNAL_FILE_NML -DNEMS_GSM) if(MULTI_GASES) add_definitions(-DMULTI_GASES) diff --git a/io/post_fv3.F90 b/io/post_fv3.F90 index c0ba56dda..cb2149fb9 100644 --- a/io/post_fv3.F90 +++ b/io/post_fv3.F90 @@ -3562,6 +3562,19 @@ subroutine set_postvars_fv3(wrt_int_state,grid_id,mype,mpicomp) enddo endif + ! model level omga + if(trim(fieldname)=='omga') then + !$omp parallel do default(none) private(i,j,l) shared(lm,jsta,jend,ista,iend,omga,arrayr43d,fillvalue,spval) + do l=1,lm + do j=jsta,jend + do i=ista, iend + omga(i,j,l) = arrayr43d(i,j,l) + if(abs(arrayr43d(i,j,l)-fillvalue)