Changes between Version 139 and Version 140 of Documentation/TrunkFunctionality4


Ignore:
Timestamp:
2023-05-30T13:32:32+02:00 (11 months ago)
Author:
jgipsl
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • Documentation/TrunkFunctionality4

    v139 v140  
    155155 
    156156=== Configurations === 
     157The model ORCHIDEE can run in offline mode. Different predefined experiment set ups can be found in folder ORCHIDEE_OL, see section [wiki:Documentation/TrunkFunctionality4#Experiments Experiments] further below. 
     158 
     159The model can also be coupled to an atomspheric model and be run in coupled mode. For example in the coupled model IPSL-CM, ORCHIDEE is coupled to the atmospheric model LMDZ and the ocean model NEMO.  
     160=== Consistency checks === 
     161Describes r6947. The code distinguishes between three options to check for mass and surface conservation. These options are controlled by the parameter '''err_act'''. Always use err_act = 3 when developing and testing the code. Note that in addition to checking for mass balance closure ORCHIDEE trunk will also check for the conservation of veget_max and frac_nobio. This is useful to make sure no surface area is lost when moving biomass from one PFT to another following natural disturbances, forest management, land cover changes and when using age classes. In some parts of the code, for example, modules that deal with disturbances, it is assumed that the tallest trees are stored in the last diameter class. When the difference in diameter between diameter classes becomes very small, this assumption could be violated. Therefore, the diameter classes are sorted to enforce the assumed order and where needed the order is checked. 
     162* err_act = 1 is recommended when running global long-term simulations. Under this option, mass balance closure is checked for all biogeochemical processes but only at the highest level thus stomate.f90 and stomate_lpj.f90. Although the mass balance checks are not very expensive in terms of computer time, skipping the numerous lower level checks is expected to save some time. Under this option the total mass balance error is only written to the history file. No information is provided in which subroutine the problem occurred. 
     163* err_act = 2 is recommended when developing and testing the model. Now the mass balance is explicitly checked in stomate.f90, stomate_lpj.f90 and all its subroutines. Under this option the mass balance error is written to the history file and if the mass balance is not closed, the warning message will indicate in which subroutine the problem likely originated. 
     164* arr_act = 3 is recommended when having a problem with mass balance closure. The mass balance is explicitly checked in stomate.f90, stomate_lpj.f90 and all its subroutines. If a mass balance error occurs, the model is stopped. It is expected that within the time step of the subroutine a precision of 1e-8 is achieved. If not the model will crash. Additionally consistency between flux-based and pool-based NBP is checked. This check represent an integrated check which give confidence for the technical implementation of the C and N cycles. Comparing the flux and pool based nbp estimates is an instantaneous check that covers just a single day in the model (thus 48 time steps for the soil and litter calcuations which are called from stomate.f90). The cross-consistency check for the flux and pool based NBP requires mass balance closure and area preservation from all all subroutines being called from stomate.f90 including stomate_lpj.f90. This check should always be satisfied, if not there is a bug somewhere! The mass balance of individual subroutines teaches us about the calculations performed within that subroutine. The flux and pool based NBP consistency check teaches us of how these fluxes and pools should be accounted for, passing this check requires additional understanding of the flow of the code (i.e., bm_to_litter) and how the different time steps come together. 
     165 
     166As an additional consistency check the time integral of the NBP (from 0 -> t) should equal the C and N stock at time step t. Comparing the time integral of NEP vs the all pools includes all the accumulated precision errors. If those errors would be random there would be no problem but they are more likely biases. Hence, when the fluxes and pools increase several order of magnitudes (e.g toward 1e4) and a small bias (1e-12) is integrated over 10,000 days (1e4) the divergence between the time integral of NEP and the pools will approach/exceed 1-8 and woukd stop the model. This is a fundamental problem related to machine precision and the way we do the calculations (think of the so called catastrophic rounding errors that may occur with floating numbers). For this reason this check is written to the history files but does not make the model crash. The user will have to decide whether (s)he is facing a precision error or a real bug. Fixing precision errors will require to improve the precision of the calculations in one or several subroutines. 
     167 
     168The variable MBC_NBP3_c was added to enable monitoring whether the NBP send to LMDZ in intersurf.f90 is identical to the NBP calculated in stomate_lpj.f90. If ERR_ACT=3 is used, the model will crash if the NBP send in intersurf differs from the NBP calculated in stomate_lpj.f90. Irrespective of the value of ERR_ACT, the mismatch between both NBPs will be send to MBC_NBP3_c. 
     169 
     170 
     171=== Croplands === 
     172Describes r7767. Makes use of sapiens_planting and sapiens_harvest. Planting and harvest is determined by temperature and soil moisture using the moigdd phenology type. At senescence, 50% of the aboveground biomass is placed into the harvest_pool (just like wood) and its decomposition is accounted for in the fluxes from the product use pool. The remaining 50% of aboveground biomass enters the litter pool, along with all of the roots.  
     173 
     174 
     175=== CWRR vs Choinel === 
     176Describes r6614. Following ORCHIDEE trunk 3, the Choinel code is no longer available in ORCHIDEE trunk. The hydrological schemes were not touched during the development of ORCHIDEE trunk. The hydraulic architecture in ORCHIDEE trunk relies on CWRR. 
     177 
     178 
     179=== Diameter classes === 
     180Describes r6614. Diameter classes were introduced to better simulate the canopy structure, they are a tool to simulate heterogeneity within a single PFT. Given that the canopy is the interface between the land and the atmosphere this feature has effects well beyond forest management. Stand structure was observed to affect albedo, transpiration, photosynthesis, soil temperature, roughness length, and recruitment. Using diameter classes adds very little complexity to setting-up the simulations as well as to the output files. The complexity is mostly within the code.  
     181 
     182The computational cost of using diameter classes is negligible and when a reasonable low number of diameter classes is used, the memory cost remains very small as the dimensions of only two variables are increased. The number of diameter classes is the same for all PFTs and is set by the parameter '''NCIRC'''. ORCHIDEE-CN, and ORCHIDEE-CNP are coded and used for NCIRC = 1. ORCHIDEE trunk was coded and tested for NCIRC = 3. Until further testing, three diameter classes are considered sufficient although for some specific application, i.e., simulating tree ring width NCIRC = 5 resulted in slightly better model performance. The branch ORCHIDEE-CN-CAN that preceded this trunk version has been run with one diameter class as well (this should be confirmed for ORCHIDEE trunk).  
     183 
     184Given earlier choices in the ORCHIDEE model, we either need to define the boundaries of each diameter class or the diameter distribution. While developing the code, we considered the second approach the most flexible. To allow maximal flexibility, each diameter class needs to be defined separately by the variable '''CIRC_CLASS_DIST_0000X''', where X is the number of the diameter class. The smallest number presents the smallest diameter class. From literature it is known that a truncated exponential distribution is a good first guess: 
     185{{{  
     186CIRC_CLASS_DIST_00001=9 
     187CIRC_CLASS_DIST_00002=5 
     188CIRC_CLASS_DIST_00003=1  
     189}}} 
     190The above declaration implies that 9/15th of the trees will always be in the smallest diameter class, 5/15th will be in the medium class and 1 tree out of 15 will be in the largest diameter class. These ratios are kept throughout the simulations and the boundaries of the diameter classes are adjusted to respect this constraint. Consequently, an even-aged stand will be simulated with three diameter classes where the diameter of the first class may be, for example, 20.3 cm, the diameter of the second class 20.4 cm and the diameter of the third class 20.5 cm. The same code and set-up allows to simulate, in the same simulation, an uneven-aged stand for the same PFT but in a different pixel with, for example, the smallest diameter 7 cm, the medium diameter 25 cm and the largest diameter 45 cm. 
     191 
     192=== Experiments === 
    157193Describes r7671. The model comes with the following well-tested configurations (config/ORCHIDEE_OL). Well-tested means that these configuration have been tested on different servers and some are part of the trusting:  
    158 * SPINUP: used for single pixel FLUXNET runs. 
    159 * ENSEMBLE: used for single pixel FLUXNET runs ([wiki:Documentation/UserGuide/FLUXNETValidation more details]). 
    160194* SPINUP_ANALYTIC_FG1(nd): 2x2 degrees CRU-JRA forcing cycles over 1901-1910 between 1901 and 2240 ([https://forge.ipsl.jussieu.fr/orchidee/wiki/Documentation/Forcings about the forcing]). Start from scratch. 15 PFTs, no land cover changes, nitrogen input for 1850, 1860 or 1900 depending on the species, and fixed CO2 concentrations ([https://forge.ipsl.jussieu.fr/orchidee/wiki/Documentation/UserGuide/SpinUpCarbon details and context]).  
    161195* OOL_SEC_STO_FG1trans(nd): 2x2 degrees CRU-JRA forcing cycles over 1901-1910 between 1861 and 1900 ([https://forge.ipsl.jussieu.fr/orchidee/wiki/Documentation/Forcings about the forcing]). Restart from SPINUP_ANALYTIC_FG1. 15 PFTs, no land cover changes, nitrogen input for 1900, and annual CO2 concentrations. 
     
    166200* OOL_SEC: 2x2 degrees annual CRU-JRA forcing between 1901 and 2010 ([https://forge.ipsl.jussieu.fr/orchidee/wiki/Documentation/Forcings about the forcing]). Start from scratch. 15 PFTs prescribed by reading in a biomass map. Land cover changes, input deposition, CO2 concentrations, and all other biogeochemical and ecological processes are deactivated. This configuration is under development, waiting for a global LAI map (in case of CN-CAN this has become biomass map) to be tested. 
    167201 
    168  
    169 Configurations that are no longer used: 
     202Experiments that are used but only on specific machines: 
     203* SPINUP: used for single pixel FLUXNET runs. 
     204* ENSEMBLE: used for single pixel FLUXNET runs ([wiki:Documentation/UserGuide/FLUXNETValidation more details]). 
     205 
     206Experiments that are no longer used: 
    170207* FORCESOIL: was restored for ORCHIDEE trunk 3 but was not maintained for ORCHIDEE trunk (see ticket #684). 
    171208* SPINUP_ANALYTIC_FG0(nd): removed in r7671 because better results were obtained by using recruitment for unmanaged forests in the spinup ([https://docs.google.com/document/d/1mw3XIL5X3xVLxtcfzGGNVXKz2T__STZKMggxZvTMU80/edit Read more about the new challenge to spinup a model with stand structure and abrupt mortality.]). SPINUP_ANALYTIC_FG0(nd): 2x2 degrees CRU-JRA forcing cycles over 1901-1910 between 1801 and 1900. Start from scratch. 15 PFTs, no land cover changes, nitrogen input for 1850, 1860 or 1900 depending on the species, and fixed CO2 concentrations. During this pre-spinup each forested PFT is clear cut once. This makes the age structure more heterogeneous. Clear cutting is prescribed according to a map such that the process is reproducible. When FG0 was used, the final files of FG0 were to be used as restart files for FG1.   
     
    173210* OOL_SEC_STO_FG5 (can be found in svn before tag 4.1 or r7686): 1x1 degrees annual IPSL RCP 4.5 forcing between 1911 and 2100. Start from OOL_SEC_STO_FG4. 64 PFTs, no land cover and changes, annual input deposition, annual CO2 concentrations, prescribed species and management changes following annual a stand replacing disturbance, litter raking for 2010. 
    174211 
    175  
    176 === Consistency checks === 
    177 Describes r6947. The code distinguishes between three options to check for mass and surface conservation. These options are controlled by the parameter '''err_act'''. Always use err_act = 3 when developing and testing the code. Note that in addition to checking for mass balance closure ORCHIDEE trunk will also check for the conservation of veget_max and frac_nobio. This is useful to make sure no surface area is lost when moving biomass from one PFT to another following natural disturbances, forest management, land cover changes and when using age classes. In some parts of the code, for example, modules that deal with disturbances, it is assumed that the tallest trees are stored in the last diameter class. When the difference in diameter between diameter classes becomes very small, this assumption could be violated. Therefore, the diameter classes are sorted to enforce the assumed order and where needed the order is checked. 
    178 * err_act = 1 is recommended when running global long-term simulations. Under this option, mass balance closure is checked for all biogeochemical processes but only at the highest level thus stomate.f90 and stomate_lpj.f90. Although the mass balance checks are not very expensive in terms of computer time, skipping the numerous lower level checks is expected to save some time. Under this option the total mass balance error is only written to the history file. No information is provided in which subroutine the problem occurred. 
    179 * err_act = 2 is recommended when developing and testing the model. Now the mass balance is explicitly checked in stomate.f90, stomate_lpj.f90 and all its subroutines. Under this option the mass balance error is written to the history file and if the mass balance is not closed, the warning message will indicate in which subroutine the problem likely originated. 
    180 * arr_act = 3 is recommended when having a problem with mass balance closure. The mass balance is explicitly checked in stomate.f90, stomate_lpj.f90 and all its subroutines. If a mass balance error occurs, the model is stopped. It is expected that within the time step of the subroutine a precision of 1e-8 is achieved. If not the model will crash. Additionally consistency between flux-based and pool-based NBP is checked. This check represent an integrated check which give confidence for the technical implementation of the C and N cycles. Comparing the flux and pool based nbp estimates is an instantaneous check that covers just a single day in the model (thus 48 time steps for the soil and litter calcuations which are called from stomate.f90). The cross-consistency check for the flux and pool based NBP requires mass balance closure and area preservation from all all subroutines being called from stomate.f90 including stomate_lpj.f90. This check should always be satisfied, if not there is a bug somewhere! The mass balance of individual subroutines teaches us about the calculations performed within that subroutine. The flux and pool based NBP consistency check teaches us of how these fluxes and pools should be accounted for, passing this check requires additional understanding of the flow of the code (i.e., bm_to_litter) and how the different time steps come together. 
    181  
    182 As an additional consistency check the time integral of the NBP (from 0 -> t) should equal the C and N stock at time step t. Comparing the time integral of NEP vs the all pools includes all the accumulated precision errors. If those errors would be random there would be no problem but they are more likely biases. Hence, when the fluxes and pools increase several order of magnitudes (e.g toward 1e4) and a small bias (1e-12) is integrated over 10,000 days (1e4) the divergence between the time integral of NEP and the pools will approach/exceed 1-8 and woukd stop the model. This is a fundamental problem related to machine precision and the way we do the calculations (think of the so called catastrophic rounding errors that may occur with floating numbers). For this reason this check is written to the history files but does not make the model crash. The user will have to decide whether (s)he is facing a precision error or a real bug. Fixing precision errors will require to improve the precision of the calculations in one or several subroutines. 
    183  
    184 The variable MBC_NBP3_c was added to enable monitoring whether the NBP send to LMDZ in intersurf.f90 is identical to the NBP calculated in stomate_lpj.f90. If ERR_ACT=3 is used, the model will crash if the NBP send in intersurf differs from the NBP calculated in stomate_lpj.f90. Irrespective of the value of ERR_ACT, the mismatch between both NBPs will be send to MBC_NBP3_c. 
    185  
    186  
    187 === Croplands === 
    188 Describes r7767. Makes use of sapiens_planting and sapiens_harvest. Planting and harvest is determined by temperature and soil moisture using the moigdd phenology type. At senescence, 50% of the aboveground biomass is placed into the harvest_pool (just like wood) and its decomposition is accounted for in the fluxes from the product use pool. The remaining 50% of aboveground biomass enters the litter pool, along with all of the roots.  
    189  
    190  
    191 === CWRR vs Choinel === 
    192 Describes r6614. Following ORCHIDEE trunk 3, the Choinel code is no longer available in ORCHIDEE trunk. The hydrological schemes were not touched during the development of ORCHIDEE trunk. The hydraulic architecture in ORCHIDEE trunk relies on CWRR. 
    193  
    194  
    195 === Diameter classes === 
    196 Describes r6614. Diameter classes were introduced to better simulate the canopy structure, they are a tool to simulate heterogeneity within a single PFT. Given that the canopy is the interface between the land and the atmosphere this feature has effects well beyond forest management. Stand structure was observed to affect albedo, transpiration, photosynthesis, soil temperature, roughness length, and recruitment. Using diameter classes adds very little complexity to setting-up the simulations as well as to the output files. The complexity is mostly within the code.  
    197  
    198 The computational cost of using diameter classes is negligible and when a reasonable low number of diameter classes is used, the memory cost remains very small as the dimensions of only two variables are increased. The number of diameter classes is the same for all PFTs and is set by the parameter '''NCIRC'''. ORCHIDEE-CN, and ORCHIDEE-CNP are coded and used for NCIRC = 1. ORCHIDEE trunk was coded and tested for NCIRC = 3. Until further testing, three diameter classes are considered sufficient although for some specific application, i.e., simulating tree ring width NCIRC = 5 resulted in slightly better model performance. The branch ORCHIDEE-CN-CAN that preceded this trunk version has been run with one diameter class as well (this should be confirmed for ORCHIDEE trunk).  
    199  
    200 Given earlier choices in the ORCHIDEE model, we either need to define the boundaries of each diameter class or the diameter distribution. While developing the code, we considered the second approach the most flexible. To allow maximal flexibility, each diameter class needs to be defined separately by the variable '''CIRC_CLASS_DIST_0000X''', where X is the number of the diameter class. The smallest number presents the smallest diameter class. From literature it is known that a truncated exponential distribution is a good first guess: 
    201 {{{  
    202 CIRC_CLASS_DIST_00001=9 
    203 CIRC_CLASS_DIST_00002=5 
    204 CIRC_CLASS_DIST_00003=1  
    205 }}} 
    206 The above declaration implies that 9/15th of the trees will always be in the smallest diameter class, 5/15th will be in the medium class and 1 tree out of 15 will be in the largest diameter class. These ratios are kept throughout the simulations and the boundaries of the diameter classes are adjusted to respect this constraint. Consequently, an even-aged stand will be simulated with three diameter classes where the diameter of the first class may be, for example, 20.3 cm, the diameter of the second class 20.4 cm and the diameter of the third class 20.5 cm. The same code and set-up allows to simulate, in the same simulation, an uneven-aged stand for the same PFT but in a different pixel with, for example, the smallest diameter 7 cm, the medium diameter 25 cm and the largest diameter 45 cm. 
    207212 
    208213=== Forced clear cut ===