====================================================================
icamax examples
====================================================================

a:PRIMARR(COMPLEX(FLOAT))

a:=[[3.+4.*%i,-4.+5.*%i,5.+6.*%i,7.-8.*%i,-9.-2.*%i]]

  [3.0 + 4.0 %i,- 4.0 + 5.0 %i,5.0 + 6.0 %i,7.0 - 8.0 %i,- 9.0 - 2.0 %i]

Note that Axiom arrays are 0-based

icamax(5,a,1)  -- should be 3

  3

If the arguments are not valid, return an invalid array index

The count must be greater than 0.

icamax(0,a,1)  -- should be -1

  - 1

The increment must be positive

icamax(5,a,-1) -- should be -1

  - 1

icamax(3,a,1)  -- should be 2

  2

icamax(3,a,2)  -- should be 1

  1

====================================================================
Man Page Details
====================================================================

NAME
       ICAMAX - BLAS level one, maximum index function

SYNOPSIS
       INTEGER FUNCTION ICAMAX ( n, x, incx )

           INTEGER               n, incx

           COMPLEX               x


DESCRIPTION
       ICAMAX  searches a complex vector for the first occurrence of the maxi-
       mum absolute value.

       ICAMAX determines the first index i such that

       |Real(x )|+ |Imag(x ) | = MAX(|Real(x )| + | Imag(x )|): j = 1, ..., n
              i           i                 j             j
               where x  is an element of a complex vector.
                      j

ARGUMENTS
       n       INTEGER. (input)
               Number of elements to process in the vector to be searched.  If
               n <= 0, these routines return 0.

       x       COMPLEX. (input)
               Array of dimension (n-1) * |incx| + 1.
               Array x contains the vector to be searched.

       incx    INTEGER. (input)
               Increment between elements of x.

RETURN VALUES
       ICAMAX  INTEGER. (output)
               Return  the first index of the maximum absolute value of vector
               x.  The vector x has length n and increment incx.

NOTES
       When working backward (incx < 0), each routine starts at the end of the
       vector and moves backward, as follows:

            x(1-incx * (n-1)), x(1-incx * (n-2)), ..., x(1)

       The largest absolute value is:

            ABS (x(1+(index-1) * incx)) when incx > 0

            ABS (x(1+(n-index) * |incx|)) when incx < 0

