util.stepper
- class jVMC.util.stepper.AdaptiveHeun(timeStep=0.001, tol=1e-08, maxStep=1)
This class implements an adaptive second order consistent integration scheme.
- Initializer arguments:
timeStep: Initial time step (will be adapted automatically)tol: Tolerance for integration errors.maxStep: Maximal allowed time step.
- step(t, f, y, normFunction=<PjitFunction of <function norm>>, **rhsArgs)
This function performs an integration time step.
For a first order ordinary differential equation (ODE) of the form
\(\frac{dy}{dt} = f(y, t, p)\)
where \(t\) denotes the time and \(p\) denotes further external parameters this function computes a second-order consistent integration step for \(y\). The time step \(\Delta t\) is chosen such that the integration error (quantified by a given norm) is smaller than the given tolerance.
- Arguments:
t: Initial time.f: Right hand side of the ODE. This callable will be called asf(y, t, **rhsArgs, intStep=k), where k is an integer indicating the step number of the underlying Runge-Kutta integration scheme.y: Initial value of \(y\).normFunction: Norm function to be used to quantify the magnitude of errors.**rhsArgs: Further static arguments \(p\) that will be passed to the right hand side functionf(y, t, **rhsArgs, intStep=k).
- Returns:
New value of \(y\) and time step used \(\Delta t\).
- class jVMC.util.stepper.Euler(timeStep=0.001)
This class implements Euler integration
- step(t, f, yInitial, **rhsArgs)
This function performs an integration time step.
For a first order ordinary differential equation (ODE) of the form
\(\frac{dy}{dt} = f(y, t, p)\)
where \(t\) denotes the time and \(p\) denotes further external parameters this function computes the Euler integration step
\(y_{n+1} = y_n+\Delta t f(y_n,t_n,p)\)
- Arguments:
t: Initial time.f: Right hand side of the ODE. This callable will be called asf(y, t, **rhsArgs, intStep=k), where k is an integer indicating the step number of the underlying Runge-Kutta integration scheme.y: Initial value of \(y\).**rhsArgs: Further static arguments \(p\) that will be passed to the right hand side functionf(y, t, **rhsArgs, intStep=k).
- Returns:
New value of \(y\) and time step used \(\Delta t\).
- class jVMC.util.stepper.Heun(timeStep=0.001)
This class implements an adaptive second order consistent integration scheme.
- Initializer arguments:
timeStep: Initial time step (will be adapted automatically)
- step(t, f, yInitial, **rhsArgs)
This function performs an integration time step.
For a first order ordinary differential equation (ODE) of the form
\(\frac{dy}{dt} = f(y, t, p)\)
where \(t\) denotes the time and \(p\) denotes further external parameters this function computes a second-order consistent integration step for \(y\).
- Arguments:
t: Initial time.f: Right hand side of the ODE. This callable will be called asf(y, t, **rhsArgs, intStep=k), where k is an integer indicating the step number of the underlying Runge-Kutta integration scheme.yInitial: Initial value of \(y\).**rhsArgs: Further static arguments \(p\) that will be passed to the right hand side functionf(y, t, **rhsArgs, intStep=k).
- Returns:
New value of \(y\) and time step used \(\Delta t\).