; STEER
;---------------------------------------------------------------
;! Task which deconvolves the David Steer way.
;# TASK IMAGING
;-----------------------------------------------------------------------
;;  Copyright (C) 1995
;;  Associated Universities, Inc. Washington DC, USA.
;;
;;  This program is free software; you can redistribute it and/or
;;  modify it under the terms of the GNU General Public License as
;;  published by the Free Software Foundation; either version 2 of
;;  the License, or (at your option) any later version.
;;
;;  This program is distributed in the hope that it will be useful,
;;  but WITHOUT ANY WARRANTY; without even the implied warranty of
;;  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
;;  GNU General Public License for more details.
;;
;;  You should have received a copy of the GNU General Public
;;  License along with this program; if not, write to the Free
;;  Software Foundation, Inc., 675 Massachusetts Ave, Cambridge,
;;  MA 02139, USA.
;;
;;  Correspondence concerning AIPS should be addressed as follows:
;;         Internet email: aipsmail@nrao.edu.
;;         Postal address: AIPS Project Office
;;                         National Radio Astronomy Observatory
;;                         520 Edgemont Road
;;                         Charlottesville, VA 22903-2475 USA
;-----------------------------------------------------------------------
;---------------------------------------------------------------
STEER     LLLLLLLLLLLLUUUUUUUUUUUU CCCCCCCCCCCCCCCCCCCCCCCCCCCCC
STEER :  Task which deconvolves the David Steer way.
                                   Dirty image
INNAME                                Image name (name)
INCLASS                               Image name (class)
INSEQ              0.0      9999.0    Image name (seq. #)
INDISK             0.0         4.0    Image disk drive #
                                   Beam image
IN2NAME                               Image name (name)
IN2CLASS                              Image name (class)
IN2SEQ             0.0      9999.0    Image name (seq. #)
IN2DISK            0.0         4.0    Image disk drive #
                                   Steer  image
OUTNAME                               Image name (name)
OUTCLASS                              Image name (class)
OUTSEQ            -1.0      9999.0    Image name (seq. #)
OUTDISK            0.0         4.0    Image disk drive #

GAIN              -1.0         1.0 Steer loop gain
NITER              0.0     32767.0 Maximum # of iterations
DOTV              -1.0         1.0 TV display of residuals?
NBOXES             0.0        10.0 Number of boxes
BOX                0.0      4096.0 Four coordinates for each box
BADDISK           -1.0      1000.0 Disks to avoid for scratch.
OFFSET            -1.0      1000.0 Trim level
----------------------------------------------------------------
STEER
Type: Task
Use: STEER  deconvolves the dirty beam from the dirty map thus
producing a map with the units of brightness (Jy/pixel).
Conversion to other units e.g. KELVIN can be done with AXDEFINE.
STEER  may be restarted if further improvement is desired. This
program is slow but should be comparable to APCLN if the map
contains many picture elements. The task CONVL may be used to
convolve the map to the resolution produced by a CLEAN program.
     The algorithm used in the program is due to David Steer.
The principle is similar to Barry Clark's CLEAN except that in
the minor cycle only points above the (trim level)*(peak in
the residual map) are selected. In the major cycle these are
removed using an FFT. If the BOXes are chosen to surround the
source snugly then the algorithm will converge faster and will
have more chance of finding a unique image.
     This is an experimental program; please relay any
complaints etc. to Tim Cornwell at the VLA
Adverbs:
  INNAME......The dirty image name.   Standard defaults.
  INCLASS.....The dirty image class.  Standard defaults.
  INSEQ.......The dirty image seq. #. 0 => highest.
  INDISK......The dirty image disk drive #. 0 => any
  IN2NAME.....The beam image name.  blank => actual
              INNAME, otherwise standard defaults.
  IN2CLASS....The beam image class.  Standard defaults
              except blank => 'RBEM' if INCLASS = 'RMAP'
                 'LBEM' if INCLASS = 'LMAP'
                 'IBEM' if INCLASS = anything else
  IN2SEQ......The beam image seq . #.  0 => actual INSEQ
  IN2DISK.....The beam image disk drive #.  0 => any
  OUTNAME.....The Steer image name.  blank => Standard defaults
              based on INNAME.
  OUTCLASS....The Steer image class.  Standard behavior with
              default =   'XGS ' if INCLASS = 'XMAP'
  OUTSEQ......The Steer image seq. #.  0 => highest unique
              If >0; image will be created if new,
              overwritten if image name exists.
  OUTDISK.....The Steer disk drive no. 0 => highest with space
  GAIN........The Steer loop gain.  0 => 0.01, for most cases
                0.02 will work well.
  NITER.......Steer iteration limit.  0 => 20
  DOTV........Display Steer map on TV channel 1. > 0 => yes.
              If true, you may stop the Steering with TV button
              D after each Steer map is displayed.
  NBOXES......The number of rectangular boxes.  The Steer image
              is non-zero only within these boxes. 0=>1
  BOX.........A 4x10 array with the BLC and TRC of each box.
              0 => use inner quarter of input map (first box)
              0 => ignore box (boxes 2 - 10)
  BADDISK.....This array contains the numbers of disks on which
              it is desired that scratch files not be located.
              BADDISK has no effect on input and output maps.
  OFFSET......The Trim Level. In a minor cycle only points
              above this fraction of the peak residual are
              selected. 0.8 works well.
----------------------------------------------------------------
