FORTRAN Generation
(/./ftp/cats/J/AJ/123/567)

Conversion of standardized ReadMe file for file /./ftp/cats/J/AJ/123/567 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-17
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/123/567      SDSS quasar catalog, I: Early Data Release  (Schneider+, 2002)
*================================================================================
*The Sloan Digital Sky Survey quasar catalog. I. Early data release.
*    Schneider D.P., Richards G.T., Fan X., Hall P.B., Strauss M.A.,
*    Vanden Berk D.E., Gunn J.E., Newberg H.J., Reichard T.A., Stoughton C.,
*    Voges W., Yanny B., Anderson S.F., Annis J., Bahcall N.A., Bauer A.,
*    Bernardi M., Blanton M.R., Boroski W.N., Brinkmann J., Briggs J.W.,
*    Brunner R., Burles S., Carey L., Castander F.J., Connolly A.J., Csabai I.,
*    Doi M., Friedman S., Frieman J.A., Fukugita M., Heckman T.M.,
*    Hennessy G.S., Hindsley R.B., Hogg D.W., Ivezic Z., Kent S., Knapp G.R.,
*    Kunzst P.Z., Lamb D.Q., Leger R.F., Long D.C., Loveday J., Lupton R.H.,
*    Margon B., Meiksin A., Merelli A., Munn J.A., Newcomb M., Nichol R.C.,
*    Owen R., Pier J.R., Pope A., Rockosi C.M., Saxe D.H., Schlegel D.,
*    Siegmund W.A., Smee S., Snir Y., Subbarao M., Szalay A.S., Thakar A.R.,
*    Uomoto A., Waddell P., York D.G.
*   <Astron. J. 123, 567 (2002)>
*   =2002AJ....123..567S
C=============================================================================

C  Internal variables

      integer*4 i__

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

C  Declarations for 'table1.dat'	! SDSS spectroscopic plate information

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

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

      integer*4     Plate      (nr__) ! Plate number
      integer*4     RAh        (nr__) ! (h) Right ascension (J2000.0)
      integer*4     RAm        (nr__) ! (min) Right ascension (J2000.0)
      real*4        RAs        (nr__) ! (s) Right ascension (J2000.0)
      character*1   DE_        (nr__) ! Declination sign (J2000.0)
      integer*4     DEd        (nr__) ! (deg) Declination (J2000.0)
      integer*4     DEm        (nr__) ! (arcmin) Declination (J2000.0)
      integer*4     DEs        (nr__) ! (arcsec) Declination (J2000.0)
      integer*4     N          (nr__) ! Number of quasars in the catalog contained on
*                                   this plate

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

C  Declarations for 'table3.dat'	! The SDSS Quasar Catalog I

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

C  J2000 position composed of: RArad DErad
      character*1   f5         (nr__1) ! [*] Discrepant redshift (see table5)
      character*18  SDSS       (nr__1) ! Object name, hhmmss.ss+ddmmss.s (1)
      integer*4     RArad      (nr__1) ! (10-7rad) Right Ascension (J2000) (in 10^-7^ radians)
      integer*4     DErad      (nr__1) ! (10-7rad) Declination (J2000) (in 10^-7^ radians)
      real*4        z          (nr__1) ! Redshift
      integer*4     r_SDSS     (nr__1) ! Source of object (2)
      real*4        u_mag      (nr__1) ! (mag) The u* band magnitude (7)
      real*4        e_u_mag    (nr__1) ! (mag) The error in u*mag
      real*4        g_mag      (nr__1) ! (mag) The g* band magnitude (7)
      real*4        e_g_mag    (nr__1) ! (mag) The error in g*mag
      real*4        r_mag      (nr__1) ! (mag) The r* band magnitude (7)
      real*4        e_r_mag    (nr__1) ! (mag) The error in r*mag
      real*4        i_mag      (nr__1) ! (mag) The i* band magnitude (7)
      real*4        e_i_mag    (nr__1) ! (mag) The error in i*mag
      real*4        z_mag      (nr__1) ! (mag) The z* band magnitude (7)
      real*4        e_z_mag    (nr__1) ! (mag) The error in z*mag
      real*4        uAbs       (nr__1) ! (mag) Galactic absorption in u band
      real*8        PFlux      (nr__1) ! (mJy) ?=0.00 FIRST peak flux density at 20cm (1.4GHz)
      real*4        logCR      (nr__1) ! ([ct/s]) ?=0 Log of ROSAT full band count rate
      real*4        i_Mag_1    (nr__1) ! (mag) Absolute i* band magnitude (3)
      integer*4     Morph      (nr__1) ! [0,1] Morphologically extended flag (4)
      integer*4     TarSel     (nr__1) ! [0] Target selection version (5)
      integer*4     QFlag      (nr__1) ! [0,1] Quasar target flag (6)
      integer*4     FFlag      (nr__1) ! [0,1] FIRST target flag (6)
      integer*4     RFlag      (nr__1) ! [0,1] ROSAT target flag (6)
      integer*4     SFlag      (nr__1) ! [0,1] Serendipity target flag (6)
      integer*4     StFlag     (nr__1) ! [0,1] Star target flag (6)
      integer*4     GFlag      (nr__1) ! [0,1] Galaxy target flag (6)
      integer*4     SNum       (nr__1) ! SDSS Imaging Run Number for photometric
*                                 measurements
      integer*4     ObsDate    (nr__1) ! (d) Modified Julian Date (MJD=JD-2400000.5)
*                                 of spectroscopic observation
      integer*4     Plate_1    (nr__1) ! Spectroscopic Plate Number
      integer*4     Fiber      (nr__1) ! Spectroscopic Fiber Number
      character*20  OName      (nr__1) ! Object Name if not discovered by SDSS
*Note (1): The full name of an object is SDSS Jhhmmss.ss+ddmmss.s (J2000).
*Note (2): Source of object
*      0 = Early Data Release (EDR) quasar;
*      1 = Extreme BAL Search;
*      2 = Visual search of Early Data Release (EDR_ spectra.
*Note (3): Absolute i* band magnitude, assuming H_0_ = 50km/s/Mpc,
*      {Omega}_M_ = 1.00, {Omega}_L_ = 0.00, and {alpha}_Q_ = -0.50.
*Note (4): Morphology flag:
*      0 = point source;
*      2 = extended.
*Note (5): Target selection version (is always 0 in this version)
*      1 = 2.2a;
*      2 = 2.5;
*      3 = 2.7.
*Note (6): Flags:
*      0 = not targetted;
*      2 = targetted.
*Note (7): For the definition of the SDSS photometric system, see
*      Fukugita, et al., 1996AJ....111.1748F

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

C  Declarations for 'table5.dat'	! Discrepant redshifts

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

      character*18  SDSS_1     (nr__2) ! SDSS quasar name
      real*4        zSDSS      (nr__2) ! SDSS redshift
      real*4        Dz         (nr__2) ! ? NED-SDSS redshift
      character*20  Name       (nr__2) ! NED Object Name

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

C  Loading file 'table1.dat'	! SDSS spectroscopic plate information

C  Format for file interpretation

    1 format(I3,2X,I2,1X,I2,1X,F4.1,1X,A1,I2,1X,I2,1X,I2,1X,I3)

C  Effective file loading

      open(unit=1,status='old',file=
     +'table1.dat')
      write(6,*) '....Loading file: table1.dat'
      do i__=1,92
        read(1,'(A29)')ar__
        read(ar__,1)
     +  Plate(i__),RAh(i__),RAm(i__),RAs(i__),DE_(i__),DEd(i__),
     +  DEm(i__),DEs(i__),N(i__)
        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(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,1)
     +  Plate(i__),RAh(i__),RAm(i__),RAs(i__),DE_(i__),DEd(i__),
     +  DEm(i__),DEs(i__),N(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 'table3.dat'	! The SDSS Quasar Catalog I

C  Format for file interpretation

    2 format(
     +  A1,A18,2X,I8,2X,I8,1X,F5.3,1X,I1,1X,F5.2,1X,F4.2,1X,F5.2,1X,
     +  F4.2,1X,F5.2,1X,F4.2,1X,F5.2,1X,F4.2,1X,F5.2,1X,F4.2,2X,F4.2,
     +  1X,F7.2,1X,F6.3,1X,F6.2,2X,I1,2X,I1,2X,I1,2X,I1,2X,I1,2X,I1,
     +  2X,I1,2X,I1,2X,I4,1X,I5,2X,I3,1X,I3,1X,A20)

C  Effective file loading

      open(unit=1,status='old',file=
     +'table3.dat')
      write(6,*) '....Loading file: table3.dat'
      do i__=1,3814
        read(1,'(A196)')ar__1
        read(ar__1,2)
     +  f5(i__),SDSS(i__),RArad(i__),DErad(i__),z(i__),r_SDSS(i__),
     +  u_mag(i__),e_u_mag(i__),g_mag(i__),e_g_mag(i__),r_mag(i__),
     +  e_r_mag(i__),i_mag(i__),e_i_mag(i__),z_mag(i__),e_z_mag(i__),
     +  uAbs(i__),PFlux(i__),logCR(i__),i_Mag_1(i__),Morph(i__),
     +  TarSel(i__),QFlag(i__),FFlag(i__),RFlag(i__),SFlag(i__),
     +  StFlag(i__),GFlag(i__),SNum(i__),ObsDate(i__),Plate_1(i__),
     +  Fiber(i__),OName(i__)
c    ..............Just test output...........
        write(6,2)
     +  f5(i__),SDSS(i__),RArad(i__),DErad(i__),z(i__),r_SDSS(i__),
     +  u_mag(i__),e_u_mag(i__),g_mag(i__),e_g_mag(i__),r_mag(i__),
     +  e_r_mag(i__),i_mag(i__),e_i_mag(i__),z_mag(i__),e_z_mag(i__),
     +  uAbs(i__),PFlux(i__),logCR(i__),i_Mag_1(i__),Morph(i__),
     +  TarSel(i__),QFlag(i__),FFlag(i__),RFlag(i__),SFlag(i__),
     +  StFlag(i__),GFlag(i__),SNum(i__),ObsDate(i__),Plate_1(i__),
     +  Fiber(i__),OName(i__)
c    .......End.of.Just test output...........
      end do
      close(1)

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

C  Loading file 'table5.dat'	! Discrepant redshifts

C  Format for file interpretation

    3 format(1X,A18,2X,F4.2,2X,F5.2,2X,A20)

C  Effective file loading

      open(unit=1,status='old',file=
     +'table5.dat')
      write(6,*) '....Loading file: table5.dat'
      do i__=1,20
        read(1,'(A54)')ar__2
        read(ar__2,3)SDSS_1(i__),zSDSS(i__),Dz(i__),Name(i__)
        if(ar__2(28:32) .EQ. '') Dz(i__) = rNULL__
c    ..............Just test output...........
        write(6,3)SDSS_1(i__),zSDSS(i__),Dz(i__),Name(i__)
c    .......End.of.Just test output...........
      end do
      close(1)

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