FORTRAN Generation
(/./ftp/cats/J/ApJ/663/320)

Conversion of standardized ReadMe file for file /./ftp/cats/J/ApJ/663/320 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.8, on 2014-Sep-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__=-1.e37)     	! NULL real number
      parameter  (iNULL__=-2147483647)	! NULL int  number

C=============================================================================
Cat. J/ApJ/663/320       IR-through-UV extinction curve          (Fitzpatrick+, 2007)
*================================================================================
*An analysis of the shapes of interstellar extinction curves.
*V. The IR-through-UV curve morphology.
*    Fitzpatrick E.L., Massa D.
*   <Astrophys. J., 663, 320-341 (2007)>
*   =2007ApJ...663..320F
C=============================================================================

C  Internal variables

      integer*4 i__

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

C  Declarations for 'table1.dat'	! Basic Data for Survey Stars

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

      character*22  Name       (nr__) ! Star name (1)
      character*15  SpType     (nr__) ! MK Spectral type (2)
      real*4        Vmag       (nr__) ! (mag) The V band magnitude
      integer*4     Dist       (nr__) ! (pc) ? Heliocentric distance (3)
      real*8        GLON       (nr__) ! (deg) Galactic longitude
      real*4        GLAT       (nr__) ! (deg) Galactic latitude
      integer*4     Ref        (nr__) ! ? Reference, in refs.dat file
*Note (1): The stars are listed in order of increasing Right Ascension using
*     the most commonly adopted forms of their names. The first preference
*     was ``HDnnn'', followed by ``BDnnn'', etc. There are 185 survey stars
*     which are members of open clusters or associations. The identity of
*     the cluster or association is either contained in the star name itself
*     (e.g., NGC 457 Pesch 34) or is given in parentheses after the star's
*     name.
*Note (2): Spectral types were selected from those given in the SIMBAD
*     database, and the source of the adopted types is shown in the "Ref".
*     When multiple types were available for a particular star, we selected
*     one based on our own preferred ranking of the sources.
*Note (3): Distances are:
*    NGC 2244 = distance is from Perez et al. (1987PASP...99.1050P);
*    NGC 3293 = distance is from Balona & Crampton (1974MNRAS.166..203B);
*    Trumpler 14 and 16 = distances are from Massey & Johnson
*          (1993, Cat. J/AJ/105/980);
*    Cep OB3 = distance is from Crawford & Barnes (1970AJ.....75..952C).
*
*     The distances to all other clusters or associations are from the Open
*     Clusters and Galactic Structure database maintained by Wilton S. Dias,
*     Jacques Lepine, Bruno S. Alessi, and Andre Moitinho, Cat. B/ocl, and
*     http://www.astro.iag.usp.br/~wilton/ .
*
*     For the non-cluster stars, distances were calculated using the E(B-V)
*     values from this study and the absolute magnitudes from Turner
*     (1980ApJ...240..137T) (for mid-B and earlier types) and Blaauw 1963
*     (in Basic Astronomical Data, ed. K. A. Strand (Chicago:
*     Univ. Chicago Press), chap. 20) (for mid-B and later types).

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

C  Declarations for 'table3.dat'	! Best-Fit Parameters for Survey Stars

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

      character*22  Name_1     (nr__1) ! Star name
      integer*4     Teff       (nr__1) ! (K) Model effective temperature (2)
      integer*4     e_Teff     (nr__1) ! (K) 1{sigma} uncertainty in Teff
      real*4        log_g      (nr__1) ! ([cm/s2]) Log of model surface gravity (3)
      real*4        e_log_g    (nr__1) ! ([cm/s2]) 1{sigma} uncertainty in log(g)
      real*4        v_m_H_     (nr__1) ! ([Sun]) Log of model metallicity (4)
      real*4        e__m_H_    (nr__1) ! ([Sun]) ? 1{sigma} uncertainty in [m/H]
      real*4        Vturb      (nr__1) ! (km/s) Model turbulent velocity (5)
      real*4        e_Vturb    (nr__1) ! (km/s) ? 1{sigma} uncertainty in Vturb
      real*4        theta      (nr__1) ! (mas) Model angular radius
      real*4        e_theta    (nr__1) ! (mas) 1{sigma} uncertainty in theta
      real*4        E_B_V      (nr__1) ! (mag) Model reddening
      real*4        e_E_B_V    (nr__1) ! (mag) 1{sigma} uncertainty in E(B-V)
*Note (2): For the O stars analyzed using the TLUSTY atmosphere models, the
*     values of Teff were adopted from the Spectral Type vs. T_eff_ relation
*     given in Table 2. These stars can be identified by their 1-{sigma}
*     uncertainties, which are +/-1000K.
*
*     Table 2: Adopted Temperature Scale for Main-Sequence O Stars
*     -------------------
*     SpType    Teff (K)
*     -------------------
*     O6        40000
*     O6.5      38500
*     O7        37000
*     O7.5      36500
*     O8        36000
*     O8.5      34750
*     O9        33500
*     O9.5      32750
*     B0        32000
*     -------------------
*Note (3): For stars in clusters, the surface gravities are determined as
*     discussed in Sect. 3.1 and rely on stellar evolution models and
*     cluster distance determinations. Surface gravities for non-cluster
*     stars are not always well-determined, because of a lack of specific
*     spectroscopic indicators. In some cases, the best-fit solutions for
*     these stars indicated physically unlikely results (i.e., log(g)>~4.3
*     or log(g)<~3.0). For these stars, a value of log(g)=3.9 was assumed
*     (which is the mean log(g) of the rest of the sample) and a 1-{sigma}
*     uncertainty of +/-0.2 was incorporated in the error analysis. These
*     cases can be identified by log(g) entries of "3.9+/-0.2".
*Note (4): For the O stars in the sample, our fitting procedure utilized
*     solar abundance TLUSTY models. For these stars the values of [m/H] 
*     are indicated by entries of "0" without uncertainties.
*Note (5): For the O stars, the adopted TLUSTY models incorporate
*     Vturb=10km/s. For these stars the values of Vturb are indicated by
*     entries of "10" without uncertainties.
*
*     For the B stars, which were modeled using ATLAS9 models, the values of
*     Vturb were determined by the fitting procedure, but were constrained
*     to lie between 0 and 10km/s.
*
*     Stars whose best-fit SED models required these limiting values are
*     indicated by Vturb entries of "0" or "10", without error bars. The
*     uncertainties for stars with best-fit Vturb values close to these
*     limits may be underestimated due to this truncation.

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

C  Declarations for 'table4.dat'	! Best-Fit Extinction Curve Parameters for
                              Survey Stars

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

      character*22  Name_2     (nr__2) ! Star name
      real*4        x0         (nr__2) ! The UV x_0_ coefficient (2)
      real*4        e_x0       (nr__2) ! 1-{sigma} uncertainty in x0
      real*4        gamma      (nr__2) ! UV {gamma} coefficient (2)
      real*4        e_gamma    (nr__2) ! 1-{sigma} uncertainty in {gamma}
      real*4        c1         (nr__2) ! UV c_1_ coefficient (2)
      real*4        e_c1       (nr__2) ! ? 1-{sigma} uncertainty in c1
      real*4        c2         (nr__2) ! UV c_2_ coefficient (2)
      real*4        e_c2       (nr__2) ! 1-{sigma} uncertainty in c2
      real*4        c3         (nr__2) ! UV c_3_ coefficient (2)
      real*4        e_c3       (nr__2) ! 1-{sigma} uncertainty in c3
      real*4        c4         (nr__2) ! UV c_4_ coefficient (2)
      real*4        e_c4       (nr__2) ! 1-{sigma} uncertainty in c4
      real*4        c5         (nr__2) ! UV c_5_ coefficient (2)
      real*4        e_c5       (nr__2) ! 1-{sigma} uncertainty in c5
      real*4        O1         (nr__2) ! ? Optical spline O_1_ point (3)
      real*4        e_O1       (nr__2) ! ? 1-{sigma} uncertainty in O1
      real*4        O2         (nr__2) ! Optical spline O_2_ point (3)
      real*4        O3         (nr__2) ! Optical spline O_3_ point (3)
      real*4        R_V        (nr__2) ! IR R(V) coefficient (4)
      real*4        e_R_V      (nr__2) ! ? 1-{sigma} uncertainty in R(V)
      real*4        kIR        (nr__2) ! IR k_IR_ coefficient (4)
      real*4        e_kIR      (nr__2) ! ? 1-{sigma} uncertainty in kIR
*Note (2): Extinction curve is defined by
*       k({lambda}-V) = c1+c2x+c3.D(x,x0,{gamma}) for x<=c5 and
*                     = c1+c2x+c3.D(x,x0,{gamma}) = c4(x-c5)^2^ for x>c5.
*     where x={lambda}^-1^, in units of inverse microns (um-1) and
*     D(x,x0,{gamma})=x^2^/[(x^2^-x0^2^)+x^2^{gamma}^2^]
*
*     For the stars HD237019, HD18352, and HD25443 the long wavelength IUE
*     spectra are incomplete. For these cases we constrained the UV linear
*     extinction component to follow the relation c1=2.18-2.91*c2 from
*     Fitzpatrick (2004, in ASP Conf. Ser. 309, 33). For these stars we 
*     list uncertainties for the c2 values but not for the c1 values.
*Note (3): The uncertainties in the O2 and O3 optical spline points (at
*     wavelengths of 4000 and 5530 Angstroms, respectively) are typically
*     0.01 or less and are not listed. For several stars, those without U
*     band photometry, we did not solve for the O1 point at 3300 Angstroms.
*Note (4): R(V) is the ratio of reddening to extinction at V. For field
*     stars without IR photometry, we assumed R(V)=3.1 and kIR=1.11, with
*     the latter based on the relation kIR=0.63*R(V)-0.84 from Fitzpatrick
*     (2004, in ASP Conf. Ser. 309, 33) clusters, we adopted the mean R(V)
*     of the other cluster members and a value of kIR based on the
*     aforementioned relation. These assumed values are listed in the Table
*     without uncertainties. Several survey stars have apparently noisy JHK
*     data and yielded very uncertain values of kIR. For these, we
*     ultimately derived the extinction curve by solving for the best-fit
*     value of R(V) with kIR constrained to follow the Fitzpatrick (2004, in
*     ASP Conf. Ser. 309, 33) relation. The resultant R(V) values are listed
*     with their uncertainties while the kIR values are listed without
*     uncertainties.

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

C  Declarations for 'refs.dat'	! References

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

      integer*4     Ref_1      (nr__3) ! Reference number
      character*19  BibCode    (nr__3) ! BibCode
      character*22  Aut        (nr__3) ! Author's name
      character*19  Com        (nr__3) ! Comments

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

C  Loading file 'table1.dat'	! Basic Data for Survey Stars

C  Format for file interpretation

    1 format(A22,1X,A15,1X,F5.2,1X,I4,1X,F7.3,1X,F6.2,1X,I2)

C  Effective file loading

      open(unit=1,file='table1.dat', status='old')
      write(6,*) '....Loading file: table1.dat'
      do i__=1,328
        read(1,'(A67)')ar__
        read(ar__,1)
     +  Name(i__),SpType(i__),Vmag(i__),Dist(i__),GLON(i__),GLAT(i__),
     +  Ref(i__)
        if(ar__(46:49) .EQ. '') Dist(i__) = iNULL__
        if(ar__(66:67) .EQ. '') Ref(i__) = iNULL__
c    ..............Just test output...........
        write(6,1)
     +  Name(i__),SpType(i__),Vmag(i__),Dist(i__),GLON(i__),GLAT(i__),
     +  Ref(i__)
c    .......End.of.Just test output...........
      end do
      close(1)

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

C  Loading file 'table3.dat'	! Best-Fit Parameters for Survey Stars

C  Format for file interpretation

    2 format(
     +  A22,1X,I5,1X,I4,1X,F4.2,1X,F4.2,1X,F5.2,1X,F4.2,1X,F4.1,1X,
     +  F3.1,1X,F6.4,1X,F6.4,1X,F4.2,1X,F4.2)

C  Effective file loading

      open(unit=1,file='table3.dat', status='old')
      write(6,*) '....Loading file: table3.dat'
      do i__=1,328
        read(1,'(A87)')ar__1
        read(ar__1,2)
     +  Name_1(i__),Teff(i__),e_Teff(i__),log_g(i__),e_log_g(i__),
     +  v_m_H_(i__),e__m_H_(i__),Vturb(i__),e_Vturb(i__),theta(i__),
     +  e_theta(i__),E_B_V(i__),e_E_B_V(i__)
        if(ar__1(51:54) .EQ. '') e__m_H_(i__) = rNULL__
        if(ar__1(61:63) .EQ. '') e_Vturb(i__) = rNULL__
c    ..............Just test output...........
        write(6,2)
     +  Name_1(i__),Teff(i__),e_Teff(i__),log_g(i__),e_log_g(i__),
     +  v_m_H_(i__),e__m_H_(i__),Vturb(i__),e_Vturb(i__),theta(i__),
     +  e_theta(i__),E_B_V(i__),e_E_B_V(i__)
c    .......End.of.Just test output...........
      end do
      close(1)

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

C  Loading file 'table4.dat'	! Best-Fit Extinction Curve Parameters for
*                              Survey Stars

C  Format for file interpretation

    3 format(
     +  A22,1X,F5.3,1X,F5.3,1X,F4.2,1X,F4.2,1X,F5.2,1X,F4.2,1X,F5.2,
     +  1X,F4.2,1X,F5.2,1X,F4.2,1X,F4.2,1X,F4.2,1X,F4.2,1X,F4.2,1X,
     +  F4.2,1X,F4.2,1X,F4.2,1X,F5.2,1X,F4.2,1X,F4.2,1X,F4.2,1X,F4.2)

C  Effective file loading

      open(unit=1,file='table4.dat', status='old')
      write(6,*) '....Loading file: table4.dat'
      do i__=1,328
        read(1,'(A138)')ar__2
        read(ar__2,3)
     +  Name_2(i__),x0(i__),e_x0(i__),gamma(i__),e_gamma(i__),c1(i__),
     +  e_c1(i__),c2(i__),e_c2(i__),c3(i__),e_c3(i__),c4(i__),
     +  e_c4(i__),c5(i__),e_c5(i__),O1(i__),e_O1(i__),O2(i__),O3(i__),
     +  R_V(i__),e_R_V(i__),kIR(i__),e_kIR(i__)
        if(ar__2(52:55) .EQ. '') e_c1(i__) = rNULL__
        if(ar__2(99:102) .EQ. '') O1(i__) = rNULL__
        if(ar__2(104:107) .EQ. '') e_O1(i__) = rNULL__
        if(ar__2(125:128) .EQ. '') e_R_V(i__) = rNULL__
        if(ar__2(135:138) .EQ. '') e_kIR(i__) = rNULL__
c    ..............Just test output...........
        write(6,3)
     +  Name_2(i__),x0(i__),e_x0(i__),gamma(i__),e_gamma(i__),c1(i__),
     +  e_c1(i__),c2(i__),e_c2(i__),c3(i__),e_c3(i__),c4(i__),
     +  e_c4(i__),c5(i__),e_c5(i__),O1(i__),e_O1(i__),O2(i__),O3(i__),
     +  R_V(i__),e_R_V(i__),kIR(i__),e_kIR(i__)
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,A22,A19)

C  Effective file loading

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

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