\( \newcommand{\E}{\mathrm{E}} \) \( \newcommand{\A}{\mathrm{A}} \) \( \newcommand{\R}{\mathrm{R}} \) \( \newcommand{\N}{\mathrm{N}} \) \( \newcommand{\Q}{\mathrm{Q}} \) \( \newcommand{\Z}{\mathrm{Z}} \) \( \def\ccSum #1#2#3{ \sum_{#1}^{#2}{#3} } \def\ccProd #1#2#3{ \sum_{#1}^{#2}{#3} }\)
CGAL 4.12 - CGAL and Solvers
CGAL::Eigen_sparse_symmetric_matrix< T > Struct Template Reference

#include <CGAL/Eigen_matrix.h>

Inherits from

CGAL::Eigen_sparse_matrix< T >.

Definition

The class Eigen_sparse_symmetric_matrix is a wrapper around Eigen matrix type Eigen::SparseMatrix

Since the matrix is symmetric, only the lower triangle part is stored.

Is Model Of:
SparseLinearAlgebraTraits_d::Matrix
Template Parameters
TNumber type.
See also
CGAL::Eigen_vector<T>
CGAL::Eigen_sparse_matrix<T>

Public Member Functions

 Eigen_sparse_symmetric_matrix (int dim)
 Create a square symmetric matrix initialized with zeros. More...
 
 Eigen_sparse_symmetric_matrix (int rows, int columns)
 Create a square symmetric matrix initialized with zeros. More...
 
- Public Member Functions inherited from CGAL::Eigen_sparse_matrix< T >
 Eigen_sparse_matrix (std::size_t dim, bool is_symmetric=false)
 Create a square matrix initialized with zeros. More...
 
 Eigen_sparse_matrix (int dim, bool is_symmetric=false)
 Create a square matrix initialized with zeros. More...
 
 Eigen_sparse_matrix (std::size_t rows, std::size_t columns, bool is_symmetric=false)
 Create a rectangular matrix initialized with zeros. More...
 
 ~Eigen_sparse_matrix ()
 Delete this object and the wrapped matrix.
 
 Eigen_sparse_matrix (int rows, int columns, bool is_symmetric=false)
 Create a rectangular matrix initialized with zeros. More...
 
int row_dimension () const
 Return the matrix number of rows.
 
int column_dimension () const
 Return the matrix number of columns.
 
void set_coef (std::size_t i_, std::size_t j_, T val, bool new_coef=false)
 Write access to a matrix coefficient: a_ij <- val. More...
 
void add_coef (int i, int j, T val)
 Write access to a matrix coefficient: a_ij <- a_ij + val. More...
 
NT get_coef (unsigned int i, unsigned int j) const
 Read access to a matrix coefficient. More...
 
const EigenTypeeigen_object () const
 Return the internal matrix, with type EigenType.
 

Additional Inherited Members

- Public Types inherited from CGAL::Eigen_sparse_matrix< T >
typedef Eigen::SparseMatrix< T > EigenType
 The internal matrix type from Eigen.
 
typedef T NT
 

Constructor & Destructor Documentation

◆ Eigen_sparse_symmetric_matrix() [1/2]

Create a square symmetric matrix initialized with zeros.

Parameters
dimMatrix dimension.

◆ Eigen_sparse_symmetric_matrix() [2/2]

template<class T >
CGAL::Eigen_sparse_symmetric_matrix< T >::Eigen_sparse_symmetric_matrix ( int  rows,
int  columns 
)

Create a square symmetric matrix initialized with zeros.

Precondition
rows == columns.
Parameters
rowsNumber of rows.
columnsNumber of columns.