! Started logfile: J0339-0146_X_1999_05_10_pus_uvs.log on Mon Jan 14 12:33:17 2008
obs J0339-0146_X_1999_05_10_pus_uva.fits
! Reading UV FITS file: J0339-0146_X_1999_05_10_pus_uva.fits
! AN table 1: 47 integrations on 153 of 153 possible baselines.
! AN table 2: 36 integrations on 153 of 153 possible baselines.
! AN table 3: 79 integrations on 153 of 153 possible baselines.
! AN table 4: 113 integrations on 153 of 153 possible baselines.
! Apparent sampling: 0.184076 visibilities/baseline/integration-bin.
! *** This seems a bit low - see "help observe" on the binwid argument.
! Found source: J0339-0146
! 
! 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  8.40997e+09        8e+06          1        8e+06
!  02        2  8.47997e+09        8e+06          1        8e+06
!  03        3  8.79497e+09        8e+06          1        8e+06
!  04        4  8.89997e+09        8e+06          1        8e+06
! 
! Polarization(s): RR
! 
! Read 1759 lines of history.
! 
! Reading 30980 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 = 256 
print "field_cell =",field_cell
! field_cell = 0.2 
print "taper_size =",taper_size
! taper_size = 70 
![@muppet J0339-0146_X_1999_05_10_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 = 256x256 pixels with 0.200x0.200 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 632 telescope corrections were flagged in sub-array 1.
!  A total of 326 telescope corrections were flagged in sub-array 2.
!  A total of 1145 telescope corrections were flagged in sub-array 3.
!  A total of 928 telescope corrections were flagged in sub-array 4.
! 
! Correcting IF 2.
!  A total of 632 telescope corrections were flagged in sub-array 1.
!  A total of 326 telescope corrections were flagged in sub-array 2.
!  A total of 1145 telescope corrections were flagged in sub-array 3.
!  A total of 928 telescope corrections were flagged in sub-array 4.
! 
! Correcting IF 3.
!  A total of 632 telescope corrections were flagged in sub-array 1.
!  A total of 326 telescope corrections were flagged in sub-array 2.
!  A total of 1145 telescope corrections were flagged in sub-array 3.
!  A total of 928 telescope corrections were flagged in sub-array 4.
! 
! Correcting IF 4.
!  A total of 632 telescope corrections were flagged in sub-array 1.
!  A total of 326 telescope corrections were flagged in sub-array 2.
!  A total of 1253 telescope corrections were flagged in sub-array 3.
!  A total of 928 telescope corrections were flagged in sub-array 4.
! 
! Fit before self-cal, rms=1.130620Jy  sigma=0.010728
! Fit after  self-cal, rms=0.822439Jy  sigma=0.008498
! 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 
! Your choice of large map pixels excluded 0.479% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
! Estimated beam: bmin=0.713 mas, bmaj=1.22 mas, bpa=-1.18 degrees
! Estimated noise=1049.2 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.27157 Jy
! Component: 100  -  total flux cleaned = 1.57361 Jy
! Total flux subtracted in 100 components = 1.57361 Jy
! Clean residual min=-0.041637 max=0.124099 Jy/beam
! Clean residual mean=0.001386 rms=0.017557 Jy/beam
! Combined flux in latest and established models = 1.57361 Jy
! Performing phase self-cal
! Adding 7 model components to the UV plane model.
! The established model now contains 7 components and 1.57361 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.443663Jy  sigma=0.004038
! Fit after  self-cal, rms=0.443680Jy  sigma=0.004038
! Inverting map 
! Your choice of large map pixels excluded 0.479% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
! Added new window around map position (1.4, 0.6).
! clean: niter=100  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.145576 Jy
! Component: 100  -  total flux cleaned = 0.240498 Jy
! Total flux subtracted in 100 components = 0.240498 Jy
! Clean residual min=-0.033669 max=0.061440 Jy/beam
! Clean residual mean=0.000860 rms=0.011522 Jy/beam
! Combined flux in latest and established models = 1.81411 Jy
! Performing phase self-cal
! Adding 27 model components to the UV plane model.
! The established model now contains 30 components and 1.81411 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.372087Jy  sigma=0.002881
! Fit after  self-cal, rms=0.369850Jy  sigma=0.002865
! Inverting map 
! Your choice of large map pixels excluded 0.479% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
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 
! Your choice of large map pixels excluded 0.479% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
! Estimated beam: bmin=0.902 mas, bmaj=1.991 mas, bpa=-9.919 degrees
! Estimated noise=429.727 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.121111 Jy
! Component: 100  -  total flux cleaned = 0.193824 Jy
! Component: 150  -  total flux cleaned = 0.241511 Jy
! Component: 200  -  total flux cleaned = 0.274117 Jy
! Total flux subtracted in 200 components = 0.274117 Jy
! Clean residual min=-0.022716 max=0.054302 Jy/beam
! Clean residual mean=0.000392 rms=0.009497 Jy/beam
! Combined flux in latest and established models = 2.08823 Jy
! Performing phase self-cal
! Adding 44 model components to the UV plane model.
! The established model now contains 63 components and 2.08823 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.336127Jy  sigma=0.002127
! Fit after  self-cal, rms=0.332769Jy  sigma=0.002082
! Inverting map 
! Your choice of large map pixels excluded 0.479% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
print "************** FINISHED NATURAL WEIGHTING CLEAN **************"
! ************** FINISHED NATURAL WEIGHTING CLEAN ************** 
! 
gscale true
! Performing overall amplitude self-cal
! 
! Correcting IF 1.
!  A total of 3 telescope corrections were flagged in sub-array 1.
!  Telescope amplitude corrections in sub-array 1:
!   BR        1.00*    FD        1.05     GC        1.00*    HH        0.90     
!   HN        1.01     KK        1.00*    KP        1.00*    LA        1.00*    
!   MC        1.00*    MK        1.00*    NL        1.08     NY        1.00*    
!   ON        0.84     OV        1.00*    PT        1.00*    SC        1.12     
!   WF        0.78     WZ        1.00*    
! 
!  Telescope amplitude corrections in sub-array 2:
!   BR        0.96     FD        0.97     GC        1.03     HH        1.00*    
!   HN        1.13     KK        0.93     KP        0.99     LA        0.98     
!   MC        1.00*    MK        0.98     NL        1.07     NY        1.00*    
!   ON        1.00*    OV        0.98     PT        1.01     SC        1.00*    
!   WF        1.42     WZ        1.00*    
! 
!  A total of 54 telescope corrections were flagged in sub-array 3.
!  Telescope amplitude corrections in sub-array 3:
!   BR        1.00*    FD        1.00*    GC        1.00*    HH        1.05     
!   HN        1.00*    KK        1.00*    KP        1.00*    LA        1.00*    
!   MC        1.06     MK        1.00*    NL        1.00*    NY        1.14     
!   ON        0.95     OV        1.00*    PT        1.00*    SC        1.00*    
!   WF        1.00*    WZ        1.06     
! 
!  A total of 15 telescope corrections were flagged in sub-array 4.
!  Telescope amplitude corrections in sub-array 4:
!   BR        0.94     FD        0.94     GC        1.16     HH        1.00*    
!   HN        1.00     KK        0.98     KP        0.99     LA        0.96     
!   MC        1.00*    MK        1.00     NL        1.04     NY        1.00*    
!   ON        1.00*    OV        0.98     PT        1.01     SC        1.02     
!   WF        1.01     WZ        1.00*    
! 
! 
! Correcting IF 2.
!  A total of 3 telescope corrections were flagged in sub-array 1.
!  Telescope amplitude corrections in sub-array 1:
!   BR        1.00*    FD        1.05     GC        1.00*    HH        1.01     
!   HN        1.00     KK        1.00*    KP        1.00*    LA        1.00*    
!   MC        1.00*    MK        1.00*    NL        1.04     NY        1.00*    
!   ON        0.91     OV        1.00*    PT        1.00*    SC        1.03     
!   WF        1.04     WZ        1.00*    
! 
!  Telescope amplitude corrections in sub-array 2:
!   BR        0.97     FD        0.97     GC        1.01     HH        1.00*    
!   HN        1.20     KK        0.93     KP        1.00     LA        0.98     
!   MC        1.00*    MK        0.98     NL        1.03     NY        1.00*    
!   ON        1.00*    OV        0.96     PT        0.93     SC        1.00*    
!   WF        1.33     WZ        1.00*    
! 
!  A total of 54 telescope corrections were flagged in sub-array 3.
!  Telescope amplitude corrections in sub-array 3:
!   BR        1.00*    FD        1.00*    GC        1.00*    HH        0.98     
!   HN        1.00*    KK        1.00*    KP        1.00*    LA        1.00*    
!   MC        1.07     MK        1.00*    NL        1.00*    NY        1.16     
!   ON        0.94     OV        1.00*    PT        1.00*    SC        1.00*    
!   WF        1.00*    WZ        1.07     
! 
!  A total of 15 telescope corrections were flagged in sub-array 4.
!  Telescope amplitude corrections in sub-array 4:
!   BR        0.95     FD        0.94     GC        1.13     HH        1.00*    
!   HN        1.00     KK        0.99     KP        0.99     LA        0.97     
!   MC        1.00*    MK        1.00     NL        1.00     NY        1.00*    
!   ON        1.00*    OV        0.96     PT        0.93     SC        1.00     
!   WF        1.07     WZ        1.00*    
! 
! 
! Correcting IF 3.
!  A total of 3 telescope corrections were flagged in sub-array 1.
!  Telescope amplitude corrections in sub-array 1:
!   BR        1.00*    FD        1.12     GC        1.00*    HH        1.02     
!   HN        1.02     KK        1.00*    KP        1.00*    LA        1.00*    
!   MC        1.00*    MK        1.00*    NL        1.04     NY        1.00*    
!   ON        0.94     OV        1.00*    PT        1.00*    SC        1.08     
!   WF        1.05     WZ        1.00*    
! 
!  Telescope amplitude corrections in sub-array 2:
!   BR        1.00     FD        0.99     GC        0.97     HH        1.00*    
!   HN        1.25     KK        1.00     KP        1.03     LA        0.98     
!   MC        1.00*    MK        0.98     NL        1.04     NY        1.00*    
!   ON        1.00*    OV        1.00     PT        0.95     SC        1.00*    
!   WF        1.34     WZ        1.00*    
! 
!  A total of 54 telescope corrections were flagged in sub-array 3.
!  Telescope amplitude corrections in sub-array 3:
!   BR        1.00*    FD        1.00*    GC        1.00*    HH        1.06     
!   HN        1.00*    KK        1.00*    KP        1.00*    LA        1.00*    
!   MC        1.12     MK        1.00*    NL        1.00*    NY        1.21     
!   ON        0.96     OV        1.00*    PT        1.00*    SC        1.00*    
!   WF        1.00*    WZ        1.09     
! 
!  A total of 15 telescope corrections were flagged in sub-array 4.
!  Telescope amplitude corrections in sub-array 4:
!   BR        0.99     FD        0.97     GC        1.14     HH        1.00*    
!   HN        1.02     KK        1.07     KP        1.01     LA        0.96     
!   MC        1.00*    MK        1.01     NL        1.00     NY        1.00*    
!   ON        1.00*    OV        0.99     PT        0.94     SC        1.02     
!   WF        1.09     WZ        1.00*    
! 
! 
! Correcting IF 4.
!  A total of 3 telescope corrections were flagged in sub-array 1.
!  Telescope amplitude corrections in sub-array 1:
!   BR        1.00*    FD        1.11     GC        1.00*    HH        1.08     
!   HN        1.03     KK        1.00*    KP        1.00*    LA        1.00*    
!   MC        1.00*    MK        1.00*    NL        1.06     NY        1.00*    
!   ON        1.00     OV        1.00*    PT        1.00*    SC        1.04     
!   WF        1.04     WZ        1.00*    
! 
!  Telescope amplitude corrections in sub-array 2:
!   BR        0.98     FD        0.99     GC        1.01     HH        1.00*    
!   HN        1.24     KK        0.99     KP        1.01     LA        1.00     
!   MC        1.00*    MK        1.00     NL        1.05     NY        1.00*    
!   ON        1.00*    OV        0.99     PT        0.98     SC        1.00*    
!   WF        1.33     WZ        1.00*    
! 
!  A total of 141 telescope corrections were flagged in sub-array 3.
!  Telescope amplitude corrections in sub-array 3:
!   BR        1.00*    FD        1.00*    GC        1.00*    HH        1.14     
!   HN        1.00*    KK        1.00*    KP        1.00*    LA        1.00*    
!   MC        1.06     MK        1.00*    NL        1.00*    NY        1.28     
!   ON        0.98     OV        1.00*    PT        1.00*    SC        1.00*    
!   WF        1.00*    WZ        1.00*    
! 
!  A total of 15 telescope corrections were flagged in sub-array 4.
!  Telescope amplitude corrections in sub-array 4:
!   BR        0.96     FD        0.96     GC        1.15     HH        1.00*    
!   HN        1.02     KK        1.03     KP        1.00     LA        0.98     
!   MC        1.00*    MK        1.02     NL        1.01     NY        1.00*    
!   ON        1.00*    OV        0.99     PT        0.97     SC        1.00     
!   WF        1.09     WZ        1.00*    
! 
! 
! Fit before self-cal, rms=0.332769Jy  sigma=0.002082
! Fit after  self-cal, rms=0.262316Jy  sigma=0.001644
dynam = dynam - 0.5
flux_cutoff = imstat(rms) * dynam
! Inverting map and beam 
! Your choice of large map pixels excluded 0.485% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
! Estimated beam: bmin=0.9073 mas, bmaj=2.016 mas, bpa=-9.71 degrees
! Estimated noise=430.465 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 (2.6, 0.8).
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.0197805 Jy
! Component: 100  -  total flux cleaned = 0.0240005 Jy
! Component: 150  -  total flux cleaned = 0.0257924 Jy
! Component: 200  -  total flux cleaned = 0.0277996 Jy
! Total flux subtracted in 200 components = 0.0277996 Jy
! Clean residual min=-0.008682 max=0.010377 Jy/beam
! Clean residual mean=0.000321 rms=0.002066 Jy/beam
! Combined flux in latest and established models = 2.11603 Jy
! Performing phase self-cal
! Adding 23 model components to the UV plane model.
! The established model now contains 84 components and 2.11603 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.260538Jy  sigma=0.001617
! Fit after  self-cal, rms=0.259777Jy  sigma=0.001612
! Inverting map 
! Your choice of large map pixels excluded 0.485% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
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.259777Jy  sigma=0.001612
! Fit after  self-cal, rms=0.256580Jy  sigma=0.001603
dynam = dynam - 0.75
clean clean_niter,clean_gain
! Inverting map and beam 
! Your choice of large map pixels excluded 0.485% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
! Estimated beam: bmin=0.9063 mas, bmaj=2.016 mas, bpa=-9.753 degrees
! Estimated noise=430.167 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.00921981 Jy
! Component: 100  -  total flux cleaned = 0.0106018 Jy
! Component: 150  -  total flux cleaned = 0.0119556 Jy
! Component: 200  -  total flux cleaned = 0.0127147 Jy
! Total flux subtracted in 200 components = 0.0127147 Jy
! Clean residual min=-0.008592 max=0.006979 Jy/beam
! Clean residual mean=0.000164 rms=0.001614 Jy/beam
! Combined flux in latest and established models = 2.12874 Jy
selfcal
! Performing phase self-cal
! Adding 23 model components to the UV plane model.
! The established model now contains 96 components and 2.12874 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.255992Jy  sigma=0.001595
! Fit after  self-cal, rms=0.255852Jy  sigma=0.001594
flux_cutoff = imstat(rms) * dynam
! Inverting map 
! Your choice of large map pixels excluded 0.485% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
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.00217112 Jy
! Component: 100  -  total flux cleaned = 0.00327775 Jy
! Component: 150  -  total flux cleaned = 0.00391086 Jy
! Component: 200  -  total flux cleaned = 0.00419895 Jy
! Total flux subtracted in 200 components = 0.00419895 Jy
! Clean residual min=-0.008206 max=0.005792 Jy/beam
! Clean residual mean=0.000102 rms=0.001460 Jy/beam
! Combined flux in latest and established models = 2.13294 Jy
! Performing phase self-cal
! Adding 23 model components to the UV plane model.
! The established model now contains 100 components and 2.13294 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.255582Jy  sigma=0.001591
! Fit after  self-cal, rms=0.255531Jy  sigma=0.001591
! Inverting map 
! Your choice of large map pixels excluded 0.485% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
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.255531Jy  sigma=0.001591
! Fit after  self-cal, rms=0.255390Jy  sigma=0.001588
clean clean_niter,clean_gain
! Inverting map and beam 
! Your choice of large map pixels excluded 0.485% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
! Estimated beam: bmin=0.9065 mas, bmaj=2.016 mas, bpa=-9.759 degrees
! Estimated noise=430.121 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.00297375 Jy
! Component: 100  -  total flux cleaned = 0.00376608 Jy
! Component: 150  -  total flux cleaned = 0.00403723 Jy
! Component: 200  -  total flux cleaned = 0.00416084 Jy
! Total flux subtracted in 200 components = 0.00416084 Jy
! Clean residual min=-0.006834 max=0.004851 Jy/beam
! Clean residual mean=0.000078 rms=0.001326 Jy/beam
! Combined flux in latest and established models = 2.1371 Jy
selfcal
! Performing phase self-cal
! Adding 21 model components to the UV plane model.
! The established model now contains 103 components and 2.1371 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.255185Jy  sigma=0.001585
! Fit after  self-cal, rms=0.255148Jy  sigma=0.001585
flux_cutoff = imstat(rms) * dynam
! Inverting map 
! Your choice of large map pixels excluded 0.485% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
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.000846042 Jy
! Component: 100  -  total flux cleaned = 0.00121678 Jy
! Component: 150  -  total flux cleaned = 0.00133411 Jy
! Component: 200  -  total flux cleaned = 0.00155336 Jy
! Total flux subtracted in 200 components = 0.00155336 Jy
! Clean residual min=-0.006393 max=0.004343 Jy/beam
! Clean residual mean=0.000055 rms=0.001259 Jy/beam
! Combined flux in latest and established models = 2.13866 Jy
! Performing phase self-cal
! Adding 22 model components to the UV plane model.
! The established model now contains 106 components and 2.13866 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.255025Jy  sigma=0.001584
! Fit after  self-cal, rms=0.255008Jy  sigma=0.001583
! Inverting map 
! Your choice of large map pixels excluded 0.485% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
uvtaper 0.3,taper_size
! Gaussian taper: value 0.3 at UV radius = 70 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.255008Jy  sigma=0.001583
! Fit after  self-cal, rms=0.254832Jy  sigma=0.001583
clean clean_niter,clean_gain
! Inverting map and beam 
! Your choice of large map pixels excluded 0.485% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
! Estimated beam: bmin=2.272 mas, bmaj=3.219 mas, bpa=-3.517 degrees
! Estimated noise=517.236 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.0027423 Jy
! Component: 100  -  total flux cleaned = 0.00334669 Jy
! Component: 150  -  total flux cleaned = 0.00379031 Jy
! Component: 200  -  total flux cleaned = 0.00413276 Jy
! Total flux subtracted in 200 components = 0.00413276 Jy
! Clean residual min=-0.005416 max=0.004598 Jy/beam
! Clean residual mean=0.000024 rms=0.001478 Jy/beam
! Combined flux in latest and established models = 2.14279 Jy
selfcal
! Performing phase self-cal
! Adding 17 model components to the UV plane model.
! The established model now contains 117 components and 2.14279 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.254775Jy  sigma=0.001582
! Fit after  self-cal, rms=0.254736Jy  sigma=0.001582
flux_cutoff = imstat(rms) * dynam
! Inverting map 
! Your choice of large map pixels excluded 0.485% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
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.000499567 Jy
! Component: 100  -  total flux cleaned = 0.000923605 Jy
! Component: 150  -  total flux cleaned = 0.00128827 Jy
! Component: 200  -  total flux cleaned = 0.00154252 Jy
! Total flux subtracted in 200 components = 0.00154252 Jy
! Clean residual min=-0.005331 max=0.004080 Jy/beam
! Clean residual mean=-0.000024 rms=0.001450 Jy/beam
! Combined flux in latest and established models = 2.14433 Jy
! Performing phase self-cal
! Adding 18 model components to the UV plane model.
! The established model now contains 121 components and 2.14433 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.254710Jy  sigma=0.001582
! Fit after  self-cal, rms=0.254695Jy  sigma=0.001582
! Inverting map 
! Your choice of large map pixels excluded 0.485% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
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 
! Your choice of large map pixels excluded 0.485% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
! Estimated beam: bmin=0.9063 mas, bmaj=2.017 mas, bpa=-9.77 degrees
! Estimated noise=430.061 mJy/beam.
! restore: Substituting estimate of restoring beam from last 'invert'.
! Restoring with beam: 0.9063 x 2.017 at -9.77 degrees (North through East)
! Clean map  min=-0.0050591  max=1.6732 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.254695Jy  sigma=0.001582
! Fit after  self-cal, rms=2.116019Jy  sigma=0.001358
! Inverting map and beam 
! Your choice of large map pixels excluded 0.485% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
! Estimated beam: bmin=0.9068 mas, bmaj=2.018 mas, bpa=-9.737 degrees
! Estimated noise=430.046 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = -0.000450791 Jy
! Component: 100  -  total flux cleaned = -0.000446805 Jy
! Component: 150  -  total flux cleaned = -0.000446711 Jy
! Component: 200  -  total flux cleaned = -0.000530636 Jy
! Total flux subtracted in 200 components = -0.000530636 Jy
! Clean residual min=-0.005122 max=0.003219 Jy/beam
! Clean residual mean=-0.000013 rms=0.001080 Jy/beam
! Combined flux in latest and established models = 2.1438 Jy
! Performing phase self-cal
! Adding 12 model components to the UV plane model.
! The established model now contains 125 components and 2.1438 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=2.116016Jy  sigma=0.001357
! Fit after  self-cal, rms=2.116024Jy  sigma=0.001357
! Inverting map 
! Your choice of large map pixels excluded 0.485% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.000260263 Jy
! Component: 100  -  total flux cleaned = 0.000260483 Jy
! Component: 150  -  total flux cleaned = 0.000262762 Jy
! Component: 200  -  total flux cleaned = 0.000263219 Jy
! Total flux subtracted in 200 components = 0.000263219 Jy
! Clean residual min=-0.004813 max=0.003269 Jy/beam
! Clean residual mean=-0.000019 rms=0.001057 Jy/beam
! Combined flux in latest and established models = 2.14406 Jy
! Performing phase self-cal
! Adding 14 model components to the UV plane model.
! The established model now contains 128 components and 2.14406 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=2.116015Jy  sigma=0.001357
! Fit after  self-cal, rms=2.116022Jy  sigma=0.001357
! Inverting map 
! Your choice of large map pixels excluded 0.485% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
! Performing amp+phase self-cal
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=2.116022Jy  sigma=0.001357
! Fit after  self-cal, rms=2.602794Jy  sigma=0.001356
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 
! Your choice of large map pixels excluded 0.485% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
! Estimated beam: bmin=0.7195 mas, bmaj=1.245 mas, bpa=-1.588 degrees
! Estimated noise=1063.47 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 1.2829 Jy
! Component: 100  -  total flux cleaned = 1.58409 Jy
! Component: 150  -  total flux cleaned = 1.72839 Jy
! Component: 200  -  total flux cleaned = 1.8187 Jy
! Total flux subtracted in 200 components = 1.8187 Jy
! Clean residual min=-0.017528 max=0.049347 Jy/beam
! Clean residual mean=0.000873 rms=0.007966 Jy/beam
! Combined flux in latest and established models = 1.8187 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 23 model components to the UV plane model.
! The established model now contains 23 components and 1.8187 Jy
! Inverting map and beam 
! Your choice of large map pixels excluded 0.485% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
! Estimated beam: bmin=0.9065 mas, bmaj=2.02 mas, bpa=-9.768 degrees
! Estimated noise=429.923 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.106621 Jy
! Component: 100  -  total flux cleaned = 0.169984 Jy
! Component: 150  -  total flux cleaned = 0.212078 Jy
! Component: 200  -  total flux cleaned = 0.241388 Jy
! Total flux subtracted in 200 components = 0.241388 Jy
! Clean residual min=-0.007015 max=0.017869 Jy/beam
! Clean residual mean=0.001204 rms=0.004068 Jy/beam
! Combined flux in latest and established models = 2.06009 Jy
! Adding 61 model components to the UV plane model.
! The established model now contains 76 components and 2.06009 Jy
! Inverting map 
! Your choice of large map pixels excluded 0.485% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
! Added new window around map position (0, 1.4).
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.021548 Jy
! Component: 100  -  total flux cleaned = 0.0372159 Jy
! Component: 150  -  total flux cleaned = 0.0488436 Jy
! Component: 200  -  total flux cleaned = 0.0575591 Jy
! Total flux subtracted in 200 components = 0.0575591 Jy
! Clean residual min=-0.004871 max=0.005040 Jy/beam
! Clean residual mean=0.000352 rms=0.001535 Jy/beam
! Combined flux in latest and established models = 2.11765 Jy
! Adding 43 model components to the UV plane model.
! The established model now contains 109 components and 2.11765 Jy
! Inverting map 
! Your choice of large map pixels excluded 0.485% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
uvtaper 0.3,taper_size
! Gaussian taper: value 0.3 at UV radius = 70 mega-wavelengths.
clean clean_niter,clean_gain
! Inverting map and beam 
! Your choice of large map pixels excluded 0.485% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
! Estimated beam: bmin=2.271 mas, bmaj=3.222 mas, bpa=-3.55 degrees
! Estimated noise=516.872 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.0101434 Jy
! Component: 100  -  total flux cleaned = 0.0160076 Jy
! Component: 150  -  total flux cleaned = 0.0197419 Jy
! Component: 200  -  total flux cleaned = 0.0223585 Jy
! Total flux subtracted in 200 components = 0.0223585 Jy
! Clean residual min=-0.004432 max=0.003937 Jy/beam
! Clean residual mean=0.000067 rms=0.001335 Jy/beam
! Combined flux in latest and established models = 2.14001 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.00184657 Jy
! Component: 100  -  total flux cleaned = 0.00297464 Jy
! Component: 150  -  total flux cleaned = 0.00332441 Jy
! Component: 200  -  total flux cleaned = 0.00360097 Jy
! Total flux subtracted in 200 components = 0.00360097 Jy
! Clean residual min=-0.004218 max=0.003646 Jy/beam
! Clean residual mean=-0.000049 rms=0.001295 Jy/beam
! Combined flux in latest and established models = 2.14361 Jy
! Adding 57 model components to the UV plane model.
! The established model now contains 157 components and 2.14361 Jy
! Inverting map 
! Your choice of large map pixels excluded 0.485% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
uvtaper 0,0
! No UV-taper is currently set.
clean
! Inverting map and beam 
! Your choice of large map pixels excluded 0.485% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
! Estimated beam: bmin=0.9065 mas, bmaj=2.02 mas, bpa=-9.768 degrees
! Estimated noise=429.923 mJy/beam.
! clean: niter=200  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = -0.00109544 Jy
! Component: 100  -  total flux cleaned = -0.000674412 Jy
! Component: 150  -  total flux cleaned = -0.000307859 Jy
! Component: 200  -  total flux cleaned = -6.33949e-05 Jy
! Total flux subtracted in 200 components = -6.33949e-05 Jy
! Clean residual min=-0.004265 max=0.003510 Jy/beam
! Clean residual mean=-0.000029 rms=0.001008 Jy/beam
! Combined flux in latest and established models = 2.14354 Jy
selfcal
! Performing phase self-cal
! Adding 20 model components to the UV plane model.
! The established model now contains 169 components and 2.14354 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=2.602669Jy  sigma=0.001356
! Fit after  self-cal, rms=2.602557Jy  sigma=0.001356
wmodel J0339-0146_X_1999_05_10_pus_map.mod
! Writing 169 model components to file: J0339-0146_X_1999_05_10_pus_map.mod
wobs J0339-0146_X_1999_05_10_pus_uvs.fits
! Writing UV FITS file: J0339-0146_X_1999_05_10_pus_uvs.fits
wwins J0339-0146_X_1999_05_10_pus_map.win
! wwins: Wrote 4 windows to J0339-0146_X_1999_05_10_pus_map.win
x = (field_size-8) * field_cell / 4
addwin -x,x,-x,x
clean (field_size*4),0.01
! Inverting map 
! Your choice of large map pixels excluded 0.485% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
! clean: niter=1024  gain=0.01  cutoff=0
! Component: 050  -  total flux cleaned = -0.000980684 Jy
! Component: 100  -  total flux cleaned = -0.00110237 Jy
! Component: 150  -  total flux cleaned = -0.00132925 Jy
! Component: 200  -  total flux cleaned = -0.00175964 Jy
! Component: 250  -  total flux cleaned = -0.00216825 Jy
! Component: 300  -  total flux cleaned = -0.00236337 Jy
! Component: 350  -  total flux cleaned = -0.00240885 Jy
! Component: 400  -  total flux cleaned = -0.00227175 Jy
! Component: 450  -  total flux cleaned = -0.00218312 Jy
! Component: 500  -  total flux cleaned = -0.00205309 Jy
! Component: 550  -  total flux cleaned = -0.00196845 Jy
! Component: 600  -  total flux cleaned = -0.0018845 Jy
! Component: 650  -  total flux cleaned = -0.00176079 Jy
! Component: 700  -  total flux cleaned = -0.00168003 Jy
! Component: 750  -  total flux cleaned = -0.00168012 Jy
! Component: 800  -  total flux cleaned = -0.00167957 Jy
! Component: 850  -  total flux cleaned = -0.00164091 Jy
! Component: 900  -  total flux cleaned = -0.00160363 Jy
! Component: 950  -  total flux cleaned = -0.0015674 Jy
! Component: 1000  -  total flux cleaned = -0.00156727 Jy
! Total flux subtracted in 1024 components = -0.00149571 Jy
! Clean residual min=-0.001784 max=0.002158 Jy/beam
! Clean residual mean=0.000011 rms=0.000713 Jy/beam
! Combined flux in latest and established models = 2.14205 Jy
keep
! Adding 62 model components to the UV plane model.
! The established model now contains 231 components and 2.14205 Jy
![Exited script file: muppet]
wmap "J0339-0146_X_1999_05_10_pus\_map.fits"
! Inverting map 
! Your choice of large map pixels excluded 0.485% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
! restore: Substituting estimate of restoring beam from last 'invert'.
! Restoring with beam: 0.9065 x 2.02 at -9.768 degrees (North through East)
! Clean map  min=-0.0035753  max=1.6778 Jy/beam
! Writing clean map to FITS file: J0339-0146_X_1999_05_10_pus_map.fits
float peak_flux
peak_flux = peak(flux,max)
print "The peak flux is",peak_flux
! The peak flux is 1.67778 
invert
! Inverting map 
! Your choice of large map pixels excluded 0.485% of the data.
!  The x-axis pixel size should ideally be below 0.1702 milli-arcsec
!  The y-axis pixel size should ideally be below 0.1898 milli-arcsec
float image_rms
image_rms = imstat(rms)
print "The final image rms is",image_rms
! The final image rms is 0.000712562 
device "J0339-0146_X_1999_05_10_pus\_map.eps/VPS"
! Attempting to open device: 'J0339-0146_X_1999_05_10_pus_map.eps/VPS'
loglevs 100*3*image_rms/peak_flux
! The new contour levels are:
!  -0.127412 0.127412 0.254823 0.509646 1.01929 2.03859 4.07717 8.15434 16.3087 32.6174 65.2347
print "clev=",int(3*image_rms*10000)/10000
! clev= 0.0021 
print "peak=",int(1000*peak_flux)/1000
! peak= 1.677 
mapcolor none
! Mapplot colormap: none, contrast: 1 brightness: 0.5.
mapplot cln
! restore: Substituting estimate of restoring beam from last 'invert'.
! Restoring with beam: 0.9065 x 2.02 at -9.768 degrees (North through East)
! Clean map  min=-0.0035753  max=1.6778 Jy/beam
mapcolor color, 0.9
! Mapplot colormap: rainbow, contrast: 0.9 brightness: 0.5.
device "J0339-0146_X_1999_05_10_pus\_map.gif/vgif"
! Attempting to open device: 'J0339-0146_X_1999_05_10_pus_map.gif/vgif'
mapplot cln
quit
! Quitting program
! Log file J0339-0146_X_1999_05_10_pus_uvs.log closed on Mon Jan 14 12:33:30 2008