FORTRAN Generation
(/./ftp/cats/J/A_A/597/A90)

Conversion of standardized ReadMe file for file /./ftp/cats/J/A_A/597/A90 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 2026-Aug-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/597/A90       rho Oph proper motions and photometry     (Ducourant+, 2017)
*================================================================================
*Proper motion survey and kinematic analysis of the rho Ophiuchi embedded
*cluster.
*    Ducourant C., Teixeira R., Krone-Martins A., Bontemps S., Despois D.,
*    Galli P.A.B., Bouy H., Le Campion J.F., Rapaport M., Cuillandre J.C.
*    <Astron. Astrophys. 597, A90 (2017)>
*    =2017A&A...597A..90D        (SIMBAD/NED BibCode)
C=============================================================================

C  Internal variables

      integer*4 i__

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

C  Declarations for 'table6.dat'	! Photometry (J,H,Ks,W1,W2,W3,W4) of 68 members
                                and 14 candidate members

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

      character*28  Name        ! Name
      character*1   f_Jmag      ! [*] Flag on Jmag (G1)
      real*4        Jmag        ! (mag) ? 2MASS J magnitude
      real*4        e_Jmag      ! (mag) ? 2MASS standard e_or on J magnitude
      character*1   f_Hmag      ! [*] Flag on Hmag (G1)
      real*4        Hmag        ! (mag) ? 2MASS H magnitude
      real*4        e_Hmag      ! (mag) ? 2MASS standard e_or on H magnitude
      character*1   f_Kmag      ! [*] Flag on Kmag (G1)
      real*4        Kmag        ! (mag) 2MASS K magnitude
      real*4        e_Kmag      ! (mag) ? 2MASS standard error on K magnitude
      real*4        W1mag       ! (mag) ? ALLWISE W1 magnitude
      real*4        e_W1mag     ! (mag) ? ALLWISE standard error on W1 magnitude
      real*4        W2mag       ! (mag) ? ALLWISE W2 magnitude
      real*4        e_W2mag     ! (mag) ? ALLWISE standard error on W2 magnitude
      real*4        W3mag       ! (mag) ? ALLWISE W3 magnitude
      real*4        e_W3mag     ! (mag) ? ALLWISE standard error on W3 magnitude
      real*4        W4mag       ! (mag) ? ALLWISE W4 magnitude
      real*4        e_W4mag     ! (mag) ? ALLWISE standard error on W4 magnitude
      character*1   Memb        ! [M/C] Flag : M=member, C=candidate member

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

C  Declarations for 'table7.dat'	! Astrometric parameters and membership probability
                                for 68 members and 14 candidate members

      integer*4 nr__1
      parameter (nr__1=82)	! Number of records
      character*126 ar__1  	! 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*28  Name_1      ! Name
      integer*4     RAh         ! (h) Right Ascension (J2000) at epoch EpRA
      integer*4     RAm         ! (min) Right Ascension (J2000)
      real*8        RAs         ! (s) Right Ascension (J2000)
      character*1   DE_         ! Declination sign (J2000) at epoch EpDE
      integer*4     DEd         ! (deg) Declination (J2000)
      integer*4     DEm         ! (arcmin) Declination (J2000)
      real*4        DEs         ! (arcsec) Declination (J2000)
      integer*4     e_pos       ! (mas) Standard error on positions
      real*4        pmRA        ! (mas/yr) Proper motion in RA*cos(DE)
      real*4        e_pmRA      ! (mas/yr) Standard error on proper motion
*                                     in RA*cos(DEC)
      real*4        pmDE        ! (mas/yr) Proper motion in RA*cos(DE)
      real*4        e_pmDE      ! (mas/yr) Standard error on proper motion in DE
      real*4        EpRA        ! (yr) Mean epoch in RA
      real*4        EpDE        ! (yr) Mean epoch in DE
      character*1   f_Ksmag     ! [*] Note on Ksmag (G1)
      real*4        Ksmag       ! (mag) 2MASS Ks magnitude
      real*4        e_Ksmag     ! (mag) ? Error on Ks magnitude
      integer*4     Nep         ! Number of epochs of observations used
*                                     to derive proper motions
      real*4        Tbase       ! (yr) Time base of observations used
*                                     to derive proper motions
      real*4        Prob        ! Membership probability
      character*1   Memb_1      ! [C/M] Flag : M=member, C=candidate member

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

C  Declarations for 'table8.dat'	! Evolutionary status of 68 members and 14
                                candidate members

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

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

      character*28  Name_2      ! Name
      character*31  OName       ! Other name
      integer*4     RAh_1       ! (h) Right Ascension (J2000) at epoch EpRA
      integer*4     RAm_1       ! (min) Right Ascension (J2000) at epoch EpRA
      real*8        RAs_1       ! (s) Right Ascension (J2000) at epoch EpRA
      character*1   DE__1       ! Declination sign (J2000) at epoch EpDE
      integer*4     DEd_1       ! (deg) Declination (J2000) at epoch EpDE
      integer*4     DEm_1       ! (arcmin) Declination (J2000) at epoch EpDE
      real*4        DEs_1       ! (arcsec) Declination (J2000) at epoch EpDE
      real*4        EpRA_1      ! (yr) Mean epoch in RA
      real*4        EpDE_1      ! (yr) Mean epoch in DE
      character*3   Status      ! Young stellar object status as given by
*                                   CDS-Simbad
      character*1   f_SED       ! [*] Note on SED (1)
      character*3   SED         ! SED class
      character*1   n_SED       ! [ab] Note on SED (2)
      integer*4     r_SED       ! ? Reference for SED
      character*8   SpType      ! Spectral type found in the litterature
      integer*4     r_SpType    ! ? Reference for SpType
      character*1   Memb_2      ! [M/C] Flag : M=member, C=candidate member
*Note (1): Classes preceded by an asterisk were assigned in this work
*Note (2): Note on SED as follows:
*  a = this object is classified as class II by Bontemps et al. (2001,
*       Cat. J/A+A/372/173) but was classified as class III by our algorithm
*  b = this object is classified as class I by Bontemps et al. (2001,
*       Cat. J/A+A/372/173) but was classified as class II by our algorithm

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

C  Declarations for 'refs.dat'	! References

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

      integer*4     Ref         ! Reference number
      character*19  BibCode     ! BibCode
      character*26  Aut         ! Author's name
      character*78  Com         ! Comments

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

C  Loading file 'table6.dat'	! Photometry (J,H,Ks,W1,W2,W3,W4) of 68 members
*                                and 14 candidate members

C  Format for file interpretation

    1 format(
     +  A28,A1,F6.3,1X,F5.3,1X,A1,F6.3,1X,F5.3,1X,A1,F6.3,1X,F5.3,1X,
     +  F6.3,1X,F5.3,1X,F6.3,1X,F5.3,1X,F6.3,1X,F5.3,1X,F6.3,1X,F5.3,
     +  1X,A1)

C  Effective file loading

      open(unit=1,status='old',file=
     +'table6.dat')
      write(6,*) '....Loading file: table6.dat'
      do i__=1,82
        read(1,'(A123)')ar__
        read(ar__,1)
     +  Name,f_Jmag,Jmag,e_Jmag,f_Hmag,Hmag,e_Hmag,f_Kmag,Kmag,e_Kmag,
     +  W1mag,e_W1mag,W2mag,e_W2mag,W3mag,e_W3mag,W4mag,e_W4mag,Memb
        if(ar__(30:35) .EQ. '') Jmag = rNULL__
        if(ar__(37:41) .EQ. '') e_Jmag = rNULL__
        if(ar__(44:49) .EQ. '') Hmag = rNULL__
        if(ar__(51:55) .EQ. '') e_Hmag = rNULL__
        if(ar__(65:69) .EQ. '') e_Kmag = rNULL__
        if(ar__(71:76) .EQ. '') W1mag = rNULL__
        if(ar__(78:82) .EQ. '') e_W1mag = rNULL__
        if(ar__(84:89) .EQ. '') W2mag = rNULL__
        if(ar__(91:95) .EQ. '') e_W2mag = rNULL__
        if(ar__(97:102) .EQ. '') W3mag = rNULL__
        if(ar__(104:108) .EQ. '') e_W3mag = rNULL__
        if(ar__(110:115) .EQ. '') W4mag = rNULL__
        if(ar__(117:121) .EQ. '') e_W4mag = rNULL__
c    ..............Just test output...........
        write(6,1)
     +  Name,f_Jmag,Jmag,e_Jmag,f_Hmag,Hmag,e_Hmag,f_Kmag,Kmag,e_Kmag,
     +  W1mag,e_W1mag,W2mag,e_W2mag,W3mag,e_W3mag,W4mag,e_W4mag,Memb
c    .......End.of.Just test output...........
      end do
      close(1)

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

C  Loading file 'table7.dat'	! Astrometric parameters and membership probability
*                                for 68 members and 14 candidate members

C  Format for file interpretation

    2 format(
     +  A28,1X,I2,1X,I2,1X,F7.4,1X,A1,I2,1X,I2,1X,F6.3,1X,I2,1X,F5.1,
     +  1X,F4.1,1X,F5.1,1X,F4.1,1X,F6.1,1X,F6.1,1X,A1,F6.3,1X,F5.3,1X,
     +  I3,1X,F5.1,1X,F4.2,1X,A1)

C  Effective file loading

      open(unit=1,status='old',file=
     +'table7.dat')
      write(6,*) '....Loading file: table7.dat'
      do i__=1,82
        read(1,'(A126)')ar__1
        read(ar__1,2)
     +  Name_1,RAh,RAm,RAs,DE_,DEd,DEm,DEs,e_pos,pmRA,e_pmRA,pmDE,
     +  e_pmDE,EpRA,EpDE,f_Ksmag,Ksmag,e_Ksmag,Nep,Tbase,Prob,Memb_1
        if(ar__1(105:109) .EQ. '') e_Ksmag = 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,2)
     +  Name_1,RAh,RAm,RAs,DE_,DEd,DEm,DEs,e_pos,pmRA,e_pmRA,pmDE,
     +  e_pmDE,EpRA,EpDE,f_Ksmag,Ksmag,e_Ksmag,Nep,Tbase,Prob,Memb_1
        write(6,'(6H Pos: 2F8.4)') RAdeg,DEdeg
c    .......End.of.Just test output...........
      end do
      close(1)

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

C  Loading file 'table8.dat'	! Evolutionary status of 68 members and 14
*                                candidate members

C  Format for file interpretation

    3 format(
     +  A28,1X,A31,1X,I2,1X,I2,1X,F7.4,A1,I2,1X,I2,1X,F6.3,1X,F6.1,1X,
     +  F6.1,1X,A3,1X,A1,A3,A1,1X,I2,1X,A8,I2,1X,A1)

C  Effective file loading

      open(unit=1,status='old',file=
     +'table8.dat')
      write(6,*) '....Loading file: table8.dat'
      do i__=1,82
        read(1,'(A127)')ar__2
        read(ar__2,3)
     +  Name_2,OName,RAh_1,RAm_1,RAs_1,DE__1,DEd_1,DEm_1,DEs_1,EpRA_1,
     +  EpDE_1,Status,f_SED,SED,n_SED,r_SED,SpType,r_SpType,Memb_2
        if(ar__2(113:114) .EQ. '') r_SED = iNULL__
        if(ar__2(124:125) .EQ. '') r_SpType = iNULL__
        RAdeg_1 = rNULL__
        DEdeg_1 = rNULL__
c  Derive coordinates RAdeg_1 and DEdeg_1 from input data
c  (RAdeg_1 and DEdeg_1 are set to rNULL__ when unknown)
        if(RAh_1 .GT. -180) RAdeg_1=RAh_1*15.
        if(RAm_1 .GT. -180) RAdeg_1=RAdeg_1+RAm_1/4.
        if(RAs_1 .GT. -180) RAdeg_1=RAdeg_1+RAs_1/240.
        if(DEd_1 .GE. 0) DEdeg_1=DEd_1
        if(DEm_1 .GE. 0) DEdeg_1=DEdeg_1+DEm_1/60.
        if(DEs_1 .GE. 0) DEdeg_1=DEdeg_1+DEs_1/3600.
        if(DE__1.EQ.'-'.AND.DEdeg_1.GE.0) DEdeg_1=-DEdeg_1
c    ..............Just test output...........
        write(6,3)
     +  Name_2,OName,RAh_1,RAm_1,RAs_1,DE__1,DEd_1,DEm_1,DEs_1,EpRA_1,
     +  EpDE_1,Status,f_SED,SED,n_SED,r_SED,SpType,r_SpType,Memb_2
        write(6,'(6H Pos: 2F8.4)') RAdeg_1,DEdeg_1
c    .......End.of.Just test output...........
      end do
      close(1)

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

C  Loading file 'refs.dat'	! References

C  Format for file interpretation

    4 format(I2,1X,A19,1X,A26,1X,A78)

C  Effective file loading

      open(unit=1,status='old',file=
     +'refs.dat')
      write(6,*) '....Loading file: refs.dat'
      do i__=1,23
        read(1,'(A128)')ar__3
        read(ar__3,4)Ref,BibCode,Aut,Com
c    ..............Just test output...........
        write(6,4)Ref,BibCode,Aut,Com
c    .......End.of.Just test output...........
      end do
      close(1)

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