FORTRAN Generation
(/./ftp/cats/J/ApJ/701/1922)

Conversion of standardized ReadMe file for file /./ftp/cats/J/ApJ/701/1922 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.81 (2015-09-23), on 2024-Apr-20
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__
      parameter  (rNULL__=--2147483648.)  	! NULL real number
      parameter  (iNULL__=(-2147483647-1))	! NULL int  number
      integer    idig			! testing NULL number

C=============================================================================
Cat. J/ApJ/701/1922       Radio interferometric planet search. I.      (Bower+, 2009)
*================================================================================
*Radio interferometric planet search.
*I. First constraints on planetary companions for nearby, low-mass stars from
*radio astrometry.
*    Bower G.C., Bolatto A., Ford E.B., Kalas P.
*   <Astrophys. J., 701, 1922-1939 (2009)>
*   =2009ApJ...701.1922B
C=============================================================================

C  Internal variables

      integer*4 i__

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

C  Declarations for 'table1.dat'	! Stellar data

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

C  J2000 position composed of: RAh RAm RAs DE- DEd DEm DEs
      real*8        RAdeg       ! (deg) Right Ascension J2000
      real*8        DEdeg       ! (deg)     Declination J2000
C  ---------------------------------- ! (position vector(s) in degrees)

      character*6   GJ          ! Gliese catalog identification
      integer*4     RAh         ! (h) Hour of right ascension (J2000)
      integer*4     RAm         ! (min) Minute of right ascension (J2000)
      real*4        RAs         ! (s) Second of right ascension (J2000)
      character*1   DE_         ! Sign of declination (J2000)
      integer*4     DEd         ! (deg) Degree of declination (J2000)
      integer*4     DEm         ! (arcmin) Arcminute of declination (J2000)
      real*4        DEs         ! (arcsec) Arcsecond of declination (J2000)
      real*8        ePos1       ! (mas) ? Positional error ellipse (major axis)
      real*8        ePos2       ! (mas) ? Positional error ellipse (minor axis)
      integer*4     ePosPA      ! (deg) ? Positional error ellipse (position angle)
      real*8        pmRA        ! (mas/yr) ? Proper motion along RA
      real*8        pmDE        ! (mas/yr) ? Proper motion along DE
      real*4        epm1        ! (mas/yr) ? Proper motion error ellipse (major axis)
      real*4        epm2        ! (mas/yr) ? Proper motion error ellipse (minor axis)
      integer*4     epmPA       ! (deg) ? Proper motion error ellipse (position angle)
      real*4        pi          ! (mas) ? Annual parallax
      real*4        e_pi        ! (mas) ? Annual parallax uncertainty
      character*7   SpType      ! MK spectral type
      real*4        Bmag        ! (mag) ? Apparent B-band magnitude
      real*4        Vmag        ! (mag) ? Apparent V-band magnitude
      real*4        logLX       ! ([10-7W]) ? Log of X-ray luminosity in erg/s

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

C  Declarations for 'table2.dat'	! VLA detected star

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

      character*7   GJ_1        ! Gliese catalog identification
      character*8   Epoch       ! ("YYYYMMDD") Epoch of observation
      character*1   l_Flux      ! Limit flag on Flux
      integer*4     Flux        ! (uJy) Flux density at 5GHz
      integer*4     e_Flux      ! (uJy) ? Flux density uncertainty

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

C  Declarations for 'table3.dat'	! VLA undetected star

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

      character*7   GJ_2        ! Gliese catalog identification
      character*8   Epoch_1     ! ("YYYYMMDD") Epoch of observation
      character*1   l_Flux_1    ! Limit flag on Flux
      integer*4     Flux_1      ! (uJy) Flux density at 5GHz
      integer*4     e_Flux_1    ! (uJy) ? Flux density uncertainty

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

C  Loading file 'table1.dat'	! Stellar data

C  Format for file interpretation

    1 format(
     +  A6,1X,I2,1X,I2,1X,F5.2,1X,A1,I2,1X,I2,1X,F5.2,1X,F9.2,1X,F9.2,
     +  1X,I3,1X,F8.2,1X,F8.2,1X,F6.2,1X,F6.2,1X,I3,1X,F6.2,1X,F5.2,
     +  1X,A7,1X,F5.2,1X,F5.2,1X,F5.2)

C  Effective file loading

      open(unit=1,status='old',file=
     +'table1.dat')
      write(6,*) '....Loading file: table1.dat'
      do i__=1,135
        read(1,'(A130)')ar__
        read(ar__,1)
     +  GJ,RAh,RAm,RAs,DE_,DEd,DEm,DEs,ePos1,ePos2,ePosPA,pmRA,pmDE,
     +  epm1,epm2,epmPA,pi,e_pi,SpType,Bmag,Vmag,logLX
        if(ar__(33:41) .EQ. '') ePos1 = rNULL__
        if(ar__(43:51) .EQ. '') ePos2 = rNULL__
        if(ar__(53:55) .EQ. '') ePosPA = iNULL__
        if(ar__(57:64) .EQ. '') pmRA = rNULL__
        if(ar__(66:73) .EQ. '') pmDE = rNULL__
        if(ar__(75:80) .EQ. '') epm1 = rNULL__
        if(ar__(82:87) .EQ. '') epm2 = rNULL__
        if(ar__(89:91) .EQ. '') epmPA = iNULL__
        if(ar__(93:98) .EQ. '') pi = rNULL__
        if(ar__(100:104) .EQ. '') e_pi = rNULL__
        if(ar__(114:118) .EQ. '') Bmag = rNULL__
        if(ar__(120:124) .EQ. '') Vmag = rNULL__
        if(ar__(126:130) .EQ. '') logLX = rNULL__
        RAdeg = rNULL__
        DEdeg = rNULL__
c  Derive coordinates RAdeg and DEdeg from input data
c  (RAdeg and DEdeg are set to rNULL__ when unknown)
        if(RAh .GT. -180) RAdeg=RAh*15.
        if(RAm .GT. -180) RAdeg=RAdeg+RAm/4.
        if(RAs .GT. -180) RAdeg=RAdeg+RAs/240.
        if(DEd .GE. 0) DEdeg=DEd
        if(DEm .GE. 0) DEdeg=DEdeg+DEm/60.
        if(DEs .GE. 0) DEdeg=DEdeg+DEs/3600.
        if(DE_.EQ.'-'.AND.DEdeg.GE.0) DEdeg=-DEdeg
c    ..............Just test output...........
        write(6,1)
     +  GJ,RAh,RAm,RAs,DE_,DEd,DEm,DEs,ePos1,ePos2,ePosPA,pmRA,pmDE,
     +  epm1,epm2,epmPA,pi,e_pi,SpType,Bmag,Vmag,logLX
        write(6,'(6H Pos: 2F8.4)') RAdeg,DEdeg
c    .......End.of.Just test output...........
      end do
      close(1)

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

C  Loading file 'table2.dat'	! VLA detected star

C  Format for file interpretation

    2 format(A7,1X,A8,1X,A1,I4,1X,I3)

C  Effective file loading

      open(unit=1,status='old',file=
     +'table2.dat')
      write(6,*) '....Loading file: table2.dat'
      do i__=1,51
        read(1,'(A26)')ar__1
        read(ar__1,2)GJ_1,Epoch,l_Flux,Flux,e_Flux
        if(ar__1(24:26) .EQ. '') e_Flux = iNULL__
c    ..............Just test output...........
        write(6,2)GJ_1,Epoch,l_Flux,Flux,e_Flux
c    .......End.of.Just test output...........
      end do
      close(1)

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

C  Loading file 'table3.dat'	! VLA undetected star

C  Format for file interpretation

    3 format(A7,1X,A8,1X,A1,I4,1X,I3)

C  Effective file loading

      open(unit=1,status='old',file=
     +'table3.dat')
      write(6,*) '....Loading file: table3.dat'
      do i__=1,134
        read(1,'(A26)')ar__2
        read(ar__2,3)GJ_2,Epoch_1,l_Flux_1,Flux_1,e_Flux_1
        if(ar__2(24:26) .EQ. '') e_Flux_1 = iNULL__
c    ..............Just test output...........
        write(6,3)GJ_2,Epoch_1,l_Flux_1,Flux_1,e_Flux_1
c    .......End.of.Just test output...........
      end do
      close(1)

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