21 std::string
const& prefix,
35 "OGS was compiled with Eigen but the config section in the "
36 "project file seems to be invalid");
41 if (
auto solver_type =
43 config->getConfigParameterOptional<std::string>(
"solver_type"))
47 if (
auto precon_type =
49 config->getConfigParameterOptional<std::string>(
"precon_type"))
53 if (
auto error_tolerance =
55 config->getConfigParameterOptional<
double>(
"error_tolerance"))
59 if (
auto max_iteration_step =
61 config->getConfigParameterOptional<
int>(
"max_iteration_step"))
65 if (
auto triangular_matrix_type =
67 config->getConfigParameterOptional<std::string>(
"triangular_matrix"))
71 *triangular_matrix_type);
75 config->getConfigParameterOptional<
bool>(
"scaling"))
77#ifdef USE_EIGEN_UNSUPPORTED
78 options.scaling = *scaling;
81 "The code is not compiled with the Eigen unsupported modules. "
82 "scaling is not available.");
87 config->getConfigParameterOptional<
int>(
"restart"))
89#ifdef USE_EIGEN_UNSUPPORTED
90 options.restart = *restart;
93 "The code is not compiled with the Eigen unsupported modules. "
94 "GMRES/GMRES option restart is not available.");
99 config->getConfigParameterOptional<
int>(
"l"))
101#ifdef USE_EIGEN_UNSUPPORTED
105 "The code is not compiled with the Eigen unsupported modules.");
110 config->getConfigParameterOptional<
int>(
"s"))
112#ifdef USE_EIGEN_UNSUPPORTED
116 "The code is not compiled with the Eigen unsupported modules.");
121 config->getConfigParameterOptional<
int>(
"smoothing"))
123#ifdef USE_EIGEN_UNSUPPORTED
124 options.smoothing = *smoothing;
127 "The code is not compiled with the Eigen unsupported modules.");
132 config->getConfigParameterOptional<
int>(
"angle"))
134#ifdef USE_EIGEN_UNSUPPORTED
135 options.angle = *angle;
138 "The code is not compiled with the Eigen unsupported modules.");
141 if (
auto residualupdate =
143 config->getConfigParameterOptional<
int>(
"residual_update"))
145#ifdef USE_EIGEN_UNSUPPORTED
146 options.residualupdate = *residualupdate;
149 "The code is not compiled with the Eigen unsupported modules.");
152 return {prefix, options};