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 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.

Return

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

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

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

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

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

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

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

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.

Return

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

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

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

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