mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-01-04 13:36:57 -06:00
specify the number of iterations where we use a "strict" Newton convergence criterion using a separate parameter
that parameter is called "max_strict_iter". This increases the flexibility of this slightly and it avoids screwing up the default value for the "max_iter" parameter in the future. The credits for this patch go to [at]atgeirr for proposing it.
This commit is contained in:
parent
0304183361
commit
e3d0bbc144
@ -979,7 +979,7 @@ namespace Opm {
|
||||
|
||||
// do not care about the cell based residual in the last two Newton
|
||||
// iterations
|
||||
if (iteration < param_.max_iter_ - 2)
|
||||
if (iteration < param_.max_strict_iter_)
|
||||
converged = converged && converged_CNV;
|
||||
|
||||
if ( terminal_output_ )
|
||||
|
@ -52,7 +52,7 @@ namespace Opm
|
||||
tolerance_well_control_ = param.getDefault("tolerance_well_control", tolerance_well_control_);
|
||||
maxSinglePrecisionTimeStep_ = unit::convert::from(
|
||||
param.getDefault("max_single_precision_days", unit::convert::to( maxSinglePrecisionTimeStep_, unit::day) ), unit::day );
|
||||
max_iter_ = param.getDefault("max_iter",10);
|
||||
max_strict_iter_ = param.getDefault("max_strict_iter",8);
|
||||
solve_welleq_initially_ = param.getDefault("solve_welleq_initially",solve_welleq_initially_);
|
||||
update_equations_scaling_ = param.getDefault("update_equations_scaling", update_equations_scaling_);
|
||||
use_update_stabilization_ = param.getDefault("use_update_stabilization", use_update_stabilization_);
|
||||
|
@ -56,8 +56,8 @@ namespace Opm
|
||||
/// for solving for the Jacobian
|
||||
double maxSinglePrecisionTimeStep_;
|
||||
|
||||
/// Maximum number of Newton iterations before we give up
|
||||
int max_iter_;
|
||||
/// Maximum number of Newton iterations before we give up on the CNV convergence criterion
|
||||
int max_strict_iter_;
|
||||
|
||||
/// Solve well equation initially
|
||||
bool solve_welleq_initially_;
|
||||
|
Loading…
Reference in New Issue
Block a user