FORTRAN Generation
(/./ftp/cats/J/A_A/565/A121)

Conversion of standardized ReadMe file for file /./ftp/cats/J/A_A/565/A121 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-May-17
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/565/A121    Abundances of 47 Tuc turn-off stars     (Dobrovolskas+, 2014)
*================================================================================
*Abundances of lithium, oxygen, and sodium in the turn-off stars of
*Galactic globular cluster 47 Tucanae.
*    Dobrovolskas V., Kucinskas A., Bonifacio P., Korotin S.A., Steffen M.,
*    Sbordone L., Caffau E., Ludwig H.-G., Royer F., Prakapavicius D.
*   <Astron. Astrophys., 565, A121-121 (2014)>
*   =2014A&A...565A.121D
C=============================================================================

C  Internal variables

      integer*4 i__

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

C  Declarations for 'tablea1.dat'	! List of the investigated TO stars in 47 Tuc,
                             their adopted atmospheric parameters and
                             determined abundances of Li, O, and Na

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

C  J2000 position composed of: RAdeg DEdeg
      integer*4     ID          ! Identification number
      real*8        RAdeg       ! (deg) Right ascension (J2000)
      real*8        DEdeg       ! (deg) Declination (J2000)
      real*4        Bmag        ! (mag) [17.8/18.1] B magnitude
      real*4        Vmag        ! (mag) [17.2/17.6] V magnitude
      real*4        logg        ! ([cm/s2]) [3.98/4.14] Surface gravity
      integer*4     Teff        ! (K) [5660/5968] Effective temperature
      real*4        A_Li_3N     ! ([-]) ?=- 3D NLTE lithium abundance (1)
      real*4        A_O_1N      ! ([-]) 1D NLTE oxygen abundance (1)
      real*4        A_O_3N      ! ([-]) 3D+NLTE oxygen abundance (1) (2)
      real*4        A_Na_1N     ! ([-]) ?=- 1D NLTE sodium abundance (1)
      real*4        A_Na_3N     ! ([-]) ?=- 3D+NLTE sodium abundance (1) (2)
*Note (1): The abundances were derived assuming identical microturbulence
*  velocity of {ksi}_micro_=1.0km/s for all stars; A(H)=12.
*Note (2): 1D NLTE abundances with 3D-1D abundance corrections taken into
*  account.

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

C  Loading file 'tablea1.dat'	! List of the investigated TO stars in 47 Tuc,
*                             their adopted atmospheric parameters and
*                             determined abundances of Li, O, and Na

C  Format for file interpretation

    1 format(
     +  I8,1X,F7.5,1X,F9.5,1X,F6.3,1X,F6.3,1X,F4.2,1X,I4,1X,F4.2,1X,
     +  F4.2,1X,F4.2,1X,F4.2,1X,F4.2)

C  Effective file loading

      open(unit=1,status='old',file=
     +'tablea1.dat')
      write(6,*) '....Loading file: tablea1.dat'
      do i__=1,110
        read(1,'(A75)')ar__
        read(ar__,1)
     +  ID,RAdeg,DEdeg,Bmag,Vmag,logg,Teff,A_Li_3N,A_O_1N,A_O_3N,
     +  A_Na_1N,A_Na_3N
        if (idig(ar__(52:55)).EQ.0) A_Li_3N =  rNULL__
        if (idig(ar__(67:70)).EQ.0) A_Na_1N =  rNULL__
        if (idig(ar__(72:75)).EQ.0) A_Na_3N =  rNULL__
c    ..............Just test output...........
        write(6,1)
     +  ID,RAdeg,DEdeg,Bmag,Vmag,logg,Teff,A_Li_3N,A_O_1N,A_O_3N,
     +  A_Na_1N,A_Na_3N
c    .......End.of.Just test output...........
      end do
      close(1)

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

C Locate position of first digit in string; or return 0
      integer function idig(c)
      character*(*) c
      character*1 c1
      integer lc,i
      lc=len(c)
      idig=0
      do i=1,lc
         if(c(i:i).ne.' ') go to 1
      end do
    1 if(i.gt.lc) return
      c1=c(i:i)
      if(c1.eq.'.'.or.c1.eq.'-'.or.c1.eq.'+') i=i+1
      if(i.gt.lc) return
      c1=c(i:i)
      if(c1.ge.'0'.and.c1.le.'9') idig=i
      return
      end