Top Description Fields Constructors Methods
org.apache.commons.math3.ode

public Class FieldODEState<T extends RealFieldElement<T>>

extends Object
Class Inheritance
Known Direct Subclasses
org.apache.commons.math3.ode.FieldODEStateAndDerivative
Type Parameters
<T>
the type of the field elements
Imports
org.apache.commons.math3.Field, .RealFieldElement, org.apache.commons.math3.util.MathArrays

Container for time, main and secondary state vectors.
Since
3.6
See Also
FirstOrderFieldDifferentialEquations, FieldSecondaryEquations, FirstOrderFieldIntegrator, FieldODEStateAndDerivative

Field Summary

Modifier and TypeField and Description
private final T[][]
secondaryState

Secondary state at time.

private final T[]
state

Main state at time.

private final T
time

Time.

Constructor Summary

AccessConstructor and Description
public
FieldODEState(T
time
time
,
T[]
state at time
state
)

Simple constructor.

public
FieldODEState(T
time
time
,
T[]
state at time
state
,
T[][]
state at time (may be null)
secondaryState
)

Simple constructor.

Method Summary

Modifier and TypeMethod and Description
protected T[][]

Returns:

copied array or null if original array was null
copy
(final Field<T>
field to which elements belong
field
,
final T[][]
original array (may be null)
original
)

Copy a two-dimensions array.

public int

Returns:

number of secondary states.
getNumberOfSecondaryStates
()

Get the number of secondary states.

public T[]

Returns:

secondary state at time
getSecondaryState
(final int
index of the secondary set as returned by FieldExpandableODE#addSecondaryEquations(FieldSecondaryEquations) (beware index 0 corresponds to main state, additional states start at 1)
index
)

Get secondary state at time.

public int

Returns:

secondary state dimension
getSecondaryStateDimension
(final int
index of the secondary set as returned by FieldExpandableODE#addSecondaryEquations(FieldSecondaryEquations) (beware index 0 corresponds to main state, additional states start at 1)
index
)

Get secondary state dimension.

public T[]

Returns:

main state at time
getState
()

Get main state at time.

public int

Returns:

main state dimension
getStateDimension
()

Get main state dimension.

public T

Returns:

time
getTime
()

Get time.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

secondaryStateback to summary
private final T[][] secondaryState

Secondary state at time.

stateback to summary
private final T[] state

Main state at time.

timeback to summary
private final T time

Time.

Constructor Detail

FieldODEStateback to summary
public FieldODEState(T time, T[] state)

Simple constructor.

Calling this constructor is equivalent to call FieldODEState(time, state, null).

Parameters
time:T

time

state:T[]

state at time

FieldODEStateback to summary
public FieldODEState(T time, T[] state, T[][] secondaryState)

Simple constructor.

Parameters
time:T

time

state:T[]

state at time

secondaryState:T[][]

state at time (may be null)

Method Detail

copyback to summary
protected T[][] copy(final Field<T> field, final T[][] original)

Copy a two-dimensions array.

Parameters
field:Field<T>

field to which elements belong

original:T[][]

original array (may be null)

Returns:T[][]

copied array or null if original array was null

getNumberOfSecondaryStatesback to summary
public int getNumberOfSecondaryStates()

Get the number of secondary states.

Returns:int

number of secondary states.

getSecondaryStateback to summary
public T[] getSecondaryState(final int index)

Get secondary state at time.

Parameters
index:int

index of the secondary set as returned by FieldExpandableODE#addSecondaryEquations(FieldSecondaryEquations) (beware index 0 corresponds to main state, additional states start at 1)

Returns:T[]

secondary state at time

getSecondaryStateDimensionback to summary
public int getSecondaryStateDimension(final int index)

Get secondary state dimension.

Parameters
index:int

index of the secondary set as returned by FieldExpandableODE#addSecondaryEquations(FieldSecondaryEquations) (beware index 0 corresponds to main state, additional states start at 1)

Returns:int

secondary state dimension

getStateback to summary
public T[] getState()

Get main state at time.

Returns:T[]

main state at time

getStateDimensionback to summary
public int getStateDimension()

Get main state dimension.

Returns:int

main state dimension

getTimeback to summary
public T getTime()

Get time.

Returns:T

time