NAME

     libvector - CVIPtools toolkit library for performing  vector
     algebra and manipulation

SYNOPSIS

     #include <CVIPvector.h>

FUNCTIONS

     The following functions are included in this manpage:

                           band2pixel_Vector
                           convolve_Vector
                           copy_Vector
                           findHisto_Vector
                           findMaxVal_Vector
                           findMinVal_Vector
                           normalize_Vector
                           pixel2band_Vector
                           printHisto_Vector
                           subSample_Vector

DESCRIPTION

  FEATURE EXTRACTION
     ******************************************************************
     double findMinVal_Vector(void *a, unsigned length, CVIP_TYPE data_type)
     ******************************************************************

     <a> - pointer to vector
     <length> - no of elements in vector
     <data_type> - valid CVIPtools data type (i.e. one of CVIP_BYTE, CVIP_SHORT,
     CVIP_INTEGER, CVIP_FLOAT or CVIP_DOUBLE)

     Returns: the minimum value in the span of  the  vector  <a>.
     Description:  Finds  the minimum value in the span of a vec-
     tor. The value is returned as a floating point value of type
     double.  Author(s): Gregory Hance.

     ******************************************************************
     double findMaxVal_Vector(void *a, unsigned length, CVIP_TYPE data_type)
     ******************************************************************

     <a> - pointer to vector
     <length> - no of elements in vector
     <data_type> - valid CVIPtools data type (i.e. one of
     CVIP_BYTE, CVIP_SHORT, CVIP_INTEGER, CVIP_FLOAT or CVIP_DOUBLE)

     Returns: the maximum value in the span of  the  vector  <a>.
     Description:  Finds  the maximum value in the span of a vec-
     tor. The value is returned as a floating point value of type
     double.  Author(s): Gregory Hance.

  DATA REPRESENTATION
     ******************************************************************
     byte **band2pixel_Vector(byte **bandP, unsigned int no_of_bands,
     unsigned int imgsize)
     ******************************************************************

     <bandP> - pointer to array of band vectors
     <no_of_bands> - number of spectral bands in image
     (number of band vectors)
     <imgsize> - size of image (length of each band vector)

     Returns: pointer to array pixel vectors.  Description:  con-
     verts   a  band  vector  array  to  a  pixel  vector  array.
     Author(s): Gregory Hance.

     ******************************************************************
     byte **pixel2band_Vector(byte **pixP, unsigned int no_of_bands,
     unsigned int imgsize)
     ******************************************************************

     <bandP> - pointer to array of pixel vectors
     <no_of_bands> - number spectral bands in image (length of each pixel vector)
     <imgsize> - size of image (number of pixel vectors)

     Returns: pointer to array pixel vectors.  Description:  con-
     verts   a  pixel  vector  array  to  a  band  vector  array.
     Author(s): Gregory Hance.

     ******************************************************************
     void copy_Vector(void *avecP, void *bvecP, unsigned int vdim, CVIP_TYPE atype,
     CVIP_TYPE btype)
     ******************************************************************

     <avecP> - pointer to vector A
     <bvecP> - pointer to vector B
     <vdim> - dimension of each vector
     <atype> - type of data pointed to by vector A
     <btype> - type of data pointed to by vector B

     Returns: nada.  Description: copies the contents of vector A
     into  vector  B.  Handles all 25 different type combinations
     of A and B. NOTE: this function  simply  copies  one  vector
     into  another;  therefore copying a vector of a more precise
     type to that of a less precise type will work  properly  but
     may  result in garbage if the range of A is not inclusive of
     that of B.  Author(s): Gregory Hance.

     ******************************************************************
     void *normalize_Vector(void *srcvecP, float *normP, CVIP_TYPE vecdtype,
     unsigned int no_of_vecs, unsigned int vdim)
     ******************************************************************

     <srcvecP> - pointer to array of vectors
     <normP> - normalization vector
     <vecdtype> - valid CVIPtools data type of vector
     <no_of_vecs> - number of vectors

     Returns: pointer to a normalized array of vectors.  Descrip-
     tion:  This function will normalize an array of vectors with
     respect  to  the  normalization   vector   <normP>.    (i.e.
     srcvecP[0]([0],[1],...,[vdim-1])/normP[0],
     srcvecP[1]([0],[1],...,[vdim-1])/normP[1].  If the data type
     of  the  vectors  is  less  precise than "float" or equal to
     "float" then the result will be type "float". If the  arrays
     are  of  type  "double"  then the result will be an array of
     normalized vectors of  type  "double".   Author(s):  Gregory
     Hance.
     ******************************************************************
     int  convolve_Vector(double *xvecP, double *hvecP, int xlen,
     int                                                    hlen)
     ******************************************************************

      <xvecP> - input sequence vector
      <hvecP> - impulse sequence vector
      <xlen> - length of input vector
      <hlen> - length of impulse vector

     Returns: None.
     Description: This function performs convolution on two  vec-
     tors.
     Author(s):                  Gregory                   Hance.
     ******************************************************************
     int findHisto_Vector(byte *vecP, int vsize, void *hP, int l,
     int              h,             CVIP_TYPE             dtype)
     ******************************************************************

      <vecP> - input vector
      <vsize> - size of input vector
      <hP> - histogram vector
      <l> - expected low value in input
      <h> - expected high value in input
      <dtype> - valid CVIPtools data type of vector

     Returns: None.
     Description: This function will find  the  histogram  of  an
     input vector of type CVIP_INTEGER or CVIP_DOUBLE.
     Author(s):                  Gregory                   Hance.
     ******************************************************************
     int printHisto_Vector(const char *fname, void *hP, CVIP_TYPE
     dtype,      int      l,      int     h,     int     skipval)
     ******************************************************************

      <fname> - filename
      <hP> - histogram vector
      <dtype> - valid CVIPtools data type of vector
      <l> - expected low value in input
      <h> - expected high value in input
      <skipval> - value to set to zero when computing histogram

     Returns: None.
     Description: This function will write  the histogram  of  an
     input vector of type CVIP_INTEGER or CVIP_DOUBLE to a file.
     Author(s):                  Gregory                   Hance.
     ******************************************************************
     void *subSample_Vector(void *vecP, unsigned  dim,  CVIP_TYPE
     data_type,     unsigned     skip,     unsigned     *new_dim)
     ******************************************************************

      <vecP> -pointer to input vector
      <dim> - dimension of input vector
      <data_type> - valid CVIPtools data type of vector
      <skip> - number of elements to skip for sampling
      <new_dim> - new vector length

     Returns: New sampled vector.
     Description: This function will produce a vector by sampling
     every  <skip> element of an input vector. This function will
     accept  CVIPtools  datatypes   of   CVIP_BYTE,   CVIP_SHORT,
     CVIP_INTEGER, CVIP_FLOAT, and CVIP_DOUBLE
     Author(s): Gregory Hance.

BUGS

     none as of yet

SEE ALSO

     CVIPvector.h, CVIPtools library quick reference guide

AUTHOR

     Copyright (C) 1992, 1995 SIUE - by Gregory Hance  and  Scott
     Umbaugh.