1234567891011121314151617181920212223242526272829303132333435363738394041424344 |
- #include <cmath>
- #include "../../test/sparse_solver.h"
- #include <Eigen/IterativeSolvers>
- template<typename T> void test_minres_T()
- {
-
- MINRES<SparseMatrix<T>, Lower, IdentityPreconditioner > minres_colmajor_lower_I;
- MINRES<SparseMatrix<T>, Upper, IdentityPreconditioner > minres_colmajor_upper_I;
-
- MINRES<SparseMatrix<T>, Lower, DiagonalPreconditioner<T> > minres_colmajor_lower_diag;
- MINRES<SparseMatrix<T>, Upper, DiagonalPreconditioner<T> > minres_colmajor_upper_diag;
- MINRES<SparseMatrix<T>, Lower|Upper, DiagonalPreconditioner<T> > minres_colmajor_uplo_diag;
-
-
- CALL_SUBTEST( check_sparse_spd_solving(minres_colmajor_lower_I) );
- CALL_SUBTEST( check_sparse_spd_solving(minres_colmajor_upper_I) );
-
- CALL_SUBTEST( check_sparse_spd_solving(minres_colmajor_lower_diag) );
- CALL_SUBTEST( check_sparse_spd_solving(minres_colmajor_upper_diag) );
- CALL_SUBTEST( check_sparse_spd_solving(minres_colmajor_uplo_diag) );
-
-
-
- }
- EIGEN_DECLARE_TEST(minres)
- {
- CALL_SUBTEST_1(test_minres_T<double>());
- }
|