! Started logfile: J0927+3902_S_2000_12_04_pus_uvs.log on Wed Oct 17 17:03:22 2007
obs J0927+3902_S_2000_12_04_pus_uva.fits
! Reading UV FITS file: J0927+3902_S_2000_12_04_pus_uva.fits
! AN table 1: 597 integrations on 190 of 190 possible baselines.
! AN table 2: 58 integrations on 190 of 190 possible baselines.
! AN table 3: 145 integrations on 190 of 190 possible baselines.
! AN table 4: 246 integrations on 190 of 190 possible baselines.
! Apparent sampling: 0.129627 visibilities/baseline/integration-bin.
! *** This seems a bit low - see "help observe" on the binwid argument.
! Found source: J0927+3902
! 
! 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 2170 lines of history.
! 
! Reading 103048 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 J0927+3902_S_2000_12_04_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 8000 telescope corrections were flagged in sub-array 1.
!  A total of 637 telescope corrections were flagged in sub-array 2.
!  A total of 1820 telescope corrections were flagged in sub-array 3.
!  A total of 4723 telescope corrections were flagged in sub-array 4.
! 
! Correcting IF 2.
!  A total of 8000 telescope corrections were flagged in sub-array 1.
!  A total of 637 telescope corrections were flagged in sub-array 2.
!  A total of 1820 telescope corrections were flagged in sub-array 3.
!  A total of 4723 telescope corrections were flagged in sub-array 4.
! 
! Correcting IF 3.
!  A total of 8074 telescope corrections were flagged in sub-array 1.
!  A total of 637 telescope corrections were flagged in sub-array 2.
!  A total of 1820 telescope corrections were flagged in sub-array 3.
!  A total of 4723 telescope corrections were flagged in sub-array 4.
! 
! Correcting IF 4.
!  A total of 8000 telescope corrections were flagged in sub-array 1.
!  A total of 637 telescope corrections were flagged in sub-array 2.
!  A total of 1820 telescope corrections were flagged in sub-array 3.
!  A total of 4723 telescope corrections were flagged in sub-array 4.
! 
! Fit before self-cal, rms=3.171712Jy  sigma=0.028699
! Fit after  self-cal, rms=2.775977Jy  sigma=0.025547
! 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.928 mas, bmaj=2.692 mas, bpa=-3.84 degrees
! Estimated noise=642.172 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 = 2.52151 Jy
! Component: 100  -  total flux cleaned = 3.27253 Jy
! Total flux subtracted in 100 components = 3.27253 Jy
! Clean residual min=-0.058989 max=0.340393 Jy/beam
! Clean residual mean=0.000388 rms=0.017689 Jy/beam
! Combined flux in latest and established models = 3.27253 Jy
! Performing phase self-cal
! Adding 6 model components to the UV plane model.
! The established model now contains 6 components and 3.27253 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.986634Jy  sigma=0.008990
! Fit after  self-cal, rms=0.986279Jy  sigma=0.008988
! Inverting map 
! clean: niter=100  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.371902 Jy
! Component: 100  -  total flux cleaned = 0.589087 Jy
! Total flux subtracted in 100 components = 0.589087 Jy
! Clean residual min=-0.036200 max=0.115035 Jy/beam
! Clean residual mean=0.000131 rms=0.010723 Jy/beam
! Combined flux in latest and established models = 3.86162 Jy
! Performing phase self-cal
! Adding 12 model components to the UV plane model.
! The established model now contains 14 components and 3.86162 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.749917Jy  sigma=0.006395
! Fit after  self-cal, rms=0.748552Jy  sigma=0.006384
! Inverting map 
! clean: niter=100  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.143171 Jy
! Component: 100  -  total flux cleaned = 0.23852 Jy
! Total flux subtracted in 100 components = 0.23852 Jy
! Clean residual min=-0.035509 max=0.052091 Jy/beam
! Clean residual mean=0.000029 rms=0.008963 Jy/beam
! Combined flux in latest and established models = 4.10014 Jy
! Performing phase self-cal
! Adding 9 model components to the UV plane model.
! The established model now contains 18 components and 4.10014 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.706125Jy  sigma=0.005811
! Fit after  self-cal, rms=0.705937Jy  sigma=0.005809
! Inverting map 
! clean: niter=100  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.0668347 Jy
! Component: 100  -  total flux cleaned = 0.11247 Jy
! Total flux subtracted in 100 components = 0.11247 Jy
! Clean residual min=-0.034883 max=0.033080 Jy/beam
! Clean residual mean=-0.000019 rms=0.008478 Jy/beam
! Combined flux in latest and established models = 4.21261 Jy
! Performing phase self-cal
! Adding 13 model components to the UV plane model.
! The established model now contains 24 components and 4.21261 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.697906Jy  sigma=0.005662
! Fit after  self-cal, rms=0.697836Jy  sigma=0.005661
! 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.587 mas, bmaj=3.775 mas, bpa=-5.455 degrees
! Estimated noise=267.724 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.0573267 Jy
! Component: 100  -  total flux cleaned = 0.086119 Jy
! Component: 150  -  total flux cleaned = 0.101013 Jy
! Component: 200  -  total flux cleaned = 0.105369 Jy
! Total flux subtracted in 200 components = 0.105369 Jy
! Clean residual min=-0.047776 max=0.032051 Jy/beam
! Clean residual mean=-0.001761 rms=0.009285 Jy/beam
! Combined flux in latest and established models = 4.31797 Jy
! Performing phase self-cal
! Adding 13 model components to the UV plane model.
! The established model now contains 31 components and 4.31798 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.696600Jy  sigma=0.005596
! Fit after  self-cal, rms=0.696580Jy  sigma=0.005596
! Inverting map 
print "************** FINISHED NATURAL WEIGHTING CLEAN **************"
! ************** FINISHED NATURAL WEIGHTING CLEAN ************** 
! 
gscale true
! Performing overall amplitude self-cal
! 
! Correcting IF 1.
!  A total of 534 telescope corrections were flagged in sub-array 1.
!  Telescope amplitude corrections in sub-array 1:
!   BR        1.01     FD        1.01     GC        0.95     GG        1.00*    
!   HH        1.08     HN        1.01     KK        1.05     KP        1.09     
!   LA        1.06     MA        1.86     MC        1.06     MK        1.04     
!   NL        1.00     NY        1.01     OV        1.01     PT        1.01     
!   SC        1.05     TS        1.09     WF        1.04     WZ        1.06     
! 
!  A total of 3 telescope corrections were flagged in sub-array 2.
!  Telescope amplitude corrections in sub-array 2:
!   BR        0.98     FD        0.95     GC        0.97     GG        1.00*    
!   HH        1.00*    HN        0.88     KK        1.01     KP        0.91     
!   LA        1.02     MA        1.00*    MC        1.00*    MK        0.98     
!   NL        0.95     NY        1.06     OV        0.96     PT        0.97     
!   SC        1.11     TS        1.06     WF        1.30     WZ        1.00*    
! 
!  A total of 33 telescope corrections were flagged in sub-array 3.
!  Telescope amplitude corrections in sub-array 3:
!   BR        1.00     FD        0.99     GC        1.02     GG        1.00*    
!   HH        1.29     HN        1.00     KK        1.00*    KP        1.04     
!   LA        1.03     MA        1.02     MC        1.06     MK        1.07     
!   NL        0.97     NY        1.00     OV        0.99     PT        0.99     
!   SC        1.04     TS        1.04     WF        0.92     WZ        1.04     
! 
!  A total of 6 telescope corrections were flagged in sub-array 4.
!  Telescope amplitude corrections in sub-array 4:
!   BR        1.00*    FD        1.00*    GC        1.00*    GG        1.00*    
!   HH        1.10     HN        1.00*    KK        1.00*    KP        1.00*    
!   LA        1.00*    MA        0.61     MC        0.93     MK        1.00*    
!   NL        1.00*    NY        1.04     OV        1.00*    PT        1.00*    
!   SC        1.00*    TS        1.08     WF        1.00*    WZ        1.03     
! 
! 
! Correcting IF 2.
!  A total of 534 telescope corrections were flagged in sub-array 1.
!  Telescope amplitude corrections in sub-array 1:
!   BR        1.01     FD        1.01     GC        0.96     GG        1.00*    
!   HH        1.09     HN        1.00     KK        1.04     KP        1.04     
!   LA        1.01     MA        1.18     MC        1.10     MK        1.04     
!   NL        0.97     NY        1.00     OV        0.97     PT        1.02     
!   SC        1.01     TS        1.07     WF        1.14     WZ        1.04     
! 
!  A total of 3 telescope corrections were flagged in sub-array 2.
!  Telescope amplitude corrections in sub-array 2:
!   BR        0.98     FD        0.97     GC        1.00     GG        1.00*    
!   HH        1.00*    HN        0.89     KK        1.05     KP        0.95     
!   LA        0.98     MA        1.00*    MC        1.00*    MK        0.98     
!   NL        0.91     NY        0.99     OV        0.92     PT        0.98     
!   SC        1.07     TS        1.05     WF        1.35     WZ        1.00*    
! 
!  A total of 33 telescope corrections were flagged in sub-array 3.
!  Telescope amplitude corrections in sub-array 3:
!   BR        1.00     FD        1.00     GC        1.03     GG        1.00*    
!   HH        1.02     HN        0.98     KK        1.00*    KP        0.99     
!   LA        0.99     MA        1.24     MC        0.95     MK        1.08     
!   NL        0.94     NY        0.99     OV        0.96     PT        0.99     
!   SC        1.00     TS        1.08     WF        1.00     WZ        1.02     
! 
!  A total of 6 telescope corrections were flagged in sub-array 4.
!  Telescope amplitude corrections in sub-array 4:
!   BR        1.00*    FD        1.00*    GC        1.00*    GG        1.00*    
!   HH        1.10     HN        1.00*    KK        1.00*    KP        1.00*    
!   LA        1.00*    MA        0.93     MC        1.06     MK        1.00*    
!   NL        1.00*    NY        1.03     OV        1.00*    PT        1.00*    
!   SC        1.00*    TS        1.07     WF        1.00*    WZ        1.00     
! 
! 
! Correcting IF 3.
!  A total of 537 telescope corrections were flagged in sub-array 1.
!  Telescope amplitude corrections in sub-array 1:
!   BR        0.96     FD        1.07     GC        0.98     GG        1.00*    
!   HH        1.01     HN        0.98     KK        0.95     KP        1.06     
!   LA        1.05     MA        0.87     MC        1.20     MK        0.98     
!   NL        1.20     NY        0.95     OV        1.01     PT        0.98     
!   SC        0.99     TS        1.04     WF        1.04     WZ        0.89     
! 
!  A total of 3 telescope corrections were flagged in sub-array 2.
!  Telescope amplitude corrections in sub-array 2:
!   BR        0.94     FD        0.97     GC        0.95     GG        1.00*    
!   HH        1.00*    HN        0.91     KK        1.09     KP        1.01     
!   LA        1.00     MA        1.00*    MC        1.00*    MK        0.91     
!   NL        0.99     NY        0.96     OV        0.99     PT        0.98     
!   SC        1.05     TS        1.00     WF        0.97     WZ        1.00*    
! 
!  A total of 33 telescope corrections were flagged in sub-array 3.
!  Telescope amplitude corrections in sub-array 3:
!   BR        0.88     FD        0.90     GC        1.04     GG        1.00*    
!   HH        1.00     HN        1.07     KK        1.00*    KP        0.90     
!   LA        0.93     MA        1.04     MC        0.86     MK        0.99     
!   NL        1.03     NY        0.95     OV        1.02     PT        0.91     
!   SC        0.99     TS        1.00     WF        1.04     WZ        0.86     
! 
!  A total of 6 telescope corrections were flagged in sub-array 4.
!  Telescope amplitude corrections in sub-array 4:
!   BR        1.00*    FD        1.00*    GC        1.00*    GG        1.00*    
!   HH        1.06     HN        1.00*    KK        1.00*    KP        1.00*    
!   LA        1.00*    MA        0.95     MC        0.76     MK        1.00*    
!   NL        1.00*    NY        0.99     OV        1.00*    PT        1.00*    
!   SC        1.00*    TS        1.00     WF        1.00*    WZ        0.84     
! 
! 
! Correcting IF 4.
!  A total of 534 telescope corrections were flagged in sub-array 1.
!  Telescope amplitude corrections in sub-array 1:
!   BR        0.95     FD        0.97     GC        1.02     GG        1.00*    
!   HH        1.00     HN        0.97     KK        1.00     KP        0.99     
!   LA        0.97     MA        1.14     MC        1.09     MK        1.01     
!   NL        0.96     NY        0.97     OV        0.97     PT        0.99     
!   SC        1.02     TS        1.03     WF        1.01     WZ        1.05     
! 
!  A total of 3 telescope corrections were flagged in sub-array 2.
!  Telescope amplitude corrections in sub-array 2:
!   BR        0.92     FD        0.93     GC        1.06     GG        1.00*    
!   HH        1.00*    HN        0.87     KK        0.92     KP        0.92     
!   LA        0.94     MA        1.00*    MC        1.00*    MK        0.94     
!   NL        0.92     NY        1.00     OV        0.93     PT        0.95     
!   SC        1.08     TS        1.01     WF        1.03     WZ        1.00*    
! 
!  A total of 33 telescope corrections were flagged in sub-array 3.
!  Telescope amplitude corrections in sub-array 3:
!   BR        0.94     FD        0.96     GC        0.99     GG        1.00*    
!   HH        1.00     HN        0.96     KK        1.00*    KP        0.96     
!   LA        0.96     MA        0.93     MC        1.51     MK        1.02     
!   NL        0.94     NY        0.96     OV        0.96     PT        0.96     
!   SC        1.01     TS        0.98     WF        0.90     WZ        1.00     
! 
!  A total of 6 telescope corrections were flagged in sub-array 4.
!  Telescope amplitude corrections in sub-array 4:
!   BR        1.00*    FD        1.00*    GC        1.00*    GG        1.00*    
!   HH        1.05     HN        1.00*    KK        1.00*    KP        1.00*    
!   LA        1.00*    MA        0.97     MC        0.65     MK        1.00*    
!   NL        1.00*    NY        1.02     OV        1.00*    PT        1.00*    
!   SC        1.00*    TS        1.02     WF        1.00*    WZ        1.02     
! 
! 
! Fit before self-cal, rms=0.696580Jy  sigma=0.005596
! Fit after  self-cal, rms=0.645479Jy  sigma=0.004868
dynam = dynam - 0.5
flux_cutoff = imstat(rms) * dynam
! Inverting map and beam 
! Estimated beam: bmin=2.603 mas, bmaj=3.891 mas, bpa=-6.857 degrees
! Estimated noise=272.455 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.0158303 Jy
! Component: 100  -  total flux cleaned = -0.0206842 Jy
! Component: 150  -  total flux cleaned = -0.0224478 Jy
! Component: 200  -  total flux cleaned = -0.0239833 Jy
! Total flux subtracted in 200 components = -0.0239833 Jy
! Clean residual min=-0.034784 max=0.025376 Jy/beam
! Clean residual mean=-0.000411 rms=0.006776 Jy/beam
! Combined flux in latest and established models = 4.29399 Jy
! Performing phase self-cal
! Adding 9 model components to the UV plane model.
! The established model now contains 35 components and 4.29399 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.644660Jy  sigma=0.004867
! Fit after  self-cal, rms=0.644863Jy  sigma=0.004866
! 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.644863Jy  sigma=0.004866
! Fit after  self-cal, rms=0.555158Jy  sigma=0.003892
dynam = dynam - 0.75
clean clean_niter,clean_gain
! Inverting map and beam 
! Estimated beam: bmin=2.607 mas, bmaj=3.898 mas, bpa=-6.547 degrees
! Estimated noise=272.915 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.000279178 Jy
! Component: 100  -  total flux cleaned = -0.00110608 Jy
! Component: 150  -  total flux cleaned = -0.00226963 Jy
! Component: 200  -  total flux cleaned = -0.00322802 Jy
! Total flux subtracted in 200 components = -0.00322802 Jy
! Clean residual min=-0.010606 max=0.024612 Jy/beam
! Clean residual mean=-0.000040 rms=0.002407 Jy/beam
! Combined flux in latest and established models = 4.29076 Jy
selfcal
! Performing phase self-cal
! Adding 4 model components to the UV plane model.
! The established model now contains 36 components and 4.29076 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.554781Jy  sigma=0.003889
! Fit after  self-cal, rms=0.555889Jy  sigma=0.003887
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 (4, -0.5).
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.0146957 Jy
! Component: 100  -  total flux cleaned = 0.0127275 Jy
! Component: 150  -  total flux cleaned = 0.0111965 Jy
! Component: 200  -  total flux cleaned = 0.0107078 Jy
! Total flux subtracted in 200 components = 0.0107078 Jy
! Clean residual min=-0.008709 max=0.009814 Jy/beam
! Clean residual mean=-0.000137 rms=0.002107 Jy/beam
! Combined flux in latest and established models = 4.30147 Jy
! Performing phase self-cal
! Adding 17 model components to the UV plane model.
! The established model now contains 50 components and 4.30147 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.555029Jy  sigma=0.003880
! Fit after  self-cal, rms=0.554868Jy  sigma=0.003879
! 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.554868Jy  sigma=0.003879
! Fit after  self-cal, rms=0.557337Jy  sigma=0.003822
clean clean_niter,clean_gain
! Inverting map and beam 
! Estimated beam: bmin=2.611 mas, bmaj=3.903 mas, bpa=-6.508 degrees
! Estimated noise=273.11 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.0046578 Jy
! Component: 100  -  total flux cleaned = 0.00396749 Jy
! Component: 150  -  total flux cleaned = 0.00343939 Jy
! Component: 200  -  total flux cleaned = 0.00300322 Jy
! Total flux subtracted in 200 components = 0.00300322 Jy
! Clean residual min=-0.007181 max=0.010156 Jy/beam
! Clean residual mean=-0.000200 rms=0.001738 Jy/beam
! Combined flux in latest and established models = 4.30447 Jy
selfcal
! Performing phase self-cal
! Adding 17 model components to the UV plane model.
! The established model now contains 56 components and 4.30447 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.556924Jy  sigma=0.003818
! Fit after  self-cal, rms=0.556923Jy  sigma=0.003818
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 (-3, 0.5).
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.000318702 Jy
! Component: 100  -  total flux cleaned = -0.000233976 Jy
! Component: 150  -  total flux cleaned = -0.000724109 Jy
! Component: 200  -  total flux cleaned = -0.00137275 Jy
! Total flux subtracted in 200 components = -0.00137275 Jy
! Clean residual min=-0.006266 max=0.006114 Jy/beam
! Clean residual mean=-0.000189 rms=0.001644 Jy/beam
! Combined flux in latest and established models = 4.3031 Jy
! Performing phase self-cal
! Adding 22 model components to the UV plane model.
! The established model now contains 75 components and 4.3031 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.556610Jy  sigma=0.003816
! Fit after  self-cal, rms=0.556583Jy  sigma=0.003816
! 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.556583Jy  sigma=0.003816
! Fit after  self-cal, rms=0.556919Jy  sigma=0.003814
clean clean_niter,clean_gain
! Inverting map and beam 
! Estimated beam: bmin=8.013 mas, bmaj=8.465 mas, bpa=-29.25 degrees
! Estimated noise=356.019 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.000817602 Jy
! Component: 100  -  total flux cleaned = -6.74168e-05 Jy
! Component: 150  -  total flux cleaned = -0.000960816 Jy
! Component: 200  -  total flux cleaned = -0.00163122 Jy
! Total flux subtracted in 200 components = -0.00163122 Jy
! Clean residual min=-0.006907 max=0.007378 Jy/beam
! Clean residual mean=-0.000375 rms=0.002037 Jy/beam
! Combined flux in latest and established models = 4.30147 Jy
selfcal
! Performing phase self-cal
! Adding 17 model components to the UV plane model.
! The established model now contains 89 components and 4.30147 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.556875Jy  sigma=0.003813
! Fit after  self-cal, rms=0.556856Jy  sigma=0.003813
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 = 7.42311e-05 Jy
! Component: 100  -  total flux cleaned = -0.000426907 Jy
! Component: 150  -  total flux cleaned = -0.000777957 Jy
! Component: 200  -  total flux cleaned = -0.000965268 Jy
! Total flux subtracted in 200 components = -0.000965268 Jy
! Clean residual min=-0.006676 max=0.007279 Jy/beam
! Clean residual mean=-0.000352 rms=0.001985 Jy/beam
! Combined flux in latest and established models = 4.3005 Jy
! Performing phase self-cal
! Adding 22 model components to the UV plane model.
! The established model now contains 102 components and 4.3005 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.556839Jy  sigma=0.003813
! Fit after  self-cal, rms=0.556831Jy  sigma=0.003813
! 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.612 mas, bmaj=3.905 mas, bpa=-6.487 degrees
! Estimated noise=273.19 mJy/beam.
! restore: Substituting estimate of restoring beam from last 'invert'.
! Restoring with beam: 2.612 x 3.905 at -6.487 degrees (North through East)
! Clean map  min=-0.006528  max=3.6044 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.556831Jy  sigma=0.003813
! Fit after  self-cal, rms=0.771692Jy  sigma=0.002858
! Inverting map and beam 
! Estimated beam: bmin=2.614 mas, bmaj=3.906 mas, bpa=-6.493 degrees
! Estimated noise=273.088 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = -0.00294778 Jy
! Component: 100  -  total flux cleaned = -0.00343006 Jy
! Component: 150  -  total flux cleaned = -0.00343606 Jy
! Component: 200  -  total flux cleaned = -0.00361934 Jy
! Total flux subtracted in 200 components = -0.00361934 Jy
! Clean residual min=-0.003960 max=0.003800 Jy/beam
! Clean residual mean=-0.000181 rms=0.001009 Jy/beam
! Combined flux in latest and established models = 4.29688 Jy
! Performing phase self-cal
! Adding 12 model components to the UV plane model.
! The established model now contains 106 components and 4.29689 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.771487Jy  sigma=0.002856
! Fit after  self-cal, rms=0.771482Jy  sigma=0.002856
! Inverting map 
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = -0.000319803 Jy
! Component: 100  -  total flux cleaned = 0.000454365 Jy
! Component: 150  -  total flux cleaned = 0.000871519 Jy
! Component: 200  -  total flux cleaned = 0.00112581 Jy
! Total flux subtracted in 200 components = 0.00112581 Jy
! Clean residual min=-0.004217 max=0.003634 Jy/beam
! Clean residual mean=-0.000191 rms=0.000996 Jy/beam
! Combined flux in latest and established models = 4.29801 Jy
! Performing phase self-cal
! Adding 19 model components to the UV plane model.
! The established model now contains 110 components and 4.29801 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.771410Jy  sigma=0.002855
! Fit after  self-cal, rms=0.771402Jy  sigma=0.002855
! 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.771402Jy  sigma=0.002855
! Fit after  self-cal, rms=0.771194Jy  sigma=0.002854
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.943 mas, bmaj=2.73 mas, bpa=-4.295 degrees
! Estimated noise=662.046 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 2.56612 Jy
! Component: 100  -  total flux cleaned = 3.31205 Jy
! Component: 150  -  total flux cleaned = 3.67929 Jy
! Component: 200  -  total flux cleaned = 3.87595 Jy
! Total flux subtracted in 200 components = 3.87595 Jy
! Clean residual min=-0.019657 max=0.101246 Jy/beam
! Clean residual mean=0.000167 rms=0.005753 Jy/beam
! Combined flux in latest and established models = 3.87595 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 12 model components to the UV plane model.
! The established model now contains 12 components and 3.87595 Jy
! Inverting map and beam 
! Estimated beam: bmin=2.616 mas, bmaj=3.91 mas, bpa=-6.495 degrees
! Estimated noise=273.085 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.208665 Jy
! Component: 100  -  total flux cleaned = 0.304717 Jy
! Component: 150  -  total flux cleaned = 0.358341 Jy
! Component: 200  -  total flux cleaned = 0.389485 Jy
! Total flux subtracted in 200 components = 0.389485 Jy
! Clean residual min=-0.005895 max=0.016003 Jy/beam
! Clean residual mean=0.000073 rms=0.001985 Jy/beam
! Combined flux in latest and established models = 4.26543 Jy
! Adding 31 model components to the UV plane model.
! The established model now contains 35 components and 4.26543 Jy
! Inverting map 
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.0193228 Jy
! Component: 100  -  total flux cleaned = 0.0268438 Jy
! Component: 150  -  total flux cleaned = 0.0299359 Jy
! Component: 200  -  total flux cleaned = 0.0323011 Jy
! Total flux subtracted in 200 components = 0.0323011 Jy
! Clean residual min=-0.006362 max=0.006207 Jy/beam
! Clean residual mean=-0.000213 rms=0.001317 Jy/beam
! Combined flux in latest and established models = 4.29774 Jy
! Adding 22 model components to the UV plane model.
! The established model now contains 44 components and 4.29774 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.01 mas, bmaj=8.466 mas, bpa=-28.67 degrees
! Estimated noise=355.41 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.00389835 Jy
! Component: 100  -  total flux cleaned = 0.00348359 Jy
! Component: 150  -  total flux cleaned = 0.00279214 Jy
! Component: 200  -  total flux cleaned = 0.00221446 Jy
! Total flux subtracted in 200 components = 0.00221446 Jy
! Clean residual min=-0.006042 max=0.004689 Jy/beam
! Clean residual mean=-0.000648 rms=0.001603 Jy/beam
! Combined flux in latest and established models = 4.29995 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.000484298 Jy
! Component: 100  -  total flux cleaned = -0.000907079 Jy
! Component: 150  -  total flux cleaned = -0.00136439 Jy
! Component: 200  -  total flux cleaned = -0.00168422 Jy
! Total flux subtracted in 200 components = -0.00168422 Jy
! Clean residual min=-0.005703 max=0.004426 Jy/beam
! Clean residual mean=-0.000608 rms=0.001509 Jy/beam
! Combined flux in latest and established models = 4.29827 Jy
! Adding 36 model components to the UV plane model.
! The established model now contains 74 components and 4.29826 Jy
! Inverting map 
uvtaper 0,0
! No UV-taper is currently set.
clean
! Inverting map and beam 
! Estimated beam: bmin=2.616 mas, bmaj=3.91 mas, bpa=-6.495 degrees
! Estimated noise=273.085 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = -0.0038908 Jy
! Component: 100  -  total flux cleaned = -0.00260965 Jy
! Component: 150  -  total flux cleaned = -0.00150652 Jy
! Component: 200  -  total flux cleaned = -0.000521427 Jy
! Total flux subtracted in 200 components = -0.000521427 Jy
! Clean residual min=-0.004689 max=0.004144 Jy/beam
! Clean residual mean=-0.000214 rms=0.001075 Jy/beam
! Combined flux in latest and established models = 4.29774 Jy
selfcal
! Performing phase self-cal
! Adding 9 model components to the UV plane model.
! The established model now contains 77 components and 4.29774 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.771696Jy  sigma=0.002858
! Fit after  self-cal, rms=0.771684Jy  sigma=0.002858
wmodel J0927+3902_S_2000_12_04_pus_map.mod
! Writing 77 model components to file: J0927+3902_S_2000_12_04_pus_map.mod
wobs J0927+3902_S_2000_12_04_pus_uvs.fits
! Writing UV FITS file: J0927+3902_S_2000_12_04_pus_uvs.fits
wwins J0927+3902_S_2000_12_04_pus_map.win
! wwins: Wrote 3 windows to J0927+3902_S_2000_12_04_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 = -5.61497e-05 Jy
! Component: 100  -  total flux cleaned = -0.000768056 Jy
! Component: 150  -  total flux cleaned = -0.00114357 Jy
! Component: 200  -  total flux cleaned = -0.00142983 Jy
! Component: 250  -  total flux cleaned = -0.00156868 Jy
! Component: 300  -  total flux cleaned = -0.00177206 Jy
! Component: 350  -  total flux cleaned = -0.00197024 Jy
! Component: 400  -  total flux cleaned = -0.00209949 Jy
! Component: 450  -  total flux cleaned = -0.00222611 Jy
! Component: 500  -  total flux cleaned = -0.00228799 Jy
! Component: 550  -  total flux cleaned = -0.00234974 Jy
! Component: 600  -  total flux cleaned = -0.00241098 Jy
! Component: 650  -  total flux cleaned = -0.00247168 Jy
! Component: 700  -  total flux cleaned = -0.00259089 Jy
! Component: 750  -  total flux cleaned = -0.00270802 Jy
! Component: 800  -  total flux cleaned = -0.00265021 Jy
! Component: 850  -  total flux cleaned = -0.00288038 Jy
! Component: 900  -  total flux cleaned = -0.00305089 Jy
! Component: 950  -  total flux cleaned = -0.00316291 Jy
! Component: 1000  -  total flux cleaned = -0.00338634 Jy
! Component: 1050  -  total flux cleaned = -0.0034418 Jy
! Component: 1100  -  total flux cleaned = -0.00360653 Jy
! Component: 1150  -  total flux cleaned = -0.00376988 Jy
! Component: 1200  -  total flux cleaned = -0.00387763 Jy
! Component: 1250  -  total flux cleaned = -0.00403841 Jy
! Component: 1300  -  total flux cleaned = -0.00425158 Jy
! Component: 1350  -  total flux cleaned = -0.00435766 Jy
! Component: 1400  -  total flux cleaned = -0.00467228 Jy
! Component: 1450  -  total flux cleaned = -0.00477606 Jy
! Component: 1500  -  total flux cleaned = -0.00498221 Jy
! Component: 1550  -  total flux cleaned = -0.00523794 Jy
! Component: 1600  -  total flux cleaned = -0.00539049 Jy
! Component: 1650  -  total flux cleaned = -0.00564273 Jy
! Component: 1700  -  total flux cleaned = -0.00574249 Jy
! Component: 1750  -  total flux cleaned = -0.00594205 Jy
! Component: 1800  -  total flux cleaned = -0.0061403 Jy
! Component: 1850  -  total flux cleaned = -0.00628817 Jy
! Component: 1900  -  total flux cleaned = -0.0065808 Jy
! Component: 1950  -  total flux cleaned = -0.0066296 Jy
! Component: 2000  -  total flux cleaned = -0.00687093 Jy
! Total flux subtracted in 2048 components = -0.00706288 Jy
! Clean residual min=-0.002840 max=0.002395 Jy/beam
! Clean residual mean=-0.000157 rms=0.000868 Jy/beam
! Combined flux in latest and established models = 4.29068 Jy
keep
! Adding 122 model components to the UV plane model.
! The established model now contains 190 components and 4.29068 Jy
![Exited script file: muppet]
wmap "J0927+3902_S_2000_12_04_pus\_map.fits"
! Inverting map 
! restore: Substituting estimate of restoring beam from last 'invert'.
! Restoring with beam: 2.616 x 3.91 at -6.495 degrees (North through East)
! Clean map  min=-0.0044977  max=3.6041 Jy/beam
! Writing clean map to FITS file: J0927+3902_S_2000_12_04_pus_map.fits
float peak_flux
peak_flux = peak(flux,max)
print "The peak flux is",peak_flux
! The peak flux is 3.60413 
invert
! Inverting map 
float image_rms
image_rms = imstat(rms)
print "The final image rms is",image_rms
! The final image rms is 0.000869079 
device "J0927+3902_S_2000_12_04_pus\_map.eps/VPS"
! Attempting to open device: 'J0927+3902_S_2000_12_04_pus_map.eps/VPS'
loglevs 100*3*image_rms/peak_flux
! The new contour levels are:
!  -0.0723402 0.0723402 0.14468 0.289361 0.578722 1.15744 2.31489 4.62977 9.25955 18.5191 37.0382 74.0764
print "clev=",int(3*image_rms*10000)/10000
! clev= 0.0026 
print "peak=",int(1000*peak_flux)/1000
! peak= 3.604 
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.616 x 3.91 at -6.495 degrees (North through East)
! Clean map  min=-0.0044977  max=3.6041 Jy/beam
mapcolor color, 0.9
! Mapplot colormap: rainbow, contrast: 0.9 brightness: 0.5.
device "J0927+3902_S_2000_12_04_pus\_map.gif/vgif"
! Attempting to open device: 'J0927+3902_S_2000_12_04_pus_map.gif/vgif'
mapplot cln
quit
! Quitting program
! Log file J0927+3902_S_2000_12_04_pus_uvs.log closed on Wed Oct 17 17:04:04 2007