File indexing completed on 2018-03-02 18:38:17 UTC
view on githubraw file Latest commit add29e06 on 2018-01-31 20:35:05 UTC
d694d255c8 Jean*0001 #include "CAL_OPTIONS.h"
0002
0003 SUBROUTINE CAL_TIME2DUMP(
c36c77a53c Jean*0004 I phase, freq, step,
d694d255c8 Jean*0005 U time2write,
0006 I myTime, myIter, myThid )
0007
0008
0009
0010
0011
0012
0013 IMPLICIT NONE
0014
0015
0016
0017 #include "cal.h"
0018
0019
c36c77a53c Jean*0020 _RL phase, freq, step
d694d255c8 Jean*0021 LOGICAL time2write
0022 _RL myTime
0023 INTEGER myIter
0024 INTEGER myThid
0025
0026
0027 INTEGER thisDate(4), prevDate(4)
c36c77a53c Jean*0028 _RL posFreq
dc0c7988e6 Jean*0029 _RL shTime, prTime
d694d255c8 Jean*0030
fdaaa7bd24 Jean*0031 IF ( calendarDumps .AND. freq .NE. 0. ) THEN
0032
0033
0034
0035
0036 IF ( myTime+step.GE.phase .OR. myTime.LT.0. ) THEN
c36c77a53c Jean*0037 posFreq = ABS(freq)
d694d255c8 Jean*0038
dc0c7988e6 Jean*0039 shTime = myTime - phase
0040 prTime = shTime - step
0041 CALL CAL_GETDATE( myIter, shTime, thisDate, myThid )
0042 CALL CAL_GETDATE( myIter, prTime, prevDate, myThid )
d694d255c8 Jean*0043
c36c77a53c Jean*0044 IF ( posFreq.GE.2592000. .AND. posFreq.LE.2678400. ) THEN
d694d255c8 Jean*0045 time2write = .FALSE.
0046 IF ( (thisdate(1)-prevdate(1)).GT.50 ) time2write=.TRUE.
0047 ENDIF
0048
c36c77a53c Jean*0049 IF ( posFreq.GE.31104000. .AND. posFreq.LE.31968000. ) THEN
d694d255c8 Jean*0050 time2write = .FALSE.
0051 IF ( (thisdate(1)-prevdate(1)).GT.5000 ) time2write=.TRUE.
0052 ENDIF
fdaaa7bd24 Jean*0053 ENDIF
d694d255c8 Jean*0054 ENDIF
0055
0056 RETURN
0057 END