SUBROUTINE OBSTIME(mjd,fday,iCYCLE,ntrack,IDX,*) c date - 7/31/96 pgmr - Anita C. Brenner c 7/96 Brian D. Beckley c function - calculate exact time in modified julian date and c fraction of the day for specific sea surface residual height c input parameters - icycle - repeat cycle number c ntrack - track number within the repeat cycle c idx - indice within the revolution c output paramters - mjd - modified julian date of seah surface height c - fday - fractional day implicit none integer*4 icycle,ntrack,idx,mjd,irec integer*4 mjdrev,ifdayrev,ideltrev,nperiod integer*4 in5,iout6,inephm,inssh,intime,inflag,inmss,indir integer*4 nreclephm,nreclmss,nreclsshfl,nrecltime, . nrecldir,ncycles,numrevs,iundf4 double precision secday,fday common/cmission/nreclephm,nreclmss,nreclsshfl,nrecltime, . nrecldir,ncycles,numrevs,nperiod common/constsi4/iundf4 common/constsr8/secday common/cunits/in5,iout6,inephm,inssh,intime,inflag,inmss,indir save c compute record number from revolution number ITRK and c repeat cycle NCYCLE irec=(ntrack-1)*ncycles+iCYCLE read(intime,rec=irec)mjdrev,ifdayrev,ideltrev c time at indice number 1 for this revolution c mjdrev : modified Julian day c ifdayrev : fractional part of day (milliseconds) c ideltrev : time interval between (1 Hz) georeferenced indices (microsec) c if(mjdrev.eq.iundf4) return 1 c time at georeference index #1 : fday=dfloat(ifdayrev)*1.d-03/secday+ . (dfloat(idx-1)*dfloat(ideltrev)*1.0d-06)/secday mjd=mjdrev+int(fday) fday=dmod(fday,1.d0) return end