# Package org.apache.commons.math3.ode.sampling

package org.apache.commons.math3.ode.sampling

This package provides classes to handle sampling steps during Ordinary Differential Equations integration.

In addition to computing the evolution of the state vector at some grid points, all ODE integrators also build up interpolation models of this evolution inside the last computed step. If users are interested in these interpolators, they can register a `StepHandler` instance using the `addStepHandler` method which is supported by all integrators. The integrator will call this instance at the end of each accepted step and provide it the interpolator. The user can do whatever he wants with this interpolator, which computes both the state and its time-derivative. A typical use of step handler is to provide some output to monitor the integration process.

In a sense, this is a kind of Inversion Of Control: rather than having the master application driving the slave integrator by providing the target end value for the free variable, we get a master integrator scheduling the free variable evolution and calling the slave application callbacks that were registered at configuration time.

Since some integrators may use variable step size, the generic `StepHandler` interface can be called either at regular or irregular rate. This interface allows to navigate to any location within the last computed step, thanks to the provided `StepInterpolator` object. If regular output is desired (for example in order to write an ephemeris file), then the simpler `FixedStepHandler` interface can be used. Objects implementing this interface should be wrapped within a `StepNormalizer` instance in order to be registered to the integrator.

Related Packages
Package
Description
org.apache.commons.math3.ode
This package provides classes to solve Ordinary Differential Equations problems.
org.apache.commons.math3.ode.events
This package provides classes to handle discrete events occurring during Ordinary Differential Equations integration.
org.apache.commons.math3.ode.nonstiff
This package provides classes to solve non-stiff Ordinary Differential Equations problems.
Class
Description
AbstractFieldStepInterpolator<T extends RealFieldElement<T>>
This abstract class represents an interpolator over the last step during an ODE integration.
AbstractStepInterpolator
This abstract class represents an interpolator over the last step during an ODE integration.
DummyStepHandler
This class is a step handler that does nothing.
FieldFixedStepHandler<T extends RealFieldElement<T>>
This interface represents a handler that should be called after each successful fixed step.
FieldStepHandler<T extends RealFieldElement<T>>
This interface represents a handler that should be called after each successful step.
FieldStepInterpolator<T extends RealFieldElement<T>>
This interface represents an interpolator over the last step during an ODE integration.
FieldStepNormalizer<T extends RealFieldElement<T>>
This class wraps an object implementing `FieldFixedStepHandler` into a `FieldStepHandler`.
FixedStepHandler
This interface represents a handler that should be called after each successful fixed step.
NordsieckStepInterpolator
This class implements an interpolator for integrators using Nordsieck representation.
StepHandler
This interface represents a handler that should be called after each successful step.
StepInterpolator
This interface represents an interpolator over the last step during an ODE integration.
StepNormalizer
This class wraps an object implementing `FixedStepHandler` into a `StepHandler`.
StepNormalizerBounds
`Step normalizer` bounds settings.
StepNormalizerMode
`Step normalizer` modes.