FORTRAN Generation
(/./ftp/cats/J/A_A/475/677)

Conversion of standardized ReadMe file for file /./ftp/cats/J/A_A/475/677 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-20
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/475/677       X-ray emission from A-type stars         (Schroeder+, 2007)
*================================================================================
*X-ray emission from A-type stars.
*    Schroeder C., Schmitt J.H.M.M.
*   <Astron. Astrophys., 475, 677-684 (2007)>
*   =2007A&A...475..677S
C=============================================================================

C  Internal variables

      integer*4 i__

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

C  Declarations for 'table2.dat'	! List of X-ray associated "bona fide" single or
                              resolved multiple A-type stars

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

      integer*4     HR         (nr__) ! HR number, from the Bright Star Catalog <V/50>
      character*2   Bin        (nr__) ! Binarity flag (1)
      integer*4     vsini      (nr__) ! (km/s) ? Rotational velocity or lower value of
*                                  rotational velocity when interval
      integer*4     vsiniu     (nr__) ! (km/s) ? Upper value of rotational velocity
*                                  when interval
      character*1   l_Sep      (nr__) ! Limit flag on Sep
      real*8        Sep        (nr__) ! (arcsec) ? Separation for visual binary systems
      real*4        Sep2       (nr__) ! (arcsec) ? Second value of separation for visual binary
*                                  systems
      character*2   n_Sep2     (nr__) ! Note on Separation values
      real*4        Dmag       (nr__) ! (mag) ? Difference in the magnitude between the
*                                   star and its closest companion
      real*4        Dmag2      (nr__) ! (mag) ? Second value of difference in the magnitude
*                                   between the A star and its closest companion
      character*6   n_Dmag     (nr__) ! Additional informations on Dmag
      character*16  SpType     (nr__) ! MK spectral types of the components
      integer*4     Dist       (nr__) ! (pc) ?=- Distance of the star as given by Hipparcos
*                                    (Cat. I/239) parallaxes
      character*3   Obs        (nr__) ! Catalog flag indicating in which observation
*                                 mode the star has been observed (2)
      real*8        CR         (nr__) ! (ct/s) Count rate of the associated X-ray source (3)
      real*8        e_CR       (nr__) ! (ct/s) ?=0.0 Error of the count rate (4)
      real*8        LX         (nr__) ! (10+20W) ?=- X-ray luminosity (5)
      integer*4     Notes      (nr__) ! [1/3]? Notes (6)
*Note (1): Binary flag as follows:
*      S = single star
*      B = visual or eclipsing binary
*     SB = spectroscopic binary
*     PB = potential binary
*Note (2): Flags as follows:
*      R = ROSAT all-sky survey
*      P = PSPC pointing
*      H = HRI pointing
*Note (3): First choice were PSPC pointing source data, second HRI and third
*     survey observation data.
*Note (4): Errors with a value of 0.0 mark sources with flags in the ROSAT
*     catalogs that indicate a suspect source or false detection in the
*     field.
*Note (5): X-ray luminosity derived from the distance as given in Col. 7
*     and the count rates as given in Col. 9. The values are given in units
*     of 10^27^erg/s (10^20^W).
*Note (6): Individual notes as follows:
*      1 = Simon et al. (1995PASP..107.1034S) calculate an L_x_ of
*          33x10^27^erg/s from PSPC pointing observations. The Second
*          ROSAT Source Catalog of Pointed Observation (2001) lists false
*          detections in the field and therefor no count rate for the source.
*      2 = In The Second ROSAT Source Catalog of Pointed Observation (2001)
*          this source is flagged as suspect in lightcurve, variability
*          and spectrum. No count rate for the source is listed.
*      3 = See Zinnecker & Preibisch (1994A&A...292..152Z) and
*          Hamaguchi et al. (2005ApJ...618..360H).

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

C  Declarations for 'table3.dat'	! List of X-ray associated A-type stars in binary
                              or multiple systems or with hints of hidden
                              companions

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

      integer*4     HR_1       (nr__1) ! HR number, from the Bright Star Catalog <V/50>
      character*2   Bin_1      (nr__1) ! Binarity flag (1)
      integer*4     vsini_1    (nr__1) ! (km/s) ? Rotational velocity or lower value of
*                                  rotational velocity when interval
      integer*4     vsiniu_1   (nr__1) ! (km/s) ? Upper value of rotational velocity
*                                  when interval
      character*1   l_Sep_1    (nr__1) ! Limit flag on Sep
      real*8        Sep_1      (nr__1) ! (arcsec) ? Separation for visual binary systems
      real*4        Sep2_1     (nr__1) ! (arcsec) ? Second value of separation for visual binary
*                                  systems
      character*2   n_Sep2_1   (nr__1) ! Note on Separation values
      real*4        Dmag_1     (nr__1) ! (mag) ? Difference in the magnitude between the
*                                   star and its closest companion
      real*4        Dmag2_1    (nr__1) ! (mag) ? Second value of difference in the magnitude
*                                   between the A star and its closest companion
      character*6   n_Dmag_1   (nr__1) ! Additional informations on Dmag
      character*16  SpType_1   (nr__1) ! MK spectral types of the components
      integer*4     Dist_1     (nr__1) ! (pc) ?=- Distance of the star as given by Hipparcos
*                                    (Cat. I/239) parallaxes
      character*3   Obs_1      (nr__1) ! Catalog flag indicating in which observation
*                                 mode the star has been observed (2)
      real*8        CR_1       (nr__1) ! (ct/s) Count rate of the associated X-ray source (3)
      real*8        e_CR_1     (nr__1) ! (ct/s) ?=0.0 Error of the count rate (4)
      real*8        LX_1       (nr__1) ! (10+20W) ?=- X-ray luminosity (5)
      integer*4     Notes_1    (nr__1) ! [1/3]? Notes (6)
*Note (1): Binary flag as follows:
*      S = single star
*      B = visual or eclipsing binary
*     SB = spectroscopic binary
*     PB = potential binary
*Note (2): Flags as follows:
*      R = ROSAT all-sky survey
*      P = PSPC pointing
*      H = HRI pointing
*Note (3): First choice were PSPC pointing source data, second HRI and third
*     survey observation data.
*Note (4): Errors with a value of 0.0 mark sources with flags in the ROSAT
*     catalogs that indicate a suspect source or false detection in the
*     field.
*Note (5): X-ray luminosity derived from the distance as given in Col. 7
*     and the count rates as given in Col. 9. The values are given in units
*     of 10^27^erg/s (10^20^W).
*Note (6): Individual notes as follows:
*      1 = Simon et al. (1995PASP..107.1034S) calculate an L_x_ of
*          33x10^27^erg/s from PSPC pointing observations. The Second
*          ROSAT Source Catalog of Pointed Observation (2001) lists false
*          detections in the field and therefor no count rate for the source.
*      2 = In The Second ROSAT Source Catalog of Pointed Observation (2001)
*          this source is flagged as suspect in lightcurve, variability
*          and spectrum. No count rate for the source is listed.
*      3 = See Zinnecker & Preibisch (1994A&A...292..152Z) and
*          Hamaguchi et al. (2005ApJ...618..360H).

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

C  Loading file 'table2.dat'	! List of X-ray associated "bona fide" single or
*                              resolved multiple A-type stars

C  Format for file interpretation

    1 format(
     +  I4,1X,A2,1X,I3,1X,I3,1X,A1,F8.4,2X,F5.1,A2,1X,F5.1,1X,F4.1,A6,
     +  A16,1X,I4,1X,A3,1X,F7.5,1X,F7.5,1X,F7.1,1X,I1)

C  Effective file loading

      open(unit=1,status='old',file=
     +'table2.dat')
      write(6,*) '....Loading file: table2.dat'
      do i__=1,84
        read(1,'(A102)')ar__
        read(ar__,1)
     +  HR(i__),Bin(i__),vsini(i__),vsiniu(i__),l_Sep(i__),Sep(i__),
     +  Sep2(i__),n_Sep2(i__),Dmag(i__),Dmag2(i__),n_Dmag(i__),
     +  SpType(i__),Dist(i__),Obs(i__),CR(i__),e_CR(i__),LX(i__),
     +  Notes(i__)
        if(ar__(9:11) .EQ. '') vsini(i__) = iNULL__
        if(ar__(13:15) .EQ. '') vsiniu(i__) = iNULL__
        if(ar__(18:25) .EQ. '') Sep(i__) = rNULL__
        if(ar__(28:32) .EQ. '') Sep2(i__) = rNULL__
        if(ar__(36:40) .EQ. '') Dmag(i__) = rNULL__
        if(ar__(42:45) .EQ. '') Dmag2(i__) = rNULL__
        if (Dist(i__) .EQ. 45) Dist(i__) =  iNULL__
        if (idig(ar__(94:100)).EQ.0) LX(i__) =  rNULL__
        if(ar__(102:102) .EQ. '') Notes(i__) = iNULL__
c    ..............Just test output...........
        write(6,1)
     +  HR(i__),Bin(i__),vsini(i__),vsiniu(i__),l_Sep(i__),Sep(i__),
     +  Sep2(i__),n_Sep2(i__),Dmag(i__),Dmag2(i__),n_Dmag(i__),
     +  SpType(i__),Dist(i__),Obs(i__),CR(i__),e_CR(i__),LX(i__),
     +  Notes(i__)
c    .......End.of.Just test output...........
      end do
      close(1)

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

C  Loading file 'table3.dat'	! List of X-ray associated A-type stars in binary
*                              or multiple systems or with hints of hidden
*                              companions

C  Format for file interpretation

    2 format(
     +  I4,1X,A2,1X,I3,1X,I3,1X,A1,F8.4,2X,F5.1,A2,1X,F5.1,1X,F4.1,A6,
     +  A16,1X,I4,1X,A3,1X,F7.5,1X,F7.5,1X,F7.1,1X,I1)

C  Effective file loading

      open(unit=1,status='old',file=
     +'table3.dat')
      write(6,*) '....Loading file: table3.dat'
      do i__=1,226
        read(1,'(A102)')ar__1
        read(ar__1,2)
     +  HR_1(i__),Bin_1(i__),vsini_1(i__),vsiniu_1(i__),l_Sep_1(i__),
     +  Sep_1(i__),Sep2_1(i__),n_Sep2_1(i__),Dmag_1(i__),Dmag2_1(i__),
     +  n_Dmag_1(i__),SpType_1(i__),Dist_1(i__),Obs_1(i__),CR_1(i__),
     +  e_CR_1(i__),LX_1(i__),Notes_1(i__)
        if(ar__1(9:11) .EQ. '') vsini_1(i__) = iNULL__
        if(ar__1(13:15) .EQ. '') vsiniu_1(i__) = iNULL__
        if(ar__1(18:25) .EQ. '') Sep_1(i__) = rNULL__
        if(ar__1(28:32) .EQ. '') Sep2_1(i__) = rNULL__
        if(ar__1(36:40) .EQ. '') Dmag_1(i__) = rNULL__
        if(ar__1(42:45) .EQ. '') Dmag2_1(i__) = rNULL__
        if (Dist_1(i__) .EQ. 45) Dist_1(i__) =  iNULL__
        if (idig(ar__1(94:100)).EQ.0) LX_1(i__) =  rNULL__
        if(ar__1(102:102) .EQ. '') Notes_1(i__) = iNULL__
c    ..............Just test output...........
        write(6,2)
     +  HR_1(i__),Bin_1(i__),vsini_1(i__),vsiniu_1(i__),l_Sep_1(i__),
     +  Sep_1(i__),Sep2_1(i__),n_Sep2_1(i__),Dmag_1(i__),Dmag2_1(i__),
     +  n_Dmag_1(i__),SpType_1(i__),Dist_1(i__),Obs_1(i__),CR_1(i__),
     +  e_CR_1(i__),LX_1(i__),Notes_1(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