Spectra
Spectra::DenseSymMatProd< Scalar, Uplo > Class Template Reference

#include <DenseSymMatProd.h>

Public Member Functions

 DenseSymMatProd (ConstGenericMatrix &mat_)
 
int rows () const
 
int cols () const
 
void perform_op (const Scalar *x_in, Scalar *y_out) const
 

Detailed Description

template<typename Scalar, int Uplo = Eigen::Lower>
class Spectra::DenseSymMatProd< Scalar, Uplo >

This class defines the matrix-vector multiplication operation on a symmetric real matrix \(A\), i.e., calculating \(y=Ax\) for any vector \(x\). It is mainly used in the SymEigsSolver eigen solver.

Definition at line 23 of file DenseSymMatProd.h.

Constructor & Destructor Documentation

◆ DenseSymMatProd()

template<typename Scalar , int Uplo = Eigen::Lower>
Spectra::DenseSymMatProd< Scalar, Uplo >::DenseSymMatProd ( ConstGenericMatrix &  mat_)
inline

Constructor to create the matrix operation object.

Parameters
mat_An Eigen matrix object, whose type can be Eigen::Matrix<Scalar, ...> (e.g. Eigen::MatrixXd and Eigen::MatrixXf), or its mapped version (e.g. Eigen::Map<Eigen::MatrixXd>).

Definition at line 45 of file DenseSymMatProd.h.

Member Function Documentation

◆ rows()

template<typename Scalar , int Uplo = Eigen::Lower>
int Spectra::DenseSymMatProd< Scalar, Uplo >::rows ( ) const
inline

Return the number of rows of the underlying matrix.

Definition at line 52 of file DenseSymMatProd.h.

◆ cols()

template<typename Scalar , int Uplo = Eigen::Lower>
int Spectra::DenseSymMatProd< Scalar, Uplo >::cols ( ) const
inline

Return the number of columns of the underlying matrix.

Definition at line 56 of file DenseSymMatProd.h.

◆ perform_op()

template<typename Scalar , int Uplo = Eigen::Lower>
void Spectra::DenseSymMatProd< Scalar, Uplo >::perform_op ( const Scalar *  x_in,
Scalar *  y_out 
) const
inline

Perform the matrix-vector multiplication operation \(y=Ax\).

Parameters
x_inPointer to the \(x\) vector.
y_outPointer to the \(y\) vector.

Definition at line 65 of file DenseSymMatProd.h.


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