BIMA Memoranda No. 30 IMAGING WITH THE BIMA ARRAY Melvyn Wright, 29-Jul-93 SUMMARY This memo provides an easy recipe for calibrating and imaging data from the BIMA array. Images can be made automatically, although at present the data must be edited to obtain the best dynamic range. AUTOMATIC IMAGING The Miriad script "Autocal" is a csh script to calibrate and image uv data. The user specifies a calibrator uvfile and line type to be used for the antenna gain calibration versus time, and a source uvfile and line type to be imaged. The antenna gains are derived from the calibration data with a 40 min time interval and applied to the source data. The script plots the calibrator amplitude and phase versus time, the antenna gains, and images of the calibrator and source. At present the data reduction is best iterated between editing the data and running Autocal to inspect the data and image quality. The data selection parameter in Autocal is used to select both calibrator and source data and provides an easy way to look at the image quality using different time ranges or antennae. e.g. to omit baseline 14 select '-ant(1)(4)'. #* Autocal - A-priori calibration using selfcal #: user tool #+ # Inputs: # P1 uvdata file for calibrator # P2 uvdata file for source # P3 PGPLOT device. e.g. /xw (if P3 = /ps , plots are printed) # P4 MIRIAD line type for calibrator. e.g. wide,1 # P5 MIRIAD line type for source, e.g. channel,4,40,4,10 # P6 MIRIAD data select. e.g. 'amp(0,30),-ant(1)(3)' # Outputs: # calibrator map and cleaned image. # source map and cleaned image. # set some parameters: set refant=5 set cell=2 set imsize=128 set nxy=3,5 set ngp=3,3 set minants=3 set interval=40 There are some fixed parameters in the script which are suitable for the 6-antenna BIMA array, but the you may wish to copy $MIRBIN/Autocal to your own directory and customize it to do your complete data reduction and imaging. EDITING THE UV DATA At present there are some correlator problems which produce bad values in the lag data. These usually show up as spectral windows with high amplitudes in about 1% of the data. Other problems may result in multiple phase jumps; the data is best omitted if it looks like this is happening. High atmospheric phase noise, or instrumental problems, result in loss of correlation, or wrong phases, and should be flagged. Amplitudes which are too high or too low can be easily flagged for all the data. You will need to do this separately for the calibrator and the source using estimates of the expected source flux density and the instrumental noise level. Remember that the uncalibrated data is in units of antenna temperature, (flux density) / (Jy/K). The average antenna gain at present is about 150 Jy/K. e.g. for a 1.5 Jy source uvflag vis=$filename flagval=flag 'select=-amp(.001,.1)' will flag bad all data, both spectral and wideband channels, whose amplitudes are not between 0.001 and 0.1 K ( 0.15 and 15 Jy ). You may wish to be more or less conservative, but in any case the process is best iterated between inspections of the data and image quality. Phases are the best indicator of correlation. If the calibrator phase is very scattered, or shows phase jumps, then these time intervals are best flagged bad for both calibrator and source data. This takes more detailed uv data selection in uvflag. Type "help select" for more details. SPECTRAL IMAGING Autocal can be used to make spectral images by selecting a spectral line type for the source. At present the on-line passband calibration is quite poor and the instrumental passband is both time and baseline dependent. The gains of the spectral windows are not completely removed by the on-line passband calibration. Accordingly, it is best to calibrate the passband for each baseline and spectral window. The Miriad task "uvgains" can be used to derive a passband gain for each channel and baseline from a strong source such as a planet observation. This channel dependent passband can only be applied if the passband calibrator and source are observed using the same correlator configuration. Because of the baseline and channel dependence, antenna based passband calibration, or observations using a different correlator configuration for source and passband calibrator are likely to be less successful at present, but will become the preferred methods when the baseline dependent passband is removed on-line. In either case, the passband should be referenced to the line used to calibrate the gains versus time in Autocal. Any time dependence of the instrumental passband is not corrected. See BIMA memo 19 for a more general discussion of calibration. In general the passband is applied automatically by Miriad tasks when plotting (uvplt, uvspec), copying (uvcat, uvcal, uvaver, uvgains), or imaging (invert), but the channel dependent gains are not interpolated and can only be applied if all the channels are used, i.e. in plotting, or imaging all the channels. To plot or image other line types the channel gains must first be applied by copying the channel gains into the Miriad dataset to be corrected (copyhd), and writing all the channels into a corrected Miriad dataset (uvcat, uvcal). Examples: To derive the channel gains relative to the wideband: uvgains vis=mars.12apr out=pass interval=1000 ref=wide,1 To apply the gains to another file: copyhd in=pass out=omc1.12apr items=ncgains,cgains,ncbase To plot the passband corrected spectra: uvspec vis=omc1.12apr device=/xw To plot the spectra without the passband correction: uvspec vis=omc1.12apr device=/xw options=nopass To plot or image other line types, first write a corrected dataset: uvcat vis=omc1.12apr out=omc1.12apr.pass