diff options
Diffstat (limited to 'unsupported/test/minres.cpp')
-rw-r--r-- | unsupported/test/minres.cpp | 25 |
1 files changed, 21 insertions, 4 deletions
diff --git a/unsupported/test/minres.cpp b/unsupported/test/minres.cpp index fd12da548..509ebe09a 100644 --- a/unsupported/test/minres.cpp +++ b/unsupported/test/minres.cpp @@ -14,15 +14,32 @@ template<typename T> void test_minres_T() { - MINRES<SparseMatrix<T>, Lower, DiagonalPreconditioner<T> > minres_colmajor_diag; - MINRES<SparseMatrix<T>, Lower, IdentityPreconditioner > minres_colmajor_I; + MINRES<SparseMatrix<T>, Lower|Upper, DiagonalPreconditioner<T> > minres_colmajor_diag; + MINRES<SparseMatrix<T>, Lower, IdentityPreconditioner > minres_colmajor_lower_I; + MINRES<SparseMatrix<T>, Upper, IdentityPreconditioner > minres_colmajor_upper_I; // MINRES<SparseMatrix<T>, Lower, IncompleteLUT<T> > minres_colmajor_ilut; //minres<SparseMatrix<T>, SSORPreconditioner<T> > minres_colmajor_ssor; - CALL_SUBTEST( check_sparse_square_solving(minres_colmajor_diag) ); - CALL_SUBTEST( check_sparse_spd_solving(minres_colmajor_I) ); + +// CALL_SUBTEST( check_sparse_square_solving(minres_colmajor_diag) ); // CALL_SUBTEST( check_sparse_square_solving(minres_colmajor_ilut) ); //CALL_SUBTEST( check_sparse_square_solving(minres_colmajor_ssor) ); + + // Diagonal preconditioner + MINRES<SparseMatrix<T>, Lower, DiagonalPreconditioner<T> > minres_colmajor_lower_diag; + MINRES<SparseMatrix<T>, Upper, DiagonalPreconditioner<T> > minres_colmajor_upper_diag; + MINRES<SparseMatrix<T>, Upper|Lower, DiagonalPreconditioner<T> > minres_colmajor_uplo_diag; + + // call tests for SPD matrix + 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) ); + + // TO DO: symmetric semi-definite matrix + // TO DO: symmetric indefinite matrix } void test_minres() |