FORTRAN Generation
(/./ftp/cats/I/311)

Conversion of standardized ReadMe file for file /./ftp/cats/I/311 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 2018-Sep-22
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. I/311               Hipparcos, the New Reduction       (van Leeuwen, 2007)
*================================================================================
*Hipparcos, the new Reduction of the Raw data
*     van Leeuwen F.
*    <Astron. Astrophys. 474, 653 (2007)>
*    =2007A&A...474..653V
C=============================================================================

C  Internal variables

      integer*4 i__

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

C  Declarations for 'hip2.dat'	! The Astrometric Catalogue

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

C  Position composed of: RArad DErad (Epoch=1991.25)
      integer*4     HIP         ! Hipparcos identifier
      integer*4     Sn          ! [0,159] Solution type new reduction (1)
      integer*4     So          ! [0,5] Solution type old reduction (2)
      integer*4     Nc          ! Number of components
      real*8        RArad       ! (rad) Right Ascension in ICRS, Ep=1991.25
      real*8        DErad       ! (rad) Declination in ICRS, Ep=1991.25
      real*8        Plx         ! (mas) Parallax
      real*8        pmRA        ! (mas/yr) Proper motion in Right Ascension
      real*8        pmDE        ! (mas/yr) Proper motion in Declination
      real*4        e_RArad     ! (mas) Formal error on RArad
      real*4        e_DErad     ! (mas) Formal error on DErad
      real*4        e_Plx       ! (mas) Formal error on Plx
      real*4        e_pmRA      ! (mas/yr) Formal error on pmRA
      real*4        e_pmDE      ! (mas/yr) Formal error on pmDE
      integer*4     Ntr         ! Number of field transits used
      real*4        F2          ! Goodness of fit
      integer*4     F1          ! (%) Percentage rejected data
      real*4        var         ! Cosmic dispersion added (stochastic solution)
      integer*4     ic          ! Entry in one of the suppl.catalogues
      real*8        Hpmag       ! (mag) Hipparcos magnitude
      real*4        e_Hpmag     ! (mag) Error on mean Hpmag
      real*4        sHp         ! (mag) Scatter of Hpmag
      integer*4     VA          ! [0,2] Reference to variability annex
      real*4        B_V         ! (mag) Colour index
      real*4        e_B_V       ! (mag) Formal error on colour index
      real*4        V_I         ! (mag) V-I colour index
      real*8        UW         (15) ! Upper-triangular weight matrix (G1)
*Note (1): Solution type.
*    The solution type is a number 10xd+s consisting of two parts d and s:
*    - s describes the type of solution adopted:
*      1 = stochastic solution (dispersion is given in the 'var' column)
*      3 = VIM solution (additional parameters in file hipvim.dat)
*      5 = 5-parameter solution (this file)
*      7 = 7-parameter solution (additional parameters in hip7p.dat)
*      9 = 9-parameter solution (additional parameters in hip9p.dat)
*    - d describes peculiarities, as a combination of values:
*      0 = single star
*      1 = double star
*      2 = variable in the system with amplitude > 0.2mag
*      4 = astrometry refers to the photocenter
*      8 = measurements concern the secondary (fainter) in the double system
*Note (2): as follows:
*      0 = standard 5-parameter solution
*      1 = 7- or 9-parameter solution
*      2 = stochastic solution
*      3 = double and multiple stars
*      4 = orbital binary as resolved in the published catalog
*      5 = VIM (variability-induced mover) solution

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

C  Declarations for 'hip7p.dat'	! Seven-parameter solutions

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

      integer*4     HIP_1       ! Hipparcos identifier
      real*4        Fg          ! Detection statistic
      real*4        dpmRA       ! (mas/yr2) Acceleration in Right Ascension
      real*4        dpmDE       ! (mas/yr2) Acceleration in Declination
      real*4        e_dpmRA     ! (mas/yr2) Formal error on dpmRA
      real*4        e_dpmDE     ! (mas/yr2) Formal error on dpmDE
      real*8        UW_1       (13) ! Upper-triangular weight matrix U16..U28 (G1)

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

C  Declarations for 'hip9p.dat'	! Nine-parameter solutions

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

      integer*4     HIP_2       ! Hipparcos identifier
      real*4        Fg_1        ! Detection statistic
      real*4        dpmRA_1     ! (mas/yr2) Acceleration in Right Ascension
      real*4        dpmDE_1     ! (mas/yr2) Acceleration in Declination
      real*4        ddpmRA      ! (mas/yr3) Acceleration change in Right Ascension
      real*4        ddpmDE      ! (mas/yr3) Acceleration change in Declination
      real*4        e_dpmRA_1   ! (mas/yr2) Formal error on dpmRA
      real*4        e_dpmDE_1   ! (mas/yr2) Formal error on dpmDE
      real*4        e_ddpmRA    ! (mas/yr3) Formal error on ddpmRA
      real*4        e_ddpmDE    ! (mas/yr3) Formal error on ddpmDE
      real*8        UW_2       (30) ! Upper-triangular weight matrix U16..U45 (G1)

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

C  Declarations for 'hipvim.dat'	! *Variability-induced (VIM) solutions

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

      integer*4     HIP_3       ! Hipparcos identifier
      real*4        Fg_2        ! Detection statistic
      real*4        upsRA       ! (mas) VIM in Right Ascension (1)
      real*4        upsDE       ! (mas) VIM in Declination (1)
      real*4        e_upsRA     ! (mas) Formal error on upsRA
      real*4        e_upsDE     ! (mas) Formal error on upsDE
      real*8        UW_3       (13) ! Upper-triangular weight matrix U16..U28 (G1)
*Note (1): the variability-induced movement is due to the variability
*     of one component of the binary which changes the position of the
*     photocenter along the RA (or Dec) axis with the quantity
*         ups*(1 - dexp(-0.4(m_r_-m)))
*     where m_r_ is the reference magnitude of the binary and m
*     the observed magnitude of the binary, and dexp the decimal
*     exponentiation (dexp(x) = 10^x^)

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

C  Loading file 'hip2.dat'	! The Astrometric Catalogue

C  Format for file interpretation

    1 format(
     +  I6,1X,I3,1X,I1,1X,I1,1X,F13.10,1X,F13.10,1X,F7.2,1X,F8.2,1X,
     +  F8.2,1X,F6.2,1X,F6.2,1X,F6.2,1X,F6.2,1X,F6.2,1X,I3,1X,F5.2,1X,
     +  I2,1X,F6.1,1X,I4,1X,F7.4,1X,F6.4,1X,F5.3,1X,I1,1X,F6.3,1X,
     +  F5.3,1X,F6.3,15F7.2)

C  Effective file loading

      open(unit=1,status='old',file=
     +'hip2.dat')
      write(6,*) '....Loading file: hip2.dat'
      do i__=1,117955
        read(1,'(A276)')ar__
        read(ar__,1)
     +  HIP,Sn,So,Nc,RArad,DErad,Plx,pmRA,pmDE,e_RArad,e_DErad,e_Plx,
     +  e_pmRA,e_pmDE,Ntr,F2,F1,var,ic,Hpmag,e_Hpmag,sHp,VA,B_V,e_B_V,
     +  V_I,(UW(j__,),j__=1,15)
c    ..............Just test output...........
        write(6,1)
     +  HIP,Sn,So,Nc,RArad,DErad,Plx,pmRA,pmDE,e_RArad,e_DErad,e_Plx,
     +  e_pmRA,e_pmDE,Ntr,F2,F1,var,ic,Hpmag,e_Hpmag,sHp,VA,B_V,e_B_V,
     +  V_I,(UW(j__,),j__=1,15)
c    .......End.of.Just test output...........
      end do
      close(1)

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

C  Loading file 'hip7p.dat'	! Seven-parameter solutions

C  Format for file interpretation

    2 format(I6,1X,F5.2,1X,F6.2,1X,F6.2,1X,F5.2,1X,F5.2,13F7.2)

C  Effective file loading

      open(unit=1,status='old',file=
     +'hip7p.dat')
      write(6,*) '....Loading file: hip7p.dat'
      do i__=1,1338
        read(1,'(A129)')ar__1
        read(ar__1,2)
     +  HIP_1,Fg,dpmRA,dpmDE,e_dpmRA,e_dpmDE,(UW_1(j__,),j__=1,13)
c    ..............Just test output...........
        write(6,2)
     +  HIP_1,Fg,dpmRA,dpmDE,e_dpmRA,e_dpmDE,(UW_1(j__,),j__=1,13)
c    .......End.of.Just test output...........
      end do
      close(1)

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

C  Loading file 'hip9p.dat'	! Nine-parameter solutions

C  Format for file interpretation

    3 format(
     +  I6,1X,F5.2,1X,F6.2,1X,F6.2,1X,F6.2,1X,F6.2,1X,F5.2,1X,F5.2,1X,
     +  F5.2,1X,F5.2,30F7.2)

C  Effective file loading

      open(unit=1,status='old',file=
     +'hip9p.dat')
      write(6,*) '....Loading file: hip9p.dat'
      do i__=1,104
        read(1,'(A274)')ar__2
        read(ar__2,3)
     +  HIP_2,Fg_1,dpmRA_1,dpmDE_1,ddpmRA,ddpmDE,e_dpmRA_1,e_dpmDE_1,
     +  e_ddpmRA,e_ddpmDE,(UW_2(j__,),j__=1,30)
c    ..............Just test output...........
        write(6,3)
     +  HIP_2,Fg_1,dpmRA_1,dpmDE_1,ddpmRA,ddpmDE,e_dpmRA_1,e_dpmDE_1,
     +  e_ddpmRA,e_ddpmDE,(UW_2(j__,),j__=1,30)
c    .......End.of.Just test output...........
      end do
      close(1)

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

C  Loading file 'hipvim.dat'	! *Variability-induced (VIM) solutions

C  Format for file interpretation

    4 format(I6,1X,F5.2,1X,F6.2,1X,F6.2,1X,F5.2,1X,F5.2,13F7.2)

C  Effective file loading

      open(unit=1,status='old',file=
     +'hipvim.dat')
      write(6,*) '....Loading file: hipvim.dat'
      do i__=1,25
        read(1,'(A129)')ar__3
        read(ar__3,4)
     +  HIP_3,Fg_2,upsRA,upsDE,e_upsRA,e_upsDE,(UW_3(j__,),j__=1,13)
c    ..............Just test output...........
        write(6,4)
     +  HIP_3,Fg_2,upsRA,upsDE,e_upsRA,e_upsDE,(UW_3(j__,),j__=1,13)
c    .......End.of.Just test output...........
      end do
      close(1)

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