The VEC_ routines are a set of subroutines which perform arithmetic, mathematical operations and type conversion on vectorised arrays of data stored using any numerical type. They incorporate handling of numerical errors and propagation of the standard bad values in a way that is fully compatible with the VAL_ functions.
VEC_ routines are invoked by statements of the form:
CALL VEC_name
![]()
( BAD, N, ARG, RESULT, IERR, NERR, STATUS )or CALL VEC_name
![]()
( BAD, N, ARG1, ARG2, RESULT, IERR, NERR, STATUS )
where
name
specifies the operation to be performed and:
- BAD is a logical value specifying whether bad input arguments are to be recognised;
- N is an integer value specifying the number of array elements to process;
- ARG, ARG1 and ARG2 are the input arguments (each is an N-element vectorised array);
- RESULT is an N-element vectorised output array;
- IERR is an integer output argument which identifies the first array element to generate a numerical error;
- NERR is an integer output argument which returns a count of the number of numerical errors which occur;
- STATUS is an integer error status variable.
PRIMDAT --- Processing of Primitive Numerical Data