FORTRAN Generation
(/./ftp/cats/J/A_A/480/379)

Conversion of standardized ReadMe file for file /./ftp/cats/J/A_A/480/379 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 2024-Apr-19
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/480/379       Abundances of 59 red giants in LMC          (Pompeia+, 2008)
*================================================================================
*Chemical abundances in LMC stellar populations. I. The Inner disk sample.
*    Pompeia L., Hill V., Spite M., Cole A., Primas F., Romaniello M.,
*    Pasquini L., Cioni M.-R., Smecker-Hane T.
*   <Astron. Astrophys. 480, 379 (2008)>
*   =2008A&A...480..379P
C=============================================================================

C  Internal variables

      integer*4 i__

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

C  Declarations for 'table1.dat'	! Photometric Data

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

      integer*4     RGB        (nr__) ! Reference star number
      character*16  v2MASS     (nr__) ! 2MASS Designation
      real*4        Vmag       (nr__) ! (mag) CTIO Photometry
      real*4        Imag       (nr__) ! (mag) CTIO Photometry
      real*4        Jmag       (nr__) ! (mag) ?=- 2MASS J Photometry
      real*4        Kmag       (nr__) ! (mag) ?=- 2MASS Ks Photometry

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

C  Declarations for 'abund.dat'	! Abundances ratios (tables 5-8 of the paper)

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

      integer*4     RGB_1      (nr__1) ! Reference star number
      real*4        v_Fe_H_    (nr__1) ! ([-]) Fe I abundance ratio
      real*4        e__Fe_H_   (nr__1) ! ([-]) Fe I abundance error
      real*4        v_Si_Fe_   (nr__1) ! ([-]) ?=- Si I abundance ratio
      real*4        e__Si_Fe_  (nr__1) ! ([-]) ?=- Si I abundance error
      real*4        v_Ca_Fe_   (nr__1) ! ([-]) ?=- Ca I abundance ratio
      real*4        e__Ca_Fe_  (nr__1) ! ([-]) Ca I abundance error
      real*4        v_TiI_Fe_  (nr__1) ! ([-]) Ti I abundance ratio
      real*4        e__TiI_Fe_ (nr__1) ! ([-]) Ti I abundance error
      real*4        v_TiII_Fe_ (nr__1) ! ([-]) ?=- Ti II abundance ratio
      real*4        e__TiII_Fe_(nr__1) ! ([-]) Ti II abundance error
      character*1   l__O_Fe_   (nr__1) ! Limit flag on [O/Fe]
      real*4        v_O_Fe_    (nr__1) ! ([-]) ?=- [OI] abundance ratio
      real*4        v_Mg_Fe_   (nr__1) ! ([-]) ?=- Mg I abundance ratio
      real*4        v_Na_Fe_   (nr__1) ! ([-]) ?=- Na I abundance ratio
      real*4        e__Na_Fe_  (nr__1) ! ([-]) Na I abundance error
      character*1   l__Sc_Fe_  (nr__1) ! Limit flag on [Sc/Fe]
      real*4        v_Sc_Fe_   (nr__1) ! ([-]) ?=- Sc II abundance ratio
      real*4        v_Cu_Fe_   (nr__1) ! ([-]) ?=- Cu II abundance ratio
      real*4        v_Cr_Fe_   (nr__1) ! ([-]) Cr abundance ratio
      real*4        e__Cr_Fe_  (nr__1) ! ([-]) Cr abundance error
      real*4        v_Ni_Fe_   (nr__1) ! ([-]) ?=- Ni I abundance ratio
      real*4        e__Ni_Fe_  (nr__1) ! ([-]) Ni I abundance error
      real*4        v_V_Fe_    (nr__1) ! ([-]) ?=- V I abundance ratio
      real*4        e__V_Fe_   (nr__1) ! ([-]) ?=- V I abundance error
      character*1   l__Co_Fe_  (nr__1) ! Limit flag on [Co/Fe]
      real*4        v_Co_Fe_   (nr__1) ! ([-]) ?=- Co I abundance ratio
      character*1   l__La_Fe_  (nr__1) ! Limit flag on [La/Fe]
      real*4        v_La_Fe_   (nr__1) ! ([-]) ?=- La II abundance ratio
      real*4        v_Ba_Fe_   (nr__1) ! ([-]) ?=- Ba II abundance ratio
      character*1   l__Y_Fe_   (nr__1) ! Limit flag on [La/Fe]
      real*4        v_Y_Fe_    (nr__1) ! ([-]) ?=- Y I abundance ratio
      character*1   l__Zr_Fe_  (nr__1) ! Limit flag on [La/Fe]
      real*4        v_Zr_Fe_   (nr__1) ! ([-]) ?=- Zr I abundance error

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

C  Declarations for 'table3.dat'	! Errors due to stellar parameters uncertainties

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

      character*11  Ratio      (nr__2) ! Elemental Ratio
      real*4        d_Teff     (nr__2) ! Abundance change due to a change of T=+100K
      real*4        d_logg     (nr__2) ! Abundance change due to a change of logg=-0.4dex
      real*4        d_Vt       (nr__2) ! Abundance change due to a change of Vt=+0.2km/s
      real*4        d__Fe_H_   (nr__2) ! Abundance change due to a change [Fe/H]=-0.15dex
      real*4        d_tot      (nr__2) ! Total error due to stellar parameter
*                                uncertainties

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

C  Declarations for 'table4.dat'	! Line List

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

      real*8        lambda     (nr__3) ! (0.1nm) Wavelength of the line
      character*4   Ion        (nr__3) ! Element code and ionization state
      real*4        EP         (nr__3) ! (eV) Lower excitation potential
      real*4        loggf      (nr__3) ! Logarithm of oscillator strength
      integer*4     Ref        (nr__3) ! Line data reference sources (1)
*Note (1): Gf sources as follows:
*      1 = NIST (http://physics.nist.gov/PhysRefData/ASD/index.html)
*      2 = Nave et al., 1994, Cat. <J/ApJS/94/221>
*      3 = Biemont et al., 1991A&A...249..539B
*      4 = gf-values adjusted to provide the same solar abundances of
*          Grevesse & Sauval, 1998, Cat. <J/A+A/437/348>
*          adopting Holweger & Muller solar model atmosphere
*      5 = McWilliam & Rich, 1994ApJS...91..749M
*      6 = Smith et al., 2000AJ....119.1239S
*      7 = Sneden et al., 1996ApJ...467..819S
*      8 = VALD (ams.astro.univie.ac.at/vald/)
*      9 = Shetrone et al., 2003AJ....125..684S

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

C  Loading file 'table1.dat'	! Photometric Data

C  Format for file interpretation

    1 format(4X,I4,3X,A16,3X,F6.3,3X,F6.3,3X,F6.3,3X,F6.3)

C  Effective file loading

      open(unit=1,status='old',file=
     +'table1.dat')
      write(6,*) '....Loading file: table1.dat'
      do i__=1,59
        read(1,'(A63)')ar__
        read(ar__,1)
     +  RGB(i__),v2MASS(i__),Vmag(i__),Imag(i__),Jmag(i__),Kmag(i__)
        if (idig(ar__(49:54)).EQ.0) Jmag(i__) =  rNULL__
        if (idig(ar__(58:63)).EQ.0) Kmag(i__) =  rNULL__
c    ..............Just test output...........
        write(6,1)
     +  RGB(i__),v2MASS(i__),Vmag(i__),Imag(i__),Jmag(i__),Kmag(i__)
c    .......End.of.Just test output...........
      end do
      close(1)

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

C  Loading file 'abund.dat'	! Abundances ratios (tables 5-8 of the paper)

C  Format for file interpretation

    2 format(
     +  4X,I4,1X,F5.2,1X,F5.2,1X,F5.2,1X,F4.2,1X,F5.2,1X,F4.2,1X,F5.2,
     +  1X,F4.2,1X,F5.2,1X,F4.2,1X,A1,F5.2,1X,F4.2,1X,F5.2,1X,F4.2,1X,
     +  A1,F5.2,1X,F5.2,1X,F5.2,1X,F4.2,1X,F5.2,1X,F4.2,1X,F5.2,1X,
     +  F4.2,1X,A1,F5.2,1X,A1,F5.2,1X,F5.2,1X,A1,F5.2,2X,A1,F5.2)

C  Effective file loading

      open(unit=1,status='old',file=
     +'abund.dat')
      write(6,*) '....Loading file: abund.dat'
      do i__=1,59
        read(1,'(A168)')ar__1
        read(ar__1,2)
     +  RGB_1(i__),v_Fe_H_(i__),e__Fe_H_(i__),v_Si_Fe_(i__),
     +  e__Si_Fe_(i__),v_Ca_Fe_(i__),e__Ca_Fe_(i__),v_TiI_Fe_(i__),
     +  e__TiI_Fe_(i__),v_TiII_Fe_(i__),e__TiII_Fe_(i__),
     +  l__O_Fe_(i__),v_O_Fe_(i__),v_Mg_Fe_(i__),v_Na_Fe_(i__),
     +  e__Na_Fe_(i__),l__Sc_Fe_(i__),v_Sc_Fe_(i__),v_Cu_Fe_(i__),
     +  v_Cr_Fe_(i__),e__Cr_Fe_(i__),v_Ni_Fe_(i__),e__Ni_Fe_(i__),
     +  v_V_Fe_(i__),e__V_Fe_(i__),l__Co_Fe_(i__),v_Co_Fe_(i__),
     +  l__La_Fe_(i__),v_La_Fe_(i__),v_Ba_Fe_(i__),l__Y_Fe_(i__),
     +  v_Y_Fe_(i__),l__Zr_Fe_(i__),v_Zr_Fe_(i__)
        if (idig(ar__1(22:26)).EQ.0) v_Si_Fe_(i__) =  rNULL__
        if (idig(ar__1(28:31)).EQ.0) e__Si_Fe_(i__) =  rNULL__
        if (idig(ar__1(33:37)).EQ.0) v_Ca_Fe_(i__) =  rNULL__
        if (idig(ar__1(55:59)).EQ.0) v_TiII_Fe_(i__) =  rNULL__
        if (idig(ar__1(67:71)).EQ.0) v_O_Fe_(i__) =  rNULL__
        if (idig(ar__1(73:76)).EQ.0) v_Mg_Fe_(i__) =  rNULL__
        if (idig(ar__1(78:82)).EQ.0) v_Na_Fe_(i__) =  rNULL__
        if (idig(ar__1(90:94)).EQ.0) v_Sc_Fe_(i__) =  rNULL__
        if (idig(ar__1(96:100)).EQ.0) v_Cu_Fe_(i__) =  rNULL__
        if (idig(ar__1(113:117)).EQ.0) v_Ni_Fe_(i__) =  rNULL__
        if (idig(ar__1(124:128)).EQ.0) v_V_Fe_(i__) =  rNULL__
        if (idig(ar__1(130:133)).EQ.0) e__V_Fe_(i__) =  rNULL__
        if (idig(ar__1(136:140)).EQ.0) v_Co_Fe_(i__) =  rNULL__
        if (idig(ar__1(143:147)).EQ.0) v_La_Fe_(i__) =  rNULL__
        if (idig(ar__1(149:153)).EQ.0) v_Ba_Fe_(i__) =  rNULL__
        if (idig(ar__1(156:160)).EQ.0) v_Y_Fe_(i__) =  rNULL__
        if (idig(ar__1(164:168)).EQ.0) v_Zr_Fe_(i__) =  rNULL__
c    ..............Just test output...........
        write(6,2)
     +  RGB_1(i__),v_Fe_H_(i__),e__Fe_H_(i__),v_Si_Fe_(i__),
     +  e__Si_Fe_(i__),v_Ca_Fe_(i__),e__Ca_Fe_(i__),v_TiI_Fe_(i__),
     +  e__TiI_Fe_(i__),v_TiII_Fe_(i__),e__TiII_Fe_(i__),
     +  l__O_Fe_(i__),v_O_Fe_(i__),v_Mg_Fe_(i__),v_Na_Fe_(i__),
     +  e__Na_Fe_(i__),l__Sc_Fe_(i__),v_Sc_Fe_(i__),v_Cu_Fe_(i__),
     +  v_Cr_Fe_(i__),e__Cr_Fe_(i__),v_Ni_Fe_(i__),e__Ni_Fe_(i__),
     +  v_V_Fe_(i__),e__V_Fe_(i__),l__Co_Fe_(i__),v_Co_Fe_(i__),
     +  l__La_Fe_(i__),v_La_Fe_(i__),v_Ba_Fe_(i__),l__Y_Fe_(i__),
     +  v_Y_Fe_(i__),l__Zr_Fe_(i__),v_Zr_Fe_(i__)
c    .......End.of.Just test output...........
      end do
      close(1)

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

C  Loading file 'table3.dat'	! Errors due to stellar parameters uncertainties

C  Format for file interpretation

    3 format(A11,F5.2,3X,F5.2,3X,F5.2,3X,F5.2,5X,F4.2)

C  Effective file loading

      open(unit=1,status='old',file=
     +'table3.dat')
      write(6,*) '....Loading file: table3.dat'
      do i__=1,19
        read(1,'(A49)')ar__2
        read(ar__2,3)
     +  Ratio(i__),d_Teff(i__),d_logg(i__),d_Vt(i__),d__Fe_H_(i__),
     +  d_tot(i__)
c    ..............Just test output...........
        write(6,3)
     +  Ratio(i__),d_Teff(i__),d_logg(i__),d_Vt(i__),d__Fe_H_(i__),
     +  d_tot(i__)
c    .......End.of.Just test output...........
      end do
      close(1)

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

C  Loading file 'table4.dat'	! Line List

C  Format for file interpretation

    4 format(F8.3,3X,A4,2X,F5.3,6X,F6.3,5X,I1)

C  Effective file loading

      open(unit=1,status='old',file=
     +'table4.dat')
      write(6,*) '....Loading file: table4.dat'
      do i__=1,120
        read(1,'(A40)')ar__3
        read(ar__3,4)lambda(i__),Ion(i__),EP(i__),loggf(i__),Ref(i__)
c    ..............Just test output...........
        write(6,4)lambda(i__),Ion(i__),EP(i__),loggf(i__),Ref(i__)
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