Fork me on GitHub
 All Classes Files Functions Variables Groups Pages
Functions
blas.h File Reference

BLAS-like functions. More...

Go to the source code of this file.

Functions

template<typename ArrayType >
int cusp::blas::amax (const ArrayType &x)
 index of the largest element in a array More...
 
template<typename ArrayType >
cusp::norm_type< typename
ArrayType::value_type >::type 
cusp::blas::asum (const ArrayType &x)
 sum of absolute value of all entries in array More...
 
template<typename ArrayType1 , typename ArrayType2 , typename ScalarType >
void cusp::blas::axpy (const ArrayType1 &x, ArrayType2 &y, const ScalarType alpha)
 scaled vector addition (y = alpha * x + y) More...
 
template<typename ArrayType1 , typename ArrayType2 , typename ArrayType3 , typename ScalarType1 , typename ScalarType2 >
void cusp::blas::axpby (const ArrayType1 &x, const ArrayType2 &y, ArrayType3 &z, ScalarType1 alpha, ScalarType2 beta)
 compute linear combination of two vectors (z = alpha * x + beta * y) More...
 
template<typename ArrayType1 , typename ArrayType2 , typename ArrayType3 , typename ArrayType4 , typename ScalarType1 , typename ScalarType2 , typename ScalarType3 >
void cusp::blas::axpbypcz (const ArrayType1 &x, const ArrayType2 &y, const ArrayType3 &z, ArrayType4 &w, ScalarType1 alpha, ScalarType2 beta, ScalarType3 gamma)
 compute linear combination of three vectors (output = alpha * x + beta * y + gamma * z) More...
 
template<typename ArrayType1 , typename ArrayType2 , typename ArrayType3 >
void cusp::blas::xmy (const ArrayType1 &x, const ArrayType2 &y, ArrayType3 &z)
 elementwise multiplication of two vectors (z[i] = x[i] * y[i]) More...
 
template<typename ArrayType1 , typename ArrayType2 >
void cusp::blas::copy (const ArrayType1 &x, ArrayType2 &y)
 vector copy (y = x) More...
 
template<typename ArrayType1 , typename ArrayType2 >
ArrayType1::value_type cusp::blas::dot (const ArrayType1 &x, const ArrayType2 &y)
 dot product (x^T * y) More...
 
template<typename ArrayType1 , typename ArrayType2 >
ArrayType1::value_type cusp::blas::dotc (const ArrayType1 &x, const ArrayType2 &y)
 conjugate dot product (conjugate(x)^T * y) More...
 
template<typename ArrayType , typename ScalarType >
void cusp::blas::fill (ArrayType &x, const ScalarType alpha)
 vector fill (x[i] = alpha) More...
 
template<typename ArrayType >
cusp::norm_type< typename
ArrayType::value_type >::type 
cusp::blas::nrm1 (const ArrayType &x)
 vector 1-norm (sum abs(x[i])) More...
 
template<typename ArrayType >
cusp::norm_type< typename
ArrayType::value_type >::type 
cusp::blas::nrm2 (const ArrayType &x)
 vector 2-norm (sqrt(sum x[i] * x[i] ) More...
 
template<typename ArrayType >
cusp::norm_type< typename
ArrayType::value_type >::type 
cusp::blas::nrmmax (const ArrayType &x)
 vector infinity norm More...
 
template<typename ArrayType , typename ScalarType >
void cusp::blas::scal (ArrayType &x, const ScalarType alpha)
 scale vector (x[i] = alpha * x[i]) More...
 
template<typename Array2d1 , typename Array1d1 , typename Array1d2 >
void cusp::blas::gemv (const Array2d1 &A, const Array1d1 &x, Array1d2 &y)
 Computes a matrix-vector product using a general matrix. More...
 
template<typename Array1d1 , typename Array1d2 , typename Array2d1 >
void cusp::blas::ger (const Array1d1 &x, const Array1d2 &y, Array2d1 &A)
 Performs a rank-1 update of a general matrix. More...
 
template<typename Array2d1 , typename Array1d1 , typename Array1d2 >
void cusp::blas::symv (const Array2d1 &A, const Array1d1 &x, Array1d2 &y)
 Computes a matrix-vector product using a symmetric matrix. More...
 
template<typename Array1d , typename Array2d >
void cusp::blas::syr (const Array1d &x, Array2d &A)
 Performs a rank-1 update of a symmetric matrix. More...
 
template<typename Array2d , typename Array1d >
void cusp::blas::trmv (const Array2d &A, Array1d &x)
 Computes a matrix-vector product using a triangular matrix. More...
 
template<typename Array2d , typename Array1d >
void cusp::blas::trsv (const Array2d &A, Array1d &x)
 Solve a triangular matrix equation. More...
 
template<typename Array2d1 , typename Array2d2 , typename Array2d3 >
void cusp::blas::gemm (const Array2d1 &A, const Array2d2 &B, Array2d3 &C)
 Computes a matrix-matrix product with general matrices. More...
 
template<typename Array2d1 , typename Array2d2 , typename Array2d3 >
void cusp::blas::symm (const Array2d1 &A, const Array2d2 &B, Array2d3 &C)
 Computes a matrix-matrix product where one input matrix is symmetric. More...
 
template<typename Array2d1 , typename Array2d2 >
void cusp::blas::syrk (const Array2d1 &A, Array2d2 &B)
 Performs a symmetric rank-k update. More...
 
template<typename Array2d1 , typename Array2d2 , typename Array2d3 >
void cusp::blas::syr2k (const Array2d1 &A, const Array2d2 &B, Array2d3 &C)
 Performs a symmetric rank-2k update. More...
 
template<typename Array2d1 , typename Array2d2 >
void cusp::blas::trmm (const Array2d1 &A, Array2d2 &B)
 Computes a matrix-matrix product where one input matrix is triangular. More...
 
template<typename Array2d1 , typename Array2d2 >
void cusp::blas::trsm (const Array2d1 &A, Array2d2 &B)
 Solve a triangular matrix equation. More...
 

Detailed Description

BLAS-like functions.

Definition in file blas.h.