! Started logfile: J2158-1501_S_2003_09_17_pus_uvs.log on Wed May 23 18:06:30 2007
obs J2158-1501_S_2003_09_17_pus_uva.fits
! Reading UV FITS file: J2158-1501_S_2003_09_17_pus_uva.fits
! AN table 1: 64 integrations on 120 of 120 possible baselines.
! AN table 2: 143 integrations on 120 of 120 possible baselines.
! AN table 3: 200 integrations on 120 of 120 possible baselines.
! AN table 4: 20 integrations on 120 of 120 possible baselines.
! AN table 5: 14 integrations on 120 of 120 possible baselines.
! Apparent sampling: 0.112245 visibilities/baseline/integration-bin.
! *** This seems a bit low - see "help observe" on the binwid argument.
! Found source: J2158-1501
! 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 1736 lines of history.
! 
! Reading 23760 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 705 telescope corrections were flagged in sub-array 1.
!  A total of 1548 telescope corrections were flagged in sub-array 2.
!  A total of 2361 telescope corrections were flagged in sub-array 3.
!  A total of 320 telescope corrections were flagged in sub-array 4.
!  A total of 194 telescope corrections were flagged in sub-array 5.
! 
! Correcting IF 2.
!  A total of 702 telescope corrections were flagged in sub-array 1.
!  A total of 1543 telescope corrections were flagged in sub-array 2.
!  A total of 2364 telescope corrections were flagged in sub-array 3.
!  A total of 320 telescope corrections were flagged in sub-array 4.
!  A total of 191 telescope corrections were flagged in sub-array 5.
! 
! Correcting IF 3.
!  A total of 702 telescope corrections were flagged in sub-array 1.
!  A total of 1544 telescope corrections were flagged in sub-array 2.
!  A total of 2361 telescope corrections were flagged in sub-array 3.
!  A total of 320 telescope corrections were flagged in sub-array 4.
!  A total of 194 telescope corrections were flagged in sub-array 5.
! 
! Correcting IF 4.
!  A total of 702 telescope corrections were flagged in sub-array 1.
!  A total of 1574 telescope corrections were flagged in sub-array 2.
!  A total of 2374 telescope corrections were flagged in sub-array 3.
!  A total of 320 telescope corrections were flagged in sub-array 4.
!  A total of 224 telescope corrections were flagged in sub-array 5.
! 
! Fit before self-cal, rms=1.320906Jy  sigma=0.008989
! Fit after  self-cal, rms=0.798459Jy  sigma=0.005440
! 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.167 mas, bmaj=8.742 mas, bpa=-1.344 degrees
! Estimated noise=1280.41 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.08 Jy
! Component: 100  -  total flux cleaned = 1.50217 Jy
! Total flux subtracted in 100 components = 1.50217 Jy
! Clean residual min=-0.047164 max=0.184363 Jy/beam
! Clean residual mean=0.000145 rms=0.016281 Jy/beam
! Combined flux in latest and established models = 1.50217 Jy
! Performing phase self-cal
! Adding 8 model components to the UV plane model.
! The established model now contains 8 components and 1.50217 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.441447Jy  sigma=0.002885
! Fit after  self-cal, rms=0.440967Jy  sigma=0.002883
! Inverting map 
! clean: niter=100  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.193625 Jy
! Component: 100  -  total flux cleaned = 0.292141 Jy
! Total flux subtracted in 100 components = 0.292141 Jy
! Clean residual min=-0.030829 max=0.050085 Jy/beam
! Clean residual mean=0.000005 rms=0.007324 Jy/beam
! Combined flux in latest and established models = 1.79432 Jy
! Performing phase self-cal
! Adding 25 model components to the UV plane model.
! The established model now contains 29 components and 1.79432 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.295499Jy  sigma=0.001781
! Fit after  self-cal, rms=0.295445Jy  sigma=0.001781
! Inverting map 
! clean: niter=100  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.0610762 Jy
! Component: 100  -  total flux cleaned = 0.100951 Jy
! Total flux subtracted in 100 components = 0.100951 Jy
! Clean residual min=-0.023901 max=0.026844 Jy/beam
! Clean residual mean=-0.000048 rms=0.005533 Jy/beam
! Combined flux in latest and established models = 1.89527 Jy
! Performing phase self-cal
! Adding 27 model components to the UV plane model.
! The established model now contains 54 components and 1.89527 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.267956Jy  sigma=0.001555
! Fit after  self-cal, rms=0.267917Jy  sigma=0.001555
! 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.794 mas, bmaj=9.163 mas, bpa=-2.148 degrees
! Estimated noise=718.602 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.0634427 Jy
! Component: 100  -  total flux cleaned = 0.0959832 Jy
! Component: 150  -  total flux cleaned = 0.113591 Jy
! Component: 200  -  total flux cleaned = 0.123431 Jy
! Total flux subtracted in 200 components = 0.123431 Jy
! Clean residual min=-0.015937 max=0.023599 Jy/beam
! Clean residual mean=-0.000253 rms=0.004759 Jy/beam
! Combined flux in latest and established models = 2.0187 Jy
! Performing phase self-cal
! Adding 46 model components to the UV plane model.
! The established model now contains 86 components and 2.0187 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.254909Jy  sigma=0.001436
! Fit after  self-cal, rms=0.254850Jy  sigma=0.001435
! 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        0.98     GC        1.00*    HN        1.00*    KP        0.94     
!   LA        1.02     MK        1.00     NL        1.01     NY        1.00*    
!   ON        1.00*    OV        1.09     PT        1.02     SC        1.00*    
!   TS        1.08     KK        0.98     WZ        1.00*    WF        1.00*    
! 
!  A total of 9 telescope corrections were flagged in sub-array 2.
!  Telescope amplitude corrections in sub-array 2:
!   FD        1.04     GC        1.00*    HN        0.95     KP        0.94     
!   LA        1.01     MK        0.94     NL        1.03     NY        1.00*    
!   ON        1.00*    OV        0.94     PT        0.96     SC        0.97     
!   TS        1.00*    KK        0.97     WZ        1.00*    WF        1.04     
! 
!  A total of 192 telescope corrections were flagged in sub-array 3.
!  Telescope amplitude corrections in sub-array 3:
!   FD        0.98     GC        1.00*    HN        0.97     KP        0.95     
!   LA        0.99     MK        1.00*    NL        1.01     NY        1.00*    
!   ON        1.00*    OV        0.98     PT        0.99     SC        0.96     
!   TS        1.00*    KK        1.00*    WZ        1.00*    WF        0.97     
! 
!  Telescope amplitude corrections in sub-array 4:
!   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 30 telescope corrections were flagged in sub-array 5.
!  Telescope amplitude corrections in sub-array 5:
!   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 87 telescope corrections were flagged in sub-array 1.
!  Telescope amplitude corrections in sub-array 1:
!   FD        0.98     GC        1.00*    HN        1.00*    KP        0.98     
!   LA        0.96     MK        1.06     NL        1.04     NY        1.00*    
!   ON        1.00*    OV        0.99     PT        0.97     SC        1.00*    
!   TS        1.09     KK        0.98     WZ        1.00*    WF        1.00*    
! 
!  A total of 12 telescope corrections were flagged in sub-array 2.
!  Telescope amplitude corrections in sub-array 2:
!   FD        1.05     GC        1.00*    HN        1.00     KP        1.02     
!   LA        1.02     MK        1.04     NL        1.08     NY        1.00*    
!   ON        1.00*    OV        0.93     PT        0.95     SC        1.04     
!   TS        1.00*    KK        0.97     WZ        1.00*    WF        1.01     
! 
!  A total of 189 telescope corrections were flagged in sub-array 3.
!  Telescope amplitude corrections in sub-array 3:
!   FD        0.99     GC        1.00*    HN        1.03     KP        1.05     
!   LA        1.00     MK        1.00*    NL        1.06     NY        1.00*    
!   ON        1.00*    OV        0.98     PT        0.97     SC        1.02     
!   TS        1.00*    KK        1.00*    WZ        1.00*    WF        0.97     
! 
!  Telescope amplitude corrections in sub-array 4:
!   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 33 telescope corrections were flagged in sub-array 5.
!  Telescope amplitude corrections in sub-array 5:
!   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 87 telescope corrections were flagged in sub-array 1.
!  Telescope amplitude corrections in sub-array 1:
!   FD        0.97     GC        1.00*    HN        1.00*    KP        1.01     
!   LA        0.94     MK        1.03     NL        0.99     NY        1.00*    
!   ON        1.00*    OV        1.06     PT        1.01     SC        1.00*    
!   TS        1.13     KK        0.96     WZ        1.00*    WF        1.00*    
! 
!  A total of 12 telescope corrections were flagged in sub-array 2.
!  Telescope amplitude corrections in sub-array 2:
!   FD        1.02     GC        1.00*    HN        0.99     KP        1.02     
!   LA        0.97     MK        1.03     NL        1.03     NY        1.00*    
!   ON        1.00*    OV        0.95     PT        1.00     SC        1.04     
!   TS        1.00*    KK        0.98     WZ        1.00*    WF        1.08     
! 
!  A total of 192 telescope corrections were flagged in sub-array 3.
!  Telescope amplitude corrections in sub-array 3:
!   FD        0.97     GC        1.00*    HN        1.04     KP        1.04     
!   LA        0.96     MK        1.00*    NL        1.01     NY        1.00*    
!   ON        1.00*    OV        1.02     PT        1.02     SC        1.03     
!   TS        1.00*    KK        1.00*    WZ        1.00*    WF        1.00     
! 
!  Telescope amplitude corrections in sub-array 4:
!   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 30 telescope corrections were flagged in sub-array 5.
!  Telescope amplitude corrections in sub-array 5:
!   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 87 telescope corrections were flagged in sub-array 1.
!  Telescope amplitude corrections in sub-array 1:
!   FD        0.95     GC        1.00*    HN        1.00*    KP        1.00     
!   LA        0.98     MK        0.97     NL        1.03     NY        1.00*    
!   ON        1.00*    OV        1.09     PT        0.96     SC        1.00*    
!   TS        1.14     KK        1.02     WZ        1.00*    WF        1.00*    
! 
!  A total of 12 telescope corrections were flagged in sub-array 2.
!  Telescope amplitude corrections in sub-array 2:
!   FD        1.00     GC        1.00*    HN        1.00     KP        1.03     
!   LA        1.01     MK        0.97     NL        1.06     NY        1.00*    
!   ON        1.00*    OV        0.95     PT        0.95     SC        0.98     
!   TS        1.00*    KK        1.05     WZ        1.00*    WF        1.05     
! 
!  A total of 183 telescope corrections were flagged in sub-array 3.
!  Telescope amplitude corrections in sub-array 3:
!   FD        0.96     GC        1.00*    HN        1.06     KP        1.04     
!   LA        1.01     MK        1.00*    NL        1.03     NY        1.00*    
!   ON        1.00*    OV        0.97     PT        0.97     SC        1.00     
!   TS        1.00*    KK        1.00*    WZ        1.00*    WF        0.98     
! 
!  Telescope amplitude corrections in sub-array 4:
!   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*    
! 
!  Telescope amplitude corrections in sub-array 5:
!   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.254850Jy  sigma=0.001435
! Fit after  self-cal, rms=0.240911Jy  sigma=0.001310
dynam = dynam - 0.5
flux_cutoff = imstat(rms) * dynam
! Inverting map and beam 
! Estimated beam: bmin=2.775 mas, bmaj=9.136 mas, bpa=-2.061 degrees
! Estimated noise=731.301 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.00361509 Jy
! Component: 100  -  total flux cleaned = -0.00392156 Jy
! Component: 150  -  total flux cleaned = -0.0040059 Jy
! Component: 200  -  total flux cleaned = -0.00400437 Jy
! Total flux subtracted in 200 components = -0.00400437 Jy
! Clean residual min=-0.007017 max=0.011022 Jy/beam
! Clean residual mean=0.000074 rms=0.002113 Jy/beam
! Combined flux in latest and established models = 2.01469 Jy
! Performing phase self-cal
! Adding 12 model components to the UV plane model.
! The established model now contains 88 components and 2.01469 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.240781Jy  sigma=0.001309
! Fit after  self-cal, rms=0.240849Jy  sigma=0.001309
! Inverting map 
! Added new window around map position (-5.5, -4).
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.00872092 Jy
! Component: 100  -  total flux cleaned = 0.00849852 Jy
! Component: 150  -  total flux cleaned = 0.00813407 Jy
! Component: 200  -  total flux cleaned = 0.00797462 Jy
! Total flux subtracted in 200 components = 0.00797462 Jy
! Clean residual min=-0.006261 max=0.007376 Jy/beam
! Clean residual mean=0.000020 rms=0.001895 Jy/beam
! Combined flux in latest and established models = 2.02267 Jy
! Performing phase self-cal
! Adding 24 model components to the UV plane model.
! The established model now contains 108 components and 2.02267 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.240377Jy  sigma=0.001305
! Fit after  self-cal, rms=0.240330Jy  sigma=0.001305
! 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.240330Jy  sigma=0.001305
! Fit after  self-cal, rms=0.238486Jy  sigma=0.001291
dynam = dynam - 0.75
clean clean_niter,clean_gain
! Inverting map and beam 
! Estimated beam: bmin=2.782 mas, bmaj=9.131 mas, bpa=-2.041 degrees
! Estimated noise=731.903 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.000207566 Jy
! Component: 100  -  total flux cleaned = 0.000210357 Jy
! Component: 150  -  total flux cleaned = 8.08861e-05 Jy
! Component: 200  -  total flux cleaned = -3.61259e-05 Jy
! Total flux subtracted in 200 components = -3.61259e-05 Jy
! Clean residual min=-0.005094 max=0.006430 Jy/beam
! Clean residual mean=0.000189 rms=0.001644 Jy/beam
! Combined flux in latest and established models = 2.02263 Jy
selfcal
! Performing phase self-cal
! Adding 25 model components to the UV plane model.
! The established model now contains 126 components and 2.02263 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.238336Jy  sigma=0.001290
! Fit after  self-cal, rms=0.238331Jy  sigma=0.001290
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.000539084 Jy
! Component: 100  -  total flux cleaned = 0.000438261 Jy
! Component: 150  -  total flux cleaned = 0.000436886 Jy
! Component: 200  -  total flux cleaned = 0.000435748 Jy
! Total flux subtracted in 200 components = 0.000435748 Jy
! Clean residual min=-0.004959 max=0.005976 Jy/beam
! Clean residual mean=0.000186 rms=0.001610 Jy/beam
! Combined flux in latest and established models = 2.02307 Jy
! Performing phase self-cal
! Adding 33 model components to the UV plane model.
! The established model now contains 143 components and 2.02307 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.238258Jy  sigma=0.001289
! Fit after  self-cal, rms=0.238253Jy  sigma=0.001289
! 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.238253Jy  sigma=0.001289
! Fit after  self-cal, rms=0.235538Jy  sigma=0.001270
clean clean_niter,clean_gain
! Inverting map and beam 
! Estimated beam: bmin=2.783 mas, bmaj=9.13 mas, bpa=-2.035 degrees
! Estimated noise=731.924 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.000722994 Jy
! Component: 100  -  total flux cleaned = 0.000905914 Jy
! Component: 150  -  total flux cleaned = 0.00106592 Jy
! Component: 200  -  total flux cleaned = 0.00121036 Jy
! Total flux subtracted in 200 components = 0.00121036 Jy
! Clean residual min=-0.003788 max=0.004448 Jy/beam
! Clean residual mean=0.000125 rms=0.001116 Jy/beam
! Combined flux in latest and established models = 2.02428 Jy
selfcal
! Performing phase self-cal
! Adding 19 model components to the UV plane model.
! The established model now contains 152 components and 2.02428 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.235481Jy  sigma=0.001270
! Fit after  self-cal, rms=0.235481Jy  sigma=0.001270
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.000559121 Jy
! Component: 100  -  total flux cleaned = 0.000687702 Jy
! Component: 150  -  total flux cleaned = 0.000808159 Jy
! Component: 200  -  total flux cleaned = 0.000919315 Jy
! Total flux subtracted in 200 components = 0.000919315 Jy
! Clean residual min=-0.003761 max=0.004210 Jy/beam
! Clean residual mean=0.000116 rms=0.001101 Jy/beam
! Combined flux in latest and established models = 2.0252 Jy
! Performing phase self-cal
! Adding 21 model components to the UV plane model.
! The established model now contains 156 components and 2.0252 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.235450Jy  sigma=0.001270
! Fit after  self-cal, rms=0.235448Jy  sigma=0.001270
! 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.235448Jy  sigma=0.001270
! Fit after  self-cal, rms=0.235407Jy  sigma=0.001270
clean clean_niter,clean_gain
! Inverting map and beam 
! Estimated beam: bmin=8.152 mas, bmaj=16.46 mas, bpa=-3.208 degrees
! Estimated noise=937.995 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.000943547 Jy
! Component: 100  -  total flux cleaned = 0.00126002 Jy
! Component: 150  -  total flux cleaned = 0.00136825 Jy
! Component: 200  -  total flux cleaned = 0.00146554 Jy
! Total flux subtracted in 200 components = 0.00146554 Jy
! Clean residual min=-0.004285 max=0.004998 Jy/beam
! Clean residual mean=0.000231 rms=0.001536 Jy/beam
! Combined flux in latest and established models = 2.02666 Jy
selfcal
! Performing phase self-cal
! Adding 13 model components to the UV plane model.
! The established model now contains 167 components and 2.02666 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.235394Jy  sigma=0.001270
! Fit after  self-cal, rms=0.235389Jy  sigma=0.001270
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.000250648 Jy
! Component: 100  -  total flux cleaned = 0.000410602 Jy
! Component: 150  -  total flux cleaned = 0.000467818 Jy
! Component: 200  -  total flux cleaned = 0.000521074 Jy
! Total flux subtracted in 200 components = 0.000521074 Jy
! Clean residual min=-0.004271 max=0.004999 Jy/beam
! Clean residual mean=0.000221 rms=0.001535 Jy/beam
! Combined flux in latest and established models = 2.02718 Jy
! Performing phase self-cal
! Adding 14 model components to the UV plane model.
! The established model now contains 173 components and 2.02718 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.235386Jy  sigma=0.001270
! Fit after  self-cal, rms=0.235383Jy  sigma=0.001270
! 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.783 mas, bmaj=9.132 mas, bpa=-2.038 degrees
! Estimated noise=731.968 mJy/beam.
! restore: Substituting estimate of restoring beam from last 'invert'.
! Restoring with beam: 2.783 x 9.132 at -2.038 degrees (North through East)
! Clean map  min=-0.0049897  max=1.4688 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.235383Jy  sigma=0.001270
! Fit after  self-cal, rms=0.218957Jy  sigma=0.001090
! Inverting map and beam 
! Estimated beam: bmin=2.775 mas, bmaj=9.128 mas, bpa=-2.116 degrees
! Estimated noise=731.145 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = -0.00197307 Jy
! Component: 100  -  total flux cleaned = -0.00182399 Jy
! Component: 150  -  total flux cleaned = -0.00156451 Jy
! Component: 200  -  total flux cleaned = -0.00144817 Jy
! Total flux subtracted in 200 components = -0.00144817 Jy
! Clean residual min=-0.003916 max=0.003529 Jy/beam
! Clean residual mean=0.000066 rms=0.000989 Jy/beam
! Combined flux in latest and established models = 2.02574 Jy
! Performing phase self-cal
! Adding 14 model components to the UV plane model.
! The established model now contains 185 components and 2.02574 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.218881Jy  sigma=0.001090
! Fit after  self-cal, rms=0.218885Jy  sigma=0.001090
! Inverting map 
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.0002161 Jy
! Component: 100  -  total flux cleaned = 0.000319168 Jy
! Component: 150  -  total flux cleaned = 0.000367823 Jy
! Component: 200  -  total flux cleaned = 0.00041244 Jy
! Total flux subtracted in 200 components = 0.00041244 Jy
! Clean residual min=-0.003826 max=0.003414 Jy/beam
! Clean residual mean=0.000061 rms=0.000978 Jy/beam
! Combined flux in latest and established models = 2.02615 Jy
! Performing phase self-cal
! Adding 20 model components to the UV plane model.
! The established model now contains 194 components and 2.02615 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.218860Jy  sigma=0.001090
! Fit after  self-cal, rms=0.218860Jy  sigma=0.001090
! 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.218860Jy  sigma=0.001090
! Fit after  self-cal, rms=0.219044Jy  sigma=0.001089
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.197 mas, bmaj=8.705 mas, bpa=-1.211 degrees
! Estimated noise=1337.22 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 1.09624 Jy
! Component: 100  -  total flux cleaned = 1.51963 Jy
! Component: 150  -  total flux cleaned = 1.71338 Jy
! Component: 200  -  total flux cleaned = 1.81359 Jy
! Total flux subtracted in 200 components = 1.81359 Jy
! Clean residual min=-0.014974 max=0.051360 Jy/beam
! Clean residual mean=0.000076 rms=0.005722 Jy/beam
! Combined flux in latest and established models = 1.81359 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 28 model components to the UV plane model.
! The established model now contains 28 components and 1.81359 Jy
! Inverting map and beam 
! Estimated beam: bmin=2.775 mas, bmaj=9.133 mas, bpa=-2.126 degrees
! Estimated noise=731.225 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.0964403 Jy
! Component: 100  -  total flux cleaned = 0.144371 Jy
! Component: 150  -  total flux cleaned = 0.170056 Jy
! Component: 200  -  total flux cleaned = 0.185089 Jy
! Total flux subtracted in 200 components = 0.185089 Jy
! Clean residual min=-0.005423 max=0.008274 Jy/beam
! Clean residual mean=0.000272 rms=0.001784 Jy/beam
! Combined flux in latest and established models = 1.99867 Jy
! Adding 62 model components to the UV plane model.
! The established model now contains 82 components and 1.99867 Jy
! Inverting map 
! Added new window around map position (4, -3.5).
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.00937827 Jy
! Component: 100  -  total flux cleaned = 0.0153576 Jy
! Component: 150  -  total flux cleaned = 0.0193999 Jy
! Component: 200  -  total flux cleaned = 0.0212225 Jy
! Total flux subtracted in 200 components = 0.0212225 Jy
! Clean residual min=-0.003868 max=0.004183 Jy/beam
! Clean residual mean=0.000123 rms=0.001055 Jy/beam
! Combined flux in latest and established models = 2.0199 Jy
! Adding 48 model components to the UV plane model.
! The established model now contains 122 components and 2.0199 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.168 mas, bmaj=16.47 mas, bpa=-3.182 degrees
! Estimated noise=937.209 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.0033276 Jy
! Component: 100  -  total flux cleaned = 0.00438575 Jy
! Component: 150  -  total flux cleaned = 0.00463275 Jy
! Component: 200  -  total flux cleaned = 0.00480579 Jy
! Total flux subtracted in 200 components = 0.00480579 Jy
! Clean residual min=-0.003937 max=0.004255 Jy/beam
! Clean residual mean=0.000187 rms=0.001418 Jy/beam
! Combined flux in latest and established models = 2.0247 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.000158023 Jy
! Component: 100  -  total flux cleaned = 0.000305302 Jy
! Component: 150  -  total flux cleaned = 0.000443318 Jy
! Component: 200  -  total flux cleaned = 0.000571654 Jy
! Total flux subtracted in 200 components = 0.000571654 Jy
! Clean residual min=-0.003830 max=0.004187 Jy/beam
! Clean residual mean=0.000176 rms=0.001407 Jy/beam
! Combined flux in latest and established models = 2.02527 Jy
! Adding 32 model components to the UV plane model.
! The established model now contains 149 components and 2.02527 Jy
! Inverting map 
uvtaper 0,0
! No UV-taper is currently set.
clean
! Inverting map and beam 
! Estimated beam: bmin=2.775 mas, bmaj=9.133 mas, bpa=-2.126 degrees
! Estimated noise=731.225 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = -0.000294482 Jy
! Component: 100  -  total flux cleaned = 9.51778e-06 Jy
! Component: 150  -  total flux cleaned = 0.000115831 Jy
! Component: 200  -  total flux cleaned = 0.000164936 Jy
! Total flux subtracted in 200 components = 0.000164936 Jy
! Clean residual min=-0.003564 max=0.003452 Jy/beam
! Clean residual mean=0.000079 rms=0.000960 Jy/beam
! Combined flux in latest and established models = 2.02544 Jy
selfcal
! Performing phase self-cal
! Adding 22 model components to the UV plane model.
! The established model now contains 167 components and 2.02544 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.218980Jy  sigma=0.001089
! Fit after  self-cal, rms=0.218977Jy  sigma=0.001089
wmodel J2158-1501_S_2003_09_17_pus_map.mod
! Writing 167 model components to file: J2158-1501_S_2003_09_17_pus_map.mod
wobs J2158-1501_S_2003_09_17_pus_uvs.fits
! Writing UV FITS file: J2158-1501_S_2003_09_17_pus_uvs.fits
wwins J2158-1501_S_2003_09_17_pus_map.win
! wwins: Wrote 3 windows to J2158-1501_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 = -5.59586e-05 Jy
! Component: 100  -  total flux cleaned = 0.000177887 Jy
! Component: 150  -  total flux cleaned = 0.000393109 Jy
! Component: 200  -  total flux cleaned = 0.000698297 Jy
! Component: 250  -  total flux cleaned = 0.00103931 Jy
! Component: 300  -  total flux cleaned = 0.00131985 Jy
! Component: 350  -  total flux cleaned = 0.00150063 Jy
! Component: 400  -  total flux cleaned = 0.00176353 Jy
! Component: 450  -  total flux cleaned = 0.00189021 Jy
! Component: 500  -  total flux cleaned = 0.00197159 Jy
! Component: 550  -  total flux cleaned = 0.00205137 Jy
! Component: 600  -  total flux cleaned = 0.00212952 Jy
! Component: 650  -  total flux cleaned = 0.00232093 Jy
! Component: 700  -  total flux cleaned = 0.00254598 Jy
! Component: 750  -  total flux cleaned = 0.00280304 Jy
! Component: 800  -  total flux cleaned = 0.00301893 Jy
! Component: 850  -  total flux cleaned = 0.0030898 Jy
! Component: 900  -  total flux cleaned = 0.00319403 Jy
! Component: 950  -  total flux cleaned = 0.00333076 Jy
! Component: 1000  -  total flux cleaned = 0.00339789 Jy
! Component: 1050  -  total flux cleaned = 0.00352993 Jy
! Component: 1100  -  total flux cleaned = 0.00359456 Jy
! Component: 1150  -  total flux cleaned = 0.00362632 Jy
! Component: 1200  -  total flux cleaned = 0.00362612 Jy
! Component: 1250  -  total flux cleaned = 0.00362688 Jy
! Component: 1300  -  total flux cleaned = 0.00365781 Jy
! Component: 1350  -  total flux cleaned = 0.00368792 Jy
! Component: 1400  -  total flux cleaned = 0.0036576 Jy
! Component: 1450  -  total flux cleaned = 0.00362792 Jy
! Component: 1500  -  total flux cleaned = 0.00359875 Jy
! Component: 1550  -  total flux cleaned = 0.0035124 Jy
! Component: 1600  -  total flux cleaned = 0.00348439 Jy
! Component: 1650  -  total flux cleaned = 0.00342845 Jy
! Component: 1700  -  total flux cleaned = 0.0034288 Jy
! Component: 1750  -  total flux cleaned = 0.00342879 Jy
! Component: 1800  -  total flux cleaned = 0.00342874 Jy
! Component: 1850  -  total flux cleaned = 0.00337482 Jy
! Component: 1900  -  total flux cleaned = 0.0034016 Jy
! Component: 1950  -  total flux cleaned = 0.00337531 Jy
! Component: 2000  -  total flux cleaned = 0.00337527 Jy
! Total flux subtracted in 2048 components = 0.00337534 Jy
! Clean residual min=-0.001598 max=0.001753 Jy/beam
! Clean residual mean=0.000032 rms=0.000541 Jy/beam
! Combined flux in latest and established models = 2.02881 Jy
keep
! Adding 139 model components to the UV plane model.
! The established model now contains 306 components and 2.02882 Jy
wmap "J2158-1501_S_2003_09_17_pus\_map.fits"
! Inverting map 
! restore: Substituting estimate of restoring beam from last 'invert'.
! Restoring with beam: 2.775 x 9.133 at -2.126 degrees (North through East)
! Clean map  min=-0.0029685  max=1.4755 Jy/beam
! Writing clean map to FITS file: J2158-1501_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 1.47554 
invert
! Inverting map 
float image_rms
image_rms = imstat(rms)
print "The final image rms is",image_rms
! The final image rms is 0.000540942 
device "J2158-1501_S_2003_09_17_pus\_map.eps/VPS"
! Attempting to open device: 'J2158-1501_S_2003_09_17_pus_map.eps/VPS'
loglevs 100*3*image_rms/peak_flux
! The new contour levels are:
!  -0.109982 0.109982 0.219964 0.439928 0.879856 1.75971 3.51942 7.03885 14.0777 28.1554 56.3108
print "clev=",int(3*image_rms*10000)/10000
! clev= 0.0016 
print "peak=",int(1000*peak_flux)/1000
! peak= 1.475 
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.775 x 9.133 at -2.126 degrees (North through East)
! Clean map  min=-0.0029685  max=1.4755 Jy/beam
mapcolor color, 0.9
! Mapplot colormap: rainbow, contrast: 0.9 brightness: 0.5.
device "J2158-1501_S_2003_09_17_pus\_map.gif/vgif"
! Attempting to open device: 'J2158-1501_S_2003_09_17_pus_map.gif/vgif'
mapplot cln
quit
! Quitting program
! Log file J2158-1501_S_2003_09_17_pus_uvs.log closed on Wed May 23 18:08:30 2007