drasys.or.linear.blas
Interface BLAS2I

All Known Implementing Classes:
SmpBLAS2, BLAS2

public interface BLAS2I

Defines an array based BLAS2 for Java. Blas2 operates on vectors and matrices stored contiguously in one-dimensional arrays. It also supports sub-matrices and sub-vectors which allow it to work with both '0' and '1' based indexing. The increment arguments 'inci' and 'incj' allow this method to operate directly on both row-major and column-major structures. The arrays containing complex elements store each complex element in two adjacent array positions. The real component has the even index and the imaginary component has the next higher index. The 'beg?' and 'inc?' arguments specify the logical index of the complex element, these are multiplied by two internally to obtain the offset into the array.

See Also:
DenseVector, RowMajorMatrix, ColumnMajorMatrix, DenseVector, RowMajorMatrix,

References:

Linear Algebra and Its Applications
    Gilbert Strang / Hardcover / Published 1988
Matrix Computations (Johns Hopkins Studies in the Mathematical Sciences)
    Gene H. Golub, Charles F. Van Loan (Contributor) / Paperback / Published 1996
Numerical Recipes in C : The Art of Scientific Computing
    William H. Press, et al / Hardcover / Published 1993


Method Summary
 void cgemv(int m, int n, ComplexI alpha, float[] A, int begA, int incAi, int incAj, float[] x, int begx, int incx, ComplexI beta, float[] y, int begy, int incy)
          Computes: y = alpha*A*x + beta*y.
 void cgerc(int m, int n, ComplexI alpha, float[] x, int begx, int incx, float[] y, int begy, int incy, float[] A, int begA, int incAi, int incAj)
          Computes: A = alpha*x*y' + A.
 void cgeru(int m, int n, ComplexI alpha, float[] x, int begx, int incx, float[] y, int begy, int incy, float[] A, int begA, int incAi, int incAj)
          Computes: A = alpha*x*y' + A.
 void dgemv(int m, int n, double alpha, double[] A, int begA, int incAi, int incAj, double[] x, int begx, int incx, double beta, double[] y, int begy, int incy)
          Computes: y = alpha*A*x + beta*y.
 void dger(int m, int n, double alpha, double[] x, int begx, int incx, double[] y, int begy, int incy, double[] A, int begA, int incAi, int incAj)
          Computes: A = alpha*x*y' + A.
 void sgemv(int m, int n, float alpha, float[] A, int begA, int incAi, int incAj, float[] x, int begx, int incx, float beta, float[] y, int begy, int incy)
          Computes: y = alpha*A*x + beta*y.
 void sger(int m, int n, float alpha, float[] x, int begx, int incx, float[] y, int begy, int incy, float[] A, int bega, int inci, int incj)
          Computes: A = alpha*x*y' + A.
 void zgemv(int m, int n, ComplexI alpha, double[] A, int begA, int incAi, int incAj, double[] x, int begx, int incx, ComplexI beta, double[] y, int begy, int incy)
          Computes: y = alpha*A*x + beta*y.
 void zgerc(int m, int n, ComplexI alpha, double[] x, int begx, int incx, double[] y, int begy, int incy, double[] A, int begA, int incAi, int incAj)
          Computes: A = alpha*x*y' + A.
 void zgeru(int m, int n, ComplexI alpha, double[] x, int begx, int incx, double[] y, int begy, int incy, double[] A, int begA, int incAi, int incAj)
          Computes: A = alpha*x*y' + A.
 

Method Detail

dgemv

public void dgemv(int m,
                  int n,
                  double alpha,
                  double[] A,
                  int begA,
                  int incAi,
                  int incAj,
                  double[] x,
                  int begx,
                  int incx,
                  double beta,
                  double[] y,
                  int begy,
                  int incy)
           throws BlasException
Computes: y = alpha*A*x + beta*y. The transpose of 'A' can be used by swapping 'incAi' and 'incAj'.
Parameters:
m - number of rows in 'A'
n - number of columns in 'A'
alpha - constant scaler
A - the matrix 'A' in contiguous format
begA - offset of the first element of 'A'
incAi - row increment for matrix 'A'
incAj - column increment for matrix 'A'
x - array containing the 'x' vector elements
begx - offset of the first 'x' vector element
incx - the distance between 'x' vector elements
beta - constant scaler
y - array containing the 'y' vector elements
begy - offset of the first 'y' vector element
incy - the distance between 'y' vector elements

dger

public void dger(int m,
                 int n,
                 double alpha,
                 double[] x,
                 int begx,
                 int incx,
                 double[] y,
                 int begy,
                 int incy,
                 double[] A,
                 int begA,
                 int incAi,
                 int incAj)
          throws BlasException
Computes: A = alpha*x*y' + A. The transpose of 'A' can be used by swapping 'incAi' and 'incAj'.
Parameters:
m - number of rows in 'A'
n - number of columns in 'A'
alpha - constant scaler
x - array containing the 'x' vector elements
begx - offset of the first 'x' vector element
incx - the distance between 'x' vector elements
y - array containing the 'y' vector elements
begy - offset of the first 'y' vector element
incy - the distance between 'y' vector elements
A - the matrix 'A' in contiguous format
begA - offset of the first element of 'A'
incAi - row increment for matrix 'A'
incAj - column increment for matrix 'A'

sgemv

public void sgemv(int m,
                  int n,
                  float alpha,
                  float[] A,
                  int begA,
                  int incAi,
                  int incAj,
                  float[] x,
                  int begx,
                  int incx,
                  float beta,
                  float[] y,
                  int begy,
                  int incy)
           throws BlasException
Computes: y = alpha*A*x + beta*y. The transpose of 'A' can be used by swapping 'incAi' and 'incAj'.
Parameters:
m - number of rows in 'A'
n - number of columns in 'A'
alpha - constant scaler
A - the matrix 'A' in contiguous format
begA - offset of the first element of 'A'
incAi - row increment for matrix 'A'
incAj - column increment for matrix 'A'
x - array containing the 'x' vector elements
begx - offset of the first 'x' vector element
incx - the distance between 'x' vector elements
beta - constant scaler
y - array containing the 'y' vector elements
begy - offset of the first 'y' vector element
incy - the distance between 'y' vector elements

sger

public void sger(int m,
                 int n,
                 float alpha,
                 float[] x,
                 int begx,
                 int incx,
                 float[] y,
                 int begy,
                 int incy,
                 float[] A,
                 int bega,
                 int inci,
                 int incj)
          throws BlasException
Computes: A = alpha*x*y' + A. The transpose of 'A' can be used by swapping 'incAi' and 'incAj'.
Parameters:
m - number of rows in 'A'
n - number of columns in 'A'
alpha - constant scaler
x - array containing the 'x' vector elements
begx - offset of the first 'x' vector element
incx - the distance between 'x' vector elements
y - array containing the 'y' vector elements
begy - offset of the first 'y' vector element
incy - the distance between 'y' vector elements
A - the matrix 'A' in contiguous format
begA - offset of the first element of 'A'
incAi - row increment for matrix 'A'
incAj - column increment for matrix 'A'

zgemv

public void zgemv(int m,
                  int n,
                  ComplexI alpha,
                  double[] A,
                  int begA,
                  int incAi,
                  int incAj,
                  double[] x,
                  int begx,
                  int incx,
                  ComplexI beta,
                  double[] y,
                  int begy,
                  int incy)
           throws BlasException
Computes: y = alpha*A*x + beta*y. The transpose of 'A' can be used by swapping 'incAi' and 'incAj'.
Parameters:
m - number of rows in 'A'
n - number of columns in 'A'
alpha - constant scaler
A - the matrix 'A' in contiguous format
begA - offset of the first element of 'A'
incAi - row increment for matrix 'A'
incAj - column increment for matrix 'A'
x - array containing the 'x' vector elements
begx - offset of the first 'x' vector element
incx - the distance between 'x' vector elements
beta - constant scaler
y - array containing the 'y' vector elements
begy - offset of the first 'y' vector element
incy - the distance between 'y' vector elements

zgeru

public void zgeru(int m,
                  int n,
                  ComplexI alpha,
                  double[] x,
                  int begx,
                  int incx,
                  double[] y,
                  int begy,
                  int incy,
                  double[] A,
                  int begA,
                  int incAi,
                  int incAj)
           throws BlasException
Computes: A = alpha*x*y' + A. The transpose of 'A' can be used by swapping 'incAi' and 'incAj'.
Parameters:
m - number of rows in 'A'
n - number of columns in 'A'
alpha - constant scaler
x - array containing the 'x' vector elements
begx - offset of the first 'x' vector element
incx - the distance between 'x' vector elements
y - array containing the 'y' vector elements
begy - offset of the first 'y' vector element
incy - the distance between 'y' vector elements
A - the matrix 'A' in contiguous format
begA - offset of the first element of 'A'
incAi - row increment for matrix 'A'
incAj - column increment for matrix 'A'

zgerc

public void zgerc(int m,
                  int n,
                  ComplexI alpha,
                  double[] x,
                  int begx,
                  int incx,
                  double[] y,
                  int begy,
                  int incy,
                  double[] A,
                  int begA,
                  int incAi,
                  int incAj)
           throws BlasException
Computes: A = alpha*x*y' + A. The transpose of 'A' can be used by swapping 'incAi' and 'incAj'.
Parameters:
m - number of rows in 'A'
n - number of columns in 'A'
alpha - constant scaler
x - array containing the 'x' vector elements
begx - offset of the first 'x' vector element
incx - the distance between 'x' vector elements
y - array containing the 'y' vector elements
begy - offset of the first 'y' vector element
incy - the distance between 'y' vector elements
A - the matrix 'A' in contiguous format
begA - offset of the first element of 'A'
incAi - row increment for matrix 'A'
incAj - column increment for matrix 'A'

cgemv

public void cgemv(int m,
                  int n,
                  ComplexI alpha,
                  float[] A,
                  int begA,
                  int incAi,
                  int incAj,
                  float[] x,
                  int begx,
                  int incx,
                  ComplexI beta,
                  float[] y,
                  int begy,
                  int incy)
           throws BlasException
Computes: y = alpha*A*x + beta*y. The transpose of 'A' can be used by swapping 'incAi' and 'incAj'.
Parameters:
m - number of rows in 'A'
n - number of columns in 'A'
alpha - constant scaler
A - the matrix 'A' in contiguous format
begA - offset of the first element of 'A'
incAi - row increment for matrix 'A'
incAj - column increment for matrix 'A'
x - array containing the 'x' vector elements
begx - offset of the first 'x' vector element
incx - the distance between 'x' vector elements
beta - constant scaler
y - array containing the 'y' vector elements
begy - offset of the first 'y' vector element
incy - the distance between 'y' vector elements

cgeru

public void cgeru(int m,
                  int n,
                  ComplexI alpha,
                  float[] x,
                  int begx,
                  int incx,
                  float[] y,
                  int begy,
                  int incy,
                  float[] A,
                  int begA,
                  int incAi,
                  int incAj)
           throws BlasException
Computes: A = alpha*x*y' + A. The transpose of 'A' can be used by swapping 'incAi' and 'incAj'.
Parameters:
m - number of rows in 'A'
n - number of columns in 'A'
alpha - constant scaler
x - array containing the 'x' vector elements
begx - offset of the first 'x' vector element
incx - the distance between 'x' vector elements
y - array containing the 'y' vector elements
begy - offset of the first 'y' vector element
incy - the distance between 'y' vector elements
A - the matrix 'A' in contiguous format
begA - offset of the first element of 'A'
incAi - row increment for matrix 'A'
incAj - column increment for matrix 'A'

cgerc

public void cgerc(int m,
                  int n,
                  ComplexI alpha,
                  float[] x,
                  int begx,
                  int incx,
                  float[] y,
                  int begy,
                  int incy,
                  float[] A,
                  int begA,
                  int incAi,
                  int incAj)
           throws BlasException
Computes: A = alpha*x*y' + A. The transpose of 'A' can be used by swapping 'incAi' and 'incAj'.
Parameters:
m - number of rows in 'A'
n - number of columns in 'A'
alpha - constant scaler
x - array containing the 'x' vector elements
begx - offset of the first 'x' vector element
incx - the distance between 'x' vector elements
y - array containing the 'y' vector elements
begy - offset of the first 'y' vector element
incy - the distance between 'y' vector elements
A - the matrix 'A' in contiguous format
begA - offset of the first element of 'A'
incAi - row increment for matrix 'A'
incAj - column increment for matrix 'A'


Copyright(C)1997-2000 by DRA Systems all rights reserved. OpsResearch.com