FORTRAN Generation
(/./ftp/cats/II/164)

Conversion of standardized ReadMe file for file /./ftp/cats/II/164 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. II/164              DDO Photoelectric Photometric Catalog   (Mermilliod+ 1989)
*================================================================================
*Catalogue of DDO Photometry 88
*     Mermilliod J.C., Nitschelm C.
*    <Astron. Astrophys. Suppl. Ser. 81, 401 (1989)>
*    =1989A&AS...81..401M
C=============================================================================

C  Internal variables

      integer*4 i__

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

C  Declarations for 'mean.dat'	! Catalog of homogeneous data

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

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

      character*10  LID        (nr__) ! Lausanne identification code (G1)
      character*1   m_LID      (nr__) ! [D1239] Remarks on duplicity and variability
      character*1   f_LID      (nr__) ! [V] Variability flag
      integer*4     HR         (nr__) ! ? Number in the Bright Star Catalog <V/50>
      integer*4     HD         (nr__) ! ? Number in Henry Draper Catalog <III/115>
      character*9   DM         (nr__) ! Durchmusterung designation (BD, CD, CPD)
      character*12  Oname      (nr__) ! Other designation
      integer*4     RAh        (nr__) ! (h) ? Right Ascension B1950 (hours)
      integer*4     RAm        (nr__) ! (min) ? Right Ascension B1950 (minutes)
      integer*4     RAs        (nr__) ! (s) ? Right Ascension B1950 (seconds)
      character*1   DE_        (nr__) ! Declination B1950 (sign)
      integer*4     DEd        (nr__) ! (deg) ? Declination B1950 (degrees)
      real*4        DEm        (nr__) ! (arcmin) ? Declination B1950 (minutes)
      real*4        m48        (nr__) ! (mag) ? Magnitude in the filter 48 of DDO system
      real*4        C_48_51    (nr__) ! (mag) ? Colour index in DDO system
      real*4        C_45_48    (nr__) ! (mag) ? Colour index in DDO system
      real*4        C_42_45    (nr__) ! (mag) ? Colour index in DDO system
      real*4        C_41_42    (nr__) ! (mag) ? Colour index in DDO system
      real*4        C_38_41    (nr__) ! (mag) ? Colour index in DDO system
      real*4        C_35_38    (nr__) ! (mag) ? Colour index in DDO system
      character*1   l_Nobs     (nr__) ! [>S] Limit flag on Nobs, or 'S' for standard
      integer*4     Nobs       (nr__) ! ? Number of measurements (blank for standard)

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

C  Declarations for 'obs.dat'	! Catalog of individual observations

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

      character*10  LID_1      (nr__1) ! Lausanne identification code (G1)
      character*1   m_LID_1    (nr__1) ! [D1239] Remarks on duplicity
      character*1   f_LID_1    (nr__1) ! [V] Variability flag
      real*4        m48_1      (nr__1) ! (mag) ? Magnitude in the filter 48 of DDO system
      real*4        C_48_51_1  (nr__1) ! (mag) ? Colour index in DDO system
      real*4        C_45_48_1  (nr__1) ! (mag) ? Colour index in DDO system
      real*4        C_42_45_1  (nr__1) ! (mag) ? Colour index in DDO system
      real*4        C_41_42_1  (nr__1) ! (mag) ? Colour index in DDO system
      real*4        C_38_41_1  (nr__1) ! (mag) ? Colour index in DDO system
      real*4        C_35_38_1  (nr__1) ! (mag) ? Colour index in DDO system
      character*1   l_Nobs_1   (nr__1) ! [>S*] Limit flag on Nobs, 'S' for standard
*                                        '*' for an estimated number
      integer*4     Nobs_1     (nr__1) ! ? Number of measurements (blank for standard)
      integer*4     r_m48      (nr__1) ! Reference of the observation in "refs.dat"

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

C  Declarations for 'refs.dat'	! References (contains 76 empty lines)

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

      integer*4     Ref        (nr__2) ! [12001/12081] Reference number
      character*72  Text       (nr__2) ! Text of reference (includes the bibcode)

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

C  Loading file 'mean.dat'	! Catalog of homogeneous data

C  Format for file interpretation

    1 format(
     +  1X,A10,A1,A1,1X,I4,1X,I6,1X,A9,1X,A12,I2,1X,I2,1X,I2,1X,A1,I2,
     +  1X,F4.1,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,
     +  F6.3,4X,A1,1X,I2)

C  Effective file loading

      open(unit=1,status='old',file=
     +'mean.dat')
      write(6,*) '....Loading file: mean.dat'
      do i__=1,6139
        read(1,'(A122)')ar__
        read(ar__,1)
     +  LID(i__),m_LID(i__),f_LID(i__),HR(i__),HD(i__),DM(i__),
     +  Oname(i__),RAh(i__),RAm(i__),RAs(i__),DE_(i__),DEd(i__),
     +  DEm(i__),m48(i__),C_48_51(i__),C_45_48(i__),C_42_45(i__),
     +  C_41_42(i__),C_38_41(i__),C_35_38(i__),l_Nobs(i__),Nobs(i__)
        if(ar__(15:18) .EQ. '') HR(i__) = iNULL__
        if(ar__(20:25) .EQ. '') HD(i__) = iNULL__
        if(ar__(49:50) .EQ. '') RAh(i__) = iNULL__
        if(ar__(52:53) .EQ. '') RAm(i__) = iNULL__
        if(ar__(55:56) .EQ. '') RAs(i__) = iNULL__
        if(ar__(59:60) .EQ. '') DEd(i__) = iNULL__
        if(ar__(62:65) .EQ. '') DEm(i__) = rNULL__
        if(ar__(67:72) .EQ. '') m48(i__) = rNULL__
        if(ar__(74:79) .EQ. '') C_48_51(i__) = rNULL__
        if(ar__(81:86) .EQ. '') C_45_48(i__) = rNULL__
        if(ar__(88:93) .EQ. '') C_42_45(i__) = rNULL__
        if(ar__(95:100) .EQ. '') C_41_42(i__) = rNULL__
        if(ar__(102:107) .EQ. '') C_38_41(i__) = rNULL__
        if(ar__(109:114) .EQ. '') C_35_38(i__) = rNULL__
        if(ar__(121:122) .EQ. '') Nobs(i__) = iNULL__
        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(DE_(i__).EQ.'-'.AND.DEdeg(i__).GE.0) DEdeg(i__)=-DEdeg(i__)
c    ..............Just test output...........
        write(6,1)
     +  LID(i__),m_LID(i__),f_LID(i__),HR(i__),HD(i__),DM(i__),
     +  Oname(i__),RAh(i__),RAm(i__),RAs(i__),DE_(i__),DEd(i__),
     +  DEm(i__),m48(i__),C_48_51(i__),C_45_48(i__),C_42_45(i__),
     +  C_41_42(i__),C_38_41(i__),C_35_38(i__),l_Nobs(i__),Nobs(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 'obs.dat'	! Catalog of individual observations

C  Format for file interpretation

    2 format(
     +  1X,A10,A1,A1,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,
     +  1X,F6.3,4X,A1,1X,I2,5X,I5)

C  Effective file loading

      open(unit=1,status='old',file=
     +'obs.dat')
      write(6,*) '....Loading file: obs.dat'
      do i__=1,8034
        read(1,'(A80)')ar__1
        read(ar__1,2)
     +  LID_1(i__),m_LID_1(i__),f_LID_1(i__),m48_1(i__),
     +  C_48_51_1(i__),C_45_48_1(i__),C_42_45_1(i__),C_41_42_1(i__),
     +  C_38_41_1(i__),C_35_38_1(i__),l_Nobs_1(i__),Nobs_1(i__),
     +  r_m48(i__)
        if(ar__1(15:20) .EQ. '') m48_1(i__) = rNULL__
        if(ar__1(22:27) .EQ. '') C_48_51_1(i__) = rNULL__
        if(ar__1(29:34) .EQ. '') C_45_48_1(i__) = rNULL__
        if(ar__1(36:41) .EQ. '') C_42_45_1(i__) = rNULL__
        if(ar__1(43:48) .EQ. '') C_41_42_1(i__) = rNULL__
        if(ar__1(50:55) .EQ. '') C_38_41_1(i__) = rNULL__
        if(ar__1(57:62) .EQ. '') C_35_38_1(i__) = rNULL__
        if(ar__1(69:70) .EQ. '') Nobs_1(i__) = iNULL__
c    ..............Just test output...........
        write(6,2)
     +  LID_1(i__),m_LID_1(i__),f_LID_1(i__),m48_1(i__),
     +  C_48_51_1(i__),C_45_48_1(i__),C_42_45_1(i__),C_41_42_1(i__),
     +  C_38_41_1(i__),C_35_38_1(i__),l_Nobs_1(i__),Nobs_1(i__),
     +  r_m48(i__)
c    .......End.of.Just test output...........
      end do
      close(1)

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

C  Loading file 'refs.dat'	! References (contains 76 empty lines)

C  Format for file interpretation

    3 format(I5,3X,A72)

C  Effective file loading

      open(unit=1,status='old',file=
     +'refs.dat')
      write(6,*) '....Loading file: refs.dat'
      do i__=1,396
        read(1,'(A80)')ar__2
        read(ar__2,3)Ref(i__),Text(i__)
c    ..............Just test output...........
        write(6,3)Ref(i__),Text(i__)
c    .......End.of.Just test output...........
      end do
      close(1)

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