ODESolution

class probnum.diffeq.ODESolution[source]

Bases: abc.ABC

ODE Solution interface.

Attributes Summary

dy

First derivative of the discrete-time solution.

t

Time points of the discrete-time solution.

y

Discrete-time solution.

Methods Summary

__call__(t)

Evaluate the time-continuous solution at time t.

sample([t, size])

Sample from the ODE solution.

Attributes Documentation

dy

First derivative of the discrete-time solution.

t

Time points of the discrete-time solution.

Return type

ndarray

y

Discrete-time solution.

Methods Documentation

__call__(t)[source]

Evaluate the time-continuous solution at time t.

Parameters

t (Union[float, List[float]]) – Location / time at which to evaluate the continuous ODE solution.

Returns

Return type

Probabilistic estimate of the continuous-time solution at time t.

sample(t=None, size=())[source]

Sample from the ODE solution.

Parameters
  • t (Union[float, List[float], None]) – Location / time at which to sample. If nothing is specified, samples at the ODE-solver grid points are computed. If it is a float, a sample of the ODE-solution at this time point is computed. Similarly, if it is a list of floats (or an array), samples at the specified grid-points are returned. This is not the same as computing i.i.d samples at the respective locations.

  • size (Union[Integral, Iterable[Integral], None]) – Number of samples.

Return type

ndarray