source: trunk/MESOSCALE/LMD_MM_MARS/SRC/PREP_MARS/makecal.F90 @ 598

Last change on this file since 598 was 11, checked in by aslmd, 14 years ago

spiga@svn-planeto:ajoute le modele meso-echelle martien

File size: 1.2 KB
Line 
1PROGRAM convdate
2
3IMPLICIT NONE
4
5!
6! pgf90 time.F makecal.F90
7!
8
9INTEGER :: gcm_day, init_oui
10
11INTEGER :: wrf_month,wrf_day
12
13INTEGER :: init,i
14INTEGER, PARAMETER :: MONTHS_PER_YEAR = 12
15INTEGER, PARAMETER :: mday(MONTHS_PER_YEAR)   &
16           = (/61,66,66,65,60,54,50,46,47,47,51,56/)
17REAL :: ls
18
19CHARACTER(2) :: cday,cmonth
20
21!!PRINT *, '     init --','   GCM sol --', '   GCM ls --', '     WRF month --', '   WRF day --'
22!!PRINT *, '     init --','   GCM sol --', '   GCM ls --', '     WRF'
23PRINT *, '-- sol -- ', ' -- ls -- ', ' -- month -- ', ' -- day --'
24
25DO gcm_day=0,668
26
27init_oui=0
28
29init=gcm_day+1    !!+1 sinon on decale tout
30DO i=1,MONTHS_PER_YEAR
31        wrf_month=i
32        init=init-mday(i)
33        IF (init <= 0) EXIT
34END DO
35
36wrf_day=init+mday(wrf_month)
37
38IF (MODULO(gcm_day+1,3) == 0) init_oui=99
39
40CALL sol2ls(real(gcm_day),ls)
41
42Write( cday, '(i0)' )  wrf_day
43Write( cmonth, '(i0)' )  wrf_month
44IF (wrf_day < 10) cday='0'//cday
45IF (wrf_month < 10) cmonth='0'//cmonth
46
47IF (ls < 1e-3) ls=0.
48
49!!PRINT *, init_oui, gcm_day, ls, wrf_day, wrf_month, '2024'//'-'//cmonth//'-'//cday//'_'//'00'//':00:00'
50!!PRINT *, init_oui, gcm_day, ls, '2024'//'-'//cmonth//'-'//cday//'_'//'00'//':00:00'
51PRINT *, gcm_day, ls, cmonth//'  '//cday
52
53ENDDO
54
55END PROGRAM convdate
Note: See TracBrowser for help on using the repository browser.