FORTRAN Generation
(/./ftp/cats/J/AJ/122/1844)

Conversion of standardized ReadMe file for file /./ftp/cats/J/AJ/122/1844 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 2026-Jun-08
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/AJ/122/1844       MSX and 2MASS cross-correlation in LMC      (Egan+, 2001)
*================================================================================
*MSX, 2MASS, and the Large Magellanic Cloud:
*a combined near- and mid-infrared view.
*    Egan M.P., van Dyk S.D., Price S.D.
*   <Astron. J. 122, 1844 (2001)>
*   =2001AJ....122.1844E
C=============================================================================

C  Internal variables

      integer*4 i__

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

C  Declarations for 'table2.dat'	! MSX sources in common with the 2MASS 2IDR

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

C  J2000 position composed of: RAdeg DEdeg
      integer*4     MSX        (nr__) ! The MSX number (G1)
      real*8        RAdeg      (nr__) ! (deg) Right Ascension in decimal degrees (J2000)
      real*8        DEdeg      (nr__) ! (deg) Declination in decimal degrees (J2000)
      real*4        Jmag       (nr__) ! (mag) ? The J band magnitude
      real*4        Hmag       (nr__) ! (mag) ? The H band magnitude
      real*4        Kmag       (nr__) ! (mag) ? The K_s_ band magnitude
      real*4        Amag       (nr__) ! (mag) The MSX A-band (8.3{mu}m) magnitude
      character*7   IRType     (nr__) ! The IR type
      character*13  SType      (nr__) ! The SIMBAD type
      character*21  SName      (nr__) ! The SIMBAD name

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

C  Declarations for 'table3.dat'	! MSX sources in common with the 2MASS unreleased
                                 regions

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

C  J2000 position composed of: RAdeg DEdeg
      integer*4     MSX_1      (nr__1) ! The MSX number (G1)
      real*8        RAdeg_1    (nr__1) ! (deg) Right Ascension in decimal degrees (J2000)
      real*8        DEdeg_1    (nr__1) ! (deg) Declination in decimal degrees (J2000)
      real*4        Jmag_1     (nr__1) ! (mag) ? The J band magnitude
      real*4        Hmag_1     (nr__1) ! (mag) ? The H band magnitude
      real*4        Kmag_1     (nr__1) ! (mag) ? The K_s_ band magnitude
      real*4        Amag_1     (nr__1) ! (mag) The MSX A-band (8.3{mu}m) magnitude
      character*7   IRType_1   (nr__1) ! The IR type
      character*13  SType_1    (nr__1) ! The SIMBAD type
      character*21  SName_1    (nr__1) ! The SIMBAD name

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

C  Declarations for 'table4.dat'	! MSX sources without 2MASS point source matches

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

C  J2000 position composed of: RAdeg DEdeg
      integer*4     MSX_2      (nr__2) ! The MSX number (G1)
      real*8        RAdeg_2    (nr__2) ! (deg) Right Ascension in decimal degrees (J2000)
      real*8        DEdeg_2    (nr__2) ! (deg) Declination in decimal degrees (J2000)
      real*4        Amag_2     (nr__2) ! (mag) The MSX A-band (8.28{mu}m) magnitude
      real*4        Cmag       (nr__2) ! (mag) ? The MSX C-band (12.13{mu}m) magnitude
      real*4        Dmag       (nr__2) ! (mag) ? The MSX D-band (14.65{mu}m) magnitude
      real*4        Emag       (nr__2) ! (mag) ? The MSX E-band (21.34{mu}m) magnitude
      character*5   SType_2    (nr__2) ! The SIMBAD type
      character*18  SName_2    (nr__2) ! The SIMBAD name
      integer*4     Note1      (nr__2) ! Number of MSX scan legs in which the source
*                                   was detected (1)
      integer*4     Note2      (nr__2) ! ? Source appearance code in MSX A-band
*                                     coadded image (2)
      integer*4     Note3      (nr__2) ! ? Source appearance code in the 2MASS
*                                     images (3)
*Note (1): This is a possible measure of the source's reliability.
*Note (2): Note on source appearance in MSX A-band coadded image:
*    NULL = point source in MSX image;
*    2 = multiple/blended source at position;
*    3 = extended emission source at position;
*    4 = very low SNR source, possibly not real; and,
*    5 = no apparent emission.
*Note (3): Note on source appearance in the 2MASS images:
*    NULL = source not seen in 2MASS images;
*    2 = extended 2MASS emission;
*    3 = very bright (saturated) 2MASS star;
*    4 = possible positional mismatch; and,
*    5 = possible faint emission at source position in 2MASS images.

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

C  Loading file 'table2.dat'	! MSX sources in common with the 2MASS 2IDR

C  Format for file interpretation

    1 format(
     +  I4,1X,F7.4,1X,F8.4,1X,F5.2,1X,F5.2,1X,F5.2,1X,F5.2,1X,A7,1X,
     +  A13,1X,A21)

C  Effective file loading

      open(unit=1,status='old',file=
     +'table2.dat')
      write(6,*) '....Loading file: table2.dat'
      do i__=1,1488
        read(1,'(A89)')ar__
        read(ar__,1)
     +  MSX(i__),RAdeg(i__),DEdeg(i__),Jmag(i__),Hmag(i__),Kmag(i__),
     +  Amag(i__),IRType(i__),SType(i__),SName(i__)
        if(ar__(23:27) .EQ. '') Jmag(i__) = rNULL__
        if(ar__(29:33) .EQ. '') Hmag(i__) = rNULL__
        if(ar__(35:39) .EQ. '') Kmag(i__) = rNULL__
c    ..............Just test output...........
        write(6,1)
     +  MSX(i__),RAdeg(i__),DEdeg(i__),Jmag(i__),Hmag(i__),Kmag(i__),
     +  Amag(i__),IRType(i__),SType(i__),SName(i__)
c    .......End.of.Just test output...........
      end do
      close(1)

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

C  Loading file 'table3.dat'	! MSX sources in common with the 2MASS unreleased
*                                 regions

C  Format for file interpretation

    2 format(
     +  I4,1X,F7.4,1X,F8.4,1X,F5.2,1X,F5.2,1X,F5.2,1X,F5.2,1X,A7,1X,
     +  A13,1X,A21)

C  Effective file loading

      open(unit=1,status='old',file=
     +'table3.dat')
      write(6,*) '....Loading file: table3.dat'
      do i__=1,176
        read(1,'(A89)')ar__1
        read(ar__1,2)
     +  MSX_1(i__),RAdeg_1(i__),DEdeg_1(i__),Jmag_1(i__),Hmag_1(i__),
     +  Kmag_1(i__),Amag_1(i__),IRType_1(i__),SType_1(i__),
     +  SName_1(i__)
        if(ar__1(23:27) .EQ. '') Jmag_1(i__) = rNULL__
        if(ar__1(29:33) .EQ. '') Hmag_1(i__) = rNULL__
        if(ar__1(35:39) .EQ. '') Kmag_1(i__) = rNULL__
c    ..............Just test output...........
        write(6,2)
     +  MSX_1(i__),RAdeg_1(i__),DEdeg_1(i__),Jmag_1(i__),Hmag_1(i__),
     +  Kmag_1(i__),Amag_1(i__),IRType_1(i__),SType_1(i__),
     +  SName_1(i__)
c    .......End.of.Just test output...........
      end do
      close(1)

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

C  Loading file 'table4.dat'	! MSX sources without 2MASS point source matches

C  Format for file interpretation

    3 format(
     +  I4,1X,F7.4,1X,F8.4,1X,F5.3,1X,F5.3,1X,F5.3,1X,F6.3,1X,A5,1X,
     +  A18,1X,I1,1X,I1,1X,I1)

C  Effective file loading

      open(unit=1,status='old',file=
     +'table4.dat')
      write(6,*) '....Loading file: table4.dat'
      do i__=1,142
        read(1,'(A78)')ar__2
        read(ar__2,3)
     +  MSX_2(i__),RAdeg_2(i__),DEdeg_2(i__),Amag_2(i__),Cmag(i__),
     +  Dmag(i__),Emag(i__),SType_2(i__),SName_2(i__),Note1(i__),
     +  Note2(i__),Note3(i__)
        if(ar__2(29:33) .EQ. '') Cmag(i__) = rNULL__
        if(ar__2(35:39) .EQ. '') Dmag(i__) = rNULL__
        if(ar__2(41:46) .EQ. '') Emag(i__) = rNULL__
        if(ar__2(75:75) .EQ. '') Note2(i__) = iNULL__
        if(ar__2(77:77) .EQ. '') Note3(i__) = iNULL__
c    ..............Just test output...........
        write(6,3)
     +  MSX_2(i__),RAdeg_2(i__),DEdeg_2(i__),Amag_2(i__),Cmag(i__),
     +  Dmag(i__),Emag(i__),SType_2(i__),SName_2(i__),Note1(i__),
     +  Note2(i__),Note3(i__)
c    .......End.of.Just test output...........
      end do
      close(1)

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