Changeset 693 for IOIPSL/trunk/src
- Timestamp:
- 07/29/09 17:49:31 (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
IOIPSL/trunk/src/calendar.f90
r428 r693 44 44 PRIVATE 45 45 PUBLIC :: ymds2ju,ju2ymds,tlen2itau,isittime,ioconf_calendar, & 46 & ioget_calendar,ioget_mon_len,i tau2date,ioget_timestamp, &47 & io conf_startdate,itau2ymds,time_diff,time_add, &48 & lock_calendar46 & ioget_calendar,ioget_mon_len,ioget_year_len,itau2date, & 47 & ioget_timestamp,ioconf_startdate,itau2ymds, & 48 & time_diff,time_add,lock_calendar 49 49 !- 50 50 INTERFACE ioget_calendar … … 909 909 !=== 910 910 !- 911 INTEGER FUNCTION ioget_year_len (year) 912 !!-------------------------------------------------------------------- 913 !! The "ioget_year_len" function returns 914 !! the number of days in "year", in the current calendar. 915 !! 916 !! INTEGER FUNCTION ioget_year_len (year) 917 !! 918 !! INPUT 919 !! 920 !! (I) year : year 921 !! 922 !! OUTPUT 923 !! 924 !! (I) ioget_year_len : number of days in the year 925 !!-------------------------------------------------------------------- 926 IMPLICIT NONE 927 !- 928 INTEGER,INTENT(IN) :: year 929 !- 930 INTEGER :: yl 931 !--------------------------------------------------------------------- 932 SELECT CASE(TRIM(calendar_used)) 933 CASE('gregorian') 934 yl = 365 935 IF ( ((MOD(year,4) == 0).AND.(MOD(year,100) /= 0)) & 936 .OR.(MOD(year,400) == 0) ) THEN 937 yl = yl+1 938 ENDIF 939 CASE('julian') 940 yl = 365 941 IF (MOD(year,4) == 0) THEN 942 yl = yl+1 943 ENDIF 944 CASE DEFAULT 945 yl = NINT(one_year) 946 END SELECT 947 ioget_year_len = yl 948 !-------------------------- 949 END FUNCTION ioget_year_len 950 !- 951 !=== 952 !- 911 953 SUBROUTINE ioget_timestamp (string) 912 954 !---------------------------------------------------------------------
Note: See TracChangeset
for help on using the changeset viewer.