12 #ifndef EIGEN_COMPLEX_EIGEN_SOLVER_H 13 #define EIGEN_COMPLEX_EIGEN_SOLVER_H 61 typedef typename MatrixType::Scalar
Scalar;
125 template<
typename InputType>
127 :
m_eivec(matrix.rows(),matrix.cols()),
132 m_matX(matrix.rows(),matrix.cols())
212 template<
typename InputType>
258 template<
typename MatrixType>
259 template<
typename InputType>
275 if(computeEigenvectors)
286 template<
typename MatrixType>
293 m_matX = EigenvectorType::Zero(n, n);
294 for(
Index k=n-1 ; k>=0 ; k--)
298 for(
Index i=k-1 ; i>=0 ; i--)
317 for(
Index k=0 ; k<n ; k++)
324 template<
typename MatrixType>
328 for (
Index i=0; i<n; i++)
336 if(computeEigenvectors)
344 #endif // EIGEN_COMPLEX_EIGEN_SOLVER_H
EIGEN_DEVICE_FUNC void swap(DenseBase< OtherDerived > &other)
static void check_template_parameters()
ComplexSchur< MatrixType > m_schur
EIGEN_DEVICE_FUNC Index rows() const
ComplexSchur & setMaxIterations(Index maxIters)
Sets the maximum number of iterations allowed.
ComplexEigenSolver(Index size)
Default Constructor with memory preallocation.
ComplexEigenSolver & compute(const EigenBase< InputType > &matrix, bool computeEigenvectors=true)
Computes eigendecomposition of given matrix.
Matrix< ComplexScalar, ColsAtCompileTime, 1, Options &(~RowMajor), MaxColsAtCompileTime, 1 > EigenvalueType
Type for vector of eigenvalues as returned by eigenvalues().
EigenvalueType m_eivalues
Holds information about the various numeric (i.e. scalar) types allowed by Eigen. ...
MatrixType::Scalar Scalar
Scalar type for matrices of type MatrixType.
ComplexSchur & compute(const EigenBase< InputType > &matrix, bool computeU=true)
Computes Schur decomposition of given matrix.
ComputationInfo info() const
Reports whether previous computation was successful.
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE Scalar & coeffRef(Index rowId, Index colId)
const EigenvalueType & eigenvalues() const
Returns the eigenvalues of given matrix.
Matrix< ComplexScalar, RowsAtCompileTime, ColsAtCompileTime, Options, MaxRowsAtCompileTime, MaxColsAtCompileTime > EigenvectorType
Type for matrix of eigenvectors as returned by eigenvectors().
NumTraits< Scalar >::Real RealScalar
ComputationInfo info() const
Reports whether previous computation was successful.
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE const Scalar & coeff(Index rowId, Index colId) const
EIGEN_DEFAULT_DENSE_INDEX_TYPE Index
The Index type as used for the API.
ComplexEigenSolver(const EigenBase< InputType > &matrix, bool computeEigenvectors=true)
Constructor; computes eigendecomposition of given matrix.
#define EIGEN_STATIC_ASSERT_NON_INTEGER(TYPE)
const EigenvectorType & eigenvectors() const
Returns the eigenvectors of given matrix.
Index getMaxIterations()
Returns the maximum number of iterations.
void doComputeEigenvectors(const RealScalar &matrixnorm)
_MatrixType MatrixType
Synonym for the template parameter _MatrixType.
ComplexEigenSolver()
Default constructor.
Index getMaxIterations()
Returns the maximum number of iterations.
ComplexEigenSolver & setMaxIterations(Index maxIters)
Sets the maximum number of iterations allowed.
const ComplexMatrixType & matrixU() const
Returns the unitary matrix in the Schur decomposition.
EIGEN_DEVICE_FUNC Index cols() const
void sortEigenvalues(bool computeEigenvectors)
std::complex< RealScalar > ComplexScalar
Complex scalar type for MatrixType.
Computes eigenvalues and eigenvectors of general complex matrices.
EIGEN_DEVICE_FUNC Derived & derived()
const ComplexMatrixType & matrixT() const
Returns the triangular matrix in the Schur decomposition.
void swap(scoped_array< T > &a, scoped_array< T > &b)