![]() |
CCCoreLib 31 May 2022
CloudCompare Core algorithms
|
Jacobi eigen vectors/values decomposition. More...
#include <Jacobi.h>
Public Types | |
using | SquareMatrix = SquareMatrixTpl< Scalar > |
using | EigenValues = std::vector< Scalar > |
Static Public Member Functions | |
static bool | ComputeEigenValuesAndVectors2 (const SquareMatrix &matrix, SquareMatrix &eigenVectors, EigenValues &eigenValues, unsigned maxIterationCount=50) |
Computes the eigenvalues and eigenvectors of a given square matrix. More... | |
static bool | ComputeEigenValuesAndVectors (const SquareMatrix &matrix, SquareMatrix &eigenVectors, EigenValues &eigenValues, bool absoluteValues=true, unsigned maxIterationCount=50) |
Computes eigen vectors (and values) with the Jacobian method. More... | |
static bool | SortEigenValuesAndVectors (SquareMatrix &eigenVectors, EigenValues &eigenValues) |
Sorts the eigenvectors in the decreasing order of their associated eigenvalues. More... | |
static bool | GetEigenVector (const SquareMatrix &eigenVectors, unsigned index, Scalar eigenVector[]) |
Returns the given eigenvector. More... | |
static bool | GetMaxEigenValueAndVector (const SquareMatrix &eigenVectors, const EigenValues &eigenValues, Scalar &maxEigenValue, Scalar maxEigenVector[]) |
Returns the biggest eigenvalue and its associated eigenvector. More... | |
static bool | GetMinEigenValueAndVector (const SquareMatrix &eigenVectors, const EigenValues &eigenValues, Scalar &minEigenValue, Scalar minEigenVector[]) |
Returns the smallest eigenvalue and its associated eigenvector. More... | |
Jacobi eigen vectors/values decomposition.
|
inlinestatic |
Computes eigen vectors (and values) with the Jacobian method.
See the Numerical Recipes.
|
inlinestatic |
Computes the eigenvalues and eigenvectors of a given square matrix.
It uses Rutishauser's modfications of the classical Jacobi rotation method with threshold pivoting.
Note: this code is inspired from John Burkardt's 'jacobi_eigenvalue' code See https://people.sc.fsu.edu/~jburkardt/cpp_src/jacobi_eigenvalue/jacobi_eigenvalue.cpp
[in] | matrix | input square matrix |
[out] | eigenVectors | eigenvectors (as a square matrix) |
[out] | eigenValues | eigenvalues |
[in] | maxIterationCount | max number of iteration (optional) |
|
inlinestatic |
Returns the given eigenvector.
eigenVectors | eigenvectors (as a square matrix) |
index | requested eigenvector index (< eigenvectors matrix size) |
eigenVector | output vector (size = matrix size) |
|
inlinestatic |
Returns the biggest eigenvalue and its associated eigenvector.
eigenVectors | eigenvectors (as a square matrix) |
eigenValues | eigenvalues |
maxEigenValue | biggest eigenvalue |
maxEigenVector | eigenvector vector corresponding to the biggest eigenvalue |
|
inlinestatic |
Returns the smallest eigenvalue and its associated eigenvector.
eigenVectors | eigenvectors (as a square matrix) |
eigenValues | eigenvalues |
minEigenValue | smallest eigenvalue |
minEigenVector | eigenvector vector corresponding to the smallest eigenvalue |
|
inlinestatic |
Sorts the eigenvectors in the decreasing order of their associated eigenvalues.
eigenVectors | eigenvectors (as a square matrix) |
eigenValues | eigenvalues |