; BY
;---------------------------------------------------------------
;! gives increment to use in FOR loops in POPS language
;# Verb POPS
;-----------------------------------------------------------------------
;;  Copyright (C) 1995, 2017
;;  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
;-----------------------------------------------------------------------
;---------------------------------------------------------------
BY        LLLLLLLLLLLLUUUUUUUUUUUU CCCCCCCCCCCCCCCCCCCCCCCCCCCCC
----------------------------------------------------------------
BY
Type:  Verb
Use:   In the FOR loop construction BY is used to signal the value by
       which to increment the incrementing variable.  (See HELP FOR).
       This value may be negative. The inclusion of BY is optional. If
       omitted, the increment will default to 1.
Grammar:  FOR variable = start TO fini BY increment
             statement1; statement2;... ; END
       where 'variable' is a scalar variable that will change each
       time through the loop, beginning at 'start', have 'increment'
       added to it each time through the loop (the increment may be
       positive or negative) and will end when the next loop would be
       executed with 'variable' greater than (increment > 0; less than
       with increment < 0) 'fini'.  Note that the loop will be
       executed at least once no matter what the start, fini and
       increment parameters are. If the BY section is omitted, the
       increment will default to 1.

       Statementi are AIPS statements.  These statements may not
       have an omitted optional immediate numeric argument.  Such
       statements depend on the POPS stack being empty in the absence
       of the argument.  But the FOR loop uses the stack for the
       'fini' and 'increment' values and so the stack is not empty.
       Thus TVON with no argument will see a non-empty stack and
       assume that it is getting an immediate argument from the stack.
       Use in this case TVON(2**(TVCHAN-1)) inside your loop.

       Verbs of this sort include EHEX, GROFF, GRON, HUEWEDGE,
       IMWEDGE, REHEX, TVOFF, TVON, TVWEDGE.

Example:   FOR I = K+3 TO K BY -1; A(I+1) = A(I); END
       This example will shift the section of array A between
       A(K) and A(K+3) forward 1 element.
----------------------------------------------------------------
