Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ vec_irmax(A) — Apollo Domain/OS SR10.4.1

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

vec_$rmin

vec_$amax

vec_$amin

vec_$rmax_i

vec_$drmax

vec_$drmax_i

vec_$rmax

vec_$irmax_i

vec_$irmax16

vec_$irmax16_i

VEC_$IRMAX                        Domain/OS                         VEC_$IRMAX


NAME
     vec_$irmax - find the maximum value in a 32-bit integer vector

SYNOPSIS (C)
     #include <apollo/base.h>
     #include <apollo/vec.h>

     long int vec_$irmax(
          long int *start_vec,
          long int &length,
          long int *result)

SYNOPSIS (Pascal)
     %include '/sys/ins/base.ins.pas';
     %include '/sys/ins/vec.ins.pas';

     function vec_$irmax(
          in start_vec: univ vec_$integer32_vector;
          in length: integer32;
          out result: integer32): integer32;

SYNOPSIS (FORTRAN)
     %include '/sys/ins/base.ins.ftn'
     %include '/sys/ins/vec.ins.ftn'

           parameter (nvec = 10)

           integer*4 start_vec(nvec), result
           integer*4 length, location

           location = vec_$irmax(start_vec, length, result)

DESCRIPTION
     Vec_$irmax searches through length elements of start_vec, sets location
     to the greatest element, and returns the location of the element with the
     greatest value. By contrast, vec_$iamax finds the element with greatest
     absolute value.  vec_$irmax differs from vec_$imax in being a function
     instead of a procedure; vec_$imax is now obsolete.

     In the case of a tie, vec_$irmax returns the index of the first maximum
     value found.

     start_vec
          The vector to be searched.

     length
          The number of elements to be operated on;  normally the same as the
          number of elements in the vectors.

     result
          The value of the greatest element in start_vec.

NOTES
     In C and Pascal, vec_$irmax searches a row vector; in FORTRAN, it
     searches a column vector.


SEE ALSO
     vec_$rmin, vec_$amax, vec_$amin, vec_$rmax_i, vec_$drmax, vec_$drmax_i,
     vec_$rmax, vec_$irmax_i, vec_$irmax16, vec_$irmax16_i.

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026