File kernel/src/utils/SiconosAlgebra/EigenProblems.hpp

File kernel/src/utils/SiconosAlgebra/EigenProblems.hpp#

Go to the source code of this file

Functions to compute eigenvalues/vectors of a matrix. Based on boost ublas bindings to lapack. Usage : see EigenProblemsTest.cpp.

namespace Siconos
namespace eigenproblems#

Functions

int syev(SiconosVector &eigenval, SiconosMatrix &eigenvec, bool withVect = true)#

Compute eigenvalues and eigenvectors of a real symmetric matrix A See examples of use in test/EigenProblemsTest.cpp.

Parameters:
  • eigenval[inout] : eigenvalues of the matrix

  • eigenvec[inout] : input matrix A, replace with eigenvectors (columns) in output.

  • withVect[in] : true if eigenvectors are to be computed (default = true). eigenvector.

Returns:

int : return value from lapack routine. 0 if successful.

int geev(SiconosMatrix &input_mat, complex_vector &eigenval, complex_matrix &left_eigenvec, complex_matrix &right_eigenvec, bool withLeft = false, bool withRight = true)#

Compute eigenvalues and eigenvectors of a nonsymmetrix complex matrix See examples of use in test/EigenProblemsTest.cpp.

Parameters:
  • input_mat[inout] SiconosMatrix : input matrix.

  • eigenval[inout] complex_vector : eigenvalues of the matrix

  • left_eigenvec[inout] complex_matrix : matrix of the left eigenvectors

  • right_eigenvec[inout] complex_matrix : matrix of the right eigenvectors

  • withLeft[in] : true if left eigenvectors are to be computed (default = false).

  • withRight[in] : true if right eigenvectors are to be computed (default = true).

Returns:

int : return value from lapack routine. 0 if succesful.