! Started logfile: J1613+3412_S_1999_03_08_pus_uvs.log on Tue Jan  8 18:28:50 2008
obs J1613+3412_S_1999_03_08_pus_uva.fits
! Reading UV FITS file: J1613+3412_S_1999_03_08_pus_uva.fits
! AN table 1: 234 integrations on 190 of 190 possible baselines.
! AN table 2: 91 integrations on 190 of 190 possible baselines.
! AN table 3: 33 integrations on 190 of 190 possible baselines.
! AN table 4: 54 integrations on 190 of 190 possible baselines.
! Apparent sampling: 0.251405 visibilities/baseline/integration-bin.
! *** This seems a bit low - see "help observe" on the binwid argument.
! Found source: J1613+3412
! 
! 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.22497e+09        8e+06          1        8e+06
!  02        2  2.24497e+09        8e+06          1        8e+06
!  03        3  2.33497e+09        8e+06          1        8e+06
!  04        4  2.36497e+09        8e+06          1        8e+06
! 
! Polarization(s): RR
! 
! Read 2332 lines of history.
! 
! Reading 78720 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 
![@muppet J1613+3412_S_1999_03_08_pus]
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 2324 telescope corrections were flagged in sub-array 1.
!  A total of 1281 telescope corrections were flagged in sub-array 2.
!  A total of 395 telescope corrections were flagged in sub-array 3.
!  A total of 632 telescope corrections were flagged in sub-array 4.
! 
! Correcting IF 2.
!  A total of 2324 telescope corrections were flagged in sub-array 1.
!  A total of 1281 telescope corrections were flagged in sub-array 2.
!  A total of 395 telescope corrections were flagged in sub-array 3.
!  A total of 632 telescope corrections were flagged in sub-array 4.
! 
! Correcting IF 3.
!  A total of 2324 telescope corrections were flagged in sub-array 1.
!  A total of 1281 telescope corrections were flagged in sub-array 2.
!  A total of 395 telescope corrections were flagged in sub-array 3.
!  A total of 616 telescope corrections were flagged in sub-array 4.
! 
! Correcting IF 4.
!  A total of 2324 telescope corrections were flagged in sub-array 1.
!  A total of 1281 telescope corrections were flagged in sub-array 2.
!  A total of 395 telescope corrections were flagged in sub-array 3.
!  A total of 616 telescope corrections were flagged in sub-array 4.
! 
! Fit before self-cal, rms=2.047346Jy  sigma=0.018374
! Fit after  self-cal, rms=1.914935Jy  sigma=0.017615
! 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=2.06 mas, bmaj=3.047 mas, bpa=-11.31 degrees
! Estimated noise=793.65 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 = 1.59392 Jy
! Component: 100  -  total flux cleaned = 2.31264 Jy
! Total flux subtracted in 100 components = 2.31264 Jy
! Clean residual min=-0.069913 max=0.373307 Jy/beam
! Clean residual mean=0.000391 rms=0.026504 Jy/beam
! Combined flux in latest and established models = 2.31264 Jy
! Performing phase self-cal
! Adding 14 model components to the UV plane model.
! The established model now contains 14 components and 2.31264 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=1.084913Jy  sigma=0.009890
! Fit after  self-cal, rms=1.069699Jy  sigma=0.009817
! Inverting map 
! clean: niter=100  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.485846 Jy
! Component: 100  -  total flux cleaned = 0.808343 Jy
! Total flux subtracted in 100 components = 0.808343 Jy
! Clean residual min=-0.042660 max=0.177696 Jy/beam
! Clean residual mean=0.000147 rms=0.014684 Jy/beam
! Combined flux in latest and established models = 3.12099 Jy
! Performing phase self-cal
! Adding 11 model components to the UV plane model.
! The established model now contains 20 components and 3.12099 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.641651Jy  sigma=0.005703
! Fit after  self-cal, rms=0.635348Jy  sigma=0.005675
! Inverting map 
! clean: niter=100  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.235218 Jy
! Component: 100  -  total flux cleaned = 0.402116 Jy
! Total flux subtracted in 100 components = 0.402116 Jy
! Clean residual min=-0.029400 max=0.105968 Jy/beam
! Clean residual mean=0.000028 rms=0.009722 Jy/beam
! Combined flux in latest and established models = 3.5231 Jy
! Performing phase self-cal
! Adding 19 model components to the UV plane model.
! The established model now contains 33 components and 3.5231 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.467131Jy  sigma=0.003967
! Fit after  self-cal, rms=0.465942Jy  sigma=0.003962
! Inverting map 
! Added new window around map position (2, -0.5).
! clean: niter=100  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.12839 Jy
! Component: 100  -  total flux cleaned = 0.22269 Jy
! Total flux subtracted in 100 components = 0.22269 Jy
! Clean residual min=-0.024256 max=0.069885 Jy/beam
! Clean residual mean=-0.000035 rms=0.007617 Jy/beam
! Combined flux in latest and established models = 3.74579 Jy
! Performing phase self-cal
! Adding 16 model components to the UV plane model.
! The established model now contains 40 components and 3.74579 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.399722Jy  sigma=0.003240
! Fit after  self-cal, rms=0.399332Jy  sigma=0.003238
! Inverting map 
! Added new window around map position (-2.5, -0.5).
! clean: niter=100  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.0777029 Jy
! Component: 100  -  total flux cleaned = 0.136111 Jy
! Total flux subtracted in 100 components = 0.136111 Jy
! Clean residual min=-0.024522 max=0.040625 Jy/beam
! Clean residual mean=-0.000073 rms=0.006658 Jy/beam
! Combined flux in latest and established models = 3.8819 Jy
! Performing phase self-cal
! Adding 14 model components to the UV plane model.
! The established model now contains 48 components and 3.8819 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.372079Jy  sigma=0.002909
! Fit after  self-cal, rms=0.371838Jy  sigma=0.002908
! Inverting map 
! Added new window around map position (-0.5, 5).
! clean: niter=100  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.0494114 Jy
! Component: 100  -  total flux cleaned = 0.0893023 Jy
! Total flux subtracted in 100 components = 0.0893023 Jy
! Clean residual min=-0.025890 max=0.029546 Jy/beam
! Clean residual mean=-0.000100 rms=0.006222 Jy/beam
! Combined flux in latest and established models = 3.97121 Jy
! Performing phase self-cal
! Adding 26 model components to the UV plane model.
! The established model now contains 65 components and 3.97121 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.359484Jy  sigma=0.002750
! Fit after  self-cal, rms=0.359286Jy  sigma=0.002749
! 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.552 mas, bmaj=4.133 mas, bpa=-4.899 degrees
! Estimated noise=315.914 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.0706829 Jy
! Component: 100  -  total flux cleaned = 0.119119 Jy
! Component: 150  -  total flux cleaned = 0.154212 Jy
! Component: 200  -  total flux cleaned = 0.180341 Jy
! Total flux subtracted in 200 components = 0.180341 Jy
! Clean residual min=-0.021543 max=0.032803 Jy/beam
! Clean residual mean=-0.000711 rms=0.007233 Jy/beam
! Combined flux in latest and established models = 4.15155 Jy
! Performing phase self-cal
! Adding 52 model components to the UV plane model.
! The established model now contains 102 components and 4.15155 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.346751Jy  sigma=0.002549
! Fit after  self-cal, rms=0.346330Jy  sigma=0.002546
! Inverting map 
print "************** FINISHED NATURAL WEIGHTING CLEAN **************"
! ************** FINISHED NATURAL WEIGHTING CLEAN ************** 
! 
gscale true
! Performing overall amplitude self-cal
! 
! Correcting IF 1.
!  A total of 138 telescope corrections were flagged in sub-array 1.
!  Telescope amplitude corrections in sub-array 1:
!   BR        0.96     FD        0.98     GC        0.96     GG        1.00*    
!   HN        0.98     KP        0.97     LA        0.98     NL        1.05     
!   OV        0.98     PT        1.02     SC        1.00     WF        0.96     
!   GN        0.95     HH        1.00*    KK        1.04     MC        1.01     
!   MK        0.97     NY        0.98     ON        0.97     WZ        1.02     
! 
!  A total of 21 telescope corrections were flagged in sub-array 2.
!  Telescope amplitude corrections in sub-array 2:
!   BR        0.94     FD        0.99     GC        1.00     GG        1.00*    
!   HN        0.97     KP        0.94     LA        0.98     NL        1.04     
!   OV        0.98     PT        1.00*    SC        1.03     WF        0.94     
!   GN        0.95     HH        1.00*    KK        0.98     MC        1.00*    
!   MK        0.94     NY        0.94     ON        2.15     WZ        1.00*    
! 
!  Telescope amplitude corrections in sub-array 3:
!   BR        0.95     FD        0.98     GC        0.99     GG        1.00*    
!   HN        1.11     KP        1.00*    LA        1.00*    NL        1.08     
!   OV        1.00*    PT        1.00*    SC        1.00*    WF        1.05     
!   GN        1.07     HH        1.00*    KK        0.97     MC        1.00*    
!   MK        0.92     NY        0.99     ON        1.00*    WZ        1.00*    
! 
!  A total of 3 telescope corrections were flagged in sub-array 4.
!  Telescope amplitude corrections in sub-array 4:
!   BR        1.03     FD        1.00     GC        1.10     GG        1.00*    
!   HN        0.98     KP        1.00*    LA        0.99     NL        0.99     
!   OV        1.00*    PT        1.06     SC        0.99     WF        0.99     
!   GN        0.98     HH        1.00*    KK        1.00*    MC        0.95     
!   MK        1.00*    NY        0.97     ON        0.96     WZ        1.05     
! 
! 
! Correcting IF 2.
!  A total of 138 telescope corrections were flagged in sub-array 1.
!  Telescope amplitude corrections in sub-array 1:
!   BR        1.00     FD        1.02     GC        0.99     GG        1.00*    
!   HN        0.96     KP        0.98     LA        0.96     NL        0.93     
!   OV        0.95     PT        0.98     SC        1.03     WF        0.96     
!   GN        0.95     HH        1.00*    KK        1.00     MC        1.45     
!   MK        0.99     NY        0.97     ON        0.98     WZ        1.02     
! 
!  A total of 21 telescope corrections were flagged in sub-array 2.
!  Telescope amplitude corrections in sub-array 2:
!   BR        0.99     FD        1.09     GC        1.03     GG        1.00*    
!   HN        0.95     KP        0.95     LA        0.95     NL        0.92     
!   OV        0.93     PT        1.00*    SC        1.07     WF        0.97     
!   GN        0.96     HH        1.00*    KK        0.95     MC        1.00*    
!   MK        0.97     NY        0.94     ON        2.21     WZ        1.00*    
! 
!  Telescope amplitude corrections in sub-array 3:
!   BR        0.99     FD        1.03     GC        1.01     GG        1.00*    
!   HN        1.00     KP        1.00*    LA        1.00*    NL        0.94     
!   OV        1.00*    PT        1.00*    SC        1.00*    WF        1.08     
!   GN        1.07     HH        1.00*    KK        0.93     MC        1.00*    
!   MK        0.95     NY        1.00     ON        1.00*    WZ        1.00*    
! 
!  A total of 3 telescope corrections were flagged in sub-array 4.
!  Telescope amplitude corrections in sub-array 4:
!   BR        1.01     FD        1.05     GC        1.14     GG        1.00*    
!   HN        0.96     KP        1.00*    LA        0.98     NL        1.00     
!   OV        1.00*    PT        1.01     SC        1.04     WF        1.01     
!   GN        0.99     HH        1.00*    KK        1.00*    MC        3.20     
!   MK        1.00*    NY        0.96     ON        0.98     WZ        1.02     
! 
! 
! Correcting IF 3.
!  A total of 138 telescope corrections were flagged in sub-array 1.
!  Telescope amplitude corrections in sub-array 1:
!   BR        1.01     FD        1.00     GC        1.00     GG        1.00*    
!   HN        1.23     KP        0.99     LA        1.00     NL        0.99     
!   OV        0.98     PT        0.96     SC        1.00     WF        0.97     
!   GN        0.96     HH        1.00*    KK        1.02     MC        0.92     
!   MK        0.98     NY        0.99     ON        1.00     WZ        1.04     
! 
!  A total of 21 telescope corrections were flagged in sub-array 2.
!  Telescope amplitude corrections in sub-array 2:
!   BR        1.01     FD        1.06     GC        1.04     GG        1.00*    
!   HN        1.22     KP        0.97     LA        0.98     NL        1.00     
!   OV        0.97     PT        1.00*    SC        1.05     WF        0.97     
!   GN        0.97     HH        1.00*    KK        0.98     MC        1.00*    
!   MK        0.96     NY        0.97     ON        2.18     WZ        1.00*    
! 
!  Telescope amplitude corrections in sub-array 3:
!   BR        1.00     FD        1.01     GC        1.01     GG        1.00*    
!   HN        1.30     KP        1.00*    LA        1.00*    NL        1.03     
!   OV        1.00*    PT        1.00*    SC        1.00*    WF        1.09     
!   GN        1.08     HH        1.00*    KK        0.96     MC        1.00*    
!   MK        0.96     NY        1.01     ON        1.00*    WZ        1.00*    
! 
!  A total of 3 telescope corrections were flagged in sub-array 4.
!  Telescope amplitude corrections in sub-array 4:
!   BR        1.06     FD        1.03     GC        1.12     GG        1.00*    
!   HN        1.23     KP        1.00*    LA        1.01     NL        1.00     
!   OV        1.00*    PT        1.01     SC        1.04     WF        1.02     
!   GN        0.98     HH        1.02     KK        1.00*    MC        1.00     
!   MK        1.00*    NY        0.99     ON        0.99     WZ        0.93     
! 
! 
! Correcting IF 4.
!  A total of 138 telescope corrections were flagged in sub-array 1.
!  Telescope amplitude corrections in sub-array 1:
!   BR        0.98     FD        1.00     GC        1.02     GG        1.00*    
!   HN        1.17     KP        0.99     LA        0.99     NL        0.96     
!   OV        1.00     PT        0.96     SC        1.01     WF        0.98     
!   GN        0.96     HH        1.00*    KK        1.07     MC        1.34     
!   MK        1.01     NY        1.00     ON        1.00     WZ        1.03     
! 
!  A total of 21 telescope corrections were flagged in sub-array 2.
!  Telescope amplitude corrections in sub-array 2:
!   BR        0.99     FD        1.07     GC        1.06     GG        1.00*    
!   HN        1.17     KP        0.97     LA        0.98     NL        0.95     
!   OV        0.99     PT        1.00*    SC        1.05     WF        0.98     
!   GN        0.96     HH        1.00*    KK        1.02     MC        1.00*    
!   MK        0.99     NY        0.97     ON        2.10     WZ        1.00*    
! 
!  Telescope amplitude corrections in sub-array 3:
!   BR        0.97     FD        1.02     GC        1.03     GG        1.00*    
!   HN        1.23     KP        1.00*    LA        1.00*    NL        0.96     
!   OV        1.00*    PT        1.00*    SC        1.00*    WF        1.09     
!   GN        1.07     HH        1.00*    KK        1.00     MC        1.00*    
!   MK        0.98     NY        1.02     ON        1.00*    WZ        1.00*    
! 
!  A total of 3 telescope corrections were flagged in sub-array 4.
!  Telescope amplitude corrections in sub-array 4:
!   BR        1.00     FD        1.01     GC        1.12     GG        1.00*    
!   HN        1.17     KP        1.00*    LA        1.01     NL        1.01     
!   OV        1.00*    PT        0.98     SC        1.04     WF        1.02     
!   GN        0.99     HH        1.12     KK        1.00*    MC        0.96     
!   MK        1.00*    NY        0.97     ON        0.99     WZ        0.99     
! 
! 
! Fit before self-cal, rms=0.346330Jy  sigma=0.002546
! Fit after  self-cal, rms=0.308281Jy  sigma=0.001699
dynam = dynam - 0.5
flux_cutoff = imstat(rms) * dynam
! Inverting map and beam 
! Estimated beam: bmin=2.584 mas, bmaj=4.178 mas, bpa=-5.214 degrees
! Estimated noise=318.577 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 (-4, 4.5).
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.00171697 Jy
! Component: 100  -  total flux cleaned = 0.00317481 Jy
! Component: 150  -  total flux cleaned = 0.00429442 Jy
! Component: 200  -  total flux cleaned = 0.00494667 Jy
! Total flux subtracted in 200 components = 0.00494667 Jy
! Clean residual min=-0.008261 max=0.010363 Jy/beam
! Clean residual mean=0.000146 rms=0.002115 Jy/beam
! Combined flux in latest and established models = 4.15649 Jy
! Performing phase self-cal
! Adding 21 model components to the UV plane model.
! The established model now contains 119 components and 4.15649 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.306604Jy  sigma=0.001684
! Fit after  self-cal, rms=0.306670Jy  sigma=0.001684
! 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.306670Jy  sigma=0.001684
! Fit after  self-cal, rms=0.582916Jy  sigma=0.001571
dynam = dynam - 0.75
clean clean_niter,clean_gain
! Inverting map and beam 
! Estimated beam: bmin=2.582 mas, bmaj=4.175 mas, bpa=-5.254 degrees
! Estimated noise=318.12 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = -0.000845788 Jy
! Component: 100  -  total flux cleaned = -0.000517936 Jy
! Component: 150  -  total flux cleaned = 0.000408521 Jy
! Component: 200  -  total flux cleaned = 0.00096131 Jy
! Total flux subtracted in 200 components = 0.00096131 Jy
! Clean residual min=-0.006278 max=0.010861 Jy/beam
! Clean residual mean=0.000121 rms=0.001484 Jy/beam
! Combined flux in latest and established models = 4.15745 Jy
selfcal
! Performing phase self-cal
! Adding 15 model components to the UV plane model.
! The established model now contains 127 components and 4.15745 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.582495Jy  sigma=0.001564
! Fit after  self-cal, rms=0.582633Jy  sigma=0.001563
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)
! Added new window around map position (5, 7.5).
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.0098246 Jy
! Component: 100  -  total flux cleaned = 0.0109447 Jy
! Component: 150  -  total flux cleaned = 0.0111954 Jy
! Component: 200  -  total flux cleaned = 0.0114249 Jy
! Total flux subtracted in 200 components = 0.0114249 Jy
! Clean residual min=-0.005678 max=0.004735 Jy/beam
! Clean residual mean=0.000079 rms=0.001246 Jy/beam
! Combined flux in latest and established models = 4.16888 Jy
! Performing phase self-cal
! Adding 20 model components to the UV plane model.
! The established model now contains 139 components and 4.16888 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.582347Jy  sigma=0.001556
! Fit after  self-cal, rms=0.582401Jy  sigma=0.001556
! 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.582401Jy  sigma=0.001556
! Fit after  self-cal, rms=0.588542Jy  sigma=0.001554
clean clean_niter,clean_gain
! Inverting map and beam 
! Estimated beam: bmin=2.584 mas, bmaj=4.176 mas, bpa=-5.267 degrees
! Estimated noise=318.172 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = -0.000871125 Jy
! Component: 100  -  total flux cleaned = -0.000442741 Jy
! Component: 150  -  total flux cleaned = 0.000378896 Jy
! Component: 200  -  total flux cleaned = 0.000759951 Jy
! Total flux subtracted in 200 components = 0.000759951 Jy
! Clean residual min=-0.004972 max=0.004366 Jy/beam
! Clean residual mean=0.000065 rms=0.001105 Jy/beam
! Combined flux in latest and established models = 4.16964 Jy
selfcal
! Performing phase self-cal
! Adding 23 model components to the UV plane model.
! The established model now contains 144 components and 4.16964 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.588350Jy  sigma=0.001551
! Fit after  self-cal, rms=0.588455Jy  sigma=0.001551
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.000744602 Jy
! Component: 100  -  total flux cleaned = 0.00144542 Jy
! Component: 150  -  total flux cleaned = 0.00193922 Jy
! Component: 200  -  total flux cleaned = 0.00224918 Jy
! Total flux subtracted in 200 components = 0.00224917 Jy
! Clean residual min=-0.004770 max=0.004210 Jy/beam
! Clean residual mean=0.000057 rms=0.001058 Jy/beam
! Combined flux in latest and established models = 4.17189 Jy
! Performing phase self-cal
! Adding 25 model components to the UV plane model.
! The established model now contains 149 components and 4.17189 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.588339Jy  sigma=0.001549
! Fit after  self-cal, rms=0.588396Jy  sigma=0.001549
! 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.588396Jy  sigma=0.001549
! Fit after  self-cal, rms=0.592957Jy  sigma=0.001549
clean clean_niter,clean_gain
! Inverting map and beam 
! Estimated beam: bmin=6.656 mas, bmaj=8.572 mas, bpa=9.567 degrees
! Estimated noise=447.643 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.00207871 Jy
! Component: 100  -  total flux cleaned = 0.00297533 Jy
! Component: 150  -  total flux cleaned = 0.00298151 Jy
! Component: 200  -  total flux cleaned = 0.00291379 Jy
! Total flux subtracted in 200 components = 0.00291379 Jy
! Clean residual min=-0.004021 max=0.005018 Jy/beam
! Clean residual mean=0.000128 rms=0.001441 Jy/beam
! Combined flux in latest and established models = 4.1748 Jy
selfcal
! Performing phase self-cal
! Adding 25 model components to the UV plane model.
! The established model now contains 169 components and 4.1748 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.592916Jy  sigma=0.001548
! Fit after  self-cal, rms=0.592969Jy  sigma=0.001547
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.000177887 Jy
! Component: 100  -  total flux cleaned = 0.000613375 Jy
! Component: 150  -  total flux cleaned = 0.000666163 Jy
! Component: 200  -  total flux cleaned = 0.000667632 Jy
! Total flux subtracted in 200 components = 0.000667632 Jy
! Clean residual min=-0.004112 max=0.004608 Jy/beam
! Clean residual mean=0.000122 rms=0.001419 Jy/beam
! Combined flux in latest and established models = 4.17547 Jy
! Performing phase self-cal
! Adding 26 model components to the UV plane model.
! The established model now contains 182 components and 4.17547 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.592956Jy  sigma=0.001547
! Fit after  self-cal, rms=0.592970Jy  sigma=0.001547
! 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.585 mas, bmaj=4.179 mas, bpa=-5.253 degrees
! Estimated noise=318.294 mJy/beam.
! restore: Substituting estimate of restoring beam from last 'invert'.
! Restoring with beam: 2.585 x 4.179 at -5.253 degrees (North through East)
! Clean map  min=-0.0041645  max=2.3827 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.592970Jy  sigma=0.001547
! Fit after  self-cal, rms=0.885311Jy  sigma=0.001249
! Inverting map and beam 
! Estimated beam: bmin=2.585 mas, bmaj=4.179 mas, bpa=-5.27 degrees
! Estimated noise=318.014 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = -0.00219383 Jy
! Component: 100  -  total flux cleaned = -0.00202853 Jy
! Component: 150  -  total flux cleaned = -0.0018764 Jy
! Component: 200  -  total flux cleaned = -0.00159991 Jy
! Total flux subtracted in 200 components = -0.00159991 Jy
! Clean residual min=-0.003791 max=0.003178 Jy/beam
! Clean residual mean=0.000027 rms=0.000866 Jy/beam
! Combined flux in latest and established models = 4.17387 Jy
! Performing phase self-cal
! Adding 19 model components to the UV plane model.
! The established model now contains 189 components and 4.17387 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.885242Jy  sigma=0.001247
! Fit after  self-cal, rms=0.885312Jy  sigma=0.001247
! Inverting map 
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = -8.09838e-06 Jy
! Component: 100  -  total flux cleaned = 0.000117947 Jy
! Component: 150  -  total flux cleaned = 0.000346591 Jy
! Component: 200  -  total flux cleaned = 0.000450564 Jy
! Total flux subtracted in 200 components = 0.000450564 Jy
! Clean residual min=-0.003399 max=0.003159 Jy/beam
! Clean residual mean=0.000026 rms=0.000845 Jy/beam
! Combined flux in latest and established models = 4.17432 Jy
! Performing phase self-cal
! Adding 22 model components to the UV plane model.
! The established model now contains 194 components and 4.17432 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.885275Jy  sigma=0.001246
! Fit after  self-cal, rms=0.885317Jy  sigma=0.001246
! 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.885317Jy  sigma=0.001246
! Fit after  self-cal, rms=0.900023Jy  sigma=0.001246
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=2.081 mas, bmaj=3.114 mas, bpa=-10.82 degrees
! Estimated noise=821.383 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 1.64813 Jy
! Component: 100  -  total flux cleaned = 2.41725 Jy
! Component: 150  -  total flux cleaned = 2.89404 Jy
! Component: 200  -  total flux cleaned = 3.2002 Jy
! Total flux subtracted in 200 components = 3.2002 Jy
! Clean residual min=-0.031379 max=0.164594 Jy/beam
! Clean residual mean=0.000255 rms=0.011712 Jy/beam
! Combined flux in latest and established models = 3.2002 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 17 model components to the UV plane model.
! The established model now contains 17 components and 3.2002 Jy
! Inverting map and beam 
! Estimated beam: bmin=2.586 mas, bmaj=4.181 mas, bpa=-5.258 degrees
! Estimated noise=318.045 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.336115 Jy
! Component: 100  -  total flux cleaned = 0.525836 Jy
! Component: 150  -  total flux cleaned = 0.644049 Jy
! Component: 200  -  total flux cleaned = 0.722049 Jy
! Total flux subtracted in 200 components = 0.722049 Jy
! Clean residual min=-0.010964 max=0.042658 Jy/beam
! Clean residual mean=0.000974 rms=0.005916 Jy/beam
! Combined flux in latest and established models = 3.92225 Jy
! Adding 51 model components to the UV plane model.
! The established model now contains 59 components and 3.92225 Jy
! Inverting map 
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.054354 Jy
! Component: 100  -  total flux cleaned = 0.0940389 Jy
! Component: 150  -  total flux cleaned = 0.124108 Jy
! Component: 200  -  total flux cleaned = 0.14774 Jy
! Total flux subtracted in 200 components = 0.14774 Jy
! Clean residual min=-0.004936 max=0.014063 Jy/beam
! Clean residual mean=0.000412 rms=0.002366 Jy/beam
! Combined flux in latest and established models = 4.06999 Jy
! Adding 64 model components to the UV plane model.
! The established model now contains 114 components and 4.06999 Jy
! Inverting map 
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.0188758 Jy
! Component: 100  -  total flux cleaned = 0.0340652 Jy
! Component: 150  -  total flux cleaned = 0.0463358 Jy
! Component: 200  -  total flux cleaned = 0.0562839 Jy
! Total flux subtracted in 200 components = 0.0562839 Jy
! Clean residual min=-0.003292 max=0.006414 Jy/beam
! Clean residual mean=0.000201 rms=0.001243 Jy/beam
! Combined flux in latest and established models = 4.12627 Jy
! Adding 43 model components to the UV plane model.
! The established model now contains 136 components and 4.12627 Jy
! Inverting map 
! Added new window around map position (0.5, 10).
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.00819619 Jy
! Component: 100  -  total flux cleaned = 0.0149316 Jy
! Component: 150  -  total flux cleaned = 0.0205061 Jy
! Component: 200  -  total flux cleaned = 0.0251975 Jy
! Total flux subtracted in 200 components = 0.0251975 Jy
! Clean residual min=-0.003081 max=0.003434 Jy/beam
! Clean residual mean=0.000108 rms=0.000893 Jy/beam
! Combined flux in latest and established models = 4.15147 Jy
! Adding 45 model components to the UV plane model.
! The established model now contains 159 components and 4.15147 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=6.656 mas, bmaj=8.576 mas, bpa=9.547 degrees
! Estimated noise=447.053 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.00814452 Jy
! Component: 100  -  total flux cleaned = 0.0127171 Jy
! Component: 150  -  total flux cleaned = 0.0156794 Jy
! Component: 200  -  total flux cleaned = 0.017695 Jy
! Total flux subtracted in 200 components = 0.017695 Jy
! Clean residual min=-0.002730 max=0.003861 Jy/beam
! Clean residual mean=0.000135 rms=0.001097 Jy/beam
! Combined flux in latest and established models = 4.16917 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 = 0.00131276 Jy
! Component: 100  -  total flux cleaned = 0.00187897 Jy
! Component: 150  -  total flux cleaned = 0.00230745 Jy
! Component: 200  -  total flux cleaned = 0.00263726 Jy
! Total flux subtracted in 200 components = 0.00263726 Jy
! Clean residual min=-0.002716 max=0.003634 Jy/beam
! Clean residual mean=0.000105 rms=0.001061 Jy/beam
! Combined flux in latest and established models = 4.1718 Jy
! Adding 105 model components to the UV plane model.
! The established model now contains 240 components and 4.1718 Jy
! Inverting map 
uvtaper 0,0
! No UV-taper is currently set.
clean
! Inverting map and beam 
! Estimated beam: bmin=2.586 mas, bmaj=4.181 mas, bpa=-5.258 degrees
! Estimated noise=318.045 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = -0.000682657 Jy
! Component: 100  -  total flux cleaned = -0.000151099 Jy
! Component: 150  -  total flux cleaned = 1.36667e-05 Jy
! Component: 200  -  total flux cleaned = 0.000246476 Jy
! Total flux subtracted in 200 components = 0.000246476 Jy
! Clean residual min=-0.003102 max=0.002653 Jy/beam
! Clean residual mean=0.000035 rms=0.000764 Jy/beam
! Combined flux in latest and established models = 4.17205 Jy
selfcal
! Performing phase self-cal
! Adding 22 model components to the UV plane model.
! The established model now contains 253 components and 4.17205 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.899887Jy  sigma=0.001242
! Fit after  self-cal, rms=0.900875Jy  sigma=0.001242
wmodel J1613+3412_S_1999_03_08_pus_map.mod
! Writing 253 model components to file: J1613+3412_S_1999_03_08_pus_map.mod
wobs J1613+3412_S_1999_03_08_pus_uvs.fits
! Writing UV FITS file: J1613+3412_S_1999_03_08_pus_uvs.fits
wwins J1613+3412_S_1999_03_08_pus_map.win
! wwins: Wrote 7 windows to J1613+3412_S_1999_03_08_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 = -7.03415e-05 Jy
! Component: 100  -  total flux cleaned = 3.09749e-05 Jy
! Component: 150  -  total flux cleaned = 8.00982e-05 Jy
! Component: 200  -  total flux cleaned = 8.07523e-05 Jy
! Component: 250  -  total flux cleaned = 0.00026539 Jy
! Component: 300  -  total flux cleaned = 0.000445101 Jy
! Component: 350  -  total flux cleaned = 0.000489059 Jy
! Component: 400  -  total flux cleaned = 0.000620014 Jy
! Component: 450  -  total flux cleaned = 0.000791309 Jy
! Component: 500  -  total flux cleaned = 0.000917408 Jy
! Component: 550  -  total flux cleaned = 0.00108347 Jy
! Component: 600  -  total flux cleaned = 0.00120542 Jy
! Component: 650  -  total flux cleaned = 0.00120565 Jy
! Component: 700  -  total flux cleaned = 0.00132581 Jy
! Component: 750  -  total flux cleaned = 0.00140524 Jy
! Component: 800  -  total flux cleaned = 0.00148352 Jy
! Component: 850  -  total flux cleaned = 0.00159837 Jy
! Component: 900  -  total flux cleaned = 0.00159827 Jy
! Component: 950  -  total flux cleaned = 0.00167351 Jy
! Component: 1000  -  total flux cleaned = 0.0016731 Jy
! Component: 1050  -  total flux cleaned = 0.00170956 Jy
! Component: 1100  -  total flux cleaned = 0.00167338 Jy
! Component: 1150  -  total flux cleaned = 0.0017452 Jy
! Component: 1200  -  total flux cleaned = 0.00167288 Jy
! Component: 1250  -  total flux cleaned = 0.00163705 Jy
! Component: 1300  -  total flux cleaned = 0.0016721 Jy
! Component: 1350  -  total flux cleaned = 0.00153301 Jy
! Component: 1400  -  total flux cleaned = 0.00153321 Jy
! Component: 1450  -  total flux cleaned = 0.00156739 Jy
! Component: 1500  -  total flux cleaned = 0.00156728 Jy
! Component: 1550  -  total flux cleaned = 0.00146656 Jy
! Component: 1600  -  total flux cleaned = 0.00160036 Jy
! Component: 1650  -  total flux cleaned = 0.00156681 Jy
! Component: 1700  -  total flux cleaned = 0.00156647 Jy
! Component: 1750  -  total flux cleaned = 0.00150132 Jy
! Component: 1800  -  total flux cleaned = 0.00153361 Jy
! Component: 1850  -  total flux cleaned = 0.00150171 Jy
! Component: 1900  -  total flux cleaned = 0.00150195 Jy
! Component: 1950  -  total flux cleaned = 0.00147035 Jy
! Component: 2000  -  total flux cleaned = 0.00153324 Jy
! Total flux subtracted in 2048 components = 0.0015331 Jy
! Clean residual min=-0.001748 max=0.001930 Jy/beam
! Clean residual mean=0.000032 rms=0.000580 Jy/beam
! Combined flux in latest and established models = 4.17359 Jy
keep
! Adding 158 model components to the UV plane model.
! The established model now contains 411 components and 4.17359 Jy
![Exited script file: muppet]
wmap "J1613+3412_S_1999_03_08_pus\_map.fits"
! Inverting map 
! restore: Substituting estimate of restoring beam from last 'invert'.
! Restoring with beam: 2.586 x 4.181 at -5.258 degrees (North through East)
! Clean map  min=-0.0021749  max=2.3833 Jy/beam
! Writing clean map to FITS file: J1613+3412_S_1999_03_08_pus_map.fits
float peak_flux
peak_flux = peak(flux,max)
print "The peak flux is",peak_flux
! The peak flux is 2.3833 
invert
! Inverting map 
float image_rms
image_rms = imstat(rms)
print "The final image rms is",image_rms
! The final image rms is 0.000580502 
device "J1613+3412_S_1999_03_08_pus\_map.eps/VPS"
! Attempting to open device: 'J1613+3412_S_1999_03_08_pus_map.eps/VPS'
loglevs 100*3*image_rms/peak_flux
! The new contour levels are:
!  -0.0730711 0.0730711 0.146142 0.292285 0.584569 1.16914 2.33828 4.67655 9.3531 18.7062 37.4124 74.8248
print "clev=",int(3*image_rms*10000)/10000
! clev= 0.0017 
print "peak=",int(1000*peak_flux)/1000
! peak= 2.383 
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.586 x 4.181 at -5.258 degrees (North through East)
! Clean map  min=-0.0021749  max=2.3833 Jy/beam
mapcolor color, 0.9
! Mapplot colormap: rainbow, contrast: 0.9 brightness: 0.5.
device "J1613+3412_S_1999_03_08_pus\_map.gif/vgif"
! Attempting to open device: 'J1613+3412_S_1999_03_08_pus_map.gif/vgif'
mapplot cln
quit
! Quitting program
! Log file J1613+3412_S_1999_03_08_pus_uvs.log closed on Tue Jan  8 18:29:28 2008