Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/main' into dev/14.4.0
Browse files Browse the repository at this point in the history
Signed-off-by: Melissa Sulprizio <mpayer@seas.harvard.edu>
  • Loading branch information
msulprizio committed Apr 3, 2024
2 parents 24d40b7 + 495766f commit c090eb0
Show file tree
Hide file tree
Showing 11 changed files with 105 additions and 42 deletions.
22 changes: 11 additions & 11 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -1,36 +1,36 @@
[submodule "src/MAPL"]
[submodule "MAPL"]
path = src/MAPL
url = https://github.com/geoschem/MAPL
[submodule "src/GMAO_Shared"]
[submodule "GMAO_Shared"]
path = src/GMAO_Shared
url = https://github.com/geoschem/GMAO_Shared
[submodule "ESMA_cmake"]
path = ESMA_cmake
url = https://github.com/geoschem/ESMA_cmake
[submodule "src/gFTL-shared"]
[submodule "gFTL-shared"]
path = src/gFTL-shared
url = https://github.com/geoschem/gFTL-shared.git
[submodule "src/FMS"]
[submodule "FMS"]
path = src/FMS
url = https://github.com/geoschem/FMS.git
[submodule "src/GCHP_GridComp/FVdycoreCubed_GridComp"]
[submodule "FVdycoreCubed_GridComp"]
path = src/GCHP_GridComp/FVdycoreCubed_GridComp
url = https://github.com/geoschem/FVdycoreCubed_GridComp.git
[submodule "src/GCHP_GridComp/GEOSChem_GridComp/geos-chem"]
[submodule "geos-chem"]
path = src/GCHP_GridComp/GEOSChem_GridComp/geos-chem
url = https://github.com/geoschem/geos-chem.git
[submodule "src/GCHP_GridComp/HEMCO_GridComp/HEMCO"]
[submodule "HEMCO"]
path = src/GCHP_GridComp/HEMCO_GridComp/HEMCO
url = https://github.com/geoschem/HEMCO.git
[submodule "src/yaFyaml"]
[submodule "yaFyaml"]
path = src/yaFyaml
url = https://github.com/geoschem/yaFyaml.git
[submodule "src/pFlogger"]
[submodule "pFlogger"]
path = src/pFlogger
url = https://github.com/geoschem/pFlogger.git
[submodule "docs/geos-chem-shared-docs"]
[submodule "geos-chem-shared-docs"]
path = docs/source/geos-chem-shared-docs
url = https://github.com/geoschem/geos-chem-shared-docs.git
[submodule "src/GCHP_GridComp/GEOSChem_GridComp/Cloud-J"]
[submodule "Cloud-J"]
path = src/GCHP_GridComp/Cloud-J
url = https://github.com/geoschem/Cloud-J
20 changes: 20 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,26 @@ This file documents all notable changes to the GCHP wrapper repository starting

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [Unreleased] - TBD
### Changed
- Updated GEOS-Chem submodule to 14.4.0
- Updated HEMCO submodule to 3.9.0

## [14.3.1] - 2024-04-02
### Added
- Now print container name being read by ExtData when `CAP.EXTDATA` is set to `DEBUG` in `logging.yml`
- Added new pre-processer setting GCHP_WRAPPER for use in submodules
- Added PLEadv export to FV3 submodule for inclusion in GCHP HISTORY.rc files

### Changed
- Updated GEOS-Chem submodule to 14.3.1
- Updated HEMCO submodule to 3.8.1
- Now use short names for submodules (i.e. without the path) in `.gitmodules`

### Fixed
- Fixed bug where SPHU used to construct PLE for advection was vertically inverted if using raw GMAO meteorology files
- Fixed bug in UpwardsMassFlux diagnostic that was causing all values to be zero

## [14.3.0] - 2024-02-07
### Added
- Added capability for TOMAS simulations in GCHP
Expand Down
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
cmake_minimum_required (VERSION 3.13)
project (gchp_ctm
VERSION 14.3.0
VERSION 14.3.1
LANGUAGES Fortran CXX C
)

Expand Down
2 changes: 1 addition & 1 deletion docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
author = 'GEOS-Chem Support Team'

# The full version, including alpha/beta/rc tags
release = '14.3.0'
release = '14.3.1'


# -- General configuration ---------------------------------------------------
Expand Down
1 change: 1 addition & 0 deletions src/GCHP_GridComp/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
# Set cmake logicals needed for subprojects
#---------------
set(FV_PRECISION R8 ) # FV3 precision is R8
set(GCHP_WRAPPER TRUE ) # GCHP model configuration
set(CLOUDJ_EXTERNAL_CONFIG TRUE ) # Not Cloud-J standalone
set(HEMCO_EXTERNAL_CONFIG TRUE ) # Not HEMCO standalone
set(GC_EXTERNAL_CONFIG TRUE ) # Not GEOS-Chem Classic
Expand Down
2 changes: 1 addition & 1 deletion src/GCHP_GridComp/FVdycoreCubed_GridComp
90 changes: 66 additions & 24 deletions src/GCHP_GridComp/GCHPctmEnv_GridComp/GCHPctmEnv_GridCompMod.F90
Original file line number Diff line number Diff line change
Expand Up @@ -686,11 +686,21 @@ subroutine prepare_ple_exports(IMPORT, EXPORT, PLE, RC)
! Also compute dry pressures if using dry pressure in advection
if ( use_total_air_pressure_in_advection < 1 ) then

call calculate_ple(PS1_IMPORT, DryPLE0_EXPORT, SPHU1_IMPORT )
call calculate_ple( &
PS=PS1_IMPORT, &
PLE=DryPLE0_EXPORT, &
SPHU=SPHU1_IMPORT, &
topDownMet=meteorology_vertical_index_is_top_down )

DryPLE0_EXPORT = 100.0d0 * DryPLE0_EXPORT
DryPLE0_EXPORT = DryPLE0_EXPORT(:,:,LM:0:-1)

call calculate_ple(PS2_IMPORT, DryPLE1_EXPORT, SPHU2_IMPORT )
call calculate_ple( &
PS=PS2_IMPORT, &
PLE=DryPLE1_EXPORT, &
SPHU=SPHU2_IMPORT, &
topDownMet=meteorology_vertical_index_is_top_down )

DryPLE1_EXPORT = 100.0d0 * DryPLE1_EXPORT
DryPLE1_EXPORT = DryPLE1_EXPORT(:,:,LM:0:-1)

Expand Down Expand Up @@ -934,10 +944,10 @@ subroutine prepare_massflux_exports(IMPORT, EXPORT, PLE, dt, RC)
end if

! Set vertical motion diagnostic if enabled in HISTORY.rc
call MAPL_GetPointer(EXPORT, UpwardsMassFlux, 'UpwardsMassFlux', &
NotFoundOK=.TRUE., RC=STATUS)
_VERIFY(STATUS)
if (associated(UpwardsMassFlux)) then
call MAPL_GetPointer(EXPORT, UpwardsMassFlux, 'UpwardsMassFlux', &
RC=STATUS)
_VERIFY(STATUS)
call lgr%debug('Calculating diagnostic export UpwardsMassFlux')

! Get vertical mass flux
Expand Down Expand Up @@ -973,12 +983,13 @@ end subroutine prepare_massflux_exports
!
! !INTERFACE:
!
subroutine calculate_ple(PS, PLE, SPHU)
subroutine calculate_ple(PS, PLE, SPHU, topDownMet )
!
! !INPUT PARAMETERS:
!
real(r4), intent(in) :: PS(:,:) ! Surface pressure [hPa]
real(r4), intent(in), OPTIONAL :: SPHU(:,:,:) ! Specific humidity [kg/kg]
logical, intent(in), OPTIONAL :: topDownMet ! True if meteorology level 1 is TOA
!
! !INPUT PARAMETERS:
!
Expand Down Expand Up @@ -1070,26 +1081,57 @@ subroutine calculate_ple(PS, PLE, SPHU)
js = lbound(PS,2)
je = ubound(PS,2)
LM = size (SPHU,3)
do J=js,je
do I=is,ie

! Start with TOA pressure
PSDry = AP(LM+1)

! Stack up dry delta-P to get surface dry pressure
do L=1,LM
PEdge_Bot = AP(L ) + ( BP(L ) * dble(PS(I,J)) )
PEdge_Top = AP(L+1) + ( BP(L+1) * dble(PS(I,J)) )
PSDry = PSDry &
+ ( ( PEdge_Bot - Pedge_Top ) * ( 1.d0 - SPHU(I,J,L) ) )
enddo

! Work back up from the surface to get dry level edges
do L=1,LM+1
PLE(I,J,L) = AP(L) + ( BP(L) * dble(PSDry) )
if ( topDownMet ) then

do J=js,je
do I=is,ie

! Start with TOA pressure
PSDry = AP(LM+1)

! Stack up dry delta-P to get surface dry pressure
! Vertically flip humidity if using top-down meteorology (raw GMAO files)
do L=1,LM
PEdge_Bot = AP(L ) + ( BP(L ) * dble(PS(I,J)) )
PEdge_Top = AP(L+1) + ( BP(L+1) * dble(PS(I,J)) )
PSDry = PSDry &
+ ( ( PEdge_Bot - Pedge_Top ) * ( 1.d0 - SPHU(I,J,LM-L+1) ) )
enddo

! Work back up from the surface to get dry level edges
do L=1,LM+1
PLE(I,J,L) = AP(L) + ( BP(L) * dble(PSDry) )
enddo

enddo
enddo

else

do J=js,je
do I=is,ie

! Start with TOA pressure
PSDry = AP(LM+1)

! Stack up dry delta-P to get surface dry pressure
do L=1,LM
PEdge_Bot = AP(L ) + ( BP(L ) * dble(PS(I,J)) )
PEdge_Top = AP(L+1) + ( BP(L+1) * dble(PS(I,J)) )
PSDry = PSDry &
+ ( ( PEdge_Bot - Pedge_Top ) * ( 1.d0 - SPHU(I,J,L) ) )
enddo

! Work back up from the surface to get dry level edges
do L=1,LM+1
PLE(I,J,L) = AP(L) + ( BP(L) * dble(PSDry) )
enddo
enddo
enddo
enddo
enddo

endif

endif


Expand Down
2 changes: 1 addition & 1 deletion src/GCHP_GridComp/GEOSChem_GridComp/geos-chem
Submodule geos-chem updated 134 files
2 changes: 1 addition & 1 deletion src/MAPL

0 comments on commit c090eb0

Please sign in to comment.