\( \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.11 - CGAL and Solvers
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Groups Pages
DiagonalizeTraits Concept Reference

Definition

template<typename FT, unsigned int dim = 3>
class DiagonalizeTraits< FT, dim >

Concept providing functions to extract eigenvectors and eigenvalues from covariance matrices represented by an array a, using symmetric diagonalization. For example, a matrix of dimension 3 is defined as follows:

\( \begin{bmatrix} a[0] & a[1] & a[2] \\ a[1] & a[3] & a[4] \\ a[2] & a[4] & a[5] \\ \end{bmatrix}\)
Template Parameters
FTNumber type
dimDimension of the matrices and vectors
Has Models:

CGAL::Eigen_diagonalize_traits

CGAL::Diagonalize_traits

Public Types

typedef cpp11::array< FT, dim > Vector
 
typedef cpp11::array< FT, dim
*dim > 
Matrix
 
typedef cpp11::array< FT,(dim
*(dim+1)/2)> 
Covariance_matrix
 

Static Public Member Functions

static bool diagonalize_selfadjoint_covariance_matrix (const Covariance_matrix &cov, Vector &eigenvalues)
 fill eigenvalues with the eigenvalues of the covariance matrix represented by cov. More...
 
static bool diagonalize_selfadjoint_covariance_matrix (const Covariance_matrix &cov, Vector &eigenvalues, Matrix &eigenvectors)
 fill eigenvalues with the eigenvalues and eigenvectors with the eigenvectors of the covariance matrix represented by cov. More...
 
static bool extract_largest_eigenvector_of_covariance_matrix (const Covariance_matrix &cov, Vector &normal)
 Extract the eigenvector associated to the largest eigenvalue of the covariance matrix represented by cov. More...
 

Member Function Documentation

template<typename FT , unsigned int dim = 3>
static bool DiagonalizeTraits< FT, dim >::diagonalize_selfadjoint_covariance_matrix ( const Covariance_matrix cov,
Vector eigenvalues 
)
static

fill eigenvalues with the eigenvalues of the covariance matrix represented by cov.

Eigenvalues are sorted by increasing order.

Returns
true if the operation was successful and false otherwise.
template<typename FT , unsigned int dim = 3>
static bool DiagonalizeTraits< FT, dim >::diagonalize_selfadjoint_covariance_matrix ( const Covariance_matrix cov,
Vector eigenvalues,
Matrix eigenvectors 
)
static

fill eigenvalues with the eigenvalues and eigenvectors with the eigenvectors of the covariance matrix represented by cov.

Eigenvalues are sorted by increasing order.

Returns
true if the operation was successful and false otherwise.
template<typename FT , unsigned int dim = 3>
static bool DiagonalizeTraits< FT, dim >::extract_largest_eigenvector_of_covariance_matrix ( const Covariance_matrix cov,
Vector normal 
)
static

Extract the eigenvector associated to the largest eigenvalue of the covariance matrix represented by cov.

Returns
true if the operation was successful and false otherwise.