Fesom2.7 recom3.1#864
Conversation
This commit includes bugfixes, new diagnostics variables for grazing and code pieces to track BGC tracer budget.
Add recom initialzation and sbc files for recom. Standard setup for recom is enable_3zoo2det = .true. and enable_coccos = .false. (namelist.recom)
Build REcoM CI test. Add push trigger and improve debugging.
- namelist.recom and namelist.tra required by REcoM (not auto-generated) - Updated file paths to use local copies in work directory - Set REcoM_restart=false for initialization from climatology - Workflow copies these template files to work_recom/
Added mslp (mean sea level pressure) forcing configuration to enable CO2 flux calculations in REcoM. Without atmospheric pressure, the CO2 flux calculation fails with NaN values. Changes: - Added namelist.forcing section with l_mslp=True - Configured to read from 'slp.' files with 'slp' variable - Copy PHC2_salx.nc and runoff.nc to work directory in CI
…orcing The default namelist.forcing.CORE2 already has mslp (atmospheric pressure) configured but disabled (l_mslp=.false.). Patch it to l_mslp=.true. in the workflow to enable reading of slp.*.nc files. This is needed for REcoM CO2 flux calculations which require atmospheric pressure (Patm). Removed unnecessary namelist.forcing section from setup.yml since we just patch the default config file directly.
Namelist for REcoM3.1 are updated (for albedo)
Grazing diagnostics results in segmentation faulf in 2p1z1d setup. Macrozooplankton allocation and initialization is revisited. Deallocation was not an issue.
ESM tools cause problems in coupled model run If double precision sign is in the namelist.recom. d0 is removed.
Tracer fields have different numbers depending on configuration. Output routine is now aware of which configuration we use. 1. **Tracer ID 1001-1022 Base tracers** always present in all configuration: 1. **Tracer ID 1023-1028 have different meanings** depending on configuration: - In **COCCOS-ONLY**: 1023-1025 are Coccos (N,C,Chl), 1026-1028 are Phaeo (N,C,Chl) - In **3ZOO2DET configs**: 1023-1024 are Zoo2 (N,C), 1025-1028 are Det2 pool - In **BASE with rivers**: 1023 is DOCt 2. **Tracer ID 1029-1031** vary by configuration: - In **FULL model**: Coccos (N,C,Chl) - In **3ZOO2DET-ONLY**: 1029-1030 are Microzoo (N,C) - In **COCCOS-ONLY with rivers**: 1029 is DOCt 3. **Tracer ID 1032-1036** only exist in **FULL model**: - 1032-1034: Phaeocystis (N,C,Chl) - 1035-1036: Microzooplankton (N,C) 4. **Tracer ID 1037** only in **FULL model with rivers**: DOCt 5. **Added comprehensive comments** explaining which configuration uses which tracer IDs to prevent confusion.
Terrestrial DOC input is added as a new tracer. Input variables are read from a Netcdf file using a new subroutine as standard FESOM routines do not help in this case.
Update namelist.config file for various recom setups.
REcoM runs with more than 35 tracer fields. Therefore, we increase maximum number of allowed restart files.
DIC budget calculations are updated. We have now the correct split. Budget closes. It is extended to the variables of DIN, All and DSi. Photosynthesis, respiration, N assimilation and remineralization diagnostics are added.
…ication and permanent burial of organic matter in marine sediments. Update recom output variables. - Denitrification: Uses Middelburg et al. (1996) parameterization to calculate nitrogen removal as a function of organic carbon flux - Permanent Burial: Uses Dunne et al. (2007) formulation to calculate burial efficiency and permanent removal of C, N, Si, and CaCO3 - Calcite Dissolution: Accounts for calcite preservation based on carbonate saturation state (Omega_calcite) - Update output streams for the REcoM tracer variables (mocsy 3D outputs, missing ballasting outputs and burial)
We hhave either 2p or 4p cases. 3p setup is not needed anymore.
|
I am not allowed to add the following yml file. .github/workflows/fesom2_recom.yml name: "FESOM2: REcoM Biogeochemistry" Controls when the action will run. Triggers the workflow on pull request only.on: A workflow run is made up of one or more jobs that can run sequentially or in paralleljobs: |
|
Hey @ogurses, & @patrickscholz. I suggest we first merge #863, then #802. Then we update this branch and merge here. |
FESOM reads AWICM forcing
…ize_tracer_indices subroutine to adjust tracer ids in vertical sinking routine relative to model complexity. Sinking information is printed out.
Re-established some albedo IO-optimizations from #400
Zooplankton group comments were mixed up (correct order is: zoo1: meso, zoo2: macro, zoo3: micro)
|
@copilot resolve the merge conflicts in this pull request |
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Co-authored-by: suvarchal <15322959+suvarchal@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Co-authored-by: suvarchal <15322959+suvarchal@users.noreply.github.com>
Agent-Logs-Url: https://github.com/FESOM/fesom2/sessions/2a8b35da-57ab-4723-a640-60e2f8cbf8cc Co-authored-by: suvarchal <15322959+suvarchal@users.noreply.github.com>
... Added the workflow file at
Merge conflicts with |
I have the following problem now /albedo/home/ogurses/test_case/trunk/src/io_meandata.F90(4368): error #6457: This derived type name has not been declared. [MEANDATA0D] Some module is missing @suvarchal @JanStreffing |
The Copilot merge resolution of origin/main into fesom2.7-recom3.1 kept the 0D writer subroutines (output_0D_streams, create_0D_file) but dropped four companion pieces that they depend on: - use io_xios_module, only: io_xios_is_on, ... (module head import block) - def_stream0D in the public list - type Meandata0D (the 0D stream record) - io_stream0D(50) and io_NSTREAMS0D module-level storage - subroutine def_stream0D (the registrar) Restored verbatim from main so the writers compile against their type again. No behavioural change beyond restoring main-side 0D scalar output.
…to g_config gen_surface_forcing.F90 references the switch unconditionally at two sites (SBC filename pattern in nc_sbc_ini_fillnames; daily-update flag in sbc_do), but the declaration lived in recom_config, which is only compiled when __recom is defined. The non-recom builds (fesom2_main, fesom2_icepack, fesom2_openmp, ...) therefore failed to compile with 'Symbol enable_AWICM has no IMPLICIT type'. Wrapping every reference in #if defined (__recom) would clutter the SBC code. Instead the declaration is moved into g_config (always compiled, default .false.) and recom_config picks it up via use-association so the &parecomsetup namelist binding still works in recom builds. The two gen_surface_forcing.F90 reference sites then need no preprocessor guard. Also renamed because the switch lives in a recom_config namelist and governs recom <-> atmosphere coupling behaviour (filename pattern of forcing produced by a coupled atmosphere model, daily SSS/runoff refresh). It is unrelated to AWICM, which is a FESOM+ECHAM ESM without REcoM. Default left at .false. so standard yearly-file forcing remains the out-of-the-box behaviour. update_daily_flag is now initialised to .false. so the consumer site (runoff_data_source=='AWICM') is safe when recom_coupled_to_atmosphere is off. Namelist defaults in config/bin_*/ updated to the new key.
|
788d0a3 — restored the 0D scalar-stream infrastructure that the Copilot merge resolution had dropped from src/io_meandata.F90. The merge kept the writer subroutines (output_0D_streams, create_0D_file) but removed (i) the use io_xios_module, only: io_xios_is_on, ... import block, (ii) def_stream0D in the public :: list, (iii) type Meandata0D ... end type Meandata0D, (iv) the module-level storage type(Meandata0D), save, target :: io_stream0D(50) and integer, save :: io_NSTREAMS0D = 0, and (v) the registrar subroutine def_stream0D(...). All five were restored verbatim from main, so the six errors you saw on MEANDATA0D / IO_XIOS_IS_ON / IO_NSTREAMS0D / ENTRY0D are resolved. c2b4213 — renames enable_AWICM to recom_coupled_to_atmosphere and moves the declaration from recom_config into g_config. recom_config picks it up via use g_config, only: recom_coupled_to_atmosphere, so the &parecomsetup namelist binding in namelist.recom still works in recom builds, and gen_surface_forcing.F90 no longer needs preprocessor guards around its two reference sites. This fixes the 'Symbol enable_AWICM has no IMPLICIT type' errors on the non-recom CI jobs (fesom2_main, fesom2_icepack, fesom2_openmp, ...). Rename motivation: in our group we typically use "AWICM" for the AOGCM-only coupled setup (FESOM + ECHAM, without biogeochemistry). The switch in &parecomsetup is only read when REcoM is active and controls SBC behaviour when REcoM is forced by a coupled atmosphere model, which is the ESM regime (AWESM3 / AWI-ESM), not the AOGCM regime, so the old name was a bit misleading. Semantics are unchanged and the default is .false., so existing setups continue to work; update_daily_flag is now initialised to .false. so the runoff_data_source=='AWICM' consumer is safe when the switch is off. Namelist defaults in config/bin_2p1z1d/, bin_2p3z2d/, bin_4p3z2d/ updated to the new key. |
…op trailing-comment #endif warnings in oce_ale_tracer.F90
Update REcoM in FESOM2.7