opm-simulators
TPSALinearSolverParameters.hpp
1 // -*- mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-
2 // vi: set et ts=4 sw=4 sts=4:
3 /*
4  Copyright 2025 NORCE AS
5 
6  This file is part of the Open Porous Media project (OPM).
7 
8  OPM is free software: you can redistribute it and/or modify
9  it under the terms of the GNU General Public License as published by
10  the Free Software Foundation, either version 2 of the License, or
11  (at your option) any later version.
12 
13  OPM is distributed in the hope that it will be useful,
14  but WITHOUT ANY WARRANTY; without even the implied warranty of
15  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16  GNU General Public License for more details.
17 
18  You should have received a copy of the GNU General Public License
19  along with OPM. If not, see <http://www.gnu.org/licenses/>.
20 
21  Consult the COPYING file in the top-level source directory of this
22  module for the precise wording of the license and the list of
23  copyright holders.
24 */
25 #ifndef TPSA_LINEAR_SOLVER_PARAMETERS_HPP
26 #define TPSA_LINEAR_SOLVER_PARAMETERS_HPP
27 
28 #include <opm/simulators/linalg/FlowLinearSolverParameters.hpp>
29 
30 #include <string>
31 
32 
33 // Default runtime parameters
34 namespace Opm::Parameters {
35 
36 struct TpsaLinearSolverReduction { static constexpr double value = 1e-3; };
37 struct TpsaRelaxedLinearSolverReduction { static constexpr double value = 1e-3; };
38 struct TpsaLinearSolverMaxIter { static constexpr int value = 200; };
39 struct TpsaLinearSolverRestart { static constexpr int value = 40; };
40 struct TpsaLinearSolverVerbosity { static constexpr int value = 0; };
41 struct TpsaIluRelaxation { static constexpr double value = 0.9; };
42 struct TpsaIluFillinLevel { static constexpr int value = 0; };
43 struct TpsaUseGmres { static constexpr bool value = false; };
44 struct TpsaLinearSolverIgnoreConvergenceFailure { static constexpr bool value = false; };
45 struct TpsaLinearSolver { static constexpr auto value = "ilu0"; };
46 struct TpsaLinearSolverPrintJsonDefinition { static constexpr auto value = false; };
47 
48 } // namespace Opm::Parameters
49 
50 namespace Opm {
51 
56 {
57  void init();
58  static void registerParameters();
59  void reset();
60 };
61 
62 } // namespace Opm
63 
64 #endif
Parametern for linear solver and preconditioner.
Definition: TPSALinearSolverParameters.hpp:55
This file contains a set of helper functions used by VFPProd / VFPInj.
Definition: blackoilbioeffectsmodules.hh:45
Definition: blackoilnewtonmethodparams.hpp:31
Definition: TPSALinearSolverParameters.hpp:41
Definition: TPSALinearSolverParameters.hpp:38
Definition: TPSALinearSolverParameters.hpp:46
Definition: TPSALinearSolverParameters.hpp:42
Definition: TPSALinearSolverParameters.hpp:45
Definition: TPSALinearSolverParameters.hpp:40
Definition: TPSALinearSolverParameters.hpp:39
This class carries all parameters for the NewtonIterationBlackoilInterleaved class.
Definition: FlowLinearSolverParameters.hpp:97
Definition: TPSALinearSolverParameters.hpp:44
Definition: TPSALinearSolverParameters.hpp:36
void reset()
Reset TPSA linear solver parameters.
Definition: TPSALinearSolverParameters.cpp:93
Definition: TPSALinearSolverParameters.hpp:37
void init()
Internalize runtime parameters.
Definition: TPSALinearSolverParameters.cpp:37
Definition: TPSALinearSolverParameters.hpp:43
static void registerParameters()
Register TPSA linear solver runtime parameters.
Definition: TPSALinearSolverParameters.cpp:59