Go to the documentation of this file.
4 #include <Eigen/IterativeLinearSolvers>
5 #include <unsupported/Eigen/IterativeSolvers>
36 template<
typename Rhs>
58 template<
typename Rhs>
64 template<
typename Dest>
69 assert(
alpha==
Scalar(1) &&
"scaling is not implemented");
91 Eigen::VectorXd
b(
n),
x;
99 std::cout <<
"CG: #iterations: " << cg.iterations() <<
", estimated error: " << cg.error() << std::endl;
106 std::cout <<
"BiCGSTAB: #iterations: " << bicg.iterations() <<
", estimated error: " << bicg.error() << std::endl;
113 std::cout <<
"GMRES: #iterations: " <<
gmres.iterations() <<
", estimated error: " <<
gmres.error() << std::endl;
120 std::cout <<
"DGMRES: #iterations: " <<
gmres.iterations() <<
", estimated error: " <<
gmres.error() << std::endl;
127 std::cout <<
"MINRES: #iterations: " <<
minres.iterations() <<
", estimated error: " <<
minres.error() << std::endl;
A GMRES solver for sparse square problems.
Namespace containing all symbols from the Eigen library.
A versatible sparse matrix representation.
A Restarted GMRES with deflation. This class implements a modification of the GMRES solver for sparse...
Eigen::Index Index
The interface type of indices.
const SparseMatrix< double > * mp_mat
static void scaleAndAddTo(Dest &dst, const MatrixReplacement &lhs, const Rhs &rhs, const Scalar &alpha)
set noclip points set clip one set noclip two set bar set border lt lw set xdata set ydata set zdata set x2data set y2data set boxwidth set dummy x
#define EIGEN_ONLY_USED_FOR_DEBUG(x)
Matrix< SCALARA, Dynamic, Dynamic, opt_A > A
void attachMyMatrix(const SparseMatrix< double > &mat)
A minimal residual solver for sparse symmetric problems.
A conjugate gradient solver for sparse (or dense) self-adjoint problems.
Expression of the product of two arbitrary matrices or vectors.
bool gmres(const MatrixType &mat, const Rhs &rhs, Dest &x, const Preconditioner &precond, Index &iters, const Index &restart, typename Dest::RealScalar &tol_error)
A bi conjugate gradient stabilized solver for sparse square problems.
EIGEN_DONT_INLINE void minres(const MatrixType &mat, const Rhs &rhs, Dest &x, const Preconditioner &precond, Index &iters, typename Dest::RealScalar &tol_error)
Product< MatrixReplacement, Rhs >::Scalar Scalar
const SparseMatrix< double > my_matrix() const
Eigen::Product< MatrixReplacement, Rhs, Eigen::AliasFreeProduct > operator*(const Eigen::MatrixBase< Rhs > &x) const
Base class for all dense matrices, vectors, and expressions.
EIGEN_DEFAULT_DENSE_INDEX_TYPE Index
The Index type as used for the API.
gtsam
Author(s):
autogenerated on Sat Nov 16 2024 04:03:06