CGAL 5.1 - CGAL and Solvers
CGAL::Eigen_matrix< FT, D1, D2 > Struct Template Reference

#include <CGAL/Eigen_matrix.h>

Inherits Matrix< FT, ::Eigen::Dynamic, ::Eigen::Dynamic >.

Definition

template<class FT, int D1 = ::Eigen::Dynamic, int D2 = ::Eigen::Dynamic>
struct CGAL::Eigen_matrix< FT, D1, D2 >

The class Eigen_matrix is a wrapper around Eigen matrix type Eigen::Matrix.

Is Model Of:
SvdTraits::Matrix
Template Parameters
TNumber type.
D1Number of rows, or Dynamic
D2Number of columns, or Dynamic
See also
CGAL::Eigen_vector<T>
CGAL::Eigen_sparse_matrix<T>
CGAL::Eigen_sparse_symmetric_matrix<T>

Public Types

typedef ::Eigen::Matrix< FT, D1, D2 > EigenType
 The internal matrix type from Eigen. More...
 

Public Member Functions

 Eigen_matrix ()
 Constructs a null matrix. More...
 
 Eigen_matrix (std::size_t nr, std::size_t nc)
 Constructs an uninitialized matrix with nr rows and nc columns. More...
 
 Eigen_matrix (const EigenType &b)
 Constructs a matrix from an Eigen matrix. More...
 
std::size_t number_of_rows () const
 Returns the matrix number of rows. More...
 
std::size_t number_of_columns () const
 Returns the matrix number of columns. More...
 
FT operator() (std::size_t i, std::size_t j) const
 Returns the value of the matrix at position (i,j). More...
 
void set (std::size_t i, std::size_t j, FT value)
 Writes access to a matrix coefficient: a_ij <- val. More...
 
const EigenTypeeigen_object () const
 Returns the internal matrix, with type EigenType. More...
 

Member Typedef Documentation

◆ EigenType

template<class FT , int D1 = ::Eigen::Dynamic, int D2 = ::Eigen::Dynamic>
typedef ::Eigen::Matrix<FT, D1, D2> CGAL::Eigen_matrix< FT, D1, D2 >::EigenType

The internal matrix type from Eigen.

Constructor & Destructor Documentation

◆ Eigen_matrix() [1/3]

template<class FT , int D1 = ::Eigen::Dynamic, int D2 = ::Eigen::Dynamic>
CGAL::Eigen_matrix< FT, D1, D2 >::Eigen_matrix ( )

Constructs a null matrix.

◆ Eigen_matrix() [2/3]

template<class FT , int D1 = ::Eigen::Dynamic, int D2 = ::Eigen::Dynamic>
CGAL::Eigen_matrix< FT, D1, D2 >::Eigen_matrix ( std::size_t  nr,
std::size_t  nc 
)

Constructs an uninitialized matrix with nr rows and nc columns.

This is useful for dynamic-size matrices. For fixed-size matrices, it is redundant to pass these parameters.

◆ Eigen_matrix() [3/3]

template<class FT , int D1 = ::Eigen::Dynamic, int D2 = ::Eigen::Dynamic>
CGAL::Eigen_matrix< FT, D1, D2 >::Eigen_matrix ( const EigenType b)

Constructs a matrix from an Eigen matrix.

Member Function Documentation

◆ eigen_object()

template<class FT , int D1 = ::Eigen::Dynamic, int D2 = ::Eigen::Dynamic>
const EigenType& CGAL::Eigen_matrix< FT, D1, D2 >::eigen_object ( ) const

Returns the internal matrix, with type EigenType.

◆ number_of_columns()

template<class FT , int D1 = ::Eigen::Dynamic, int D2 = ::Eigen::Dynamic>
std::size_t CGAL::Eigen_matrix< FT, D1, D2 >::number_of_columns ( ) const

Returns the matrix number of columns.

◆ number_of_rows()

template<class FT , int D1 = ::Eigen::Dynamic, int D2 = ::Eigen::Dynamic>
std::size_t CGAL::Eigen_matrix< FT, D1, D2 >::number_of_rows ( ) const

Returns the matrix number of rows.

◆ operator()()

template<class FT , int D1 = ::Eigen::Dynamic, int D2 = ::Eigen::Dynamic>
FT CGAL::Eigen_matrix< FT, D1, D2 >::operator() ( std::size_t  i,
std::size_t  j 
) const

Returns the value of the matrix at position (i,j).

◆ set()

template<class FT , int D1 = ::Eigen::Dynamic, int D2 = ::Eigen::Dynamic>
void CGAL::Eigen_matrix< FT, D1, D2 >::set ( std::size_t  i,
std::size_t  j,
FT  value 
)

Writes access to a matrix coefficient: a_ij <- val.