Skip to content

ContinuousTimeStateEvolution

Continuous-time state evolution via stochastic differential equations (SDEs).

The state evolves according to

\[ dx_t = \bigl[ \mu(x_t, u_t, t) + s \, \nabla_x V(x_t, u_t, t) \bigr] \, dt + L(x_t, u_t, t) \, dW_t \]

where \(\mu\) is the drift, \(V\) is an optional potential, and \(L\) is the diffusion coefficient. The sign \(s\) is \(-1\) when use_negative_gradient is True (e.g., for Langevin dynamics) and \(+1\) otherwise.

Attributes:

Name Type Description
drift Drift | None

Drift vector field \(\mu(x, u, t)\). Defaults to zero if None. At least one of drift or potential must be non-None.

potential Potential | None

Scalar potential \(V(x, u, t)\) whose gradient is added to the drift. Defaults to zero if None. At least one of drift or potential must be non-None.

use_negative_gradient bool

If True, use \(-\nabla_x V\) (e.g., gradient descent on potential); otherwise use \(+\nabla_x V\). Default is False.

diffusion_coefficient Drift | None

Diffusion coefficient \(L(x, u, t)\) mapping to a matrix; multiplies the Brownian increment \(dW_t\). Defaults to zero if None (i.e., deterministic ODE).

bm_dim int | None

Dimension of the Brownian motion \(W_t\). Inferred automatically from the output shape of diffusion_coefficient; if passed by the user, it must match diffusion_coefficient(...).shape[1].