1 |
guez |
3 |
module conf_gcm_m |
2 |
|
|
|
3 |
|
|
IMPLICIT NONE |
4 |
|
|
|
5 |
guez |
350 |
INTEGER, protected:: nday = 1 ! nombre de jours d'int\'egration |
6 |
guez |
3 |
|
7 |
guez |
301 |
integer, protected:: day_step = 240 |
8 |
|
|
! nombre de pas de temps de la dynamique par jour |
9 |
|
|
|
10 |
|
|
integer, protected:: iperiod = 5 |
11 |
|
|
! periode pour le pas Matsuno (en pas de temps) |
12 |
|
|
|
13 |
|
|
integer, protected:: iapp_tracvl = 5 |
14 |
guez |
3 |
! Should normally be equal to "iperiod" |
15 |
|
|
! frequence du groupement des flux (en pas de temps) |
16 |
|
|
|
17 |
guez |
301 |
integer, protected:: iconser = 240 |
18 |
guez |
326 |
! number of time steps of dynamics between output of control variables |
19 |
guez |
3 |
|
20 |
guez |
301 |
integer, protected:: iphysiq = 5 |
21 |
guez |
331 |
! Number of time steps of dynamics between calls to physics. Must be |
22 |
|
|
! >= 1. 1 means one call to physics at each time step of dynamics. |
23 |
guez |
40 |
|
24 |
guez |
301 |
logical, protected:: raz_date = .false. |
25 |
guez |
154 |
! prise en compte de la date initiale de la namelist et remise \`a |
26 |
|
|
! z\'ero des compteurs de pas de temps (sinon on garde la date du |
27 |
guez |
98 |
! fichier restart) |
28 |
guez |
3 |
|
29 |
guez |
301 |
integer, protected:: periodav = 1 |
30 |
guez |
56 |
! time interval between outputs in the dynamical part, in days |
31 |
guez |
3 |
|
32 |
guez |
301 |
LOGICAL, protected:: purmats= .FALSE. |
33 |
guez |
57 |
! Help = Choix du schema d'integration temporel. |
34 |
|
|
! y = pure Matsuno sinon c'est du Matsuno-leapfrog |
35 |
|
|
|
36 |
guez |
301 |
logical, protected:: iflag_phys = .true. ! call parameterizations of physics |
37 |
|
|
INTEGER, SAVE, protected:: lmt_pas ! number of time steps of "physics" per day |
38 |
guez |
202 |
|
39 |
guez |
3 |
contains |
40 |
|
|
|
41 |
guez |
13 |
SUBROUTINE conf_gcm |
42 |
guez |
3 |
|
43 |
|
|
! Auteurs : L. Fairhead, P. Le Van |
44 |
|
|
! Version du 29/04/97 |
45 |
|
|
|
46 |
guez |
33 |
use abort_gcm_m, only: abort_gcm |
47 |
guez |
212 |
use nr_util, only: assert |
48 |
guez |
57 |
use unit_nml_m, only: unit_nml |
49 |
guez |
3 |
|
50 |
guez |
129 |
namelist /conf_gcm_nml/ raz_date, nday, day_step, iperiod, iapp_tracvl, & |
51 |
guez |
266 |
iconser, periodav, iphysiq |
52 |
guez |
115 |
namelist /logic_nml/ purmats, iflag_phys |
53 |
guez |
57 |
|
54 |
guez |
3 |
!------------------------------------ |
55 |
|
|
|
56 |
|
|
print *, "Call sequence information: conf_gcm" |
57 |
guez |
12 |
|
58 |
guez |
57 |
print *, "Enter namelist 'logic_nml'." |
59 |
|
|
read(unit=*, nml=logic_nml) |
60 |
|
|
write(unit_nml, nml=logic_nml) |
61 |
|
|
|
62 |
guez |
3 |
print *, "Enter namelist 'conf_gcm_nml'." |
63 |
|
|
read(unit=*, nml=conf_gcm_nml) |
64 |
guez |
57 |
write(unit_nml, nml=conf_gcm_nml) |
65 |
guez |
3 |
|
66 |
guez |
331 |
if (iphysiq <= 0 .or. iperiod <= 0 .or. day_step <= 0) & |
67 |
|
|
call abort_gcm("conf_gcm", & |
68 |
|
|
"iphysiq <= 0 or iperiod <= 0 or day_step <= 0") |
69 |
|
|
|
70 |
guez |
171 |
IF (MOD(day_step, iperiod) /= 0) call abort_gcm("conf_gcm", & |
71 |
|
|
'Il faut choisir un nombre de pas par jour multiple de "iperiod".') |
72 |
guez |
33 |
|
73 |
guez |
171 |
IF (MOD(day_step, iphysiq)/= 0) call abort_gcm("conf_gcm", & |
74 |
|
|
'Il faut choisir un nombre de pas par jour multiple de "iphysiq".') |
75 |
guez |
33 |
|
76 |
guez |
212 |
call assert(mod(iphysiq, iperiod) == 0, & |
77 |
|
|
"conf_gcm -- iphysiq must be multiple of iperiod") |
78 |
|
|
|
79 |
guez |
202 |
lmt_pas = day_step / iphysiq |
80 |
|
|
print *, 'Number of time steps of "physics" per day: ', lmt_pas |
81 |
|
|
|
82 |
guez |
3 |
END SUBROUTINE conf_gcm |
83 |
|
|
|
84 |
|
|
end module conf_gcm_m |