ViennaCL - The Vienna Computing Library  1.5.2
Public Types | Public Member Functions
hankel_matrix< SCALARTYPE, ALIGNMENT > Class Template Reference

A Hankel matrix class. More...

#include <forwards.h>

Public Types

typedef
viennacl::backend::mem_handle 
handle_type
 
typedef scalar< typename
viennacl::tools::CHECK_SCALAR_TEMPLATE_ARGUMENT
< SCALARTYPE >::ResultType > 
value_type
 

Public Member Functions

 hankel_matrix ()
 The default constructor. Does not allocate any memory. More...
 
 hankel_matrix (vcl_size_t rows, vcl_size_t cols)
 Creates the matrix with the given size. More...
 
void resize (vcl_size_t sz, bool preserve=true)
 Resizes the matrix. Existing entries can be preserved. More...
 
handle_type const & handle () const
 Returns the OpenCL handle. More...
 
toeplitz_matrix< SCALARTYPE,
ALIGNMENT > & 
elements ()
 Returns an internal viennacl::toeplitz_matrix, which represents a Hankel matrix elements. More...
 
toeplitz_matrix< SCALARTYPE,
ALIGNMENT > const & 
elements () const
 
vcl_size_t size1 () const
 Returns the number of rows of the matrix. More...
 
vcl_size_t size2 () const
 Returns the number of columns of the matrix. More...
 
vcl_size_t internal_size () const
 Returns the internal size of matrix representtion. Usually required for launching OpenCL kernels only. More...
 
entry_proxy< SCALARTYPE > operator() (unsigned int row_index, unsigned int col_index)
 Read-write access to a element of the matrix. More...
 
hankel_matrix< SCALARTYPE,
ALIGNMENT > & 
operator+= (hankel_matrix< SCALARTYPE, ALIGNMENT > &that)
 += operation for Hankel matrices More...
 

Detailed Description

template<class SCALARTYPE, unsigned int ALIGNMENT>
class viennacl::hankel_matrix< SCALARTYPE, ALIGNMENT >

A Hankel matrix class.

Template Parameters
SCALARTYPEThe underlying scalar type (either float or double)
ALIGNMENTThe internal memory size is given by (size()/ALIGNMENT + 1) * ALIGNMENT. ALIGNMENT must be a power of two. Best values or usually 4, 8 or 16, higher values are usually a waste of memory.

Member Typedef Documentation

typedef scalar<typename viennacl::tools::CHECK_SCALAR_TEMPLATE_ARGUMENT<SCALARTYPE>::ResultType> value_type

Constructor & Destructor Documentation

hankel_matrix ( )
inlineexplicit

The default constructor. Does not allocate any memory.

hankel_matrix ( vcl_size_t  rows,
vcl_size_t  cols 
)
inlineexplicit

Creates the matrix with the given size.

Parameters
rowsNumber of rows of the matrix
colsNumber of columns of the matrix

Member Function Documentation

toeplitz_matrix<SCALARTYPE, ALIGNMENT>& elements ( )
inline

Returns an internal viennacl::toeplitz_matrix, which represents a Hankel matrix elements.

toeplitz_matrix<SCALARTYPE, ALIGNMENT> const& elements ( ) const
inline
handle_type const& handle ( ) const
inline

Returns the OpenCL handle.

Returns
OpenCL handle
vcl_size_t internal_size ( ) const
inline

Returns the internal size of matrix representtion. Usually required for launching OpenCL kernels only.

Returns
Internal size of matrix representation
entry_proxy<SCALARTYPE> operator() ( unsigned int  row_index,
unsigned int  col_index 
)
inline

Read-write access to a element of the matrix.

Parameters
row_indexRow index of accessed element
col_indexColumn index of accessed element
Returns
Proxy for matrix entry
hankel_matrix<SCALARTYPE, ALIGNMENT>& operator+= ( hankel_matrix< SCALARTYPE, ALIGNMENT > &  that)
inline

+= operation for Hankel matrices

Parameters
thatMatrix which will be added
Returns
Result of addition
void resize ( vcl_size_t  sz,
bool  preserve = true 
)
inline

Resizes the matrix. Existing entries can be preserved.

Parameters
szNew size of matrix
preserveIf true, existing values are preserved.
vcl_size_t size1 ( ) const
inline

Returns the number of rows of the matrix.

vcl_size_t size2 ( ) const
inline

Returns the number of columns of the matrix.


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