FORTRAN Generation
(/./ftp/cats/III/197)

Conversion of standardized ReadMe file for file /./ftp/cats/III/197 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. III/197             IRAS Low Resolution Spectra    (IRAS team, 1987)
*================================================================================
*IRAS Low Resolution Spectra (LRS)
*     Joint IRAS Science Working Group
*    <NASA RP-1190 (1987)>
*    =1987yCat.3197....0J
C=============================================================================

C  Internal variables

      integer*4 i__

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

C  Declarations for 'calib.dat'	! Wavelength table

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

      real*8        Angle      (100,nr__) ! (arcmin) Angle from center of slit
*                                    (one number per sample)
      real*8        Lambda1    (100,nr__) ! (um) Wavelength in 8-13um
*                                    corresponding to each sample
      real*8        Lambda2    (100,nr__) ! (um) Wavelength in 11-22um
*                                    corresponding to each sample

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

C  Declarations for 'lrs.dat'	! The IRAS Low Resolution Spectra

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

C  1950.0 position composed of: RAh RAm RAds DE- DEd DEm DEs (Epoch=1983.5)
      real*8        RAdeg      (nr__1) ! (deg) Right Ascension 1950.0, Epoch=1983.5
      real*8        DEdeg      (nr__1) ! (deg)     Declination 1950.0, Epoch=1983.5
C  ---------------------------------- ! (position vector(s) in degrees)

      character*11  IRAS       (nr__1) ! IRAS source name
      integer*4     RAh        (nr__1) ! (h) Hours RA, equinox 1950.0, epoch 1983.5
      integer*4     RAm        (nr__1) ! (min) Minutes RA
      integer*4     RAds       (nr__1) ! (0.1s) [0/600] Deci-seconds RA
      character*1   DE_        (nr__1) ! Sign Dec, equinox 1950.0, epoch 1983.5
      integer*4     DEd        (nr__1) ! (deg) Degrees Dec, equinox 1950.0, epoch 1983.5
      integer*4     DEm        (nr__1) ! (arcmin) Minutes Dec
      integer*4     DEs        (nr__1) ! (arcsec) [0/60] Seconds Dec
      real*4        F12        (nr__1) ! (Jy) Average non-color corrected flux density, 12um
      real*4        F25        (nr__1) ! (Jy) Average non-color corrected flux density, 25um
      real*4        F60        (nr__1) ! (Jy) Average non-color corrected flux density, 60um
      real*4        F100       (nr__1) ! (Jy) Average non-color corrected flux density 100um
      integer*4     NLRS       (nr__1) ! Number of significant LRS spectra
      integer*4     Nsp1       (nr__1) ! Number of accepted spectra in  8-13um band
      integer*4     Nsp2       (nr__1) ! Number of accepted spectra in 11-22um band
      integer*4     LRSChar    (nr__1) ! Characterization of averaged LRS spectrum (1)
      integer*4     SpQual1    (nr__1) ! [1/3] Quality of spectrum in  8-13um band (2)
      integer*4     SpQual2    (nr__1) ! [1/3] Quality of spectrum in 11-22um band (2)
      integer*4     Var        (nr__1) ! Percent likelihood of variability
      integer*4     NID        (nr__1) ! Number of associations in file "assoc.dat"
      integer*4     IDType     (nr__1) ! [0/4] Type of association (5)
      integer*4     Bline1s    (nr__1) ! Average of samples  1-20  in  8-13um band (4)
      integer*4     Bline1l    (nr__1) ! Average of samples 81-100 in  8-13um band (4)
      integer*4     Bline2s    (nr__1) ! Average of samples  1-20  in 11-22um band (4)
      integer*4     Bline2l    (nr__1) ! Average of samples 81-100 in 11-22um band (4)
      integer*4     Noise1     (nr__1) ! rms noise of  8-13um band (4)
      integer*4     Noise2     (nr__1) ! rms noise of 11-22um band (4)
      real*4        SNR1       (nr__1) ! Signal-to-noise ratio in  8-13um band
      real*4        SNR2       (nr__1) ! Signal-to-noise ratio in 11-22um band
      real*4        Asymm1     (nr__1) ! Asymmetry in   8-13um band (3)
      real*4        Asymm2     (nr__1) ! Asymmetry in  11-22um band (3)
      real*4        Sratio     (nr__1) ! Ratio of integrated LRS to 12um flux
      real*4        SCALE      (nr__1) ! (W/m2/um) Scale factor for all flux densities (4)
      integer*4     LRS1       (100,nr__1) ! Scaled fluxes in  8-13um band (4)
      integer*4     LRS2       (100,nr__1) ! Scaled fluxes in 11-22um band (4)
*Note (1): See Table IX.D.1 page IX-15 of publication which details
*    the spectral classification scheme. The leftmost digit indicates
*    the following typical objects (other are unknown):
*    1x = star, Sp<=M5 ;
*    2x = star with not too thick O-rich envelopes
*    3x = star with thick O-rich envelopes
*    4x = star with C-rich envelopes
*    6x = star with very thick O-rich envelopes
*    7x = star with extremely thick O-rich envelopes
*    8x = compact HII regions and PNe
*Note (2): the quality indicator is
*     1 = good ;     2 = moderate ;    3 = barely acceptable
*Note (3): the value indicates by what fraction of the average signal
*    the baselines on the short and long wavelength sides of the spectrum
*    halves differ. A large baseline asymmetry indicates that a confusing
*    source may have contaminated the spectrum. The baseline asymmetry is
*    usually large near the Galactic plane.
*Note (4): the integers Blinexx, Noisex, and flux values LRSx must be
*    multiplied by SCALE to get values of flux densities expressed
*    in W.m^-2^.um^-1^. The wavelength array is given in "calib.dat" .
*Note (5): the IDType states whether an association was found in:
*      1 = extragalactic catalog ;
*      2 = stellar catalog ;
*      3 = other catalogs ;
*      4 = multiple types of catalogs.

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

C  Declarations for 'assoc.dat'	! Associated sources

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

      character*11  IRAS_1     (nr__2) ! IRAS source name
      integer*4     RecNo      (nr__2) ! Record number of IRAS source in lrs.dat
      integer*4     CatNum     (nr__2) ! Catalog number (1)
      character*15  Source     (nr__2) ! Source identification
      character*5   Type       (nr__2) ! Source type or spectral class (1)
      integer*4     Radius     (nr__2) ! (arcsec) Radius vector from IRAS source to association
      integer*4     Pos        (nr__2) ! (deg) Position angle (E of N), IRAS source to object
      integer*4     Field1     (nr__2) ! Object data field 1, catalog dependent (1)
      integer*4     Field2     (nr__2) ! Object data field 2, catalog dependent (1)
      integer*4     Field3     (nr__2) ! Object data field 3, catalog dependent (1)
*Note (1): Table X.B.4 in  the "IRAS Catalogs and Atlases Explanatory:
* Meaning of the Source Association Fields.
* ------------------------------------------------------------------------------
* CatNum             Field and Meaning
* ------------------------------------------------------------------------------
* 1 GCVS             Type             Blank
*                    Field1 =         Code gives meaning for Fields 2-3
*                    if Field1 = 1    Field2 and Field3 are B mag [decimag] at
*                                        max,min
*                              = 2    Field2 and Field3 are V mag [decimag] at
*                                        max,min
*                              = 3    Field2 and Field3 are photographic mag
*                                        [decimag] at max,min
*                              = 4    Field2 and Field3 are estimated V mag
*                                        [decimag] at max,min
*                              = 5    Field2 is 999 and Field3 is 0
* ------------------------------------------------------------------------------
* 2 Dearborn         Type             Blank
*   Obs.             Field1           Code for Field2 (1,2)
*                    Field2           if Field1 is 1, Field2 is red magnitude
*                                        [decimag]*
*                                     if Field1 is 2, Field2 is 999
*                    Field3           0
* ------------------------------------------------------------------------------
* 3 Revised          Type             Blank
*   AFGL             Field1           Magnitude at 4.2 microns [decimag]
*                    Field2           Magnitude at 11 microns [decimag]
*                    Field3           Magnitude at 27 microns [decimag]
* ------------------------------------------------------------------------------
* 4 2-Micron         Type             Blank
*   Sky Survey       Field1           K magnitude [decimag]
*                    Field2           I magnitude [decimag]
*                    Field3           0
* ------------------------------------------------------------------------------
* 5 Globules         Type             Blank
*   (Wesselius)      Field1           999
*                    Field2           Minimum diameter [arcsec]
*                    Field3           Maximum diameter [arcsec]
* ------------------------------------------------------------------------------
* 6 RC2              Type             Blank
*                    Field1           Harvard V magnitude [decimag]
*                    Field2           B(T) [decimag]
*                    Field3           D(0) [arcsec]
* ------------------------------------------------------------------------------
* 7 Stars with       Type             Blank
*   em. lines        Field1           V magnitude [decimag]
*                    Field2           999
*                    Field3           0
* ------------------------------------------------------------------------------
* 8 Equatorial       Type             Blank
*   IR Cat.          Field1           Flux density [1.0E-16 W/cm**2/um]
*                                        at 2.7 microns
*                    Field2           999
*                    Field3           0
* ------------------------------------------------------------------------------
* 9 UGC              Type             Blank
*                    Field1           Zwicky magnitude [decimag]
*                    Field2           Minimum diameter [arcsec] in B
*                    Field3           Maximum diameter [arcsec] in B
* ------------------------------------------------------------------------------
* 10 MCG             Type             Blank
*                    Field1           999
*                    Field2           Minimum diameter [arcsec] in B
*                    Field3           Maximum diameter [arcsec] in B
* ------------------------------------------------------------------------------
* 11 Strasbourg      Type             Blank
* Planetary Nebulae  Field1           V magnitude of Nebula [decimag]
*                    Field2           B magnitude of Center Star [decimag]
*                    Field3           Minimum diameter of Nebula [arcsec]
* ------------------------------------------------------------------------------
* 12 Zwicky          Type             Blank
*                    Field1           Zwicky magnitude [decimag]
*                    Field2           999
*                    Field3           0
* ------------------------------------------------------------------------------
* 13 SAO             Type             Spectral Type
*                    Field1           V magnitude [decimag]
*                    Field2           p(g) magnitude [decimag]
*                    Field3           0
* ------------------------------------------------------------------------------
* 14 ESO/            Type             First 3 characters of object type
* Uppsala            Field1           B magnitude [decimag]
*                    Field2           Maximum diameter [arcsec]
*                    Field3           Minimum diameter [arcsec]
* ------------------------------------------------------------------------------
* 15 Bright          Type             Spectral Type
* Stars              Field1           V magnitude [decimag]
*                    Field2           B-V [centimag]
*                    Field3           U-B [centimag]
* ------------------------------------------------------------------------------
* 16 Suspected       Type             Spectral Information
* Var.               Field1           V magnitude at maximum [decimag]
*                    Field2           999
*                    Field3           0
* ------------------------------------------------------------------------------
* 17 Carbon          Type             Spectral Type (May be truncated)
* Stars              Field1           p(g) magnitude [decimag]
*                    Field2           V magnitude [decimag]
*                    Field3           I magnitude [decimag]
* ------------------------------------------------------------------------------
* 18 Gliese          Type             Spectral Type (May be truncated)
*                    Field1           V magnitude [decimag]
*                    Field2           B-V magnitude [millimag]
*                    Field3           U-B magnitude [millimag]
* ------------------------------------------------------------------------------
* 19 S Stars         Type             Blank
*                    Field1           p(g) magnitude [millimag]
*                    Field2           V magnitude [decimag]
*                    Field3           I magnitude [decimag]
* ------------------------------------------------------------------------------
* 20 Parkes HII      Type             Blank
* Survey             Field1           999
*                    Field2           Minimum diameter [arcsec]
*                    Field3           Maximum diameter [arcsec]
* ------------------------------------------------------------------------------
* 21 Bonn HII        Type             Blank
* Survey             Field1           Flux density at 4.875 GHz (Jy)
*                    Field2           Diameter [arcsec]
*                    Field3           0
* ------------------------------------------------------------------------------
* 22 Blitz           Type             Blank
*                    Field1           Diameter [arcsec]
*                    Field2           V(CO) [Km/s]
*                    Field3           Peak T(A) [degrees K]
* ------------------------------------------------------------------------------
* 23 OSU             Type             Blank
*                    Field1           999
*                    Field2           999
*                    Field3           Diameter [arcsec]
* ------------------------------------------------------------------------------
* 24 IRC             Type             C if 2.2 micron sources are possibly
*                                        confused, w/good pos. blank otherwise
*                    Field1           Right ascension difference (IRC-IRAS)
*                                        [deciseconds of time]
*                    Field2           Declination difference (IRC-IRAS)
*                                        [seconds of arc]
*                    Field3           0
* ------------------------------------------------------------------------------
* 25 DDO             Type             Blank
*                    Field1           999
*                    Field2           999
*                    Field3           0
* ------------------------------------------------------------------------------
* 26 Arp             Type             Blank
*                    Field1           999
*                    Field2           999
*                    Field            0
* ------------------------------------------------------------------------------
* 27 Markarian       Type             Blank
*                    Field1           999
*                    Field2           999
*                    Field3           0
* ------------------------------------------------------------------------------
* 28 Strong          Type             Object type (GAL or QSO)
* 5 GHz              Field1           V magnitude [decimag]
*                    Field2           5 GHz flux density [deciJy]
*                    Field3           0
* ------------------------------------------------------------------------------
* 29 Veron-          Type             Object classification
* Veron              Field1           V magnitude [decimag]
*                    Field2           Redshift x 1000
*                    Field3           0
* ------------------------------------------------------------------------------
* 30 Zwicky          Type             Blank
* 8 Lists            Field1           999
*                    Field2           999
*                    Field3           0
* ------------------------------------------------------------------------------
* 31 VV              Type             Blank
*                    Field1           Special flag, (see below) 999 otherwise
*                    Field2           999
*                    Field3           0
* ------------------------------------------------------------------------------
*                  VV Catalog Special Flags (Catalog 31)
* ------------------------------------------------------------------------------
* Field1   Explanation
*     10   VV 10 has the same coordinates  as VV 29 in the VV  Atlas.  The
*          UGC was used to confirm  that the coordinate is correct  for VV
*          29 and erroneous for VV 10.   The UGC position for VV 10  = UGC
*          10814 was adopted.
*     11   The  VV  position  is  substantially  different  (>400")   from
*          positions for the  object in other  catalogs.  The VV  position
*          has  been  assumed  to  be  in  error because two or more other
*          catalogs agree on a  different position.  The UGC  position has
*          been adopted.
*     12   Same as for 11, but the OSU position has been adopted.
*     13   The position in the VV  Atlas, and the position listed  for the
*          VV object in  the OSU are  in disagreement.  The  true position
*          has been established to be close to that of the OSU by the  use
*          of overlay  transparencies on  the POSS.  The OSU  position has
*          been adopted.
*     14   Same as for 13, but the  OSU position is not very good  either,
*          so a new position has been measured (accurate to about 1').
* ------------------------------------------------------------------------------

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

C  Loading file 'calib.dat'	! Wavelength table

C  Format for file interpretation

    1 format(100F8.4,100F8.4,100F8.4)

C  Effective file loading

      open(unit=1,status='old',file=
     +'calib.dat')
      write(6,*) '....Loading file: calib.dat'
      do i__=1,1
        read(1,'(A2400)')ar__
        read(ar__,1)
     +  (Angle(j__,i__),j__=1,100),(Lambda1(j__,i__),j__=1,100),
     +  (Lambda2(j__,i__),j__=1,100)
c    ..............Just test output...........
        write(6,1)
     +  (Angle(j__,i__),j__=1,100),(Lambda1(j__,i__),j__=1,100),
     +  (Lambda2(j__,i__),j__=1,100)
c    .......End.of.Just test output...........
      end do
      close(1)

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

C  Loading file 'lrs.dat'	! The IRAS Low Resolution Spectra

C  Format for file interpretation

    2 format(
     +  A11,I2,I2,I3,A1,I2,I2,I2,E9.3,E9.3,E9.3,E9.3,I2,I2,I2,I2,I1,
     +  I1,I2,I2,I1,4X,I4,I4,I4,I4,I4,I4,E10.3,E10.3,E10.3,E10.3,F5.2,
     +  E11.5,100I4,100I4)

C  Effective file loading

      open(unit=1,status='old',file=
     +'lrs.dat')
      write(6,*) '....Loading file: lrs.dat'
      do i__=1,5425
        read(1,'(A960)')ar__1
        read(ar__1,2)
     +  IRAS(i__),RAh(i__),RAm(i__),RAds(i__),DE_(i__),DEd(i__),
     +  DEm(i__),DEs(i__),F12(i__),F25(i__),F60(i__),F100(i__),
     +  NLRS(i__),Nsp1(i__),Nsp2(i__),LRSChar(i__),SpQual1(i__),
     +  SpQual2(i__),Var(i__),NID(i__),IDType(i__),Bline1s(i__),
     +  Bline1l(i__),Bline2s(i__),Bline2l(i__),Noise1(i__),
     +  Noise2(i__),SNR1(i__),SNR2(i__),Asymm1(i__),Asymm2(i__),
     +  Sratio(i__),SCALE(i__),(LRS1(j__,i__),j__=1,100),(LRS2(j__,
     +  i__),j__=1,100)
        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(RAds(i__) .GT. -180) RAdeg(i__)=RAdeg(i__)+RAds(i__)/2400.
        if(DEd(i__) .GE. 0) DEdeg(i__)=DEd(i__)
        if(DEm(i__) .GE. 0) DEdeg(i__)=DEdeg(i__)+DEm(i__)/60.
        if(DEs(i__) .GE. 0) DEdeg(i__)=DEdeg(i__)+DEs(i__)/3600.
        if(DE_(i__).EQ.'-'.AND.DEdeg(i__).GE.0) DEdeg(i__)=-DEdeg(i__)
c    ..............Just test output...........
        write(6,2)
     +  IRAS(i__),RAh(i__),RAm(i__),RAds(i__),DE_(i__),DEd(i__),
     +  DEm(i__),DEs(i__),F12(i__),F25(i__),F60(i__),F100(i__),
     +  NLRS(i__),Nsp1(i__),Nsp2(i__),LRSChar(i__),SpQual1(i__),
     +  SpQual2(i__),Var(i__),NID(i__),IDType(i__),Bline1s(i__),
     +  Bline1l(i__),Bline2s(i__),Bline2l(i__),Noise1(i__),
     +  Noise2(i__),SNR1(i__),SNR2(i__),Asymm1(i__),Asymm2(i__),
     +  Sratio(i__),SCALE(i__),(LRS1(j__,i__),j__=1,100),(LRS2(j__,
     +  i__),j__=1,100)
        write(6,'(6H Pos: 2F8.4)') RAdeg(i__),DEdeg(i__)
c    .......End.of.Just test output...........
      end do
      close(1)

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

C  Loading file 'assoc.dat'	! Associated sources

C  Format for file interpretation

    3 format(A11,I6,1X,I2,A15,A5,I3,I3,I4,I4,I4)

C  Effective file loading

      open(unit=1,status='old',file=
     +'assoc.dat')
      write(6,*) '....Loading file: assoc.dat'
      do i__=1,10913
        read(1,'(A58)')ar__2
        read(ar__2,3)
     +  IRAS_1(i__),RecNo(i__),CatNum(i__),Source(i__),Type(i__),
     +  Radius(i__),Pos(i__),Field1(i__),Field2(i__),Field3(i__)
c    ..............Just test output...........
        write(6,3)
     +  IRAS_1(i__),RecNo(i__),CatNum(i__),Source(i__),Type(i__),
     +  Radius(i__),Pos(i__),Field1(i__),Field2(i__),Field3(i__)
c    .......End.of.Just test output...........
      end do
      close(1)

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