! Started logfile: J0700+1709_S_2003_09_17_pus_uvs.log on Tue May 22 12:14:56 2007
obs J0700+1709_S_2003_09_17_pus_uva.fits
! Reading UV FITS file: J0700+1709_S_2003_09_17_pus_uva.fits
! AN table 1: 92 integrations on 120 of 120 possible baselines.
! AN table 2: 96 integrations on 120 of 120 possible baselines.
! AN table 3: 20 integrations on 120 of 120 possible baselines.
! AN table 4: 113 integrations on 120 of 120 possible baselines.
! AN table 5: 120 integrations on 120 of 120 possible baselines.
! AN table 6: 9 integrations on 120 of 120 possible baselines.
! Apparent sampling: 0.101537 visibilities/baseline/integration-bin.
! *** This seems a bit low - see "help observe" on the binwid argument.
! Found source: J0700+1709
! Warning: Unknown AN-table MNTSTA value (3).
!          Will assume that it is ground-based.
! Warning: Unknown AN-table MNTSTA value (3).
!          Will assume that it is ground-based.
! Warning: Unknown AN-table MNTSTA value (3).
!          Will assume that it is ground-based.
! Warning: Unknown AN-table MNTSTA value (3).
!          Will assume that it is ground-based.
! Warning: Unknown AN-table MNTSTA value (3).
!          Will assume that it is ground-based.
! Warning: Unknown AN-table MNTSTA value (3).
!          Will assume that it is ground-based.
! 
! There are 4 IFs, and a total of 4 channels:
! 
!  IF  Channel    Frequency  Freq offset  Number of   Overall IF
!       origin    at origin  per channel   channels    bandwidth
!  ------------------------------------------------------------- (Hz)
!  01        1  2.23697e+09        8e+06          1        8e+06
!  02        2  2.26697e+09        8e+06          1        8e+06
!  03        3  2.35697e+09        8e+06          1        8e+06
!  04        4  2.37697e+09        8e+06          1        8e+06
! 
! Polarization(s): RR
! 
! Read 1732 lines of history.
! 
! Reading 21932 visibilities.
select I
! Polarization I is unavailable.
! Selecting polarization: RR,  channels: 1..4
! Reading IF 1 channels: 1..1
! Reading IF 2 channels: 2..2
! Reading IF 3 channels: 3..3
! Reading IF 4 channels: 4..4
print "field_size =",field_size
! field_size = 512 
print "field_cell =",field_cell
! field_cell = 0.5 
print "taper_size =",taper_size
! taper_size = 20 
integer clean_niter
clean_niter = 100
float clean_gain
clean_gain = 0.03
float dynam
dynam = 6.0
float soltime1
soltime1 = 120
float soltime2
soltime2 = 20
float thresh
thresh = 0.5
float win_mult
win_mult = 1.8
float time_av
time_av = 16
float old_peak
float new_peak
float flux_cutoff
mapsize field_size, field_cell
! Map grid = 512x512 pixels with 0.500x0.500 milli-arcsec cellsize.
startmod
! Applying default point source starting model.
! Performing phase self-cal
! Adding 1 model components to the UV plane model.
! The established model now contains 1 components and 1 Jy
! 
! Correcting IF 1.
!  A total of 1014 telescope corrections were flagged in sub-array 1.
!  A total of 1132 telescope corrections were flagged in sub-array 2.
!  A total of 281 telescope corrections were flagged in sub-array 3.
!  A total of 1444 telescope corrections were flagged in sub-array 4.
!  A total of 1307 telescope corrections were flagged in sub-array 5.
!  A total of 144 telescope corrections were flagged in sub-array 6.
! 
! Correcting IF 2.
!  A total of 1014 telescope corrections were flagged in sub-array 1.
!  A total of 1132 telescope corrections were flagged in sub-array 2.
!  A total of 281 telescope corrections were flagged in sub-array 3.
!  A total of 1444 telescope corrections were flagged in sub-array 4.
!  A total of 1307 telescope corrections were flagged in sub-array 5.
!  A total of 144 telescope corrections were flagged in sub-array 6.
! 
! Correcting IF 3.
!  A total of 1014 telescope corrections were flagged in sub-array 1.
!  A total of 1132 telescope corrections were flagged in sub-array 2.
!  A total of 281 telescope corrections were flagged in sub-array 3.
!  A total of 1444 telescope corrections were flagged in sub-array 4.
!  A total of 1307 telescope corrections were flagged in sub-array 5.
!  A total of 144 telescope corrections were flagged in sub-array 6.
! 
! Correcting IF 4.
!  A total of 1014 telescope corrections were flagged in sub-array 1.
!  A total of 1132 telescope corrections were flagged in sub-array 2.
!  A total of 281 telescope corrections were flagged in sub-array 3.
!  A total of 1444 telescope corrections were flagged in sub-array 4.
!  A total of 1307 telescope corrections were flagged in sub-array 5.
!  A total of 144 telescope corrections were flagged in sub-array 6.
! 
! Fit before self-cal, rms=0.981765Jy  sigma=0.005666
! Fit after  self-cal, rms=0.535922Jy  sigma=0.002976
! clrmod: Cleared the established, tentative and continuum models.
! Redundant starting model cleared.
uvw 2,-1
! Uniform weighting binwidth: 2 (pixels).
! Gridding weights will be scaled by errors raised to the power -1.
! Radial weighting is not currently selected.
flux_cutoff = imstat(rms) * dynam
! Inverting map and beam 
! Estimated beam: bmin=1.931 mas, bmaj=3.934 mas, bpa=4.108 degrees
! Estimated noise=1205.91 mJy/beam.
repeat
  if (peak(flux) > flux_cutoff) peakwin win_mult
  clean clean_niter,clean_gain
  flux_cutoff = imstat(rms) * dynam
  selfcal
  new_peak = peak(flux)
  until(new_peak<=flux_cutoff)
! Added new window around map position (0, 0).
! clean: niter=100  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.446957 Jy
! Component: 100  -  total flux cleaned = 0.556103 Jy
! Total flux subtracted in 100 components = 0.556103 Jy
! Clean residual min=-0.015354 max=0.046648 Jy/beam
! Clean residual mean=0.000296 rms=0.004961 Jy/beam
! Combined flux in latest and established models = 0.556103 Jy
! Performing phase self-cal
! Adding 8 model components to the UV plane model.
! The established model now contains 8 components and 0.556103 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.351589Jy  sigma=0.001560
! Fit after  self-cal, rms=0.351295Jy  sigma=0.001559
! Inverting map 
! clean: niter=100  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.0536707 Jy
! Component: 100  -  total flux cleaned = 0.0876763 Jy
! Total flux subtracted in 100 components = 0.0876763 Jy
! Clean residual min=-0.013580 max=0.032215 Jy/beam
! Clean residual mean=0.000190 rms=0.003894 Jy/beam
! Combined flux in latest and established models = 0.64378 Jy
! Performing phase self-cal
! Adding 21 model components to the UV plane model.
! The established model now contains 24 components and 0.64378 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.339262Jy  sigma=0.001431
! Fit after  self-cal, rms=0.338715Jy  sigma=0.001430
! Inverting map 
! Added new window around map position (-2.5, -4.5).
! clean: niter=100  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.0312824 Jy
! Component: 100  -  total flux cleaned = 0.0520935 Jy
! Total flux subtracted in 100 components = 0.0520935 Jy
! Clean residual min=-0.011490 max=0.019076 Jy/beam
! Clean residual mean=0.000138 rms=0.003388 Jy/beam
! Combined flux in latest and established models = 0.695873 Jy
! Performing phase self-cal
! Adding 12 model components to the UV plane model.
! The established model now contains 30 components and 0.695873 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.334430Jy  sigma=0.001381
! Fit after  self-cal, rms=0.334017Jy  sigma=0.001379
! Inverting map 
print "************** FINISHED UNIFORM WEIGHTING CLEAN **************"
! ************** FINISHED UNIFORM WEIGHTING CLEAN ************** 
! 
uvw 0,-1
! Uniform weighting is not currently selected.
! Gridding weights will be scaled by errors raised to the power -1.
! Radial weighting is not currently selected.
win_mult = win_mult * 1.6
clean_niter = clean_niter * 2
dynam = dynam - 0.5
flux_cutoff = imstat(rms) * dynam
! Inverting map and beam 
! Estimated beam: bmin=2.053 mas, bmaj=4.59 mas, bpa=2.097 degrees
! Estimated noise=829.515 mJy/beam.
repeat
  if (peak(flux) > flux_cutoff) peakwin win_mult
  clean clean_niter,clean_gain
  flux_cutoff = imstat(rms) * dynam
  selfcal
  new_peak = peak(flux)
  until(new_peak<=flux_cutoff)
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.0326059 Jy
! Component: 100  -  total flux cleaned = 0.0546098 Jy
! Component: 150  -  total flux cleaned = 0.0699056 Jy
! Component: 200  -  total flux cleaned = 0.0805889 Jy
! Total flux subtracted in 200 components = 0.0805889 Jy
! Clean residual min=-0.010621 max=0.016195 Jy/beam
! Clean residual mean=-0.000093 rms=0.003353 Jy/beam
! Combined flux in latest and established models = 0.776462 Jy
! Performing phase self-cal
! Adding 28 model components to the UV plane model.
! The established model now contains 56 components and 0.776462 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.330896Jy  sigma=0.001339
! Fit after  self-cal, rms=0.330553Jy  sigma=0.001337
! Inverting map 
print "************** FINISHED NATURAL WEIGHTING CLEAN **************"
! ************** FINISHED NATURAL WEIGHTING CLEAN ************** 
! 
gscale true
! Performing overall amplitude self-cal
! 
! Correcting IF 1.
!  A total of 84 telescope corrections were flagged in sub-array 1.
!  Telescope amplitude corrections in sub-array 1:
!   FD        1.01     GC        0.96     HN        0.87     KP        0.98     
!   LA        0.90     MK        0.99     NL        0.82     NY        1.01     
!   ON        1.03     OV        0.97     PT        0.90     SC        1.00*    
!   TS        1.05     KK        0.98     WZ        0.95     WF        1.02     
! 
!  A total of 18 telescope corrections were flagged in sub-array 2.
!  Telescope amplitude corrections in sub-array 2:
!   FD        1.00     GC        2.12     HN        1.00*    KP        0.98     
!   LA        1.01     MK        1.03     NL        1.10     NY        0.96     
!   ON        0.98     OV        1.05     PT        1.02     SC        1.00*    
!   TS        0.97     KK        1.00*    WZ        1.15     WF        1.00*    
! 
!  A total of 39 telescope corrections were flagged in sub-array 3.
!  Telescope amplitude corrections in sub-array 3:
!   FD        0.00*    GC        0.00*    HN        0.00*    KP        0.00*    
!   LA        0.00*    MK        0.00*    NL        0.00*    NY        0.00*    
!   ON        0.00*    OV        0.00*    PT        0.00*    SC        0.00*    
!   TS        0.00*    KK        0.00*    WZ        0.00*    WF        0.00*    
! 
!  A total of 165 telescope corrections were flagged in sub-array 4.
!  Telescope amplitude corrections in sub-array 4:
!   FD        1.00     GC        0.91     HN        1.09     KP        0.97     
!   LA        0.96     MK        1.00*    NL        1.05     NY        1.02     
!   ON        1.14     OV        0.95     PT        1.00     SC        0.94     
!   TS        0.98     KK        1.00*    WZ        1.01     WF        1.06     
! 
!  A total of 27 telescope corrections were flagged in sub-array 5.
!  Telescope amplitude corrections in sub-array 5:
!   FD        0.96     GC        0.94     HN        1.02     KP        0.93     
!   LA        0.97     MK        1.04     NL        1.03     NY        1.03     
!   ON        1.00*    OV        1.29     PT        0.95     SC        0.96     
!   TS        1.09     KK        0.95     WZ        1.00*    WF        0.99     
! 
!  Telescope amplitude corrections in sub-array 6:
!   FD        0.00*    GC        0.00*    HN        0.00*    KP        0.00*    
!   LA        0.00*    MK        0.00*    NL        0.00*    NY        0.00*    
!   ON        0.00*    OV        0.00*    PT        0.00*    SC        0.00*    
!   TS        0.00*    KK        0.00*    WZ        0.00*    WF        0.00*    
! 
! 
! Correcting IF 2.
!  A total of 84 telescope corrections were flagged in sub-array 1.
!  Telescope amplitude corrections in sub-array 1:
!   FD        0.98     GC        0.93     HN        0.92     KP        1.09     
!   LA        0.88     MK        1.07     NL        0.87     NY        0.98     
!   ON        1.36     OV        1.02     PT        0.90     SC        1.00*    
!   TS        1.07     KK        0.98     WZ        0.95     WF        1.42     
! 
!  A total of 18 telescope corrections were flagged in sub-array 2.
!  Telescope amplitude corrections in sub-array 2:
!   FD        1.01     GC        2.03     HN        1.00*    KP        1.06     
!   LA        1.04     MK        1.08     NL        1.16     NY        0.99     
!   ON        1.10     OV        0.81     PT        0.99     SC        1.00*    
!   TS        0.95     KK        1.00*    WZ        1.10     WF        1.00*    
! 
!  A total of 39 telescope corrections were flagged in sub-array 3.
!  Telescope amplitude corrections in sub-array 3:
!   FD        0.00*    GC        0.00*    HN        0.00*    KP        0.00*    
!   LA        0.00*    MK        0.00*    NL        0.00*    NY        0.00*    
!   ON        0.00*    OV        0.00*    PT        0.00*    SC        0.00*    
!   TS        0.00*    KK        0.00*    WZ        0.00*    WF        0.00*    
! 
!  A total of 165 telescope corrections were flagged in sub-array 4.
!  Telescope amplitude corrections in sub-array 4:
!   FD        1.02     GC        0.91     HN        1.00     KP        1.01     
!   LA        0.97     MK        1.00*    NL        1.12     NY        1.08     
!   ON        1.05     OV        0.93     PT        0.97     SC        0.95     
!   TS        0.95     KK        1.00*    WZ        1.00     WF        1.00     
! 
!  A total of 27 telescope corrections were flagged in sub-array 5.
!  Telescope amplitude corrections in sub-array 5:
!   FD        0.94     GC        0.91     HN        1.02     KP        0.99     
!   LA        0.97     MK        1.03     NL        1.09     NY        1.04     
!   ON        1.00*    OV        1.02     PT        0.92     SC        1.00     
!   TS        1.08     KK        0.98     WZ        1.00*    WF        0.97     
! 
!  Telescope amplitude corrections in sub-array 6:
!   FD        0.00*    GC        0.00*    HN        0.00*    KP        0.00*    
!   LA        0.00*    MK        0.00*    NL        0.00*    NY        0.00*    
!   ON        0.00*    OV        0.00*    PT        0.00*    SC        0.00*    
!   TS        0.00*    KK        0.00*    WZ        0.00*    WF        0.00*    
! 
! 
! Correcting IF 3.
!  A total of 84 telescope corrections were flagged in sub-array 1.
!  Telescope amplitude corrections in sub-array 1:
!   FD        0.95     GC        0.98     HN        0.89     KP        1.03     
!   LA        0.89     MK        1.07     NL        0.83     NY        0.98     
!   ON        1.02     OV        1.04     PT        0.90     SC        1.00*    
!   TS        1.04     KK        1.07     WZ        0.93     WF        1.02     
! 
!  A total of 18 telescope corrections were flagged in sub-array 2.
!  Telescope amplitude corrections in sub-array 2:
!   FD        0.96     GC        1.94     HN        1.00*    KP        1.06     
!   LA        0.99     MK        1.02     NL        1.05     NY        0.95     
!   ON        1.02     OV        0.92     PT        1.02     SC        1.00*    
!   TS        0.98     KK        1.00*    WZ        0.99     WF        1.00*    
! 
!  A total of 39 telescope corrections were flagged in sub-array 3.
!  Telescope amplitude corrections in sub-array 3:
!   FD        0.00*    GC        0.00*    HN        0.00*    KP        0.00*    
!   LA        0.00*    MK        0.00*    NL        0.00*    NY        0.00*    
!   ON        0.00*    OV        0.00*    PT        0.00*    SC        0.00*    
!   TS        0.00*    KK        0.00*    WZ        0.00*    WF        0.00*    
! 
!  A total of 165 telescope corrections were flagged in sub-array 4.
!  Telescope amplitude corrections in sub-array 4:
!   FD        0.98     GC        0.97     HN        1.01     KP        1.00     
!   LA        0.95     MK        1.00*    NL        0.99     NY        1.02     
!   ON        1.12     OV        0.92     PT        0.99     SC        0.98     
!   TS        0.99     KK        1.00*    WZ        0.90     WF        0.99     
! 
!  A total of 27 telescope corrections were flagged in sub-array 5.
!  Telescope amplitude corrections in sub-array 5:
!   FD        0.93     GC        0.96     HN        1.02     KP        0.98     
!   LA        0.91     MK        0.98     NL        0.97     NY        1.00     
!   ON        1.00*    OV        1.13     PT        0.97     SC        1.01     
!   TS        1.11     KK        1.00     WZ        1.00*    WF        0.98     
! 
!  Telescope amplitude corrections in sub-array 6:
!   FD        0.00*    GC        0.00*    HN        0.00*    KP        0.00*    
!   LA        0.00*    MK        0.00*    NL        0.00*    NY        0.00*    
!   ON        0.00*    OV        0.00*    PT        0.00*    SC        0.00*    
!   TS        0.00*    KK        0.00*    WZ        0.00*    WF        0.00*    
! 
! 
! Correcting IF 4.
!  A total of 84 telescope corrections were flagged in sub-array 1.
!  Telescope amplitude corrections in sub-array 1:
!   FD        0.95     GC        0.90     HN        0.89     KP        1.06     
!   LA        0.90     MK        0.99     NL        0.82     NY        0.98     
!   ON        0.97     OV        1.05     PT        0.88     SC        1.00*    
!   TS        1.05     KK        0.96     WZ        0.94     WF        0.94     
! 
!  A total of 18 telescope corrections were flagged in sub-array 2.
!  Telescope amplitude corrections in sub-array 2:
!   FD        1.19     GC        2.02     HN        1.00*    KP        1.05     
!   LA        1.04     MK        0.97     NL        1.05     NY        0.94     
!   ON        1.13     OV        0.86     PT        0.95     SC        1.00*    
!   TS        0.99     KK        1.00*    WZ        1.09     WF        1.00*    
! 
!  A total of 39 telescope corrections were flagged in sub-array 3.
!  Telescope amplitude corrections in sub-array 3:
!   FD        0.00*    GC        0.00*    HN        0.00*    KP        0.00*    
!   LA        0.00*    MK        0.00*    NL        0.00*    NY        0.00*    
!   ON        0.00*    OV        0.00*    PT        0.00*    SC        0.00*    
!   TS        0.00*    KK        0.00*    WZ        0.00*    WF        0.00*    
! 
!  A total of 165 telescope corrections were flagged in sub-array 4.
!  Telescope amplitude corrections in sub-array 4:
!   FD        0.97     GC        0.99     HN        1.03     KP        1.04     
!   LA        0.95     MK        1.00*    NL        1.08     NY        0.99     
!   ON        0.96     OV        0.91     PT        0.93     SC        1.02     
!   TS        0.96     KK        1.00*    WZ        1.02     WF        0.87     
! 
!  A total of 27 telescope corrections were flagged in sub-array 5.
!  Telescope amplitude corrections in sub-array 5:
!   FD        0.91     GC        0.96     HN        1.22     KP        0.97     
!   LA        0.98     MK        0.92     NL        0.99     NY        0.98     
!   ON        1.00*    OV        1.14     PT        0.94     SC        1.06     
!   TS        1.10     KK        1.02     WZ        1.00*    WF        1.00     
! 
!  Telescope amplitude corrections in sub-array 6:
!   FD        0.00*    GC        0.00*    HN        0.00*    KP        0.00*    
!   LA        0.00*    MK        0.00*    NL        0.00*    NY        0.00*    
!   ON        0.00*    OV        0.00*    PT        0.00*    SC        0.00*    
!   TS        0.00*    KK        0.00*    WZ        0.00*    WF        0.00*    
! 
! 
! Fit before self-cal, rms=0.330553Jy  sigma=0.001337
! Fit after  self-cal, rms=0.349305Jy  sigma=0.001276
dynam = dynam - 0.5
flux_cutoff = imstat(rms) * dynam
! Inverting map and beam 
! Estimated beam: bmin=2.092 mas, bmaj=4.595 mas, bpa=2.023 degrees
! Estimated noise=842.384 mJy/beam.
repeat
  if (peak(flux) > flux_cutoff) peakwin win_mult
  clean clean_niter,clean_gain
  flux_cutoff = imstat(rms) * dynam
  selfcal
  new_peak = peak(flux)
  until(new_peak<=flux_cutoff)
! Added new window around map position (-5, -10.5).
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.00486651 Jy
! Component: 100  -  total flux cleaned = 0.00442755 Jy
! Component: 150  -  total flux cleaned = 0.0042662 Jy
! Component: 200  -  total flux cleaned = 0.00357344 Jy
! Total flux subtracted in 200 components = 0.00357344 Jy
! Clean residual min=-0.006984 max=0.004547 Jy/beam
! Clean residual mean=-0.000252 rms=0.001434 Jy/beam
! Combined flux in latest and established models = 0.780035 Jy
! Performing phase self-cal
! Adding 19 model components to the UV plane model.
! The established model now contains 73 components and 0.780035 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.349036Jy  sigma=0.001273
! Fit after  self-cal, rms=0.350595Jy  sigma=0.001272
! Inverting map 
selfcal true, true, soltime1
! Performing amp+phase self-cal over 120 minute time intervals
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.350595Jy  sigma=0.001272
! Fit after  self-cal, rms=0.354493Jy  sigma=0.001268
dynam = dynam - 0.75
clean clean_niter,clean_gain
! Inverting map and beam 
! Estimated beam: bmin=2.098 mas, bmaj=4.596 mas, bpa=1.994 degrees
! Estimated noise=842.88 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.00131345 Jy
! Component: 100  -  total flux cleaned = 0.000823288 Jy
! Component: 150  -  total flux cleaned = 6.77628e-05 Jy
! Component: 200  -  total flux cleaned = -0.000471643 Jy
! Total flux subtracted in 200 components = -0.000471643 Jy
! Clean residual min=-0.006108 max=0.004416 Jy/beam
! Clean residual mean=-0.000182 rms=0.001271 Jy/beam
! Combined flux in latest and established models = 0.779564 Jy
selfcal
! Performing phase self-cal
! Adding 23 model components to the UV plane model.
! The established model now contains 86 components and 0.779564 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.354360Jy  sigma=0.001266
! Fit after  self-cal, rms=0.354674Jy  sigma=0.001266
flux_cutoff = imstat(rms) * dynam
! Inverting map 
repeat
  if (peak(flux) > flux_cutoff) peakwin win_mult
  clean clean_niter,clean_gain
  flux_cutoff = imstat(rms) * dynam
  selfcal
  new_peak = peak(flux)
  until(new_peak<=flux_cutoff)
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.000757188 Jy
! Component: 100  -  total flux cleaned = 0.000566282 Jy
! Component: 150  -  total flux cleaned = 0.000395515 Jy
! Component: 200  -  total flux cleaned = 0.000235614 Jy
! Total flux subtracted in 200 components = 0.000235614 Jy
! Clean residual min=-0.006106 max=0.004394 Jy/beam
! Clean residual mean=-0.000187 rms=0.001255 Jy/beam
! Combined flux in latest and established models = 0.779799 Jy
! Performing phase self-cal
! Adding 31 model components to the UV plane model.
! The established model now contains 97 components and 0.779799 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.354626Jy  sigma=0.001266
! Fit after  self-cal, rms=0.354634Jy  sigma=0.001266
! Inverting map 
selfcal true, true, soltime2
! Performing amp+phase self-cal over 20 minute time intervals
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.354634Jy  sigma=0.001266
! Fit after  self-cal, rms=0.353826Jy  sigma=0.001265
clean clean_niter,clean_gain
! Inverting map and beam 
! Estimated beam: bmin=2.104 mas, bmaj=4.598 mas, bpa=1.91 degrees
! Estimated noise=842.988 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = -7.44088e-05 Jy
! Component: 100  -  total flux cleaned = -0.000545745 Jy
! Component: 150  -  total flux cleaned = -0.000934466 Jy
! Component: 200  -  total flux cleaned = -0.00135964 Jy
! Total flux subtracted in 200 components = -0.00135964 Jy
! Clean residual min=-0.005446 max=0.004165 Jy/beam
! Clean residual mean=-0.000142 rms=0.001198 Jy/beam
! Combined flux in latest and established models = 0.77844 Jy
selfcal
! Performing phase self-cal
! Adding 24 model components to the UV plane model.
! The established model now contains 108 components and 0.77844 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.353754Jy  sigma=0.001264
! Fit after  self-cal, rms=0.353718Jy  sigma=0.001264
flux_cutoff = imstat(rms) * dynam
! Inverting map 
repeat
  if (peak(flux) > flux_cutoff) peakwin win_mult
  clean clean_niter,clean_gain
  flux_cutoff = imstat(rms) * dynam
  selfcal
  new_peak = peak(flux)
  until(new_peak<=flux_cutoff)
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.000476192 Jy
! Component: 100  -  total flux cleaned = 0.000179686 Jy
! Component: 150  -  total flux cleaned = -8.24416e-05 Jy
! Component: 200  -  total flux cleaned = -0.000201723 Jy
! Total flux subtracted in 200 components = -0.000201723 Jy
! Clean residual min=-0.005507 max=0.004194 Jy/beam
! Clean residual mean=-0.000141 rms=0.001188 Jy/beam
! Combined flux in latest and established models = 0.778238 Jy
! Performing phase self-cal
! Adding 27 model components to the UV plane model.
! The established model now contains 113 components and 0.778238 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.353689Jy  sigma=0.001264
! Fit after  self-cal, rms=0.353702Jy  sigma=0.001264
! Inverting map 
uvtaper 0.3,taper_size
! Gaussian taper: value 0.3 at UV radius = 20 mega-wavelengths.
win_mult = win_mult * 1.2
selfcal true, true, soltime2
! Performing amp+phase self-cal over 20 minute time intervals
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.353702Jy  sigma=0.001264
! Fit after  self-cal, rms=0.353044Jy  sigma=0.001263
clean clean_niter,clean_gain
! Inverting map and beam 
! Estimated beam: bmin=8.317 mas, bmaj=10.77 mas, bpa=-5.38 degrees
! Estimated noise=1242.15 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = -0.00249375 Jy
! Component: 100  -  total flux cleaned = -0.00275913 Jy
! Component: 150  -  total flux cleaned = -0.00301611 Jy
! Component: 200  -  total flux cleaned = -0.00318311 Jy
! Total flux subtracted in 200 components = -0.00318311 Jy
! Clean residual min=-0.005140 max=0.004497 Jy/beam
! Clean residual mean=-0.000342 rms=0.001539 Jy/beam
! Combined flux in latest and established models = 0.775055 Jy
selfcal
! Performing phase self-cal
! Adding 11 model components to the UV plane model.
! The established model now contains 119 components and 0.775055 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.353036Jy  sigma=0.001263
! Fit after  self-cal, rms=0.352978Jy  sigma=0.001263
flux_cutoff = imstat(rms) * dynam
! Inverting map 
repeat
  if (peak(flux) > flux_cutoff) peakwin win_mult
  clean clean_niter,clean_gain
  flux_cutoff = imstat(rms) * dynam
  selfcal
  new_peak = peak(flux)
  until(new_peak<=flux_cutoff)
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = -9.08249e-05 Jy
! Component: 100  -  total flux cleaned = -8.49615e-05 Jy
! Component: 150  -  total flux cleaned = -0.000146838 Jy
! Component: 200  -  total flux cleaned = -0.00017404 Jy
! Total flux subtracted in 200 components = -0.00017404 Jy
! Clean residual min=-0.005107 max=0.004474 Jy/beam
! Clean residual mean=-0.000341 rms=0.001530 Jy/beam
! Combined flux in latest and established models = 0.774881 Jy
! Performing phase self-cal
! Adding 7 model components to the UV plane model.
! The established model now contains 121 components and 0.774881 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.352990Jy  sigma=0.001263
! Fit after  self-cal, rms=0.352990Jy  sigma=0.001263
! Inverting map 
uvtaper 0,0
! No UV-taper is currently set.
win_mult = win_mult / 1.2
print "************** FINISHED AMPLITUDE SELF-CAL **************"
! ************** FINISHED AMPLITUDE SELF-CAL ************** 
restore
! Inverting map and beam 
! Estimated beam: bmin=2.109 mas, bmaj=4.602 mas, bpa=1.86 degrees
! Estimated noise=843.234 mJy/beam.
! restore: Substituting estimate of restoring beam from last 'invert'.
! Restoring with beam: 2.109 x 4.602 at 1.86 degrees (North through East)
! Clean map  min=-0.0046599  max=0.57622 Jy/beam
if(peak(flux) > thresh)
  selfcal true, true
  clean clean_niter,clean_gain
  selfcal
  flux_cutoff = imstat(rms) * dynam
  repeat
    if (peak(flux) > flux_cutoff) peakwin win_mult
    clean clean_niter,clean_gain
    flux_cutoff = imstat(rms) * dynam
    selfcal
    new_peak = peak(flux)
    until(new_peak<=flux_cutoff)
  selfcal true, true
  end if
! Performing amp+phase self-cal
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.352990Jy  sigma=0.001263
! Fit after  self-cal, rms=0.802864Jy  sigma=0.001142
! Inverting map and beam 
! Estimated beam: bmin=2.113 mas, bmaj=4.601 mas, bpa=1.91 degrees
! Estimated noise=842.362 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = -0.00101905 Jy
! Component: 100  -  total flux cleaned = -0.00068169 Jy
! Component: 150  -  total flux cleaned = -0.000536873 Jy
! Component: 200  -  total flux cleaned = -0.00047255 Jy
! Total flux subtracted in 200 components = -0.00047255 Jy
! Clean residual min=-0.003645 max=0.003776 Jy/beam
! Clean residual mean=0.000017 rms=0.000991 Jy/beam
! Combined flux in latest and established models = 0.774408 Jy
! Performing phase self-cal
! Adding 25 model components to the UV plane model.
! The established model now contains 134 components and 0.774408 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.802844Jy  sigma=0.001142
! Fit after  self-cal, rms=0.802872Jy  sigma=0.001142
! Inverting map 
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.000542751 Jy
! Component: 100  -  total flux cleaned = 0.000542501 Jy
! Component: 150  -  total flux cleaned = 0.000543722 Jy
! Component: 200  -  total flux cleaned = 0.000590539 Jy
! Total flux subtracted in 200 components = 0.000590539 Jy
! Clean residual min=-0.003639 max=0.003762 Jy/beam
! Clean residual mean=0.000012 rms=0.000985 Jy/beam
! Combined flux in latest and established models = 0.774999 Jy
! Performing phase self-cal
! Adding 21 model components to the UV plane model.
! The established model now contains 136 components and 0.774999 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.802863Jy  sigma=0.001142
! Fit after  self-cal, rms=0.802863Jy  sigma=0.001142
! Inverting map 
! Performing amp+phase self-cal
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.802863Jy  sigma=0.001142
! Fit after  self-cal, rms=1.306247Jy  sigma=0.001142
print "************** CLEARING MODEL AND STARTING OVER **********"
! ************** CLEARING MODEL AND STARTING OVER ********** 
clrmod true
! clrmod: Cleared the established and tentative models.
uvw 2,-1
! Uniform weighting binwidth: 2 (pixels).
! Gridding weights will be scaled by errors raised to the power -1.
! Radial weighting is not currently selected.
clean clean_niter,clean_gain
! Inverting map and beam 
! Estimated beam: bmin=1.964 mas, bmaj=3.914 mas, bpa=3.742 degrees
! Estimated noise=1223.22 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.445799 Jy
! Component: 100  -  total flux cleaned = 0.554044 Jy
! Component: 150  -  total flux cleaned = 0.605082 Jy
! Component: 200  -  total flux cleaned = 0.639668 Jy
! Total flux subtracted in 200 components = 0.639668 Jy
! Clean residual min=-0.008395 max=0.019453 Jy/beam
! Clean residual mean=0.000138 rms=0.002640 Jy/beam
! Combined flux in latest and established models = 0.639668 Jy
uvw 0,-1
! Uniform weighting is not currently selected.
! Gridding weights will be scaled by errors raised to the power -1.
! Radial weighting is not currently selected.
flux_cutoff = imstat(rms) * dynam
! Adding 24 model components to the UV plane model.
! The established model now contains 24 components and 0.639668 Jy
! Inverting map and beam 
! Estimated beam: bmin=2.116 mas, bmaj=4.605 mas, bpa=1.832 degrees
! Estimated noise=842.489 mJy/beam.
repeat
  if (peak(flux) > flux_cutoff) peakwin win_mult
  clean clean_niter,clean_gain
  flux_cutoff = imstat(rms) * dynam
  keep
  new_peak = peak(flux)
  until(new_peak<=flux_cutoff)
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.0420933 Jy
! Component: 100  -  total flux cleaned = 0.0699206 Jy
! Component: 150  -  total flux cleaned = 0.0889041 Jy
! Component: 200  -  total flux cleaned = 0.102265 Jy
! Total flux subtracted in 200 components = 0.102265 Jy
! Clean residual min=-0.005024 max=0.007455 Jy/beam
! Clean residual mean=0.000303 rms=0.001458 Jy/beam
! Combined flux in latest and established models = 0.741933 Jy
! Adding 62 model components to the UV plane model.
! The established model now contains 79 components and 0.741933 Jy
! Inverting map 
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.00955918 Jy
! Component: 100  -  total flux cleaned = 0.0164689 Jy
! Component: 150  -  total flux cleaned = 0.0214715 Jy
! Component: 200  -  total flux cleaned = 0.0251041 Jy
! Total flux subtracted in 200 components = 0.0251041 Jy
! Clean residual min=-0.003968 max=0.004061 Jy/beam
! Clean residual mean=0.000073 rms=0.001032 Jy/beam
! Combined flux in latest and established models = 0.767037 Jy
! Adding 36 model components to the UV plane model.
! The established model now contains 100 components and 0.767037 Jy
! Inverting map 
uvtaper 0.3,taper_size
! Gaussian taper: value 0.3 at UV radius = 20 mega-wavelengths.
clean clean_niter,clean_gain
! Inverting map and beam 
! Estimated beam: bmin=8.309 mas, bmaj=10.8 mas, bpa=-6.035 degrees
! Estimated noise=1236.93 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.00492575 Jy
! Component: 100  -  total flux cleaned = 0.00622084 Jy
! Component: 150  -  total flux cleaned = 0.00646778 Jy
! Component: 200  -  total flux cleaned = 0.00657533 Jy
! Total flux subtracted in 200 components = 0.00657533 Jy
! Clean residual min=-0.003707 max=0.004339 Jy/beam
! Clean residual mean=0.000040 rms=0.001299 Jy/beam
! Combined flux in latest and established models = 0.773612 Jy
flux_cutoff = imstat(rms) * dynam
repeat
  if (peak(flux) > flux_cutoff) peakwin win_mult
  clean clean_niter,clean_gain
  flux_cutoff = imstat(rms) * dynam
  keep
  new_peak = peak(flux)
  until(new_peak<=flux_cutoff)
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 2.82526e-05 Jy
! Component: 100  -  total flux cleaned = -4.53821e-05 Jy
! Component: 150  -  total flux cleaned = -6.7246e-05 Jy
! Component: 200  -  total flux cleaned = -0.000110744 Jy
! Total flux subtracted in 200 components = -0.000110744 Jy
! Clean residual min=-0.003644 max=0.004335 Jy/beam
! Clean residual mean=0.000043 rms=0.001291 Jy/beam
! Combined flux in latest and established models = 0.773502 Jy
! Adding 34 model components to the UV plane model.
! The established model now contains 122 components and 0.773502 Jy
! Inverting map 
uvtaper 0,0
! No UV-taper is currently set.
clean
! Inverting map and beam 
! Estimated beam: bmin=2.116 mas, bmaj=4.605 mas, bpa=1.832 degrees
! Estimated noise=842.489 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.000175563 Jy
! Component: 100  -  total flux cleaned = 0.00045243 Jy
! Component: 150  -  total flux cleaned = 0.000512377 Jy
! Component: 200  -  total flux cleaned = 0.00056767 Jy
! Total flux subtracted in 200 components = 0.00056767 Jy
! Clean residual min=-0.003553 max=0.003732 Jy/beam
! Clean residual mean=0.000007 rms=0.000983 Jy/beam
! Combined flux in latest and established models = 0.774069 Jy
selfcal
! Performing phase self-cal
! Adding 19 model components to the UV plane model.
! The established model now contains 138 components and 0.774069 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=1.306230Jy  sigma=0.001142
! Fit after  self-cal, rms=1.306280Jy  sigma=0.001141
wmodel J0700+1709_S_2003_09_17_pus_map.mod
! Writing 138 model components to file: J0700+1709_S_2003_09_17_pus_map.mod
wobs J0700+1709_S_2003_09_17_pus_uvs.fits
! Writing UV FITS file: J0700+1709_S_2003_09_17_pus_uvs.fits
wwins J0700+1709_S_2003_09_17_pus_map.win
! wwins: Wrote 3 windows to J0700+1709_S_2003_09_17_pus_map.win
x = (field_size-8) * field_cell / 4
addwin -x,x,-x,x
clean (field_size*4),0.01
! Inverting map 
! clean: niter=2048  gain=0.01  cutoff=0
! Component: 050  -  total flux cleaned = 0.000614753 Jy
! Component: 100  -  total flux cleaned = 0.000874639 Jy
! Component: 150  -  total flux cleaned = 0.000999917 Jy
! Component: 200  -  total flux cleaned = 0.000939811 Jy
! Component: 250  -  total flux cleaned = 0.000823544 Jy
! Component: 300  -  total flux cleaned = 0.000595143 Jy
! Component: 350  -  total flux cleaned = 0.000314433 Jy
! Component: 400  -  total flux cleaned = 0.000204061 Jy
! Component: 450  -  total flux cleaned = 0.000149283 Jy
! Component: 500  -  total flux cleaned = -1.16985e-05 Jy
! Component: 550  -  total flux cleaned = -6.46588e-05 Jy
! Component: 600  -  total flux cleaned = -0.000221138 Jy
! Component: 650  -  total flux cleaned = -0.000221443 Jy
! Component: 700  -  total flux cleaned = -0.000323759 Jy
! Component: 750  -  total flux cleaned = -0.000474121 Jy
! Component: 800  -  total flux cleaned = -0.000523997 Jy
! Component: 850  -  total flux cleaned = -0.000671422 Jy
! Component: 900  -  total flux cleaned = -0.000768278 Jy
! Component: 950  -  total flux cleaned = -0.000864028 Jy
! Component: 1000  -  total flux cleaned = -0.000864262 Jy
! Component: 1050  -  total flux cleaned = -0.000959387 Jy
! Component: 1100  -  total flux cleaned = -0.0012386 Jy
! Component: 1150  -  total flux cleaned = -0.00119162 Jy
! Component: 1200  -  total flux cleaned = -0.00114588 Jy
! Component: 1250  -  total flux cleaned = -0.00119111 Jy
! Component: 1300  -  total flux cleaned = -0.00105676 Jy
! Component: 1350  -  total flux cleaned = -0.00110184 Jy
! Component: 1400  -  total flux cleaned = -0.001146 Jy
! Component: 1450  -  total flux cleaned = -0.00118998 Jy
! Component: 1500  -  total flux cleaned = -0.00123309 Jy
! Component: 1550  -  total flux cleaned = -0.00123291 Jy
! Component: 1600  -  total flux cleaned = -0.00118976 Jy
! Component: 1650  -  total flux cleaned = -0.00110539 Jy
! Component: 1700  -  total flux cleaned = -0.00114752 Jy
! Component: 1750  -  total flux cleaned = -0.00114769 Jy
! Component: 1800  -  total flux cleaned = -0.00114778 Jy
! Component: 1850  -  total flux cleaned = -0.00110665 Jy
! Component: 1900  -  total flux cleaned = -0.00106591 Jy
! Component: 1950  -  total flux cleaned = -0.00106595 Jy
! Component: 2000  -  total flux cleaned = -0.00110616 Jy
! Total flux subtracted in 2048 components = -0.00106592 Jy
! Clean residual min=-0.002074 max=0.002179 Jy/beam
! Clean residual mean=0.000018 rms=0.000774 Jy/beam
! Combined flux in latest and established models = 0.773004 Jy
keep
! Adding 153 model components to the UV plane model.
! The established model now contains 291 components and 0.773003 Jy
wmap "J0700+1709_S_2003_09_17_pus\_map.fits"
! Inverting map 
! restore: Substituting estimate of restoring beam from last 'invert'.
! Restoring with beam: 2.116 x 4.605 at 1.832 degrees (North through East)
! Clean map  min=-0.0030719  max=0.57622 Jy/beam
! Writing clean map to FITS file: J0700+1709_S_2003_09_17_pus_map.fits
float peak_flux
peak_flux = peak(flux,max)
print "The peak flux is",peak_flux
! The peak flux is 0.576215 
invert
! Inverting map 
float image_rms
image_rms = imstat(rms)
print "The final image rms is",image_rms
! The final image rms is 0.000774337 
device "J0700+1709_S_2003_09_17_pus\_map.eps/VPS"
! Attempting to open device: 'J0700+1709_S_2003_09_17_pus_map.eps/VPS'
loglevs 100*3*image_rms/peak_flux
! The new contour levels are:
!  -0.40315 0.40315 0.806299 1.6126 3.2252 6.4504 12.9008 25.8016 51.6032
print "clev=",int(3*image_rms*10000)/10000
! clev= 0.0023 
print "peak=",int(1000*peak_flux)/1000
! peak= 0.576 
mapcolor none
! Mapplot colormap: none, contrast: 1 brightness: 0.5.
mapplot cln
! restore: Substituting estimate of restoring beam from last 'invert'.
! Restoring with beam: 2.116 x 4.605 at 1.832 degrees (North through East)
! Clean map  min=-0.0030719  max=0.57622 Jy/beam
mapcolor color, 0.9
! Mapplot colormap: rainbow, contrast: 0.9 brightness: 0.5.
device "J0700+1709_S_2003_09_17_pus\_map.gif/vgif"
! Attempting to open device: 'J0700+1709_S_2003_09_17_pus_map.gif/vgif'
mapplot cln
quit
! Quitting program
! Log file J0700+1709_S_2003_09_17_pus_uvs.log closed on Tue May 22 12:16:51 2007