Opm::BLAS_LAPACK Namespace Reference

Functions

template<typename T >
void GEMV (const char *transA, const int m, const int n, const T &a1, const T *A, const int ldA, const T *x, const int incX, const T &a2, T *y, const int incY)
 GEneral Matrix Vector product (Level 2 BLAS). More...
 
template<>
void GEMV< double > (const char *transA, const int m, const int n, const double &a1, const double *A, const int ldA, const double *x, const int incX, const double &a2, double *y, const int incY)
 GEneral Matrix Vector product specialization for double. More...
 
template<typename T >
void GEMM (const char *transA, const char *transB, const int m, const int n, const int k, const T &a1, const T *A, const int ldA, const T *B, const int ldB, const T &a2, T *C, const int ldC)
 GEneral Matrix Matrix product (Level 3 BLAS). More...
 
template<>
void GEMM< double > (const char *transA, const char *transB, const int m, const int n, const int k, const double &a1, const double *A, const int ldA, const double *B, const int ldB, const double &a2, double *C, const int ldC)
 GEneral Matrix Matrix product specialization for double. More...
 
template<typename T >
void SYRK (const char *uplo, const char *trans, const int n, const int k, const T &a1, const T *A, const int ldA, const T &a2, T *C, const int ldC)
 SYmmetric Rank K update of symmetric matrix (Level 3 BLAS) More...
 
template<>
void SYRK< double > (const char *uplo, const char *trans, const int n, const int k, const double &a1, const double *A, const int ldA, const double &a2, double *C, const int ldC)
 SYmmetric Rank K update of symmetric matrix specialization for double. More...
 
template<typename T >
void TRMM (const char *side, const char *uplo, const char *transA, const char *diag, const int m, const int n, const T &a, const T *A, const int ldA, T *B, const int ldB)
 TRiangular Matrix Matrix product (Level 2 BLAS) More...
 
template<>
void TRMM< double > (const char *side, const char *uplo, const char *transA, const char *diag, const int m, const int n, const double &a, const double *A, const int ldA, double *B, const int ldB)
 TRiangular Matrix Matrix product specialization for double. More...
 
template<typename T >
void GEQRF (const int m, const int n, T *A, const int ld, T *tau, T *work, const int lwork, int &info)
 GEneral matrix QR Factorization (LAPACK) More...
 
template<>
void GEQRF< double > (const int m, const int n, double *A, const int ld, double *tau, double *work, const int lwork, int &info)
 GEneral matrix QR Factorization specialization for double. More...
 
template<typename T >
void ORGQR (const int m, const int n, const int k, T *A, const int ld, const T *tau, T *work, const int lwork, int &info)
 ORthogonal matrix Generator from QR factorization (LAPACK). More...
 
template<>
void ORGQR< double > (const int m, const int n, const int k, double *A, const int ld, const double *tau, double *work, const int lwork, int &info)
 ORthogonal matrix Generator from QR factorization specialization for double. More...
 
template<typename T >
void GETRF (const int m, const int n, T *A, const int ld, int *ipiv, int &info)
 GEneral matrix TRiangular Factorization (LAPACK). More...
 
template<>
void GETRF< double > (const int m, const int n, double *A, const int ld, int *ipiv, int &info)
 GEneral matrix TRiangular Factorization specialization for double. More...
 
template<typename T >
void GETRI (const int n, T *A, const int ld, const int *ipiv, T *work, int lwork, int &info)
 GEneral matrix TRiangular Inversion (LAPACK). More...
 
template<>
void GETRI (const int n, double *A, const int ld, const int *ipiv, double *work, int lwork, int &info)
 GEneral matrix TRiangular Inversion specialization for double. More...
 

Function Documentation

template<typename T >
void Opm::BLAS_LAPACK::GEMM ( const char *  transA,
const char *  transB,
const int  m,
const int  n,
const int  k,
const T &  a1,
const T *  A,
const int  ldA,
const T *  B,
const int  ldB,
const T &  a2,
T *  C,
const int  ldC 
)

GEneral Matrix Matrix product (Level 3 BLAS).

Template Parameters
TElement type of matrix.

Double precision general matrix-matrix product matrix update. Specifically, $ C \leftarrow a_1 \mathrm{op}(A) \mathrm{op}(B) + a_2 C $.

Parameters
[in]transASpecifcation of $ \mathrm{op} $.
transA = 'N'
yields $ \mathrm{op}(A) = A $ while
transA = 'T'
yields $ \mathrm{op}(A) = A^{\mathsf{T}} $.
[in]transBSpecifcation of $ \mathrm{op} $.
transB = 'N'
yields $ \mathrm{op}(B) = A $ while
transB = 'T'
yields $ \mathrm{op}(B) = B^{\mathsf{T}} $.
[in]mNumber of rows of matrix $ \mathrm{op}(A) $ and of matrix $ C $.
[in]nNumber of columns of matrix $ \mathrm{op}(B) $ and of matrix $ C $.
[in]kNumber of columns of matrix $ \mathrm{op}(A) $ and number of rows of matrix $ \mathrm{op}(B) $.
[in]a1Scalar coefficient $ a_1 $.
[in]APointer to first data element of matrix $ A $.
[in]ldALeading dimension of storage std::array containing the matrix $ A $.
[in]BPointer to first data element of matrix $ B $.
[in]ldBLeading dimension of storage std::array containing the matrix $ B $.
[in]a2Scalar coefficient $ a_2 $.
CPointer to first data element of matrix $ C $.
[in]ldCLeading dimension of storage std::array containing the matrix $ C $.

Referenced by Opm::matMulAdd_NN(), Opm::matMulAdd_NT(), and Opm::matMulAdd_TN().

template<>
void Opm::BLAS_LAPACK::GEMM< double > ( const char *  transA,
const char *  transB,
const int  m,
const int  n,
const int  k,
const double &  a1,
const double *  A,
const int  ldA,
const double *  B,
const int  ldB,
const double &  a2,
double *  C,
const int  ldC 
)

GEneral Matrix Matrix product specialization for double.

template<typename T >
void Opm::BLAS_LAPACK::GEMV ( const char *  transA,
const int  m,
const int  n,
const T &  a1,
const T *  A,
const int  ldA,
const T *  x,
const int  incX,
const T &  a2,
T *  y,
const int  incY 
)

GEneral Matrix Vector product (Level 2 BLAS).

Template Parameters
TElement type of matrix/vector.
Parameters
transASpecifcation of $ \mathrm{op} $.
transA = 'N'
yields $ \mathrm{op}(A) = A $ while
transA = 'T'
yields $ \mathrm{op}(A) = A^{\mathsf{T}} $.
[in]mNumber of matrix rows (and number of rows for which new data will be assigned to the result vector $ y $.)
[in]nNumber of matrix columns (and number of rows for which data will be retrieved from the input vector $ x $).
[in]a1Scalar coefficient $ a_1 $.
[in]APointer to first data element of matrix $ A $.
[in]ldALeading dimension of storage std::array containing the matrix $ A $.
[in]xInput vector $ x $.
[in]incXData element stride for input vector $ x $.
[in]a2Scalar coefficient $ a_2 $.
yResult vector $ y $.
[in]incYData element stride for result vector $ y $.

Referenced by Opm::vecMulAdd_N(), and Opm::vecMulAdd_T().

template<>
void Opm::BLAS_LAPACK::GEMV< double > ( const char *  transA,
const int  m,
const int  n,
const double &  a1,
const double *  A,
const int  ldA,
const double *  x,
const int  incX,
const double &  a2,
double *  y,
const int  incY 
)

GEneral Matrix Vector product specialization for double.

template<typename T >
void Opm::BLAS_LAPACK::GEQRF ( const int  m,
const int  n,
T *  A,
const int  ld,
T *  tau,
T *  work,
const int  lwork,
int &  info 
)

GEneral matrix QR Factorization (LAPACK)

Template Parameters
TMatrix element type.

Referenced by Opm::orthogonalizeColumns().

template<>
void Opm::BLAS_LAPACK::GEQRF< double > ( const int  m,
const int  n,
double *  A,
const int  ld,
double *  tau,
double *  work,
const int  lwork,
int &  info 
)

GEneral matrix QR Factorization specialization for double.

template<typename T >
void Opm::BLAS_LAPACK::GETRF ( const int  m,
const int  n,
T *  A,
const int  ld,
int *  ipiv,
int &  info 
)

GEneral matrix TRiangular Factorization (LAPACK).

Template Parameters
TMatrix element type.

Referenced by Opm::invert().

template<>
void Opm::BLAS_LAPACK::GETRF< double > ( const int  m,
const int  n,
double *  A,
const int  ld,
int *  ipiv,
int &  info 
)

GEneral matrix TRiangular Factorization specialization for double.

template<typename T >
void Opm::BLAS_LAPACK::GETRI ( const int  n,
T *  A,
const int  ld,
const int *  ipiv,
T *  work,
int  lwork,
int &  info 
)

GEneral matrix TRiangular Inversion (LAPACK).

Template Parameters
TMatrix element type.

Referenced by Opm::invert().

template<>
void Opm::BLAS_LAPACK::GETRI ( const int  n,
double *  A,
const int  ld,
const int *  ipiv,
double *  work,
int  lwork,
int &  info 
)

GEneral matrix TRiangular Inversion specialization for double.

template<typename T >
void Opm::BLAS_LAPACK::ORGQR ( const int  m,
const int  n,
const int  k,
T *  A,
const int  ld,
const T *  tau,
T *  work,
const int  lwork,
int &  info 
)

ORthogonal matrix Generator from QR factorization (LAPACK).

Template Parameters
TMatrix element type.

Referenced by Opm::orthogonalizeColumns().

template<>
void Opm::BLAS_LAPACK::ORGQR< double > ( const int  m,
const int  n,
const int  k,
double *  A,
const int  ld,
const double *  tau,
double *  work,
const int  lwork,
int &  info 
)

ORthogonal matrix Generator from QR factorization specialization for double.

template<typename T >
void Opm::BLAS_LAPACK::SYRK ( const char *  uplo,
const char *  trans,
const int  n,
const int  k,
const T &  a1,
const T *  A,
const int  ldA,
const T &  a2,
T *  C,
const int  ldC 
)

SYmmetric Rank K update of symmetric matrix (Level 3 BLAS)

Template Parameters
TMatrix element type.

Referenced by Opm::symmetricUpdate().

template<>
void Opm::BLAS_LAPACK::SYRK< double > ( const char *  uplo,
const char *  trans,
const int  n,
const int  k,
const double &  a1,
const double *  A,
const int  ldA,
const double &  a2,
double *  C,
const int  ldC 
)

SYmmetric Rank K update of symmetric matrix specialization for double.

template<typename T >
void Opm::BLAS_LAPACK::TRMM ( const char *  side,
const char *  uplo,
const char *  transA,
const char *  diag,
const int  m,
const int  n,
const T &  a,
const T *  A,
const int  ldA,
T *  B,
const int  ldB 
)

TRiangular Matrix Matrix product (Level 2 BLAS)

Template Parameters
TMatrix element type.

Referenced by Opm::symmetricUpdate().

template<>
void Opm::BLAS_LAPACK::TRMM< double > ( const char *  side,
const char *  uplo,
const char *  transA,
const char *  diag,
const int  m,
const int  n,
const double &  a,
const double *  A,
const int  ldA,
double *  B,
const int  ldB 
)

TRiangular Matrix Matrix product specialization for double.