FORTRAN Generation
(/./ftp/cats/J/AcA/56/253)

Conversion of standardized ReadMe file for file /./ftp/cats/J/AcA/56/253 into FORTRAN code for reading data files line by line.

Note that special values are assigned to unknown or unspecified numbers (also called NULL numbers); when necessary, the coordinate components making up the right ascension and declination are converted into floating-point numbers representing these angles in degrees.



      program load_ReadMe
C=============================================================================
C  F77-compliant program generated by readme2f_1.5, on 2013-May-21
C=============================================================================
*  This code was generated from the ReadMe file documenting a catalogue
*  according to the "Standard for Documentation of Astronomical Catalogues"
*  currently in use by the Astronomical Data Centers (CDS, ADC, A&A)
*  (see full documentation at URL http://vizier.u-strasbg.fr/doc/catstd.htx)
*  Please report problems or questions to   
C=============================================================================

      implicit none
*  Unspecified or NULL values, generally corresponding to blank columns,
*  are assigned one of the following special values:
*     rNULL__    for unknown or NULL floating-point values
*     iNULL__    for unknown or NULL   integer      values
      real*4     rNULL__
      integer*4  iNULL__
ter  (rNULL__=-1.e37)     	! NULL real number
      parameter  (iNULL__=-2147483647)	! NULL int  number

C=============================================================================
Cat. J/AcA/56/253  Period changes of OGLE contact binaries  (Kubiak+, 2006)
*================================================================================
*Period changes of contact binaries in OGLE database.
*    Kubiak M., Udalski A., Szymanski M.K.
*   <Acta Astron., 56, 253-265 (2006)>
*   =2006AcA....56..253K
C=============================================================================

C  Internal variables

      integer*4 i__

c - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 

C  Declarations for 'table1.dat'	! Contact binaries in OGLE database used for
                             determination of secular period changes

      integer*4 nr__
      parameter (nr__=679)	! Number of records
      character*61 ar__   	! Full-size record

      real*8        RA_         ! (deg) Right Ascension J2000
      real*8        Dec         ! (deg)     Declination J2000
      character*4   Field       ! Field
      integer*4     Star        ! Star number in the field
      real*8        Per         ! (d) Period
      real*4        Imag        ! (mag) Observed brightness in I band
      real*4        V_I         ! (mag) ?=9.99 Observed V-I colour index
      integer*4     RAh         ! (h) Right ascension (J2000)
      integer*4     RAm         ! (min) Right ascension (J2000)
      real*4        RAs         ! (s) Right ascension (J2000)
      character*1   DE_         ! Declination sign (J2000)
      integer*4     DEd         ! (deg) Declination (J2000)
      integer*4     DEm         ! (arcmin) Declination (J2000)
      real*4        DEs         ! (arcsec) Declination (J2000)

c - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 

C  Declarations for 'table2.dat'	! Time derivatives of periods determined by the
                             method of variance minimization

      integer*4 nr__1
      parameter (nr__1=569)	! Number of records
      character*64 ar__1  	! Full-size record

      character*4   Field_1     ! Field
      integer*4     Star_1      ! Star number in the field
      real*8        P           ! (d) Best value of the period
      real*4        dP_dt       ! (d/yr) Rate of period change
      integer*4     Nobs        ! Number of observations
      real*4        Fst         ! F-statistics
      real*4        Pst         ! P-statistics
      character*11  FileName    ! Name of the light curve in "lc" subdirectory

c - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 

C  Declarations for 'table3.dat'	! Results of the "average O-C diagram" method

      integer*4 nr__2
      parameter (nr__2=272)	! Number of records
      character*52 ar__2  	! Full-size record

      character*4   Field_2     ! Field
      integer*4     Star_2      ! Star number in the field
      real*8        P_1         ! (d) Period
      integer*4     Nobs_1      ! Number of observations
      real*4        dP_dt_1     ! (d/yr) Rate of period change determined from the
*                                   quadratic term in the O -C diagram
      real*4        p_e_        ! (d/yr) Formal error of the solution

c - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 

C  Declarations for 'lc/*'	! Individual light curves

      integer*4 nr__3
      parameter (nr__3=569)	! Number of records
      character*21 ar__3  	! Full-size record

      real*8        HJD_2448000 ! (d) Heliocentric Julian date, HJD-2448000
      real*4        dImag       ! (mag) I-band brightness minus mean

C=============================================================================

C  Loading file 'table1.dat'	! Contact binaries in OGLE database used for
*                             determination of secular period changes

C  Format for file interpretation

    1 format(
     +  A4,1X,I6,2X,F8.6,3X,F5.2,2X,F4.2,3X,I2,1X,I2,1X,F5.2,1X,A1,I2,
     +  1X,I2,1X,F4.1)

C  Effective file loading

      open(unit=1,file='table1.dat', status='old')
      write(6,*) '....Loading file: table1.dat'
      do i__=1,679
        read(1,'(A61)')ar__
        read(ar__,1)
     +  Field,Star,Per,Imag,V_I,RAh,RAm,RAs,DE_,DEd,DEm,DEs
c       Derive coordinates RA_ and Dec from input data
c       (RA_ and Dec are set to rNULL_ when unknown)
        RA_ = RAh
        if(RAh .GE. 0) RA_=RAh*15.
        if(RAm .GE. 0) RA_=RA_+RAm/4.
        if(RAs .GE. 0) RA_=RA_+RAs/240.
        Dec = DEd
        if(DEm .GE. 0) Dec=Dec+DEm/60.
        if(DEs .GE. 0) Dec=Dec+DEs/3600.
        if(DE_.EQ.'-'.AND.Dec.GE.0) Dec=-Dec
c    ..............Just test output...........
        write(6,1)
     +  Field,Star,Per,Imag,V_I,RAh,RAm,RAs,DE_,DEd,DEm,DEs
        write(6,'(6H Pos: 2F8.4)') RA_,Dec
c    .......End.of.Just test output...........
      end do
      close(1)

C=============================================================================

C  Loading file 'table2.dat'	! Time derivatives of periods determined by the
*                             method of variance minimization

C  Format for file interpretation

    2 format(A4,1X,I6,1X,F9.7,2X,E9.4,2X,I4,1X,F5.3,1X,F6.1,2X,A11)

C  Effective file loading

      open(unit=1,file='table2.dat', status='old')
      write(6,*) '....Loading file: table2.dat'
      do i__=1,569
        read(1,'(A64)')ar__1
        read(ar__1,2)Field_1,Star_1,P,dP_dt,Nobs,Fst,Pst,FileName
c    ..............Just test output...........
        write(6,2)Field_1,Star_1,P,dP_dt,Nobs,Fst,Pst,FileName
c    .......End.of.Just test output...........
      end do
      close(1)

C=============================================================================

C  Loading file 'table3.dat'	! Results of the "average O-C diagram" method

C  Format for file interpretation

    3 format(A4,1X,I6,2X,F8.6,3X,I4,3X,E9.4,4X,E8.4)

C  Effective file loading

      open(unit=1,file='table3.dat', status='old')
      write(6,*) '....Loading file: table3.dat'
      do i__=1,272
        read(1,'(A52)')ar__2
        read(ar__2,3)Field_2,Star_2,P_1,Nobs_1,dP_dt_1,p_e_
c    ..............Just test output...........
        write(6,3)Field_2,Star_2,P_1,Nobs_1,dP_dt_1,p_e_
c    .......End.of.Just test output...........
      end do
      close(1)

C=============================================================================

C  Loading file 'lc/*'	! Individual light curves

C  Format for file interpretation

    4 format(2X,F10.5,3X,F6.3)

C  Effective file loading

      open(unit=1,file='lc/*', status='old')
      write(6,*) '....Loading file: lc/*'
      do i__=1,569
        read(1,'(A21)')ar__3
        read(ar__3,4)HJD_2448000,dImag
c    ..............Just test output...........
        write(6,4)HJD_2448000,dImag
c    .......End.of.Just test output...........
      end do
      close(1)

C=============================================================================
      stop
      end