42 | | '''intersurf.f90''' reads the number of PFTs and the parameters values chosen by the user. |
| 42 | '''intersurf.f90''' reads the number of PFTs and the parameters values chosen by the user. [[BR]] |
| 43 | We put the routines get_vegcorr and get_soilcorr in slowproc.f90. We correct the following bug in the Olson classification (subroutine get_vegcorr) : |
| 44 | |
| 45 | {{{ |
| 46 | ! 78 warm C3 woody savanna |
| 47 | vegcorr(78,:) = & |
| 48 | & (/0.0, 0.0, 0.4, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.6, 0.0, 0.0, 0.0/) |
| 49 | ! 79 warm C4 woody savanna |
| 50 | vegcorr(79,:) = & |
| 51 | & (/0.0, 0.0, 0.4, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.6, 0.0, 0.0, 0.0/) |
| 52 | |
| 53 | }}} |
| 54 | |
| 55 | The good formulation is : |
| 56 | |
| 57 | {{{ |
| 58 | ! 78 warm C3 woody savanna |
| 59 | vegcorr(78,:) = & |
| 60 | & (/0.0, 0.0, 0.4, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.6, 0.0, 0.0, 0.0/) |
| 61 | ! 79 warm C4 woody savanna |
| 62 | vegcorr(79,:) = & |
| 63 | & (/0.0, 0.0, 0.4, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.6, 0.0, 0.0/) |
| 64 | }}} |
| 65 | |
| 187 | |
| 188 | |
| 189 | === SUMMARY OF THE CHANGES === |
| 190 | |
| 191 | I summarize the modifications and the features of the externalized version of ORCHIDEE : |
| 192 | * 3 bugs corrected : black_carbon(lpj_fire), herbivores(season) and routine get_vegcorr(slowproc) |
| 193 | |
| 194 | * 3 new modules : pft_parameters, constantes_mtc and qsat_moisture |
| 195 | |
| 196 | * 4 modules deleted : constantes_soil, constantes_co2, constantes_veg and stomate_constants |
| 197 | |
| 198 | * ext_coeff replace in all the code ext_coef and ext_coeff |
| 199 | |
| 200 | * type phenology deleted : because we can't use the attribute ALLOCATABLE for a field in a structure |
| 201 | |
| 202 | * Rewrite the explicit referenced to PFTs :(IF j==12 .OR. j==13) replaced by IF(.NOT. natural(j)) => adapte code for a generic number of PFTs |
| 203 | |
| 204 | * Add the function getin_p for characters array |
| 205 | |
| 206 | * Delete multi definitions for Earth radius, pi, min_sechiba, min_stomate |
| 207 | |
| 208 | * Unify parameters definitions for weather and ORCHIDEE : the values used by weather are the same used by ORCHIDEE. |
| 209 | |
| 210 | * Create Labels for all new externalized parameters and add Config Units for the previous parameters |
| 211 | |
| 212 | * Configuration of the number of PFTs : from 2 to X |
| 213 | |
| 214 | * Configuration of the values of some 400 parameters without having to recompile the code. |
| 215 | |
| 216 | * SCRIPTS : design new default files |
| 217 | |
| 218 | Delete unused parameters : |
| 219 | |
| 220 | |
| 221 | |
| 222 | === Choices made === |
| 223 | |
| 224 | |
| 225 | |
| 226 | I try to regroup all the externalized parameters in src_parameters.[[BR]] |
| 227 | |
| 228 | For the pft_parameters : they have to be allocated and some are used by many modules. Moreover, I want to have |
| 229 | a flag called IMPOSE_PARAM which controls the reading of the parameters. [[BR]] |
| 230 | |
| 231 | If Someone wants to go back to the standard values, this flag has to be set to TRUE. [[BR]] |
| 232 | I think also the module pft_parameters as the symetric module of constantes_mtc. |
| 233 | With constantes_mtc.f90, we have only one file to modify to add a new metaclass and we can track more easily the changes made to the values. |
| 234 | |
| 235 | |
| 236 | |
| 237 | |
| 238 | For the other parameters, I want to avoid multiple definitions as some parameters are used by different modules.[[BR]] |
| 239 | |
| 240 | I regroup also these parameters because of the flag IMPOSE_PARAM. [[BR]] |
| 241 | |
| 242 | |
| 243 | The other advantages is that we can distinguish variables from parameters in the code and that we have a |
| 244 | |
| 245 | better readibility of the code (personal point of view). But this is incomfort for some people, we can dispatch |
| 246 | |
| 247 | again the parameters (except the pft-parameters ones).[[BR]] |
| 248 | |
| 249 | |
| 250 | |
| 251 | === NEED TO BE DISCUSSED BEFORE THE TAG === |