FORTRAN Generation
(/./ftp/cats/J/A_A/364/102)

Conversion of standardized ReadMe file for file /./ftp/cats/J/A_A/364/102 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-Mar-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/364/102       Abundances of field BHB star candidates  (Kinman+, 2000)
*================================================================================
*A spectroscopic study of field BHB star candidates
*    Kinman T., Castelli F., Cacciari C., Bragaglia A., Harmer D., Valdes F.
*      <Astron. Astrophys. 364, 102 (2000)>
*      =2000A&A...364..102K      (SIMBAD/NED BibCode)
C=============================================================================

C  Internal variables

      integer*4 i__

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

C  Declarations for 'stars.dat'	! Star positions and magnitudes (from Simbad)

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

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

      character*10  Name       (nr__) ! Object name
      integer*4     RAh        (nr__) ! (h) Right ascension (J2000.0)
      integer*4     RAm        (nr__) ! (min) Right ascension (J2000.0)
      real*4        RAs        (nr__) ! (s) Right ascension (J2000.0)
      character*1   DE_        (nr__) ! Declination sign (J2000.0)
      integer*4     DEd        (nr__) ! (deg) Declination (J2000.0)
      integer*4     DEm        (nr__) ! (arcmin) Declination (J2000.0)
      integer*4     DEs        (nr__) ! (arcsec) Declination (J2000.0)
      real*4        Bmag       (nr__) ! (mag) ? B magnitude
      real*4        Vmag       (nr__) ! (mag) ? V magnitude
      character*20  SpType     (nr__) ! Spectral type

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

C  Declarations for 'table4.dat'	! KPNO equivalent widths and abundances

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

      character*11  Name_1     (nr__1) ! Star name
      real*8        lambda     (nr__1) ! (0.1nm) Wavelength
      character*4   El         (nr__1) ! Element
      character*5   mult       (nr__1) ! Multiplet number
      real*4        loggf      (nr__1) ! Oscillator strength
      character*4   r_loggf    (nr__1) ! Source of log gf (1)
      integer*4     EW         (nr__1) ! (0.1pm) ? Equivalent width
      character*1   u_EW       (nr__1) ! Uncertainty flag on EW
      real*4        log_El_Ntot_(nr__1) ! ? Elemental abundance
*Note (1): Source of log gf (only in table4.dat):
*   KP   : Kurucz & Peytremann 1975, Cat. <VI/10>
*   NSB1 : Wiese, Smith & Miles 1969, NSRDS-NBS Vol. II
*   NSB2 : Wiese & Fuhr 1975, J. Phys. Chem. Ref. Data 4. 263
*   NSB2 : Miles & Wiese 1969, NBS technical Note 274
*   MFW  : Martin, Fuhr & Wiese 1984, Cat. <VI/72>
*   FMW  : Fuhr, Martin & Wiese 1988, Cat. <VI/72>
*   BK   : Bridges & Kornblith 1974ApJ...192..793B

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

C  Declarations for 'table5.dat'	! ESO-CAT equivalent widths and abundances

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

      character*11  Name_2     (nr__2) ! Star name
      real*8        lambda_1   (nr__2) ! (0.1nm) Wavelength
      character*4   El_1       (nr__2) ! Element
      character*5   mult_1     (nr__2) ! Multiplet number
      real*4        loggf_1    (nr__2) ! Oscillator strength
      character*4   r_loggf_1  (nr__2) ! Source of log gf (1)
      integer*4     EW_1       (nr__2) ! (0.1pm) ? Equivalent width
      character*1   u_EW_1     (nr__2) ! Uncertainty flag on EW
      real*4        log_El_Ntot__1(nr__2) ! ? Elemental abundance
*Note (1): Source of log gf (only in table4.dat):
*   KP   : Kurucz & Peytremann 1975, Cat. <VI/10>
*   NSB1 : Wiese, Smith & Miles 1969, NSRDS-NBS Vol. II
*   NSB2 : Wiese & Fuhr 1975, J. Phys. Chem. Ref. Data 4. 263
*   NSB2 : Miles & Wiese 1969, NBS technical Note 274
*   MFW  : Martin, Fuhr & Wiese 1984, Cat. <VI/72>
*   FMW  : Fuhr, Martin & Wiese 1988, Cat. <VI/72>
*   BK   : Bridges & Kornblith 1974ApJ...192..793B

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

C  Loading file 'stars.dat'	! Star positions and magnitudes (from Simbad)

C  Format for file interpretation

    1 format(
     +  A10,4X,I2,1X,I2,1X,F4.1,1X,A1,I2,1X,I2,1X,I2,3X,F5.2,1X,F5.2,
     +  1X,A20)

C  Effective file loading

      open(unit=1,status='old',file=
     +'stars.dat')
      write(6,*) '....Loading file: stars.dat'
      do i__=1,29
        read(1,'(A69)')ar__
        read(ar__,1)
     +  Name(i__),RAh(i__),RAm(i__),RAs(i__),DE_(i__),DEd(i__),
     +  DEm(i__),DEs(i__),Bmag(i__),Vmag(i__),SpType(i__)
        if(ar__(38:42) .EQ. '') Bmag(i__) = rNULL__
        if(ar__(44:48) .EQ. '') Vmag(i__) = rNULL__
        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)
     +  Name(i__),RAh(i__),RAm(i__),RAs(i__),DE_(i__),DEd(i__),
     +  DEm(i__),DEs(i__),Bmag(i__),Vmag(i__),SpType(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 'table4.dat'	! KPNO equivalent widths and abundances

C  Format for file interpretation

    2 format(A11,1X,F8.3,1X,A4,1X,A5,1X,F6.3,1X,A4,2X,I3,A1,1X,F6.2)

C  Effective file loading

      open(unit=1,status='old',file=
     +'table4.dat')
      write(6,*) '....Loading file: table4.dat'
      do i__=1,601
        read(1,'(A56)')ar__1
        read(ar__1,2)
     +  Name_1(i__),lambda(i__),El(i__),mult(i__),loggf(i__),
     +  r_loggf(i__),EW(i__),u_EW(i__),log_El_Ntot_(i__)
        if(ar__1(46:48) .EQ. '') EW(i__) = iNULL__
        if(ar__1(51:56) .EQ. '') log_El_Ntot_(i__) = rNULL__
c    ..............Just test output...........
        write(6,2)
     +  Name_1(i__),lambda(i__),El(i__),mult(i__),loggf(i__),
     +  r_loggf(i__),EW(i__),u_EW(i__),log_El_Ntot_(i__)
c    .......End.of.Just test output...........
      end do
      close(1)

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

C  Loading file 'table5.dat'	! ESO-CAT equivalent widths and abundances

C  Format for file interpretation

    3 format(A11,1X,F8.3,1X,A4,1X,A5,1X,F6.3,1X,A4,2X,I3,A1,1X,F6.2)

C  Effective file loading

      open(unit=1,status='old',file=
     +'table5.dat')
      write(6,*) '....Loading file: table5.dat'
      do i__=1,69
        read(1,'(A56)')ar__2
        read(ar__2,3)
     +  Name_2(i__),lambda_1(i__),El_1(i__),mult_1(i__),loggf_1(i__),
     +  r_loggf_1(i__),EW_1(i__),u_EW_1(i__),log_El_Ntot__1(i__)
        if(ar__2(46:48) .EQ. '') EW_1(i__) = iNULL__
        if(ar__2(51:56) .EQ. '') log_El_Ntot__1(i__) = rNULL__
c    ..............Just test output...........
        write(6,3)
     +  Name_2(i__),lambda_1(i__),El_1(i__),mult_1(i__),loggf_1(i__),
     +  r_loggf_1(i__),EW_1(i__),u_EW_1(i__),log_El_Ntot__1(i__)
c    .......End.of.Just test output...........
      end do
      close(1)

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