Eigen  3.4.90 (git rev 67eeba6e720c5745abc77ae6c92ce0a44aa7b7ae)
Eigen::BDCSVD< MatrixType_, Options_ > Class Template Reference

Detailed Description

template<typename MatrixType_, int Options_>
class Eigen::BDCSVD< MatrixType_, Options_ >

class Bidiagonal Divide and Conquer SVD

Template Parameters
MatrixType_the type of the matrix of which we are computing the SVD decomposition
Options_this optional parameter allows one to specify options for computing unitaries U and V. Possible values are ComputeThinU, ComputeThinV, ComputeFullU, ComputeFullV. It is not possible to request both the thin and full version of U or V. By default, unitaries are not computed.

This class first reduces the input matrix to bi-diagonal form using class UpperBidiagonalization, and then performs a divide-and-conquer diagonalization. Small blocks are diagonalized using class JacobiSVD. You can control the switching size with the setSwitchSize() method, default is 16. For small matrice (<16), it is thus preferable to directly use JacobiSVD. For larger ones, BDCSVD is highly recommended and can several order of magnitude faster.

Warning
this algorithm is unlikely to provide accurate result when compiled with unsafe math optimizations. For instance, this concerns Intel's compiler (ICC), which performs such optimization by default unless you compile with the -fp-model precise option. Likewise, the -ffast-math option of GCC or clang will significantly degrade the accuracy.
See also
class JacobiSVD
+ Inheritance diagram for Eigen::BDCSVD< MatrixType_, Options_ >:

Public Member Functions

 BDCSVD ()
 Default Constructor. More...
 
 BDCSVD (const MatrixType &matrix)
 Constructor performing the decomposition of given matrix, using the custom options specified with the Options template paramter. More...
 
EIGEN_DEPRECATED BDCSVD (const MatrixType &matrix, unsigned int computationOptions)
 Constructor performing the decomposition of given matrix using specified options for computing unitaries. More...
 
 BDCSVD (Index rows, Index cols)
 Default Constructor with memory preallocation. More...
 
EIGEN_DEPRECATED BDCSVD (Index rows, Index cols, unsigned int computationOptions)
 Default Constructor with memory preallocation. More...
 
EIGEN_CONSTEXPR Index cols () const EIGEN_NOEXCEPT
 
BDCSVDcompute (const MatrixType &matrix)
 Method performing the decomposition of given matrix. Computes Thin/Full unitaries U/V if specified using the Options template parameter or the class constructor. More...
 
EIGEN_DEPRECATED BDCSVDcompute (const MatrixType &matrix, unsigned int computationOptions)
 Method performing the decomposition of given matrix, as specified by the computationOptions parameter. More...
 
EIGEN_CONSTEXPR Index rows () const EIGEN_NOEXCEPT
 
- Public Member Functions inherited from Eigen::SVDBase< BDCSVD< MatrixType_, Options_ > >
bool computeU () const
 
bool computeV () const
 
ComputationInfo info () const
 Reports whether previous computation was successful. More...
 
const MatrixUTypematrixU () const
 
const MatrixVTypematrixV () const
 
Index nonzeroSingularValues () const
 
Index rank () const
 
BDCSVD< MatrixType_, Options_ > & setThreshold (const RealScalar &threshold)
 
BDCSVD< MatrixType_, Options_ > & setThreshold (Default_t)
 
const SingularValuesType & singularValues () const
 
const Solve< BDCSVD< MatrixType_, Options_ >, Rhs > solve (const MatrixBase< Rhs > &b) const
 
RealScalar threshold () const
 
- Public Member Functions inherited from Eigen::SolverBase< Derived >
const AdjointReturnType adjoint () const
 
Derived & derived ()
 
const Derived & derived () const
 
template<typename Rhs >
const Solve< Derived, Rhs > solve (const MatrixBase< Rhs > &b) const
 
 SolverBase ()
 
const ConstTransposeReturnType transpose () const
 
- Public Member Functions inherited from Eigen::EigenBase< Derived >
EIGEN_CONSTEXPR Index cols () const EIGEN_NOEXCEPT
 
Derived & derived ()
 
const Derived & derived () const
 
EIGEN_CONSTEXPR Index rows () const EIGEN_NOEXCEPT
 
EIGEN_CONSTEXPR Index size () const EIGEN_NOEXCEPT
 

Additional Inherited Members

- Public Types inherited from Eigen::SVDBase< BDCSVD< MatrixType_, Options_ > >
typedef Eigen::Index Index
 
- Public Types inherited from Eigen::EigenBase< Derived >
typedef Eigen::Index Index
 The interface type of indices. More...
 
- Protected Member Functions inherited from Eigen::SVDBase< BDCSVD< MatrixType_, Options_ > >
 SVDBase ()
 Default Constructor. More...
 

Constructor & Destructor Documentation

◆ BDCSVD() [1/5]

template<typename MatrixType_ , int Options_>
Eigen::BDCSVD< MatrixType_, Options_ >::BDCSVD ( )
inline

Default Constructor.

The default constructor is useful in cases in which the user intends to perform decompositions via BDCSVD::compute(const MatrixType&).

◆ BDCSVD() [2/5]

template<typename MatrixType_ , int Options_>
Eigen::BDCSVD< MatrixType_, Options_ >::BDCSVD ( Index  rows,
Index  cols 
)
inline

Default Constructor with memory preallocation.

Like the default constructor but with preallocation of the internal data according to the specified problem size and Options template parameter.

See also
BDCSVD()

◆ BDCSVD() [3/5]

template<typename MatrixType_ , int Options_>
EIGEN_DEPRECATED Eigen::BDCSVD< MatrixType_, Options_ >::BDCSVD ( Index  rows,
Index  cols,
unsigned int  computationOptions 
)
inline

Default Constructor with memory preallocation.

Like the default constructor but with preallocation of the internal data according to the specified problem size and the computationOptions.

One cannot request unitiaries using both the Options template parameter and the constructor. If possible, prefer using the Options template parameter.

Parameters
computationOptionsspecifification for computing Thin/Full unitaries U/V
See also
BDCSVD()
Deprecated:
Will be removed in the next major Eigen version. Options should be specified in the Options template parameter.

◆ BDCSVD() [4/5]

template<typename MatrixType_ , int Options_>
Eigen::BDCSVD< MatrixType_, Options_ >::BDCSVD ( const MatrixType &  matrix)
inline

Constructor performing the decomposition of given matrix, using the custom options specified with the Options template paramter.

Parameters
matrixthe matrix to decompose

◆ BDCSVD() [5/5]

template<typename MatrixType_ , int Options_>
EIGEN_DEPRECATED Eigen::BDCSVD< MatrixType_, Options_ >::BDCSVD ( const MatrixType &  matrix,
unsigned int  computationOptions 
)
inline

Constructor performing the decomposition of given matrix using specified options for computing unitaries.

One cannot request unitiaries using both the Options template parameter and the constructor. If possible, prefer using the Options template parameter.

Parameters
matrixthe matrix to decompose
computationOptionsspecifification for computing Thin/Full unitaries U/V
Deprecated:
Will be removed in the next major Eigen version. Options should be specified in the Options template parameter.

Member Function Documentation

◆ cols()

template<typename MatrixType_ , int Options_>
EIGEN_CONSTEXPR Index Eigen::EigenBase< Derived >::cols ( void  )
inline
Returns
the number of columns.
See also
rows(), ColsAtCompileTime

◆ compute() [1/2]

template<typename MatrixType_ , int Options_>
BDCSVD& Eigen::BDCSVD< MatrixType_, Options_ >::compute ( const MatrixType &  matrix)
inline

Method performing the decomposition of given matrix. Computes Thin/Full unitaries U/V if specified using the Options template parameter or the class constructor.

Parameters
matrixthe matrix to decompose

◆ compute() [2/2]

template<typename MatrixType_ , int Options_>
EIGEN_DEPRECATED BDCSVD& Eigen::BDCSVD< MatrixType_, Options_ >::compute ( const MatrixType &  matrix,
unsigned int  computationOptions 
)
inline

Method performing the decomposition of given matrix, as specified by the computationOptions parameter.

Parameters
matrixthe matrix to decompose
computationOptionsspecify whether to compute Thin/Full unitaries U/V
Deprecated:
Will be removed in the next major Eigen version. Options should be specified in the Options template parameter.

◆ rows()

template<typename MatrixType_ , int Options_>
EIGEN_CONSTEXPR Index Eigen::EigenBase< Derived >::rows ( void  )
inline
Returns
the number of rows.
See also
cols(), RowsAtCompileTime

The documentation for this class was generated from the following file: