C+ C NAME: C sidereal_t.f C PURPOSE: C Calculate the true sidereal time at ASHI from the true sidereal time at the beginning of the ASHI nighttime observations. C CATEGORY: C Abnalysis C CALLING SEQUENCE: C call sidereal_t(JDX,JDbeg,stbeg,alonx,st) C C INPUTS: C JDX real*8 Julian date of the observation (UT time) C JDbeg real*8 Julian date at the beginning of the ASHI observations (UT time) C stbeg real*8 Sidereal time at the beginning of the ASHI observations (in degrees) C alonx real longitude of the observation (ASHI) C C OUTPUTS: C st real sidereal time at ASHI in degrees since the beginning of the day C C FUNCTIONS/SUBROUTINES: C julian8 C C MODIFICATION HISTORY: C April-2022, Bernard Jackson (UCSD) C- subroutine sidereal_t(JDX,JDbeg,stbeg,alonx,alonb,st) real alonx ! Longitude of the ASHI observation (in degrees and fraction) real*8 JDX ! Input time of the ASHI observation in Day of Year in UTC real*8 JDbeg ! Input time of the beginning ASHI observation in Day of Year in UTC real*8 stbeg ! True sidereal time at the beginning of the ASHI observation (in degrees) C (from http://neoprogrammics.com/sidereal_time_calculator/index.php) real*8 caobsdoy, ! UT calendar days plus longitude offset since the beginning ASHI observation & daytidif, ! difference in sidereal days from calendar days & sideg ! sidereal time in degrees and fraction at the time of the ASHI observation C print*, ' Into sidereal',JDX,JDbeg,stbeg,alonx,alonb caobsdoy = (JDX-JDbeg) ! calendar days since the beginning ASHI obs. in UT plus the longitude offset difference daytidif = 0.00273042407d0*caobsdoy sideg = stbeg + (caobsdoy + daytidif)*360.0d0 + (alonb-alonx) if(sideg.gt.360.0d0) sideg = sideg - 360.0d0 st = sideg ! Sidereal time at ASHI in degrees in single precision C write(*,'(5F14.8)') daytidif, caobsdoy, sideg, alonb-alonx,st return end