FORTRAN Generation
(/./ftp/cats/IV/25)

Conversion of standardized ReadMe file for file /./ftp/cats/IV/25 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-28
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. IV/25               HD identifications for Tycho-2 stars      (Fabricius+, 2002)
*================================================================================
*Henry Draper Catalogue identifications for Tycho-2 stars.
*      Fabricius C, Makarov V V, Knude J., Wycoff G.L.
*     <Astron. Astrophys. 386, 709 (2002)>
*     =2002A&A...386..709F
C=============================================================================

C  Internal variables

      integer*4 i__

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

C  Declarations for 'tyc2_hd.dat'	! Catalog

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

      integer*4     TYC1       (nr__) ! [1,9537]+= TYC1 from Tycho-2
      integer*4     TYC2       (nr__) ! [1,12121]  TYC2 from Tycho-2
      integer*4     TYC3       (nr__) ! [1,4]      TYC3 from Tycho-2
      character*1   f_TYC      (nr__) ! [S] Set for stars in Tycho-2 Supplement#1
      integer*4     HD         (nr__) ! HD (Cat. <III/135>) identifier
      character*3   SpType     (nr__) ! Spectral type from HD catalogue
      integer*4     n_HD       (nr__) ! [1,2] number of HD stars for this Tyc2 star
      integer*4     n_TYC      (nr__) ! [1,2] number of Tyc2 stars for this HD star
      character*1   TDSC       (nr__) ! [D] star in Tycho Double Star Catalogue
      character*1   Rem        (nr__) ! *[DEGMR*] Remarks flag from HD file
      character*1   Note       (nr__) ! [N] note exists in the notes.dat file
*Note on Rem: the flag has the following meaning:
*     D = Entry deleted (compared to the printed catalog)
*     E = Image at edge of plate
*     G = Position and BD number taken directly from AGK1 and precessed to 1900
*     M = Multiple images used
*     R = Remark in the published catalog
*     * = Spectral type refers a cluster, nebula or nebulous star

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

C  Declarations for 'notes.dat'	! Individual notes

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

      integer*4     HD_1       (nr__1) ! HD number
      character*116 Text       (nr__1) ! Text of the note

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

C  Loading file 'tyc2_hd.dat'	! Catalog

C  Format for file interpretation

    1 format(
     +  I4,1X,I5,1X,I1,A1,1X,I6,1X,A3,1X,I1,1X,I1,1X,A1,1X,A1,1X,A1)

C  Effective file loading

      open(unit=1,status='old',file=
     +'tyc2_hd.dat')
      write(6,*) '....Loading file: tyc2_hd.dat'
      do i__=1,353527
        read(1,'(A34)')ar__
        read(ar__,1)
     +  TYC1(i__),TYC2(i__),TYC3(i__),f_TYC(i__),HD(i__),SpType(i__),
     +  n_HD(i__),n_TYC(i__),TDSC(i__),Rem(i__),Note(i__)
c    ..............Just test output...........
        write(6,1)
     +  TYC1(i__),TYC2(i__),TYC3(i__),f_TYC(i__),HD(i__),SpType(i__),
     +  n_HD(i__),n_TYC(i__),TDSC(i__),Rem(i__),Note(i__)
c    .......End.of.Just test output...........
      end do
      close(1)

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

C  Loading file 'notes.dat'	! Individual notes

C  Format for file interpretation

    2 format(I6,1X,A116)

C  Effective file loading

      open(unit=1,status='old',file=
     +'notes.dat')
      write(6,*) '....Loading file: notes.dat'
      do i__=1,123
        read(1,'(A123)')ar__1
        read(ar__1,2)HD_1(i__),Text(i__)
c    ..............Just test output...........
        write(6,2)HD_1(i__),Text(i__)
c    .......End.of.Just test output...........
      end do
      close(1)

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