mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-16 20:24:48 -06:00
Refine setting of (linear) solver_approach.
Ensure that the parameter is printed also if defaulted.
This commit is contained in:
parent
6fed5a50c3
commit
d8390590f8
@ -672,19 +672,16 @@ namespace Opm
|
||||
const std::string cprSolver = "cpr";
|
||||
const std::string interleavedSolver = "interleaved";
|
||||
const std::string directSolver = "direct";
|
||||
const std::string flowDefaultSolver = interleavedSolver;
|
||||
std::string flowDefaultSolver = interleavedSolver;
|
||||
|
||||
std::shared_ptr<const Opm::SimulationConfig> simCfg = eclipse_state_->getSimulationConfig();
|
||||
std::string solver_approach = flowDefaultSolver;
|
||||
|
||||
if (param_.has("solver_approach")) {
|
||||
solver_approach = param_.get<std::string>("solver_approach");
|
||||
} else {
|
||||
if (simCfg->useCPR()) {
|
||||
solver_approach = cprSolver;
|
||||
if (!param_.has("solver_approach")) {
|
||||
if (eclipse_state_->getSimulationConfig()->useCPR()) {
|
||||
flowDefaultSolver = cprSolver;
|
||||
}
|
||||
}
|
||||
|
||||
std::string solver_approach = param_.getDefault<std::string>("solver_approach", flowDefaultSolver);
|
||||
|
||||
if (solver_approach == cprSolver) {
|
||||
fis_solver_.reset(new NewtonIterationBlackoilCPR(param_, parallel_information_));
|
||||
} else if (solver_approach == interleavedSolver) {
|
||||
|
Loading…
Reference in New Issue
Block a user