All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.apache.commons.math.ode.sampling.package.html Maven / Gradle / Ivy

Go to download

The Math project is a library of lightweight, self-contained mathematics and statistics components addressing the most common practical problems not immediately available in the Java programming language or commons-lang.

There is a newer version: 2.2
Show newest version


    

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 {@link org.apache.commons.math.ode.sampling.StepHandler StepHandler} instance using the {@link org.apache.commons.math.ode.FirstOrderIntegrator#addStepHandler 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 {@link org.apache.commons.math.ode.sampling.StepHandler 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 {@link org.apache.commons.math.ode.sampling.StepInterpolator StepInterpolator} object. If regular output is desired (for example in order to write an ephemeris file), then the simpler {@link org.apache.commons.math.ode.sampling.FixedStepHandler FixedStepHandler} interface can be used. Objects implementing this interface should be wrapped within a {@link org.apache.commons.math.ode.sampling.StepNormalizer StepNormalizer} instance in order to be registered to the integrator.





© 2015 - 2024 Weber Informatics LLC | Privacy Policy