Museum

Home

Lab Overview

Retrotechnology Articles

⇒ Online Manual

Media Vault

Software Library

Restoration Projects

Artifacts Sought

VEC_$IINIT                        Domain/OS                         VEC_$IINIT


NAME
     vec_$iinit - initialize a 32-bit integer vector

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

     void vec_$iinit(
          long *vector,
          long int &length,
          long &constant)

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

     procedure vec_$iinit(
          var vector: univ vec_$integer32_vector;
          in length: integer32;
          in constant: integer32);

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

           parameter (nvec = 10)

           integer*4 vector(nvec), constant
           integer*4 length

           call vec_$iinit(vector, length, constant)

DESCRIPTION
     Vec_$iinit sets length elements of vector to the 32-bit integer value
     constant.

     In C, the resulting operation is

          for (i = 0; i < length; ++i)
               vector[i] = constant;

     In Pascal, the resulting operation is

          for i := 1 to length do
               begin
               vector[i] := constant;
               end

     In FORTRAN, the resulting operation is

           do 10 i = 1, length
               vector(i) = constant
       10  continue

     vector
          The vector to initialize.

     length
          The number of elements in vector to initialize.

     constant
          The value that the elements of vector should be set to.

NOTES
     In C and Pascal, vec_$iinit initializes a row vector; whereas in FORTRAN,
     it initializes a column vector.

SEE ALSO
     vec_$dinit, vec_$iinit16, vec_$iinit_i, vec_$init.

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