Skip to content
Snippets Groups Projects
Commit 5afeea1d authored by Elias Pipping's avatar Elias Pipping
Browse files

[Algorit] Do away with an unnecessary cutoff

parent 23dba2ff
No related branches found
No related tags found
No related merge requests found
......@@ -39,11 +39,11 @@ void minimise(Functional const &J, typename Functional::SmallVector &x,
for (size_t step = 0; step < steps; ++step) {
SmallVector v;
J.gradient(x, v);
v *= -1;
if (v.two_norm() < 1e-14) // TODO: Make controllable
if (v.two_norm() == 0.0)
return;
v *= -1;
descentMinimisation(J, x, v, bisection);
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment