tsloc.f

Go to the documentation of this file.
00001 C:\opentelemac\v7p0\sources\utils\bief\tsloc.f
00002 !
00085                      DOUBLE PRECISION FUNCTION TSLOC
00086 !                    *******************************
00087 !
00088      & (YEAR,MONTH,DAY,HOUR,MINU,SEC,AT)
00089 !
00090 !***********************************************************************
00091 ! BIEF   V6P2                                   21/08/2010
00092 !***********************************************************************
00093 !
00094 !
00095 !
00096 !
00097 !
00098 !
00099 !~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
00100 !| AT             |-->| TIME IN SECONDS
00101 !| DAY            |-->| DAY
00102 !| HOUR           |-->| HOUR IN UNIVERSAL TIME
00103 !| MINUTE         |-->| MINUTE IN UNIVERSAL TIME
00104 !| MONTH          |-->| MONTH
00105 !| SEC            |-->| SECOND IN UNIVERSAL TIME
00106 !| YEAR           |-->| YEAR
00107 !~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
00108 !
00109       USE BIEF, EX_TSLOC => TSLOC
00110 !
00111       IMPLICIT NONE
00112       INTEGER LNG,LU
00113       COMMON/INFO/LNG,LU
00114 !
00115 !+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
00116 !
00117       INTEGER, INTENT(IN)          :: MONTH,DAY,HOUR,MINU,SEC
00118       INTEGER, INTENT(INOUT)       :: YEAR
00119       DOUBLE PRECISION, INTENT(IN) :: AT
00120 !
00121 !+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
00122 !
00123       DOUBLE PRECISION T,TETA,TETA0,UT
00124       DOUBLE PRECISION AT1,ATR
00125 !
00126       INTRINSIC ACOS,INT
00127 !
00128 !-----------------------------------------------------------------------
00129 !
00130       ATR = AT + ( HOUR * 60.D0 + MINU ) * 60.D0 + SEC
00131       AT1 = INT ( ATR / ( 24.D0 * 3600.D0 ) ) * ( 24.D0 * 3600.D0 )
00132       ATR = ATR - AT1
00133       T = JULTIM(YEAR,MONTH,DAY,0,0,0,AT1)
00134 !
00135 ! COMPUTES THE SIDEREAL TIME WRT GREENWICH AT 0:00 (IN HOURS)
00136 !
00137       TETA0 = 6.6460656D0 + 2400.051262D0 * T + 0.00002581D0 * T**2
00138 !
00139 ! COMPUTES THE SIDEREAL TIME WRT GREENWICH AT TU
00140 !
00141       UT = ATR / 3600.D0
00142       TETA = TETA0 + UT*1.002737908D0
00143 !
00144 ! COMPUTES THE LOCAL SIDEREAL TIME IN RADIANS WITHOUT TAKING LONGITUDE
00145 ! INTO ACCOUNT
00146 !
00147       TSLOC = TETA * ACOS(-1.D0) / 12.D0
00148 !
00149 !-----------------------------------------------------------------------
00150 !
00151       RETURN
00152       END

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