renamed BracketedSolution into BracketedUnivariateRealSolver and make it extend UnivariateRealSolver.
This will allow specifying directly a sub-category of solvers when needed. It will be used for example by the ODE events detection mechanism, as it will ensure the integrator can automatically go past the event time. JIRA: MATH-605 git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1141920 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
77af8e9585
commit
4500105e12
|
@ -162,8 +162,8 @@ public abstract class BaseSecantSolverAbstractTest {
|
|||
public void testSolutionLeftSide() {
|
||||
UnivariateRealFunction f = new SinFunction();
|
||||
UnivariateRealSolver solver = getSolver();
|
||||
if (!(solver instanceof BracketedSolution)) return;
|
||||
((BracketedSolution)solver).setAllowedSolutions(AllowedSolutions.LEFT_SIDE);
|
||||
if (!(solver instanceof BracketedUnivariateRealSolver)) return;
|
||||
((BracketedUnivariateRealSolver)solver).setAllowedSolutions(AllowedSolutions.LEFT_SIDE);
|
||||
double left = -1.5;
|
||||
double right = 0.05;
|
||||
for(int i = 0; i < 10; i++) {
|
||||
|
@ -181,8 +181,8 @@ public abstract class BaseSecantSolverAbstractTest {
|
|||
public void testSolutionRightSide() {
|
||||
UnivariateRealFunction f = new SinFunction();
|
||||
UnivariateRealSolver solver = getSolver();
|
||||
if (!(solver instanceof BracketedSolution)) return;
|
||||
((BracketedSolution)solver).setAllowedSolutions(AllowedSolutions.RIGHT_SIDE);
|
||||
if (!(solver instanceof BracketedUnivariateRealSolver)) return;
|
||||
((BracketedUnivariateRealSolver)solver).setAllowedSolutions(AllowedSolutions.RIGHT_SIDE);
|
||||
double left = -1.5;
|
||||
double right = 0.05;
|
||||
for(int i = 0; i < 10; i++) {
|
||||
|
|
Loading…
Reference in New Issue