Use the new nth order bracketing Brent solver by default if user didn't specify a root solver for ODE events detection.

git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1152283 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Luc Maisonobe 2011-07-29 15:50:39 +00:00
parent fe650d7b39
commit 9679d37e09
1 changed files with 3 additions and 2 deletions

View File

@ -28,7 +28,7 @@ import java.util.TreeSet;
import org.apache.commons.math.ConvergenceException;
import org.apache.commons.math.MaxEvaluationsExceededException;
import org.apache.commons.math.analysis.solvers.BrentSolver;
import org.apache.commons.math.analysis.solvers.BracketingNthOrderBrentSolver;
import org.apache.commons.math.analysis.solvers.UnivariateRealSolver;
import org.apache.commons.math.exception.MathUserException;
import org.apache.commons.math.exception.util.LocalizedFormats;
@ -126,7 +126,8 @@ public abstract class AbstractIntegrator implements FirstOrderIntegrator {
final double convergence,
final int maxIterationCount) {
addEventHandler(handler, maxCheckInterval, convergence,
maxIterationCount, new BrentSolver(convergence));
maxIterationCount,
new BracketingNthOrderBrentSolver(convergence, 5));
}
/** {@inheritDoc} */