commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From l..@apache.org
Subject [39/50] [abbrv] [math] Renamed interfaces for consistency with other classes.
Date Wed, 06 Jan 2016 13:50:55 GMT
Renamed interfaces for consistency with other classes.


Project: http://git-wip-us.apache.org/repos/asf/commons-math/repo
Commit: http://git-wip-us.apache.org/repos/asf/commons-math/commit/346a81d7
Tree: http://git-wip-us.apache.org/repos/asf/commons-math/tree/346a81d7
Diff: http://git-wip-us.apache.org/repos/asf/commons-math/diff/346a81d7

Branch: refs/heads/master
Commit: 346a81d770fcd5e7e401a8d1daa42acf6493c2f8
Parents: 0aa826e
Author: Luc Maisonobe <luc@apache.org>
Authored: Wed Jan 6 14:15:09 2016 +0100
Committer: Luc Maisonobe <luc@apache.org>
Committed: Wed Jan 6 14:15:09 2016 +0100

----------------------------------------------------------------------
 .../math4/ode/AbstractFieldIntegrator.java      |   2 +-
 .../commons/math4/ode/FieldExpandableODE.java   |   8 +-
 .../FieldFirstOrderDifferentialEquations.java   |  73 -------
 .../math4/ode/FieldFirstOrderIntegrator.java    | 188 -------------------
 .../apache/commons/math4/ode/FieldODEState.java |   4 +-
 .../math4/ode/FieldODEStateAndDerivative.java   |   4 +-
 .../math4/ode/FieldSecondaryEquations.java      |   4 +-
 .../FirstOrderFieldDifferentialEquations.java   |  73 +++++++
 .../math4/ode/FirstOrderFieldIntegrator.java    | 188 +++++++++++++++++++
 .../ode/nonstiff/RungeKuttaFieldIntegrator.java |   4 +-
 .../sampling/AbstractFieldStepInterpolator.java |   2 +-
 .../math4/ode/sampling/FieldStepHandler.java    |   2 +-
 .../ode/sampling/FieldStepInterpolator.java     |   2 +-
 src/site/xdoc/userguide/ode.xml                 |   4 +-
 .../ode/ContinuousOutputFieldModelTest.java     |  14 +-
 .../math4/ode/FieldExpandableODETest.java       |  20 +-
 .../math4/ode/TestFieldProblemAbstract.java     |   2 +-
 .../math4/ode/TestFieldProblemHandler.java      |   4 +-
 ...ctEmbeddedRungeKuttaFieldIntegratorTest.java |  20 +-
 .../AbstractRungeKuttaFieldIntegratorTest.java  |  10 +-
 ...ractRungeKuttaFieldStepInterpolatorTest.java |  10 +-
 .../math4/ode/nonstiff/StepFieldProblem.java    |   4 +-
 .../ode/sampling/StepInterpolatorTestUtils.java |   4 +-
 23 files changed, 323 insertions(+), 323 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/commons-math/blob/346a81d7/src/main/java/org/apache/commons/math4/ode/AbstractFieldIntegrator.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/commons/math4/ode/AbstractFieldIntegrator.java b/src/main/java/org/apache/commons/math4/ode/AbstractFieldIntegrator.java
index d741de5..41d7f15 100644
--- a/src/main/java/org/apache/commons/math4/ode/AbstractFieldIntegrator.java
+++ b/src/main/java/org/apache/commons/math4/ode/AbstractFieldIntegrator.java
@@ -47,7 +47,7 @@ import org.apache.commons.math4.util.IntegerSequence;
  * @param <T> the type of the field elements
  * @since 3.6
  */
-public abstract class AbstractFieldIntegrator<T extends RealFieldElement<T>> implements FieldFirstOrderIntegrator<T> {
+public abstract class AbstractFieldIntegrator<T extends RealFieldElement<T>> implements FirstOrderFieldIntegrator<T> {
 
     /** Default relative accuracy. */
     private static final double DEFAULT_RELATIVE_ACCURACY = 1e-14;

http://git-wip-us.apache.org/repos/asf/commons-math/blob/346a81d7/src/main/java/org/apache/commons/math4/ode/FieldExpandableODE.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/commons/math4/ode/FieldExpandableODE.java b/src/main/java/org/apache/commons/math4/ode/FieldExpandableODE.java
index 5e31a04..e5dd205 100644
--- a/src/main/java/org/apache/commons/math4/ode/FieldExpandableODE.java
+++ b/src/main/java/org/apache/commons/math4/ode/FieldExpandableODE.java
@@ -38,11 +38,11 @@ import org.apache.commons.math4.util.MathArrays;
  * <p>
  * We want the integrator to use <em>only</em> the primary set to estimate the
  * errors and hence the step sizes. It should <em>not</em> use the secondary
- * equations in this computation. The {@link FieldFirstOrderIntegrator integrator} will
+ * equations in this computation. The {@link FirstOrderFieldIntegrator integrator} will
  * be able to know where the primary set ends and so where the secondary sets begin.
  * </p>
  *
- * @see FieldFirstOrderDifferentialEquations
+ * @see FirstOrderFieldDifferentialEquations
  * @see FieldSecondaryEquations
  *
  * @param <T> the type of the field elements
@@ -52,7 +52,7 @@ import org.apache.commons.math4.util.MathArrays;
 public class FieldExpandableODE<T extends RealFieldElement<T>> {
 
     /** Primary differential equation. */
-    private final FieldFirstOrderDifferentialEquations<T> primary;
+    private final FirstOrderFieldDifferentialEquations<T> primary;
 
     /** Components of the expandable ODE. */
     private List<FieldSecondaryEquations<T>> components;
@@ -63,7 +63,7 @@ public class FieldExpandableODE<T extends RealFieldElement<T>> {
     /** Build an expandable set from its primary ODE set.
      * @param primary the primary set of differential equations to be integrated.
      */
-    public FieldExpandableODE(final FieldFirstOrderDifferentialEquations<T> primary) {
+    public FieldExpandableODE(final FirstOrderFieldDifferentialEquations<T> primary) {
         this.primary    = primary;
         this.components = new ArrayList<FieldSecondaryEquations<T>>();
         this.mapper     = new FieldEquationsMapper<T>(null, primary.getDimension());

http://git-wip-us.apache.org/repos/asf/commons-math/blob/346a81d7/src/main/java/org/apache/commons/math4/ode/FieldFirstOrderDifferentialEquations.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/commons/math4/ode/FieldFirstOrderDifferentialEquations.java b/src/main/java/org/apache/commons/math4/ode/FieldFirstOrderDifferentialEquations.java
deleted file mode 100644
index 05944fa..0000000
--- a/src/main/java/org/apache/commons/math4/ode/FieldFirstOrderDifferentialEquations.java
+++ /dev/null
@@ -1,73 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.commons.math4.ode;
-
-import org.apache.commons.math4.RealFieldElement;
-
-/** This interface represents a first order differential equations set.
- *
- * <p>This interface should be implemented by all real first order
- * differential equation problems before they can be handled by the
- * integrators {@link FirstOrderIntegrator#integrate} method.</p>
- *
- * <p>A first order differential equations problem, as seen by an
- * integrator is the time derivative <code>dY/dt</code> of a state
- * vector <code>Y</code>, both being one dimensional arrays. From the
- * integrator point of view, this derivative depends only on the
- * current time <code>t</code> and on the state vector
- * <code>Y</code>.</p>
- *
- * <p>For real problems, the derivative depends also on parameters
- * that do not belong to the state vector (dynamical model constants
- * for example). These constants are completely outside of the scope
- * of this interface, the classes that implement it are allowed to
- * handle them as they want.</p>
- *
- * @see FieldFirstOrderIntegrator
- *
- * @param <T> the type of the field elements
- * @since 3.6
- */
-
-public interface FieldFirstOrderDifferentialEquations<T extends RealFieldElement<T>> {
-
-    /** Get the dimension of the problem.
-     * @return dimension of the problem
-     */
-    int getDimension();
-
-    /** Initialize equations at the start of an ODE integration.
-     * <p>
-     * This method is called once at the start of the integration. It
-     * may be used by the equations to initialize some internal data
-     * if needed.
-     * </p>
-     * @param t0 value of the independent <I>time</I> variable at integration start
-     * @param y0 array containing the value of the state vector at integration start
-     * @param finalTime target time for the integration
-     */
-    void init(T t0, T[] y0, T finalTime);
-
-    /** Get the current time derivative of the state vector.
-     * @param t current value of the independent <I>time</I> variable
-     * @param y array containing the current value of the state vector
-     * @return time derivative of the state vector
-     */
-    T[] computeDerivatives(T t, T[] y);
-
-}

http://git-wip-us.apache.org/repos/asf/commons-math/blob/346a81d7/src/main/java/org/apache/commons/math4/ode/FieldFirstOrderIntegrator.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/commons/math4/ode/FieldFirstOrderIntegrator.java b/src/main/java/org/apache/commons/math4/ode/FieldFirstOrderIntegrator.java
deleted file mode 100644
index 981d22b..0000000
--- a/src/main/java/org/apache/commons/math4/ode/FieldFirstOrderIntegrator.java
+++ /dev/null
@@ -1,188 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.commons.math4.ode;
-
-import java.util.Collection;
-
-import org.apache.commons.math4.RealFieldElement;
-import org.apache.commons.math4.analysis.solvers.BracketedRealFieldUnivariateSolver;
-import org.apache.commons.math4.exception.MaxCountExceededException;
-import org.apache.commons.math4.exception.NoBracketingException;
-import org.apache.commons.math4.exception.NumberIsTooSmallException;
-import org.apache.commons.math4.ode.events.FieldEventHandler;
-import org.apache.commons.math4.ode.sampling.FieldStepHandler;
-
-/** This interface represents a first order integrator for
- * differential equations.
-
- * <p>The classes which are devoted to solve first order differential
- * equations should implement this interface. The problems which can
- * be handled should implement the {@link
- * FirstOrderDifferentialEquations} interface.</p>
- *
- * @see FieldFirstOrderDifferentialEquations
- * @param <T> the type of the field elements
- * @since 3.6
- */
-
-public interface FieldFirstOrderIntegrator<T extends RealFieldElement<T>> {
-
-    /** Get the name of the method.
-     * @return name of the method
-     */
-    String getName();
-
-    /** Add a step handler to this integrator.
-     * <p>The handler will be called by the integrator for each accepted
-     * step.</p>
-     * @param handler handler for the accepted steps
-     * @see #getStepHandlers()
-     * @see #clearStepHandlers()
-     */
-    void addStepHandler(FieldStepHandler<T> handler);
-
-    /** Get all the step handlers that have been added to the integrator.
-     * @return an unmodifiable collection of the added events handlers
-     * @see #addStepHandler(FieldStepHandler)
-     * @see #clearStepHandlers()
-     */
-    Collection<FieldStepHandler<T>> getStepHandlers();
-
-    /** Remove all the step handlers that have been added to the integrator.
-     * @see #addStepHandler(FieldStepHandler)
-     * @see #getStepHandlers()
-     */
-    void clearStepHandlers();
-
-    /** Add an event handler to the integrator.
-     * <p>
-     * The default solver is a 5<sup>th</sup> order {@link
-     * org.apache.commons.math4.analysis.solvers.FieldBracketingNthOrderBrentSolver}.
-     * </p>
-     * @param handler event handler
-     * @param maxCheckInterval maximal time interval between switching
-     * function checks (this interval prevents missing sign changes in
-     * case the integration steps becomes very large)
-     * @param convergence convergence threshold in the event time search
-     * @param maxIterationCount upper limit of the iteration count in
-     * the event time search events.
-     * @see #addEventHandler(FieldEventHandler, double, double, int,
-     * org.apache.commons.math4.analysis.solvers.BracketedRealFieldUnivariateSolver)
-     * @see #getEventHandlers()
-     * @see #clearEventHandlers()
-     */
-    void addEventHandler(FieldEventHandler<T>  handler, double maxCheckInterval,
-                         double convergence, int maxIterationCount);
-
-    /** Add an event handler to the integrator.
-     * @param handler event handler
-     * @param maxCheckInterval maximal time interval between switching
-     * function checks (this interval prevents missing sign changes in
-     * case the integration steps becomes very large)
-     * @param convergence convergence threshold in the event time search
-     * @param maxIterationCount upper limit of the iteration count in
-     * the event time search events.
-     * @param solver solver to use to locate the event
-     * @see #addEventHandler(FieldEventHandler, double, double, int)
-     * @see #getEventHandlers()
-     * @see #clearEventHandlers()
-     */
-    void addEventHandler(FieldEventHandler<T>  handler, double maxCheckInterval,
-                         double convergence, int maxIterationCount,
-                         BracketedRealFieldUnivariateSolver<T> solver);
-
-    /** Get all the event handlers that have been added to the integrator.
-     * @return an unmodifiable collection of the added events handlers
-     * @see #addEventHandler(FieldEventHandler, double, double, int)
-     * @see #clearEventHandlers()
-     */
-    Collection<FieldEventHandler<T> > getEventHandlers();
-
-    /** Remove all the event handlers that have been added to the integrator.
-     * @see #addEventHandler(FieldEventHandler, double, double, int)
-     * @see #getEventHandlers()
-     */
-    void clearEventHandlers();
-
-    /** Get the current value of the step start time t<sub>i</sub>.
-     * <p>This method can be called during integration (typically by
-     * the object implementing the {@link FirstOrderDifferentialEquations
-     * differential equations} problem) if the value of the current step that
-     * is attempted is needed.</p>
-     * <p>The result is undefined if the method is called outside of
-     * calls to <code>integrate</code>.</p>
-     * @return current value of the state at step start time t<sub>i</sub>
-     */
-    FieldODEStateAndDerivative<T> getCurrentStepStart();
-
-    /** Get the current signed value of the integration stepsize.
-     * <p>This method can be called during integration (typically by
-     * the object implementing the {@link FirstOrderDifferentialEquations
-     * differential equations} problem) if the signed value of the current stepsize
-     * that is tried is needed.</p>
-     * <p>The result is undefined if the method is called outside of
-     * calls to <code>integrate</code>.</p>
-     * @return current signed value of the stepsize
-     */
-    T getCurrentSignedStepsize();
-
-    /** Set the maximal number of differential equations function evaluations.
-     * <p>The purpose of this method is to avoid infinite loops which can occur
-     * for example when stringent error constraints are set or when lots of
-     * discrete events are triggered, thus leading to many rejected steps.</p>
-     * @param maxEvaluations maximal number of function evaluations (negative
-     * values are silently converted to maximal integer value, thus representing
-     * almost unlimited evaluations)
-     */
-    void setMaxEvaluations(int maxEvaluations);
-
-    /** Get the maximal number of functions evaluations.
-     * @return maximal number of functions evaluations
-     */
-    int getMaxEvaluations();
-
-    /** Get the number of evaluations of the differential equations function.
-     * <p>
-     * The number of evaluations corresponds to the last call to the
-     * <code>integrate</code> method. It is 0 if the method has not been called yet.
-     * </p>
-     * @return number of evaluations of the differential equations function
-     */
-    int getEvaluations();
-
-    /** Integrate the differential equations up to the given time.
-     * <p>This method solves an Initial Value Problem (IVP).</p>
-     * <p>Since this method stores some internal state variables made
-     * available in its public interface during integration ({@link
-     * #getCurrentSignedStepsize()}), it is <em>not</em> thread-safe.</p>
-     * @param equations differential equations to integrate
-     * @param initialState initial state (time, primary and secondary state vectors)
-     * @param finalTime target time for the integration
-     * (can be set to a value smaller than {@code t0} for backward integration)
-     * @return final state, its time will be the same as {@code finalTime} if
-     * integration reached its target, but may be different if some {@link
-     * org.apache.commons.math4.ode.events.FieldEventHandler} stops it at some point.
-     * @exception NumberIsTooSmallException if integration step is too small
-     * @exception MaxCountExceededException if the number of functions evaluations is exceeded
-     * @exception NoBracketingException if the location of an event cannot be bracketed
-     */
-    FieldODEStateAndDerivative<T> integrate(FieldExpandableODE<T> equations,
-                                            FieldODEState<T> initialState, T finalTime)
-        throws NumberIsTooSmallException, MaxCountExceededException, NoBracketingException;
-
-}

http://git-wip-us.apache.org/repos/asf/commons-math/blob/346a81d7/src/main/java/org/apache/commons/math4/ode/FieldODEState.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/commons/math4/ode/FieldODEState.java b/src/main/java/org/apache/commons/math4/ode/FieldODEState.java
index a0d0342..ae3566e 100644
--- a/src/main/java/org/apache/commons/math4/ode/FieldODEState.java
+++ b/src/main/java/org/apache/commons/math4/ode/FieldODEState.java
@@ -23,9 +23,9 @@ import org.apache.commons.math4.util.MathArrays;
 
 /** Container for time, main and secondary state vectors.
 
- * @see FieldFirstOrderDifferentialEquations
+ * @see FirstOrderFieldDifferentialEquations
  * @see FieldSecondaryEquations
- * @see FieldFirstOrderIntegrator
+ * @see FirstOrderFieldIntegrator
  * @see FieldODEStateAndDerivative
  * @param <T> the type of the field elements
  * @since 3.6

http://git-wip-us.apache.org/repos/asf/commons-math/blob/346a81d7/src/main/java/org/apache/commons/math4/ode/FieldODEStateAndDerivative.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/commons/math4/ode/FieldODEStateAndDerivative.java b/src/main/java/org/apache/commons/math4/ode/FieldODEStateAndDerivative.java
index a10b544..7851bd5 100644
--- a/src/main/java/org/apache/commons/math4/ode/FieldODEStateAndDerivative.java
+++ b/src/main/java/org/apache/commons/math4/ode/FieldODEStateAndDerivative.java
@@ -21,9 +21,9 @@ import org.apache.commons.math4.RealFieldElement;
 
 /** Container for time, main and secondary state vectors as well as their derivatives.
 
- * @see FieldFirstOrderDifferentialEquations
+ * @see FirstOrderFieldDifferentialEquations
  * @see FieldSecondaryEquations
- * @see FieldFirstOrderIntegrator
+ * @see FirstOrderFieldIntegrator
  * @param <T> the type of the field elements
  * @since 3.6
  */

http://git-wip-us.apache.org/repos/asf/commons-math/blob/346a81d7/src/main/java/org/apache/commons/math4/ode/FieldSecondaryEquations.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/commons/math4/ode/FieldSecondaryEquations.java b/src/main/java/org/apache/commons/math4/ode/FieldSecondaryEquations.java
index 6bce859..c5f10b4 100644
--- a/src/main/java/org/apache/commons/math4/ode/FieldSecondaryEquations.java
+++ b/src/main/java/org/apache/commons/math4/ode/FieldSecondaryEquations.java
@@ -31,11 +31,11 @@ import org.apache.commons.math4.exception.MaxCountExceededException;
  * </p>
  * <p>
  * This interface allows users to add such equations to a primary set of {@link
- * FieldFirstOrderDifferentialEquations first order differential equations}
+ * FirstOrderFieldDifferentialEquations first order differential equations}
  * thanks to the {@link FieldExpandableODE#addSecondaryEquations(FieldSecondaryEquations)}
  * method.
  * </p>
- * @see FieldFirstOrderDifferentialEquations
+ * @see FirstOrderFieldDifferentialEquations
  * @see FieldExpandableODE
  * @param <T> the type of the field elements
  * @since 3.6

http://git-wip-us.apache.org/repos/asf/commons-math/blob/346a81d7/src/main/java/org/apache/commons/math4/ode/FirstOrderFieldDifferentialEquations.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/commons/math4/ode/FirstOrderFieldDifferentialEquations.java b/src/main/java/org/apache/commons/math4/ode/FirstOrderFieldDifferentialEquations.java
new file mode 100644
index 0000000..288e581
--- /dev/null
+++ b/src/main/java/org/apache/commons/math4/ode/FirstOrderFieldDifferentialEquations.java
@@ -0,0 +1,73 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.commons.math4.ode;
+
+import org.apache.commons.math4.RealFieldElement;
+
+/** This interface represents a first order differential equations set.
+ *
+ * <p>This interface should be implemented by all real first order
+ * differential equation problems before they can be handled by the
+ * integrators {@link FirstOrderIntegrator#integrate} method.</p>
+ *
+ * <p>A first order differential equations problem, as seen by an
+ * integrator is the time derivative <code>dY/dt</code> of a state
+ * vector <code>Y</code>, both being one dimensional arrays. From the
+ * integrator point of view, this derivative depends only on the
+ * current time <code>t</code> and on the state vector
+ * <code>Y</code>.</p>
+ *
+ * <p>For real problems, the derivative depends also on parameters
+ * that do not belong to the state vector (dynamical model constants
+ * for example). These constants are completely outside of the scope
+ * of this interface, the classes that implement it are allowed to
+ * handle them as they want.</p>
+ *
+ * @see FirstOrderFieldIntegrator
+ *
+ * @param <T> the type of the field elements
+ * @since 3.6
+ */
+
+public interface FirstOrderFieldDifferentialEquations<T extends RealFieldElement<T>> {
+
+    /** Get the dimension of the problem.
+     * @return dimension of the problem
+     */
+    int getDimension();
+
+    /** Initialize equations at the start of an ODE integration.
+     * <p>
+     * This method is called once at the start of the integration. It
+     * may be used by the equations to initialize some internal data
+     * if needed.
+     * </p>
+     * @param t0 value of the independent <I>time</I> variable at integration start
+     * @param y0 array containing the value of the state vector at integration start
+     * @param finalTime target time for the integration
+     */
+    void init(T t0, T[] y0, T finalTime);
+
+    /** Get the current time derivative of the state vector.
+     * @param t current value of the independent <I>time</I> variable
+     * @param y array containing the current value of the state vector
+     * @return time derivative of the state vector
+     */
+    T[] computeDerivatives(T t, T[] y);
+
+}

http://git-wip-us.apache.org/repos/asf/commons-math/blob/346a81d7/src/main/java/org/apache/commons/math4/ode/FirstOrderFieldIntegrator.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/commons/math4/ode/FirstOrderFieldIntegrator.java b/src/main/java/org/apache/commons/math4/ode/FirstOrderFieldIntegrator.java
new file mode 100644
index 0000000..2ebd9b9
--- /dev/null
+++ b/src/main/java/org/apache/commons/math4/ode/FirstOrderFieldIntegrator.java
@@ -0,0 +1,188 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.commons.math4.ode;
+
+import java.util.Collection;
+
+import org.apache.commons.math4.RealFieldElement;
+import org.apache.commons.math4.analysis.solvers.BracketedRealFieldUnivariateSolver;
+import org.apache.commons.math4.exception.MaxCountExceededException;
+import org.apache.commons.math4.exception.NoBracketingException;
+import org.apache.commons.math4.exception.NumberIsTooSmallException;
+import org.apache.commons.math4.ode.events.FieldEventHandler;
+import org.apache.commons.math4.ode.sampling.FieldStepHandler;
+
+/** This interface represents a first order integrator for
+ * differential equations.
+
+ * <p>The classes which are devoted to solve first order differential
+ * equations should implement this interface. The problems which can
+ * be handled should implement the {@link
+ * FirstOrderDifferentialEquations} interface.</p>
+ *
+ * @see FirstOrderFieldDifferentialEquations
+ * @param <T> the type of the field elements
+ * @since 3.6
+ */
+
+public interface FirstOrderFieldIntegrator<T extends RealFieldElement<T>> {
+
+    /** Get the name of the method.
+     * @return name of the method
+     */
+    String getName();
+
+    /** Add a step handler to this integrator.
+     * <p>The handler will be called by the integrator for each accepted
+     * step.</p>
+     * @param handler handler for the accepted steps
+     * @see #getStepHandlers()
+     * @see #clearStepHandlers()
+     */
+    void addStepHandler(FieldStepHandler<T> handler);
+
+    /** Get all the step handlers that have been added to the integrator.
+     * @return an unmodifiable collection of the added events handlers
+     * @see #addStepHandler(FieldStepHandler)
+     * @see #clearStepHandlers()
+     */
+    Collection<FieldStepHandler<T>> getStepHandlers();
+
+    /** Remove all the step handlers that have been added to the integrator.
+     * @see #addStepHandler(FieldStepHandler)
+     * @see #getStepHandlers()
+     */
+    void clearStepHandlers();
+
+    /** Add an event handler to the integrator.
+     * <p>
+     * The default solver is a 5<sup>th</sup> order {@link
+     * org.apache.commons.math4.analysis.solvers.FieldBracketingNthOrderBrentSolver}.
+     * </p>
+     * @param handler event handler
+     * @param maxCheckInterval maximal time interval between switching
+     * function checks (this interval prevents missing sign changes in
+     * case the integration steps becomes very large)
+     * @param convergence convergence threshold in the event time search
+     * @param maxIterationCount upper limit of the iteration count in
+     * the event time search events.
+     * @see #addEventHandler(FieldEventHandler, double, double, int,
+     * org.apache.commons.math4.analysis.solvers.BracketedRealFieldUnivariateSolver)
+     * @see #getEventHandlers()
+     * @see #clearEventHandlers()
+     */
+    void addEventHandler(FieldEventHandler<T>  handler, double maxCheckInterval,
+                         double convergence, int maxIterationCount);
+
+    /** Add an event handler to the integrator.
+     * @param handler event handler
+     * @param maxCheckInterval maximal time interval between switching
+     * function checks (this interval prevents missing sign changes in
+     * case the integration steps becomes very large)
+     * @param convergence convergence threshold in the event time search
+     * @param maxIterationCount upper limit of the iteration count in
+     * the event time search events.
+     * @param solver solver to use to locate the event
+     * @see #addEventHandler(FieldEventHandler, double, double, int)
+     * @see #getEventHandlers()
+     * @see #clearEventHandlers()
+     */
+    void addEventHandler(FieldEventHandler<T>  handler, double maxCheckInterval,
+                         double convergence, int maxIterationCount,
+                         BracketedRealFieldUnivariateSolver<T> solver);
+
+    /** Get all the event handlers that have been added to the integrator.
+     * @return an unmodifiable collection of the added events handlers
+     * @see #addEventHandler(FieldEventHandler, double, double, int)
+     * @see #clearEventHandlers()
+     */
+    Collection<FieldEventHandler<T> > getEventHandlers();
+
+    /** Remove all the event handlers that have been added to the integrator.
+     * @see #addEventHandler(FieldEventHandler, double, double, int)
+     * @see #getEventHandlers()
+     */
+    void clearEventHandlers();
+
+    /** Get the current value of the step start time t<sub>i</sub>.
+     * <p>This method can be called during integration (typically by
+     * the object implementing the {@link FirstOrderDifferentialEquations
+     * differential equations} problem) if the value of the current step that
+     * is attempted is needed.</p>
+     * <p>The result is undefined if the method is called outside of
+     * calls to <code>integrate</code>.</p>
+     * @return current value of the state at step start time t<sub>i</sub>
+     */
+    FieldODEStateAndDerivative<T> getCurrentStepStart();
+
+    /** Get the current signed value of the integration stepsize.
+     * <p>This method can be called during integration (typically by
+     * the object implementing the {@link FirstOrderDifferentialEquations
+     * differential equations} problem) if the signed value of the current stepsize
+     * that is tried is needed.</p>
+     * <p>The result is undefined if the method is called outside of
+     * calls to <code>integrate</code>.</p>
+     * @return current signed value of the stepsize
+     */
+    T getCurrentSignedStepsize();
+
+    /** Set the maximal number of differential equations function evaluations.
+     * <p>The purpose of this method is to avoid infinite loops which can occur
+     * for example when stringent error constraints are set or when lots of
+     * discrete events are triggered, thus leading to many rejected steps.</p>
+     * @param maxEvaluations maximal number of function evaluations (negative
+     * values are silently converted to maximal integer value, thus representing
+     * almost unlimited evaluations)
+     */
+    void setMaxEvaluations(int maxEvaluations);
+
+    /** Get the maximal number of functions evaluations.
+     * @return maximal number of functions evaluations
+     */
+    int getMaxEvaluations();
+
+    /** Get the number of evaluations of the differential equations function.
+     * <p>
+     * The number of evaluations corresponds to the last call to the
+     * <code>integrate</code> method. It is 0 if the method has not been called yet.
+     * </p>
+     * @return number of evaluations of the differential equations function
+     */
+    int getEvaluations();
+
+    /** Integrate the differential equations up to the given time.
+     * <p>This method solves an Initial Value Problem (IVP).</p>
+     * <p>Since this method stores some internal state variables made
+     * available in its public interface during integration ({@link
+     * #getCurrentSignedStepsize()}), it is <em>not</em> thread-safe.</p>
+     * @param equations differential equations to integrate
+     * @param initialState initial state (time, primary and secondary state vectors)
+     * @param finalTime target time for the integration
+     * (can be set to a value smaller than {@code t0} for backward integration)
+     * @return final state, its time will be the same as {@code finalTime} if
+     * integration reached its target, but may be different if some {@link
+     * org.apache.commons.math4.ode.events.FieldEventHandler} stops it at some point.
+     * @exception NumberIsTooSmallException if integration step is too small
+     * @exception MaxCountExceededException if the number of functions evaluations is exceeded
+     * @exception NoBracketingException if the location of an event cannot be bracketed
+     */
+    FieldODEStateAndDerivative<T> integrate(FieldExpandableODE<T> equations,
+                                            FieldODEState<T> initialState, T finalTime)
+        throws NumberIsTooSmallException, MaxCountExceededException, NoBracketingException;
+
+}

http://git-wip-us.apache.org/repos/asf/commons-math/blob/346a81d7/src/main/java/org/apache/commons/math4/ode/nonstiff/RungeKuttaFieldIntegrator.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/commons/math4/ode/nonstiff/RungeKuttaFieldIntegrator.java b/src/main/java/org/apache/commons/math4/ode/nonstiff/RungeKuttaFieldIntegrator.java
index d052f4b..45ad237 100644
--- a/src/main/java/org/apache/commons/math4/ode/nonstiff/RungeKuttaFieldIntegrator.java
+++ b/src/main/java/org/apache/commons/math4/ode/nonstiff/RungeKuttaFieldIntegrator.java
@@ -27,7 +27,7 @@ import org.apache.commons.math4.exception.NumberIsTooSmallException;
 import org.apache.commons.math4.ode.AbstractFieldIntegrator;
 import org.apache.commons.math4.ode.FieldEquationsMapper;
 import org.apache.commons.math4.ode.FieldExpandableODE;
-import org.apache.commons.math4.ode.FieldFirstOrderDifferentialEquations;
+import org.apache.commons.math4.ode.FirstOrderFieldDifferentialEquations;
 import org.apache.commons.math4.ode.FieldODEState;
 import org.apache.commons.math4.ode.FieldODEStateAndDerivative;
 import org.apache.commons.math4.util.MathArrays;
@@ -230,7 +230,7 @@ public abstract class RungeKuttaFieldIntegrator<T extends RealFieldElement<T>>
      * (can be set to a value smaller than {@code t0} for backward integration)
      * @return state vector at {@code t}
      */
-    public T[] singleStep(final FieldFirstOrderDifferentialEquations<T> equations,
+    public T[] singleStep(final FirstOrderFieldDifferentialEquations<T> equations,
                           final T t0, final T[] y0, final T t) {
 
         // create some internal working arrays

http://git-wip-us.apache.org/repos/asf/commons-math/blob/346a81d7/src/main/java/org/apache/commons/math4/ode/sampling/AbstractFieldStepInterpolator.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/commons/math4/ode/sampling/AbstractFieldStepInterpolator.java b/src/main/java/org/apache/commons/math4/ode/sampling/AbstractFieldStepInterpolator.java
index b9a5de2..4385336 100644
--- a/src/main/java/org/apache/commons/math4/ode/sampling/AbstractFieldStepInterpolator.java
+++ b/src/main/java/org/apache/commons/math4/ode/sampling/AbstractFieldStepInterpolator.java
@@ -30,7 +30,7 @@ import org.apache.commons.math4.ode.FieldODEStateAndDerivative;
  * retrieve the state vector at intermediate times between the
  * previous and the current grid points (dense output).</p>
  *
- * @see org.apache.commons.math4.ode.FieldFirstOrderIntegrator
+ * @see org.apache.commons.math4.ode.FirstOrderFieldIntegrator
  * @see StepHandler
  *
  * @param <T> the type of the field elements

http://git-wip-us.apache.org/repos/asf/commons-math/blob/346a81d7/src/main/java/org/apache/commons/math4/ode/sampling/FieldStepHandler.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/commons/math4/ode/sampling/FieldStepHandler.java b/src/main/java/org/apache/commons/math4/ode/sampling/FieldStepHandler.java
index 4a1e3c9..77b7ddd 100644
--- a/src/main/java/org/apache/commons/math4/ode/sampling/FieldStepHandler.java
+++ b/src/main/java/org/apache/commons/math4/ode/sampling/FieldStepHandler.java
@@ -34,7 +34,7 @@ import org.apache.commons.math4.ode.FieldODEStateAndDerivative;
  * last one, store the points in an ephemeris, or forward them to
  * specialized processing or output methods.</p>
  *
- * @see org.apache.commons.math4.ode.FieldFirstOrderIntegrator
+ * @see org.apache.commons.math4.ode.FirstOrderFieldIntegrator
  * @see FieldStepInterpolator
  * @param <T> the type of the field elements
  * @since 3.6

http://git-wip-us.apache.org/repos/asf/commons-math/blob/346a81d7/src/main/java/org/apache/commons/math4/ode/sampling/FieldStepInterpolator.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/commons/math4/ode/sampling/FieldStepInterpolator.java b/src/main/java/org/apache/commons/math4/ode/sampling/FieldStepInterpolator.java
index a68d098..9a647e5 100644
--- a/src/main/java/org/apache/commons/math4/ode/sampling/FieldStepInterpolator.java
+++ b/src/main/java/org/apache/commons/math4/ode/sampling/FieldStepInterpolator.java
@@ -31,7 +31,7 @@ import org.apache.commons.math4.ode.FieldODEStateAndDerivative;
  * (this feature is often called dense output).</p>
  *
  * @param <T> the type of the field elements
- * @see org.apache.commons.math4.ode.FieldFirstOrderIntegrator
+ * @see org.apache.commons.math4.ode.FirstOrderFieldIntegrator
  * @see FieldStepHandler
  * @since 3.6
  */

http://git-wip-us.apache.org/repos/asf/commons-math/blob/346a81d7/src/site/xdoc/userguide/ode.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/userguide/ode.xml b/src/site/xdoc/userguide/ode.xml
index 3dc48bc..ffbebc6 100644
--- a/src/site/xdoc/userguide/ode.xml
+++ b/src/site/xdoc/userguide/ode.xml
@@ -85,10 +85,10 @@
         <p>
           The user should describe his problem in his own classes which should implement the
           <a href="../apidocs/org/apache/commons/math4/ode/FirstOrderDifferentialEquations.html">FirstOrderDifferentialEquations</a>
-          interface (or  <a href="../apidocs/org/apache/commons/math4/ode/FieldFirstOrderDifferentialEquations.html">FieldFirstOrderDifferentialEquations</a>
+          interface (or  <a href="../apidocs/org/apache/commons/math4/ode/FirstOrderFieldDifferentialEquations.html">FirstOrderFieldDifferentialEquations</a>
           interface). Then he should pass it to the integrator he prefers among all the classes that implement
           the <a href="../apidocs/org/apache/commons/math4/ode/FirstOrderIntegrator.html">FirstOrderIntegrator</a>
-          interface (or the <a href="../apidocs/org/apache/commons/math4/ode/FieldFirstOrderIntegrator.html">FieldFirstOrderIntegrator</a>
+          interface (or the <a href="../apidocs/org/apache/commons/math4/ode/FirstOrderFieldIntegrator.html">FirstOrderFieldIntegrator</a>
           interface). The following example shows how to implement the simple two-dimensional problem using double primitives:
           <ul>
             <li>y'<sub>0</sub>(t) = &#x3c9; &#xD7; (c<sub>1</sub> - y<sub>1</sub>(t))</li>

http://git-wip-us.apache.org/repos/asf/commons-math/blob/346a81d7/src/test/java/org/apache/commons/math4/ode/ContinuousOutputFieldModelTest.java
----------------------------------------------------------------------
diff --git a/src/test/java/org/apache/commons/math4/ode/ContinuousOutputFieldModelTest.java b/src/test/java/org/apache/commons/math4/ode/ContinuousOutputFieldModelTest.java
index fd87aba..870ee1e 100644
--- a/src/test/java/org/apache/commons/math4/ode/ContinuousOutputFieldModelTest.java
+++ b/src/test/java/org/apache/commons/math4/ode/ContinuousOutputFieldModelTest.java
@@ -45,7 +45,7 @@ public class ContinuousOutputFieldModelTest {
         TestFieldProblem3<T> pb = new TestFieldProblem3<T>(field, field.getZero().add(0.9));
         double minStep = 0;
         double maxStep = pb.getFinalTime().subtract(pb.getInitialState().getTime()).getReal();
-        FieldFirstOrderIntegrator<T> integ = new DormandPrince54FieldIntegrator<T>(field, minStep, maxStep, 1.0e-8, 1.0e-8);
+        FirstOrderFieldIntegrator<T> integ = new DormandPrince54FieldIntegrator<T>(field, minStep, maxStep, 1.0e-8, 1.0e-8);
         integ.addStepHandler(new ContinuousOutputFieldModel<T>());
         integ.integrate(new FieldExpandableODE<T>(pb), pb.getInitialState(), pb.getFinalTime());
         ContinuousOutputFieldModel<T> cm = (ContinuousOutputFieldModel<T>) integ.getStepHandlers().iterator().next();
@@ -64,7 +64,7 @@ public class ContinuousOutputFieldModelTest {
         TestFieldProblem3<T> pb = new TestFieldProblem3<T>(field, field.getZero().add(0.9));
         double minStep = 0;
         double maxStep = pb.getFinalTime().subtract(pb.getInitialState().getTime()).getReal();
-        FieldFirstOrderIntegrator<T> integ = new DormandPrince54FieldIntegrator<T>(field, minStep, maxStep, 1.0e-8, 1.0e-8);
+        FirstOrderFieldIntegrator<T> integ = new DormandPrince54FieldIntegrator<T>(field, minStep, maxStep, 1.0e-8, 1.0e-8);
         ContinuousOutputFieldModel<T> cm = new ContinuousOutputFieldModel<T>();
         integ.addStepHandler(cm);
         integ.integrate(new FieldExpandableODE<T>(pb), pb.getInitialState(), pb.getFinalTime());
@@ -101,8 +101,8 @@ public class ContinuousOutputFieldModelTest {
     private <T extends RealFieldElement<T>> void doTestModelsMerging(final Field<T> field) {
 
         // theoretical solution: y[0] = cos(t), y[1] = sin(t)
-        FieldFirstOrderDifferentialEquations<T> problem =
-                        new FieldFirstOrderDifferentialEquations<T>() {
+        FirstOrderFieldDifferentialEquations<T> problem =
+                        new FirstOrderFieldDifferentialEquations<T>() {
             public T[] computeDerivatives(T t, T[] y) {
                 T[] yDot = MathArrays.buildArray(field, 2);
                 yDot[0] = y[1].negate();
@@ -118,7 +118,7 @@ public class ContinuousOutputFieldModelTest {
 
         // integrate backward from &pi; to 0;
         ContinuousOutputFieldModel<T> cm1 = new ContinuousOutputFieldModel<T>();
-        FieldFirstOrderIntegrator<T> integ1 =
+        FirstOrderFieldIntegrator<T> integ1 =
                         new DormandPrince853FieldIntegrator<T>(field, 0, 1.0, 1.0e-8, 1.0e-8);
         integ1.addStepHandler(cm1);
         T t0 = field.getZero().add(FastMath.PI);
@@ -131,7 +131,7 @@ public class ContinuousOutputFieldModelTest {
 
         // integrate backward from 2&pi; to &pi;
         ContinuousOutputFieldModel<T> cm2 = new ContinuousOutputFieldModel<T>();
-        FieldFirstOrderIntegrator<T> integ2 =
+        FirstOrderFieldIntegrator<T> integ2 =
                         new DormandPrince853FieldIntegrator<T>(field, 0, 0.1, 1.0e-12, 1.0e-12);
         integ2.addStepHandler(cm2);
         t0 = field.getZero().add(2.0 * FastMath.PI);
@@ -203,7 +203,7 @@ public class ContinuousOutputFieldModelTest {
         }
         final FieldODEStateAndDerivative<T> s0 = new FieldODEStateAndDerivative<T>(field.getZero().add(t0), fieldY, fieldY);
         final FieldODEStateAndDerivative<T> s1 = new FieldODEStateAndDerivative<T>(field.getZero().add(t1), fieldY, fieldY);
-        final FieldEquationsMapper<T> mapper   = new FieldExpandableODE<T>(new FieldFirstOrderDifferentialEquations<T>() {
+        final FieldEquationsMapper<T> mapper   = new FieldExpandableODE<T>(new FirstOrderFieldDifferentialEquations<T>() {
             public int getDimension() {
                 return s0.getStateDimension();
             }

http://git-wip-us.apache.org/repos/asf/commons-math/blob/346a81d7/src/test/java/org/apache/commons/math4/ode/FieldExpandableODETest.java
----------------------------------------------------------------------
diff --git a/src/test/java/org/apache/commons/math4/ode/FieldExpandableODETest.java b/src/test/java/org/apache/commons/math4/ode/FieldExpandableODETest.java
index 8005274..79070d0 100644
--- a/src/test/java/org/apache/commons/math4/ode/FieldExpandableODETest.java
+++ b/src/test/java/org/apache/commons/math4/ode/FieldExpandableODETest.java
@@ -23,7 +23,7 @@ import org.apache.commons.math4.RealFieldElement;
 import org.apache.commons.math4.exception.DimensionMismatchException;
 import org.apache.commons.math4.exception.MathIllegalArgumentException;
 import org.apache.commons.math4.ode.FieldExpandableODE;
-import org.apache.commons.math4.ode.FieldFirstOrderDifferentialEquations;
+import org.apache.commons.math4.ode.FirstOrderFieldDifferentialEquations;
 import org.apache.commons.math4.ode.FieldODEStateAndDerivative;
 import org.apache.commons.math4.ode.FieldSecondaryEquations;
 import org.apache.commons.math4.util.Decimal64Field;
@@ -39,7 +39,7 @@ public class FieldExpandableODETest {
     }
 
     private <T extends RealFieldElement<T>> void doTestOnlyMainEquation(final Field<T> field) {
-        FieldFirstOrderDifferentialEquations<T> main = new Linear<T>(field, 3, 0);
+        FirstOrderFieldDifferentialEquations<T> main = new Linear<T>(field, 3, 0);
         FieldExpandableODE<T> equation = new FieldExpandableODE<T>(main);
         Assert.assertEquals(main.getDimension(), equation.getMapper().getTotalDimension());
         Assert.assertEquals(1, equation.getMapper().getNumberOfEquations());
@@ -70,7 +70,7 @@ public class FieldExpandableODETest {
 
     private <T extends RealFieldElement<T>> void doTestMainAndSecondary(final Field<T> field) {
 
-        FieldFirstOrderDifferentialEquations<T> main = new Linear<T>(field, 3, 0);
+        FirstOrderFieldDifferentialEquations<T> main = new Linear<T>(field, 3, 0);
         FieldExpandableODE<T> equation = new FieldExpandableODE<T>(main);
         FieldSecondaryEquations<T> secondary1 = new Linear<T>(field, 3, main.getDimension());
         int i1 = equation.addSecondaryEquations(secondary1);
@@ -127,7 +127,7 @@ public class FieldExpandableODETest {
 
     private <T extends RealFieldElement<T>> void doTestMap(final Field<T> field) {
 
-        FieldFirstOrderDifferentialEquations<T> main = new Linear<T>(field, 3, 0);
+        FirstOrderFieldDifferentialEquations<T> main = new Linear<T>(field, 3, 0);
         FieldExpandableODE<T> equation = new FieldExpandableODE<T>(main);
         FieldSecondaryEquations<T> secondary1 = new Linear<T>(field, 3, main.getDimension());
         int i1 = equation.addSecondaryEquations(secondary1);
@@ -215,7 +215,7 @@ public class FieldExpandableODETest {
     private <T extends RealFieldElement<T>> void doTestExtractDimensionMismatch(final Field<T> field)
         throws DimensionMismatchException {
 
-        FieldFirstOrderDifferentialEquations<T> main = new Linear<T>(field, 3, 0);
+        FirstOrderFieldDifferentialEquations<T> main = new Linear<T>(field, 3, 0);
         FieldExpandableODE<T> equation = new FieldExpandableODE<T>(main);
         FieldSecondaryEquations<T> secondary1 = new Linear<T>(field, 3, main.getDimension());
         int i1 = equation.addSecondaryEquations(secondary1);
@@ -231,7 +231,7 @@ public class FieldExpandableODETest {
     private <T extends RealFieldElement<T>> void doTestInsertTooShortComplete(final Field<T> field)
         throws DimensionMismatchException {
 
-        FieldFirstOrderDifferentialEquations<T> main = new Linear<T>(field, 3, 0);
+        FirstOrderFieldDifferentialEquations<T> main = new Linear<T>(field, 3, 0);
         FieldExpandableODE<T> equation = new FieldExpandableODE<T>(main);
         FieldSecondaryEquations<T> secondary1 = new Linear<T>(field, 3, main.getDimension());
         int i1 = equation.addSecondaryEquations(secondary1);
@@ -248,7 +248,7 @@ public class FieldExpandableODETest {
     private <T extends RealFieldElement<T>> void doTestInsertWrongEquationData(final Field<T> field)
         throws DimensionMismatchException {
 
-        FieldFirstOrderDifferentialEquations<T> main = new Linear<T>(field, 3, 0);
+        FirstOrderFieldDifferentialEquations<T> main = new Linear<T>(field, 3, 0);
         FieldExpandableODE<T> equation = new FieldExpandableODE<T>(main);
         FieldSecondaryEquations<T> secondary1 = new Linear<T>(field, 3, main.getDimension());
         int i1 = equation.addSecondaryEquations(secondary1);
@@ -265,7 +265,7 @@ public class FieldExpandableODETest {
     private <T extends RealFieldElement<T>> void doTestNegativeIndex(final Field<T> field)
         throws MathIllegalArgumentException {
 
-        FieldFirstOrderDifferentialEquations<T> main = new Linear<T>(field, 3, 0);
+        FirstOrderFieldDifferentialEquations<T> main = new Linear<T>(field, 3, 0);
         FieldExpandableODE<T> equation = new FieldExpandableODE<T>(main);
         T[] complete = MathArrays.buildArray(field, equation.getMapper().getTotalDimension());
         equation.getMapper().extractEquationData(-1, complete);
@@ -279,14 +279,14 @@ public class FieldExpandableODETest {
     private <T extends RealFieldElement<T>> void doTestTooLargeIndex(final Field<T> field)
         throws MathIllegalArgumentException {
 
-        FieldFirstOrderDifferentialEquations<T> main = new Linear<T>(field, 3, 0);
+        FirstOrderFieldDifferentialEquations<T> main = new Linear<T>(field, 3, 0);
         FieldExpandableODE<T> equation = new FieldExpandableODE<T>(main);
         T[] complete = MathArrays.buildArray(field, equation.getMapper().getTotalDimension());
         equation.getMapper().extractEquationData(+1, complete);
     }
 
     private static class  Linear<T extends RealFieldElement<T>>
-        implements  FieldFirstOrderDifferentialEquations<T>, FieldSecondaryEquations<T> {
+        implements  FirstOrderFieldDifferentialEquations<T>, FieldSecondaryEquations<T> {
 
         private final Field<T> field;
         private final int dimension;

http://git-wip-us.apache.org/repos/asf/commons-math/blob/346a81d7/src/test/java/org/apache/commons/math4/ode/TestFieldProblemAbstract.java
----------------------------------------------------------------------
diff --git a/src/test/java/org/apache/commons/math4/ode/TestFieldProblemAbstract.java b/src/test/java/org/apache/commons/math4/ode/TestFieldProblemAbstract.java
index bc2abfe..9d1b78b 100644
--- a/src/test/java/org/apache/commons/math4/ode/TestFieldProblemAbstract.java
+++ b/src/test/java/org/apache/commons/math4/ode/TestFieldProblemAbstract.java
@@ -30,7 +30,7 @@ import org.apache.commons.math4.util.MathArrays;
  * @param <T> the type of the field elements
  */
 public abstract class TestFieldProblemAbstract<T extends RealFieldElement<T>>
-    implements FieldFirstOrderDifferentialEquations<T> {
+    implements FirstOrderFieldDifferentialEquations<T> {
 
     /** Field to which elements belong. */
     private Field<T> field;

http://git-wip-us.apache.org/repos/asf/commons-math/blob/346a81d7/src/test/java/org/apache/commons/math4/ode/TestFieldProblemHandler.java
----------------------------------------------------------------------
diff --git a/src/test/java/org/apache/commons/math4/ode/TestFieldProblemHandler.java b/src/test/java/org/apache/commons/math4/ode/TestFieldProblemHandler.java
index 3cafb54..c298bf3 100644
--- a/src/test/java/org/apache/commons/math4/ode/TestFieldProblemHandler.java
+++ b/src/test/java/org/apache/commons/math4/ode/TestFieldProblemHandler.java
@@ -45,7 +45,7 @@ public class TestFieldProblemHandler<T extends RealFieldElement<T>>
     private T lastTime;
 
     /** ODE solver used. */
-    private FieldFirstOrderIntegrator<T> integrator;
+    private FirstOrderFieldIntegrator<T> integrator;
 
     /** Expected start for step. */
     private T expectedStepStart;
@@ -55,7 +55,7 @@ public class TestFieldProblemHandler<T extends RealFieldElement<T>>
      * @param problem problem for which steps should be handled
      * @param integrator ODE solver used
      */
-    public TestFieldProblemHandler(TestFieldProblemAbstract<T> problem, FieldFirstOrderIntegrator<T> integrator) {
+    public TestFieldProblemHandler(TestFieldProblemAbstract<T> problem, FirstOrderFieldIntegrator<T> integrator) {
         this.problem      = problem;
         this.integrator   = integrator;
         maxValueError     = problem.getField().getZero();

http://git-wip-us.apache.org/repos/asf/commons-math/blob/346a81d7/src/test/java/org/apache/commons/math4/ode/nonstiff/AbstractEmbeddedRungeKuttaFieldIntegratorTest.java
----------------------------------------------------------------------
diff --git a/src/test/java/org/apache/commons/math4/ode/nonstiff/AbstractEmbeddedRungeKuttaFieldIntegratorTest.java b/src/test/java/org/apache/commons/math4/ode/nonstiff/AbstractEmbeddedRungeKuttaFieldIntegratorTest.java
index 0f3449f..9314b27 100644
--- a/src/test/java/org/apache/commons/math4/ode/nonstiff/AbstractEmbeddedRungeKuttaFieldIntegratorTest.java
+++ b/src/test/java/org/apache/commons/math4/ode/nonstiff/AbstractEmbeddedRungeKuttaFieldIntegratorTest.java
@@ -26,8 +26,8 @@ import org.apache.commons.math4.exception.MaxCountExceededException;
 import org.apache.commons.math4.exception.NoBracketingException;
 import org.apache.commons.math4.exception.NumberIsTooSmallException;
 import org.apache.commons.math4.ode.FieldExpandableODE;
-import org.apache.commons.math4.ode.FieldFirstOrderDifferentialEquations;
-import org.apache.commons.math4.ode.FieldFirstOrderIntegrator;
+import org.apache.commons.math4.ode.FirstOrderFieldDifferentialEquations;
+import org.apache.commons.math4.ode.FirstOrderFieldIntegrator;
 import org.apache.commons.math4.ode.FieldODEState;
 import org.apache.commons.math4.ode.FieldODEStateAndDerivative;
 import org.apache.commons.math4.ode.TestFieldProblem1;
@@ -131,7 +131,7 @@ public abstract class AbstractEmbeddedRungeKuttaFieldIntegratorTest {
     public abstract void testForwardBackwardExceptions();
 
     protected <T extends RealFieldElement<T>> void doTestForwardBackwardExceptions(final Field<T> field) {
-        FieldFirstOrderDifferentialEquations<T> equations = new FieldFirstOrderDifferentialEquations<T>() {
+        FirstOrderFieldDifferentialEquations<T> equations = new FirstOrderFieldDifferentialEquations<T>() {
 
             public int getDimension() {
                 return 1;
@@ -188,7 +188,7 @@ public abstract class AbstractEmbeddedRungeKuttaFieldIntegratorTest {
         double[] vecAbsoluteTolerance = { 1.0e-15, 1.0e-16 };
         double[] vecRelativeTolerance = { 1.0e-15, 1.0e-16 };
 
-        FieldFirstOrderIntegrator<T> integ = createIntegrator(field, minStep, maxStep,
+        FirstOrderFieldIntegrator<T> integ = createIntegrator(field, minStep, maxStep,
                                                               vecAbsoluteTolerance, vecRelativeTolerance);
         TestFieldProblemHandler<T> handler = new TestFieldProblemHandler<T>(pb, integ);
         integ.addStepHandler(handler);
@@ -212,7 +212,7 @@ public abstract class AbstractEmbeddedRungeKuttaFieldIntegratorTest {
             double scalAbsoluteTolerance = FastMath.pow(10.0, i);
             double scalRelativeTolerance = 0.01 * scalAbsoluteTolerance;
 
-            FieldFirstOrderIntegrator<T> integ = createIntegrator(field, minStep, maxStep,
+            FirstOrderFieldIntegrator<T> integ = createIntegrator(field, minStep, maxStep,
                                                                   scalAbsoluteTolerance, scalRelativeTolerance);
             TestFieldProblemHandler<T> handler = new TestFieldProblemHandler<T>(pb, integ);
             integ.addStepHandler(handler);
@@ -243,7 +243,7 @@ public abstract class AbstractEmbeddedRungeKuttaFieldIntegratorTest {
       double scalAbsoluteTolerance = 1.0e-8;
       double scalRelativeTolerance = 0.01 * scalAbsoluteTolerance;
 
-      FieldFirstOrderIntegrator<T> integ = createIntegrator(field, minStep, maxStep,
+      FirstOrderFieldIntegrator<T> integ = createIntegrator(field, minStep, maxStep,
                                                             scalAbsoluteTolerance, scalRelativeTolerance);
       TestFieldProblemHandler<T> handler = new TestFieldProblemHandler<T>(pb, integ);
       integ.addStepHandler(handler);
@@ -275,7 +275,7 @@ public abstract class AbstractEmbeddedRungeKuttaFieldIntegratorTest {
         double scalAbsoluteTolerance = 1.0e-8;
         double scalRelativeTolerance = 0.01 * scalAbsoluteTolerance;
 
-        FieldFirstOrderIntegrator<T> integ = createIntegrator(field, minStep, maxStep,
+        FirstOrderFieldIntegrator<T> integ = createIntegrator(field, minStep, maxStep,
                                                               scalAbsoluteTolerance, scalRelativeTolerance);
         TestFieldProblemHandler<T> handler = new TestFieldProblemHandler<T>(pb, integ);
         integ.addStepHandler(handler);
@@ -314,7 +314,7 @@ public abstract class AbstractEmbeddedRungeKuttaFieldIntegratorTest {
         double scalAbsoluteTolerance = 1.0e-8;
         double scalRelativeTolerance = 0.01 * scalAbsoluteTolerance;
 
-        FieldFirstOrderIntegrator<T> integ = createIntegrator(field, minStep, maxStep,
+        FirstOrderFieldIntegrator<T> integ = createIntegrator(field, minStep, maxStep,
                                                               scalAbsoluteTolerance, scalRelativeTolerance);
         TestFieldProblemHandler<T> handler = new TestFieldProblemHandler<T>(pb, integ);
         integ.addStepHandler(handler);
@@ -422,7 +422,7 @@ public abstract class AbstractEmbeddedRungeKuttaFieldIntegratorTest {
         double[] vecAbsoluteTolerance = { 1.0e-8, 1.0e-8, 1.0e-10, 1.0e-10 };
         double[] vecRelativeTolerance = { 1.0e-10, 1.0e-10, 1.0e-8, 1.0e-8 };
 
-        FieldFirstOrderIntegrator<T> integ = createIntegrator(field, minStep, maxStep,
+        FirstOrderFieldIntegrator<T> integ = createIntegrator(field, minStep, maxStep,
                                                               vecAbsoluteTolerance, vecRelativeTolerance);
         integ.addStepHandler(new KeplerHandler<T>(pb, epsilon));
         integ.integrate(new FieldExpandableODE<T>(pb), pb.getInitialState(), pb.getFinalTime());
@@ -511,7 +511,7 @@ public abstract class AbstractEmbeddedRungeKuttaFieldIntegratorTest {
         return y.getPartialDerivative(orders);
     }
 
-    private static class SinCos implements FieldFirstOrderDifferentialEquations<DerivativeStructure> {
+    private static class SinCos implements FirstOrderFieldDifferentialEquations<DerivativeStructure> {
 
         private final DerivativeStructure omega;
         private       DerivativeStructure r;

http://git-wip-us.apache.org/repos/asf/commons-math/blob/346a81d7/src/test/java/org/apache/commons/math4/ode/nonstiff/AbstractRungeKuttaFieldIntegratorTest.java
----------------------------------------------------------------------
diff --git a/src/test/java/org/apache/commons/math4/ode/nonstiff/AbstractRungeKuttaFieldIntegratorTest.java b/src/test/java/org/apache/commons/math4/ode/nonstiff/AbstractRungeKuttaFieldIntegratorTest.java
index cc130d7..ae56e6b 100644
--- a/src/test/java/org/apache/commons/math4/ode/nonstiff/AbstractRungeKuttaFieldIntegratorTest.java
+++ b/src/test/java/org/apache/commons/math4/ode/nonstiff/AbstractRungeKuttaFieldIntegratorTest.java
@@ -28,7 +28,7 @@ import org.apache.commons.math4.exception.MaxCountExceededException;
 import org.apache.commons.math4.exception.NoBracketingException;
 import org.apache.commons.math4.exception.NumberIsTooSmallException;
 import org.apache.commons.math4.ode.FieldExpandableODE;
-import org.apache.commons.math4.ode.FieldFirstOrderDifferentialEquations;
+import org.apache.commons.math4.ode.FirstOrderFieldDifferentialEquations;
 import org.apache.commons.math4.ode.FieldODEState;
 import org.apache.commons.math4.ode.FieldODEStateAndDerivative;
 import org.apache.commons.math4.ode.TestFieldProblem1;
@@ -126,7 +126,7 @@ public abstract class AbstractRungeKuttaFieldIntegratorTest {
         k[0] = field.getZero().add(1.0e-4);
         k[1] = field.getZero().add(1.0e-5);
         k[2] = field.getZero().add(1.0e-6);
-        FieldFirstOrderDifferentialEquations<T> ode = new FieldFirstOrderDifferentialEquations<T>() {
+        FirstOrderFieldDifferentialEquations<T> ode = new FirstOrderFieldDifferentialEquations<T>() {
 
             public int getDimension() {
                 return k.length;
@@ -424,7 +424,7 @@ public abstract class AbstractRungeKuttaFieldIntegratorTest {
             public void init(FieldODEStateAndDerivative<T> s0, T t) {
             }
         });
-        integ.integrate(new FieldExpandableODE<T>(new FieldFirstOrderDifferentialEquations<T>() {
+        integ.integrate(new FieldExpandableODE<T>(new FirstOrderFieldDifferentialEquations<T>() {
             public void init(T t0, T[] y0, T t) {
             }
             public T[] computeDerivatives(T t, T[] y) {
@@ -470,7 +470,7 @@ public abstract class AbstractRungeKuttaFieldIntegratorTest {
         final T[] y0 = MathArrays.buildArray(field, 1);
         y0[0] = field.getOne();
         final T t   = field.getZero().add(0.001);
-        FieldFirstOrderDifferentialEquations<T> equations = new FieldFirstOrderDifferentialEquations<T>() {
+        FirstOrderFieldDifferentialEquations<T> equations = new FirstOrderFieldDifferentialEquations<T>() {
 
             public int getDimension() {
                 return 1;
@@ -573,7 +573,7 @@ public abstract class AbstractRungeKuttaFieldIntegratorTest {
         return y.getPartialDerivative(orders);
     }
 
-    private static class SinCos implements FieldFirstOrderDifferentialEquations<DerivativeStructure> {
+    private static class SinCos implements FirstOrderFieldDifferentialEquations<DerivativeStructure> {
 
         private final DerivativeStructure omega;
         private       DerivativeStructure r;

http://git-wip-us.apache.org/repos/asf/commons-math/blob/346a81d7/src/test/java/org/apache/commons/math4/ode/nonstiff/AbstractRungeKuttaFieldStepInterpolatorTest.java
----------------------------------------------------------------------
diff --git a/src/test/java/org/apache/commons/math4/ode/nonstiff/AbstractRungeKuttaFieldStepInterpolatorTest.java b/src/test/java/org/apache/commons/math4/ode/nonstiff/AbstractRungeKuttaFieldStepInterpolatorTest.java
index b670cda..100db47 100644
--- a/src/test/java/org/apache/commons/math4/ode/nonstiff/AbstractRungeKuttaFieldStepInterpolatorTest.java
+++ b/src/test/java/org/apache/commons/math4/ode/nonstiff/AbstractRungeKuttaFieldStepInterpolatorTest.java
@@ -25,7 +25,7 @@ import org.apache.commons.math4.ode.EquationsMapper;
 import org.apache.commons.math4.ode.ExpandableStatefulODE;
 import org.apache.commons.math4.ode.FieldEquationsMapper;
 import org.apache.commons.math4.ode.FieldExpandableODE;
-import org.apache.commons.math4.ode.FieldFirstOrderDifferentialEquations;
+import org.apache.commons.math4.ode.FirstOrderFieldDifferentialEquations;
 import org.apache.commons.math4.ode.FieldODEStateAndDerivative;
 import org.apache.commons.math4.ode.sampling.AbstractFieldStepInterpolator;
 import org.apache.commons.math4.util.FastMath;
@@ -103,7 +103,7 @@ public abstract class AbstractRungeKuttaFieldStepInterpolatorTest {
                                                                                      double epsilonSin, double epsilonCos,
                                                                                      double epsilonSinDot, double epsilonCosDot) {
 
-        FieldFirstOrderDifferentialEquations<T> eqn = new SinCos<T>(field);
+        FirstOrderFieldDifferentialEquations<T> eqn = new SinCos<T>(field);
         RungeKuttaFieldStepInterpolator<T> fieldInterpolator =
                         setUpInterpolator(field, eqn, 0.0, new double[] { 0.0, 1.0 }, 0.125);
         RungeKuttaStepInterpolator regularInterpolator = convertInterpolator(fieldInterpolator, eqn);
@@ -142,7 +142,7 @@ public abstract class AbstractRungeKuttaFieldStepInterpolatorTest {
 
     private <T extends RealFieldElement<T>>
     RungeKuttaFieldStepInterpolator<T> setUpInterpolator(final Field<T> field,
-                                                         final FieldFirstOrderDifferentialEquations<T> eqn,
+                                                         final FirstOrderFieldDifferentialEquations<T> eqn,
                                                          final double t0, final double[] y0,
                                                          final double t1) {
 
@@ -192,7 +192,7 @@ public abstract class AbstractRungeKuttaFieldStepInterpolatorTest {
 
     private <T extends RealFieldElement<T>>
     RungeKuttaStepInterpolator convertInterpolator(final RungeKuttaFieldStepInterpolator<T> fieldInterpolator,
-                                                   final FieldFirstOrderDifferentialEquations<T> eqn) {
+                                                   final FirstOrderFieldDifferentialEquations<T> eqn) {
 
         RungeKuttaStepInterpolator regularInterpolator = null;
         try {
@@ -284,7 +284,7 @@ public abstract class AbstractRungeKuttaFieldStepInterpolatorTest {
 
     }
 
-    private static class SinCos<T extends RealFieldElement<T>> implements FieldFirstOrderDifferentialEquations<T> {
+    private static class SinCos<T extends RealFieldElement<T>> implements FirstOrderFieldDifferentialEquations<T> {
         private final Field<T> field;
         protected SinCos(final Field<T> field) {
             this.field = field;

http://git-wip-us.apache.org/repos/asf/commons-math/blob/346a81d7/src/test/java/org/apache/commons/math4/ode/nonstiff/StepFieldProblem.java
----------------------------------------------------------------------
diff --git a/src/test/java/org/apache/commons/math4/ode/nonstiff/StepFieldProblem.java b/src/test/java/org/apache/commons/math4/ode/nonstiff/StepFieldProblem.java
index 3307cba..0368c85 100644
--- a/src/test/java/org/apache/commons/math4/ode/nonstiff/StepFieldProblem.java
+++ b/src/test/java/org/apache/commons/math4/ode/nonstiff/StepFieldProblem.java
@@ -19,7 +19,7 @@ package org.apache.commons.math4.ode.nonstiff;
 
 import org.apache.commons.math4.Field;
 import org.apache.commons.math4.RealFieldElement;
-import org.apache.commons.math4.ode.FieldFirstOrderDifferentialEquations;
+import org.apache.commons.math4.ode.FirstOrderFieldDifferentialEquations;
 import org.apache.commons.math4.ode.FieldODEState;
 import org.apache.commons.math4.ode.FieldODEStateAndDerivative;
 import org.apache.commons.math4.ode.events.Action;
@@ -28,7 +28,7 @@ import org.apache.commons.math4.util.MathArrays;
 
 
 public class StepFieldProblem<T extends RealFieldElement<T>>
-    implements FieldFirstOrderDifferentialEquations<T>, FieldEventHandler<T> {
+    implements FirstOrderFieldDifferentialEquations<T>, FieldEventHandler<T> {
 
     public StepFieldProblem(Field<T> field, T rateBefore, T rateAfter, T switchTime) {
         this.field      = field;

http://git-wip-us.apache.org/repos/asf/commons-math/blob/346a81d7/src/test/java/org/apache/commons/math4/ode/sampling/StepInterpolatorTestUtils.java
----------------------------------------------------------------------
diff --git a/src/test/java/org/apache/commons/math4/ode/sampling/StepInterpolatorTestUtils.java b/src/test/java/org/apache/commons/math4/ode/sampling/StepInterpolatorTestUtils.java
index 9798b9d..5c592d3 100644
--- a/src/test/java/org/apache/commons/math4/ode/sampling/StepInterpolatorTestUtils.java
+++ b/src/test/java/org/apache/commons/math4/ode/sampling/StepInterpolatorTestUtils.java
@@ -23,7 +23,7 @@ import org.apache.commons.math4.exception.MaxCountExceededException;
 import org.apache.commons.math4.exception.NoBracketingException;
 import org.apache.commons.math4.exception.NumberIsTooSmallException;
 import org.apache.commons.math4.ode.FieldExpandableODE;
-import org.apache.commons.math4.ode.FieldFirstOrderIntegrator;
+import org.apache.commons.math4.ode.FirstOrderFieldIntegrator;
 import org.apache.commons.math4.ode.FieldODEStateAndDerivative;
 import org.apache.commons.math4.ode.FirstOrderIntegrator;
 import org.apache.commons.math4.ode.TestFieldProblemAbstract;
@@ -95,7 +95,7 @@ public class StepInterpolatorTestUtils {
 
     }
 
-    public static <T extends RealFieldElement<T>> void checkDerivativesConsistency(final FieldFirstOrderIntegrator<T> integrator,
+    public static <T extends RealFieldElement<T>> void checkDerivativesConsistency(final FirstOrderFieldIntegrator<T> integrator,
                                                                                    final TestFieldProblemAbstract<T> problem,
                                                                                    final double threshold) {
         integrator.addStepHandler(new FieldStepHandler<T>() {


Mime
View raw message