! Started logfile: 1640-231_S.log on Thu Nov  2 15:25:13 2006
observe 1640-231_S.edt
! Reading UV FITS file: 1640-231_S.edt
! AN table 1: 164 integrations on 136 of 136 possible baselines.
! Apparent sampling: 0.0754125 visibilities/baseline/integration-bin.
! *** This seems a bit low - see "help observe" on the binwid argument.
! Found source: 1640-231
! Warning: Unknown AN-table MNTSTA value (4).
!          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 1577 lines of history.
! 
! Reading 6728 visibilities.
![@gonzo12-0.4_0537 1640-231_S]
print "***********************************"
! *********************************** 
print "*** Using gonzo instruction set ***"
! *** Using gonzo instruction set *** 
print "***********************************"
! *********************************** 
float field_size
field_size = 1024
float field_cell
field_cell = 0.4
integer clean_niter
clean_niter = 50
float clean_gain
clean_gain = 0.03
float dynam
dynam = 12.0
float win_mult
win_mult = 0.7
float solint
solint = 3.6/6.0
logical doflt
doflt = true
logical doamp
float new_peak
float flux_cutoff
mapsize field_size,field_cell
! Map grid = 1024x1024 pixels with 0.400x0.400 milli-arcsec cellsize.
select
! 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
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 2017 telescope corrections were flagged in sub-array 1.
! 
! Correcting IF 2.
!  A total of 2049 telescope corrections were flagged in sub-array 1.
! 
! Correcting IF 3.
!  A total of 2017 telescope corrections were flagged in sub-array 1.
! 
! Correcting IF 4.
!  A total of 2070 telescope corrections were flagged in sub-array 1.
! 
! Fit before self-cal, rms=0.820592Jy  sigma=0.011889
! Fit after  self-cal, rms=0.820557Jy  sigma=0.011890
! clrmod: Cleared the established, tentative and continuum models.
! Redundant starting model cleared.
uvweight 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.
doamp = false
flux_cutoff = imstat(rms) * dynam
! Inverting map and beam 
! Estimated beam: bmin=8.19 mas, bmaj=20.97 mas, bpa=-0.8037 degrees
! Estimated noise=1226.8 mJy/beam.
repeat
  if (peak(flux) > flux_cutoff) peakwin win_mult
  clean clean_niter,clean_gain
  flux_cutoff = imstat(rms) * dynam
  selfcal doamp, doflt, solint
  new_peak = peak(flux)
  until(new_peak<=flux_cutoff)
! clean: niter=50  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.129694 Jy
! Total flux subtracted in 50 components = 0.129694 Jy
! Clean residual min=-0.016571 max=0.039241 Jy/beam
! Clean residual mean=0.001436 rms=0.007877 Jy/beam
! Combined flux in latest and established models = 0.129694 Jy
! Performing phase self-cal over 0.6 minute time intervals
! Adding 11 model components to the UV plane model.
! The established model now contains 11 components and 0.129694 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.104343Jy  sigma=0.001460
! Fit after  self-cal, rms=0.104330Jy  sigma=0.001460
! Inverting map 
print "****************************************"
! **************************************** 
print "*** Finished Uniform Weighting CLEAN ***"
! *** Finished Uniform Weighting CLEAN *** 
print "****************************************"
! **************************************** 
uvweight 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
doamp = false
flux_cutoff = imstat(rms) * dynam
! Inverting map and beam 
! Estimated beam: bmin=9.845 mas, bmaj=24.16 mas, bpa=0.9382 degrees
! Estimated noise=638.723 mJy/beam.
repeat
  if (peak(flux) > flux_cutoff) peakwin win_mult
  clean clean_niter,clean_gain
  flux_cutoff = imstat(rms) * dynam
  selfcal doamp, doflt, solint
  new_peak = peak(flux)
  until(new_peak<=flux_cutoff)
! clean: niter=100  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.0516781 Jy
! Component: 100  -  total flux cleaned = 0.0764894 Jy
! Total flux subtracted in 100 components = 0.0764894 Jy
! Clean residual min=-0.006404 max=0.011554 Jy/beam
! Clean residual mean=0.000940 rms=0.003195 Jy/beam
! Combined flux in latest and established models = 0.206184 Jy
! Performing phase self-cal over 0.6 minute time intervals
! Adding 37 model components to the UV plane model.
! The established model now contains 43 components and 0.206184 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.078728Jy  sigma=0.001099
! Fit after  self-cal, rms=0.078629Jy  sigma=0.001097
! Inverting map 
print "****************************************"
! **************************************** 
print "*** Finished Natural Weighting CLEAN ***"
! *** Finished Natural Weighting CLEAN *** 
print "****************************************"
! **************************************** 
gscale true
! Performing overall amplitude self-cal
! 
! Correcting IF 1.
!  A total of 36 telescope corrections were flagged in sub-array 1.
!  Telescope amplitude corrections in sub-array 1:
!   BR        1.09     FD        0.95     HN        1.00*    HO        1.00*    
!   KP        1.00*    LA        0.91     MK        1.00*    NL        1.02     
!   NY        1.00*    OV        0.99     PT        0.91     MC        1.00*    
!   SC        1.00*    SV        1.00*    TC        1.00*    WF        1.00*    
!   WZ        1.00*    
! 
! 
! Correcting IF 2.
!  A total of 39 telescope corrections were flagged in sub-array 1.
!  Telescope amplitude corrections in sub-array 1:
!   BR        1.02     FD        0.96     HN        1.00*    HO        1.00*    
!   KP        1.00*    LA        0.89     MK        1.00*    NL        1.01     
!   NY        1.00*    OV        1.01     PT        0.94     MC        1.00*    
!   SC        1.00*    SV        1.00*    TC        1.00*    WF        1.00*    
!   WZ        1.00*    
! 
! 
! Correcting IF 3.
!  A total of 36 telescope corrections were flagged in sub-array 1.
!  Telescope amplitude corrections in sub-array 1:
!   BR        1.09     FD        0.95     HN        1.00*    HO        1.00*    
!   KP        1.00*    LA        0.91     MK        1.00*    NL        1.06     
!   NY        1.00*    OV        1.04     PT        0.96     MC        1.00*    
!   SC        1.00*    SV        1.00*    TC        1.00*    WF        1.00*    
!   WZ        1.00*    
! 
! 
! Correcting IF 4.
!  A total of 36 telescope corrections were flagged in sub-array 1.
!  Telescope amplitude corrections in sub-array 1:
!   BR        1.18     FD        0.96     HN        1.00*    HO        1.00*    
!   KP        1.00*    LA        0.91     MK        1.00*    NL        1.07     
!   NY        1.00*    OV        0.98     PT        0.94     MC        1.00*    
!   SC        1.00*    SV        1.00*    TC        1.00*    WF        1.00*    
!   WZ        1.00*    
! 
! 
! Fit before self-cal, rms=0.078629Jy  sigma=0.001097
! Fit after  self-cal, rms=0.072945Jy  sigma=0.001068
dynam = dynam - 0.5
doamp = false
flux_cutoff = imstat(rms) * dynam
! Inverting map and beam 
! Estimated beam: bmin=10.13 mas, bmaj=24.45 mas, bpa=0.8595 degrees
! Estimated noise=611.559 mJy/beam.
repeat
  if (peak(flux) > flux_cutoff) peakwin win_mult
  clean clean_niter,clean_gain
  flux_cutoff = imstat(rms) * dynam
  selfcal doamp, doflt, solint
  new_peak = peak(flux)
  until(new_peak<=flux_cutoff)
! clean: niter=100  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.0070817 Jy
! Component: 100  -  total flux cleaned = 0.00919629 Jy
! Total flux subtracted in 100 components = 0.00919629 Jy
! Clean residual min=-0.002969 max=0.002953 Jy/beam
! Clean residual mean=0.000127 rms=0.001142 Jy/beam
! Combined flux in latest and established models = 0.21538 Jy
! Performing phase self-cal over 0.6 minute time intervals
! Adding 37 model components to the UV plane model.
! The established model now contains 80 components and 0.21538 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.072104Jy  sigma=0.001056
! Fit after  self-cal, rms=0.072100Jy  sigma=0.001055
! Inverting map 
dynam = dynam - 1.0
doamp = true
solint = solint * (6.0/3.6)
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 doamp, doflt, solint
  new_peak = peak(flux)
  until(new_peak<=flux_cutoff)
! clean: niter=100  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.000576311 Jy
! Component: 100  -  total flux cleaned = 0.000560343 Jy
! Total flux subtracted in 100 components = 0.000560343 Jy
! Clean residual min=-0.001975 max=0.001963 Jy/beam
! Clean residual mean=0.000069 rms=0.000804 Jy/beam
! Combined flux in latest and established models = 0.21594 Jy
! Performing amp+phase self-cal over 1 minute time intervals
! Adding 41 model components to the UV plane model.
! The established model now contains 117 components and 0.21594 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.071838Jy  sigma=0.001052
! Fit after  self-cal, rms=0.071285Jy  sigma=0.001022
! Inverting map and beam 
! Estimated beam: bmin=10.14 mas, bmaj=24.55 mas, bpa=0.6836 degrees
! Estimated noise=614.401 mJy/beam.
doamp = false
solint = solint / (6.0/3.6)
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 doamp, doflt, solint
  new_peak = peak(flux)
  until(new_peak<=flux_cutoff)
! clean: niter=100  gain=0.03  cutoff=0
! Component: 050  -  total flux cleaned = 0.00204642 Jy
! Component: 100  -  total flux cleaned = 0.00271924 Jy
! Total flux subtracted in 100 components = 0.00271924 Jy
! Clean residual min=-0.001242 max=0.001253 Jy/beam
! Clean residual mean=0.000081 rms=0.000518 Jy/beam
! Combined flux in latest and established models = 0.21866 Jy
! Performing phase self-cal over 0.6 minute time intervals
! Adding 33 model components to the UV plane model.
! The established model now contains 150 components and 0.21866 Jy
! 
! Correcting IF 1.
! 
! Correcting IF 2.
! 
! Correcting IF 3.
! 
! Correcting IF 4.
! 
! Fit before self-cal, rms=0.071165Jy  sigma=0.001020
! Fit after  self-cal, rms=0.071160Jy  sigma=0.001020
! Inverting map 
print "***********************************"
! *********************************** 
print "*** Finished Amplitude Self-Cal ***"
! *** Finished Amplitude Self-Cal *** 
print "***********************************"
! *********************************** 
save 1640-231_S
! Writing UV FITS file: 1640-231_S.uvf
! Writing 150 model components to file: 1640-231_S.mod
! restore: Substituting estimate of restoring beam from last 'invert'.
! Restoring with beam: 10.14 x 24.55 at 0.6836 degrees (North through East)
! Clean map  min=-0.0024638  max=0.17394 Jy/beam
! Writing clean map to FITS file: 1640-231_S.fits
! Writing difmap environment to: 1640-231_S.par
print "****************************"
! **************************** 
print "*** Now, make some plots ***"
! *** Now, make some plots *** 
print "****************************"
! **************************** 
![@gonzo_plot 1640-231_S]
device 1640-231_Suv.ps/vps,1,2
! Attempting to open device: '1640-231_Suv.ps/vps'
radplot
! Using default options string "m1"
uvplot
! Using default options string ""
device 1640-231_Sim.ps/vps
! Attempting to open device: '1640-231_Sim.ps/vps'
uvweight 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.
loglevs -1,2048,2
! The new contour levels are:
!  -1 1 2 4 8 16 32 64 128 256 512 1024 2048
cmul = imstat(rms)*3
! Inverting map and beam 
! Estimated beam: bmin=10.14 mas, bmaj=24.55 mas, bpa=0.6836 degrees
! Estimated noise=614.401 mJy/beam.
mappl cln
! restore: Substituting estimate of restoring beam from last 'invert'.
! Restoring with beam: 10.14 x 24.55 at 0.6836 degrees (North through East)
! Clean map  min=-0.0024638  max=0.17394 Jy/beam
![Exited script file: gonzo_plot]
![Exited script file: gonzo12-0.4_0537]
quit
! Quitting program
! Log file 1640-231_S.log closed on Thu Nov  2 15:25:39 2006