jultim.f

Go to the documentation of this file.
00001 C:\opentelemac\v7p0\sources\utils\bief\jultim.f
00002 !
00059                      DOUBLE PRECISION FUNCTION JULTIM
00060 !                    ********************************
00061 !
00062      &(YEAR,MONTH,DAY,HOUR,MINU,SEC,AT)
00063 !
00064 !***********************************************************************
00065 ! BIEF   V6P2                                   21/08/2010
00066 !***********************************************************************
00067 !
00068 !
00069 !
00070 !
00071 !
00072 !
00073 !~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
00074 !| AT             |-->| TIME IN SECONDS
00075 !| DAY            |-->| DAY
00076 !| HOUR           |-->| HOUR IN UNIVERSAL TIME
00077 !| MIN            |-->| MINUTE IN UNIVERSAL TIME
00078 !| MONTH          |-->| MONTH
00079 !| SEC            |-->| SECOND IN UNIVERSAL TIME
00080 !| YEAR           |-->| YEAR
00081 !~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
00082 !
00083       IMPLICIT NONE
00084 !
00085       INTEGER LNG,LU
00086       COMMON/INFO/LNG,LU
00087 !
00088 !+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
00089 !
00090       INTEGER,          INTENT(IN) :: MONTH,DAY,HOUR,MINU,SEC,YEAR
00091       DOUBLE PRECISION, INTENT(IN) :: AT
00092 !
00093 !+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
00094 !
00095       INTEGER GREG,Y,M,YEAR2
00096       DOUBLE PRECISION J
00097 !
00098       INTRINSIC INT
00099 !
00100       PARAMETER (GREG=15+31*(10+12*1582))
00101 !
00102 !-----------------------------------------------------------------------
00103 !
00104       YEAR2=YEAR
00105       IF(YEAR2.EQ.0) THEN
00106         IF (LNG.EQ.1) WRITE (LU,100)
00107         IF(LNG.EQ.2)  WRITE (LU,101)
00108         CALL PLANTE(1)
00109         STOP
00110       ENDIF
00111       IF(YEAR2.LT.0) YEAR2=YEAR2+1
00112 !
00113       IF (MONTH.GT.2) THEN
00114         Y=YEAR2
00115         M=MONTH+1
00116       ELSE
00117         Y=YEAR2-1
00118         M=MONTH+13
00119       ENDIF
00120 !
00121       J=INT(365.25D0*Y)+INT(30.6001D0*M)+DAY+1720995.D0
00122       IF(DAY+31*(MONTH+12*YEAR2).GE.GREG) THEN
00123         J=J+2-INT(0.01D0*Y)+INT(0.25D0*INT(0.01D0*Y))
00124       ENDIF
00125       J=J-2415020.5D0
00126       JULTIM=(J+(HOUR+(MINU+(SEC+AT)/60.D0)/60.D0)/24.D0)/36525.D0
00127 !
00128 !---------------------------------------------------------------
00129 !
00130 100   FORMAT (//,10X,'**********************************',
00131      &         /,10X,'       FONCTION JULTIM',
00132      &         /,10X,' LA VALEUR DE L''ANNEE EST NULLE',
00133      &         /,10X,' CALCUL IMPOSSIBLE ...'
00134      &         /,10X,'**********************************')
00135 101   FORMAT (//,10X,'**********************************',
00136      &         /,10X,'       JULTIM FUNCTION',
00137      &         /,10X,' THE VALUE FOR THE YEAR IS ZERO',
00138      &         /,10X,' COMPUTATION NOT POSSIBLE ...'
00139      &         /,10X,'**********************************')
00140 !
00141 !---------------------------------------------------------------
00142 !
00143       RETURN
00144       END

Generated on Fri Aug 31 2013 18:12:58 by S.E.Bourban (HRW) using doxygen 1.7.0