imate
C++/CUDA Reference
cMatrix< DataType > Class Template Referenceabstract

Base class for constant matrices. More...

#include <c_matrix.h>

Inheritance diagram for cMatrix< DataType >:
Collaboration diagram for cMatrix< DataType >:

Public Member Functions

 cMatrix ()
 Default constructor. More...
 
virtual ~cMatrix ()
 
DataType get_eigenvalue (const DataType *known_parameters, const DataType known_eigenvalue, const DataType *inquiry_parameters) const
 This virtual function is implemented from its pure virtual function of the base class. In this class, this functio has no use and was only implemented so that this class be able to be instantiated (due to the pure virtual function). More...
 
virtual FlagType is_identity_matrix () const =0
 
virtual void dot_plus (const DataType *vector, const DataType alpha, DataType *product)=0
 
virtual void transpose_dot_plus (const DataType *vector, const DataType alpha, DataType *product)=0
 
- Public Member Functions inherited from cLinearOperator< DataType >
 cLinearOperator ()
 Default constructor. More...
 
 cLinearOperator (const LongIndexType num_rows_, const LongIndexType num_columns_)
 Constructor with setting num_rows and num_columns. More...
 
virtual ~cLinearOperator ()
 
LongIndexType get_num_rows () const
 
LongIndexType get_num_columns () const
 
void set_parameters (DataType *parameters_)
 Sets the scalar parameter this->parameters. Parameter is initialized to NULL. However, before calling dot or transpose_dot functions, the parameters must be set. More...
 
IndexType get_num_parameters () const
 
FlagType is_eigenvalue_relation_known () const
 Returns a flag that determines whether a relation between the parameters of the operator and its eigenvalue(s) is known. More...
 
virtual void dot (const DataType *vector, DataType *product)=0
 
virtual void transpose_dot (const DataType *vector, DataType *product)=0
 

Additional Inherited Members

- Protected Attributes inherited from cLinearOperator< DataType >
const LongIndexType num_rows
 
const LongIndexType num_columns
 
FlagType eigenvalue_relation_known
 
DataType * parameters
 
IndexType num_parameters
 

Detailed Description

template<typename DataType>
class cMatrix< DataType >

Base class for constant matrices.

The prefix c in this class's name (and its derivatves), stands for the cpp code, intrast to the cu prefix, which stands for the cuda code. Most derived classes have a cuda counterpart.

See also
cAffineMatrixFunction

Definition at line 40 of file c_matrix.h.

Constructor & Destructor Documentation

◆ cMatrix()

template<typename DataType >
cMatrix< DataType >::cMatrix

Default constructor.

Definition at line 28 of file c_matrix.cpp.

29 {
30 }

◆ ~cMatrix()

template<typename DataType >
cMatrix< DataType >::~cMatrix
virtual

Definition at line 38 of file c_matrix.cpp.

39 {
40 }

Member Function Documentation

◆ dot_plus()

template<typename DataType >
virtual void cMatrix< DataType >::dot_plus ( const DataType *  vector,
const DataType  alpha,
DataType *  product 
)
pure virtual

◆ get_eigenvalue()

template<typename DataType >
DataType cMatrix< DataType >::get_eigenvalue ( const DataType *  known_parameters,
const DataType  known_eigenvalue,
const DataType *  inquiry_parameters 
) const
virtual

This virtual function is implemented from its pure virtual function of the base class. In this class, this functio has no use and was only implemented so that this class be able to be instantiated (due to the pure virtual function).

Parameters
[in]known_parametersA set of parameters of the operator where the corresponding eigenvalue of the parameter is known for.
[in]known_eigenvalueThe known eigenvalue of the operator for the known parameters.
[in]inquiry_parametersA set of inquiry parameters of the operator where the corresponding eigenvalue of the operator is sought.
Returns
The eigenvalue of the operator corresponding the inquiry parameters.

Implements cLinearOperator< DataType >.

Definition at line 64 of file c_matrix.cpp.

68 {
69  assert((false) && "This function should no be called within this class");
70 
71  // Mark unused variables to avoid compiler warnings (-Wno-unused-parameter)
72  (void) known_parameters;
73  (void) known_eigenvalue;
74  (void) inquiry_parameters;
75 
76  return 0;
77 }

◆ is_identity_matrix()

template<typename DataType >
virtual FlagType cMatrix< DataType >::is_identity_matrix ( ) const
pure virtual

◆ transpose_dot_plus()

template<typename DataType >
virtual void cMatrix< DataType >::transpose_dot_plus ( const DataType *  vector,
const DataType  alpha,
DataType *  product 
)
pure virtual

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