Changes between Initial Version and Version 1 of Tags/196/ExternalisationParameters/TechnicalModifications


Ignore:
Timestamp:
2011-10-10T11:24:11+02:00 (13 years ago)
Author:
nvuilsce
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • Tags/196/ExternalisationParameters/TechnicalModifications

    v1 v1  
     1== Technical modifications == 
     2 
     3 
     4This page summarizes the choices and the modifications done for the externalization of the parameters. 
     5 
     6=== Global Specifications === 
     7 
     8We tried to respect as soon as possible the structure of the code. [[BR]] 
     9 
     10Three folders over five were affected by 
     11the modifications : ''src_parameters'', ''src_sechiba'' and ''src_stomate''. [[BR]] 
     12 
     13We regroup all the 
     14files containing parameters in src_parameters. We rewrite some parts of the code in order not to have explicit 
     15references to indexes to some PFTs (like agricultural ones). [[BR]] 
     16 
     17We delete all the multiple definitions of some parameters like pi or the terrestrial radius R_Earth. 
     18 
     19 
     20Finally, we gave names to some coefficents intervening in equations and externalized them. 
     21 
     22  
     23The main changings are detailed below : 
     24 
     25 
     26=== Src_parameters === 
     27 
     28Originally, this folder was organized in 4 files called '''constantes.f90''', '''constantes_co2.f90''', '''constantes_veg.f90''' and  
     29'''constantes_soil.f90'''.  
     30 
     31The last three files were mixed up with '''stomate_constants.f90''' to give '''pft_parameters.f90''' and '''constantes_mtc.f90'''. These new files make the initialization and the overwriting of the pft-parameters. 
     32 
     33All the default values for the pft-parameters are in '''constantes_mtc.f90'''.  
     34 
     35'''constantes.f90''' contains all the physical constants used by ORCHIDEE  
     36and (for the moment) the rest of the externalized parameters (scalar and no-pfts-sized arrays). 
     37 
     38 
     39=== Src_sechiba === 
     40 
     41We add a new module called '''qsat_moisture.f90'''. This module regroups the routines for the calculation of qsat (previously in '''constantes_veg.f90'''). [[BR]] 
     42'''intersurf.f90''' reads the number of PFTs and the parameters values chosen by the user.  
     43 
     44 
     45=== Src_stomate === 
     46 
     47We delete '''stomate_constants.f90''' in order to move its parameters in ''src_parameters''. The too-specific parameters were moved to '''stomate_data.f90'''. [[BR]] 
     48Due to Fortran language, we have to delete the following structures in ORCHIDEE (previously in '''stomate_constants.f90''': 
     49 
     50{{{ 
     51! type declaration for photosynthesis 
     52  TYPE t_photo_type 
     53    REAL(r_std), DIMENSION(nvm)                  :: t_max_a 
     54    REAL(r_std), DIMENSION(nvm)                  :: t_max_b 
     55    REAL(r_std), DIMENSION(nvm)                  :: t_max_c 
     56    REAL(r_std), DIMENSION(nvm)                  :: t_opt_a 
     57    REAL(r_std), DIMENSION(nvm)                  :: t_opt_b 
     58    REAL(r_std), DIMENSION(nvm)                  :: t_opt_c 
     59    REAL(r_std), DIMENSION(nvm)                  :: t_min_a 
     60    REAL(r_std), DIMENSION(nvm)                  :: t_min_b 
     61    REAL(r_std), DIMENSION(nvm)                  :: t_min_c 
     62  END TYPE t_photo_type 
     63}}} 
     64and  : 
     65 
     66{{{ 
     67! type declaration for phenology 
     68  TYPE pheno_type 
     69    REAL(r_std), DIMENSION(nvm,3)                :: gdd 
     70    REAL(r_std), DIMENSION(nvm)                  :: ngd 
     71    REAL(r_std), DIMENSION(nvm)                  :: ncdgdd_temp 
     72    REAL(r_std), DIMENSION(nvm)                  :: hum_frac 
     73    REAL(r_std), DIMENSION(nvm)                  :: lowgpp_time 
     74    REAL(r_std), DIMENSION(nvm)                  :: leaffall 
     75    REAL(r_std), DIMENSION(nvm)                  :: leafagecrit 
     76    REAL(r_std)                       :: tau_hum_month 
     77    REAL(r_std)                       :: tau_hum_week 
     78    REAL(r_std)                       :: tau_t2m_month 
     79    REAL(r_std)                       :: tau_t2m_week 
     80    REAL(r_std)                       :: tau_tsoil_month 
     81    REAL(r_std)                       :: tau_soilhum_month 
     82    REAL(r_std)                       :: tau_gpp_week 
     83    REAL(r_std)                       :: tau_gdd 
     84    REAL(r_std)                       :: tau_ngd 
     85    REAL(r_std)                       :: tau_longterm 
     86    REAL(r_std), DIMENSION(nvm)                  :: lai_initmin 
     87    CHARACTER(len=6), DIMENSION(nvm)            :: pheno_model 
     88    CHARACTER(len=6), DIMENSION(nvm)            :: senescence_type 
     89    REAL(r_std), DIMENSION(nvm,3)                :: senescence_temp 
     90    REAL(r_std), DIMENSION(nvm)                  :: senescence_hum 
     91    REAL(r_std), DIMENSION(nvm)                  :: nosenescence_hum 
     92    REAL(r_std), DIMENSION(nvm)                  :: max_turnover_time 
     93    REAL(r_std), DIMENSION(nvm)                  :: min_leaf_age_for_senescence 
     94    REAL(r_std), DIMENSION(nvm)                  :: min_turnover_time 
     95!- 
     96    REAL(r_std), DIMENSION(nvm)                  :: hum_min_time 
     97  END TYPE pheno_type 
     98}}} 
     99 
     100We replace the structures by individuals arrays. 
     101 
     102During our validations on fluxnet sites, we modified the herbivory model and the formulation for the variable  
     103"black_carbon". In '''stomate_season.f90''', we replace :  
     104{{{ 
     105    DO j = 2,nvm 
     106       ! 
     107       IF ( natural(j) ) THEN 
     108          ! 
     109          WHERE ( nlflong_nat(:) .GT. zero ) 
     110             consumption(:) = hvc1 * nlflong_nat(:) ** hvc2 
     111             herbivores(:,j) = one_year * green_age(:) * nlflong_nat(:) / consumption(:) 
     112          ELSEWHERE 
     113             herbivores(:,j) = 100000. 
     114          ENDWHERE 
     115          ! 
     116       ELSE 
     117          ! 
     118          herbivores(:,j) = 100000. 
     119          ! 
     120       ENDIF 
     121       ! 
     122    ENDDO 
     123}}} 
     124by :  
     125{{{ 
     126     DO j = 2,nvm 
     127       ! 
     128       IF ( natural(j) ) THEN 
     129          ! 
     130          WHERE ( nlflong_nat(:,j) .GT. zero ) 
     131             consumption(:) = hvc1 * nlflong_nat(:,j) ** hvc2 
     132             herbivores(:,j) = one_year * green_age(:,j) * nlflong_nat(:,j) / consumption(:) 
     133          ELSEWHERE 
     134             herbivores(:,j) = 100000. 
     135          ENDWHERE 
     136          ! 
     137       ELSE 
     138          ! 
     139          herbivores(:,j) = 100000. 
     140          ! 
     141       ENDIF 
     142       ! 
     143    ENDDO   
     144}}} 
     145in order to make herbivores more pft-specific. For "black_carbon", we relaced the following line 
     146{{{ 
     147 black_carbon(:) = & 
     148                  black_carbon(:) + bcfrac(:) * residue(:)  
     149}}} 
     150by : 
     151 
     152{{{ 
     153 black_carbon(:) = & 
     154                  black_carbon(:) + bcfrac(:) * residue(:) * veget_max(:,j) 
     155}}} 
     156 
     157In both cases, when we add a new PFT on the same surface, the consumption of herbivory and the quantity of black carbon was doubled ! That's why we change the formulations of these 
     158two sub-models. 
     159 
     160 
     161=== JULY 2011 === 
     162 
     163The most part of the externalized parameters which were still in src_sechiba are in src_parameters now.