FORTRAN Generation
(/./ftp/cats/J/A_A/635/A73)

Conversion of standardized ReadMe file for file /./ftp/cats/J/A_A/635/A73 into FORTRAN code for loading all data files into arrays.

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 2026-Sep-12
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/A+A/635/A73 Multiplicity study of transiting exoplanet hosts. I. (Bohn+, 2020)
*================================================================================
*A multiplicity study of transiting exoplanet host stars.
*I. High-contrast imaging with VLT/SPHERE .
*    Bohn A.J., Southworth, J., Ginski, C., Kenworthy M.A., Maxted P.F.L.,
*    Evans D.F.
*    <Astron. Astrophys. 635, A73 (2020)>
*    =2020A&A...635A..73B        (SIMBAD/NED BibCode)
C=============================================================================

C  Internal variables

      integer*4 i__

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

C  Declarations for 'stars.dat'	! List of studied stars

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

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

      character*8   Star       (nr__) ! Star name
      integer*4     RAh        (nr__) ! (h) Right Ascension (J2000)
      integer*4     RAm        (nr__) ! (min) Right Ascension (J2000)
      real*4        RAs        (nr__) ! (s) Right Ascension (J2000)
      character*1   DE_        (nr__) ! Declination sign (J2000)
      integer*4     DEd        (nr__) ! (deg) Declination (J2000)
      integer*4     DEm        (nr__) ! (arcmin) Declination (J2000)
      real*4        DEs        (nr__) ! (arcsec) Declination (J2000)
      integer*4     Nx         (nr__) ! Number of pixels along X-axis
      integer*4     Ny         (nr__) ! Number of pixels along Y-axis
      integer*4     size       (nr__) ! (Kibyte) Size of FITS file
      character*18  FileName   (nr__) ! Name of FITS file, in subdirectory fits
      character*31  Title      (nr__) ! Title of the FITS file

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

C  Declarations for 'table2.dat'	! Astrometry, photometry, background probability
                                 and derived masses and effective temperatures
                                 of identified candidate companions

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

      character*8   Star_1     (nr__1) ! Host star name around which the companion
*                                     was detected
      integer*4     CCID       (nr__1) ! ID of the companion candidate
      character*10  Date       (nr__1) ! ("date") Date of the observation
      real*4        Sep        (nr__1) ! (arcsec) Separation of the CC
      real*4        e_Sep      (nr__1) ! (arcsec) Uncertainty of CC separation
      real*4        PA         (nr__1) ! (deg) Position angle of the CC
      real*4        e_PA       (nr__1) ! (deg) Uncertainty of the CC PA
      real*4        Kmag       (nr__1) ! (mag) K band magnitude of the host star,
*                                     corrected for contribution of the CCs
      real*4        DeltaK     (nr__1) ! (mag) Magnitude difference between primary and CC
      real*4        e_DeltaK   (nr__1) ! (mag) Uncertainty in magnitude difference between
*                                     primary and CC
      character*1   Status     (nr__1) ! [ABC] Status of the CC (1)
      real*8        pbg        (nr__1) ! Probability that CC is background object
      real*4        Mass       (nr__1) ! (Msun) ? Mass of the CC (2)
      real*4        B_Mass     (nr__1) ! (Msun) ? Upper threshold for CC mass
      real*4        b_Mass_1   (nr__1) ! (Msun) ? Lower threshold for CC mass
      integer*4     Teff       (nr__1) ! (K) ? Effective temperature of the CC  (2)
      integer*4     B_Teff     (nr__1) ! (K) ? Upper threshold for CC temperature
      integer*4     b_Teff_1   (nr__1) ! (K) ? Lower threshold for CC temperature
*Note (1): Status of the CC as follows:
*           C = companion
*           B = background
*           A = ambiguous
*Note (2): No mass and Teff are provided for background objects.

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

C  Declarations for 'det-lim.dat'	! Contrast limits of our data reduction for
                                 all targets

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

      character*8   Star_2     (nr__2) ! Star name
      real*4        Sep_1      (nr__2) ! (arcsec) Projected separation
      real*4        DeltaKs    (nr__2) ! (mag) Magnitude contrast Ks band
      real*4        e_DeltaKs  (nr__2) ! (mag) Uncertainty of magnitude contrast Ks band
      real*4        Masslimit  (nr__2) ! (Mjup) Average mass limit
      real*4        E_Masslimit(nr__2) ! (Mjup) Upper mass limit
      real*4        e_Masslimit_1(nr__2) ! (Mjup) Lower mass limit

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

C  Loading file 'stars.dat'	! List of studied stars

C  Format for file interpretation

    1 format(
     +  A8,1X,I2,1X,I2,1X,F5.2,A1,I2,1X,I2,1X,F4.1,1X,I3,1X,I3,1X,I4,
     +  1X,A18,1X,A31)

C  Effective file loading

      open(unit=1,status='old',file=
     +'stars.dat')
      write(6,*) '....Loading file: stars.dat'
      do i__=1,23
        read(1,'(A95)')ar__
        read(ar__,1)
     +  Star(i__),RAh(i__),RAm(i__),RAs(i__),DE_(i__),DEd(i__),
     +  DEm(i__),DEs(i__),Nx(i__),Ny(i__),size(i__),FileName(i__),
     +  Title(i__)
        RAdeg(i__) = rNULL__
        DEdeg(i__) = rNULL__
c  Derive coordinates RAdeg and DEdeg from input data
c  (RAdeg and DEdeg are set to rNULL__ when unknown)
        if(RAh(i__) .GT. -180) RAdeg(i__)=RAh(i__)*15.
        if(RAm(i__) .GT. -180) RAdeg(i__)=RAdeg(i__)+RAm(i__)/4.
        if(RAs(i__) .GT. -180) RAdeg(i__)=RAdeg(i__)+RAs(i__)/240.
        if(DEd(i__) .GE. 0) DEdeg(i__)=DEd(i__)
        if(DEm(i__) .GE. 0) DEdeg(i__)=DEdeg(i__)+DEm(i__)/60.
        if(DEs(i__) .GE. 0) DEdeg(i__)=DEdeg(i__)+DEs(i__)/3600.
        if(DE_(i__).EQ.'-'.AND.DEdeg(i__).GE.0) DEdeg(i__)=-DEdeg(i__)
c    ..............Just test output...........
        write(6,1)
     +  Star(i__),RAh(i__),RAm(i__),RAs(i__),DE_(i__),DEd(i__),
     +  DEm(i__),DEs(i__),Nx(i__),Ny(i__),size(i__),FileName(i__),
     +  Title(i__)
        write(6,'(6H Pos: 2F8.4)') RAdeg(i__),DEdeg(i__)
c    .......End.of.Just test output...........
      end do
      close(1)

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

C  Loading file 'table2.dat'	! Astrometry, photometry, background probability
*                                 and derived masses and effective temperatures
*                                 of identified candidate companions

C  Format for file interpretation

    2 format(
     +  A8,1X,I1,1X,A10,1X,F5.3,1X,F5.3,1X,F5.1,1X,F5.1,1X,F5.2,1X,
     +  F4.2,1X,F4.2,1X,A1,1X,F7.5,1X,F4.2,1X,F4.2,1X,F4.2,1X,I4,1X,
     +  I4,1X,I4)

C  Effective file loading

      open(unit=1,status='old',file=
     +'table2.dat')
      write(6,*) '....Loading file: table2.dat'
      do i__=1,29
        read(1,'(A101)')ar__1
        read(ar__1,2)
     +  Star_1(i__),CCID(i__),Date(i__),Sep(i__),e_Sep(i__),PA(i__),
     +  e_PA(i__),Kmag(i__),DeltaK(i__),e_DeltaK(i__),Status(i__),
     +  pbg(i__),Mass(i__),B_Mass(i__),b_Mass_1(i__),Teff(i__),
     +  B_Teff(i__),b_Teff_1(i__)
        if(ar__1(73:76) .EQ. '') Mass(i__) = rNULL__
        if(ar__1(78:81) .EQ. '') B_Mass(i__) = rNULL__
        if(ar__1(83:86) .EQ. '') b_Mass_1(i__) = rNULL__
        if(ar__1(88:91) .EQ. '') Teff(i__) = iNULL__
        if(ar__1(93:96) .EQ. '') B_Teff(i__) = iNULL__
        if(ar__1(98:101) .EQ. '') b_Teff_1(i__) = iNULL__
c    ..............Just test output...........
        write(6,2)
     +  Star_1(i__),CCID(i__),Date(i__),Sep(i__),e_Sep(i__),PA(i__),
     +  e_PA(i__),Kmag(i__),DeltaK(i__),e_DeltaK(i__),Status(i__),
     +  pbg(i__),Mass(i__),B_Mass(i__),b_Mass_1(i__),Teff(i__),
     +  B_Teff(i__),b_Teff_1(i__)
c    .......End.of.Just test output...........
      end do
      close(1)

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

C  Loading file 'det-lim.dat'	! Contrast limits of our data reduction for
*                                 all targets

C  Format for file interpretation

    3 format(A8,1X,F4.2,1X,F5.2,1X,F5.2,1X,F6.2,1X,F6.2,1X,F6.2)

C  Effective file loading

      open(unit=1,status='old',file=
     +'det-lim.dat')
      write(6,*) '....Loading file: det-lim.dat'
      do i__=1,4815
        read(1,'(A46)')ar__2
        read(ar__2,3)
     +  Star_2(i__),Sep_1(i__),DeltaKs(i__),e_DeltaKs(i__),
     +  Masslimit(i__),E_Masslimit(i__),e_Masslimit_1(i__)
c    ..............Just test output...........
        write(6,3)
     +  Star_2(i__),Sep_1(i__),DeltaKs(i__),e_DeltaKs(i__),
     +  Masslimit(i__),E_Masslimit(i__),e_Masslimit_1(i__)
c    .......End.of.Just test output...........
      end do
      close(1)

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