[1D] Only reset Jacobian age after successful *steady-state* solve

This commit is contained in:
Ray Speth 2015-12-11 11:36:00 -05:00
parent f0a1e25cd9
commit 39a6819bf3

View file

@ -349,7 +349,9 @@ int MultiNewton::solve(doublereal* x0, doublereal* x1,
copy(x1, x1 + m_n, m_x.begin());
} else if (m == 1) {
// convergence
jac.setAge(0); // for efficient sensitivity analysis
if (rdt == 0) {
jac.setAge(0); // for efficient sensitivity analysis
}
break;
} else if (m < 0) {
// If dampStep fails, first try a new Jacobian if an old one was