diff --git a/opm/autodiff/WellStateFullyImplicitBlackoil.hpp b/opm/autodiff/WellStateFullyImplicitBlackoil.hpp index 84a54ebff..b34587f01 100644 --- a/opm/autodiff/WellStateFullyImplicitBlackoil.hpp +++ b/opm/autodiff/WellStateFullyImplicitBlackoil.hpp @@ -161,7 +161,12 @@ namespace Opm } // currentControls - const int old_control_index = prevState.currentControls()[ oldIndex ]; + // TODO: copying the control index from the previous state can provide better guess of the inital control + // while it can cause problem when the combination of the controls/constraints change. In that situation, coying + // the control index means specifying a rather random control. The VFP table provides some damaging values for + // situatioin not desirable, entering with a random control will possibly crash the whole simulation. Restarting with smaller + // time step might not help. + /* const int old_control_index = prevState.currentControls()[ oldIndex ]; if (old_control_index < well_controls_get_num(wells->ctrls[w])) { // If the set of controls have changed, this may not be identical // to the last control, but it must be a valid control. @@ -169,7 +174,7 @@ namespace Opm } else { assert(well_controls_get_num(wells->ctrls[w]) > 0); currentControls()[ newIndex ] = 0; - } + } */ }