FORTRAN Generation
(/./ftp/cats/J/ApJS/200/9)

Conversion of standardized ReadMe file for file /./ftp/cats/J/ApJS/200/9 into FORTRAN code for reading data files line by line.

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-May-14
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/ApJS/200/9                The ACS-GC catalog                (Griffith+, 2012)
*================================================================================
*The Advanced Camera for Surveys General Catalog: structural parameters for
*approximately half a million galaxies.
*    Griffith R.L., Cooper M.C., Newman J.A., Moustakas L.A., Stern D.,
*    Comerford J.M., Davis M., Lotz J.M., Barden M., Conselice C.J., Capak P.L.,
*    Faber S.M., Kirkpatrick J.D., Koekemoer A.M., Koo D.C., Noeske K.G.,
*    Scoville N., Sheth K., Shopbell P., Willmer C.N.A., Weiner B.
*   <Astrophys. J. Suppl. Ser., 200, 9 (2012)>
*   =2012ApJS..200....9G
C=============================================================================

C  Internal variables

      integer*4 i__

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

C  Declarations for 'acs-gc.dat'	! The ACS-GC catalog (V1.0)

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

C  J2000 position composed of: RAdeg DEdeg
      integer*4     ObjNo       ! Unique object number (OBJNO) (1)
      integer*4     Survey      ! ?=- Unique survey ID if available (SURVEY_ID)
      real*8        RAdeg       ! (deg) Right Ascension (J2000) (RA)
      real*8        DEdeg       ! (deg) Declination (DEC)
      integer*4     Nf1         ! [0/23] Total number of objects simultaneously
*                                        fitted, for filter#1 (NTOT_HI)
      integer*4     Nf2         ! [0/15]? Total number of objects simultaneously
*                                        fitted, for filter#2 (NTOT_LOW)
      character*7   Imaging     ! Imaging survey: AEGIS, COSMOS, GEMS,
*                                 GOODS-N or GOODS-S (IMAGING)
      real*8        zsp         ! ? Spectroscopic redshift (SPECZ)
      real*4        zph         ! ? Photometric redshift (PHOTOZ)
      real*8        zchi2       ! ? Reduced {chi}^2^ for zph (PHOTOZ_CHI2)
      real*4        e_zph       ! ? Error on zph (PHOTOZ_ERR) (2)
      real*4        q_zsp       ! [-2/212]? Quality flag for zsp (ZQUALITY) (3)
      character*11  r_zsp       ! Origin of zsp (Z_ORIGIN)
      real*8        z           ! ? Best available redshift (Z)
      real*4        Bmag        ! ? B-band apparent magnitude (MAGB)
      real*4        e_Bmag      ! ? Error in Bmag (MAGB_ERR)
      real*4        Rmag1       ! ? R-band apparent magnitude (MAGR)
      real*4        e_Rmag1     ! ? Error in Rmag (MAGR_ERR)
      real*4        Imag1       ! ? I-band apparent magnitude (MAGI)
      real*4        e_Imag1     ! ? Error in Imag (MAGI_ERR)
      real*4        umag        ! ? u-band apparent magnitude (CFHT_U)
      real*4        e_umag      ! ? Error in umag (CFHT_U_ERR)
      real*4        gmag        ! ? g-band apparent magnitude (CFHT_G)
      real*4        e_gmag      ! ? Error in gmag (CFHT_G_ERR)
      real*4        rmag        ! ? r-band apparent magnitude (CFHT_R)
      real*4        e_rmag      ! ? Error in rmag (CFHT_R_ERR)
      real*4        imag        ! ? i-band apparent magnitude (CFHT_I)
      real*4        e_imag      ! ? Error in imag (CFHT_I_ERR)
      real*4        zmag        ! ? z-band apparent magnitude (CFHT_Z)
      real*4        e_zmag      ! ? Error in zmag (CFHT_Z_ERR)
      real*4        E_B_V       ! [0/0.5]? Extinction (color excess) (EBV)
      character*15  Class       ! Source classification from DEEP2 and
*                                 COMBO-17: AGN, QSO, Galaxu, Star (CLASS)
      real*4        mu1         ! (mag/arcsec2) ? Surface brightness in filter#1 (MU_HI)
      real*4        mu2         ! (mag/arcsec2) ? Surface brightness in filter#2 (MU_LOW)
      real*4        PAim1       ! (deg) [-90/90] SExtractor image orientation,
*                                 filter#1 (THETA_IMAGE_HI)
      real*4        PAim2       ! (deg) [-90/90]? SExtractor image orientation,
*                                 filter#2 (THETA_IMAGE_LOW)
      real*4        PA1         ! (deg) [-90/90] SExtractor position angle,
*                                 filter#1 (THETA_WORLD_HI)
      real*4        PA2         ! (deg) [-90/90]? SExtractor position angle,
*                                 filter#1 (THETA_WORLD_LOW)
      real*4        b_a1        ! [0/1] SExtractor axis ratio b/a,
*                                 filter#1 (BA_HI)
      real*4        b_a2        ! [0/1]? SExtractor axis ratio b/a,
*                                 filter#2 (BA_LOW)
      real*4        rKron1      ! [0/14] SExtractor Kron radius,
*                                 filter#1 (KRON_RADIUS_HI)
      real*4        rKron2      ! [0/14]? SExtractor Kron radius,
*                                 filter#2 (KRON_RADIUS_LOW)
      real*4        FWHM1       ! (pix) SExtractor full width at half maximum,
*                                 filter#1 (FWHM_HI
      real*4        FWHM2       ! (pix) ? SExtractor full width at half maximum,
*                                 filter#2 (FWHM_LOW)
      real*8        a1          ! (pix) SExtractor major axis, filter#1 (A_IMAGE_HI)
      real*8        a2          ! (pix) ? SExtractor major axis, filter#2 (A_IMAGE_LOW)
      real*8        b1          ! (pix) SExtractor minor axis, filter#1 (B_IMAGE_HI)
      real*8        b2          ! (pix) ? SExtractor minor axis, filter#2 (B_IMAGE_LOW)
      real*8        bg1         ! (ct) ? SExtractor sky background,
*                                 filter#1 (BACKGROUND_HI)
      real*8        bg2         ! (ct) ? SExtractor sky background,
*                                 filter#2 (BACKGROUND_LOW)
      real*4        Fbest1      ! (ct) SExtractor best flux, filt#1 (FLUX_BEST_HI)
      real*4        Fbest2      ! (ct) ? SExtractor best flux, filt#2 (FLUX_BEST_LOW)
      real*4        e_Fbest1    ! (ct) Error on Fbest1 (FLUXERR_BEST_HI)
      real*4        e_Fbest2    ! (ct) ? Error on Fbest2 (FLUXERR_BEST_LOW)
      real*4        mbest1      ! (mag) ?=0 SExtractor best magnitude,
*                                 filter#1 (MAG_BEST_HI)
      real*4        mbest2      ! (mag) ? SExtractor best magnitude,
*                                 filter#2 (MAG_BEST_LOW)
      real*4        e_mbest1    ! (mag) ? Error on mbest1 (MAGERR_BEST_HI)
      real*4        e_mbest2    ! (mag) ? Error on mbest2 (MAGERR_BEST_LOW)
      real*8        Re_S1       ! (pix) ? SExtractor effective radius,
*                                 filter#1 (FLUX_RADIUS_HI)
      real*8        Re_S2       ! (pix) ? SExtractor effective radius,
*                                 filter#2 (FLUX_RADIUS_LOW)
      integer*4     Area1       ! (pix) ? SExtractor isophotal area,
*                                 filter#1 (ISOAREA_IMAGE_HI)
      integer*4     Area2       ! (pix) ? SExtractor isophotal area,
*                                 filter#2 (ISOAREA_IMAGE_LOW)
      integer*4     Sf1         ! [0/31]? SExtractor flags,
*                                 filter#1 (SEX_FLAGS_HI)
      integer*4     Sf2         ! [0/31]? SExtractor flags,
*                                 filter#2 (SEX_FLAGS_LOW)
      integer*4     Gf1         ! GALFIT flag: 0=good, 1=bad (FLAG_GALFIT_HI)
      integer*4     Gf2         ! ? GALFIT flag: 0=good, 1=bad (FLAG_GALFIT_LOW)
      real*4        Gchi1       ! ? GALFIT reduced {chi}^2^ (CHI2NU_HI)
      real*4        Gchi2       ! ? GALFIT reduced {chi}^2^ (CHI2NU_LOW)
      real*4        s_g1        ! [0/1] SExtractor star(1)/galaxy(0) class
*                                 (CLASS_STAR_HI)
      real*4        s_g2        ! [0/1]? SExtractor star(1)/galaxy(0) class
*                                 (CLASS_STAR_LOW)
      real*8        Xpos1       ! (pix) GALFIT X position (X_GALFIT_HI)
      real*8        Xpos2       ! (pix) ? GALFIT X position (X_GALFIT_LOW)
      real*8        Ypos1       ! (pix) GALFIT Y position (Y_GALFIT_HI)
      real*8        Ypos2       ! (pix) ? GALFIT Y position (Y_GALFIT_LOW)
      real*4        mGal1       ! (mag) ?=0 GALFIT magnitude, filter#1 (MAG_GALFIT_HI)
      real*4        mGal2       ! (mag) ? GALFIT magnitude, filter#2 (MAG_GALFIT_LOW)
      real*4        Re_G1       ! (pix) GALFIT effective radius (RE_GALFIT_HI)
      real*4        Re_G2       ! (pix) ? GALFIT effective radius (RE_GALFIT_LOW)
      real*4        n_G1        ! [0/8]? GALFIT Sersic index (N_GALFIT_HI)
      real*4        n_G2        ! [0/8]? GALFIT Sersic index (N_GALFIT_LOW)
      real*4        b_a_G1      ! [0/360]? GALFIT axis ratio (BA_GALFIT_HI)
      real*4        b_a_G2      ! [0/360]? GALFIT axis ratio (BA_GALFIT_LOW)
      real*4        pa_G1       ! (deg) [-90/90]? GALFIT position angle (PA_GALFIT_HI)
      real*4        pa_G2       ! (deg) [-90/90]? GALFIT position angle (PA_GALFIT_LOW)
      real*4        bg_G1       ! (ct) GALFIT background (SKY_GALFIT_HI)
      real*4        bg_G2       ! (ct) ? GALFIT background (SKY_GALFIT_LOW)
      real*4        e_mGal1     ! (mag) ? Error on mGal1 (MAGERR_GALFIT_HI)
      real*4        e_mGal2     ! (mag) ? Error on mGal2 (MAGERR_GALFIT_LOW)
      real*4        e_Re_G1     ! (pix) ? Error on Re.G1 (REERR_GALFIT_HI)
      real*4        e_Re_G2     ! (pix) ? Error on Re.G2 (REERR_GALFIT_LOW)
      real*4        e_n_G1      ! ? Error on n.G1 (NERR_GALFIT_HI)
      real*4        e_n_G2      ! ? Error on n.G2 (NERR_GALFIT_LOW)
      real*4        e_b_a_G1    ! ? Error on b/a.G1 (BAERR_GALFIT_HI)
      real*4        e_b_a_G2    ! ? Error on b/a.G2 (BAERR_GALFIT_LOW)
      real*4        e_pa_G1     ! (deg) ? Error on pa.G1 (PAERR_GALFIT_HI)
      real*4        e_pa_G2     ! (deg) ? Error on pa.G2 (PAERR_GALFIT_LOW)
      character*12  Morph       ! Visual morphology classification (VIS_MORPH)
*Note (1): Object numbers follow the convention (see Table 4):
*  ------------------------------------------------------------------------------
*  Survey       Objno     Description (filters #1 and #2)
*  ------------------------------------------------------------------------------
*  AEGIS        100.....  F814W(1) and F606W(2) detection in ACS-GC but not DEEP2
*               101.....  F814W(1) detection only in ACS-GC but not DEEP2
*               102.....  F606W(2) detection only in ACS-GC but not DEEP2
*               11......  F814W(1) and F606W(2) detection in ACS-GC and DEEP2
*               12......  F814W(1) and F606W(2) detection in ACS-GC and DEEP2
*               13......  F814W(1) and F606W(2) detection in ACS-GC and DEEP2
*               14......  F814W(1) and F606W(2) detection in ACS-GC and DEEP2
*  COSMOS       20......  F814W(1) detection
*  GOODS-N      500.....  F775W(1) and F606W(2) detection
*               501.....  F775W(1) detection only
*               502.....  F606W(2) detection only
*  GEMS+GOODS-S 900.....  F606W(1) and F850LP(2) detection
*               901.....  F850LP(1) detection only
*               902.....  F606W(2) detection only
*  ------------------------------------------------------------------------------
*Note (2): the error is 1{sigma} for EGS (Extended Groth Strip) and
*          3{sigma} for COSMOS
*Note (3): Quality of redshift as in VVDS-DEEP (III/250) or DEEP2 (III/268)
*    The last (rightmost) digit characterises the quality of the redshift:
*    -2 = Object was effectively unobserved
*    -1 = Object is identified as a star (i.e., z~0)
*     0 = No redshift could be assigned to the 1D spectrum.
*     1 = 50% confidence in the redshift.
*     2 = 75% confidence in the redshift.
*     3 = 95% confidence.
*     4 = 100% confidence.
*     9 = Single isolated emission line spectra
*    A value less than 10 indicates the quality of primary targets, i.e.
*    objects which have been targeted in the VIMOS spectral slit.
*    To this quality value, the following number may be added:
*     +10 = a primary QSO target
*     +20 = a secondary identified target, i.e. an object which is present
*           by chance in the spectral slit in addition of the primary target;
*           thus the secondary object is not ensured to be fully centered
*           within the slit.
*    +210 = secondary QSO identified target

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

C  Declarations for 'cosmos.dat'	! Subset of ACS-GC in COSMOS field

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

C  J2000 position composed of: RAdeg DEdeg
      integer*4     ObjNo_1     ! Unique object number (OBJNO) (1)
      integer*4     Survey_1    ! ?=- Unique survey ID if available (SURVEY_ID)
      real*8        RAdeg_1     ! (deg) Right Ascension (J2000) (RA)
      real*8        DEdeg_1     ! (deg) Declination (DEC)
      integer*4     Nf1_1       ! [0/23] Total number of objects simultaneously
*                                        fitted, for filter#1 (NTOT_HI)
      integer*4     Nf2_1       ! [0/15]? Total number of objects simultaneously
*                                        fitted, for filter#2 (NTOT_LOW)
      character*7   Imaging_1   ! Imaging survey: AEGIS, COSMOS, GEMS,
*                                 GOODS-N or GOODS-S (IMAGING)
      real*8        zsp_1       ! ? Spectroscopic redshift (SPECZ)
      real*4        zph_1       ! ? Photometric redshift (PHOTOZ)
      real*8        zchi2_1     ! ? Reduced {chi}^2^ for zph (PHOTOZ_CHI2)
      real*4        e_zph_1     ! ? Error on zph (PHOTOZ_ERR) (2)
      real*4        q_zsp_1     ! [-2/212]? Quality flag for zsp (ZQUALITY) (3)
      character*11  r_zsp_1     ! Origin of zsp (Z_ORIGIN)
      real*8        z_1         ! ? Best available redshift (Z)
      real*4        Bmag_1      ! ? B-band apparent magnitude (MAGB)
      real*4        e_Bmag_1    ! ? Error in Bmag (MAGB_ERR)
      real*4        Rmag1_1     ! ? R-band apparent magnitude (MAGR)
      real*4        e_Rmag1_1   ! ? Error in Rmag (MAGR_ERR)
      real*4        Imag1_1     ! ? I-band apparent magnitude (MAGI)
      real*4        e_Imag1_1   ! ? Error in Imag (MAGI_ERR)
      real*4        umag_1      ! ? u-band apparent magnitude (CFHT_U)
      real*4        e_umag_1    ! ? Error in umag (CFHT_U_ERR)
      real*4        gmag_1      ! ? g-band apparent magnitude (CFHT_G)
      real*4        e_gmag_1    ! ? Error in gmag (CFHT_G_ERR)
      real*4        rmag_1      ! ? r-band apparent magnitude (CFHT_R)
      real*4        e_rmag_1    ! ? Error in rmag (CFHT_R_ERR)
      real*4        imag_1      ! ? i-band apparent magnitude (CFHT_I)
      real*4        e_imag_1    ! ? Error in imag (CFHT_I_ERR)
      real*4        zmag_1      ! ? z-band apparent magnitude (CFHT_Z)
      real*4        e_zmag_1    ! ? Error in zmag (CFHT_Z_ERR)
      real*4        E_B_V_1     ! [0/0.5]? Extinction (color excess) (EBV)
      character*15  Class_1     ! Source classification from DEEP2 and
*                                 COMBO-17: AGN, QSO, Galaxu, Star (CLASS)
      real*4        mu1_1       ! (mag/arcsec2) ? Surface brightness in filter#1 (MU_HI)
      real*4        mu2_1       ! (mag/arcsec2) ? Surface brightness in filter#2 (MU_LOW)
      real*4        PAim1_1     ! (deg) [-90/90] SExtractor image orientation,
*                                 filter#1 (THETA_IMAGE_HI)
      real*4        PAim2_1     ! (deg) [-90/90]? SExtractor image orientation,
*                                 filter#2 (THETA_IMAGE_LOW)
      real*4        PA1_1       ! (deg) [-90/90] SExtractor position angle,
*                                 filter#1 (THETA_WORLD_HI)
      real*4        PA2_1       ! (deg) [-90/90]? SExtractor position angle,
*                                 filter#1 (THETA_WORLD_LOW)
      real*4        b_a1_1      ! [0/1] SExtractor axis ratio b/a,
*                                 filter#1 (BA_HI)
      real*4        b_a2_1      ! [0/1]? SExtractor axis ratio b/a,
*                                 filter#2 (BA_LOW)
      real*4        rKron1_1    ! [0/14] SExtractor Kron radius,
*                                 filter#1 (KRON_RADIUS_HI)
      real*4        rKron2_1    ! [0/14]? SExtractor Kron radius,
*                                 filter#2 (KRON_RADIUS_LOW)
      real*4        FWHM1_1     ! (pix) SExtractor full width at half maximum,
*                                 filter#1 (FWHM_HI
      real*4        FWHM2_1     ! (pix) ? SExtractor full width at half maximum,
*                                 filter#2 (FWHM_LOW)
      real*8        a1_1        ! (pix) SExtractor major axis, filter#1 (A_IMAGE_HI)
      real*8        a2_1        ! (pix) ? SExtractor major axis, filter#2 (A_IMAGE_LOW)
      real*8        b1_1        ! (pix) SExtractor minor axis, filter#1 (B_IMAGE_HI)
      real*8        b2_1        ! (pix) ? SExtractor minor axis, filter#2 (B_IMAGE_LOW)
      real*8        bg1_1       ! (ct) ? SExtractor sky background,
*                                 filter#1 (BACKGROUND_HI)
      real*8        bg2_1       ! (ct) ? SExtractor sky background,
*                                 filter#2 (BACKGROUND_LOW)
      real*4        Fbest1_1    ! (ct) SExtractor best flux, filt#1 (FLUX_BEST_HI)
      real*4        Fbest2_1    ! (ct) ? SExtractor best flux, filt#2 (FLUX_BEST_LOW)
      real*4        e_Fbest1_1  ! (ct) Error on Fbest1 (FLUXERR_BEST_HI)
      real*4        e_Fbest2_1  ! (ct) ? Error on Fbest2 (FLUXERR_BEST_LOW)
      real*4        mbest1_1    ! (mag) ?=0 SExtractor best magnitude,
*                                 filter#1 (MAG_BEST_HI)
      real*4        mbest2_1    ! (mag) ? SExtractor best magnitude,
*                                 filter#2 (MAG_BEST_LOW)
      real*4        e_mbest1_1  ! (mag) ? Error on mbest1 (MAGERR_BEST_HI)
      real*4        e_mbest2_1  ! (mag) ? Error on mbest2 (MAGERR_BEST_LOW)
      real*8        Re_S1_1     ! (pix) ? SExtractor effective radius,
*                                 filter#1 (FLUX_RADIUS_HI)
      real*8        Re_S2_1     ! (pix) ? SExtractor effective radius,
*                                 filter#2 (FLUX_RADIUS_LOW)
      integer*4     Area1_1     ! (pix) ? SExtractor isophotal area,
*                                 filter#1 (ISOAREA_IMAGE_HI)
      integer*4     Area2_1     ! (pix) ? SExtractor isophotal area,
*                                 filter#2 (ISOAREA_IMAGE_LOW)
      integer*4     Sf1_1       ! [0/31]? SExtractor flags,
*                                 filter#1 (SEX_FLAGS_HI)
      integer*4     Sf2_1       ! [0/31]? SExtractor flags,
*                                 filter#2 (SEX_FLAGS_LOW)
      integer*4     Gf1_1       ! GALFIT flag: 0=good, 1=bad (FLAG_GALFIT_HI)
      integer*4     Gf2_1       ! ? GALFIT flag: 0=good, 1=bad (FLAG_GALFIT_LOW)
      real*4        Gchi1_1     ! ? GALFIT reduced {chi}^2^ (CHI2NU_HI)
      real*4        Gchi2_1     ! ? GALFIT reduced {chi}^2^ (CHI2NU_LOW)
      real*4        s_g1_1      ! [0/1] SExtractor star(1)/galaxy(0) class
*                                 (CLASS_STAR_HI)
      real*4        s_g2_1      ! [0/1]? SExtractor star(1)/galaxy(0) class
*                                 (CLASS_STAR_LOW)
      real*8        Xpos1_1     ! (pix) GALFIT X position (X_GALFIT_HI)
      real*8        Xpos2_1     ! (pix) ? GALFIT X position (X_GALFIT_LOW)
      real*8        Ypos1_1     ! (pix) GALFIT Y position (Y_GALFIT_HI)
      real*8        Ypos2_1     ! (pix) ? GALFIT Y position (Y_GALFIT_LOW)
      real*4        mGal1_1     ! (mag) ?=0 GALFIT magnitude, filter#1 (MAG_GALFIT_HI)
      real*4        mGal2_1     ! (mag) ? GALFIT magnitude, filter#2 (MAG_GALFIT_LOW)
      real*4        Re_G1_1     ! (pix) GALFIT effective radius (RE_GALFIT_HI)
      real*4        Re_G2_1     ! (pix) ? GALFIT effective radius (RE_GALFIT_LOW)
      real*4        n_G1_1      ! [0/8]? GALFIT Sersic index (N_GALFIT_HI)
      real*4        n_G2_1      ! [0/8]? GALFIT Sersic index (N_GALFIT_LOW)
      real*4        b_a_G1_1    ! [0/360]? GALFIT axis ratio (BA_GALFIT_HI)
      real*4        b_a_G2_1    ! [0/360]? GALFIT axis ratio (BA_GALFIT_LOW)
      real*4        pa_G1_1     ! (deg) [-90/90]? GALFIT position angle (PA_GALFIT_HI)
      real*4        pa_G2_1     ! (deg) [-90/90]? GALFIT position angle (PA_GALFIT_LOW)
      real*4        bg_G1_1     ! (ct) GALFIT background (SKY_GALFIT_HI)
      real*4        bg_G2_1     ! (ct) ? GALFIT background (SKY_GALFIT_LOW)
      real*4        e_mGal1_1   ! (mag) ? Error on mGal1 (MAGERR_GALFIT_HI)
      real*4        e_mGal2_1   ! (mag) ? Error on mGal2 (MAGERR_GALFIT_LOW)
      real*4        e_Re_G1_1   ! (pix) ? Error on Re.G1 (REERR_GALFIT_HI)
      real*4        e_Re_G2_1   ! (pix) ? Error on Re.G2 (REERR_GALFIT_LOW)
      real*4        e_n_G1_1    ! ? Error on n.G1 (NERR_GALFIT_HI)
      real*4        e_n_G2_1    ! ? Error on n.G2 (NERR_GALFIT_LOW)
      real*4        e_b_a_G1_1  ! ? Error on b/a.G1 (BAERR_GALFIT_HI)
      real*4        e_b_a_G2_1  ! ? Error on b/a.G2 (BAERR_GALFIT_LOW)
      real*4        e_pa_G1_1   ! (deg) ? Error on pa.G1 (PAERR_GALFIT_HI)
      real*4        e_pa_G2_1   ! (deg) ? Error on pa.G2 (PAERR_GALFIT_LOW)
      character*12  Morph_1     ! Visual morphology classification (VIS_MORPH)
*Note (1): Object numbers follow the convention (see Table 4):
*  ------------------------------------------------------------------------------
*  Survey       Objno     Description (filters #1 and #2)
*  ------------------------------------------------------------------------------
*  AEGIS        100.....  F814W(1) and F606W(2) detection in ACS-GC but not DEEP2
*               101.....  F814W(1) detection only in ACS-GC but not DEEP2
*               102.....  F606W(2) detection only in ACS-GC but not DEEP2
*               11......  F814W(1) and F606W(2) detection in ACS-GC and DEEP2
*               12......  F814W(1) and F606W(2) detection in ACS-GC and DEEP2
*               13......  F814W(1) and F606W(2) detection in ACS-GC and DEEP2
*               14......  F814W(1) and F606W(2) detection in ACS-GC and DEEP2
*  COSMOS       20......  F814W(1) detection
*  GOODS-N      500.....  F775W(1) and F606W(2) detection
*               501.....  F775W(1) detection only
*               502.....  F606W(2) detection only
*  GEMS+GOODS-S 900.....  F606W(1) and F850LP(2) detection
*               901.....  F850LP(1) detection only
*               902.....  F606W(2) detection only
*  ------------------------------------------------------------------------------
*Note (2): the error is 1{sigma} for EGS (Extended Groth Strip) and
*          3{sigma} for COSMOS
*Note (3): Quality of redshift as in VVDS-DEEP (III/250) or DEEP2 (III/268)
*    The last (rightmost) digit characterises the quality of the redshift:
*    -2 = Object was effectively unobserved
*    -1 = Object is identified as a star (i.e., z~0)
*     0 = No redshift could be assigned to the 1D spectrum.
*     1 = 50% confidence in the redshift.
*     2 = 75% confidence in the redshift.
*     3 = 95% confidence.
*     4 = 100% confidence.
*     9 = Single isolated emission line spectra
*    A value less than 10 indicates the quality of primary targets, i.e.
*    objects which have been targeted in the VIMOS spectral slit.
*    To this quality value, the following number may be added:
*     +10 = a primary QSO target
*     +20 = a secondary identified target, i.e. an object which is present
*           by chance in the spectral slit in addition of the primary target;
*           thus the secondary object is not ensured to be fully centered
*           within the slit.
*    +210 = secondary QSO identified target

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

C  Declarations for 'egs.dat'	! Subset of ACS-GC in Extended Groth Strip (EGS)

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

C  J2000 position composed of: RAdeg DEdeg
      integer*4     ObjNo_2     ! Unique object number (OBJNO) (1)
      integer*4     Survey_2    ! ?=- Unique survey ID if available (SURVEY_ID)
      real*8        RAdeg_2     ! (deg) Right Ascension (J2000) (RA)
      real*8        DEdeg_2     ! (deg) Declination (DEC)
      integer*4     Nf1_2       ! [0/23] Total number of objects simultaneously
*                                        fitted, for filter#1 (NTOT_HI)
      integer*4     Nf2_2       ! [0/15]? Total number of objects simultaneously
*                                        fitted, for filter#2 (NTOT_LOW)
      character*7   Imaging_2   ! Imaging survey: AEGIS, COSMOS, GEMS,
*                                 GOODS-N or GOODS-S (IMAGING)
      real*8        zsp_2       ! ? Spectroscopic redshift (SPECZ)
      real*4        zph_2       ! ? Photometric redshift (PHOTOZ)
      real*8        zchi2_2     ! ? Reduced {chi}^2^ for zph (PHOTOZ_CHI2)
      real*4        e_zph_2     ! ? Error on zph (PHOTOZ_ERR) (2)
      real*4        q_zsp_2     ! [-2/212]? Quality flag for zsp (ZQUALITY) (3)
      character*11  r_zsp_2     ! Origin of zsp (Z_ORIGIN)
      real*8        z_2         ! ? Best available redshift (Z)
      real*4        Bmag_2      ! ? B-band apparent magnitude (MAGB)
      real*4        e_Bmag_2    ! ? Error in Bmag (MAGB_ERR)
      real*4        Rmag1_2     ! ? R-band apparent magnitude (MAGR)
      real*4        e_Rmag1_2   ! ? Error in Rmag (MAGR_ERR)
      real*4        Imag1_2     ! ? I-band apparent magnitude (MAGI)
      real*4        e_Imag1_2   ! ? Error in Imag (MAGI_ERR)
      real*4        umag_2      ! ? u-band apparent magnitude (CFHT_U)
      real*4        e_umag_2    ! ? Error in umag (CFHT_U_ERR)
      real*4        gmag_2      ! ? g-band apparent magnitude (CFHT_G)
      real*4        e_gmag_2    ! ? Error in gmag (CFHT_G_ERR)
      real*4        rmag_2      ! ? r-band apparent magnitude (CFHT_R)
      real*4        e_rmag_2    ! ? Error in rmag (CFHT_R_ERR)
      real*4        imag_2      ! ? i-band apparent magnitude (CFHT_I)
      real*4        e_imag_2    ! ? Error in imag (CFHT_I_ERR)
      real*4        zmag_2      ! ? z-band apparent magnitude (CFHT_Z)
      real*4        e_zmag_2    ! ? Error in zmag (CFHT_Z_ERR)
      real*4        E_B_V_1     ! [0/0.5]? Extinction (color excess) (EBV)
      character*15  Class_2     ! Source classification from DEEP2 and
*                                 COMBO-17: AGN, QSO, Galaxu, Star (CLASS)
      real*4        mu1_2       ! (mag/arcsec2) ? Surface brightness in filter#1 (MU_HI)
      real*4        mu2_2       ! (mag/arcsec2) ? Surface brightness in filter#2 (MU_LOW)
      real*4        PAim1_2     ! (deg) [-90/90] SExtractor image orientation,
*                                 filter#1 (THETA_IMAGE_HI)
      real*4        PAim2_2     ! (deg) [-90/90]? SExtractor image orientation,
*                                 filter#2 (THETA_IMAGE_LOW)
      real*4        PA1_2       ! (deg) [-90/90] SExtractor position angle,
*                                 filter#1 (THETA_WORLD_HI)
      real*4        PA2_2       ! (deg) [-90/90]? SExtractor position angle,
*                                 filter#1 (THETA_WORLD_LOW)
      real*4        b_a1_2      ! [0/1] SExtractor axis ratio b/a,
*                                 filter#1 (BA_HI)
      real*4        b_a2_2      ! [0/1]? SExtractor axis ratio b/a,
*                                 filter#2 (BA_LOW)
      real*4        rKron1_2    ! [0/14] SExtractor Kron radius,
*                                 filter#1 (KRON_RADIUS_HI)
      real*4        rKron2_2    ! [0/14]? SExtractor Kron radius,
*                                 filter#2 (KRON_RADIUS_LOW)
      real*4        FWHM1_2     ! (pix) SExtractor full width at half maximum,
*                                 filter#1 (FWHM_HI
      real*4        FWHM2_2     ! (pix) ? SExtractor full width at half maximum,
*                                 filter#2 (FWHM_LOW)
      real*8        a1_2        ! (pix) SExtractor major axis, filter#1 (A_IMAGE_HI)
      real*8        a2_2        ! (pix) ? SExtractor major axis, filter#2 (A_IMAGE_LOW)
      real*8        b1_2        ! (pix) SExtractor minor axis, filter#1 (B_IMAGE_HI)
      real*8        b2_2        ! (pix) ? SExtractor minor axis, filter#2 (B_IMAGE_LOW)
      real*8        bg1_2       ! (ct) ? SExtractor sky background,
*                                 filter#1 (BACKGROUND_HI)
      real*8        bg2_2       ! (ct) ? SExtractor sky background,
*                                 filter#2 (BACKGROUND_LOW)
      real*4        Fbest1_2    ! (ct) SExtractor best flux, filt#1 (FLUX_BEST_HI)
      real*4        Fbest2_2    ! (ct) ? SExtractor best flux, filt#2 (FLUX_BEST_LOW)
      real*4        e_Fbest1_2  ! (ct) Error on Fbest1 (FLUXERR_BEST_HI)
      real*4        e_Fbest2_2  ! (ct) ? Error on Fbest2 (FLUXERR_BEST_LOW)
      real*4        mbest1_2    ! (mag) ?=0 SExtractor best magnitude,
*                                 filter#1 (MAG_BEST_HI)
      real*4        mbest2_2    ! (mag) ? SExtractor best magnitude,
*                                 filter#2 (MAG_BEST_LOW)
      real*4        e_mbest1_2  ! (mag) ? Error on mbest1 (MAGERR_BEST_HI)
      real*4        e_mbest2_2  ! (mag) ? Error on mbest2 (MAGERR_BEST_LOW)
      real*8        Re_S1_2     ! (pix) ? SExtractor effective radius,
*                                 filter#1 (FLUX_RADIUS_HI)
      real*8        Re_S2_2     ! (pix) ? SExtractor effective radius,
*                                 filter#2 (FLUX_RADIUS_LOW)
      integer*4     Area1_2     ! (pix) ? SExtractor isophotal area,
*                                 filter#1 (ISOAREA_IMAGE_HI)
      integer*4     Area2_2     ! (pix) ? SExtractor isophotal area,
*                                 filter#2 (ISOAREA_IMAGE_LOW)
      integer*4     Sf1_2       ! [0/31]? SExtractor flags,
*                                 filter#1 (SEX_FLAGS_HI)
      integer*4     Sf2_2       ! [0/31]? SExtractor flags,
*                                 filter#2 (SEX_FLAGS_LOW)
      integer*4     Gf1_2       ! GALFIT flag: 0=good, 1=bad (FLAG_GALFIT_HI)
      integer*4     Gf2_2       ! ? GALFIT flag: 0=good, 1=bad (FLAG_GALFIT_LOW)
      real*4        Gchi1_2     ! ? GALFIT reduced {chi}^2^ (CHI2NU_HI)
      real*4        Gchi2_2     ! ? GALFIT reduced {chi}^2^ (CHI2NU_LOW)
      real*4        s_g1_2      ! [0/1] SExtractor star(1)/galaxy(0) class
*                                 (CLASS_STAR_HI)
      real*4        s_g2_2      ! [0/1]? SExtractor star(1)/galaxy(0) class
*                                 (CLASS_STAR_LOW)
      real*8        Xpos1_2     ! (pix) GALFIT X position (X_GALFIT_HI)
      real*8        Xpos2_2     ! (pix) ? GALFIT X position (X_GALFIT_LOW)
      real*8        Ypos1_2     ! (pix) GALFIT Y position (Y_GALFIT_HI)
      real*8        Ypos2_2     ! (pix) ? GALFIT Y position (Y_GALFIT_LOW)
      real*4        mGal1_2     ! (mag) ?=0 GALFIT magnitude, filter#1 (MAG_GALFIT_HI)
      real*4        mGal2_2     ! (mag) ? GALFIT magnitude, filter#2 (MAG_GALFIT_LOW)
      real*4        Re_G1_2     ! (pix) GALFIT effective radius (RE_GALFIT_HI)
      real*4        Re_G2_2     ! (pix) ? GALFIT effective radius (RE_GALFIT_LOW)
      real*4        n_G1_2      ! [0/8]? GALFIT Sersic index (N_GALFIT_HI)
      real*4        n_G2_2      ! [0/8]? GALFIT Sersic index (N_GALFIT_LOW)
      real*4        b_a_G1_2    ! [0/360]? GALFIT axis ratio (BA_GALFIT_HI)
      real*4        b_a_G2_2    ! [0/360]? GALFIT axis ratio (BA_GALFIT_LOW)
      real*4        pa_G1_2     ! (deg) [-90/90]? GALFIT position angle (PA_GALFIT_HI)
      real*4        pa_G2_2     ! (deg) [-90/90]? GALFIT position angle (PA_GALFIT_LOW)
      real*4        bg_G1_2     ! (ct) GALFIT background (SKY_GALFIT_HI)
      real*4        bg_G2_2     ! (ct) ? GALFIT background (SKY_GALFIT_LOW)
      real*4        e_mGal1_2   ! (mag) ? Error on mGal1 (MAGERR_GALFIT_HI)
      real*4        e_mGal2_2   ! (mag) ? Error on mGal2 (MAGERR_GALFIT_LOW)
      real*4        e_Re_G1_2   ! (pix) ? Error on Re.G1 (REERR_GALFIT_HI)
      real*4        e_Re_G2_2   ! (pix) ? Error on Re.G2 (REERR_GALFIT_LOW)
      real*4        e_n_G1_2    ! ? Error on n.G1 (NERR_GALFIT_HI)
      real*4        e_n_G2_2    ! ? Error on n.G2 (NERR_GALFIT_LOW)
      real*4        e_b_a_G1_2  ! ? Error on b/a.G1 (BAERR_GALFIT_HI)
      real*4        e_b_a_G2_2  ! ? Error on b/a.G2 (BAERR_GALFIT_LOW)
      real*4        e_pa_G1_2   ! (deg) ? Error on pa.G1 (PAERR_GALFIT_HI)
      real*4        e_pa_G2_2   ! (deg) ? Error on pa.G2 (PAERR_GALFIT_LOW)
      character*12  Morph_2     ! Visual morphology classification (VIS_MORPH)
*Note (1): Object numbers follow the convention (see Table 4):
*  ------------------------------------------------------------------------------
*  Survey       Objno     Description (filters #1 and #2)
*  ------------------------------------------------------------------------------
*  AEGIS        100.....  F814W(1) and F606W(2) detection in ACS-GC but not DEEP2
*               101.....  F814W(1) detection only in ACS-GC but not DEEP2
*               102.....  F606W(2) detection only in ACS-GC but not DEEP2
*               11......  F814W(1) and F606W(2) detection in ACS-GC and DEEP2
*               12......  F814W(1) and F606W(2) detection in ACS-GC and DEEP2
*               13......  F814W(1) and F606W(2) detection in ACS-GC and DEEP2
*               14......  F814W(1) and F606W(2) detection in ACS-GC and DEEP2
*  COSMOS       20......  F814W(1) detection
*  GOODS-N      500.....  F775W(1) and F606W(2) detection
*               501.....  F775W(1) detection only
*               502.....  F606W(2) detection only
*  GEMS+GOODS-S 900.....  F606W(1) and F850LP(2) detection
*               901.....  F850LP(1) detection only
*               902.....  F606W(2) detection only
*  ------------------------------------------------------------------------------
*Note (2): the error is 1{sigma} for EGS (Extended Groth Strip) and
*          3{sigma} for COSMOS
*Note (3): Quality of redshift as in VVDS-DEEP (III/250) or DEEP2 (III/268)
*    The last (rightmost) digit characterises the quality of the redshift:
*    -2 = Object was effectively unobserved
*    -1 = Object is identified as a star (i.e., z~0)
*     0 = No redshift could be assigned to the 1D spectrum.
*     1 = 50% confidence in the redshift.
*     2 = 75% confidence in the redshift.
*     3 = 95% confidence.
*     4 = 100% confidence.
*     9 = Single isolated emission line spectra
*    A value less than 10 indicates the quality of primary targets, i.e.
*    objects which have been targeted in the VIMOS spectral slit.
*    To this quality value, the following number may be added:
*     +10 = a primary QSO target
*     +20 = a secondary identified target, i.e. an object which is present
*           by chance in the spectral slit in addition of the primary target;
*           thus the secondary object is not ensured to be fully centered
*           within the slit.
*    +210 = secondary QSO identified target

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

C  Declarations for 'gems.dat'	! Subset of ACS-GC in EGS field

      integer*4 nr__3
      parameter (nr__3=70446)	! Number of records
      character*711 ar__3  	! Full-size record

C  J2000 position composed of: RAdeg DEdeg
      integer*4     ObjNo_3     ! Unique object number (OBJNO) (1)
      integer*4     Survey_3    ! ?=- Unique survey ID if available (SURVEY_ID)
      real*8        RAdeg_3     ! (deg) Right Ascension (J2000) (RA)
      real*8        DEdeg_3     ! (deg) Declination (DEC)
      integer*4     Nf1_3       ! [0/23] Total number of objects simultaneously
*                                        fitted, for filter#1 (NTOT_HI)
      integer*4     Nf2_3       ! [0/15]? Total number of objects simultaneously
*                                        fitted, for filter#2 (NTOT_LOW)
      character*7   Imaging_3   ! Imaging survey: AEGIS, COSMOS, GEMS,
*                                 GOODS-N or GOODS-S (IMAGING)
      real*8        zsp_3       ! ? Spectroscopic redshift (SPECZ)
      real*4        zph_3       ! ? Photometric redshift (PHOTOZ)
      real*8        zchi2_3     ! ? Reduced {chi}^2^ for zph (PHOTOZ_CHI2)
      real*4        e_zph_3     ! ? Error on zph (PHOTOZ_ERR) (2)
      real*4        q_zsp_3     ! [-2/212]? Quality flag for zsp (ZQUALITY) (3)
      character*11  r_zsp_3     ! Origin of zsp (Z_ORIGIN)
      real*8        z_3         ! ? Best available redshift (Z)
      real*4        Bmag_3      ! ? B-band apparent magnitude (MAGB)
      real*4        e_Bmag_3    ! ? Error in Bmag (MAGB_ERR)
      real*4        Rmag1_3     ! ? R-band apparent magnitude (MAGR)
      real*4        e_Rmag1_3   ! ? Error in Rmag (MAGR_ERR)
      real*4        Imag1_3     ! ? I-band apparent magnitude (MAGI)
      real*4        e_Imag1_3   ! ? Error in Imag (MAGI_ERR)
      real*4        umag_3      ! ? u-band apparent magnitude (CFHT_U)
      real*4        e_umag_3    ! ? Error in umag (CFHT_U_ERR)
      real*4        gmag_3      ! ? g-band apparent magnitude (CFHT_G)
      real*4        e_gmag_3    ! ? Error in gmag (CFHT_G_ERR)
      real*4        rmag_3      ! ? r-band apparent magnitude (CFHT_R)
      real*4        e_rmag_3    ! ? Error in rmag (CFHT_R_ERR)
      real*4        imag_3      ! ? i-band apparent magnitude (CFHT_I)
      real*4        e_imag_3    ! ? Error in imag (CFHT_I_ERR)
      real*4        zmag_3      ! ? z-band apparent magnitude (CFHT_Z)
      real*4        e_zmag_3    ! ? Error in zmag (CFHT_Z_ERR)
      real*4        E_B_V_1     ! [0/0.5]? Extinction (color excess) (EBV)
      character*15  Class_3     ! Source classification from DEEP2 and
*                                 COMBO-17: AGN, QSO, Galaxu, Star (CLASS)
      real*4        mu1_3       ! (mag/arcsec2) ? Surface brightness in filter#1 (MU_HI)
      real*4        mu2_3       ! (mag/arcsec2) ? Surface brightness in filter#2 (MU_LOW)
      real*4        PAim1_3     ! (deg) [-90/90] SExtractor image orientation,
*                                 filter#1 (THETA_IMAGE_HI)
      real*4        PAim2_3     ! (deg) [-90/90]? SExtractor image orientation,
*                                 filter#2 (THETA_IMAGE_LOW)
      real*4        PA1_3       ! (deg) [-90/90] SExtractor position angle,
*                                 filter#1 (THETA_WORLD_HI)
      real*4        PA2_3       ! (deg) [-90/90]? SExtractor position angle,
*                                 filter#1 (THETA_WORLD_LOW)
      real*4        b_a1_3      ! [0/1] SExtractor axis ratio b/a,
*                                 filter#1 (BA_HI)
      real*4        b_a2_3      ! [0/1]? SExtractor axis ratio b/a,
*                                 filter#2 (BA_LOW)
      real*4        rKron1_3    ! [0/14] SExtractor Kron radius,
*                                 filter#1 (KRON_RADIUS_HI)
      real*4        rKron2_3    ! [0/14]? SExtractor Kron radius,
*                                 filter#2 (KRON_RADIUS_LOW)
      real*4        FWHM1_3     ! (pix) SExtractor full width at half maximum,
*                                 filter#1 (FWHM_HI
      real*4        FWHM2_3     ! (pix) ? SExtractor full width at half maximum,
*                                 filter#2 (FWHM_LOW)
      real*8        a1_3        ! (pix) SExtractor major axis, filter#1 (A_IMAGE_HI)
      real*8        a2_3        ! (pix) ? SExtractor major axis, filter#2 (A_IMAGE_LOW)
      real*8        b1_3        ! (pix) SExtractor minor axis, filter#1 (B_IMAGE_HI)
      real*8        b2_3        ! (pix) ? SExtractor minor axis, filter#2 (B_IMAGE_LOW)
      real*8        bg1_3       ! (ct) ? SExtractor sky background,
*                                 filter#1 (BACKGROUND_HI)
      real*8        bg2_3       ! (ct) ? SExtractor sky background,
*                                 filter#2 (BACKGROUND_LOW)
      real*4        Fbest1_3    ! (ct) SExtractor best flux, filt#1 (FLUX_BEST_HI)
      real*4        Fbest2_3    ! (ct) ? SExtractor best flux, filt#2 (FLUX_BEST_LOW)
      real*4        e_Fbest1_3  ! (ct) Error on Fbest1 (FLUXERR_BEST_HI)
      real*4        e_Fbest2_3  ! (ct) ? Error on Fbest2 (FLUXERR_BEST_LOW)
      real*4        mbest1_3    ! (mag) ?=0 SExtractor best magnitude,
*                                 filter#1 (MAG_BEST_HI)
      real*4        mbest2_3    ! (mag) ? SExtractor best magnitude,
*                                 filter#2 (MAG_BEST_LOW)
      real*4        e_mbest1_3  ! (mag) ? Error on mbest1 (MAGERR_BEST_HI)
      real*4        e_mbest2_3  ! (mag) ? Error on mbest2 (MAGERR_BEST_LOW)
      real*8        Re_S1_3     ! (pix) ? SExtractor effective radius,
*                                 filter#1 (FLUX_RADIUS_HI)
      real*8        Re_S2_3     ! (pix) ? SExtractor effective radius,
*                                 filter#2 (FLUX_RADIUS_LOW)
      integer*4     Area1_3     ! (pix) ? SExtractor isophotal area,
*                                 filter#1 (ISOAREA_IMAGE_HI)
      integer*4     Area2_3     ! (pix) ? SExtractor isophotal area,
*                                 filter#2 (ISOAREA_IMAGE_LOW)
      integer*4     Sf1_3       ! [0/31]? SExtractor flags,
*                                 filter#1 (SEX_FLAGS_HI)
      integer*4     Sf2_3       ! [0/31]? SExtractor flags,
*                                 filter#2 (SEX_FLAGS_LOW)
      integer*4     Gf1_3       ! GALFIT flag: 0=good, 1=bad (FLAG_GALFIT_HI)
      integer*4     Gf2_3       ! ? GALFIT flag: 0=good, 1=bad (FLAG_GALFIT_LOW)
      real*4        Gchi1_3     ! ? GALFIT reduced {chi}^2^ (CHI2NU_HI)
      real*4        Gchi2_3     ! ? GALFIT reduced {chi}^2^ (CHI2NU_LOW)
      real*4        s_g1_3      ! [0/1] SExtractor star(1)/galaxy(0) class
*                                 (CLASS_STAR_HI)
      real*4        s_g2_3      ! [0/1]? SExtractor star(1)/galaxy(0) class
*                                 (CLASS_STAR_LOW)
      real*8        Xpos1_3     ! (pix) GALFIT X position (X_GALFIT_HI)
      real*8        Xpos2_3     ! (pix) ? GALFIT X position (X_GALFIT_LOW)
      real*8        Ypos1_3     ! (pix) GALFIT Y position (Y_GALFIT_HI)
      real*8        Ypos2_3     ! (pix) ? GALFIT Y position (Y_GALFIT_LOW)
      real*4        mGal1_3     ! (mag) ?=0 GALFIT magnitude, filter#1 (MAG_GALFIT_HI)
      real*4        mGal2_3     ! (mag) ? GALFIT magnitude, filter#2 (MAG_GALFIT_LOW)
      real*4        Re_G1_3     ! (pix) GALFIT effective radius (RE_GALFIT_HI)
      real*4        Re_G2_3     ! (pix) ? GALFIT effective radius (RE_GALFIT_LOW)
      real*4        n_G1_3      ! [0/8]? GALFIT Sersic index (N_GALFIT_HI)
      real*4        n_G2_3      ! [0/8]? GALFIT Sersic index (N_GALFIT_LOW)
      real*4        b_a_G1_3    ! [0/360]? GALFIT axis ratio (BA_GALFIT_HI)
      real*4        b_a_G2_3    ! [0/360]? GALFIT axis ratio (BA_GALFIT_LOW)
      real*4        pa_G1_3     ! (deg) [-90/90]? GALFIT position angle (PA_GALFIT_HI)
      real*4        pa_G2_3     ! (deg) [-90/90]? GALFIT position angle (PA_GALFIT_LOW)
      real*4        bg_G1_3     ! (ct) GALFIT background (SKY_GALFIT_HI)
      real*4        bg_G2_3     ! (ct) ? GALFIT background (SKY_GALFIT_LOW)
      real*4        e_mGal1_3   ! (mag) ? Error on mGal1 (MAGERR_GALFIT_HI)
      real*4        e_mGal2_3   ! (mag) ? Error on mGal2 (MAGERR_GALFIT_LOW)
      real*4        e_Re_G1_3   ! (pix) ? Error on Re.G1 (REERR_GALFIT_HI)
      real*4        e_Re_G2_3   ! (pix) ? Error on Re.G2 (REERR_GALFIT_LOW)
      real*4        e_n_G1_3    ! ? Error on n.G1 (NERR_GALFIT_HI)
      real*4        e_n_G2_3    ! ? Error on n.G2 (NERR_GALFIT_LOW)
      real*4        e_b_a_G1_3  ! ? Error on b/a.G1 (BAERR_GALFIT_HI)
      real*4        e_b_a_G2_3  ! ? Error on b/a.G2 (BAERR_GALFIT_LOW)
      real*4        e_pa_G1_3   ! (deg) ? Error on pa.G1 (PAERR_GALFIT_HI)
      real*4        e_pa_G2_3   ! (deg) ? Error on pa.G2 (PAERR_GALFIT_LOW)
      character*12  Morph_3     ! Visual morphology classification (VIS_MORPH)
*Note (1): Object numbers follow the convention (see Table 4):
*  ------------------------------------------------------------------------------
*  Survey       Objno     Description (filters #1 and #2)
*  ------------------------------------------------------------------------------
*  AEGIS        100.....  F814W(1) and F606W(2) detection in ACS-GC but not DEEP2
*               101.....  F814W(1) detection only in ACS-GC but not DEEP2
*               102.....  F606W(2) detection only in ACS-GC but not DEEP2
*               11......  F814W(1) and F606W(2) detection in ACS-GC and DEEP2
*               12......  F814W(1) and F606W(2) detection in ACS-GC and DEEP2
*               13......  F814W(1) and F606W(2) detection in ACS-GC and DEEP2
*               14......  F814W(1) and F606W(2) detection in ACS-GC and DEEP2
*  COSMOS       20......  F814W(1) detection
*  GOODS-N      500.....  F775W(1) and F606W(2) detection
*               501.....  F775W(1) detection only
*               502.....  F606W(2) detection only
*  GEMS+GOODS-S 900.....  F606W(1) and F850LP(2) detection
*               901.....  F850LP(1) detection only
*               902.....  F606W(2) detection only
*  ------------------------------------------------------------------------------
*Note (2): the error is 1{sigma} for EGS (Extended Groth Strip) and
*          3{sigma} for COSMOS
*Note (3): Quality of redshift as in VVDS-DEEP (III/250) or DEEP2 (III/268)
*    The last (rightmost) digit characterises the quality of the redshift:
*    -2 = Object was effectively unobserved
*    -1 = Object is identified as a star (i.e., z~0)
*     0 = No redshift could be assigned to the 1D spectrum.
*     1 = 50% confidence in the redshift.
*     2 = 75% confidence in the redshift.
*     3 = 95% confidence.
*     4 = 100% confidence.
*     9 = Single isolated emission line spectra
*    A value less than 10 indicates the quality of primary targets, i.e.
*    objects which have been targeted in the VIMOS spectral slit.
*    To this quality value, the following number may be added:
*     +10 = a primary QSO target
*     +20 = a secondary identified target, i.e. an object which is present
*           by chance in the spectral slit in addition of the primary target;
*           thus the secondary object is not ensured to be fully centered
*           within the slit.
*    +210 = secondary QSO identified target

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

C  Declarations for 'goods.dat'	! Subset of ACS-GC in GOODS field

      integer*4 nr__4
      parameter (nr__4=24225)	! Number of records
      character*711 ar__4  	! Full-size record

C  J2000 position composed of: RAdeg DEdeg
      integer*4     ObjNo_4     ! Unique object number (OBJNO) (1)
      integer*4     Survey_4    ! ?=- Unique survey ID if available (SURVEY_ID)
      real*8        RAdeg_4     ! (deg) Right Ascension (J2000) (RA)
      real*8        DEdeg_4     ! (deg) Declination (DEC)
      integer*4     Nf1_4       ! [0/23] Total number of objects simultaneously
*                                        fitted, for filter#1 (NTOT_HI)
      integer*4     Nf2_4       ! [0/15]? Total number of objects simultaneously
*                                        fitted, for filter#2 (NTOT_LOW)
      character*7   Imaging_4   ! Imaging survey: AEGIS, COSMOS, GEMS,
*                                 GOODS-N or GOODS-S (IMAGING)
      real*8        zsp_4       ! ? Spectroscopic redshift (SPECZ)
      real*4        zph_4       ! ? Photometric redshift (PHOTOZ)
      real*8        zchi2_4     ! ? Reduced {chi}^2^ for zph (PHOTOZ_CHI2)
      real*4        e_zph_4     ! ? Error on zph (PHOTOZ_ERR) (2)
      real*4        q_zsp_4     ! [-2/212]? Quality flag for zsp (ZQUALITY) (3)
      character*11  r_zsp_4     ! Origin of zsp (Z_ORIGIN)
      real*8        z_4         ! ? Best available redshift (Z)
      real*4        Bmag_4      ! ? B-band apparent magnitude (MAGB)
      real*4        e_Bmag_4    ! ? Error in Bmag (MAGB_ERR)
      real*4        Rmag1_4     ! ? R-band apparent magnitude (MAGR)
      real*4        e_Rmag1_4   ! ? Error in Rmag (MAGR_ERR)
      real*4        Imag1_4     ! ? I-band apparent magnitude (MAGI)
      real*4        e_Imag1_4   ! ? Error in Imag (MAGI_ERR)
      real*4        umag_4      ! ? u-band apparent magnitude (CFHT_U)
      real*4        e_umag_4    ! ? Error in umag (CFHT_U_ERR)
      real*4        gmag_4      ! ? g-band apparent magnitude (CFHT_G)
      real*4        e_gmag_4    ! ? Error in gmag (CFHT_G_ERR)
      real*4        rmag_4      ! ? r-band apparent magnitude (CFHT_R)
      real*4        e_rmag_4    ! ? Error in rmag (CFHT_R_ERR)
      real*4        imag_4      ! ? i-band apparent magnitude (CFHT_I)
      real*4        e_imag_4    ! ? Error in imag (CFHT_I_ERR)
      real*4        zmag_4      ! ? z-band apparent magnitude (CFHT_Z)
      real*4        e_zmag_4    ! ? Error in zmag (CFHT_Z_ERR)
      real*4        E_B_V_1     ! [0/0.5]? Extinction (color excess) (EBV)
      character*15  Class_4     ! Source classification from DEEP2 and
*                                 COMBO-17: AGN, QSO, Galaxu, Star (CLASS)
      real*4        mu1_4       ! (mag/arcsec2) ? Surface brightness in filter#1 (MU_HI)
      real*4        mu2_4       ! (mag/arcsec2) ? Surface brightness in filter#2 (MU_LOW)
      real*4        PAim1_4     ! (deg) [-90/90] SExtractor image orientation,
*                                 filter#1 (THETA_IMAGE_HI)
      real*4        PAim2_4     ! (deg) [-90/90]? SExtractor image orientation,
*                                 filter#2 (THETA_IMAGE_LOW)
      real*4        PA1_4       ! (deg) [-90/90] SExtractor position angle,
*                                 filter#1 (THETA_WORLD_HI)
      real*4        PA2_4       ! (deg) [-90/90]? SExtractor position angle,
*                                 filter#1 (THETA_WORLD_LOW)
      real*4        b_a1_4      ! [0/1] SExtractor axis ratio b/a,
*                                 filter#1 (BA_HI)
      real*4        b_a2_4      ! [0/1]? SExtractor axis ratio b/a,
*                                 filter#2 (BA_LOW)
      real*4        rKron1_4    ! [0/14] SExtractor Kron radius,
*                                 filter#1 (KRON_RADIUS_HI)
      real*4        rKron2_4    ! [0/14]? SExtractor Kron radius,
*                                 filter#2 (KRON_RADIUS_LOW)
      real*4        FWHM1_4     ! (pix) SExtractor full width at half maximum,
*                                 filter#1 (FWHM_HI
      real*4        FWHM2_4     ! (pix) ? SExtractor full width at half maximum,
*                                 filter#2 (FWHM_LOW)
      real*8        a1_4        ! (pix) SExtractor major axis, filter#1 (A_IMAGE_HI)
      real*8        a2_4        ! (pix) ? SExtractor major axis, filter#2 (A_IMAGE_LOW)
      real*8        b1_4        ! (pix) SExtractor minor axis, filter#1 (B_IMAGE_HI)
      real*8        b2_4        ! (pix) ? SExtractor minor axis, filter#2 (B_IMAGE_LOW)
      real*8        bg1_4       ! (ct) ? SExtractor sky background,
*                                 filter#1 (BACKGROUND_HI)
      real*8        bg2_4       ! (ct) ? SExtractor sky background,
*                                 filter#2 (BACKGROUND_LOW)
      real*4        Fbest1_4    ! (ct) SExtractor best flux, filt#1 (FLUX_BEST_HI)
      real*4        Fbest2_4    ! (ct) ? SExtractor best flux, filt#2 (FLUX_BEST_LOW)
      real*4        e_Fbest1_4  ! (ct) Error on Fbest1 (FLUXERR_BEST_HI)
      real*4        e_Fbest2_4  ! (ct) ? Error on Fbest2 (FLUXERR_BEST_LOW)
      real*4        mbest1_4    ! (mag) ?=0 SExtractor best magnitude,
*                                 filter#1 (MAG_BEST_HI)
      real*4        mbest2_4    ! (mag) ? SExtractor best magnitude,
*                                 filter#2 (MAG_BEST_LOW)
      real*4        e_mbest1_4  ! (mag) ? Error on mbest1 (MAGERR_BEST_HI)
      real*4        e_mbest2_4  ! (mag) ? Error on mbest2 (MAGERR_BEST_LOW)
      real*8        Re_S1_4     ! (pix) ? SExtractor effective radius,
*                                 filter#1 (FLUX_RADIUS_HI)
      real*8        Re_S2_4     ! (pix) ? SExtractor effective radius,
*                                 filter#2 (FLUX_RADIUS_LOW)
      integer*4     Area1_4     ! (pix) ? SExtractor isophotal area,
*                                 filter#1 (ISOAREA_IMAGE_HI)
      integer*4     Area2_4     ! (pix) ? SExtractor isophotal area,
*                                 filter#2 (ISOAREA_IMAGE_LOW)
      integer*4     Sf1_4       ! [0/31]? SExtractor flags,
*                                 filter#1 (SEX_FLAGS_HI)
      integer*4     Sf2_4       ! [0/31]? SExtractor flags,
*                                 filter#2 (SEX_FLAGS_LOW)
      integer*4     Gf1_4       ! GALFIT flag: 0=good, 1=bad (FLAG_GALFIT_HI)
      integer*4     Gf2_4       ! ? GALFIT flag: 0=good, 1=bad (FLAG_GALFIT_LOW)
      real*4        Gchi1_4     ! ? GALFIT reduced {chi}^2^ (CHI2NU_HI)
      real*4        Gchi2_4     ! ? GALFIT reduced {chi}^2^ (CHI2NU_LOW)
      real*4        s_g1_4      ! [0/1] SExtractor star(1)/galaxy(0) class
*                                 (CLASS_STAR_HI)
      real*4        s_g2_4      ! [0/1]? SExtractor star(1)/galaxy(0) class
*                                 (CLASS_STAR_LOW)
      real*8        Xpos1_4     ! (pix) GALFIT X position (X_GALFIT_HI)
      real*8        Xpos2_4     ! (pix) ? GALFIT X position (X_GALFIT_LOW)
      real*8        Ypos1_4     ! (pix) GALFIT Y position (Y_GALFIT_HI)
      real*8        Ypos2_4     ! (pix) ? GALFIT Y position (Y_GALFIT_LOW)
      real*4        mGal1_4     ! (mag) ?=0 GALFIT magnitude, filter#1 (MAG_GALFIT_HI)
      real*4        mGal2_4     ! (mag) ? GALFIT magnitude, filter#2 (MAG_GALFIT_LOW)
      real*4        Re_G1_4     ! (pix) GALFIT effective radius (RE_GALFIT_HI)
      real*4        Re_G2_4     ! (pix) ? GALFIT effective radius (RE_GALFIT_LOW)
      real*4        n_G1_4      ! [0/8]? GALFIT Sersic index (N_GALFIT_HI)
      real*4        n_G2_4      ! [0/8]? GALFIT Sersic index (N_GALFIT_LOW)
      real*4        b_a_G1_4    ! [0/360]? GALFIT axis ratio (BA_GALFIT_HI)
      real*4        b_a_G2_4    ! [0/360]? GALFIT axis ratio (BA_GALFIT_LOW)
      real*4        pa_G1_4     ! (deg) [-90/90]? GALFIT position angle (PA_GALFIT_HI)
      real*4        pa_G2_4     ! (deg) [-90/90]? GALFIT position angle (PA_GALFIT_LOW)
      real*4        bg_G1_4     ! (ct) GALFIT background (SKY_GALFIT_HI)
      real*4        bg_G2_4     ! (ct) ? GALFIT background (SKY_GALFIT_LOW)
      real*4        e_mGal1_4   ! (mag) ? Error on mGal1 (MAGERR_GALFIT_HI)
      real*4        e_mGal2_4   ! (mag) ? Error on mGal2 (MAGERR_GALFIT_LOW)
      real*4        e_Re_G1_4   ! (pix) ? Error on Re.G1 (REERR_GALFIT_HI)
      real*4        e_Re_G2_4   ! (pix) ? Error on Re.G2 (REERR_GALFIT_LOW)
      real*4        e_n_G1_4    ! ? Error on n.G1 (NERR_GALFIT_HI)
      real*4        e_n_G2_4    ! ? Error on n.G2 (NERR_GALFIT_LOW)
      real*4        e_b_a_G1_4  ! ? Error on b/a.G1 (BAERR_GALFIT_HI)
      real*4        e_b_a_G2_4  ! ? Error on b/a.G2 (BAERR_GALFIT_LOW)
      real*4        e_pa_G1_4   ! (deg) ? Error on pa.G1 (PAERR_GALFIT_HI)
      real*4        e_pa_G2_4   ! (deg) ? Error on pa.G2 (PAERR_GALFIT_LOW)
      character*12  Morph_4     ! Visual morphology classification (VIS_MORPH)
*Note (1): Object numbers follow the convention (see Table 4):
*  ------------------------------------------------------------------------------
*  Survey       Objno     Description (filters #1 and #2)
*  ------------------------------------------------------------------------------
*  AEGIS        100.....  F814W(1) and F606W(2) detection in ACS-GC but not DEEP2
*               101.....  F814W(1) detection only in ACS-GC but not DEEP2
*               102.....  F606W(2) detection only in ACS-GC but not DEEP2
*               11......  F814W(1) and F606W(2) detection in ACS-GC and DEEP2
*               12......  F814W(1) and F606W(2) detection in ACS-GC and DEEP2
*               13......  F814W(1) and F606W(2) detection in ACS-GC and DEEP2
*               14......  F814W(1) and F606W(2) detection in ACS-GC and DEEP2
*  COSMOS       20......  F814W(1) detection
*  GOODS-N      500.....  F775W(1) and F606W(2) detection
*               501.....  F775W(1) detection only
*               502.....  F606W(2) detection only
*  GEMS+GOODS-S 900.....  F606W(1) and F850LP(2) detection
*               901.....  F850LP(1) detection only
*               902.....  F606W(2) detection only
*  ------------------------------------------------------------------------------
*Note (2): the error is 1{sigma} for EGS (Extended Groth Strip) and
*          3{sigma} for COSMOS
*Note (3): Quality of redshift as in VVDS-DEEP (III/250) or DEEP2 (III/268)
*    The last (rightmost) digit characterises the quality of the redshift:
*    -2 = Object was effectively unobserved
*    -1 = Object is identified as a star (i.e., z~0)
*     0 = No redshift could be assigned to the 1D spectrum.
*     1 = 50% confidence in the redshift.
*     2 = 75% confidence in the redshift.
*     3 = 95% confidence.
*     4 = 100% confidence.
*     9 = Single isolated emission line spectra
*    A value less than 10 indicates the quality of primary targets, i.e.
*    objects which have been targeted in the VIMOS spectral slit.
*    To this quality value, the following number may be added:
*     +10 = a primary QSO target
*     +20 = a secondary identified target, i.e. an object which is present
*           by chance in the spectral slit in addition of the primary target;
*           thus the secondary object is not ensured to be fully centered
*           within the slit.
*    +210 = secondary QSO identified target

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

C  Declarations for 'refs.dat'	! Redshift references (table2, completed at CDS)

      integer*4 nr__5
      parameter (nr__5=36)	! Number of records
      character*74 ar__5  	! Full-size record

      character*14  Ref         ! Origin of spectroscopic redshift (zORIGIN)
      character*18  Auth        ! First author's name
      character*19  BibCode     ! Bibcode
      character*20  Note        ! Note

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

C  Loading file 'acs-gc.dat'	! The ACS-GC catalog (V1.0)

C  Format for file interpretation

    1 format(
     +  I8,1X,I8,1X,F10.6,1X,F10.6,1X,I2,1X,I2,1X,A7,1X,F9.6,1X,F6.3,
     +  1X,F7.1,1X,F6.3,1X,F5.1,1X,A11,1X,F9.6,1X,F6.3,1X,F6.3,1X,
     +  F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,
     +  1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,
     +  A15,1X,F6.3,1X,F6.3,1X,F5.1,1X,F5.1,1X,F5.1,1X,F5.1,1X,F5.3,
     +  1X,F5.3,1X,F5.2,1X,F5.2,1X,F6.2,1X,F6.2,1X,F7.3,1X,F7.3,1X,
     +  F7.3,1X,F7.3,1X,F7.3,1X,F7.3,1X,E10.4,1X,E10.4,1X,E9.3,1X,
     +  E9.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F8.3,1X,F8.3,1X,I7,1X,
     +  I7,1X,I2,1X,I2,1X,I1,1X,I1,1X,E12.5,1X,E12.5,1X,F4.2,1X,F4.2,
     +  1X,F8.2,1X,F8.2,1X,F8.2,1X,F8.2,1X,F5.2,1X,F5.2,1X,F6.2,1X,
     +  F6.2,1X,F4.2,1X,F4.2,1X,F6.2,1X,F6.2,1X,F6.2,1X,F6.2,1X,F6.2,
     +  1X,F6.2,1X,F5.2,1X,F5.2,1X,F6.2,1X,F6.2,1X,F4.2,1X,F4.2,1X,
     +  F5.2,1X,F5.2,1X,F6.2,1X,F6.2,1X,A12)

C  Effective file loading

      open(unit=1,status='old',file=
     +'acs-gc.dat')
      write(6,*) '....Loading file: acs-gc.dat'
      do i__=1,469501
        read(1,'(A711)')ar__
        read(ar__,1)
     +  ObjNo,Survey,RAdeg,DEdeg,Nf1,Nf2,Imaging,zsp,zph,zchi2,e_zph,
     +  q_zsp,r_zsp,z,Bmag,e_Bmag,Rmag1,e_Rmag1,Imag1,e_Imag1,umag,
     +  e_umag,gmag,e_gmag,rmag,e_rmag,imag,e_imag,zmag,e_zmag,E_B_V,
     +  Class,mu1,mu2,PAim1,PAim2,PA1,PA2,b_a1,b_a2,rKron1,rKron2,
     +  FWHM1,FWHM2,a1,a2,b1,b2,bg1,bg2,Fbest1,Fbest2,e_Fbest1,
     +  e_Fbest2,mbest1,mbest2,e_mbest1,e_mbest2,Re_S1,Re_S2,Area1,
     +  Area2,Sf1,Sf2,Gf1,Gf2,Gchi1,Gchi2,s_g1,s_g2,Xpos1,Xpos2,Ypos1,
     +  Ypos2,mGal1,mGal2,Re_G1,Re_G2,n_G1,n_G2,b_a_G1,b_a_G2,pa_G1,
     +  pa_G2,bg_G1,bg_G2,e_mGal1,e_mGal2,e_Re_G1,e_Re_G2,e_n_G1,
     +  e_n_G2,e_b_a_G1,e_b_a_G2,e_pa_G1,e_pa_G2,Morph
        if (Survey .EQ. 45) Survey =  iNULL__
        if(ar__(44:45) .EQ. '') Nf2 = iNULL__
        if(ar__(55:63) .EQ. '') zsp = rNULL__
        if(ar__(65:70) .EQ. '') zph = rNULL__
        if(ar__(72:78) .EQ. '') zchi2 = rNULL__
        if(ar__(80:85) .EQ. '') e_zph = rNULL__
        if(ar__(87:91) .EQ. '') q_zsp = rNULL__
        if(ar__(105:113) .EQ. '') z = rNULL__
        if(ar__(115:120) .EQ. '') Bmag = rNULL__
        if(ar__(122:127) .EQ. '') e_Bmag = rNULL__
        if(ar__(129:134) .EQ. '') Rmag1 = rNULL__
        if(ar__(136:141) .EQ. '') e_Rmag1 = rNULL__
        if(ar__(143:148) .EQ. '') Imag1 = rNULL__
        if(ar__(150:155) .EQ. '') e_Imag1 = rNULL__
        if(ar__(157:162) .EQ. '') umag = rNULL__
        if(ar__(164:169) .EQ. '') e_umag = rNULL__
        if(ar__(171:176) .EQ. '') gmag = rNULL__
        if(ar__(178:183) .EQ. '') e_gmag = rNULL__
        if(ar__(185:190) .EQ. '') rmag = rNULL__
        if(ar__(192:197) .EQ. '') e_rmag = rNULL__
        if(ar__(199:204) .EQ. '') imag = rNULL__
        if(ar__(206:211) .EQ. '') e_imag = rNULL__
        if(ar__(213:218) .EQ. '') zmag = rNULL__
        if(ar__(220:225) .EQ. '') e_zmag = rNULL__
        if(ar__(227:232) .EQ. '') E_B_V = rNULL__
        if(ar__(250:255) .EQ. '') mu1 = rNULL__
        if(ar__(257:262) .EQ. '') mu2 = rNULL__
        if(ar__(270:274) .EQ. '') PAim2 = rNULL__
        if(ar__(282:286) .EQ. '') PA2 = rNULL__
        if(ar__(294:298) .EQ. '') b_a2 = rNULL__
        if(ar__(306:310) .EQ. '') rKron2 = rNULL__
        if(ar__(319:324) .EQ. '') FWHM2 = rNULL__
        if(ar__(334:340) .EQ. '') a2 = rNULL__
        if(ar__(350:356) .EQ. '') b2 = rNULL__
        if(ar__(358:364) .EQ. '') bg1 = rNULL__
        if(ar__(366:372) .EQ. '') bg2 = rNULL__
        if(ar__(385:394) .EQ. '') Fbest2 = rNULL__
        if(ar__(406:414) .EQ. '') e_Fbest2 = rNULL__
        if(ar__(423:428) .EQ. '') mbest2 = rNULL__
        if(ar__(430:435) .EQ. '') e_mbest1 = rNULL__
        if(ar__(437:442) .EQ. '') e_mbest2 = rNULL__
        if(ar__(444:451) .EQ. '') Re_S1 = rNULL__
        if(ar__(453:460) .EQ. '') Re_S2 = rNULL__
        if(ar__(462:468) .EQ. '') Area1 = iNULL__
        if(ar__(470:476) .EQ. '') Area2 = iNULL__
        if(ar__(478:479) .EQ. '') Sf1 = iNULL__
        if(ar__(481:482) .EQ. '') Sf2 = iNULL__
        if(ar__(486:486) .EQ. '') Gf2 = iNULL__
        if(ar__(488:499) .EQ. '') Gchi1 = rNULL__
        if(ar__(501:512) .EQ. '') Gchi2 = rNULL__
        if(ar__(519:522) .EQ. '') s_g2 = rNULL__
        if(ar__(533:540) .EQ. '') Xpos2 = rNULL__
        if(ar__(551:558) .EQ. '') Ypos2 = rNULL__
        if(ar__(566:570) .EQ. '') mGal2 = rNULL__
        if(ar__(579:584) .EQ. '') Re_G2 = rNULL__
        if(ar__(586:589) .EQ. '') n_G1 = rNULL__
        if(ar__(591:594) .EQ. '') n_G2 = rNULL__
        if(ar__(596:601) .EQ. '') b_a_G1 = rNULL__
        if(ar__(603:608) .EQ. '') b_a_G2 = rNULL__
        if(ar__(610:615) .EQ. '') pa_G1 = rNULL__
        if(ar__(617:622) .EQ. '') pa_G2 = rNULL__
        if(ar__(631:636) .EQ. '') bg_G2 = rNULL__
        if(ar__(638:642) .EQ. '') e_mGal1 = rNULL__
        if(ar__(644:648) .EQ. '') e_mGal2 = rNULL__
        if(ar__(650:655) .EQ. '') e_Re_G1 = rNULL__
        if(ar__(657:662) .EQ. '') e_Re_G2 = rNULL__
        if(ar__(664:667) .EQ. '') e_n_G1 = rNULL__
        if(ar__(669:672) .EQ. '') e_n_G2 = rNULL__
        if(ar__(674:678) .EQ. '') e_b_a_G1 = rNULL__
        if(ar__(680:684) .EQ. '') e_b_a_G2 = rNULL__
        if(ar__(686:691) .EQ. '') e_pa_G1 = rNULL__
        if(ar__(693:698) .EQ. '') e_pa_G2 = rNULL__
c    ..............Just test output...........
        write(6,1)
     +  ObjNo,Survey,RAdeg,DEdeg,Nf1,Nf2,Imaging,zsp,zph,zchi2,e_zph,
     +  q_zsp,r_zsp,z,Bmag,e_Bmag,Rmag1,e_Rmag1,Imag1,e_Imag1,umag,
     +  e_umag,gmag,e_gmag,rmag,e_rmag,imag,e_imag,zmag,e_zmag,E_B_V,
     +  Class,mu1,mu2,PAim1,PAim2,PA1,PA2,b_a1,b_a2,rKron1,rKron2,
     +  FWHM1,FWHM2,a1,a2,b1,b2,bg1,bg2,Fbest1,Fbest2,e_Fbest1,
     +  e_Fbest2,mbest1,mbest2,e_mbest1,e_mbest2,Re_S1,Re_S2,Area1,
     +  Area2,Sf1,Sf2,Gf1,Gf2,Gchi1,Gchi2,s_g1,s_g2,Xpos1,Xpos2,Ypos1,
     +  Ypos2,mGal1,mGal2,Re_G1,Re_G2,n_G1,n_G2,b_a_G1,b_a_G2,pa_G1,
     +  pa_G2,bg_G1,bg_G2,e_mGal1,e_mGal2,e_Re_G1,e_Re_G2,e_n_G1,
     +  e_n_G2,e_b_a_G1,e_b_a_G2,e_pa_G1,e_pa_G2,Morph
c    .......End.of.Just test output...........
      end do
      close(1)

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

C  Loading file 'cosmos.dat'	! Subset of ACS-GC in COSMOS field

C  Format for file interpretation

    2 format(
     +  I8,1X,I8,1X,F10.6,1X,F10.6,1X,I2,1X,I2,1X,A7,1X,F9.6,1X,F6.3,
     +  1X,F7.1,1X,F6.3,1X,F5.1,1X,A11,1X,F9.6,1X,F6.3,1X,F6.3,1X,
     +  F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,
     +  1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,
     +  A15,1X,F6.3,1X,F6.3,1X,F5.1,1X,F5.1,1X,F5.1,1X,F5.1,1X,F5.3,
     +  1X,F5.3,1X,F5.2,1X,F5.2,1X,F6.2,1X,F6.2,1X,F7.3,1X,F7.3,1X,
     +  F7.3,1X,F7.3,1X,F7.3,1X,F7.3,1X,E10.4,1X,E10.4,1X,E9.3,1X,
     +  E9.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F8.3,1X,F8.3,1X,I7,1X,
     +  I7,1X,I2,1X,I2,1X,I1,1X,I1,1X,E12.5,1X,E12.5,1X,F4.2,1X,F4.2,
     +  1X,F8.2,1X,F8.2,1X,F8.2,1X,F8.2,1X,F5.2,1X,F5.2,1X,F6.2,1X,
     +  F6.2,1X,F4.2,1X,F4.2,1X,F6.2,1X,F6.2,1X,F6.2,1X,F6.2,1X,F6.2,
     +  1X,F6.2,1X,F5.2,1X,F5.2,1X,F6.2,1X,F6.2,1X,F4.2,1X,F4.2,1X,
     +  F5.2,1X,F5.2,1X,F6.2,1X,F6.2,1X,A12)

C  Effective file loading

      open(unit=1,status='old',file=
     +'cosmos.dat')
      write(6,*) '....Loading file: cosmos.dat'
      do i__=1,304688
        read(1,'(A711)')ar__1
        read(ar__1,2)
     +  ObjNo_1,Survey_1,RAdeg_1,DEdeg_1,Nf1_1,Nf2_1,Imaging_1,zsp_1,
     +  zph_1,zchi2_1,e_zph_1,q_zsp_1,r_zsp_1,z_1,Bmag_1,e_Bmag_1,
     +  Rmag1_1,e_Rmag1_1,Imag1_1,e_Imag1_1,umag_1,e_umag_1,gmag_1,
     +  e_gmag_1,rmag_1,e_rmag_1,imag_1,e_imag_1,zmag_1,e_zmag_1,
     +  E_B_V_1,Class_1,mu1_1,mu2_1,PAim1_1,PAim2_1,PA1_1,PA2_1,
     +  b_a1_1,b_a2_1,rKron1_1,rKron2_1,FWHM1_1,FWHM2_1,a1_1,a2_1,
     +  b1_1,b2_1,bg1_1,bg2_1,Fbest1_1,Fbest2_1,e_Fbest1_1,e_Fbest2_1,
     +  mbest1_1,mbest2_1,e_mbest1_1,e_mbest2_1,Re_S1_1,Re_S2_1,
     +  Area1_1,Area2_1,Sf1_1,Sf2_1,Gf1_1,Gf2_1,Gchi1_1,Gchi2_1,
     +  s_g1_1,s_g2_1,Xpos1_1,Xpos2_1,Ypos1_1,Ypos2_1,mGal1_1,mGal2_1,
     +  Re_G1_1,Re_G2_1,n_G1_1,n_G2_1,b_a_G1_1,b_a_G2_1,pa_G1_1,
     +  pa_G2_1,bg_G1_1,bg_G2_1,e_mGal1_1,e_mGal2_1,e_Re_G1_1,
     +  e_Re_G2_1,e_n_G1_1,e_n_G2_1,e_b_a_G1_1,e_b_a_G2_1,e_pa_G1_1,
     +  e_pa_G2_1,Morph_1
        if (Survey_1 .EQ. 45) Survey_1 =  iNULL__
        if(ar__1(44:45) .EQ. '') Nf2_1 = iNULL__
        if(ar__1(55:63) .EQ. '') zsp_1 = rNULL__
        if(ar__1(65:70) .EQ. '') zph_1 = rNULL__
        if(ar__1(72:78) .EQ. '') zchi2_1 = rNULL__
        if(ar__1(80:85) .EQ. '') e_zph_1 = rNULL__
        if(ar__1(87:91) .EQ. '') q_zsp_1 = rNULL__
        if(ar__1(105:113) .EQ. '') z_1 = rNULL__
        if(ar__1(115:120) .EQ. '') Bmag_1 = rNULL__
        if(ar__1(122:127) .EQ. '') e_Bmag_1 = rNULL__
        if(ar__1(129:134) .EQ. '') Rmag1_1 = rNULL__
        if(ar__1(136:141) .EQ. '') e_Rmag1_1 = rNULL__
        if(ar__1(143:148) .EQ. '') Imag1_1 = rNULL__
        if(ar__1(150:155) .EQ. '') e_Imag1_1 = rNULL__
        if(ar__1(157:162) .EQ. '') umag_1 = rNULL__
        if(ar__1(164:169) .EQ. '') e_umag_1 = rNULL__
        if(ar__1(171:176) .EQ. '') gmag_1 = rNULL__
        if(ar__1(178:183) .EQ. '') e_gmag_1 = rNULL__
        if(ar__1(185:190) .EQ. '') rmag_1 = rNULL__
        if(ar__1(192:197) .EQ. '') e_rmag_1 = rNULL__
        if(ar__1(199:204) .EQ. '') imag_1 = rNULL__
        if(ar__1(206:211) .EQ. '') e_imag_1 = rNULL__
        if(ar__1(213:218) .EQ. '') zmag_1 = rNULL__
        if(ar__1(220:225) .EQ. '') e_zmag_1 = rNULL__
        if(ar__1(227:232) .EQ. '') E_B_V_1 = rNULL__
        if(ar__1(250:255) .EQ. '') mu1_1 = rNULL__
        if(ar__1(257:262) .EQ. '') mu2_1 = rNULL__
        if(ar__1(270:274) .EQ. '') PAim2_1 = rNULL__
        if(ar__1(282:286) .EQ. '') PA2_1 = rNULL__
        if(ar__1(294:298) .EQ. '') b_a2_1 = rNULL__
        if(ar__1(306:310) .EQ. '') rKron2_1 = rNULL__
        if(ar__1(319:324) .EQ. '') FWHM2_1 = rNULL__
        if(ar__1(334:340) .EQ. '') a2_1 = rNULL__
        if(ar__1(350:356) .EQ. '') b2_1 = rNULL__
        if(ar__1(358:364) .EQ. '') bg1_1 = rNULL__
        if(ar__1(366:372) .EQ. '') bg2_1 = rNULL__
        if(ar__1(385:394) .EQ. '') Fbest2_1 = rNULL__
        if(ar__1(406:414) .EQ. '') e_Fbest2_1 = rNULL__
        if(ar__1(423:428) .EQ. '') mbest2_1 = rNULL__
        if(ar__1(430:435) .EQ. '') e_mbest1_1 = rNULL__
        if(ar__1(437:442) .EQ. '') e_mbest2_1 = rNULL__
        if(ar__1(444:451) .EQ. '') Re_S1_1 = rNULL__
        if(ar__1(453:460) .EQ. '') Re_S2_1 = rNULL__
        if(ar__1(462:468) .EQ. '') Area1_1 = iNULL__
        if(ar__1(470:476) .EQ. '') Area2_1 = iNULL__
        if(ar__1(478:479) .EQ. '') Sf1_1 = iNULL__
        if(ar__1(481:482) .EQ. '') Sf2_1 = iNULL__
        if(ar__1(486:486) .EQ. '') Gf2_1 = iNULL__
        if(ar__1(488:499) .EQ. '') Gchi1_1 = rNULL__
        if(ar__1(501:512) .EQ. '') Gchi2_1 = rNULL__
        if(ar__1(519:522) .EQ. '') s_g2_1 = rNULL__
        if(ar__1(533:540) .EQ. '') Xpos2_1 = rNULL__
        if(ar__1(551:558) .EQ. '') Ypos2_1 = rNULL__
        if(ar__1(566:570) .EQ. '') mGal2_1 = rNULL__
        if(ar__1(579:584) .EQ. '') Re_G2_1 = rNULL__
        if(ar__1(586:589) .EQ. '') n_G1_1 = rNULL__
        if(ar__1(591:594) .EQ. '') n_G2_1 = rNULL__
        if(ar__1(596:601) .EQ. '') b_a_G1_1 = rNULL__
        if(ar__1(603:608) .EQ. '') b_a_G2_1 = rNULL__
        if(ar__1(610:615) .EQ. '') pa_G1_1 = rNULL__
        if(ar__1(617:622) .EQ. '') pa_G2_1 = rNULL__
        if(ar__1(631:636) .EQ. '') bg_G2_1 = rNULL__
        if(ar__1(638:642) .EQ. '') e_mGal1_1 = rNULL__
        if(ar__1(644:648) .EQ. '') e_mGal2_1 = rNULL__
        if(ar__1(650:655) .EQ. '') e_Re_G1_1 = rNULL__
        if(ar__1(657:662) .EQ. '') e_Re_G2_1 = rNULL__
        if(ar__1(664:667) .EQ. '') e_n_G1_1 = rNULL__
        if(ar__1(669:672) .EQ. '') e_n_G2_1 = rNULL__
        if(ar__1(674:678) .EQ. '') e_b_a_G1_1 = rNULL__
        if(ar__1(680:684) .EQ. '') e_b_a_G2_1 = rNULL__
        if(ar__1(686:691) .EQ. '') e_pa_G1_1 = rNULL__
        if(ar__1(693:698) .EQ. '') e_pa_G2_1 = rNULL__
c    ..............Just test output...........
        write(6,2)
     +  ObjNo_1,Survey_1,RAdeg_1,DEdeg_1,Nf1_1,Nf2_1,Imaging_1,zsp_1,
     +  zph_1,zchi2_1,e_zph_1,q_zsp_1,r_zsp_1,z_1,Bmag_1,e_Bmag_1,
     +  Rmag1_1,e_Rmag1_1,Imag1_1,e_Imag1_1,umag_1,e_umag_1,gmag_1,
     +  e_gmag_1,rmag_1,e_rmag_1,imag_1,e_imag_1,zmag_1,e_zmag_1,
     +  E_B_V_1,Class_1,mu1_1,mu2_1,PAim1_1,PAim2_1,PA1_1,PA2_1,
     +  b_a1_1,b_a2_1,rKron1_1,rKron2_1,FWHM1_1,FWHM2_1,a1_1,a2_1,
     +  b1_1,b2_1,bg1_1,bg2_1,Fbest1_1,Fbest2_1,e_Fbest1_1,e_Fbest2_1,
     +  mbest1_1,mbest2_1,e_mbest1_1,e_mbest2_1,Re_S1_1,Re_S2_1,
     +  Area1_1,Area2_1,Sf1_1,Sf2_1,Gf1_1,Gf2_1,Gchi1_1,Gchi2_1,
     +  s_g1_1,s_g2_1,Xpos1_1,Xpos2_1,Ypos1_1,Ypos2_1,mGal1_1,mGal2_1,
     +  Re_G1_1,Re_G2_1,n_G1_1,n_G2_1,b_a_G1_1,b_a_G2_1,pa_G1_1,
     +  pa_G2_1,bg_G1_1,bg_G2_1,e_mGal1_1,e_mGal2_1,e_Re_G1_1,
     +  e_Re_G2_1,e_n_G1_1,e_n_G2_1,e_b_a_G1_1,e_b_a_G2_1,e_pa_G1_1,
     +  e_pa_G2_1,Morph_1
c    .......End.of.Just test output...........
      end do
      close(1)

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

C  Loading file 'egs.dat'	! Subset of ACS-GC in Extended Groth Strip (EGS)

C  Format for file interpretation

    3 format(
     +  I8,1X,I8,1X,F10.6,1X,F10.6,1X,I2,1X,I2,1X,A7,1X,F9.6,1X,F6.3,
     +  1X,F7.1,1X,F6.3,1X,F5.1,1X,A11,1X,F9.6,1X,F6.3,1X,F6.3,1X,
     +  F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,
     +  1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,
     +  A15,1X,F6.3,1X,F6.3,1X,F5.1,1X,F5.1,1X,F5.1,1X,F5.1,1X,F5.3,
     +  1X,F5.3,1X,F5.2,1X,F5.2,1X,F6.2,1X,F6.2,1X,F7.3,1X,F7.3,1X,
     +  F7.3,1X,F7.3,1X,F7.3,1X,F7.3,1X,E10.4,1X,E10.4,1X,E9.3,1X,
     +  E9.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F8.3,1X,F8.3,1X,I7,1X,
     +  I7,1X,I2,1X,I2,1X,I1,1X,I1,1X,E12.5,1X,E12.5,1X,F4.2,1X,F4.2,
     +  1X,F8.2,1X,F8.2,1X,F8.2,1X,F8.2,1X,F5.2,1X,F5.2,1X,F6.2,1X,
     +  F6.2,1X,F4.2,1X,F4.2,1X,F6.2,1X,F6.2,1X,F6.2,1X,F6.2,1X,F6.2,
     +  1X,F6.2,1X,F5.2,1X,F5.2,1X,F6.2,1X,F6.2,1X,F4.2,1X,F4.2,1X,
     +  F5.2,1X,F5.2,1X,F6.2,1X,F6.2,1X,A12)

C  Effective file loading

      open(unit=1,status='old',file=
     +'egs.dat')
      write(6,*) '....Loading file: egs.dat'
      do i__=1,70142
        read(1,'(A711)')ar__2
        read(ar__2,3)
     +  ObjNo_2,Survey_2,RAdeg_2,DEdeg_2,Nf1_2,Nf2_2,Imaging_2,zsp_2,
     +  zph_2,zchi2_2,e_zph_2,q_zsp_2,r_zsp_2,z_2,Bmag_2,e_Bmag_2,
     +  Rmag1_2,e_Rmag1_2,Imag1_2,e_Imag1_2,umag_2,e_umag_2,gmag_2,
     +  e_gmag_2,rmag_2,e_rmag_2,imag_2,e_imag_2,zmag_2,e_zmag_2,
     +  E_B_V_1,Class_2,mu1_2,mu2_2,PAim1_2,PAim2_2,PA1_2,PA2_2,
     +  b_a1_2,b_a2_2,rKron1_2,rKron2_2,FWHM1_2,FWHM2_2,a1_2,a2_2,
     +  b1_2,b2_2,bg1_2,bg2_2,Fbest1_2,Fbest2_2,e_Fbest1_2,e_Fbest2_2,
     +  mbest1_2,mbest2_2,e_mbest1_2,e_mbest2_2,Re_S1_2,Re_S2_2,
     +  Area1_2,Area2_2,Sf1_2,Sf2_2,Gf1_2,Gf2_2,Gchi1_2,Gchi2_2,
     +  s_g1_2,s_g2_2,Xpos1_2,Xpos2_2,Ypos1_2,Ypos2_2,mGal1_2,mGal2_2,
     +  Re_G1_2,Re_G2_2,n_G1_2,n_G2_2,b_a_G1_2,b_a_G2_2,pa_G1_2,
     +  pa_G2_2,bg_G1_2,bg_G2_2,e_mGal1_2,e_mGal2_2,e_Re_G1_2,
     +  e_Re_G2_2,e_n_G1_2,e_n_G2_2,e_b_a_G1_2,e_b_a_G2_2,e_pa_G1_2,
     +  e_pa_G2_2,Morph_2
        if (Survey_2 .EQ. 45) Survey_2 =  iNULL__
        if(ar__2(44:45) .EQ. '') Nf2_2 = iNULL__
        if(ar__2(55:63) .EQ. '') zsp_2 = rNULL__
        if(ar__2(65:70) .EQ. '') zph_2 = rNULL__
        if(ar__2(72:78) .EQ. '') zchi2_2 = rNULL__
        if(ar__2(80:85) .EQ. '') e_zph_2 = rNULL__
        if(ar__2(87:91) .EQ. '') q_zsp_2 = rNULL__
        if(ar__2(105:113) .EQ. '') z_2 = rNULL__
        if(ar__2(115:120) .EQ. '') Bmag_2 = rNULL__
        if(ar__2(122:127) .EQ. '') e_Bmag_2 = rNULL__
        if(ar__2(129:134) .EQ. '') Rmag1_2 = rNULL__
        if(ar__2(136:141) .EQ. '') e_Rmag1_2 = rNULL__
        if(ar__2(143:148) .EQ. '') Imag1_2 = rNULL__
        if(ar__2(150:155) .EQ. '') e_Imag1_2 = rNULL__
        if(ar__2(157:162) .EQ. '') umag_2 = rNULL__
        if(ar__2(164:169) .EQ. '') e_umag_2 = rNULL__
        if(ar__2(171:176) .EQ. '') gmag_2 = rNULL__
        if(ar__2(178:183) .EQ. '') e_gmag_2 = rNULL__
        if(ar__2(185:190) .EQ. '') rmag_2 = rNULL__
        if(ar__2(192:197) .EQ. '') e_rmag_2 = rNULL__
        if(ar__2(199:204) .EQ. '') imag_2 = rNULL__
        if(ar__2(206:211) .EQ. '') e_imag_2 = rNULL__
        if(ar__2(213:218) .EQ. '') zmag_2 = rNULL__
        if(ar__2(220:225) .EQ. '') e_zmag_2 = rNULL__
        if(ar__2(227:232) .EQ. '') E_B_V_1 = rNULL__
        if(ar__2(250:255) .EQ. '') mu1_2 = rNULL__
        if(ar__2(257:262) .EQ. '') mu2_2 = rNULL__
        if(ar__2(270:274) .EQ. '') PAim2_2 = rNULL__
        if(ar__2(282:286) .EQ. '') PA2_2 = rNULL__
        if(ar__2(294:298) .EQ. '') b_a2_2 = rNULL__
        if(ar__2(306:310) .EQ. '') rKron2_2 = rNULL__
        if(ar__2(319:324) .EQ. '') FWHM2_2 = rNULL__
        if(ar__2(334:340) .EQ. '') a2_2 = rNULL__
        if(ar__2(350:356) .EQ. '') b2_2 = rNULL__
        if(ar__2(358:364) .EQ. '') bg1_2 = rNULL__
        if(ar__2(366:372) .EQ. '') bg2_2 = rNULL__
        if(ar__2(385:394) .EQ. '') Fbest2_2 = rNULL__
        if(ar__2(406:414) .EQ. '') e_Fbest2_2 = rNULL__
        if(ar__2(423:428) .EQ. '') mbest2_2 = rNULL__
        if(ar__2(430:435) .EQ. '') e_mbest1_2 = rNULL__
        if(ar__2(437:442) .EQ. '') e_mbest2_2 = rNULL__
        if(ar__2(444:451) .EQ. '') Re_S1_2 = rNULL__
        if(ar__2(453:460) .EQ. '') Re_S2_2 = rNULL__
        if(ar__2(462:468) .EQ. '') Area1_2 = iNULL__
        if(ar__2(470:476) .EQ. '') Area2_2 = iNULL__
        if(ar__2(478:479) .EQ. '') Sf1_2 = iNULL__
        if(ar__2(481:482) .EQ. '') Sf2_2 = iNULL__
        if(ar__2(486:486) .EQ. '') Gf2_2 = iNULL__
        if(ar__2(488:499) .EQ. '') Gchi1_2 = rNULL__
        if(ar__2(501:512) .EQ. '') Gchi2_2 = rNULL__
        if(ar__2(519:522) .EQ. '') s_g2_2 = rNULL__
        if(ar__2(533:540) .EQ. '') Xpos2_2 = rNULL__
        if(ar__2(551:558) .EQ. '') Ypos2_2 = rNULL__
        if(ar__2(566:570) .EQ. '') mGal2_2 = rNULL__
        if(ar__2(579:584) .EQ. '') Re_G2_2 = rNULL__
        if(ar__2(586:589) .EQ. '') n_G1_2 = rNULL__
        if(ar__2(591:594) .EQ. '') n_G2_2 = rNULL__
        if(ar__2(596:601) .EQ. '') b_a_G1_2 = rNULL__
        if(ar__2(603:608) .EQ. '') b_a_G2_2 = rNULL__
        if(ar__2(610:615) .EQ. '') pa_G1_2 = rNULL__
        if(ar__2(617:622) .EQ. '') pa_G2_2 = rNULL__
        if(ar__2(631:636) .EQ. '') bg_G2_2 = rNULL__
        if(ar__2(638:642) .EQ. '') e_mGal1_2 = rNULL__
        if(ar__2(644:648) .EQ. '') e_mGal2_2 = rNULL__
        if(ar__2(650:655) .EQ. '') e_Re_G1_2 = rNULL__
        if(ar__2(657:662) .EQ. '') e_Re_G2_2 = rNULL__
        if(ar__2(664:667) .EQ. '') e_n_G1_2 = rNULL__
        if(ar__2(669:672) .EQ. '') e_n_G2_2 = rNULL__
        if(ar__2(674:678) .EQ. '') e_b_a_G1_2 = rNULL__
        if(ar__2(680:684) .EQ. '') e_b_a_G2_2 = rNULL__
        if(ar__2(686:691) .EQ. '') e_pa_G1_2 = rNULL__
        if(ar__2(693:698) .EQ. '') e_pa_G2_2 = rNULL__
c    ..............Just test output...........
        write(6,3)
     +  ObjNo_2,Survey_2,RAdeg_2,DEdeg_2,Nf1_2,Nf2_2,Imaging_2,zsp_2,
     +  zph_2,zchi2_2,e_zph_2,q_zsp_2,r_zsp_2,z_2,Bmag_2,e_Bmag_2,
     +  Rmag1_2,e_Rmag1_2,Imag1_2,e_Imag1_2,umag_2,e_umag_2,gmag_2,
     +  e_gmag_2,rmag_2,e_rmag_2,imag_2,e_imag_2,zmag_2,e_zmag_2,
     +  E_B_V_1,Class_2,mu1_2,mu2_2,PAim1_2,PAim2_2,PA1_2,PA2_2,
     +  b_a1_2,b_a2_2,rKron1_2,rKron2_2,FWHM1_2,FWHM2_2,a1_2,a2_2,
     +  b1_2,b2_2,bg1_2,bg2_2,Fbest1_2,Fbest2_2,e_Fbest1_2,e_Fbest2_2,
     +  mbest1_2,mbest2_2,e_mbest1_2,e_mbest2_2,Re_S1_2,Re_S2_2,
     +  Area1_2,Area2_2,Sf1_2,Sf2_2,Gf1_2,Gf2_2,Gchi1_2,Gchi2_2,
     +  s_g1_2,s_g2_2,Xpos1_2,Xpos2_2,Ypos1_2,Ypos2_2,mGal1_2,mGal2_2,
     +  Re_G1_2,Re_G2_2,n_G1_2,n_G2_2,b_a_G1_2,b_a_G2_2,pa_G1_2,
     +  pa_G2_2,bg_G1_2,bg_G2_2,e_mGal1_2,e_mGal2_2,e_Re_G1_2,
     +  e_Re_G2_2,e_n_G1_2,e_n_G2_2,e_b_a_G1_2,e_b_a_G2_2,e_pa_G1_2,
     +  e_pa_G2_2,Morph_2
c    .......End.of.Just test output...........
      end do
      close(1)

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

C  Loading file 'gems.dat'	! Subset of ACS-GC in EGS field

C  Format for file interpretation

    4 format(
     +  I8,1X,I8,1X,F10.6,1X,F10.6,1X,I2,1X,I2,1X,A7,1X,F9.6,1X,F6.3,
     +  1X,F7.1,1X,F6.3,1X,F5.1,1X,A11,1X,F9.6,1X,F6.3,1X,F6.3,1X,
     +  F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,
     +  1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,
     +  A15,1X,F6.3,1X,F6.3,1X,F5.1,1X,F5.1,1X,F5.1,1X,F5.1,1X,F5.3,
     +  1X,F5.3,1X,F5.2,1X,F5.2,1X,F6.2,1X,F6.2,1X,F7.3,1X,F7.3,1X,
     +  F7.3,1X,F7.3,1X,F7.3,1X,F7.3,1X,E10.4,1X,E10.4,1X,E9.3,1X,
     +  E9.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F8.3,1X,F8.3,1X,I7,1X,
     +  I7,1X,I2,1X,I2,1X,I1,1X,I1,1X,E12.5,1X,E12.5,1X,F4.2,1X,F4.2,
     +  1X,F8.2,1X,F8.2,1X,F8.2,1X,F8.2,1X,F5.2,1X,F5.2,1X,F6.2,1X,
     +  F6.2,1X,F4.2,1X,F4.2,1X,F6.2,1X,F6.2,1X,F6.2,1X,F6.2,1X,F6.2,
     +  1X,F6.2,1X,F5.2,1X,F5.2,1X,F6.2,1X,F6.2,1X,F4.2,1X,F4.2,1X,
     +  F5.2,1X,F5.2,1X,F6.2,1X,F6.2,1X,A12)

C  Effective file loading

      open(unit=1,status='old',file=
     +'gems.dat')
      write(6,*) '....Loading file: gems.dat'
      do i__=1,70446
        read(1,'(A711)')ar__3
        read(ar__3,4)
     +  ObjNo_3,Survey_3,RAdeg_3,DEdeg_3,Nf1_3,Nf2_3,Imaging_3,zsp_3,
     +  zph_3,zchi2_3,e_zph_3,q_zsp_3,r_zsp_3,z_3,Bmag_3,e_Bmag_3,
     +  Rmag1_3,e_Rmag1_3,Imag1_3,e_Imag1_3,umag_3,e_umag_3,gmag_3,
     +  e_gmag_3,rmag_3,e_rmag_3,imag_3,e_imag_3,zmag_3,e_zmag_3,
     +  E_B_V_1,Class_3,mu1_3,mu2_3,PAim1_3,PAim2_3,PA1_3,PA2_3,
     +  b_a1_3,b_a2_3,rKron1_3,rKron2_3,FWHM1_3,FWHM2_3,a1_3,a2_3,
     +  b1_3,b2_3,bg1_3,bg2_3,Fbest1_3,Fbest2_3,e_Fbest1_3,e_Fbest2_3,
     +  mbest1_3,mbest2_3,e_mbest1_3,e_mbest2_3,Re_S1_3,Re_S2_3,
     +  Area1_3,Area2_3,Sf1_3,Sf2_3,Gf1_3,Gf2_3,Gchi1_3,Gchi2_3,
     +  s_g1_3,s_g2_3,Xpos1_3,Xpos2_3,Ypos1_3,Ypos2_3,mGal1_3,mGal2_3,
     +  Re_G1_3,Re_G2_3,n_G1_3,n_G2_3,b_a_G1_3,b_a_G2_3,pa_G1_3,
     +  pa_G2_3,bg_G1_3,bg_G2_3,e_mGal1_3,e_mGal2_3,e_Re_G1_3,
     +  e_Re_G2_3,e_n_G1_3,e_n_G2_3,e_b_a_G1_3,e_b_a_G2_3,e_pa_G1_3,
     +  e_pa_G2_3,Morph_3
        if (Survey_3 .EQ. 45) Survey_3 =  iNULL__
        if(ar__3(44:45) .EQ. '') Nf2_3 = iNULL__
        if(ar__3(55:63) .EQ. '') zsp_3 = rNULL__
        if(ar__3(65:70) .EQ. '') zph_3 = rNULL__
        if(ar__3(72:78) .EQ. '') zchi2_3 = rNULL__
        if(ar__3(80:85) .EQ. '') e_zph_3 = rNULL__
        if(ar__3(87:91) .EQ. '') q_zsp_3 = rNULL__
        if(ar__3(105:113) .EQ. '') z_3 = rNULL__
        if(ar__3(115:120) .EQ. '') Bmag_3 = rNULL__
        if(ar__3(122:127) .EQ. '') e_Bmag_3 = rNULL__
        if(ar__3(129:134) .EQ. '') Rmag1_3 = rNULL__
        if(ar__3(136:141) .EQ. '') e_Rmag1_3 = rNULL__
        if(ar__3(143:148) .EQ. '') Imag1_3 = rNULL__
        if(ar__3(150:155) .EQ. '') e_Imag1_3 = rNULL__
        if(ar__3(157:162) .EQ. '') umag_3 = rNULL__
        if(ar__3(164:169) .EQ. '') e_umag_3 = rNULL__
        if(ar__3(171:176) .EQ. '') gmag_3 = rNULL__
        if(ar__3(178:183) .EQ. '') e_gmag_3 = rNULL__
        if(ar__3(185:190) .EQ. '') rmag_3 = rNULL__
        if(ar__3(192:197) .EQ. '') e_rmag_3 = rNULL__
        if(ar__3(199:204) .EQ. '') imag_3 = rNULL__
        if(ar__3(206:211) .EQ. '') e_imag_3 = rNULL__
        if(ar__3(213:218) .EQ. '') zmag_3 = rNULL__
        if(ar__3(220:225) .EQ. '') e_zmag_3 = rNULL__
        if(ar__3(227:232) .EQ. '') E_B_V_1 = rNULL__
        if(ar__3(250:255) .EQ. '') mu1_3 = rNULL__
        if(ar__3(257:262) .EQ. '') mu2_3 = rNULL__
        if(ar__3(270:274) .EQ. '') PAim2_3 = rNULL__
        if(ar__3(282:286) .EQ. '') PA2_3 = rNULL__
        if(ar__3(294:298) .EQ. '') b_a2_3 = rNULL__
        if(ar__3(306:310) .EQ. '') rKron2_3 = rNULL__
        if(ar__3(319:324) .EQ. '') FWHM2_3 = rNULL__
        if(ar__3(334:340) .EQ. '') a2_3 = rNULL__
        if(ar__3(350:356) .EQ. '') b2_3 = rNULL__
        if(ar__3(358:364) .EQ. '') bg1_3 = rNULL__
        if(ar__3(366:372) .EQ. '') bg2_3 = rNULL__
        if(ar__3(385:394) .EQ. '') Fbest2_3 = rNULL__
        if(ar__3(406:414) .EQ. '') e_Fbest2_3 = rNULL__
        if(ar__3(423:428) .EQ. '') mbest2_3 = rNULL__
        if(ar__3(430:435) .EQ. '') e_mbest1_3 = rNULL__
        if(ar__3(437:442) .EQ. '') e_mbest2_3 = rNULL__
        if(ar__3(444:451) .EQ. '') Re_S1_3 = rNULL__
        if(ar__3(453:460) .EQ. '') Re_S2_3 = rNULL__
        if(ar__3(462:468) .EQ. '') Area1_3 = iNULL__
        if(ar__3(470:476) .EQ. '') Area2_3 = iNULL__
        if(ar__3(478:479) .EQ. '') Sf1_3 = iNULL__
        if(ar__3(481:482) .EQ. '') Sf2_3 = iNULL__
        if(ar__3(486:486) .EQ. '') Gf2_3 = iNULL__
        if(ar__3(488:499) .EQ. '') Gchi1_3 = rNULL__
        if(ar__3(501:512) .EQ. '') Gchi2_3 = rNULL__
        if(ar__3(519:522) .EQ. '') s_g2_3 = rNULL__
        if(ar__3(533:540) .EQ. '') Xpos2_3 = rNULL__
        if(ar__3(551:558) .EQ. '') Ypos2_3 = rNULL__
        if(ar__3(566:570) .EQ. '') mGal2_3 = rNULL__
        if(ar__3(579:584) .EQ. '') Re_G2_3 = rNULL__
        if(ar__3(586:589) .EQ. '') n_G1_3 = rNULL__
        if(ar__3(591:594) .EQ. '') n_G2_3 = rNULL__
        if(ar__3(596:601) .EQ. '') b_a_G1_3 = rNULL__
        if(ar__3(603:608) .EQ. '') b_a_G2_3 = rNULL__
        if(ar__3(610:615) .EQ. '') pa_G1_3 = rNULL__
        if(ar__3(617:622) .EQ. '') pa_G2_3 = rNULL__
        if(ar__3(631:636) .EQ. '') bg_G2_3 = rNULL__
        if(ar__3(638:642) .EQ. '') e_mGal1_3 = rNULL__
        if(ar__3(644:648) .EQ. '') e_mGal2_3 = rNULL__
        if(ar__3(650:655) .EQ. '') e_Re_G1_3 = rNULL__
        if(ar__3(657:662) .EQ. '') e_Re_G2_3 = rNULL__
        if(ar__3(664:667) .EQ. '') e_n_G1_3 = rNULL__
        if(ar__3(669:672) .EQ. '') e_n_G2_3 = rNULL__
        if(ar__3(674:678) .EQ. '') e_b_a_G1_3 = rNULL__
        if(ar__3(680:684) .EQ. '') e_b_a_G2_3 = rNULL__
        if(ar__3(686:691) .EQ. '') e_pa_G1_3 = rNULL__
        if(ar__3(693:698) .EQ. '') e_pa_G2_3 = rNULL__
c    ..............Just test output...........
        write(6,4)
     +  ObjNo_3,Survey_3,RAdeg_3,DEdeg_3,Nf1_3,Nf2_3,Imaging_3,zsp_3,
     +  zph_3,zchi2_3,e_zph_3,q_zsp_3,r_zsp_3,z_3,Bmag_3,e_Bmag_3,
     +  Rmag1_3,e_Rmag1_3,Imag1_3,e_Imag1_3,umag_3,e_umag_3,gmag_3,
     +  e_gmag_3,rmag_3,e_rmag_3,imag_3,e_imag_3,zmag_3,e_zmag_3,
     +  E_B_V_1,Class_3,mu1_3,mu2_3,PAim1_3,PAim2_3,PA1_3,PA2_3,
     +  b_a1_3,b_a2_3,rKron1_3,rKron2_3,FWHM1_3,FWHM2_3,a1_3,a2_3,
     +  b1_3,b2_3,bg1_3,bg2_3,Fbest1_3,Fbest2_3,e_Fbest1_3,e_Fbest2_3,
     +  mbest1_3,mbest2_3,e_mbest1_3,e_mbest2_3,Re_S1_3,Re_S2_3,
     +  Area1_3,Area2_3,Sf1_3,Sf2_3,Gf1_3,Gf2_3,Gchi1_3,Gchi2_3,
     +  s_g1_3,s_g2_3,Xpos1_3,Xpos2_3,Ypos1_3,Ypos2_3,mGal1_3,mGal2_3,
     +  Re_G1_3,Re_G2_3,n_G1_3,n_G2_3,b_a_G1_3,b_a_G2_3,pa_G1_3,
     +  pa_G2_3,bg_G1_3,bg_G2_3,e_mGal1_3,e_mGal2_3,e_Re_G1_3,
     +  e_Re_G2_3,e_n_G1_3,e_n_G2_3,e_b_a_G1_3,e_b_a_G2_3,e_pa_G1_3,
     +  e_pa_G2_3,Morph_3
c    .......End.of.Just test output...........
      end do
      close(1)

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

C  Loading file 'goods.dat'	! Subset of ACS-GC in GOODS field

C  Format for file interpretation

    5 format(
     +  I8,1X,I8,1X,F10.6,1X,F10.6,1X,I2,1X,I2,1X,A7,1X,F9.6,1X,F6.3,
     +  1X,F7.1,1X,F6.3,1X,F5.1,1X,A11,1X,F9.6,1X,F6.3,1X,F6.3,1X,
     +  F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,
     +  1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,
     +  A15,1X,F6.3,1X,F6.3,1X,F5.1,1X,F5.1,1X,F5.1,1X,F5.1,1X,F5.3,
     +  1X,F5.3,1X,F5.2,1X,F5.2,1X,F6.2,1X,F6.2,1X,F7.3,1X,F7.3,1X,
     +  F7.3,1X,F7.3,1X,F7.3,1X,F7.3,1X,E10.4,1X,E10.4,1X,E9.3,1X,
     +  E9.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F6.3,1X,F8.3,1X,F8.3,1X,I7,1X,
     +  I7,1X,I2,1X,I2,1X,I1,1X,I1,1X,E12.5,1X,E12.5,1X,F4.2,1X,F4.2,
     +  1X,F8.2,1X,F8.2,1X,F8.2,1X,F8.2,1X,F5.2,1X,F5.2,1X,F6.2,1X,
     +  F6.2,1X,F4.2,1X,F4.2,1X,F6.2,1X,F6.2,1X,F6.2,1X,F6.2,1X,F6.2,
     +  1X,F6.2,1X,F5.2,1X,F5.2,1X,F6.2,1X,F6.2,1X,F4.2,1X,F4.2,1X,
     +  F5.2,1X,F5.2,1X,F6.2,1X,F6.2,1X,A12)

C  Effective file loading

      open(unit=1,status='old',file=
     +'goods.dat')
      write(6,*) '....Loading file: goods.dat'
      do i__=1,24225
        read(1,'(A711)')ar__4
        read(ar__4,5)
     +  ObjNo_4,Survey_4,RAdeg_4,DEdeg_4,Nf1_4,Nf2_4,Imaging_4,zsp_4,
     +  zph_4,zchi2_4,e_zph_4,q_zsp_4,r_zsp_4,z_4,Bmag_4,e_Bmag_4,
     +  Rmag1_4,e_Rmag1_4,Imag1_4,e_Imag1_4,umag_4,e_umag_4,gmag_4,
     +  e_gmag_4,rmag_4,e_rmag_4,imag_4,e_imag_4,zmag_4,e_zmag_4,
     +  E_B_V_1,Class_4,mu1_4,mu2_4,PAim1_4,PAim2_4,PA1_4,PA2_4,
     +  b_a1_4,b_a2_4,rKron1_4,rKron2_4,FWHM1_4,FWHM2_4,a1_4,a2_4,
     +  b1_4,b2_4,bg1_4,bg2_4,Fbest1_4,Fbest2_4,e_Fbest1_4,e_Fbest2_4,
     +  mbest1_4,mbest2_4,e_mbest1_4,e_mbest2_4,Re_S1_4,Re_S2_4,
     +  Area1_4,Area2_4,Sf1_4,Sf2_4,Gf1_4,Gf2_4,Gchi1_4,Gchi2_4,
     +  s_g1_4,s_g2_4,Xpos1_4,Xpos2_4,Ypos1_4,Ypos2_4,mGal1_4,mGal2_4,
     +  Re_G1_4,Re_G2_4,n_G1_4,n_G2_4,b_a_G1_4,b_a_G2_4,pa_G1_4,
     +  pa_G2_4,bg_G1_4,bg_G2_4,e_mGal1_4,e_mGal2_4,e_Re_G1_4,
     +  e_Re_G2_4,e_n_G1_4,e_n_G2_4,e_b_a_G1_4,e_b_a_G2_4,e_pa_G1_4,
     +  e_pa_G2_4,Morph_4
        if (Survey_4 .EQ. 45) Survey_4 =  iNULL__
        if(ar__4(44:45) .EQ. '') Nf2_4 = iNULL__
        if(ar__4(55:63) .EQ. '') zsp_4 = rNULL__
        if(ar__4(65:70) .EQ. '') zph_4 = rNULL__
        if(ar__4(72:78) .EQ. '') zchi2_4 = rNULL__
        if(ar__4(80:85) .EQ. '') e_zph_4 = rNULL__
        if(ar__4(87:91) .EQ. '') q_zsp_4 = rNULL__
        if(ar__4(105:113) .EQ. '') z_4 = rNULL__
        if(ar__4(115:120) .EQ. '') Bmag_4 = rNULL__
        if(ar__4(122:127) .EQ. '') e_Bmag_4 = rNULL__
        if(ar__4(129:134) .EQ. '') Rmag1_4 = rNULL__
        if(ar__4(136:141) .EQ. '') e_Rmag1_4 = rNULL__
        if(ar__4(143:148) .EQ. '') Imag1_4 = rNULL__
        if(ar__4(150:155) .EQ. '') e_Imag1_4 = rNULL__
        if(ar__4(157:162) .EQ. '') umag_4 = rNULL__
        if(ar__4(164:169) .EQ. '') e_umag_4 = rNULL__
        if(ar__4(171:176) .EQ. '') gmag_4 = rNULL__
        if(ar__4(178:183) .EQ. '') e_gmag_4 = rNULL__
        if(ar__4(185:190) .EQ. '') rmag_4 = rNULL__
        if(ar__4(192:197) .EQ. '') e_rmag_4 = rNULL__
        if(ar__4(199:204) .EQ. '') imag_4 = rNULL__
        if(ar__4(206:211) .EQ. '') e_imag_4 = rNULL__
        if(ar__4(213:218) .EQ. '') zmag_4 = rNULL__
        if(ar__4(220:225) .EQ. '') e_zmag_4 = rNULL__
        if(ar__4(227:232) .EQ. '') E_B_V_1 = rNULL__
        if(ar__4(250:255) .EQ. '') mu1_4 = rNULL__
        if(ar__4(257:262) .EQ. '') mu2_4 = rNULL__
        if(ar__4(270:274) .EQ. '') PAim2_4 = rNULL__
        if(ar__4(282:286) .EQ. '') PA2_4 = rNULL__
        if(ar__4(294:298) .EQ. '') b_a2_4 = rNULL__
        if(ar__4(306:310) .EQ. '') rKron2_4 = rNULL__
        if(ar__4(319:324) .EQ. '') FWHM2_4 = rNULL__
        if(ar__4(334:340) .EQ. '') a2_4 = rNULL__
        if(ar__4(350:356) .EQ. '') b2_4 = rNULL__
        if(ar__4(358:364) .EQ. '') bg1_4 = rNULL__
        if(ar__4(366:372) .EQ. '') bg2_4 = rNULL__
        if(ar__4(385:394) .EQ. '') Fbest2_4 = rNULL__
        if(ar__4(406:414) .EQ. '') e_Fbest2_4 = rNULL__
        if(ar__4(423:428) .EQ. '') mbest2_4 = rNULL__
        if(ar__4(430:435) .EQ. '') e_mbest1_4 = rNULL__
        if(ar__4(437:442) .EQ. '') e_mbest2_4 = rNULL__
        if(ar__4(444:451) .EQ. '') Re_S1_4 = rNULL__
        if(ar__4(453:460) .EQ. '') Re_S2_4 = rNULL__
        if(ar__4(462:468) .EQ. '') Area1_4 = iNULL__
        if(ar__4(470:476) .EQ. '') Area2_4 = iNULL__
        if(ar__4(478:479) .EQ. '') Sf1_4 = iNULL__
        if(ar__4(481:482) .EQ. '') Sf2_4 = iNULL__
        if(ar__4(486:486) .EQ. '') Gf2_4 = iNULL__
        if(ar__4(488:499) .EQ. '') Gchi1_4 = rNULL__
        if(ar__4(501:512) .EQ. '') Gchi2_4 = rNULL__
        if(ar__4(519:522) .EQ. '') s_g2_4 = rNULL__
        if(ar__4(533:540) .EQ. '') Xpos2_4 = rNULL__
        if(ar__4(551:558) .EQ. '') Ypos2_4 = rNULL__
        if(ar__4(566:570) .EQ. '') mGal2_4 = rNULL__
        if(ar__4(579:584) .EQ. '') Re_G2_4 = rNULL__
        if(ar__4(586:589) .EQ. '') n_G1_4 = rNULL__
        if(ar__4(591:594) .EQ. '') n_G2_4 = rNULL__
        if(ar__4(596:601) .EQ. '') b_a_G1_4 = rNULL__
        if(ar__4(603:608) .EQ. '') b_a_G2_4 = rNULL__
        if(ar__4(610:615) .EQ. '') pa_G1_4 = rNULL__
        if(ar__4(617:622) .EQ. '') pa_G2_4 = rNULL__
        if(ar__4(631:636) .EQ. '') bg_G2_4 = rNULL__
        if(ar__4(638:642) .EQ. '') e_mGal1_4 = rNULL__
        if(ar__4(644:648) .EQ. '') e_mGal2_4 = rNULL__
        if(ar__4(650:655) .EQ. '') e_Re_G1_4 = rNULL__
        if(ar__4(657:662) .EQ. '') e_Re_G2_4 = rNULL__
        if(ar__4(664:667) .EQ. '') e_n_G1_4 = rNULL__
        if(ar__4(669:672) .EQ. '') e_n_G2_4 = rNULL__
        if(ar__4(674:678) .EQ. '') e_b_a_G1_4 = rNULL__
        if(ar__4(680:684) .EQ. '') e_b_a_G2_4 = rNULL__
        if(ar__4(686:691) .EQ. '') e_pa_G1_4 = rNULL__
        if(ar__4(693:698) .EQ. '') e_pa_G2_4 = rNULL__
c    ..............Just test output...........
        write(6,5)
     +  ObjNo_4,Survey_4,RAdeg_4,DEdeg_4,Nf1_4,Nf2_4,Imaging_4,zsp_4,
     +  zph_4,zchi2_4,e_zph_4,q_zsp_4,r_zsp_4,z_4,Bmag_4,e_Bmag_4,
     +  Rmag1_4,e_Rmag1_4,Imag1_4,e_Imag1_4,umag_4,e_umag_4,gmag_4,
     +  e_gmag_4,rmag_4,e_rmag_4,imag_4,e_imag_4,zmag_4,e_zmag_4,
     +  E_B_V_1,Class_4,mu1_4,mu2_4,PAim1_4,PAim2_4,PA1_4,PA2_4,
     +  b_a1_4,b_a2_4,rKron1_4,rKron2_4,FWHM1_4,FWHM2_4,a1_4,a2_4,
     +  b1_4,b2_4,bg1_4,bg2_4,Fbest1_4,Fbest2_4,e_Fbest1_4,e_Fbest2_4,
     +  mbest1_4,mbest2_4,e_mbest1_4,e_mbest2_4,Re_S1_4,Re_S2_4,
     +  Area1_4,Area2_4,Sf1_4,Sf2_4,Gf1_4,Gf2_4,Gchi1_4,Gchi2_4,
     +  s_g1_4,s_g2_4,Xpos1_4,Xpos2_4,Ypos1_4,Ypos2_4,mGal1_4,mGal2_4,
     +  Re_G1_4,Re_G2_4,n_G1_4,n_G2_4,b_a_G1_4,b_a_G2_4,pa_G1_4,
     +  pa_G2_4,bg_G1_4,bg_G2_4,e_mGal1_4,e_mGal2_4,e_Re_G1_4,
     +  e_Re_G2_4,e_n_G1_4,e_n_G2_4,e_b_a_G1_4,e_b_a_G2_4,e_pa_G1_4,
     +  e_pa_G2_4,Morph_4
c    .......End.of.Just test output...........
      end do
      close(1)

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

C  Loading file 'refs.dat'	! Redshift references (table2, completed at CDS)

C  Format for file interpretation

    6 format(A14,1X,A18,1X,A19,1X,A20)

C  Effective file loading

      open(unit=1,status='old',file=
     +'refs.dat')
      write(6,*) '....Loading file: refs.dat'
      do i__=1,36
        read(1,'(A74)')ar__5
        read(ar__5,6)Ref,Auth,BibCode,Note
c    ..............Just test output...........
        write(6,6)Ref,Auth,BibCode,Note
c    .......End.of.Just test output...........
      end do
      close(1)

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