ViennaCL - The Vienna Computing Library  1.7.1
Free open-source GPU-accelerated linear algebra and solver library.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
viennacl::scalar_expression< LHS, RHS, op_inner_prod > Class Template Reference

Specialization of a scalar expression for inner products. Allows for a final reduction on the CPU. More...

#include <scalar.hpp>

Public Types

typedef
viennacl::result_of::cpu_value_type
< LHS >::type 
ScalarType
 

Public Member Functions

 scalar_expression (LHS &lhs, RHS &rhs)
 
LHS & lhs () const
 Returns the left hand side operand. More...
 
RHS & rhs () const
 Returns the left hand side operand. More...
 
 operator ScalarType () const
 Conversion operator to a ViennaCL scalar. More...
 

Detailed Description

template<typename LHS, typename RHS>
class viennacl::scalar_expression< LHS, RHS, op_inner_prod >

Specialization of a scalar expression for inner products. Allows for a final reduction on the CPU.

assumption: dim(LHS) >= dim(RHS), where dim(scalar) = 0, dim(vector) = 1 and dim(matrix = 2)

Template Parameters
LHSThe left hand side operand
RHSThe right hand side operand
OPThe operation tag

Definition at line 82 of file scalar.hpp.

Member Typedef Documentation

template<typename LHS , typename RHS >
typedef viennacl::result_of::cpu_value_type<LHS>::type viennacl::scalar_expression< LHS, RHS, op_inner_prod >::ScalarType

Definition at line 86 of file scalar.hpp.

Constructor & Destructor Documentation

template<typename LHS , typename RHS >
viennacl::scalar_expression< LHS, RHS, op_inner_prod >::scalar_expression ( LHS &  lhs,
RHS &  rhs 
)
inline

Definition at line 88 of file scalar.hpp.

Member Function Documentation

template<typename LHS , typename RHS >
LHS& viennacl::scalar_expression< LHS, RHS, op_inner_prod >::lhs ( ) const
inline

Returns the left hand side operand.

Definition at line 91 of file scalar.hpp.

template<typename LHS , typename RHS >
viennacl::scalar_expression< LHS, RHS, op_inner_prod >::operator ScalarType ( ) const
inline

Conversion operator to a ViennaCL scalar.

Definition at line 96 of file scalar.hpp.

template<typename LHS , typename RHS >
RHS& viennacl::scalar_expression< LHS, RHS, op_inner_prod >::rhs ( ) const
inline

Returns the left hand side operand.

Definition at line 93 of file scalar.hpp.


The documentation for this class was generated from the following file: