PARALUTION  1.0.0
PARALUTION
paralution::Operator< ValueType > Class Template Referenceabstract

Operator class defines the generic interface for applying an operator (e.g. matrix, stencil) from/to global and local vectors. More...

#include <operator.hpp>

Inheritance diagram for paralution::Operator< ValueType >:
paralution::BaseParalution< ValueType > paralution::ParalutionObj paralution::LocalMatrix< ValueTypeH > paralution::LocalMatrix< ValueTypeL > paralution::LocalMatrix< ValueType > paralution::LocalStencil< ValueType >

Public Member Functions

 Operator ()
 
virtual ~Operator ()
 
virtual int get_nrow (void) const =0
 Return the number of rows in the matrix/stencil. More...
 
virtual int get_ncol (void) const =0
 Return the number of columns in the matrix/stencil. More...
 
virtual int get_nnz (void) const =0
 Return the number of non-zeros in the matrix/stencil. More...
 
virtual int get_local_nrow (void) const
 Return the number of rows in the local matrix/stencil. More...
 
virtual int get_local_ncol (void) const
 Return the number of columns in the local matrix/stencil. More...
 
virtual int get_local_nnz (void) const
 Return the number of non-zeros in the local matrix/stencil. More...
 
virtual int get_ghost_nrow (void) const
 Return the number of rows in the ghost matrix/stencil. More...
 
virtual int get_ghost_ncol (void) const
 Return the number of columns in the ghost matrix/stencil. More...
 
virtual int get_ghost_nnz (void) const
 Return the number of non-zeros in the ghost matrix/stencil. More...
 
virtual void Apply (const LocalVector< ValueType > &in, LocalVector< ValueType > *out) const
 Apply the operator, out = Operator(in), where in, out are local vectors. More...
 
virtual void ApplyAdd (const LocalVector< ValueType > &in, const ValueType scalar, LocalVector< ValueType > *out) const
 Apply and add the operator, out = out + scalar*Operator(in), where in, out are local vectors. More...
 
virtual void MoveToAccelerator (void)=0
 Move the object to the Accelerator backend. More...
 
virtual void MoveToHost (void)=0
 Move the object to the Host backend. More...
 
virtual void MoveToAcceleratorAsync (void)
 Move the object to the Accelerator backend with async move. More...
 
virtual void MoveToHostAsync (void)
 Move the object to the Host backend with async move. More...
 
virtual void Sync (void)
 
void CloneBackend (const BaseParalution< ValueType > &src)
 Clone the Backend descriptor from another object. More...
 
template<typename ValueType2 >
void CloneBackend (const BaseParalution< ValueType2 > &src)
 Clone the Backend descriptor from another object with different template ValueType. More...
 
virtual void info () const =0
 Print the object information (properties, backends) More...
 
virtual void Clear ()=0
 Clear (free all data) the object. More...
 

Protected Member Functions

virtual bool is_host (void) const =0
 Return true if the object is on the host. More...
 
virtual bool is_accel (void) const =0
 Return true if the object is on the accelerator. More...
 

Protected Attributes

std::string object_name_
 Name of the object. More...
 
Paralution_Backend_Descriptor local_backend_
 Backend descriptor. More...
 
bool asyncf
 
size_t global_obj_id
 

Detailed Description

template<typename ValueType>
class paralution::Operator< ValueType >

Operator class defines the generic interface for applying an operator (e.g. matrix, stencil) from/to global and local vectors.

Constructor & Destructor Documentation

template<typename ValueType >
paralution::Operator< ValueType >::Operator ( )
template<typename ValueType >
paralution::Operator< ValueType >::~Operator ( )
virtual

Member Function Documentation

template<typename ValueType >
void paralution::Operator< ValueType >::Apply ( const LocalVector< ValueType > &  in,
LocalVector< ValueType > *  out 
) const
virtual

Apply the operator, out = Operator(in), where in, out are local vectors.

Reimplemented in paralution::LocalMatrix< ValueType >, and paralution::LocalStencil< ValueType >.

template<typename ValueType >
void paralution::Operator< ValueType >::ApplyAdd ( const LocalVector< ValueType > &  in,
const ValueType  scalar,
LocalVector< ValueType > *  out 
) const
virtual

Apply and add the operator, out = out + scalar*Operator(in), where in, out are local vectors.

Reimplemented in paralution::LocalMatrix< ValueType >, and paralution::LocalStencil< ValueType >.

template<typename ValueType >
template<typename ValueType2 >
void paralution::BaseParalution< ValueType >::CloneBackend ( const BaseParalution< ValueType2 > &  src)
inherited

Clone the Backend descriptor from another object with different template ValueType.

template<typename ValueType >
int paralution::Operator< ValueType >::get_ghost_ncol ( void  ) const
virtual

Return the number of columns in the ghost matrix/stencil.

template<typename ValueType >
int paralution::Operator< ValueType >::get_ghost_nnz ( void  ) const
virtual

Return the number of non-zeros in the ghost matrix/stencil.

template<typename ValueType >
int paralution::Operator< ValueType >::get_ghost_nrow ( void  ) const
virtual

Return the number of rows in the ghost matrix/stencil.

template<typename ValueType >
int paralution::Operator< ValueType >::get_local_ncol ( void  ) const
virtual

Return the number of columns in the local matrix/stencil.

template<typename ValueType >
int paralution::Operator< ValueType >::get_local_nnz ( void  ) const
virtual

Return the number of non-zeros in the local matrix/stencil.

template<typename ValueType >
int paralution::Operator< ValueType >::get_local_nrow ( void  ) const
virtual

Return the number of rows in the local matrix/stencil.

template<typename ValueType>
virtual int paralution::Operator< ValueType >::get_ncol ( void  ) const
pure virtual
template<typename ValueType>
virtual int paralution::Operator< ValueType >::get_nnz ( void  ) const
pure virtual
template<typename ValueType>
virtual int paralution::Operator< ValueType >::get_nrow ( void  ) const
pure virtual
template<typename ValueType >
void paralution::BaseParalution< ValueType >::MoveToAcceleratorAsync ( void  )
virtualinherited

Field Documentation

template<typename ValueType>
bool paralution::BaseParalution< ValueType >::asyncf
protectedinherited
size_t paralution::ParalutionObj::global_obj_id
protectedinherited
template<typename ValueType>
Paralution_Backend_Descriptor paralution::BaseParalution< ValueType >::local_backend_
protectedinherited

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