From 17b132937305114a33dc90d06db47007bd002709 Mon Sep 17 00:00:00 2001 From: Bob Yantosca Date: Wed, 10 Jan 2024 14:39:34 -0500 Subject: [PATCH 01/11] geos-chem-shared-docs update: Minor edits to supplemental guides Added updates to coards, error, netCDF Supplemental Guides Signed-off-by: Bob Yantosca --- docs/source/geos-chem-shared-docs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/source/geos-chem-shared-docs b/docs/source/geos-chem-shared-docs index e23eb23d..367e5fa4 160000 --- a/docs/source/geos-chem-shared-docs +++ b/docs/source/geos-chem-shared-docs @@ -1 +1 @@ -Subproject commit e23eb23dcc5cd2922e62a356e2f59634817bdd95 +Subproject commit 367e5fa4184185e00cb57d9babf0b16db1d1abba From a22ed165dfbb1c6e2e4c905c535c112175ec3ad1 Mon Sep 17 00:00:00 2001 From: Bob Yantosca Date: Wed, 10 Jan 2024 14:46:37 -0500 Subject: [PATCH 02/11] Minor updates in ReadTheDocs documentation docs/source/conf.py - Exclude the following files from being included in the documentation - geos-chem-shared-docs/README.md - geos-chem-shared-docs/supplemental-guides/species-guide.rst - geos-chem-shared-docs/supplemental-guides/using-kpp-with-gc.rst docs/sourrce/hco-sa-guide/login-env.rst - Remove reference to the using-kpp-with-gc.rst supplemental guide Signed-off-by: Bob Yantosca --- docs/source/conf.py | 7 +++++-- docs/source/hco-sa-guide/login-env.rst | 3 +-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/docs/source/conf.py b/docs/source/conf.py index c7ccc0b0..30a3395b 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -82,8 +82,11 @@ def format_web_refs(self, e): # List of patterns, relative to source directory, that match files and # directories to ignore when looking for source files. # This pattern also affects html_static_path and html_extra_path. -exclude_patterns = [] - +exclude_patterns = [ + 'geos-chem-shared-docs/README.md', + 'geos-chem-shared-docs/supplemental-guides/species-guide.rst', + 'geos-chem-shared-docs/supplemental-guides/using-kpp-with-gc.rst', +] # -- Options for HTML output ------------------------------------------------- diff --git a/docs/source/hco-sa-guide/login-env.rst b/docs/source/hco-sa-guide/login-env.rst index 4fdfd64f..8c6710f6 100644 --- a/docs/source/hco-sa-guide/login-env.rst +++ b/docs/source/hco-sa-guide/login-env.rst @@ -255,8 +255,7 @@ These environment variables should be defined in your HEMCOc only requires the Fortran compiler. But you will also need the C and C++ compilers if you plan to build other - software packages (:ref:`such as KPP `) or :ref:`install - libraries manually `. + software packages or :ref:`install libraries manually `. Also, older Intel compiler versions used :envvar:`icc` as the name for the C compiler and :envvar:`icpc` as the name of the C++ compiler. From 4ee0e5c959b07219f284dc252ff8bce8c6703ee4 Mon Sep 17 00:00:00 2001 From: bcroft Date: Fri, 12 Jan 2024 08:36:51 -0600 Subject: [PATCH 03/11] Bug fixes for TOMAS --- src/Extensions/hcox_tomas_jeagle_mod.F90 | 52 +++++++++++++----------- 1 file changed, 28 insertions(+), 24 deletions(-) diff --git a/src/Extensions/hcox_tomas_jeagle_mod.F90 b/src/Extensions/hcox_tomas_jeagle_mod.F90 index a53a58ad..b59f4ad6 100644 --- a/src/Extensions/hcox_tomas_jeagle_mod.F90 +++ b/src/Extensions/hcox_tomas_jeagle_mod.F90 @@ -281,7 +281,7 @@ SUBROUTINE HCOX_TOMAS_Jeagle_Run( ExtState, HcoState, RC ) ! adjusting coeff !### Debug - print*, 'IN HCOX_TOMAS_Jeagle_Mod.F90' + !print*, 'IN HCOX_TOMAS_Jeagle_Mod.F90' ! Init ptr3D => NULL() @@ -530,9 +530,9 @@ SUBROUTINE HCOX_TOMAS_Jeagle_Run( ExtState, HcoState, RC ) ! HEMCO species ID HcoID = HCO_GetHcoID( TRIM(SpcName), HcoState ) - !### Debug - print*, 'Aerosol number AT 50, 10,: ', Inst%TC1(ii,jj,1,k) - print*, 'HCO ID: ', K, SpcName, HcoID + !### Debug - comment out print over random oceen box - update indices if needed bc, 18/12/23 + !!print*, 'Aerosol number AT 1, 1,: ', Inst%TC1(ii,jj,1,k) + !!print*, 'HCO ID: ', K, SpcName, HcoID ! Add number to the HEMCO data structure CALL HCO_EmisAdd( HcoState, Inst%TC1(:,:,:,K), HcoID, RC) @@ -1052,29 +1052,33 @@ SUBROUTINE HCOX_TOMAS_Jeagle_Init( HcoState, ExtName, ExtState, RC ) 4.02325d-01, 5.06898d-01, 6.38652d-01, 8.04651d-01, 1.01380d+00 /) #endif + + !bc, 10/01/24 - comment this out as coef is not being used !======================================================================= ! Allocate quantities depending on horizontal resolution !======================================================================= - IF ( TRIM( HcoState%Config%GridRes) == '4.0x5.0' ) THEN - - !----------------------------------------------------------------------- - ! TOMAS simulations at 4 x 5 global resolution - !----------------------------------------------------------------------- - Inst%TOMAS_COEF = 1.d0 - - ELSE IF ( TRIM( HcoState%Config%GridRes) == '2.0x2.5' ) THEN - - !----------------------------------------------------------------------- - ! TOMAS simulations at 2 x 2.5 global resolution - !----------------------------------------------------------------------- - Inst%TOMAS_COEF = 1.d0 - - ELSE - - MSG = 'Adjust TOMAS_Jeagle emiss coeff (TOMAS_COEF) for your model res: SRCSALT30: hcox_TOMAS_jeagle_mod.F90' - CALL HCO_ERROR(MSG, RC ) - - ENDIF +! !IF ( TRIM( HcoState%Config%GridRes) == '4.0x5.0' ) THEN !comment out for +! resolution independence in code and consider implementing offline SS in +! TOMAS +! +! !----------------------------------------------------------------------- +! ! TOMAS simulations at 4 x 5 global resolution +! !----------------------------------------------------------------------- +! Inst%TOMAS_COEF = 1.d0 +! +! ELSE IF ( TRIM( HcoState%Config%GridRes) == '2.0x2.5' ) THEN +! +! !----------------------------------------------------------------------- +! ! TOMAS simulations at 2 x 2.5 global resolution +! !----------------------------------------------------------------------- +! Inst%TOMAS_COEF = 1.d0 +! +! ELSE +! +! MSG = 'Adjust TOMAS_Jeagle emiss coeff (TOMAS_COEF) for your model res: SRCSALT30: hcox_TOMAS_jeagle_mod.F90' +! CALL HCO_ERROR(MSG, RC ) +! +! ENDIF !======================================================================= ! Activate this module and the fields of ExtState that it uses From efde9f583e98855e7371b19b6cb96daff95f7586 Mon Sep 17 00:00:00 2001 From: Bob Yantosca Date: Wed, 17 Jan 2024 13:49:04 -0500 Subject: [PATCH 04/11] geos-chem-shared-docs update: Fix typo in netcdf-guide.rst This commit informs the GCClassic superproject about the following commits pushed to the geos-chem-shared-docs GitHub repository: 4bb2b11 Fix typo in netcdf-guide.rst Signed-off-by: Bob Yantosca --- docs/source/geos-chem-shared-docs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/source/geos-chem-shared-docs b/docs/source/geos-chem-shared-docs index 367e5fa4..4bb2b11e 160000 --- a/docs/source/geos-chem-shared-docs +++ b/docs/source/geos-chem-shared-docs @@ -1 +1 @@ -Subproject commit 367e5fa4184185e00cb57d9babf0b16db1d1abba +Subproject commit 4bb2b11e35953a8b0a8e1aec9161479bf0fc6bb6 From f807e1a3828a57d663001297f8d8cf36978040c3 Mon Sep 17 00:00:00 2001 From: Melissa Sulprizio Date: Wed, 7 Feb 2024 13:36:14 -0500 Subject: [PATCH 05/11] Update HEMCO version number to 3.8.0 in preparation for release Signed-off-by: Melissa Sulprizio --- CHANGELOG.md | 2 +- CMakeLists.txt | 2 +- docs/source/conf.py | 2 +- src/Core/hco_error_mod.F90 | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 46930265..2bb7df08 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,7 +5,7 @@ All notable changes to this project will be documented in this file. 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 +## [3.8.0] - 2024-02-07 ### Changed - Updated TOMAS_Jeagle sea salt extension diff --git a/CMakeLists.txt b/CMakeLists.txt index 39638d1e..99ff499b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,7 +1,7 @@ # HEMCO/CMakeLists.txt cmake_minimum_required(VERSION 3.5) -project(HEMCO VERSION 3.7.2 LANGUAGES Fortran) +project(HEMCO VERSION 3.8.0 LANGUAGES Fortran) # Reminder: Make sure to also update version in src/Core/hco_error_mod.F90 #----------------------------------------------------------------------------- diff --git a/docs/source/conf.py b/docs/source/conf.py index 30a3395b..a0ed8f58 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -23,7 +23,7 @@ author = 'GEOS-Chem Support Team' # The full version, including alpha/beta/rc tags -release = '3.7.2' +release = '3.8.0' # -- General configuration --------------------------------------------------- diff --git a/src/Core/hco_error_mod.F90 b/src/Core/hco_error_mod.F90 index 7bf556e9..291905b4 100644 --- a/src/Core/hco_error_mod.F90 +++ b/src/Core/hco_error_mod.F90 @@ -105,7 +105,7 @@ MODULE HCO_Error_Mod #endif ! HEMCO version number. - CHARACTER(LEN=12), PARAMETER, PUBLIC :: HCO_VERSION = '3.7.2' + CHARACTER(LEN=12), PARAMETER, PUBLIC :: HCO_VERSION = '3.8.0' INTERFACE HCO_Error MODULE PROCEDURE HCO_ErrorNoErr From 7933a1bb5692de8d475c7fa576d73b546d806869 Mon Sep 17 00:00:00 2001 From: Bob Yantosca Date: Tue, 12 Mar 2024 13:05:45 -0400 Subject: [PATCH 06/11] Increase allowed # of nested brackets from 5 to 10 src/Core/hco_config_mod.F90 - In routine "BracketCheck", changed the MAXBRACKNEST=5 setting to MAXBRACKNEST=10. This will allow up to 10 nested brackets in the HEMCO_Config.rc file. CHANGELOG.md - Updated accordingly Signed-off-by: Bob Yantosca --- CHANGELOG.md | 4 ++++ src/Core/hco_config_mod.F90 | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2bb7df08..e8d0802d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,10 @@ All notable changes to this project will be documented in this file. 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 +- Now allow up to 10 nested brackets (`((( )))`) in the `HEMCO_Config.rc` file + ## [3.8.0] - 2024-02-07 ### Changed - Updated TOMAS_Jeagle sea salt extension diff --git a/src/Core/hco_config_mod.F90 b/src/Core/hco_config_mod.F90 index 1dfca34a..f1b27372 100644 --- a/src/Core/hco_config_mod.F90 +++ b/src/Core/hco_config_mod.F90 @@ -1366,7 +1366,7 @@ SUBROUTINE BracketCheck( HcoConfig, STAT, LINE, SKIP, RC ) ! !LOCAL VARIABLES: ! ! Maximum number of nested brackets - INTEGER, PARAMETER :: MAXBRACKNEST = 5 + INTEGER, PARAMETER :: MAXBRACKNEST = 10 INTEGER :: IDX, STRLEN, ExtNr LOGICAL :: FOUND LOGICAL :: UseBracket, UseThis From 2bef966a0098297898757d3a8b7368353e4d24dc Mon Sep 17 00:00:00 2001 From: Christoph Keller Date: Wed, 13 Mar 2024 09:17:49 -0400 Subject: [PATCH 07/11] Limit volcano climatology message to root CPU Prevent excessive messages in log file if the volcano climatology is being used. --- src/Extensions/hcox_volcano_mod.F90 | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/Extensions/hcox_volcano_mod.F90 b/src/Extensions/hcox_volcano_mod.F90 index 1dc9841a..400818de 100644 --- a/src/Extensions/hcox_volcano_mod.F90 +++ b/src/Extensions/hcox_volcano_mod.F90 @@ -651,9 +651,11 @@ SUBROUTINE ReadVolcTable( HcoState, ExtState, Inst, RC ) INQUIRE( FILE=TRIM( ThisFile ), EXIST=FileExists ) ! Write message to stdout and HEMCO log - MSG = 'Attempting to read volcano climatology file' - WRITE( 6, 300 ) TRIM( MSG ) - CALL HCO_MSG( HcoState%Config%Err, MSG ) + IF ( Hcostate%amIRoot ) THEN + MSG = 'Attempting to read volcano climatology file' + WRITE( 6, 300 ) TRIM( MSG ) + CALL HCO_MSG( HcoState%Config%Err, MSG ) + ENDIF ! Create a display string based on whether or not the file is found IF ( FileExists ) THEN From 1115ce2da14e5d848cad939d3e7f0a957a12898c Mon Sep 17 00:00:00 2001 From: Lizzie Lundgren Date: Wed, 13 Mar 2024 10:18:36 -0400 Subject: [PATCH 08/11] Update changelog Signed-off-by: Lizzie Lundgren --- CHANGELOG.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2bb7df08..7cc29be5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,10 @@ All notable changes to this project will be documented in this file. 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). +## [3.8.1] - TBD +### Fixed +- Limit volcano climatology file read message to root core + ## [3.8.0] - 2024-02-07 ### Changed - Updated TOMAS_Jeagle sea salt extension From bd9d8cb72434add79fa7955ac1e3e8ac5a560fb9 Mon Sep 17 00:00:00 2001 From: Bob Yantosca Date: Mon, 18 Mar 2024 14:05:58 -0400 Subject: [PATCH 09/11] Now use short names for submodules in .gitmodules .gitmodules - Use short names (i.e. only the name of the module and not of the entire path) for submodules CHANGELOG.md - Updated accordingly Signed-off-by: Bob Yantosca --- .gitmodules | 2 +- CHANGELOG.md | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/.gitmodules b/.gitmodules index 2f62d27d..4527043d 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,3 +1,3 @@ -[submodule "docs/source/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 diff --git a/CHANGELOG.md b/CHANGELOG.md index 2eb7505c..cc15bcb2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] - TBD ### Changed - Now allow up to 10 nested brackets (`((( )))`) in the `HEMCO_Config.rc` file +- Now use short submodule names (i.e. w/o path) in `.gitmodules` ### Fixed - Limit volcano climatology file read message to root core From 2a4bb1261153842715854ca7a0df1672c10385ee Mon Sep 17 00:00:00 2001 From: nicholasbalasus Date: Thu, 21 Mar 2024 13:59:04 -0400 Subject: [PATCH 10/11] Merge PR #268 (Handle 3D NEI emissions) This merge brings PR 268 (Handle 3D NEI emissions, by @nicholasbalasus) into the HEMCO "no-diff-to-benchmark" development stream. This PR implements a workaround to an issue caused by the merge of HEMCO PR #235 (Bug fix for vertical regridding). This must be merged simultaneously with GEOS-Chem PR #2213. Signed-off-by: Bob Yantosca --- CHANGELOG.md | 1 + src/Core/hco_interp_mod.F90 | 73 ++++++++++++++++++++++++++----------- 2 files changed, 53 insertions(+), 21 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index cc15bcb2..5649b356 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -12,6 +12,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Fixed - Limit volcano climatology file read message to root core +- Updated `hco_interp_mod.F90` to handle 3D NEI emissions. ## [3.8.0] - 2024-02-07 ### Changed diff --git a/src/Core/hco_interp_mod.F90 b/src/Core/hco_interp_mod.F90 index 60c3d9bf..c214dfda 100644 --- a/src/Core/hco_interp_mod.F90 +++ b/src/Core/hco_interp_mod.F90 @@ -500,17 +500,17 @@ SUBROUTINE ModelLev_Check( HcoState, nLev, IsModelLev, RC ) IF ( nlev == nz .OR. nlev == nz + 1 ) THEN IsModelLev = .TRUE. - ! If input is 72 layer (or 36 layer) and output is 47 layer + ! If input is 72 layer (or 3/11/36 layer) and output is 47 layer ELSEIF ( nz == 47 ) THEN - IsModelLev = ( nlev == 72 .OR. nlev == 73 .OR. nlev == 36) + IsModelLev = ( nlev == 72 .OR. nlev == 73 .OR. nlev == 36 .OR. nlev == 3 .OR. nlev == 11) ! If input is 102 layer and output is 74 layer ELSEIF ( nz == 74 ) THEN IsModelLev = ( nlev == 102 .OR. nlev == 103 ) - ! If input is 47 layer (or 36 layer) and output is 72 layer + ! If input is 47 layer (or 3/11/36 layer) and output is 72 layer ELSEIF ( nz == 72 ) THEN - IsModelLev = ( nlev == 47 .OR. nlev == 48 .OR. nlev == 36) + IsModelLev = ( nlev == 47 .OR. nlev == 48 .OR. nlev == 36 .OR. nlev == 3 .OR. nlev == 11) ELSE IsModelLev = .FALSE. @@ -543,10 +543,11 @@ END SUBROUTINE ModelLev_Check ! levels, this is interpreted as native data and will be collapsed onto the ! reduced GISS grid. If the input holds 47/48 input levels, this is interpreted ! as reduced GEOS-5 data and it will be inflated to the native GEOS-5 grid -! (with a warning, as this is not recommended). If the input holds 36 input levels, -! this is assumed to be the first 36 levels of the GEOS-5 grid, meaning they will be -! written as levels 1-36 of a 47 or 72 level output grid (with the remaining values -! left to be zero) (nbalasus, 8/29/2023). +! (with a warning, as this is not recommended). If the input holds N input levels, +! (where N = 3, 11, or 36 to account for NEI and AEIC emissions), this is assumed +! to be the first N levels of the GEOS-5 grid, meaning they will be written as +! levels 1-N of a 47 or 72 level output grid (with the remaining values left to +! be zero) (nbalasus, 8/29/2023). ! ! ! Currently, this routine can remap the following combinations: @@ -554,7 +555,7 @@ END SUBROUTINE ModelLev_Check ! * Native GEOS-5 onto reduced GEOS-5 (72 --> 47 levels, 73 --> 48 edges) ! * Native GISS onto reduced GISS (102 --> 74 levels, 103 --> 75 edges) ! * Reduced GEOS-5 onto native GEOS-5 (47 --> 72 levels, 48 --> 73 edges) -! * 36 levels onto native/reduced GEOS-5 (36 --> levels 1-36 levels of 47/72 level grid, rest are 0) +! * N (N = 3/11/36) levels onto native/reduced GEOS-5 (N --> levels 1-N levels of 47/72 level grid, rest are 0) ! ! !INTERFACE: ! @@ -638,8 +639,8 @@ SUBROUTINE ModelLev_Interpolate( HcoState, REGR_4D, Lct, RC ) IF ( ( ( nlev == nz ) .OR. ( nlev == nz+1 ) ) .OR. & ! write data without doing anything ( ( nz == 47 ) .AND. ( ( nlev == 72 ) .OR. ( nlev == 73 ) ) ) .OR. & ! collapse native to reduced GEOS-5 ( ( nz == 74 ) .AND. ( ( nlev == 102 ) .OR. ( nlev == 103 ) ) ) .OR. & ! collapse native to reduced GISS - ( ( nz == 72 ) .AND. ( ( nlev == 47 ) .OR. ( nlev == 48 ) ) ) .OR. & ! inflate reduced to native GEOS-5 - ( ( ( nz == 72 ) .OR. ( nz == 47 ) ) .AND. ( nlev == 36 ) ) ) THEN ! write 36 levels to reduced/native GEOS-5 + ( ( nz == 72 ) .AND. ( ( nlev == 47 ) .OR. ( nlev == 48 ) ) ) .OR. & ! inflate reduced to native GEOS-5 + ( ( ( nz == 72 ) .OR. ( nz == 47 ) ) .AND. ( ( nlev == 3 ) .OR. ( nlev == 11 ) .OR. ( nlev == 36 ) ) ) ) THEN ! write 3/11/36 levels to reduced/native GEOS-5 ! do nothing ELSE WRITE(MSG,*) 'ModelLev_Interpolate was called but MESSy should have been used: ',TRIM(Lct%Dct%cName) @@ -694,15 +695,21 @@ SUBROUTINE ModelLev_Interpolate( HcoState, REGR_4D, Lct, RC ) ELSEIF ( nlev == 73 ) THEN NL = 37 nout = 48 + ELSEIF ( nlev == 3 ) THEN + NL = 3 + nout = 47 + ELSEIF ( nlev == 11 ) THEN + NL = 11 + nout = 47 ELSEIF ( nlev == 36 ) THEN NL = 36 nout = 47 ELSE MSG = 'Can only remap from native onto reduced GEOS-5 if '// & - 'input data has exactly 72, 73, or 36 levels: '//TRIM(Lct%Dct%cName) + 'input data has exactly 72, 73, 3, 11, or 36 levels: '//TRIM(Lct%Dct%cName) CALL HCO_ERROR( MSG, RC ) RETURN - ENDIF ! nlev == (72,73,36,ELSE) + ENDIF ! nlev == (72,73,3,11,36ELSE) ! Make sure output array is allocated CALL FileData_ArrCheck( HcoState%Config, Lct%Dct%Dta, nx, ny, nout, nt, RC ) @@ -743,7 +750,15 @@ SUBROUTINE ModelLev_Interpolate( HcoState, REGR_4D, Lct, RC ) Lct%Dct%Dta%V3(T)%Val(:,:,46) = REGR_4D(:,:,65,T) Lct%Dct%Dta%V3(T)%Val(:,:,47) = REGR_4D(:,:,69,T) Lct%Dct%Dta%V3(T)%Val(:,:,48) = REGR_4D(:,:,73,T) - ! If the input is 36 levels, levels 37-47 are set to 0 + ! If the input is N (N = 3/11/36) levels, levels N+1 to 47 are set to 0 + ELSEIF ( nlev == 3 ) THEN + DO L = 4,47 + Lct%Dct%Dta%V3(T)%Val(:,:,L) = 0.0_hp + ENDDO !L + ELSEIF ( nlev == 11 ) THEN + DO L = 12,47 + Lct%Dct%Dta%V3(T)%Val(:,:,L) = 0.0_hp + ENDDO !L ELSEIF ( nlev == 36 ) THEN DO L = 37,47 Lct%Dct%Dta%V3(T)%Val(:,:,L) = 0.0_hp @@ -756,8 +771,8 @@ SUBROUTINE ModelLev_Interpolate( HcoState, REGR_4D, Lct, RC ) IF ( HCO_IsVerb( HcoState%Config%Err ) ) THEN WRITE(MSG,*) 'Mapped ', nlev, ' levels onto reduced GEOS-5 levels.' CALL HCO_MSG(HcoState%Config%Err,MSG) - IF ( nlev == 36 ) THEN - WRITE(MSG,*) 'The input variable has 36 L, which were written to be L 1-36 on the output 47 L grid (remaining values set to 0).' + IF ( nlev == 3 .OR. nlev == 11 .OR. nlev == 36 ) THEN + WRITE(MSG,*) 'The input variable has ', nlev, 'L, which were written to be L 1-', nlev, ' on the output 47 L grid (remaining values set to 0).' ELSE WRITE(MSG,*) 'Pressure-weighted vertical regridding was done - consider if this is appropriate for the variable units.' CALL HCO_MSG(HcoState%Config%Err,MSG) @@ -857,15 +872,21 @@ SUBROUTINE ModelLev_Interpolate( HcoState, REGR_4D, Lct, RC ) ELSEIF ( nlev == 48 ) THEN NL = 37 nout = 73 + ELSEIF ( nlev == 3 ) THEN + NL = 3 + nout = 72 + ELSEIF ( nlev == 11 ) THEN + NL = 11 + nout = 72 ELSEIF ( nlev == 36 ) THEN NL = 36 nout = 72 ELSE MSG = 'Can only remap from reduced onto native GEOS-5 if '// & - 'input data has exactly 47, 48, or 36 levels: '//TRIM(Lct%Dct%cName) + 'input data has exactly 47, 48, 3, 11, or 36 levels: '//TRIM(Lct%Dct%cName) CALL HCO_ERROR( MSG, RC ) RETURN - ENDIF ! nlev == (48,48,36,ELSE) + ENDIF ! nlev == (48,48,3,11,36,ELSE) ! Make sure output array is allocated CALL FileData_ArrCheck( HcoState%Config, Lct%Dct%Dta, nx, ny, nout, nt, RC ) @@ -924,20 +945,30 @@ SUBROUTINE ModelLev_Interpolate( HcoState, REGR_4D, Lct, RC ) Lct%Dct%Dta%V3(T)%Val(:,:,fineIDX) = REGR_4D(:,:,coarseIDX,T) ENDDO ! I + ELSEIF ( nlev == 3 ) THEN + DO L = 4,72 + Lct%Dct%Dta%V3(T)%Val(:,:,L) = 0.0_hp + ENDDO !L + + ELSEIF ( nlev == 11 ) THEN + DO L = 12,72 + Lct%Dct%Dta%V3(T)%Val(:,:,L) = 0.0_hp + ENDDO !L + ELSEIF ( nlev == 36 ) THEN DO L = 37,72 Lct%Dct%Dta%V3(T)%Val(:,:,L) = 0.0_hp ENDDO !L - ENDIF ! nlev == (47,48,36) + ENDIF ! nlev == (47,48,3,11,36) ENDDO ! T ! Verbose IF ( HCO_IsVerb(HcoState%Config%Err ) ) THEN WRITE(MSG,*) 'Mapped ', nlev, ' levels onto native GEOS-5 levels.' CALL HCO_MSG(HcoState%Config%Err,MSG) - IF ( nlev == 36 ) THEN - WRITE(MSG,*) 'The input variable has 36 L, which were written to be L 1-36 on the output 72 L grid (remaining values set to 0).' + IF ( nlev == 3 .OR. nlev == 11 .OR. nlev == 36 ) THEN + WRITE(MSG,*) 'The input variable has ', nlev, 'L, which were written to be L 1-', nlev, ' on the output 72 L grid (remaining values set to 0).' ELSE WRITE(MSG,*) 'Inflating from 47/48 to 72/73 levels is not recommended and is likely not mass-conserving.' ENDIF From fddcae53f73327e0da7f0a505b4d07a53dd0930b Mon Sep 17 00:00:00 2001 From: Melissa Sulprizio Date: Tue, 2 Apr 2024 11:42:34 -0400 Subject: [PATCH 11/11] Update version to 3.8.1 for release Signed-off-by: Melissa Sulprizio --- CHANGELOG.md | 2 +- CMakeLists.txt | 2 +- docs/source/conf.py | 2 +- src/Core/hco_error_mod.F90 | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 5649b356..3d732a14 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,7 +5,7 @@ All notable changes to this project will be documented in this file. 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 +## [3.8.1] - 2024-04-02 ### Changed - Now allow up to 10 nested brackets (`((( )))`) in the `HEMCO_Config.rc` file - Now use short submodule names (i.e. w/o path) in `.gitmodules` diff --git a/CMakeLists.txt b/CMakeLists.txt index 99ff499b..47f44e7a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,7 +1,7 @@ # HEMCO/CMakeLists.txt cmake_minimum_required(VERSION 3.5) -project(HEMCO VERSION 3.8.0 LANGUAGES Fortran) +project(HEMCO VERSION 3.8.1 LANGUAGES Fortran) # Reminder: Make sure to also update version in src/Core/hco_error_mod.F90 #----------------------------------------------------------------------------- diff --git a/docs/source/conf.py b/docs/source/conf.py index a0ed8f58..d4d9ab70 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -23,7 +23,7 @@ author = 'GEOS-Chem Support Team' # The full version, including alpha/beta/rc tags -release = '3.8.0' +release = '3.8.1' # -- General configuration --------------------------------------------------- diff --git a/src/Core/hco_error_mod.F90 b/src/Core/hco_error_mod.F90 index 291905b4..59830d4c 100644 --- a/src/Core/hco_error_mod.F90 +++ b/src/Core/hco_error_mod.F90 @@ -105,7 +105,7 @@ MODULE HCO_Error_Mod #endif ! HEMCO version number. - CHARACTER(LEN=12), PARAMETER, PUBLIC :: HCO_VERSION = '3.8.0' + CHARACTER(LEN=12), PARAMETER, PUBLIC :: HCO_VERSION = '3.8.1' INTERFACE HCO_Error MODULE PROCEDURE HCO_ErrorNoErr