source: LMDZ6/trunk/libf/phylmd/conf_phys_m.F90 @ 3357

Last change on this file since 3357 was 3357, checked in by oboucher, 6 years ago

flag_aerosol_strat can be 1 without RRTM

  • Property copyright set to
    Name of program: LMDZ
    Creation date: 1984
    Version: LMDZ5
    License: CeCILL version 2
    Holder: Laboratoire de m\'et\'eorologie dynamique, CNRS, UMR 8539
    See the license file in the root directory
File size: 82.1 KB
Line 
1!
2! $Id: conf_phys.F90 1668 2012-10-12 10:47:37Z idelkadi $
3!
4!
5!
6MODULE conf_phys_m
7
8  IMPLICIT NONE
9
10CONTAINS
11
12  SUBROUTINE conf_phys(ok_journe, ok_mensuel, ok_instan, ok_hf, &
13       ok_LES,&
14       callstats,&
15       solarlong0,seuil_inversion, &
16       fact_cldcon, facttemps,ok_newmicro,iflag_radia,&
17       iflag_cld_th, &
18       iflag_ratqs,ratqsbas,ratqshaut,tau_ratqs, &
19       ok_ade, ok_aie, ok_alw, ok_cdnc, aerosol_couple, chemistry_couple, &
20       flag_aerosol, flag_aerosol_strat, new_aod, &
21       flag_bc_internal_mixture, bl95_b0, bl95_b1,&
22       read_climoz, &
23       alp_offset)
24
25    USE IOIPSL
26    USE surface_data
27    USE phys_cal_mod
28    USE carbon_cycle_mod,  ONLY: carbon_cycle_tr, carbon_cycle_cpl
29    USE mod_grid_phy_lmdz, ONLY: klon_glo
30    USE print_control_mod, ONLY: lunout
31
32    include "conema3.h"
33    include "fisrtilp.h"
34    include "nuage.h"
35    include "YOMCST.h"
36    include "YOMCST2.h"
37
38    include "thermcell.h"
39
40
41    !IM : on inclut/initialise les taux de CH4, N2O, CFC11 et CFC12
42    include "clesphys.h"
43    include "compbl.h"
44    include "comsoil.h"
45    include "YOEGWD.h"
46    !
47    ! Configuration de la "physique" de LMDZ a l'aide de la fonction
48    ! GETIN de IOIPSL
49    !
50    ! LF 05/2001
51    !
52
53    !
54    ! type_ocean:      type d'ocean (force, slab, couple)
55    ! version_ocean:   version d'ocean (opa8/nemo pour type_ocean=couple ou
56    !                                   sicOBS,sicINT,sicNO pour type_ocean=slab)
57    ! ok_veget:   type de modele de vegetation
58    ! ok_journe:  sorties journalieres
59    ! ok_hf:  sorties haute frequence
60    ! ok_mensuel: sorties mensuelles
61    ! ok_instan:  sorties instantanees
62    ! ok_ade, ok_aie: apply or not aerosol direct and indirect effects
63    ! ok_alw: activate aerosol LW effect
64    ! ok_cdnc, ok cloud droplet number concentration
65    ! flag_aerosol_strat : flag pour les aerosols stratos
66    ! flag_bc_internal_mixture : use BC internal mixture if true
67    ! bl95_b*: parameters in the formula to link CDNC to aerosol mass conc
68    !
69
70
71    ! Sortie:
72    LOGICAL              :: ok_newmicro
73    INTEGER              :: iflag_radia
74    LOGICAL              :: ok_journe, ok_mensuel, ok_instan, ok_hf
75    LOGICAL              :: ok_LES
76    LOGICAL              :: callstats
77    LOGICAL              :: ok_ade, ok_aie, ok_alw, ok_cdnc
78    LOGICAL              :: aerosol_couple, chemistry_couple
79    INTEGER              :: flag_aerosol
80    INTEGER              :: flag_aerosol_strat
81    LOGICAL              :: flag_bc_internal_mixture
82    LOGICAL              :: new_aod
83    REAL                 :: bl95_b0, bl95_b1
84    REAL                 :: fact_cldcon, facttemps,ratqsbas,ratqshaut,tau_ratqs
85    INTEGER              :: iflag_cld_th
86    INTEGER              :: iflag_ratqs
87
88    CHARACTER (len = 6), SAVE  :: type_ocean_omp, version_ocean_omp, ocean_omp
89    CHARACTER (len = 10),SAVE  :: type_veget_omp
90    CHARACTER (len = 8), SAVE  :: aer_type_omp
91    LOGICAL, SAVE       :: ok_snow_omp
92    LOGICAL, SAVE       :: ok_newmicro_omp
93    LOGICAL, SAVE       :: ok_all_xml_omp
94    LOGICAL, SAVE       :: ok_lwoff_omp
95    LOGICAL, SAVE       :: ok_journe_omp, ok_mensuel_omp, ok_instan_omp, ok_hf_omp       
96    LOGICAL, SAVE       :: ok_LES_omp   
97    LOGICAL, SAVE       :: callstats_omp
98    LOGICAL, SAVE       :: ok_ade_omp, ok_aie_omp, ok_alw_omp, ok_cdnc_omp
99    LOGICAL, SAVE       :: aerosol_couple_omp, chemistry_couple_omp
100    INTEGER, SAVE       :: flag_aerosol_omp
101    INTEGER, SAVE       :: flag_aerosol_strat_omp
102    LOGICAL, SAVE       :: flag_bc_internal_mixture_omp
103    LOGICAL, SAVE       :: new_aod_omp
104    REAL,SAVE           :: bl95_b0_omp, bl95_b1_omp
105    REAL,SAVE           :: freq_ISCCP_omp, ecrit_ISCCP_omp
106    REAL,SAVE           :: freq_COSP_omp, freq_AIRS_omp
107    REAL,SAVE           :: fact_cldcon_omp, facttemps_omp,ratqsbas_omp
108    REAL,SAVE           :: tau_cld_cv_omp, coefw_cld_cv_omp
109    INTEGER, SAVE       :: iflag_cld_cv_omp
110
111
112    REAL, SAVE          :: ratqshaut_omp
113    REAL, SAVE          :: tau_ratqs_omp
114    REAL, SAVE          :: t_coupl_omp
115    INTEGER, SAVE       :: iflag_radia_omp
116    INTEGER, SAVE       :: iflag_rrtm_omp
117    INTEGER, SAVE       :: iflag_albedo_omp !albedo SB
118    LOGICAL, SAVE       :: ok_chlorophyll_omp ! albedo SB 
119    INTEGER, SAVE       :: NSW_omp
120    INTEGER, SAVE       :: iflag_cld_th_omp, ip_ebil_phy_omp
121    INTEGER, SAVE       :: iflag_ratqs_omp
122
123    REAL, SAVE          :: f_cdrag_ter_omp,f_cdrag_oce_omp
124    REAL, SAVE          :: f_rugoro_omp   , z0min_omp
125    REAL, SAVE          :: z0m_seaice_omp,z0h_seaice_omp
126    REAL, SAVE          :: min_wind_speed_omp,f_gust_wk_omp,f_gust_bl_omp,f_qsat_oce_omp, f_z0qh_oce_omp
127    INTEGER, SAVE       :: iflag_gusts_omp,iflag_z0_oce_omp
128
129    ! Local
130    REAL                 :: zzz
131
132    REAL :: seuil_inversion
133    REAL,SAVE :: seuil_inversion_omp
134
135    INTEGER,SAVE :: iflag_thermals_ed_omp,iflag_thermals_optflux_omp,iflag_thermals_closure_omp
136    REAL, SAVE :: fact_thermals_ed_dz_omp
137    INTEGER,SAVE :: iflag_thermals_omp,nsplit_thermals_omp
138    REAL,SAVE :: tau_thermals_omp,alp_bl_k_omp
139    ! nrlmd le 10/04/2012
140    INTEGER,SAVE :: iflag_trig_bl_omp,iflag_clos_bl_omp
141    INTEGER,SAVE :: tau_trig_shallow_omp,tau_trig_deep_omp
142    REAL,SAVE    :: s_trig_omp
143    ! fin nrlmd le 10/04/2012
144    REAL :: alp_offset
145    REAL, SAVE :: alp_offset_omp
146    INTEGER,SAVE :: iflag_coupl_omp,iflag_clos_omp,iflag_wake_omp
147    INTEGER,SAVE :: iflag_cvl_sigd_omp
148    REAL, SAVE :: coef_clos_ls_omp
149    REAL, SAVE :: supcrit1_omp, supcrit2_omp
150    INTEGER, SAVE :: iflag_mix_omp
151    INTEGER, SAVE :: iflag_mix_adiab_omp
152    REAL, SAVE :: scut_omp, qqa1_omp, qqa2_omp, gammas_omp, Fmax_omp, alphas_omp
153    REAL, SAVE :: tmax_fonte_cv_omp
154
155    REAL,SAVE :: R_ecc_omp,R_peri_omp,R_incl_omp,solaire_omp
156    LOGICAL,SAVE :: ok_suntime_rrtm_omp
157    REAL,SAVE :: co2_ppm_omp, RCO2_omp, co2_ppm_per_omp, RCO2_per_omp
158    REAL,SAVE :: CH4_ppb_omp, RCH4_omp, CH4_ppb_per_omp, RCH4_per_omp
159    REAL,SAVE :: N2O_ppb_omp, RN2O_omp, N2O_ppb_per_omp, RN2O_per_omp
160    REAL,SAVE :: CFC11_ppt_omp,RCFC11_omp,CFC11_ppt_per_omp,RCFC11_per_omp
161    REAL,SAVE :: CFC12_ppt_omp,RCFC12_omp,CFC12_ppt_per_omp,RCFC12_per_omp
162    REAL,SAVE :: epmax_omp
163    REAL,SAVE :: coef_epmax_cape_omp
164    LOGICAL,SAVE :: ok_adj_ema_omp
165    INTEGER,SAVE :: iflag_clw_omp
166    REAL,SAVE :: cld_lc_lsc_omp,cld_lc_con_omp,cld_tau_lsc_omp,cld_tau_con_omp
167    REAL,SAVE :: ffallv_lsc_omp, ffallv_con_omp,coef_eva_omp
168    LOGICAL,SAVE :: reevap_ice_omp
169    INTEGER,SAVE :: iflag_pdf_omp
170    INTEGER,SAVE :: iflag_ice_thermo_omp
171    INTEGER,SAVE :: iflag_t_glace_omp
172    INTEGER,SAVE :: iflag_cloudth_vert_omp
173    INTEGER,SAVE :: iflag_rain_incloud_vol_omp
174    REAL,SAVE :: rad_froid_omp, rad_chau1_omp, rad_chau2_omp
175    REAL,SAVE :: t_glace_min_omp, t_glace_max_omp
176    REAL,SAVE :: exposant_glace_omp
177    REAL,SAVE :: rei_min_omp, rei_max_omp
178    INTEGER,SAVE :: iflag_sic_omp
179    REAL,SAVE :: inertie_sol_omp,inertie_sno_omp,inertie_sic_omp
180    REAL,SAVE :: inertie_lic_omp
181    REAL,SAVE :: qsol0_omp
182    REAL,SAVE :: evap0_omp
183    REAL,SAVE :: albsno0_omp
184    REAL      :: solarlong0
185    REAL,SAVE :: solarlong0_omp
186    INTEGER,SAVE :: top_height_omp,overlap_omp
187    REAL,SAVE :: cdmmax_omp,cdhmax_omp,ksta_omp,ksta_ter_omp,f_ri_cd_min_omp
188    LOGICAL,SAVE :: ok_kzmin_omp
189    REAL, SAVE   :: pbl_lmixmin_alpha_omp
190    REAL, SAVE ::  fmagic_omp, pmagic_omp
191    INTEGER,SAVE :: iflag_pbl_omp,lev_histhf_omp,lev_histday_omp,lev_histmth_omp
192    INTEGER,SAVE :: iflag_pbl_split_omp
193!FC
194    INTEGER,SAVE :: ifl_pbltree_omp
195    REAL,SAVE :: Cd_frein_omp
196!FC
197    INTEGER,SAVE :: iflag_order2_sollw_omp
198    INTEGER, SAVE :: lev_histins_omp, lev_histLES_omp
199    INTEGER, SAVE :: lev_histdayNMC_omp
200    INTEGER, SAVE :: levout_histNMC_omp(3)
201    LOGICAL, SAVE :: ok_histNMC_omp(3)
202    REAL, SAVE :: freq_outNMC_omp(3), freq_calNMC_omp(3)
203    CHARACTER*4, SAVE :: type_run_omp
204    LOGICAL,SAVE :: ok_cosp_omp, ok_airs_omp
205    LOGICAL,SAVE :: ok_mensuelCOSP_omp,ok_journeCOSP_omp,ok_hfCOSP_omp
206    REAL,SAVE :: lonmin_ins_omp, lonmax_ins_omp, latmin_ins_omp, latmax_ins_omp
207    REAL,SAVE :: ecrit_hf_omp, ecrit_day_omp, ecrit_mth_omp, ecrit_reg_omp
208    REAL,SAVE :: ecrit_ins_omp
209    REAL,SAVE :: ecrit_LES_omp
210    REAL,SAVE :: ecrit_tra_omp
211    REAL,SAVE :: cvl_comp_threshold_omp
212    REAL,SAVE :: cvl_sig2feed_omp
213    REAL,SAVE :: cvl_corr_omp
214    LOGICAL,SAVE :: ok_lic_melt_omp
215    LOGICAL,SAVE :: ok_lic_cond_omp
216    !
217    INTEGER,SAVE  :: iflag_cycle_diurne_omp
218    LOGICAL,SAVE  :: soil_model_omp,new_oliq_omp
219    LOGICAL,SAVE  :: ok_orodr_omp, ok_orolf_omp, ok_limitvrai_omp
220    INTEGER, SAVE :: nbapp_rad_omp, iflag_con_omp
221    INTEGER, SAVE :: nbapp_cv_omp, nbapp_wk_omp
222    INTEGER, SAVE :: iflag_ener_conserv_omp
223    LOGICAL, SAVE :: ok_conserv_q_omp
224    INTEGER, SAVE :: iflag_fisrtilp_qsat_omp
225    INTEGER, SAVE :: iflag_bergeron_omp
226    LOGICAL,SAVE  :: ok_strato_omp
227    LOGICAL,SAVE  :: ok_hines_omp, ok_gwd_rando_omp
228    REAL, SAVE    :: gwd_rando_ruwmax_omp, gwd_rando_sat_omp
229    REAL, SAVE    :: gwd_front_ruwmax_omp, gwd_front_sat_omp
230    REAL, SAVE    :: sso_gkdrag_omp,sso_grahil_omp,sso_grcrit_omp
231    REAL, SAVE    :: sso_gfrcri_omp,sso_gkwake_omp,sso_gklift_omp
232    LOGICAL,SAVE  :: ok_qch4_omp
233    LOGICAL,SAVE  :: carbon_cycle_tr_omp
234    LOGICAL,SAVE  :: carbon_cycle_cpl_omp
235    LOGICAL,SAVE  :: adjust_tropopause_omp
236    LOGICAL,SAVE  :: ok_daily_climoz_omp
237
238    INTEGER, INTENT(OUT):: read_climoz ! read ozone climatology, OpenMP shared
239    ! Allowed values are 0, 1 and 2
240    ! 0: do not read an ozone climatology
241    ! 1: read a single ozone climatology that will be used day and night
242    ! 2: read two ozone climatologies, the average day and night
243    ! climatology and the daylight climatology
244
245    !-----------------------------------------------------------------
246
247    print*,'CONFPHYS ENTREE'
248    !$OMP MASTER
249    !Config Key  = type_ocean
250    !Config Desc = Type d'ocean
251    !Config Def  = force
252    !Config Help = Type d'ocean utilise: force, slab,couple
253    !
254    type_ocean_omp = 'force '
255    CALL getin('type_ocean', type_ocean_omp)
256    !
257    !Config Key  = version_ocean
258    !Config Desc = Version d'ocean
259    !Config Def  = xxxxxx
260    !Config Help = Version d'ocean utilise: opa8/nemo/sicOBS/xxxxxx
261    !
262    version_ocean_omp = 'xxxxxx'
263    CALL getin('version_ocean', version_ocean_omp)
264
265    !Config Key  = OCEAN
266    !Config Desc = Old parameter name for type_ocean
267    !Config Def  = yyyyyy
268    !Config Help = This is only for testing purpose
269    !
270    ocean_omp = 'yyyyyy'
271    CALL getin('OCEAN', ocean_omp)
272    IF (ocean_omp /= 'yyyyyy') THEN
273       WRITE(lunout,*)'ERROR! Old variable name OCEAN used in parmeter file.'
274       WRITE(lunout,*)'Variable OCEAN has been replaced by the variable type_ocean.'
275       WRITE(lunout,*)'You have to update your parameter file physiq.def to succed running'
276       CALL abort_physic('conf_phys','Variable OCEAN no longer existing, use variable name type_ocean',1)
277    ENDIF
278
279    !Config Key  = t_coupl
280    !Config Desc = Pas de temps du couplage atm/oce en sec.
281    !Config Def  = 86400
282    !Config Help = This is only for testing purpose
283    !
284    t_coupl_omp = 86400.
285    CALL getin('t_coupl', t_coupl_omp)
286    IF (t_coupl_omp == 0) THEN
287       WRITE(lunout,*)'ERROR! Timestep of coupling between atmosphere and ocean'
288       WRITE(lunout,*)'cannot be zero.'
289       CALL abort_physic('conf_phys','t_coupl = 0.',1)
290    ENDIF
291
292    !
293    !Config Key  = ok_all_xml
294    !Config Desc = utiliser les xml pourles définitions des champs pour xios
295    !Config Def  = .FALSE.
296    !Config Help =
297    !
298    ok_all_xml_omp = .FALSE.
299    CALL getin('ok_all_xml', ok_all_xml_omp)
300
301    !
302    !Config Key  = ok_lwoff
303    !Config Desc = inhiber l effet radiatif LW des nuages
304    !Config Def  = .FALSE.
305    !Config Help =
306    !
307    ok_lwoff_omp = .FALSE.
308    CALL getin('ok_lwoff', ok_lwoff_omp)
309    !
310
311    !
312    !Config Key  = VEGET
313    !Config Desc = Type de modele de vegetation
314    !Config Def  = .FALSE.
315    !Config Help = Type de modele de vegetation utilise
316    !
317    type_veget_omp ='orchidee'
318    CALL getin('VEGET', type_veget_omp)
319    !
320
321    ! Martin
322    !Config Key  = ok_snow
323    !Config Desc = Flag to activate snow model SISVAT
324    !Config Def  = .FALSE.
325    ok_snow_omp = .FALSE.
326    CALL getin('ok_snow', ok_snow_omp)
327    ! Martin
328
329    !Config Key  = OK_journe
330    !Config Desc = Pour des sorties journalieres
331    !Config Def  = .FALSE.
332    !Config Help = Pour creer le fichier histday contenant les sorties
333    !              journalieres
334    !
335    ok_journe_omp = .FALSE.
336    CALL getin('OK_journe', ok_journe_omp)
337    !
338    !Config Key  = ok_hf
339    !Config Desc = Pour des sorties haute frequence
340    !Config Def  = .FALSE.
341    !Config Help = Pour creer le fichier histhf contenant les sorties
342    !              haute frequence ( 3h ou 6h)
343    !
344    ok_hf_omp = .FALSE.
345    CALL getin('ok_hf', ok_hf_omp)
346    !
347    !Config Key  = OK_mensuel
348    !Config Desc = Pour des sorties mensuelles
349    !Config Def  = .TRUE.
350    !Config Help = Pour creer le fichier histmth contenant les sorties
351    !              mensuelles
352    !
353    ok_mensuel_omp = .TRUE.
354    CALL getin('OK_mensuel', ok_mensuel_omp)
355    !
356    !Config Key  = OK_instan
357    !Config Desc = Pour des sorties instantanees
358    !Config Def  = .FALSE.
359    !Config Help = Pour creer le fichier histins contenant les sorties
360    !              instantanees
361    !
362    ok_instan_omp = .FALSE.
363    CALL getin('OK_instan', ok_instan_omp)
364    !
365    !Config Key  = ok_ade
366    !Config Desc = Aerosol direct effect or not?
367    !Config Def  = .FALSE.
368    !Config Help = Used in radlwsw.F
369    !
370    ok_ade_omp = .FALSE.
371    CALL getin('ok_ade', ok_ade_omp)
372
373    !Config Key  = ok_alw
374    !Config Desc = Aerosol longwave effect or not?
375    !Config Def  = .FALSE.
376    !Config Help = Used in radlwsw.F
377    !
378    ok_alw_omp = .FALSE.
379    CALL getin('ok_alw', ok_alw_omp)
380
381    !
382    !Config Key  = ok_aie
383    !Config Desc = Aerosol indirect effect or not?
384    !Config Def  = .FALSE.
385    !Config Help = Used in nuage.F and radlwsw.F
386    !
387    ok_aie_omp = .FALSE.
388    CALL getin('ok_aie', ok_aie_omp)
389
390    !
391    !Config Key  = ok_cdnc
392    !Config Desc = ok cloud droplet number concentration
393    !Config Def  = .FALSE.
394    !Config Help = Used in newmicro.F
395    !
396    ok_cdnc_omp = .FALSE.
397    CALL getin('ok_cdnc', ok_cdnc_omp)
398    !
399    !Config Key  = aerosol_couple
400    !Config Desc = read aerosol in file or calcul by inca
401    !Config Def  = .FALSE.
402    !Config Help = Used in physiq.F
403    !
404    aerosol_couple_omp = .FALSE.
405    CALL getin('aerosol_couple',aerosol_couple_omp)
406    !
407    !Config Key  = chemistry_couple
408    !Config Desc = read O3 chemistry in file or calcul by inca
409    !Config Def  = .FALSE.
410    !Config Help = Used in physiq.F
411    !
412    chemistry_couple_omp = .FALSE.
413    CALL getin('chemistry_couple',chemistry_couple_omp)
414    !
415    !Config Key  = flag_aerosol
416    !Config Desc = which aerosol is use for coupled model
417    !Config Def  = 1
418    !Config Help = Used in physiq.F
419    !
420    ! - flag_aerosol=0 => no aerosol
421    ! - flag_aerosol=1 => so4 only (defaut)
422    ! - flag_aerosol=2 => bc  only
423    ! - flag_aerosol=3 => pom only
424    ! - flag_aerosol=4 => seasalt only
425    ! - flag_aerosol=5 => dust only
426    ! - flag_aerosol=6 => all aerosol
427    ! - flag_aerosol=7 => natural aerosol + MACv2SP
428    ! - (in this case aerosols.1980.nc should point to aerosols.nat.nc)
429
430    flag_aerosol_omp = 0
431    CALL getin('flag_aerosol',flag_aerosol_omp)
432
433    !
434    !Config Key  = flag_bc_internal_mixture
435    !Config Desc = state of mixture for BC aerosols
436    ! - n = external mixture
437    ! - y = internal mixture
438    !Config Def  = n
439    !Config Help = Used in physiq.F / aeropt
440    !
441    flag_bc_internal_mixture_omp = .FALSE.
442    CALL getin('flag_bc_internal_mixture',flag_bc_internal_mixture_omp)
443
444    ! Temporary variable for testing purpose!
445    !Config Key  = new_aod
446    !Config Desc = which calcul of aeropt
447    !Config Def  = FALSE
448    !Config Help = Used in physiq.F
449    !
450    new_aod_omp = .TRUE.
451    CALL getin('new_aod',new_aod_omp)
452
453    !
454    !Config Key  = aer_type
455    !Config Desc = Use a constant field for the aerosols
456    !Config Def  = scenario
457    !Config Help = Used in readaerosol.F90
458    !
459    aer_type_omp = 'scenario'
460    CALL getin('aer_type', aer_type_omp)
461
462    !
463    !Config Key  = bl95_b0
464    !Config Desc = Parameter in CDNC-maer link (Boucher&Lohmann 1995)
465    !Config Def  = .FALSE.
466    !Config Help = Used in nuage.F
467    !
468    bl95_b0_omp = 2.
469    CALL getin('bl95_b0', bl95_b0_omp)
470
471    !Config Key  = bl95_b1
472    !Config Desc = Parameter in CDNC-maer link (Boucher&Lohmann 1995)
473    !Config Def  = .FALSE.
474    !Config Help = Used in nuage.F
475    !
476    bl95_b1_omp = 0.2
477    CALL getin('bl95_b1', bl95_b1_omp)
478
479    !Config Key  = freq_ISCCP
480    !Config Desc = Frequence d'appel du simulateur ISCCP en secondes;
481    !              par defaut 10800, i.e. 3 heures
482    !Config Def  = 10800.
483    !Config Help = Used in ini_histISCCP.h
484    !
485    freq_ISCCP_omp = 10800.
486    CALL getin('freq_ISCCP', freq_ISCCP_omp)
487    !
488    !Config Key  = ecrit_ISCCP
489    !Config Desc = Frequence d'ecriture des resultats du simulateur ISCCP en nombre de jours;
490    !              par defaut 1., i.e. 1 jour
491    !Config Def  = 1.
492    !Config Help = Used in ini_histISCCP.h
493    !
494    !
495    ecrit_ISCCP_omp = 1.
496    CALL getin('ecrit_ISCCP', ecrit_ISCCP_omp)
497
498    !Config Key  = freq_COSP
499    !Config Desc = Frequence d'appel du simulateur COSP en secondes;
500    !              par defaut 10800, i.e. 3 heures
501    !Config Def  = 10800.
502    !Config Help = Used in ini_histdayCOSP.h
503    !
504    freq_COSP_omp = 10800.
505    CALL getin('freq_COSP', freq_COSP_omp)
506
507    !Config Key  = freq_AIRS
508    !Config Desc = Frequence d'appel du simulateur AIRS en secondes;
509    !              par defaut 10800, i.e. 3 heures
510    !Config Def  = 10800.
511    !Config Help = Used in ini_histdayAIRS.h
512    !
513    freq_AIRS_omp = 10800.
514    CALL getin('freq_AIRS', freq_AIRS_omp)
515
516    !
517    !Config Key  = ip_ebil_phy
518    !Config Desc = Niveau de sortie pour les diags bilan d'energie
519    !Config Def  = 0
520    !Config Help =
521    !               
522    ip_ebil_phy_omp = 0
523    CALL getin('ip_ebil_phy', ip_ebil_phy_omp)
524    IF (ip_ebil_phy_omp/=0) THEN
525       CALL abort_physic('conf_phys','ip_ebil_phy_omp doit etre 0 sur cette version',1)
526    ENDIF
527
528    !
529    !Config Key  = seuil_inversion
530    !Config Desc = Seuil ur dTh pour le choix entre les schemas de CL
531    !Config Def  = -0.1
532    !Config Help =
533    !               
534    seuil_inversion_omp = -0.1
535    CALL getin('seuil_inversion', seuil_inversion_omp)
536
537    !
538    ! Constante solaire & Parametres orbitaux & taux gaz effet de serre BEG
539    !
540    !Config Key  = R_ecc
541    !Config Desc = Excentricite
542    !Config Def  = 0.016715
543    !Config Help =
544    !               
545    !valeur AMIP II
546    R_ecc_omp = 0.016715
547    CALL getin('R_ecc', R_ecc_omp)
548    !
549    !Config Key  = R_peri
550    !Config Desc = Equinoxe
551    !Config Def  =
552    !Config Help =
553    !               
554    !
555    !valeur AMIP II
556    R_peri_omp = 102.7
557    CALL getin('R_peri', R_peri_omp)
558    !
559    !Config Key  = R_incl
560    !Config Desc = Inclinaison
561    !Config Def  =
562    !Config Help =
563    !               
564    !
565    !valeur AMIP II
566    R_incl_omp = 23.441
567    CALL getin('R_incl', R_incl_omp)
568    !
569    !Config Key  = solaire
570    !Config Desc = Constante solaire en W/m2
571    !Config Def  = 1365.
572    !Config Help =
573    !               
574    !
575    !valeur AMIP II
576    solaire_omp = 1365.
577    CALL getin('solaire', solaire_omp)
578    !
579    !Config Key  = co2_ppm
580    !Config Desc = concentration du gaz carbonique en ppmv
581    !Config Def  = 348.
582    !Config Help =
583    !               
584    !
585    !valeur AMIP II
586    co2_ppm_omp = 348.
587    CALL getin('co2_ppm', co2_ppm_omp)
588    !
589    !Config Key  = RCO2
590    !Config Desc = Concentration du CO2
591    !Config Def  = co2_ppm * 1.0e-06  * 44.011/28.97
592    !Config Def  = 348. * 1.0e-06  * 44.011/28.97
593    !Config Help =
594    !               
595    ! RCO2 = 5.286789092164308E-04
596    !ancienne valeur
597    RCO2_omp = co2_ppm_omp * 1.0e-06  * 44.011/28.97 ! pour co2_ppm=348.
598
599    !  CALL getin('RCO2', RCO2)
600    !
601    !Config Key  = RCH4
602    !Config Desc = Concentration du CH4
603    !Config Def  = 1.65E-06* 16.043/28.97
604    !Config Help =
605    !               
606    !
607    !valeur AMIP II
608    !OK  RCH4 = 1.65E-06* 16.043/28.97
609    ! RCH4 = 9.137366240938903E-07
610    !
611    !ancienne valeur
612    ! RCH4 = 1.72E-06* 16.043/28.97
613    !OK CALL getin('RCH4', RCH4)
614    zzz = 1650.
615    CALL getin('CH4_ppb', zzz)
616    CH4_ppb_omp = zzz
617    RCH4_omp = CH4_ppb_omp * 1.0E-09 * 16.043/28.97
618    !
619    !Config Key  = RN2O
620    !Config Desc = Concentration du N2O
621    !Config Def  = 306.E-09* 44.013/28.97
622    !Config Help =
623    !               
624    !
625    !valeur AMIP II
626    !OK  RN2O = 306.E-09* 44.013/28.97
627    ! RN2O = 4.648939592682085E-07
628    !
629    !ancienne valeur
630    ! RN2O = 310.E-09* 44.013/28.97
631    !OK  CALL getin('RN2O', RN2O)
632    zzz=306.
633    CALL getin('N2O_ppb', zzz)
634    N2O_ppb_omp = zzz
635    RN2O_omp = N2O_ppb_omp * 1.0E-09 * 44.013/28.97
636    !
637    !Config Key  = RCFC11
638    !Config Desc = Concentration du CFC11
639    !Config Def  = 280.E-12* 137.3686/28.97
640    !Config Help =
641    !               
642    !
643    !OK RCFC11 = 280.E-12* 137.3686/28.97
644    zzz = 280.
645    CALL getin('CFC11_ppt',zzz)
646    CFC11_ppt_omp = zzz
647    RCFC11_omp=CFC11_ppt_omp* 1.0E-12 * 137.3686/28.97
648    ! RCFC11 = 1.327690990680013E-09
649    !OK CALL getin('RCFC11', RCFC11)
650    !
651    !Config Key  = RCFC12
652    !Config Desc = Concentration du CFC12
653    !Config Def  = 484.E-12* 120.9140/28.97
654    !Config Help =
655    !               
656    !
657    !OK RCFC12 = 484.E-12* 120.9140/28.97
658    zzz = 484.
659    CALL getin('CFC12_ppt',zzz)
660    CFC12_ppt_omp = zzz
661    RCFC12_omp = CFC12_ppt_omp * 1.0E-12 * 120.9140/28.97
662    ! RCFC12 = 2.020102726958923E-09
663    !OK CALL getin('RCFC12', RCFC12)
664
665    !ajout CFMIP begin
666    !
667    !Config Key  = co2_ppm_per
668    !Config Desc = concentration du co2_ppm_per
669    !Config Def  = 348.
670    !Config Help =
671    !               
672    co2_ppm_per_omp = co2_ppm_omp
673    CALL getin('co2_ppm_per', co2_ppm_per_omp)
674    !
675    !Config Key  = RCO2_per
676    !Config Desc = Concentration du CO2_per
677    !Config Def  = co2_ppm_per * 1.0e-06  * 44.011/28.97
678    !Config Def  = 348. * 1.0e-06  * 44.011/28.97
679    !Config Help =
680    !               
681    RCO2_per_omp = co2_ppm_per_omp * 1.0e-06  * 44.011/28.97
682
683    !Config Key  = ok_4xCO2atm
684    !Config Desc = Calcul ou non effet radiatif 4xco2
685    !Config Def  = .FALSE.
686    !Config Help =
687
688    !Config Key  = RCH4_per
689    !Config Desc = Concentration du CH4_per
690    !Config Def  = 1.65E-06* 16.043/28.97
691    !Config Help =
692    !               
693    zzz = CH4_ppb_omp
694    CALL getin('CH4_ppb_per', zzz)
695    CH4_ppb_per_omp = zzz
696    RCH4_per_omp = CH4_ppb_per_omp * 1.0E-09 * 16.043/28.97
697    !
698    !Config Key  = RN2O_per
699    !Config Desc = Concentration du N2O_per
700    !Config Def  = 306.E-09* 44.013/28.97
701    !Config Help =
702    !               
703    zzz = N2O_ppb_omp
704    CALL getin('N2O_ppb_per', zzz)
705    N2O_ppb_per_omp = zzz
706    RN2O_per_omp = N2O_ppb_per_omp * 1.0E-09 * 44.013/28.97
707    !
708    !Config Key  = RCFC11_per
709    !Config Desc = Concentration du CFC11_per
710    !Config Def  = 280.E-12* 137.3686/28.97
711    !Config Help =
712    !               
713    zzz = CFC11_ppt_omp
714    CALL getin('CFC11_ppt_per',zzz)
715    CFC11_ppt_per_omp = zzz
716    RCFC11_per_omp=CFC11_ppt_per_omp* 1.0E-12 * 137.3686/28.97
717    !
718    !Config Key  = RCFC12_per
719    !Config Desc = Concentration du CFC12_per
720    !Config Def  = 484.E-12* 120.9140/28.97
721    !Config Help =
722    !               
723    zzz = CFC12_ppt_omp
724    CALL getin('CFC12_ppt_per',zzz)
725    CFC12_ppt_per_omp = zzz
726    RCFC12_per_omp = CFC12_ppt_per_omp * 1.0E-12 * 120.9140/28.97
727    !ajout CFMIP end
728
729    !
730    ! FH 2008/05/09 On elimine toutes les clefs physiques dans la dynamique
731    ! Constantes precedemment dans dyn3d/conf_gcm
732
733    !Config  Key  = iflag_cycle_diurne
734    !Config  Desc = Cycle diurne
735    !Config  Def  = 1
736    !Config  Help = Cette option permet d'eteidre le cycle diurne.
737    !Config         Peut etre util pour accelerer le code !
738    iflag_cycle_diurne_omp = 1
739    CALL getin('iflag_cycle_diurne',iflag_cycle_diurne_omp)
740
741    !Config  Key  = soil_model
742    !Config  Desc = Modele de sol
743    !Config  Def  = y
744    !Config  Help = Choix du modele de sol (Thermique ?)
745    !Config         Option qui pourait un string afin de pouvoir
746    !Config         plus de choix ! Ou meme une liste d'options !
747    soil_model_omp = .TRUE.
748    CALL getin('soil_model',soil_model_omp)
749
750    !Config  Key  = new_oliq
751    !Config  Desc = Nouvelle eau liquide
752    !Config  Def  = y
753    !Config  Help = Permet de mettre en route la
754    !Config         nouvelle parametrisation de l'eau liquide !
755    new_oliq_omp = .TRUE.
756    CALL getin('new_oliq',new_oliq_omp)
757
758    !Config  Key  = ok_orodr
759    !Config  Desc = Orodr ???
760    !Config  Def  = y
761    !Config  Help = Y en a pas comprendre !
762    !Config         
763    ok_orodr_omp = .TRUE.
764    CALL getin('ok_orodr',ok_orodr_omp)
765
766    !Config  Key  =  ok_orolf
767    !Config  Desc = Orolf ??
768    !Config  Def  = y
769    !Config  Help = Connais pas !
770    ok_orolf_omp = .TRUE.
771    CALL getin('ok_orolf', ok_orolf_omp)
772
773    !Config  Key  = ok_limitvrai
774    !Config  Desc = Force la lecture de la bonne annee
775    !Config  Def  = n
776    !Config  Help = On peut forcer le modele a lire le
777    !Config         fichier SST de la bonne annee. C'est une tres bonne
778    !Config         idee, pourquoi ne pas mettre toujours a y ???
779    ok_limitvrai_omp = .FALSE.
780    CALL getin('ok_limitvrai',ok_limitvrai_omp)
781
782    !Config  Key  = nbapp_rad
783    !Config  Desc = Frequence d'appel au rayonnement
784    !Config  Def  = 12
785    !Config  Help = Nombre  d'appels des routines de rayonnements
786    !Config         par jour.
787    nbapp_rad_omp = 12
788    CALL getin('nbapp_rad',nbapp_rad_omp)
789
790    !Config  Key  = iflag_con
791    !Config  Desc = Flag de convection
792    !Config  Def  = 2
793    !Config  Help = Flag  pour la convection les options suivantes existent :
794    !Config         1 pour LMD,
795    !Config         2 pour Tiedtke,
796    !Config         3 pour CCM(NCAR) 
797    iflag_con_omp = 2
798    CALL getin('iflag_con',iflag_con_omp)
799
800    !Config  Key  = nbapp_cv
801    !Config  Desc = Frequence d'appel a la convection
802    !Config  Def  = 0
803    !Config  Help = Nombre  d'appels des routines de convection
804    !Config         par jour. Si =0, appel a chaque pas de temps physique.
805    nbapp_cv_omp = 0
806    CALL getin('nbapp_cv',nbapp_cv_omp)
807
808    !Config  Key  = nbapp_wk
809    !Config  Desc = Frequence d'appel aux wakes
810    !Config  Def  = 0
811    !Config  Help = Nombre  d'appels des routines de wakes
812    !Config         par jour. Si =0, appel a chaque pas de temps physique.
813    nbapp_wk_omp = 0
814    CALL getin('nbapp_wk',nbapp_wk_omp)
815
816    !Config  Key  = iflag_ener_conserv
817    !Config  Desc = Flag de convection
818    !Config  Def  = 1
819    !Config  Help = Flag  pour la convection les options suivantes existent :
820    !Config         -1 pour Kinetic energy correction
821    !Config         1  conservation kinetic and enthalpy
822    iflag_ener_conserv_omp = -1
823    CALL getin('iflag_ener_conserv',iflag_ener_conserv_omp)
824
825    !Config  Key  = ok_conserv_q
826    !Config  Desc = Switch des corrections de conservation de l'eau
827    !Config  Def  = y
828    !Config  Help = Switch des corrections de conservation de l'eau
829    !Config         y -> corrections activees
830    !Config         n -> conformite avec versions anterieures au 1/4/2014
831    ok_conserv_q_omp = .FALSE.
832    CALL getin('ok_conserv_q',ok_conserv_q_omp)
833
834    !Config  Key  = iflag_fisrtilp_qsat
835    !Config  Desc = Flag de fisrtilp
836    !Config  Def  = 0
837    !Config  Help = Flag  pour la pluie grande-échelle les options suivantes existent :
838    !Config         >1 nb iterations pour converger dans le calcul de qsat
839    iflag_fisrtilp_qsat_omp = 0
840    CALL getin('iflag_fisrtilp_qsat',iflag_fisrtilp_qsat_omp)
841
842    !Config  Key  = iflag_bergeron
843    !Config  Desc = Flag de fisrtilp
844    !Config  Def  = 0
845    !Config  Help = Flag  pour la pluie grande-échelle les options suivantes existent :
846    !Config         0 pas d effet Bergeron
847    !Config         1 effet Bergeron pour T<0
848    iflag_bergeron_omp = 0
849    CALL getin('iflag_bergeron',iflag_bergeron_omp)
850
851    !
852    !
853    !
854    ! Constante solaire & Parametres orbitaux & taux gaz effet de serre END
855    !
856    ! KE
857    !
858
859    !Config key  = cvl_comp_threshold
860    !Config Desc = maximum fraction of convective points enabling compression
861    !Config Def  = 1.00
862    !Config Help = fields are compressed when less than a fraction cvl_comp_threshold
863    !Config Help = of the points is convective.
864    cvl_comp_threshold_omp = 1.00
865    CALL getin('cvl_comp_threshold', cvl_comp_threshold_omp)
866
867    !Config key  = cvl_sig2feed
868    !Config Desc = sigma coordinate at top of feeding layer
869    !Config Def  = 0.97
870    !Config Help = deep convection is fed by the layer extending from the surface (pressure ps)
871    !Config Help = and cvl_sig2feed*ps.
872    cvl_sig2feed_omp = 0.97
873    CALL getin('cvl_sig2feed', cvl_sig2feed_omp)
874
875    !Config key  = cvl_corr
876    !Config Desc = Facteur multiplication des precip convectives dans KE
877    !Config Def  = 1.00
878    !Config Help = 1.02 pour un moderne ou un pre-ind. A ajuster pour un glaciaire
879    cvl_corr_omp = 1.00
880    CALL getin('cvl_corr', cvl_corr_omp)
881
882
883    !Config Key  = epmax
884    !Config Desc = Efficacite precip
885    !Config Def  = 0.993
886    !Config Help =
887    !
888    epmax_omp = .993
889    CALL getin('epmax', epmax_omp)
890
891    coef_epmax_cape_omp = 0.0   
892    CALL getin('coef_epmax_cape', coef_epmax_cape_omp)       
893    !
894    !Config Key  = ok_adj_ema
895    !Config Desc = 
896    !Config Def  = FALSE
897    !Config Help =
898    !
899    ok_adj_ema_omp = .FALSE.
900    CALL getin('ok_adj_ema',ok_adj_ema_omp)
901    !
902    !Config Key  = iflag_clw
903    !Config Desc = 
904    !Config Def  = 0
905    !Config Help =
906    !
907    iflag_clw_omp = 0
908    CALL getin('iflag_clw',iflag_clw_omp)
909    !
910    !Config Key  = cld_lc_lsc
911    !Config Desc = 
912    !Config Def  = 2.6e-4
913    !Config Help =
914    !
915    cld_lc_lsc_omp = 2.6e-4
916    CALL getin('cld_lc_lsc',cld_lc_lsc_omp)
917    !
918    !Config Key  = cld_lc_con
919    !Config Desc = 
920    !Config Def  = 2.6e-4
921    !Config Help =
922    !
923    cld_lc_con_omp = 2.6e-4
924    CALL getin('cld_lc_con',cld_lc_con_omp)
925    !
926    !Config Key  = cld_tau_lsc
927    !Config Desc = 
928    !Config Def  = 3600.
929    !Config Help =
930    !
931    cld_tau_lsc_omp = 3600.
932    CALL getin('cld_tau_lsc',cld_tau_lsc_omp)
933    !
934    !Config Key  = cld_tau_con
935    !Config Desc = 
936    !Config Def  = 3600.
937    !Config Help =
938    !
939    cld_tau_con_omp = 3600.
940    CALL getin('cld_tau_con',cld_tau_con_omp)
941    !
942    !Config Key  = ffallv_lsc
943    !Config Desc = 
944    !Config Def  = 1.
945    !Config Help =
946    !
947    ffallv_lsc_omp = 1.
948    CALL getin('ffallv_lsc',ffallv_lsc_omp)
949    !
950    !Config Key  = ffallv_con
951    !Config Desc = 
952    !Config Def  = 1.
953    !Config Help =
954    !
955    ffallv_con_omp = 1.
956    CALL getin('ffallv_con',ffallv_con_omp)
957    !
958    !Config Key  = coef_eva
959    !Config Desc = 
960    !Config Def  = 2.e-5
961    !Config Help =
962    !
963    coef_eva_omp = 2.e-5
964    CALL getin('coef_eva',coef_eva_omp)
965    !
966    !Config Key  = reevap_ice
967    !Config Desc = 
968    !Config Def  = .FALSE.
969    !Config Help =
970    !
971    reevap_ice_omp = .FALSE.
972    CALL getin('reevap_ice',reevap_ice_omp)
973
974    !Config Key  = iflag_ratqs
975    !Config Desc =
976    !Config Def  = 1
977    !Config Help =
978    !
979    iflag_ratqs_omp = 1
980    CALL getin('iflag_ratqs',iflag_ratqs_omp)
981
982    !
983    !Config Key  = iflag_radia
984    !Config Desc = 
985    !Config Def  = 1
986    !Config Help =
987    !
988    iflag_radia_omp = 1
989    CALL getin('iflag_radia',iflag_radia_omp)
990
991    !
992    !Config Key  = iflag_rrtm
993    !Config Desc = 
994    !Config Def  = 0
995    !Config Help =
996    !
997    iflag_rrtm_omp = 0
998    CALL getin('iflag_rrtm',iflag_rrtm_omp)
999
1000    !
1001    !Config Key  = NSW
1002    !Config Desc = 
1003    !Config Def  = 0
1004    !Config Help =
1005    !
1006    NSW_omp = 2
1007    CALL getin('NSW',NSW_omp)
1008    !albedo SB >>>
1009    iflag_albedo_omp = 0
1010    CALL getin('iflag_albedo',iflag_albedo_omp)
1011
1012    ok_chlorophyll_omp=.FALSE.
1013    CALL getin('ok_chlorophyll',ok_chlorophyll_omp)
1014    !albedo SB <<<
1015    !
1016    !Config Key  = ok_sun_time
1017    !Config Desc = oui ou non variabilite solaire
1018    !Config Def  = .FALSE.
1019    !Config Help =
1020    !
1021    !
1022    !valeur AMIP II
1023    ok_suntime_rrtm_omp = .FALSE.
1024    IF (iflag_rrtm_omp==1) THEN
1025      CALL getin('ok_suntime_rrtm',ok_suntime_rrtm_omp)
1026    ENDIF
1027    !
1028    !Config Key  = flag_aerosol_strat
1029    !Config Desc = use stratospheric aerosols 0, 1, 2
1030    ! - 0 = no stratospheric aerosols
1031    ! - 1 = stratospheric aerosols scaled from 550 nm AOD
1032    ! - 2 = stratospheric aerosol properties from CMIP6
1033    !Option 2 is only available with RRTM, this is tested later on
1034    !Config Def  = 0
1035    !Config Help = Used in physiq.F
1036    !
1037    !
1038    flag_aerosol_strat_omp = 0
1039    CALL getin('flag_aerosol_strat',flag_aerosol_strat_omp)
1040
1041    !
1042    !Config Key  = iflag_cld_th
1043    !Config Desc = 
1044    !Config Def  = 1
1045    !Config Help =
1046    !
1047    iflag_cld_th_omp = 1
1048    ! On lit deux fois avec l'ancien et le nouveau nom
1049    ! pour assurer une retrocompatiblite.
1050    ! A abandonner un jour
1051    CALL getin('iflag_cldcon',iflag_cld_th_omp)
1052    CALL getin('iflag_cld_th',iflag_cld_th_omp)
1053    iflag_cld_cv_omp = 0
1054    CALL getin('iflag_cld_cv',iflag_cld_cv_omp)
1055
1056    !
1057    !Config Key  = tau_cld_cv
1058    !Config Desc =
1059    !Config Def  = 10.
1060    !Config Help =
1061    !
1062    tau_cld_cv_omp = 10.
1063    CALL getin('tau_cld_cv',tau_cld_cv_omp)
1064
1065    !
1066    !Config Key  = coefw_cld_cv
1067    !Config Desc =
1068    !Config Def  = 0.1
1069    !Config Help =
1070    !
1071    coefw_cld_cv_omp = 0.1
1072    CALL getin('coefw_cld_cv',coefw_cld_cv_omp)
1073
1074
1075
1076
1077    !
1078    !Config Key  = iflag_pdf
1079    !Config Desc = 
1080    !Config Def  = 0
1081    !Config Help =
1082    !
1083    iflag_pdf_omp = 0
1084    CALL getin('iflag_pdf',iflag_pdf_omp)
1085    !
1086    !Config Key  = fact_cldcon
1087    !Config Desc = 
1088    !Config Def  = 0.375
1089    !Config Help =
1090    !
1091    fact_cldcon_omp = 0.375
1092    CALL getin('fact_cldcon',fact_cldcon_omp)
1093
1094    !
1095    !Config Key  = facttemps
1096    !Config Desc = 
1097    !Config Def  = 1.e-4
1098    !Config Help =
1099    !
1100    facttemps_omp = 1.e-4
1101    CALL getin('facttemps',facttemps_omp)
1102
1103    !
1104    !Config Key  = ok_newmicro
1105    !Config Desc = 
1106    !Config Def  = .TRUE.
1107    !Config Help =
1108    !
1109    ok_newmicro_omp = .TRUE.
1110    CALL getin('ok_newmicro',ok_newmicro_omp)
1111    !
1112    !Config Key  = ratqsbas
1113    !Config Desc = 
1114    !Config Def  = 0.01
1115    !Config Help =
1116    !
1117    ratqsbas_omp = 0.01
1118    CALL getin('ratqsbas',ratqsbas_omp)
1119    !
1120    !Config Key  = ratqshaut
1121    !Config Desc = 
1122    !Config Def  = 0.3
1123    !Config Help =
1124    !
1125    ratqshaut_omp = 0.3
1126    CALL getin('ratqshaut',ratqshaut_omp)
1127
1128    !Config Key  = tau_ratqs
1129    !Config Desc = 
1130    !Config Def  = 1800.
1131    !Config Help =
1132    !
1133    tau_ratqs_omp = 1800.
1134    CALL getin('tau_ratqs',tau_ratqs_omp)
1135
1136    !
1137    !-----------------------------------------------------------------------
1138    ! Longitude solaire pour le calcul de l'ensoleillement en degre
1139    ! si on veut imposer la saison. Sinon, solarlong0=-999.999
1140    !Config Key  = solarlong0
1141    !Config Desc = 
1142    !Config Def  = -999.999
1143    !Config Help =
1144    !
1145    solarlong0_omp = -999.999
1146    CALL getin('solarlong0',solarlong0_omp)
1147    !
1148    !-----------------------------------------------------------------------
1149    !  Valeur imposee pour configuration idealisees
1150    !Config Key  = qsol0 pour le bucket, evap0 pour aquaplanetes, albsno0
1151    ! Default value -1 to activate the full computation
1152    qsol0_omp = -1.
1153    CALL getin('qsol0',qsol0_omp)
1154    evap0_omp = -1.
1155    CALL getin('evap0',evap0_omp)
1156    albsno0_omp = -1.
1157    CALL getin('albsno0',albsno0_omp)
1158    !
1159    !-----------------------------------------------------------------------
1160    !
1161    !Config Key  = iflag_sic
1162    !Config Desc = 
1163    !Config Def  = 0
1164    !Config Help =
1165    !
1166    iflag_sic_omp = 0
1167    CALL getin('iflag_sic',iflag_sic_omp)
1168    !
1169    !Config Key  = inertie_sic
1170    !Config Desc = 
1171    !Config Def  = 2000.
1172    !Config Help =
1173    !
1174    inertie_sic_omp = 2000.
1175    CALL getin('inertie_sic',inertie_sic_omp)
1176    !
1177    !Config Key  = inertie_lic
1178    !Config Desc = 
1179    !Config Def  = 2000.
1180    !Config Help =
1181    !
1182    inertie_lic_omp = 2000.
1183    CALL getin('inertie_lic',inertie_lic_omp)
1184    !
1185    !Config Key  = inertie_sno
1186    !Config Desc = 
1187    !Config Def  = 2000.
1188    !Config Help =
1189    !
1190    inertie_sno_omp = 2000.
1191    CALL getin('inertie_sno',inertie_sno_omp)
1192    !
1193    !Config Key  = inertie_sol
1194    !Config Desc = 
1195    !Config Def  = 2000.
1196    !Config Help =
1197    !
1198    inertie_sol_omp = 2000.
1199    CALL getin('inertie_sol',inertie_sol_omp)
1200
1201    !
1202    !Config Key  = rad_froid
1203    !Config Desc = 
1204    !Config Def  = 35.0
1205    !Config Help =
1206    !
1207    rad_froid_omp = 35.0
1208    CALL getin('rad_froid',rad_froid_omp)
1209
1210    !
1211    !Config Key  = rad_chau1
1212    !Config Desc = 
1213    !Config Def  = 13.0
1214    !Config Help =
1215    !
1216    rad_chau1_omp = 13.0
1217    CALL getin('rad_chau1',rad_chau1_omp)
1218
1219    !
1220    !Config Key  = rad_chau2
1221    !Config Desc = 
1222    !Config Def  = 9.0
1223    !Config Help =
1224    !
1225    rad_chau2_omp = 9.0
1226    CALL getin('rad_chau2',rad_chau2_omp)
1227
1228    !
1229    !Config Key  = t_glace_min
1230    !Config Desc = 
1231    !Config Def  = 258.
1232    !Config Help =
1233    !
1234    t_glace_min_omp = 258.
1235    CALL getin('t_glace_min',t_glace_min_omp)
1236
1237    !
1238    !Config Key  = t_glace_max
1239    !Config Desc = 
1240    !Config Def  = 273.13
1241    !Config Help =
1242    !
1243    t_glace_max_omp = 273.13
1244    CALL getin('t_glace_max',t_glace_max_omp)
1245
1246    !
1247    !Config Key  = exposant_glace
1248    !Config Desc = 
1249    !Config Def  = 2.
1250    !Config Help =
1251    !
1252    exposant_glace_omp = 1.
1253    CALL getin('exposant_glace',exposant_glace_omp)
1254
1255    !
1256    !Config Key  = iflag_t_glace
1257    !Config Desc = 
1258    !Config Def  = 0
1259    !Config Help =
1260    !
1261    iflag_t_glace_omp = 0
1262    CALL getin('iflag_t_glace',iflag_t_glace_omp)
1263
1264    !
1265    !Config Key  = iflag_cloudth_vert
1266    !Config Desc = 
1267    !Config Def  = 0
1268    !Config Help =
1269    !
1270    iflag_cloudth_vert_omp = 0
1271    CALL getin('iflag_cloudth_vert',iflag_cloudth_vert_omp)
1272
1273    !
1274    !Config Key  = iflag_rain_incloud_vol
1275    !Config Desc = 
1276    !Config Def  = 0
1277    !Config Help =
1278    !
1279    iflag_rain_incloud_vol_omp = 0
1280    CALL getin('iflag_rain_incloud_vol',iflag_rain_incloud_vol_omp)
1281
1282    !
1283    !Config Key  = iflag_ice_thermo
1284    !Config Desc = 
1285    !Config Def  = 0
1286    !Config Help =
1287    !
1288    iflag_ice_thermo_omp = 0
1289    CALL getin('iflag_ice_thermo',iflag_ice_thermo_omp)
1290
1291    !Config Key  = rei_min
1292    !Config Desc = 
1293    !Config Def  = 3.5
1294    !Config Help =
1295    !
1296    rei_min_omp = 3.5
1297    CALL getin('rei_min',rei_min_omp)
1298
1299    !
1300    !Config Key  = rei_max
1301    !Config Desc = 
1302    !Config Def  = 61.29
1303    !Config Help =
1304    !
1305    rei_max_omp = 61.29
1306    CALL getin('rei_max',rei_max_omp)
1307
1308    !
1309    !Config Key  = top_height
1310    !Config Desc =
1311    !Config Def  = 3
1312    !Config Help =
1313    !
1314    top_height_omp = 3
1315    CALL getin('top_height',top_height_omp)
1316
1317    !
1318    !Config Key  = overlap
1319    !Config Desc =
1320    !Config Def  = 3
1321    !Config Help =
1322    !
1323    overlap_omp = 3
1324    CALL getin('overlap',overlap_omp)
1325
1326    !
1327    !Config Key  = cdmmax
1328    !Config Desc =
1329    !Config Def  = 1.3E-3
1330    !Config Help =
1331    !
1332    cdmmax_omp = 1.3E-3
1333    CALL getin('cdmmax',cdmmax_omp)
1334
1335    !
1336    !Config Key  = cdhmax
1337    !Config Desc =
1338    !Config Def  = 1.1E-3
1339    !Config Help =
1340    !
1341    cdhmax_omp = 1.1E-3
1342    CALL getin('cdhmax',cdhmax_omp)
1343
1344    !261103
1345    !
1346    !Config Key  = ksta
1347    !Config Desc =
1348    !Config Def  = 1.0e-10
1349    !Config Help =
1350    !
1351    ksta_omp = 1.0e-10
1352    CALL getin('ksta',ksta_omp)
1353
1354    !
1355    !Config Key  = ksta_ter
1356    !Config Desc =
1357    !Config Def  = 1.0e-10
1358    !Config Help =
1359    !
1360    ksta_ter_omp = 1.0e-10
1361    CALL getin('ksta_ter',ksta_ter_omp)
1362
1363    !Config Key  = f_ri_cd_min
1364    !Config Desc =
1365    !Config Def  = 0.1
1366    !Config Help =
1367    !
1368    f_ri_cd_min_omp = 0.1
1369    CALL getin('f_ri_cd_min',f_ri_cd_min_omp)
1370
1371    !
1372    !Config Key  = ok_kzmin
1373    !Config Desc =
1374    !Config Def  = .TRUE.
1375    !Config Help =
1376    !
1377    ok_kzmin_omp = .TRUE.
1378    CALL getin('ok_kzmin',ok_kzmin_omp)
1379
1380    pbl_lmixmin_alpha_omp=0.0
1381    CALL getin('pbl_lmixmin_alpha',pbl_lmixmin_alpha_omp)
1382
1383    !
1384    !Config Key  = fmagic
1385    !Config Desc = additionnal multiplicator factor used for albedo
1386    !Config Def  = 1.
1387    !Config Help = additionnal multiplicator factor used in albedo.F
1388    !
1389    fmagic_omp = 1.
1390    CALL getin('fmagic',fmagic_omp)
1391
1392    !
1393    !Config Key  = pmagic
1394    !Config Desc = additional factor used for albedo
1395    !Config Def  = 0.
1396    !Config Help = additional factor used in albedo.F
1397    !
1398    pmagic_omp = 0.
1399    CALL getin('pmagic',pmagic_omp)
1400
1401
1402    !Config Key = ok_lic_melt
1403    !Config Desc = Prise en compte de la fonte de la calotte dans le bilan d'eau
1404    !Config Def  = .FALSE.
1405    !Config Help = mettre a .FALSE. pour assurer la conservation en eau
1406    ok_lic_melt_omp = .FALSE.
1407    CALL getin('ok_lic_melt', ok_lic_melt_omp)
1408
1409
1410    !Config Key = ok_lic_cond
1411    !Config Desc = Prise en compte depot de vapeur d'eau sur la calotte dans le bilan d'eau
1412    !Config Def  = .FALSE.
1413    !Config Help = mettre a .TRUE. pour assurer la conservation en eau
1414    ok_lic_cond_omp = .FALSE.
1415    CALL getin('ok_lic_cond', ok_lic_cond_omp)
1416
1417    !
1418    ! PARAMETER FOR THE PLANETARY BOUNDARY LAYER
1419    !
1420
1421    !Config Key  = iflag_pbl
1422    !Config Desc =
1423    !Config Def  = 1
1424    !Config Help =
1425    !
1426    iflag_pbl_omp = 1
1427    CALL getin('iflag_pbl',iflag_pbl_omp)
1428
1429!FC
1430    !Config Key  = ifl_pbltree
1431    !Config Desc = drag from trees 0 no activated
1432    !Config Def  = 0
1433    !Config Help =
1434    !
1435    ifl_pbltree_omp = 0
1436    CALL getin('ifl_pbltree',ifl_pbltree_omp)
1437!FC
1438    !Config Key  = Cd_frein
1439    !Config Desc = drag from trees
1440    !Config Def  = 7.5E-02 (valeur Masson mais fait planter avec des LAI eleves)
1441    !Config Help =
1442    !
1443    Cd_frein_omp = 7.5E-02
1444    CALL getin('Cd_frein',Cd_frein_omp)
1445
1446    !
1447    !Config Key  = iflag_pbl_split
1448    !Config Desc = decimal flag: least signif digit = split vdf; next digit = split thermals
1449    !Config Def  = 0
1450    !Config Help = 0-> no splitting; 1-> vdf splitting; 10-> thermals splitting; 11-> full splitting
1451    !
1452    iflag_pbl_split_omp = 0
1453    call getin('iflag_pbl_split',iflag_pbl_split_omp)
1454    !
1455    !Config Key  = iflag_order2_sollw
1456    !Config Desc =
1457    !Config Def  = 0
1458    !Config Help =
1459    !
1460    iflag_order2_sollw_omp = 0
1461    CALL getin('iflag_order2_sollw',iflag_order2_sollw_omp)
1462    !
1463    !Config Key  = iflag_thermals
1464    !Config Desc =
1465    !Config Def  = 0
1466    !Config Help =
1467    !
1468    iflag_thermals_omp = 0
1469    CALL getin('iflag_thermals',iflag_thermals_omp)
1470    !
1471    !Config Key  = iflag_thermals_ed
1472    !Config Desc =
1473    !Config Def  = 0
1474    !Config Help =
1475    !
1476    fact_thermals_ed_dz_omp = 0.1
1477
1478    CALL getin('fact_thermals_ed_dz',fact_thermals_ed_dz_omp)
1479    !
1480    !
1481    !Config Key  = iflag_thermals_ed
1482    !Config Desc =
1483    !Config Def  = 0
1484    !Config Help =
1485    !
1486    iflag_thermals_ed_omp = 0
1487    CALL getin('iflag_thermals_ed',iflag_thermals_ed_omp)
1488    !
1489    !
1490    !Config Key  = iflag_thermals_optflux
1491    !Config Desc =
1492    !Config Def  = 0
1493    !Config Help =
1494    !
1495    iflag_thermals_optflux_omp = 0
1496    CALL getin('iflag_thermals_optflux',iflag_thermals_optflux_omp)
1497    !
1498    !Config Key  = iflag_thermals_closure
1499    !Config Desc =
1500    !Config Def  = 0
1501    !Config Help =
1502    !
1503    iflag_thermals_closure_omp = 1
1504    CALL getin('iflag_thermals_closure',iflag_thermals_closure_omp)
1505    !
1506    !Config Key  = nsplit_thermals
1507    !Config Desc =
1508    !Config Def  = 1
1509    !Config Help =
1510    !
1511    nsplit_thermals_omp = 1
1512    CALL getin('nsplit_thermals',nsplit_thermals_omp)
1513
1514    !Config Key  = alp_bl_k
1515    !Config Desc =
1516    !Config Def  = 0.
1517    !Config Help =
1518    !
1519    alp_bl_k_omp = 1.
1520    CALL getin('alp_bl_k',alp_bl_k_omp)
1521
1522    ! nrlmd le 10/04/2012
1523
1524    !Config Key  = iflag_trig_bl
1525    !Config Desc = 
1526    !Config Def  = 0
1527    !Config Help =
1528    !
1529    iflag_trig_bl_omp = 0
1530    CALL getin('iflag_trig_bl',iflag_trig_bl_omp)
1531
1532    !Config Key  = s_trig_bl
1533    !Config Desc = 
1534    !Config Def  = 0
1535    !Config Help =
1536    !
1537    s_trig_omp = 2e7
1538    CALL getin('s_trig',s_trig_omp)
1539
1540    !Config Key  = tau_trig_shallow
1541    !Config Desc = 
1542    !Config Def  = 0
1543    !Config Help =
1544    !
1545    tau_trig_shallow_omp = 600
1546    CALL getin('tau_trig_shallow',tau_trig_shallow_omp)
1547
1548    !Config Key  = tau_trig_deep
1549    !Config Desc = 
1550    !Config Def  = 0
1551    !Config Help =
1552    !
1553    tau_trig_deep_omp = 1800
1554    CALL getin('tau_trig_deep',tau_trig_deep_omp)
1555
1556    !Config Key  = iflag_clos_bl
1557    !Config Desc = 
1558    !Config Def  = 0
1559    !Config Help =
1560    !
1561    iflag_clos_bl_omp = 0
1562    CALL getin('iflag_clos_bl',iflag_clos_bl_omp)
1563
1564    ! fin nrlmd le 10/04/2012
1565
1566    !
1567    !Config Key  = tau_thermals
1568    !Config Desc =
1569    !Config Def  = 0.
1570    !Config Help =
1571    !
1572    tau_thermals_omp = 0.
1573    CALL getin('tau_thermals',tau_thermals_omp)
1574
1575    !
1576    !Config Key  = iflag_coupl
1577    !Config Desc =
1578    !Config Def  = 0
1579    !Config Help =
1580    !
1581    iflag_coupl_omp = 0
1582    CALL getin('iflag_coupl',iflag_coupl_omp)
1583
1584    !
1585    !Config Key  = iflag_clos
1586    !Config Desc = 
1587    !Config Def  = 0
1588    !Config Help =
1589    !
1590    iflag_clos_omp = 1
1591    CALL getin('iflag_clos',iflag_clos_omp)
1592    !
1593    !Config Key  = coef_clos_ls
1594    !Config Desc = 
1595    !Config Def  = 0
1596    !Config Help =
1597    !
1598    coef_clos_ls_omp = 0.
1599    CALL getin('coef_clos_ls',coef_clos_ls_omp)
1600
1601    !
1602    !Config Key  = iflag_cvl_sigd
1603    !Config Desc = 
1604    !Config Def  = 0
1605    !Config Help =
1606    !
1607    iflag_cvl_sigd_omp = 0
1608    CALL getin('iflag_cvl_sigd',iflag_cvl_sigd_omp)
1609
1610    !Config Key  = iflag_wake
1611    !Config Desc = 
1612    !Config Def  = 0
1613    !Config Help =
1614    !
1615    iflag_wake_omp = 0
1616    CALL getin('iflag_wake',iflag_wake_omp)
1617
1618    !Config Key  = alp_offset
1619    !Config Desc = 
1620    !Config Def  = 0
1621    !Config Help =
1622    !
1623    alp_offset_omp = 0.
1624    CALL getin('alp_offset',alp_offset_omp)
1625
1626    !
1627    !Config Key  = lev_histhf
1628    !Config Desc =
1629    !Config Def  = 1
1630    !Config Help =
1631    !
1632    lev_histhf_omp = 1
1633    CALL getin('lev_histhf',lev_histhf_omp)
1634
1635    !
1636    !Config Key  = lev_histday
1637    !Config Desc =
1638    !Config Def  = 1
1639    !Config Help =
1640    !
1641    lev_histday_omp = 1
1642    CALL getin('lev_histday',lev_histday_omp)
1643
1644    !
1645    !Config Key  = lev_histmth
1646    !Config Desc =
1647    !Config Def  = 2
1648    !Config Help =
1649    !
1650    lev_histmth_omp = 2
1651    CALL getin('lev_histmth',lev_histmth_omp)
1652    !
1653    !Config Key  = lev_histins
1654    !Config Desc =
1655    !Config Def  = 1
1656    !Config Help =
1657    !
1658    lev_histins_omp = 1
1659    CALL getin('lev_histins',lev_histins_omp)
1660    !
1661    !Config Key  = lev_histLES
1662    !Config Desc =
1663    !Config Def  = 1
1664    !Config Help =
1665    !
1666    lev_histLES_omp = 1
1667    CALL getin('lev_histLES',lev_histLES_omp)
1668    !
1669    !Config Key  = lev_histdayNMC
1670    !Config Desc =
1671    !Config Def  = 8
1672    !Config Help =
1673    !
1674    lev_histdayNMC_omp = 8
1675    CALL getin('lev_histdayNMC',lev_histdayNMC_omp)
1676    !
1677    !Config Key  = levout_histNMC
1678    !Config Desc =
1679    !Config Def  = 5
1680    !Config Help =
1681    !
1682    levout_histNMC_omp(1) = 5
1683    levout_histNMC_omp(2) = 5
1684    levout_histNMC_omp(3) = 5
1685    CALL getin('levout_histNMC',levout_histNMC_omp)
1686    !
1687    !histNMC BEG
1688    !Config Key  = ok_histNMC
1689    !Config Desc = ok_histNMC(1) = frequence de sortie fichiers histmthNMC
1690    !Config Desc = ok_histNMC(2) = frequence de sortie fichiers histdayNMC
1691    !Config Desc = ok_histNMC(3) = frequence de sortie fichiers histhfNMC
1692    !Config Def  = n, n, n
1693    !Config Help =
1694    !
1695    ok_histNMC_omp(1) = .FALSE.
1696    ok_histNMC_omp(2) = .FALSE.
1697    ok_histNMC_omp(3) = .FALSE.
1698    CALL getin('ok_histNMC',ok_histNMC_omp)
1699    !
1700    !Config Key  = freq_outNMC
1701    !Config Desc = freq_outNMC(1) = frequence de sortie fichiers histmthNMC
1702    !Config Desc = freq_outNMC(2) = frequence de sortie fichiers histdayNMC
1703    !Config Desc = freq_outNMC(3) = frequence de sortie fichiers histhfNMC
1704    !Config Def  = 2592000., 86400., 21600. (1mois, 1jour, 6h)
1705    !Config Help =
1706    !
1707    freq_outNMC_omp(1) = mth_len
1708    freq_outNMC_omp(2) = 1.
1709    freq_outNMC_omp(3) = 1./4.
1710    CALL getin('freq_outNMC',freq_outNMC_omp)
1711    !
1712    !Config Key  = freq_calNMC
1713    !Config Desc = freq_calNMC(1) = frequence de calcul fichiers histmthNMC
1714    !Config Desc = freq_calNMC(2) = frequence de calcul fichiers histdayNMC
1715    !Config Desc = freq_calNMC(3) = frequence de calcul fichiers histhfNMC
1716    !Config Def  = pasphys
1717    !Config Help =
1718    !
1719    freq_calNMC_omp(1) = pasphys
1720    freq_calNMC_omp(2) = pasphys
1721    freq_calNMC_omp(3) = pasphys
1722    CALL getin('freq_calNMC',freq_calNMC_omp)
1723    !
1724    !Config Key  = type_run
1725    !Config Desc =
1726    !Config Def  = 'AMIP'/'CFMIP'  ou 'CLIM'/'ENSP'
1727    !Config Help =
1728    !
1729    type_run_omp = 'AMIP'
1730    CALL getin('type_run',type_run_omp)
1731
1732    !
1733    !Config Key  = ok_cosp
1734    !Config Desc =
1735    !Config Def  = .FALSE.
1736    !Config Help =
1737    !
1738    ok_cosp_omp = .FALSE.
1739    CALL getin('ok_cosp',ok_cosp_omp)
1740
1741    !
1742    !Config Key  = ok_airs
1743    !Config Desc =
1744    !Config Def  = .FALSE.
1745    !Config Help =
1746    !
1747    ok_airs_omp = .FALSE.
1748    CALL getin('ok_airs',ok_airs_omp)
1749
1750    !
1751    !Config Key  = ok_mensuelCOSP
1752    !Config Desc =
1753    !Config Def  = .TRUE.
1754    !Config Help =
1755    !
1756    ok_mensuelCOSP_omp = .TRUE.
1757    CALL getin('ok_mensuelCOSP',ok_mensuelCOSP_omp)
1758
1759    !
1760    !Config Key  = ok_journeCOSP
1761    !Config Desc =
1762    !Config Def  = .TRUE.
1763    !Config Help =
1764    !
1765    ok_journeCOSP_omp = .TRUE.
1766    CALL getin('ok_journeCOSP',ok_journeCOSP_omp)
1767
1768    !
1769    !Config Key  = ok_hfCOSP
1770    !Config Desc =
1771    !Config Def  = .FALSE.
1772    !Config Help =
1773    !
1774    ok_hfCOSP_omp = .FALSE.
1775    CALL getin('ok_hfCOSP',ok_hfCOSP_omp)
1776
1777    !
1778    ! coordonnees (lonmin_ins, lonmax_ins, latmin_ins, latmax_ins) pour la zone
1779    ! avec sorties instantannees tous les pas de temps de la physique => "histbilKP_ins.nc"
1780    !
1781    !Config Key  = lonmin_ins
1782    !Config Desc = 100. 
1783    !Config Def  = longitude minimale sorties "bilKP_ins"
1784    !Config Help =
1785    !
1786    lonmin_ins_omp = 100.
1787    CALL getin('lonmin_ins',lonmin_ins_omp)
1788    !
1789    !Config Key  = lonmax_ins
1790    !Config Desc = 130.
1791    !Config Def  = longitude maximale sorties "bilKP_ins"
1792    !Config Help =
1793    !
1794    lonmax_ins_omp = 130.
1795    CALL getin('lonmax_ins',lonmax_ins_omp)
1796    !
1797    !Config Key  = latmin_ins
1798    !Config Desc = -20. 
1799    !Config Def  = latitude minimale sorties "bilKP_ins"
1800    !Config Help =
1801    !
1802    latmin_ins_omp = -20.
1803    CALL getin('latmin_ins',latmin_ins_omp)
1804    !
1805    !Config Key  = latmax_ins
1806    !Config Desc = 20.
1807    !Config Def  = latitude maximale sorties "bilKP_ins"
1808    !Config Help =
1809    !
1810    latmax_ins_omp = 20.
1811    CALL getin('latmax_ins',latmax_ins_omp)
1812    !
1813    !Config Key  = ecrit_hf
1814    !Config Desc =
1815    !Config Def  = 1./8. !toutes les 3h
1816    !Config Help =
1817    !
1818    ecrit_hf_omp = 1./8.
1819    CALL getin('ecrit_hf',ecrit_hf_omp)
1820    !
1821    !Config Key  = ecrit_ins
1822    !Config Desc =
1823    !Config Def  = 1./48. ! toutes les 1/2 h
1824    !Config Help =
1825    !
1826    ecrit_ins_omp = 1./48.
1827    CALL getin('ecrit_ins',ecrit_ins_omp)
1828    !
1829    !Config Key  = ecrit_day
1830    !Config Desc =
1831    !Config Def  = 1.0 !tous les jours
1832    !Config Help = nombre de jours pour ecriture fichier histday.nc
1833    !
1834    ecrit_day_omp = 1.0
1835    CALL getin('ecrit_day',ecrit_day_omp)
1836    !
1837    !Config Key  = ecrit_mth
1838    !Config Desc =
1839    !Config Def  = 30. !tous les 30jours (1 fois par mois)
1840    !Config Help =
1841    !
1842    ecrit_mth_omp = 30.
1843    CALL getin('ecrit_mth',ecrit_mth_omp)
1844    !
1845    !Config Key  = ecrit_tra
1846    !Config Desc =
1847    !Config Def  = 30. !tous les 30jours (1 fois par mois)
1848    !Config Help =
1849    !
1850    ecrit_tra_omp = 0.
1851    CALL getin('ecrit_tra',ecrit_tra_omp)
1852    !
1853    !Config Key  = ecrit_reg
1854    !Config Desc =
1855    !Config Def  = 0.25  !4 fois par jour
1856    !Config Help =
1857    !
1858    ecrit_reg_omp = 0.25   !4 fois par jour
1859    CALL getin('ecrit_reg',ecrit_reg_omp)
1860    !
1861    !
1862    print*,'CONFPHYS OOK avant drag_ter'
1863    !
1864    ! PARAMETRES CDRAG
1865    !
1866    f_cdrag_ter_omp = 0.8
1867    CALL getin('f_cdrag_ter',f_cdrag_ter_omp)
1868    !
1869    f_cdrag_oce_omp = 0.8
1870    CALL getin('f_cdrag_oce',f_cdrag_oce_omp)
1871    !
1872
1873    ! Gustiness flags
1874    f_z0qh_oce_omp = 1.
1875    CALL getin('f_z0qh_oce',f_z0qh_oce_omp)
1876    !
1877    f_qsat_oce_omp = 1.
1878    CALL getin('f_qsat_oce',f_qsat_oce_omp)
1879    !
1880    f_gust_bl_omp = 0.
1881    CALL getin('f_gust_bl',f_gust_bl_omp)
1882    !
1883    f_gust_wk_omp = 0.
1884    CALL getin('f_gust_wk',f_gust_wk_omp)
1885    !
1886    !Config Key  = iflag_z0_oce
1887    !Config Desc = 0 (z0h=z0m), 1 (diff. equ. for z0h and z0m), -1 (z0m=z0h=z0min)
1888    !Config Def  = 0   ! z0h = z0m
1889    !Config Help =
1890    !
1891    iflag_z0_oce_omp=0
1892    CALL getin('iflag_z0_oce',iflag_z0_oce_omp)
1893    !
1894    iflag_gusts_omp=0
1895    CALL getin('iflag_gusts',iflag_gusts_omp)
1896    !
1897    min_wind_speed_omp = 1.
1898    CALL getin('min_wind_speed',min_wind_speed_omp)
1899
1900    z0m_seaice_omp = 0.002 ; CALL getin('z0m_seaice',z0m_seaice_omp)
1901    z0h_seaice_omp = 0.002 ; CALL getin('z0h_seaice',z0h_seaice_omp)
1902
1903    f_rugoro_omp = 0.
1904    CALL getin('f_rugoro',f_rugoro_omp)
1905
1906    z0min_omp = 0.000015
1907    CALL getin('z0min',z0min_omp)
1908
1909
1910    ! PARAMETERS FOR CONVECTIVE INHIBITION BY TROPOS. DRYNESS
1911    !
1912    !Config Key  = supcrit1
1913    !Config Desc =
1914    !Config Def  = .540
1915    !Config Help =
1916    !
1917    supcrit1_omp = .540
1918    CALL getin('supcrit1',supcrit1_omp)
1919
1920    !
1921    !Config Key  = supcrit2
1922    !Config Desc =
1923    !Config Def  = .600
1924    !Config Help =
1925    !
1926    supcrit2_omp = .600
1927    CALL getin('supcrit2',supcrit2_omp)
1928
1929    !
1930    ! PARAMETERS FOR THE MIXING DISTRIBUTION
1931    ! iflag_mix: 0=OLD,
1932    !            1=NEW (JYG),           
1933    !            2=NEW + conv. depth inhib. by tropos. dryness
1934    ! '2' is NOT operationnal and should not be used.
1935    !
1936    !Config Key  = iflag_mix
1937    !Config Desc =
1938    !Config Def  = 1
1939    !Config Help =
1940    !
1941    iflag_mix_omp = 1
1942    CALL getin('iflag_mix',iflag_mix_omp)
1943
1944!
1945    ! PARAMETERS FOR THE EROSION OF THE ADIABATIC ASCENTS
1946    ! iflag_mix_adiab: 0=OLD,
1947    !                  1=NEW (CR),           
1948    !           
1949    !
1950    !Config Key  = iflag_mix_adiab
1951    !Config Desc =
1952    !Config Def  = 1
1953    !Config Help =
1954    !
1955    iflag_mix_adiab_omp = 0
1956    CALL getin('iflag_mix_adiab',iflag_mix_adiab_omp)
1957
1958    !
1959    !Config Key  = scut
1960    !Config Desc =
1961    !Config Def  = 0.95
1962    !Config Help =
1963    !
1964    scut_omp = 0.95
1965    CALL getin('scut',scut_omp)
1966
1967    !
1968    !Config Key  = qqa1
1969    !Config Desc =
1970    !Config Def  = 1.0
1971    !Config Help =
1972    !
1973    qqa1_omp = 1.0
1974    CALL getin('qqa1',qqa1_omp)
1975
1976    !
1977    !Config Key  = qqa2
1978    !Config Desc =
1979    !Config Def  = 0.0
1980    !Config Help =
1981    !
1982    qqa2_omp = 0.0
1983    CALL getin('qqa2',qqa2_omp)
1984
1985    !
1986    !Config Key  = gammas
1987    !Config Desc =
1988    !Config Def  = 0.05
1989    !Config Help =
1990    !
1991    gammas_omp = 0.05
1992    CALL getin('gammas',gammas_omp)
1993
1994    !
1995    !Config Key  = Fmax
1996    !Config Desc =
1997    !Config Def  = 0.65
1998    !Config Help =
1999    !
2000    Fmax_omp = 0.65
2001    CALL getin('Fmax',Fmax_omp)
2002
2003    !
2004    !Config Key  = tmax_fonte_cv
2005    !Config Desc =
2006    !Config Def  = 275.15
2007    !Config Help =
2008    !
2009    tmax_fonte_cv_omp = 275.15
2010    CALL getin('tmax_fonte_cv',tmax_fonte_cv_omp)
2011
2012    !
2013    !Config Key  = alphas 
2014    !Config Desc =
2015    !Config Def  = -5.
2016    !Config Help =
2017    !
2018    alphas_omp = -5.
2019    CALL getin('alphas',alphas_omp)
2020
2021    !Config key = ok_strato
2022    !Config  Desc = activation de la version strato
2023    !Config  Def  = .FALSE.
2024    !Config  Help = active la version stratosph\'erique de LMDZ de F. Lott
2025    !               Et la sponge layer (Runs Stratospheriques)
2026
2027    ok_strato_omp=.FALSE.
2028    CALL getin('ok_strato',ok_strato_omp)
2029
2030    !Config  key = ok_hines
2031    !Config  Desc = activation de la parametrisation de hines
2032    !Config  Def  = .FALSE.
2033    !Config  Help = Clefs controlant la parametrization de Hines
2034
2035    ok_hines_omp=.FALSE.
2036    CALL getin('ok_hines',ok_hines_omp)
2037
2038    !  Parametres pour les ondes de gravite
2039    ! 
2040    !  Subgrid Scale Orography (Lott Miller (1997), Lott (1999))
2041
2042    sso_gkdrag_omp = merge(0.1875, 0.2, ok_strato_omp)
2043    CALL getin('sso_gkdrag', sso_gkdrag_omp)
2044
2045    sso_grahil_omp=merge(0.1,1.,ok_strato_omp)
2046    CALL getin('sso_grahil', sso_grahil_omp)
2047
2048    sso_grcrit_omp =merge(1.,0.01,ok_strato_omp)
2049    CALL getin('sso_grcrit', sso_grcrit_omp)
2050
2051    sso_gfrcri_omp = 1.
2052    CALL getin('sso_gfrcri', sso_gfrcri_omp)
2053
2054    sso_gkwake_omp = 0.50
2055    CALL getin('sso_gkwake', sso_gkwake_omp)
2056
2057    sso_gklift_omp = merge(0.25,0.50,ok_strato_omp)
2058    CALL getin('sso_gklift', sso_gklift_omp)
2059
2060    ! Random gravity waves:
2061
2062    ok_gwd_rando_omp = .FALSE.
2063    IF ( klon_glo == 1 ) THEN
2064       print*,'La parametrisation des ondes de gravites non orographiques'
2065       print*,'ne fonctionne pas en 1D'
2066    ELSE
2067       CALL getin('ok_gwd_rando', ok_gwd_rando_omp)
2068    ENDIF
2069
2070    gwd_rando_ruwmax_omp = 2.00
2071    CALL getin('gwd_rando_ruwmax', gwd_rando_ruwmax_omp)
2072
2073    gwd_rando_sat_omp = 0.25
2074    CALL getin('gwd_rando_sat', gwd_rando_sat_omp)
2075
2076    gwd_front_ruwmax_omp = 2.50
2077    CALL getin('gwd_front_ruwmax', gwd_front_ruwmax_omp)
2078
2079    gwd_front_sat_omp = 0.60
2080    CALL getin('gwd_front_sat', gwd_front_sat_omp)
2081
2082
2083    !Config  key = ok_qch4
2084    !Config  Desc = activation de la parametrisation du methane
2085    !Config  Def  = .FALSE.
2086    !Config  Help = Clef controlant l'activation de la parametrisation
2087    !               de l'humidite due a oxydation+photolyse du methane strato
2088
2089    ok_qch4_omp=.FALSE.
2090    CALL getin('ok_qch4',ok_qch4_omp)
2091
2092    !Config Key  = OK_LES                                               
2093    !Config Desc = Pour des sorties LES                                 
2094    !Config Def  = .FALSE.                                             
2095    !Config Help = Pour creer le fichier histLES contenant les sorties 
2096    !              LES                                                 
2097    !                                                                   
2098    ok_LES_omp = .FALSE.                                             
2099    CALL getin('OK_LES', ok_LES_omp)                                 
2100
2101    !Config Key  = callstats                                               
2102    !Config Desc = Pour des sorties callstats                                 
2103    !Config Def  = .FALSE.                                             
2104    !Config Help = Pour creer le fichier stats contenant les sorties 
2105    !              stats                                                 
2106    !                                                                   
2107    callstats_omp = .FALSE.                                             
2108    CALL getin('callstats', callstats_omp)                                 
2109    !
2110    !Config Key  = ecrit_LES
2111    !Config Desc = Frequence d'ecriture des resultats du LES en nombre de jours;
2112    !              par defaut 1., i.e. 1 jour
2113    !Config Def  = 1./8.
2114    !Config Help = ...
2115    !
2116    !
2117    adjust_tropopause = .FALSE.
2118    CALL getin('adjust_tropopause', adjust_tropopause_omp)
2119    !
2120    !Config Key  = adjust_tropopause
2121    !Config Desc = Adjust the ozone field from the climoz file by stretching its
2122    !              tropopause so that it matches the one of LMDZ.
2123    !Config Def  = .FALSE.
2124    !Config Help = Ensure tropospheric ozone column conservation.
2125    !
2126    !
2127    ok_daily_climoz = .FALSE.
2128    CALL getin('ok_daily_climoz', ok_daily_climoz_omp)
2129    !
2130    !Config Key  = ok_daily_climoz
2131    !Config Desc = Interpolate in time the ozone forcings within ce0l.
2132    !              .TRUE. if backward compatibility is needed.
2133    !Config Def  = .TRUE.
2134    !Config Help = .FALSE. ensure much fewer (no calendar dependency)
2135    !  and lighter monthly climoz files, inetrpolated in time at gcm run time.
2136    !
2137    ecrit_LES_omp = 1./8.
2138    CALL getin('ecrit_LES', ecrit_LES_omp)
2139    !
2140    read_climoz = 0 ! default value
2141    CALL getin('read_climoz', read_climoz)
2142
2143    carbon_cycle_tr_omp=.FALSE.
2144    CALL getin('carbon_cycle_tr',carbon_cycle_tr_omp)
2145
2146    carbon_cycle_cpl_omp=.FALSE.
2147    CALL getin('carbon_cycle_cpl',carbon_cycle_cpl_omp)
2148
2149    !$OMP END MASTER
2150    !$OMP BARRIER
2151
2152    R_ecc = R_ecc_omp
2153    R_peri = R_peri_omp
2154    R_incl = R_incl_omp
2155    solaire = solaire_omp
2156    ok_suntime_rrtm = ok_suntime_rrtm_omp
2157    co2_ppm = co2_ppm_omp
2158    RCO2 = RCO2_omp
2159    CH4_ppb = CH4_ppb_omp
2160    RCH4 = RCH4_omp
2161    N2O_ppb = N2O_ppb_omp
2162    RN2O = RN2O_omp
2163    CFC11_ppt = CFC11_ppt_omp
2164    RCFC11 = RCFC11_omp
2165    CFC12_ppt = CFC12_ppt_omp
2166    RCFC12 = RCFC12_omp
2167    RCO2_act = RCO2
2168    RCH4_act = RCH4
2169    RN2O_act = RN2O
2170    RCFC11_act = RCFC11
2171    RCFC12_act = RCFC12
2172    RCO2_per = RCO2_per_omp
2173    RCH4_per = RCH4_per_omp
2174    RN2O_per = RN2O_per_omp
2175    RCFC11_per = RCFC11_per_omp
2176    RCFC12_per = RCFC12_per_omp
2177
2178    iflag_cycle_diurne = iflag_cycle_diurne_omp
2179    soil_model = soil_model_omp
2180    new_oliq = new_oliq_omp
2181    ok_orodr = ok_orodr_omp
2182    ok_orolf = ok_orolf_omp
2183    ok_limitvrai = ok_limitvrai_omp
2184    nbapp_rad = nbapp_rad_omp
2185    iflag_con = iflag_con_omp
2186    nbapp_cv = nbapp_cv_omp
2187    nbapp_wk = nbapp_wk_omp
2188    iflag_ener_conserv = iflag_ener_conserv_omp
2189    ok_conserv_q = ok_conserv_q_omp
2190    iflag_fisrtilp_qsat = iflag_fisrtilp_qsat_omp
2191    iflag_bergeron = iflag_bergeron_omp
2192
2193    epmax = epmax_omp
2194    coef_epmax_cape = coef_epmax_cape_omp
2195    ok_adj_ema = ok_adj_ema_omp
2196    iflag_clw = iflag_clw_omp
2197    cld_lc_lsc = cld_lc_lsc_omp
2198    cld_lc_con = cld_lc_con_omp
2199    cld_tau_lsc = cld_tau_lsc_omp
2200    cld_tau_con = cld_tau_con_omp
2201    ffallv_lsc = ffallv_lsc_omp
2202    ffallv_con = ffallv_con_omp
2203    coef_eva = coef_eva_omp
2204    reevap_ice = reevap_ice_omp
2205    iflag_pdf = iflag_pdf_omp
2206    solarlong0 = solarlong0_omp
2207    qsol0 = qsol0_omp
2208    evap0 = evap0_omp
2209    albsno0 = albsno0_omp
2210    iflag_sic = iflag_sic_omp
2211    inertie_sol = inertie_sol_omp
2212    inertie_sic = inertie_sic_omp
2213    inertie_lic = inertie_lic_omp
2214    inertie_sno = inertie_sno_omp
2215    rad_froid = rad_froid_omp
2216    rad_chau1 = rad_chau1_omp
2217    rad_chau2 = rad_chau2_omp
2218    t_glace_min = t_glace_min_omp
2219    t_glace_max = t_glace_max_omp
2220    exposant_glace = exposant_glace_omp
2221    iflag_t_glace = iflag_t_glace_omp
2222    iflag_cloudth_vert=iflag_cloudth_vert_omp
2223    iflag_rain_incloud_vol=iflag_rain_incloud_vol_omp
2224    iflag_ice_thermo = iflag_ice_thermo_omp
2225    rei_min = rei_min_omp
2226    rei_max = rei_max_omp
2227    top_height = top_height_omp
2228    overlap = overlap_omp
2229    cdmmax = cdmmax_omp
2230    cdhmax = cdhmax_omp
2231    ksta = ksta_omp
2232    ksta_ter = ksta_ter_omp
2233    f_ri_cd_min = f_ri_cd_min_omp
2234    ok_kzmin = ok_kzmin_omp
2235    pbl_lmixmin_alpha=pbl_lmixmin_alpha_omp
2236    fmagic = fmagic_omp
2237    pmagic = pmagic_omp
2238    iflag_pbl = iflag_pbl_omp
2239    iflag_pbl_split = iflag_pbl_split_omp
2240!FC
2241    ifl_pbltree = ifl_pbltree_omp
2242    Cd_frein    =Cd_frein_omp
2243    iflag_order2_sollw = iflag_order2_sollw_omp
2244    lev_histhf = lev_histhf_omp
2245    lev_histday = lev_histday_omp
2246    lev_histmth = lev_histmth_omp
2247    lev_histins = lev_histins_omp
2248    lev_histLES = lev_histLES_omp
2249    lev_histdayNMC = lev_histdayNMC_omp
2250    levout_histNMC = levout_histNMC_omp
2251    ok_histNMC(:) = ok_histNMC_omp(:)
2252    freq_outNMC(:) = freq_outNMC_omp(:)
2253    freq_calNMC(:) = freq_calNMC_omp(:)
2254
2255    type_ocean = type_ocean_omp
2256    version_ocean = version_ocean_omp
2257    t_coupl = t_coupl_omp
2258
2259    ok_veget=.TRUE.
2260    type_veget=type_veget_omp
2261    IF (type_veget=='n' .or. type_veget=='bucket' .or. type_veget=='betaclim') THEN
2262       ok_veget=.FALSE.
2263    ENDIF
2264    ! Martin
2265    ok_snow = ok_snow_omp
2266    ! Martin
2267
2268    ok_all_xml = ok_all_xml_omp
2269    ok_lwoff = ok_lwoff_omp
2270    ok_newmicro = ok_newmicro_omp
2271    ok_journe = ok_journe_omp
2272    ok_hf = ok_hf_omp
2273    ok_mensuel = ok_mensuel_omp
2274    ok_instan = ok_instan_omp
2275    freq_ISCCP = freq_ISCCP_omp
2276    ecrit_ISCCP = ecrit_ISCCP_omp
2277    freq_COSP = freq_COSP_omp
2278    freq_AIRS = freq_AIRS_omp
2279    ok_ade = ok_ade_omp
2280    ok_aie = ok_aie_omp
2281    ok_alw = ok_alw_omp
2282    ok_cdnc = ok_cdnc_omp
2283    aerosol_couple = aerosol_couple_omp
2284    chemistry_couple = chemistry_couple_omp
2285    flag_aerosol=flag_aerosol_omp
2286    flag_aerosol_strat=flag_aerosol_strat_omp
2287    flag_bc_internal_mixture=flag_bc_internal_mixture_omp
2288    new_aod=new_aod_omp
2289    aer_type = aer_type_omp
2290    bl95_b0 = bl95_b0_omp
2291    bl95_b1 = bl95_b1_omp
2292    fact_cldcon = fact_cldcon_omp
2293    facttemps = facttemps_omp
2294    ratqsbas = ratqsbas_omp
2295    ratqshaut = ratqshaut_omp
2296    tau_ratqs = tau_ratqs_omp
2297
2298    iflag_radia = iflag_radia_omp
2299    iflag_rrtm = iflag_rrtm_omp
2300    iflag_albedo = iflag_albedo_omp
2301    ok_chlorophyll = ok_chlorophyll_omp
2302    NSW = NSW_omp
2303    iflag_cld_th = iflag_cld_th_omp
2304    iflag_cld_cv = iflag_cld_cv_omp
2305    tau_cld_cv = tau_cld_cv_omp
2306    coefw_cld_cv = coefw_cld_cv_omp
2307    iflag_ratqs = iflag_ratqs_omp
2308    ip_ebil_phy = ip_ebil_phy_omp
2309    iflag_thermals = iflag_thermals_omp
2310    iflag_thermals_ed = iflag_thermals_ed_omp
2311    fact_thermals_ed_dz = fact_thermals_ed_dz_omp
2312    iflag_thermals_optflux = iflag_thermals_optflux_omp
2313    iflag_thermals_closure = iflag_thermals_closure_omp
2314    nsplit_thermals = nsplit_thermals_omp
2315    tau_thermals = tau_thermals_omp
2316    alp_bl_k = alp_bl_k_omp
2317    ! nrlmd le 10/04/2012
2318    iflag_trig_bl = iflag_trig_bl_omp
2319    s_trig = s_trig_omp
2320    tau_trig_shallow = tau_trig_shallow_omp
2321    tau_trig_deep = tau_trig_deep_omp
2322    iflag_clos_bl = iflag_clos_bl_omp
2323    ! fin nrlmd le 10/04/2012
2324    iflag_coupl = iflag_coupl_omp
2325    iflag_clos = iflag_clos_omp
2326    iflag_wake = iflag_wake_omp
2327    coef_clos_ls = coef_clos_ls_omp
2328    alp_offset = alp_offset_omp
2329    iflag_cvl_sigd = iflag_cvl_sigd_omp
2330    type_run = type_run_omp
2331    ok_cosp = ok_cosp_omp
2332    ok_airs = ok_airs_omp
2333
2334    ok_mensuelCOSP = ok_mensuelCOSP_omp
2335    ok_journeCOSP = ok_journeCOSP_omp
2336    ok_hfCOSP = ok_hfCOSP_omp
2337    seuil_inversion=seuil_inversion_omp
2338    lonmin_ins = lonmin_ins_omp
2339    lonmax_ins = lonmax_ins_omp
2340    latmin_ins = latmin_ins_omp
2341    latmax_ins = latmax_ins_omp
2342    ecrit_hf   = ecrit_hf_omp
2343    ecrit_ins   = ecrit_ins_omp
2344    ecrit_day = ecrit_day_omp
2345    ecrit_mth = ecrit_mth_omp
2346    ecrit_tra = ecrit_tra_omp
2347    ecrit_reg = ecrit_reg_omp
2348    cvl_comp_threshold = cvl_comp_threshold_omp
2349    cvl_sig2feed = cvl_sig2feed_omp
2350    cvl_corr = cvl_corr_omp
2351    ok_lic_melt = ok_lic_melt_omp
2352    ok_lic_cond = ok_lic_cond_omp
2353    f_cdrag_ter=f_cdrag_ter_omp
2354    f_cdrag_oce=f_cdrag_oce_omp
2355
2356    f_gust_wk=f_gust_wk_omp
2357    f_gust_bl=f_gust_bl_omp
2358    f_qsat_oce=f_qsat_oce_omp
2359    f_z0qh_oce=f_z0qh_oce_omp
2360    min_wind_speed=min_wind_speed_omp
2361    iflag_gusts=iflag_gusts_omp
2362    iflag_z0_oce=iflag_z0_oce_omp
2363
2364    z0m_seaice=z0m_seaice_omp
2365    z0h_seaice=z0h_seaice_omp
2366
2367    f_rugoro=f_rugoro_omp
2368
2369    z0min=z0min_omp
2370    supcrit1 = supcrit1_omp
2371    supcrit2 = supcrit2_omp
2372    iflag_mix = iflag_mix_omp
2373    iflag_mix_adiab = iflag_mix_adiab_omp
2374    scut = scut_omp
2375    qqa1 = qqa1_omp
2376    qqa2 = qqa2_omp
2377    gammas = gammas_omp
2378    Fmax = Fmax_omp
2379    tmax_fonte_cv = tmax_fonte_cv_omp
2380    alphas = alphas_omp
2381
2382    gkdrag=sso_gkdrag_omp
2383    grahilo=sso_grahil_omp
2384    grcrit=sso_grcrit_omp
2385    gfrcrit=sso_gfrcri_omp
2386    gkwake=sso_gkwake_omp
2387    gklift=sso_gklift_omp
2388
2389    ok_strato = ok_strato_omp
2390    ok_hines = ok_hines_omp
2391    ok_gwd_rando = ok_gwd_rando_omp
2392    gwd_rando_ruwmax = gwd_rando_ruwmax_omp
2393    gwd_rando_sat = gwd_rando_sat_omp
2394    gwd_front_ruwmax = gwd_front_ruwmax_omp
2395    gwd_front_sat = gwd_front_sat_omp
2396    ok_qch4 = ok_qch4_omp
2397    ok_LES = ok_LES_omp
2398    callstats = callstats_omp
2399    ecrit_LES = ecrit_LES_omp
2400    adjust_tropopause = adjust_tropopause_omp
2401    ok_daily_climoz = ok_daily_climoz_omp
2402    carbon_cycle_tr = carbon_cycle_tr_omp
2403    carbon_cycle_cpl = carbon_cycle_cpl_omp
2404
2405    ! Test of coherence between type_ocean and version_ocean
2406    IF (type_ocean=='couple' .AND. (version_ocean/='opa8' .AND. version_ocean/='nemo') ) THEN
2407       WRITE(lunout,*)' ERROR version_ocean=',version_ocean,' not valid in coupled configuration'
2408       CALL abort_physic('conf_phys','version_ocean not valid',1)
2409    ENDIF
2410
2411    IF (type_ocean=='slab' .AND. version_ocean=='xxxxxx') THEN
2412       version_ocean='sicOBS'
2413    ELSE IF (type_ocean=='slab' .AND. version_ocean/='sicOBS' &
2414         .AND. version_ocean/='sicINT' .AND. version_ocean/='sicNO') THEN
2415       WRITE(lunout,*)' ERROR version_ocean=',version_ocean,' not valid with slab ocean'
2416       CALL abort_physic('conf_phys','version_ocean not valid',1)
2417    ENDIF
2418
2419    !--test on radiative scheme
2420    IF (iflag_rrtm .EQ. 0) THEN
2421      IF (NSW.NE.2) THEN
2422        WRITE(lunout,*) ' ERROR iflag_rrtm=0 and NSW<>2 not possible'
2423        CALL abort_physic('conf_phys','choice NSW not valid',1)
2424      ENDIF
2425    ELSE IF (iflag_rrtm .EQ. 1) THEN
2426      IF (NSW.NE.2.AND.NSW.NE.4.AND.NSW.NE.6) THEN
2427        WRITE(lunout,*) ' ERROR iflag_rrtm=1 and NSW<>2,4,6 not possible'
2428        CALL abort_physic('conf_phys','choice NSW not valid',1)
2429      ENDIF
2430    ELSE
2431       WRITE(lunout,*) ' ERROR iflag_rrtm<>0,1'
2432       CALL abort_physic('conf_phys','choice iflag_rrtm not valid',1)
2433    ENDIF
2434#ifdef CPP_StratAer
2435    IF (iflag_rrtm .NE. 1) THEN
2436       WRITE(lunout,*) ' ERROR iflag_rrtm<>1 but StratAer activated'
2437       CALL abort_physic('conf_phys','iflag_rrtm not valid for StratAer',1)
2438    ENDIF
2439    IF (NSW .NE. 6) THEN
2440       WRITE(lunout,*) ' ERROR NSW<>6 but StratAer activated'
2441       CALL abort_physic('conf_phys','NSW not valid for StratAer',1)
2442    ENDIF
2443#endif
2444
2445    !--test on ocean surface albedo
2446    IF (iflag_albedo.LT.0.OR.iflag_albedo.GT.2) THEN
2447       WRITE(lunout,*) ' ERROR iflag_albedo<>0,1'
2448       CALL abort_physic('conf_phys','choice iflag_albedo not valid',1)
2449    ENDIF
2450
2451    ! Test sur new_aod. Ce flag permet de retrouver les resultats de l'AR4
2452    ! il n'est utilisable que lors du couplage avec le SO4 seul
2453    IF (ok_ade .OR. ok_aie) THEN
2454       IF ( flag_aerosol .EQ. 0 ) THEN
2455          CALL abort_physic('conf_phys','flag_aerosol=0 not compatible avec ok_ade ou ok_aie=.TRUE.',1)
2456       ENDIF
2457       IF ( .NOT. new_aod .AND.  flag_aerosol .NE. 1) THEN
2458          CALL abort_physic('conf_phys','new_aod=.FALSE. not compatible avec flag_aerosol=1',1)
2459       ENDIF
2460    ENDIF
2461
2462    ! Flag_aerosol cannot be to zero if we are in coupled mode for aerosol
2463    IF (aerosol_couple .AND. flag_aerosol .EQ. 0 ) THEN
2464       CALL abort_physic('conf_phys', 'flag_aerosol cannot be to zero if aerosol_couple=y ', 1)
2465    ENDIF
2466
2467    ! Read_climoz need to be zero if we are in couple mode for chemistry
2468    IF (chemistry_couple .AND. read_climoz .ne. 0) THEN
2469       CALL abort_physic('conf_phys', 'read_climoz need to be to zero if chemistry_couple=y ', 1)
2470    ENDIF
2471
2472
2473    ! flag_aerosol need to be different to zero if ok_cdnc is activated
2474    IF (ok_cdnc .AND. flag_aerosol .EQ. 0) THEN
2475       CALL abort_physic('conf_phys', 'flag_aerosol cannot be to zero if ok_cdnc is activated ', 1)
2476    ENDIF
2477
2478    ! ok_cdnc must be set to y if ok_aie is activated
2479    IF (ok_aie .AND. .NOT. ok_cdnc) THEN
2480       CALL abort_physic('conf_phys', 'ok_cdnc must be set to y if ok_aie is activated',1)
2481    ENDIF
2482
2483    ! flag_aerosol=7 => MACv2SP climatology
2484    IF (flag_aerosol.EQ.7.AND. iflag_rrtm.NE.1) THEN
2485       CALL abort_physic('conf_phys', 'flag_aerosol=7 (MACv2SP) can only be activated with RRTM',1)
2486    ENDIF
2487    IF (flag_aerosol.EQ.7.AND. NSW.NE.6) THEN
2488       CALL abort_physic('conf_phys', 'flag_aerosol=7 (MACv2SP) can only be activated with NSW=6',1)
2489    ENDIF
2490
2491    ! BC internal mixture is only possible with RRTM & NSW=6 & flag_aerosol=6 or aerosol_couple
2492    IF (flag_bc_internal_mixture .AND. NSW.NE.6) THEN
2493       CALL abort_physic('conf_phys', 'flag_bc_internal_mixture can only be activated with NSW=6',1)
2494    ENDIF
2495    IF (flag_bc_internal_mixture .AND. iflag_rrtm.NE.1) THEN
2496       CALL abort_physic('conf_phys', 'flag_bc_internal_mixture can only be activated with RRTM',1)
2497    ENDIF
2498    IF (flag_bc_internal_mixture .AND. flag_aerosol.NE.6) THEN
2499       CALL abort_physic('conf_phys', 'flag_bc_internal_mixture can only be activated with flag_aerosol=6',1)
2500    ENDIF
2501
2502    ! ORCHIDEE must be activated for ifl_pbltree=1
2503    IF (.NOT. ok_veget .AND. ifl_pbltree==1) THEN
2504       WRITE(lunout,*)'Warning: ORCHIDEE must be activated for ifl_pbltree=1'
2505       WRITE(lunout,*)'ifl_pbltree is now changed to zero'
2506       ifl_pbltree=0
2507    END IF
2508
2509    !$OMP MASTER
2510
2511    write(lunout,*)' ##############################################'
2512    write(lunout,*)' Configuration des parametres de la physique: '
2513    write(lunout,*)' Type ocean = ', type_ocean
2514    write(lunout,*)' Version ocean = ', version_ocean
2515    write(lunout,*)' Config veget = ', ok_veget,type_veget
2516    write(lunout,*)' Snow model SISVAT : ok_snow = ', ok_snow
2517    write(lunout,*)' Config xml pour XIOS : ok_all_xml = ', ok_all_xml
2518    write(lunout,*)' Sortie journaliere = ', ok_journe
2519    write(lunout,*)' Sortie haute frequence = ', ok_hf
2520    write(lunout,*)' Sortie mensuelle = ', ok_mensuel
2521    write(lunout,*)' Sortie instantanee = ', ok_instan
2522    write(lunout,*)' Frequence appel simulateur ISCCP, freq_ISCCP =', freq_ISCCP
2523    write(lunout,*)' Frequence appel simulateur ISCCP, ecrit_ISCCP =', ecrit_ISCCP
2524    write(lunout,*)' Frequence appel simulateur COSP, freq_COSP =', freq_COSP
2525    write(lunout,*)' Frequence appel simulateur AIRS, freq_AIRS =', freq_AIRS
2526    write(lunout,*)' Sortie bilan d''energie, ip_ebil_phy =', ip_ebil_phy
2527    write(lunout,*)' Excentricite = ',R_ecc
2528    write(lunout,*)' Equinoxe = ',R_peri
2529    write(lunout,*)' Inclinaison =',R_incl
2530    write(lunout,*)' Constante solaire =',solaire
2531    write(lunout,*)' ok_suntime_rrtm =',ok_suntime_rrtm
2532    write(lunout,*)' co2_ppm =',co2_ppm
2533    write(lunout,*)' RCO2_act = ',RCO2_act
2534    write(lunout,*)' CH4_ppb =',CH4_ppb,' RCH4_act = ',RCH4_act
2535    write(lunout,*)' N2O_ppb =',N2O_ppb,' RN2O_act=  ',RN2O_act
2536    write(lunout,*)' CFC11_ppt=',CFC11_ppt,' RCFC11_act=  ',RCFC11_act
2537    write(lunout,*)' CFC12_ppt=',CFC12_ppt,' RCFC12_act=  ',RCFC12_act
2538    write(lunout,*)' RCO2_per = ',RCO2_per,' RCH4_per = ', RCH4_per
2539    write(lunout,*)' RN2O_per = ',RN2O_per,' RCFC11_per = ', RCFC11_per
2540    write(lunout,*)' RCFC12_per = ',RCFC12_per
2541    write(lunout,*)' cvl_comp_threshold=', cvl_comp_threshold
2542    write(lunout,*)' cvl_sig2feed=', cvl_sig2feed
2543    write(lunout,*)' cvl_corr=', cvl_corr
2544    write(lunout,*)'ok_lic_melt=', ok_lic_melt
2545    write(lunout,*)'ok_lic_cond=', ok_lic_cond
2546    write(lunout,*)'iflag_cycle_diurne=',iflag_cycle_diurne
2547    write(lunout,*)'soil_model=',soil_model
2548    write(lunout,*)'new_oliq=',new_oliq
2549    write(lunout,*)'ok_orodr=',ok_orodr
2550    write(lunout,*)'ok_orolf=',ok_orolf
2551    write(lunout,*)'ok_limitvrai=',ok_limitvrai
2552    write(lunout,*)'nbapp_rad=',nbapp_rad
2553    write(lunout,*)'iflag_con=',iflag_con
2554    write(lunout,*)'nbapp_cv=',nbapp_cv
2555    write(lunout,*)'nbapp_wk=',nbapp_wk
2556    write(lunout,*)'iflag_ener_conserv=',iflag_ener_conserv
2557    write(lunout,*)'ok_conserv_q=',ok_conserv_q
2558    write(lunout,*)'iflag_fisrtilp_qsat=',iflag_fisrtilp_qsat
2559    write(lunout,*)'iflag_bergeron=',iflag_bergeron
2560    write(lunout,*)' epmax = ', epmax
2561    write(lunout,*)' coef_epmax_cape = ', coef_epmax_cape
2562    write(lunout,*)' ok_adj_ema = ', ok_adj_ema
2563    write(lunout,*)' iflag_clw = ', iflag_clw
2564    write(lunout,*)' cld_lc_lsc = ', cld_lc_lsc
2565    write(lunout,*)' cld_lc_con = ', cld_lc_con
2566    write(lunout,*)' cld_tau_lsc = ', cld_tau_lsc
2567    write(lunout,*)' cld_tau_con = ', cld_tau_con
2568    write(lunout,*)' ffallv_lsc = ', ffallv_lsc
2569    write(lunout,*)' ffallv_con = ', ffallv_con
2570    write(lunout,*)' coef_eva = ', coef_eva
2571    write(lunout,*)' reevap_ice = ', reevap_ice
2572    write(lunout,*)' iflag_pdf = ', iflag_pdf
2573    write(lunout,*)' iflag_cld_th = ', iflag_cld_th
2574    write(lunout,*)' iflag_cld_cv = ', iflag_cld_cv
2575    write(lunout,*)' tau_cld_cv = ', tau_cld_cv
2576    write(lunout,*)' coefw_cld_cv = ', coefw_cld_cv
2577    write(lunout,*)' iflag_radia = ', iflag_radia
2578    write(lunout,*)' iflag_rrtm = ', iflag_rrtm
2579    write(lunout,*)' NSW = ', NSW
2580    write(lunout,*)' iflag_albedo = ', iflag_albedo !albedo SB
2581    write(lunout,*)' ok_chlorophyll =',ok_chlorophyll ! albedo SB
2582    write(lunout,*)' iflag_ratqs = ', iflag_ratqs
2583    write(lunout,*)' seuil_inversion = ', seuil_inversion
2584    write(lunout,*)' fact_cldcon = ', fact_cldcon
2585    write(lunout,*)' facttemps = ', facttemps
2586    write(lunout,*)' ok_newmicro = ',ok_newmicro
2587    write(lunout,*)' ratqsbas = ',ratqsbas
2588    write(lunout,*)' ratqshaut = ',ratqshaut
2589    write(lunout,*)' tau_ratqs = ',tau_ratqs
2590    write(lunout,*)' top_height = ',top_height
2591    write(lunout,*)' rad_froid = ',rad_froid
2592    write(lunout,*)' rad_chau1 = ',rad_chau1
2593    write(lunout,*)' rad_chau2 = ',rad_chau2
2594    write(lunout,*)' t_glace_min = ',t_glace_min
2595    write(lunout,*)' t_glace_max = ',t_glace_max
2596    write(lunout,*)' exposant_glace = ',exposant_glace
2597    write(lunout,*)' iflag_t_glace = ',iflag_t_glace
2598    write(lunout,*)' iflag_cloudth_vert = ',iflag_cloudth_vert
2599    write(lunout,*)' iflag_rain_incloud_vol = ',iflag_rain_incloud_vol
2600    write(lunout,*)' iflag_ice_thermo = ',iflag_ice_thermo
2601    write(lunout,*)' rei_min = ',rei_min
2602    write(lunout,*)' rei_max = ',rei_max
2603    write(lunout,*)' overlap = ',overlap
2604    write(lunout,*)' cdmmax = ',cdmmax
2605    write(lunout,*)' cdhmax = ',cdhmax
2606    write(lunout,*)' ksta = ',ksta
2607    write(lunout,*)' ksta_ter = ',ksta_ter
2608    write(lunout,*)' f_ri_cd_min = ',f_ri_cd_min
2609    write(lunout,*)' ok_kzmin = ',ok_kzmin
2610    write(lunout,*)' pbl_lmixmin_alpha = ',pbl_lmixmin_alpha
2611    write(lunout,*)' fmagic = ',fmagic
2612    write(lunout,*)' pmagic = ',pmagic
2613    write(lunout,*)' ok_ade = ',ok_ade
2614    write(lunout,*)' ok_aie = ',ok_aie
2615    write(lunout,*)' ok_alw = ',ok_alw
2616    write(lunout,*)' aerosol_couple = ', aerosol_couple
2617    write(lunout,*)' chemistry_couple = ', chemistry_couple
2618    write(lunout,*)' flag_aerosol = ', flag_aerosol
2619    write(lunout,*)' flag_aerosol_strat= ', flag_aerosol_strat
2620    write(lunout,*)' new_aod = ', new_aod
2621    write(lunout,*)' aer_type = ',aer_type
2622    write(lunout,*)' bl95_b0 = ',bl95_b0
2623    write(lunout,*)' bl95_b1 = ',bl95_b1
2624    write(lunout,*)' lev_histhf = ',lev_histhf
2625    write(lunout,*)' lev_histday = ',lev_histday
2626    write(lunout,*)' lev_histmth = ',lev_histmth
2627    write(lunout,*)' lev_histins = ',lev_histins
2628    write(lunout,*)' lev_histLES = ',lev_histLES
2629    write(lunout,*)' lev_histdayNMC = ',lev_histdayNMC
2630    write(lunout,*)' levout_histNMC = ',levout_histNMC
2631    write(lunout,*)' ok_histNMC = ',ok_histNMC
2632    write(lunout,*)' freq_outNMC = ',freq_outNMC
2633    write(lunout,*)' freq_calNMC = ',freq_calNMC
2634    write(lunout,*)' iflag_pbl = ', iflag_pbl
2635!FC
2636    write(lunout,*)' ifl_pbltree = ', ifl_pbltree
2637    write(lunout,*)' Cd_frein = ', Cd_frein
2638    write(lunout,*)' iflag_pbl_split = ', iflag_pbl_split
2639    write(lunout,*)' iflag_order2_sollw = ', iflag_order2_sollw
2640    write(lunout,*)' iflag_thermals = ', iflag_thermals
2641    write(lunout,*)' iflag_thermals_ed = ', iflag_thermals_ed
2642    write(lunout,*)' fact_thermals_ed_dz = ', fact_thermals_ed_dz
2643    write(lunout,*)' iflag_thermals_optflux = ', iflag_thermals_optflux
2644    write(lunout,*)' iflag_thermals_closure = ', iflag_thermals_closure
2645    write(lunout,*)' iflag_clos = ', iflag_clos
2646    write(lunout,*)' coef_clos_ls = ', coef_clos_ls
2647    write(lunout,*)' type_run = ',type_run
2648    write(lunout,*)' ok_cosp = ',ok_cosp
2649    write(lunout,*)' ok_airs = ',ok_airs
2650
2651    write(lunout,*)' ok_mensuelCOSP = ',ok_mensuelCOSP
2652    write(lunout,*)' ok_journeCOSP = ',ok_journeCOSP
2653    write(lunout,*)' ok_hfCOSP =',ok_hfCOSP
2654    write(lunout,*)' solarlong0 = ', solarlong0
2655    write(lunout,*)' qsol0 = ', qsol0
2656    write(lunout,*)' evap0 = ', evap0
2657    write(lunout,*)' albsno0 = ', albsno0
2658    write(lunout,*)' iflag_sic = ', iflag_sic
2659    write(lunout,*)' inertie_sol = ', inertie_sol
2660    write(lunout,*)' inertie_sic = ', inertie_sic
2661    write(lunout,*)' inertie_lic = ', inertie_lic
2662    write(lunout,*)' inertie_sno = ', inertie_sno
2663    write(lunout,*)' f_cdrag_ter = ',f_cdrag_ter
2664    write(lunout,*)' f_cdrag_oce = ',f_cdrag_oce
2665    write(lunout,*)' f_rugoro = ',f_rugoro
2666    write(lunout,*)' z0min = ',z0min
2667    write(lunout,*)' supcrit1 = ', supcrit1
2668    write(lunout,*)' supcrit2 = ', supcrit2
2669    write(lunout,*)' iflag_mix = ', iflag_mix
2670    write(lunout,*)' iflag_mix_adiab = ', iflag_mix_adiab
2671    write(lunout,*)' scut = ', scut
2672    write(lunout,*)' qqa1 = ', qqa1
2673    write(lunout,*)' qqa2 = ', qqa2
2674    write(lunout,*)' gammas = ', gammas
2675    write(lunout,*)' Fmax = ', Fmax
2676    write(lunout,*)' tmax_fonte_cv = ', tmax_fonte_cv
2677    write(lunout,*)' alphas = ', alphas
2678    write(lunout,*)' iflag_wake = ', iflag_wake
2679    write(lunout,*)' alp_offset = ', alp_offset
2680    ! nrlmd le 10/04/2012
2681    write(lunout,*)' iflag_trig_bl = ', iflag_trig_bl
2682    write(lunout,*)' s_trig = ', s_trig
2683    write(lunout,*)' tau_trig_shallow = ', tau_trig_shallow
2684    write(lunout,*)' tau_trig_deep = ', tau_trig_deep
2685    write(lunout,*)' iflag_clos_bl = ', iflag_clos_bl
2686    ! fin nrlmd le 10/04/2012
2687
2688    write(lunout,*)' lonmin lonmax latmin latmax bilKP_ins =',&
2689         lonmin_ins, lonmax_ins, latmin_ins, latmax_ins
2690    write(lunout,*)' ecrit_ hf, ins, day, mth, reg, tra, ISCCP, LES',&
2691         ecrit_hf, ecrit_ins, ecrit_day, ecrit_mth, ecrit_reg, ecrit_tra, ecrit_ISCCP, ecrit_LES
2692
2693    write(lunout,*) 'ok_strato = ', ok_strato
2694    write(lunout,*) 'ok_hines = ',  ok_hines
2695    write(lunout,*) 'ok_gwd_rando = ',  ok_gwd_rando
2696    write(lunout,*) 'ok_qch4 = ',  ok_qch4
2697    write(lunout,*) 'gwd_rando_ruwmax = ', gwd_rando_ruwmax
2698    write(lunout,*) 'gwd_rando_sat = ', gwd_rando_sat
2699    write(lunout,*) 'gwd_front_ruwmax = ', gwd_front_ruwmax
2700    write(lunout,*) 'gwd_front_sat = ', gwd_front_sat
2701    write(lunout,*) 'SSO gkdrag =',gkdrag
2702    write(lunout,*) 'SSO grahilo=',grahilo
2703    write(lunout,*) 'SSO grcrit=',grcrit
2704    write(lunout,*) 'SSO gfrcrit=',gfrcrit
2705    write(lunout,*) 'SSO gkwake=',gkwake
2706    write(lunout,*) 'SSO gklift=',gklift
2707    write(lunout,*) 'adjust_tropopause = ', adjust_tropopause
2708    write(lunout,*) 'ok_daily_climoz = ',ok_daily_climoz
2709    write(lunout,*) 'read_climoz = ', read_climoz
2710    write(lunout,*) 'carbon_cycle_tr = ', carbon_cycle_tr
2711    write(lunout,*) 'carbon_cycle_cpl = ', carbon_cycle_cpl
2712
2713    !$OMP END MASTER
2714
2715    RETURN
2716
2717  END SUBROUTINE conf_phys
2718
2719END MODULE conf_phys_m
2720!
2721!#################################################################
2722!
2723
2724SUBROUTINE conf_interface(tau_calv)
2725
2726  USE IOIPSL
2727  USE print_control_mod, ONLY: lunout
2728  IMPLICIT NONE
2729  ! Configuration de l'interace atm/surf
2730  !
2731  ! tau_calv:    temps de relaxation pour la fonte des glaciers
2732
2733  REAL          :: tau_calv
2734  REAL,SAVE     :: tau_calv_omp
2735
2736  !
2737  !Config Key  = tau_calv
2738  !Config Desc = temps de relaxation pour fonte des glaciers en jours
2739  !Config Def  = 1 an
2740  !Config Help =
2741  !
2742  tau_calv_omp = 360.*10.
2743  !$OMP MASTER
2744  CALL getin('tau_calv',tau_calv_omp)
2745  !$OMP END MASTER
2746  !$OMP BARRIER
2747
2748  tau_calv=tau_calv_omp
2749
2750  !$OMP MASTER
2751  write(lunout,*)' ##############################################'
2752  WRITE(lunout,*)' Configuration de l''interface atm/surfaces  : '
2753  WRITE(lunout,*)' tau_calv = ',tau_calv
2754  !$OMP END MASTER
2755
2756  RETURN
2757
2758END SUBROUTINE conf_interface
Note: See TracBrowser for help on using the repository browser.