From f920ea44a396d6467685d20d69f8ddba0a4af24b Mon Sep 17 00:00:00 2001 From: xDarkLemon Date: Mon, 12 Aug 2024 17:27:18 -0400 Subject: [PATCH] Fix Trilinos nullspace --- src/polysolve/linear/Solver.hpp | 3 --- src/polysolve/linear/TrilinosSolver.cpp | 10 ---------- src/polysolve/linear/TrilinosSolver.hpp | 2 -- 3 files changed, 15 deletions(-) diff --git a/src/polysolve/linear/Solver.hpp b/src/polysolve/linear/Solver.hpp index 9a53121..3df9128 100644 --- a/src/polysolve/linear/Solver.hpp +++ b/src/polysolve/linear/Solver.hpp @@ -4,9 +4,6 @@ #include -#include -#include -#include #define POLYSOLVE_DELETE_MOVE_COPY(Base) \ Base(Base &&) = delete; \ diff --git a/src/polysolve/linear/TrilinosSolver.cpp b/src/polysolve/linear/TrilinosSolver.cpp index 1edd18f..4e94306 100644 --- a/src/polysolve/linear/TrilinosSolver.cpp +++ b/src/polysolve/linear/TrilinosSolver.cpp @@ -12,7 +12,6 @@ namespace polysolve::linear TrilinosSolver::TrilinosSolver() { precond_num_ = 0; -// #ifdef HAVE_MPI int done_already; MPI_Initialized(&done_already); if (!done_already) @@ -25,9 +24,6 @@ namespace polysolve::linear MPI_Init(&argc, &argvv); CommPtr = new Epetra_MpiComm(MPI_COMM_WORLD); } -// #else - // CommPtr=new Epetra_SerialComm; -// #endif } //////////////////////////////////////////////////////////////// @@ -50,10 +46,6 @@ namespace polysolve::linear { conv_tol_ = params["Trilinos"]["tolerance"]; } - if (params["Trilinos"].contains("is_nullspace")) - { - is_nullspace_ = params["Trilinos"]["is_nullspace"]; - } } } @@ -289,9 +281,7 @@ namespace polysolve::linear delete A; delete rowMap; delete MLPrec; -// #ifdef HAVE_MPI MPI_Finalize() ; -// #endif } } diff --git a/src/polysolve/linear/TrilinosSolver.hpp b/src/polysolve/linear/TrilinosSolver.hpp index f1cf897..0b3fdb2 100644 --- a/src/polysolve/linear/TrilinosSolver.hpp +++ b/src/polysolve/linear/TrilinosSolver.hpp @@ -84,8 +84,6 @@ namespace polysolve::linear double conv_tol_ = 1e-8; size_t iterations_; double residual_error_; - bool is_nullspace_ = true; - Eigen::MatrixXd reduced_vertices; ML_Epetra::MultiLevelPreconditioner* MLPrec=NULL; Epetra_Map *rowMap=NULL;