ca.nengo.dynamics.impl
Class EulerIntegrator
java.lang.Object
ca.nengo.dynamics.impl.EulerIntegrator
- All Implemented Interfaces:
- Integrator, java.io.Serializable, java.lang.Cloneable
public class EulerIntegrator
- extends java.lang.Object
- implements Integrator
Euler's method of numerical integration: x(t+h) ~ x(t) + h*x'(t)
TODO: test
TODO: should there be some means for aborting early (aside from exceptions, e.g. if output converges to constant)?
- Author:
- Bryan Tripp
- See Also:
- Serialized Form
Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
EulerIntegrator
public EulerIntegrator(float stepSize)
EulerIntegrator
public EulerIntegrator()
- Uses default step size of .0001
getStepSize
public float getStepSize()
setStepSize
public void setStepSize(float stepSize)
integrate
public TimeSeries integrate(DynamicalSystem system,
TimeSeries input)
- Linear interpolation is performed between given input points.
- Specified by:
integrate
in interface Integrator
- Parameters:
system
- The DynamicalSystem to solve.input
- Input vector to the system, defined at the desired start and end times
of integration, and optionally at times in between. The way in which the
integrator interpolates between inputs at different times is decided by the
Integrator implementation.
- Returns:
- Time series of output vector
- See Also:
Integrator.integrate(ca.nengo.dynamics.DynamicalSystem, ca.nengo.util.TimeSeries)
clone
public Integrator clone()
throws java.lang.CloneNotSupportedException
- Specified by:
clone
in interface Integrator
- Overrides:
clone
in class java.lang.Object
- Throws:
java.lang.CloneNotSupportedException