sde_srk4_step#
- class braintools.quad.sde_srk4_step(df, dg, y, t, *args, **kwargs)#
Stochastic Runge–Kutta 4 (Stratonovich; classical RK4).
Applies the classical 4-stage RK4 tableau to the Stratonovich increment
F(y,t) = f(y,t) dt + g(y,t) dWwith a single shared BrowniandW:k1 = F(y, t)k2 = F(y + 0.5 k1, t + 0.5 dt)k3 = F(y + 0.5 k2, t + 0.5 dt)k4 = F(y + k3, t + dt)y_{n+1} = y + (k1 + 2 k2 + 2 k3 + k4)/6
Notes
Suitable for Stratonovich SDEs. For Itô SDEs, conversions require additional correction terms (not included here).
- Returns:
The updated state
y_{n+1}.- Return type:
PyTree