FORTRAN Generation
(/./ftp/cats/VIII/62)

Conversion of standardized ReadMe file for file /./ftp/cats/VIII/62 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. VIII/62             The Westerbork Northern Sky Survey      (Leiden, 1998)
*================================================================================
*Westerbork Northern Sky Survey (WENSS)
*   de Bruyn G., Miley G., Rengelink R., Tang Y., Bremer M., Rottgering H.,
*   Raimond R., Bremer M., Fullagar D.
*  <WENSS Collaboration NFRA/ASTRON and Leiden Observatory (1998)>
C=============================================================================

C  Internal variables

      integer*4 i__

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

C  Declarations for 'main.dat'	! WENSS main catalogue (28 to 76{deg})

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

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

      character*13  Name       (nr__) ! *Designation of the source
      character*1   f_Name     (nr__) ! *[abmp] Several objects share the same name
      integer*4     RA1950h    (nr__) ! (h) Right Ascension B1950 (hours)
      integer*4     RA1950m    (nr__) ! (min) Right Ascension B1950 (minutes)
      real*4        RA1950s    (nr__) ! (s) Right Ascension B1950 (seconds)
      character*1   DE1950_    (nr__) ! Declination B1950 (sign)
      integer*4     DE1950d    (nr__) ! (deg) Declination B1950 (degrees)
      integer*4     DE1950m    (nr__) ! (arcmin) Declination B1950 (minutes)
      real*4        DE1950s    (nr__) ! (arcsec) Declination B1950 (seconds)
      integer*4     RAh        (nr__) ! (h) Right Ascension J2000 (hours)
      integer*4     RAm        (nr__) ! (min) Right Ascension J2000 (minutes)
      real*4        RAs        (nr__) ! (s) Right Ascension J2000 (seconds)
      character*1   DE_        (nr__) ! Declination J2000 (sign)
      integer*4     DEd        (nr__) ! (deg) Declination J2000 (degrees)
      integer*4     DEm        (nr__) ! (arcmin) Declination J2000 (minutes)
      real*4        DEs        (nr__) ! (arcsec) Declination J2000 (seconds)
      character*1   flg1       (nr__) ! *[SMEC] source type flag
      character*1   flg2       (nr__) ! *[*] problems in fitting the source
      integer*4     Speak      (nr__) ! (mJy) *Peak flux density at 330MHz in mJy/beam
      integer*4     Sint       (nr__) ! (mJy) *Integrated flux density 330MHz in mJy
      integer*4     MajAxis    (nr__) ! (arcsec) *Major axis
      integer*4     MinAxis    (nr__) ! (arcsec) *Minor axis
      integer*4     PA         (nr__) ! (deg) *Position angle (North to East)
      real*4        Nse        (nr__) ! (mJy) Local rms-noise level in mJy/beam
      character*9   Frame      (nr__) ! Frame from which the source was obtained
*Note on Name, f_Name:
*    The name has a format 'Bhhmm.m+ddmmA', where 'B' indicates a name based
*    on B1950 coordinates, followed by the truncated position to 0.1min in
*    right ascension and 1 arcmin in declination, followed by a letter
*    A,B,C,D for components of the multi-component sources.
*
*    There are 748 names which are assigned to more than one source; these
*    names are flagged "a", "b", "m" or "p" in the f_Name column:
*     a,b  when the same name exists in the same file (there are two
*          identical names in main.dat or polar.dat)
*     m,p  when the same name exists in the other file (there are two
*          identical names, one in main.dat, and the other one in polar.dat)
*Note on flg1: this flag indicates the source type as:
*     S = Single component source
*     M = Multicomponent source
*     C = Component of a multicomponent source
*     E = Extended source (more than four components)
*Note on flg2: warning flag indicating problems in fitting the source.
*     Source parameters were then obtained using 'aperture' integration.
*Note on Speak, Sint:
*     The frequency is 325MHz in the main part, and 352MHz in the polar part.
*Note on MajAxis, MinAxis, PA: sources that are probably resolved.
*    Non-null numbers indicate that the flux density ratio Sint/Speak
*    exceeds a signal-to-noise dependent threshold. This threshold is the
*    flux ratio Sint/Speak that is exceeded by less than 5% of the
*    unresolved sources. These parameters have not been deconvolved.

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

C  Declarations for 'polar.dat'	! WENSS polar catalogue (sources above 72{deg})

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

C  J2000 position composed of: RAh RAm RAs DE- DEd DEm DEs
      real*8        RAdeg_1    (nr__1) ! (deg) Right Ascension J2000
      real*8        DEdeg_1    (nr__1) ! (deg)     Declination J2000
C  ---------------------------------- ! (position vector(s) in degrees)

      character*13  Name_1     (nr__1) ! *Designation of the source
      character*1   f_Name_1   (nr__1) ! *[abmp] Several objects share the same name
      integer*4     RA1950h_1  (nr__1) ! (h) Right Ascension B1950 (hours)
      integer*4     RA1950m_1  (nr__1) ! (min) Right Ascension B1950 (minutes)
      real*4        RA1950s_1  (nr__1) ! (s) Right Ascension B1950 (seconds)
      character*1   DE1950__1  (nr__1) ! Declination B1950 (sign)
      integer*4     DE1950d_1  (nr__1) ! (deg) Declination B1950 (degrees)
      integer*4     DE1950m_1  (nr__1) ! (arcmin) Declination B1950 (minutes)
      real*4        DE1950s_1  (nr__1) ! (arcsec) Declination B1950 (seconds)
      integer*4     RAh_1      (nr__1) ! (h) Right Ascension J2000 (hours)
      integer*4     RAm_1      (nr__1) ! (min) Right Ascension J2000 (minutes)
      real*4        RAs_1      (nr__1) ! (s) Right Ascension J2000 (seconds)
      character*1   DE__1      (nr__1) ! Declination J2000 (sign)
      integer*4     DEd_1      (nr__1) ! (deg) Declination J2000 (degrees)
      integer*4     DEm_1      (nr__1) ! (arcmin) Declination J2000 (minutes)
      real*4        DEs_1      (nr__1) ! (arcsec) Declination J2000 (seconds)
      character*1   flg1_1     (nr__1) ! *[SMEC] source type flag
      character*1   flg2_1     (nr__1) ! *[*] problems in fitting the source
      integer*4     Speak_1    (nr__1) ! (mJy) *Peak flux density at 330MHz in mJy/beam
      integer*4     Sint_1     (nr__1) ! (mJy) *Integrated flux density 330MHz in mJy
      integer*4     MajAxis_1  (nr__1) ! (arcsec) *Major axis
      integer*4     MinAxis_1  (nr__1) ! (arcsec) *Minor axis
      integer*4     PA_1       (nr__1) ! (deg) *Position angle (North to East)
      real*4        Nse_1      (nr__1) ! (mJy) Local rms-noise level in mJy/beam
      character*9   Frame_1    (nr__1) ! Frame from which the source was obtained
*Note on Name, f_Name:
*    The name has a format 'Bhhmm.m+ddmmA', where 'B' indicates a name based
*    on B1950 coordinates, followed by the truncated position to 0.1min in
*    right ascension and 1 arcmin in declination, followed by a letter
*    A,B,C,D for components of the multi-component sources.
*
*    There are 748 names which are assigned to more than one source; these
*    names are flagged "a", "b", "m" or "p" in the f_Name column:
*     a,b  when the same name exists in the same file (there are two
*          identical names in main.dat or polar.dat)
*     m,p  when the same name exists in the other file (there are two
*          identical names, one in main.dat, and the other one in polar.dat)
*Note on flg1: this flag indicates the source type as:
*     S = Single component source
*     M = Multicomponent source
*     C = Component of a multicomponent source
*     E = Extended source (more than four components)
*Note on flg2: warning flag indicating problems in fitting the source.
*     Source parameters were then obtained using 'aperture' integration.
*Note on Speak, Sint:
*     The frequency is 325MHz in the main part, and 352MHz in the polar part.
*Note on MajAxis, MinAxis, PA: sources that are probably resolved.
*    Non-null numbers indicate that the flux density ratio Sint/Speak
*    exceeds a signal-to-noise dependent threshold. This threshold is the
*    flux ratio Sint/Speak that is exceeded by less than 5% of the
*    unresolved sources. These parameters have not been deconvolved.

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

C  Loading file 'main.dat'	! WENSS main catalogue (28 to 76{deg})

C  Format for file interpretation

    1 format(
     +  2X,A13,A1,1X,I2,1X,I2,1X,F5.2,1X,A1,I2,1X,I2,1X,F4.1,2X,I2,1X,
     +  I2,1X,F5.2,1X,A1,I2,1X,I2,1X,F4.1,2X,A1,1X,A1,2X,I6,1X,I7,1X,
     +  I4,1X,I3,1X,I3,1X,F4.1,1X,A9)

C  Effective file loading

      open(unit=1,status='old',file=
     +'main.dat')
      write(6,*) '....Loading file: main.dat'
      do i__=1,211234
        read(1,'(A114)')ar__
        read(ar__,1)
     +  Name(i__),f_Name(i__),RA1950h(i__),RA1950m(i__),RA1950s(i__),
     +  DE1950_(i__),DE1950d(i__),DE1950m(i__),DE1950s(i__),RAh(i__),
     +  RAm(i__),RAs(i__),DE_(i__),DEd(i__),DEm(i__),DEs(i__),
     +  flg1(i__),flg2(i__),Speak(i__),Sint(i__),MajAxis(i__),
     +  MinAxis(i__),PA(i__),Nse(i__),Frame(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)
     +  Name(i__),f_Name(i__),RA1950h(i__),RA1950m(i__),RA1950s(i__),
     +  DE1950_(i__),DE1950d(i__),DE1950m(i__),DE1950s(i__),RAh(i__),
     +  RAm(i__),RAs(i__),DE_(i__),DEd(i__),DEm(i__),DEs(i__),
     +  flg1(i__),flg2(i__),Speak(i__),Sint(i__),MajAxis(i__),
     +  MinAxis(i__),PA(i__),Nse(i__),Frame(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 'polar.dat'	! WENSS polar catalogue (sources above 72{deg})

C  Format for file interpretation

    2 format(
     +  2X,A13,A1,1X,I2,1X,I2,1X,F5.2,1X,A1,I2,1X,I2,1X,F4.1,2X,I2,1X,
     +  I2,1X,F5.2,1X,A1,I2,1X,I2,1X,F4.1,2X,A1,1X,A1,2X,I6,1X,I7,1X,
     +  I4,1X,I3,1X,I3,1X,F4.1,1X,A9)

C  Effective file loading

      open(unit=1,status='old',file=
     +'polar.dat')
      write(6,*) '....Loading file: polar.dat'
      do i__=1,18186
        read(1,'(A114)')ar__1
        read(ar__1,2)
     +  Name_1(i__),f_Name_1(i__),RA1950h_1(i__),RA1950m_1(i__),
     +  RA1950s_1(i__),DE1950__1(i__),DE1950d_1(i__),DE1950m_1(i__),
     +  DE1950s_1(i__),RAh_1(i__),RAm_1(i__),RAs_1(i__),DE__1(i__),
     +  DEd_1(i__),DEm_1(i__),DEs_1(i__),flg1_1(i__),flg2_1(i__),
     +  Speak_1(i__),Sint_1(i__),MajAxis_1(i__),MinAxis_1(i__),
     +  PA_1(i__),Nse_1(i__),Frame_1(i__)
        RAdeg_1(i__) = rNULL__
        DEdeg_1(i__) = rNULL__
c  Derive coordinates RAdeg_1 and DEdeg_1 from input data
c  (RAdeg_1 and DEdeg_1 are set to rNULL__ when unknown)
        if(RAh_1(i__) .GT. -180) RAdeg_1(i__)=RAh_1(i__)*15.
        if(RAm_1(i__) .GT. -180) RAdeg_1(i__)=RAdeg_1(i__)+RAm_1(i__)/4.
        if(RAs_1(i__) .GT. -180) RAdeg_1(i__)=RAdeg_1(i__)+RAs_1(i__)/240.
        if(DEd_1(i__) .GE. 0) DEdeg_1(i__)=DEd_1(i__)
        if(DEm_1(i__) .GE. 0) DEdeg_1(i__)=DEdeg_1(i__)+DEm_1(i__)/60.
        if(DEs_1(i__) .GE. 0) DEdeg_1(i__)=DEdeg_1(i__)+DEs_1(i__)/3600.
        if(DE__1(i__).EQ.'-'.AND.DEdeg_1(i__).GE.0) DEdeg_1(i__)=-DEdeg_1(i__)
c    ..............Just test output...........
        write(6,2)
     +  Name_1(i__),f_Name_1(i__),RA1950h_1(i__),RA1950m_1(i__),
     +  RA1950s_1(i__),DE1950__1(i__),DE1950d_1(i__),DE1950m_1(i__),
     +  DE1950s_1(i__),RAh_1(i__),RAm_1(i__),RAs_1(i__),DE__1(i__),
     +  DEd_1(i__),DEm_1(i__),DEs_1(i__),flg1_1(i__),flg2_1(i__),
     +  Speak_1(i__),Sint_1(i__),MajAxis_1(i__),MinAxis_1(i__),
     +  PA_1(i__),Nse_1(i__),Frame_1(i__)
        write(6,'(6H Pos: 2F8.4)') RAdeg_1(i__),DEdeg_1(i__)
c    .......End.of.Just test output...........
      end do
      close(1)

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