stateupdaters package
Module for transforming model equations into “abstract code” that can be then be
further translated into executable code by the codegen
module.
Exported members:
StateUpdateMethod
, linear
, exact
, independent
, milstein
, heun
, euler
, rk2
, rk4
, ExplicitStateUpdater
, exponential_euler
, gsl_rk2
, gsl_rk4
, gsl_rkf45
, gsl_rkck
, gsl_rk8pd
GSL
module
Module containg the StateUpdateMethod for integration using the ODE solver
provided in the GNU Scientific Library (GSL)
Exported members:
gsl_rk2
, gsl_rk4
, gsl_rkf45
, gsl_rkck
, gsl_rk8pd
Classes
GSLContainer (method_options, integrator[, …]) |
Class that contains information (equation- or integrator-related) required for later code generation |
GSLStateUpdater (integrator) |
A statupdater that rewrites the differential equations so that the GSL generator knows how to write the code in the target language. |
Objects
gsl_rk2 |
A statupdater that rewrites the differential equations so that the GSL generator knows how to write the code in the target language. |
gsl_rk4 |
A statupdater that rewrites the differential equations so that the GSL generator knows how to write the code in the target language. |
gsl_rk8pd |
A statupdater that rewrites the differential equations so that the GSL generator knows how to write the code in the target language. |
gsl_rkck |
A statupdater that rewrites the differential equations so that the GSL generator knows how to write the code in the target language. |
gsl_rkf45 |
A statupdater that rewrites the differential equations so that the GSL generator knows how to write the code in the target language. |
base
module
This module defines the StateUpdateMethod
class that acts as a base class for
all stateupdaters and allows to register stateupdaters so that it is able to
return a suitable stateupdater object for a given set of equations. This is used
for example in NeuronGroup
when no state updater is given explicitly.
Exported members:
StateUpdateMethod
Classes
Functions
extract_method_options (method_options, …) |
Helper function to check method_options against options understood by this state updater, and setting default values for all unspecified options. |
exact
module
Exact integration for linear equations.
Exported members:
linear
, exact
, independent
Classes
Functions
get_linear_system (eqs, variables) |
Convert equations into a linear system using sympy. |
Objects
exact |
A state updater for linear equations. |
independent |
A state update for equations that do not depend on other state variables, i.e. |
linear |
A state updater for linear equations. |
explicit
module
Numerical integration functions.
Exported members:
milstein
, heun
, euler
, rk2
, rk4
, ExplicitStateUpdater
Classes
ExplicitStateUpdater (description[, …]) |
An object that can be used for defining state updaters via a simple description (see below). |
Functions
diagonal_noise (equations, variables) |
Checks whether we deal with diagonal noise, i.e. |
split_expression (expr) |
Split an expression into a part containing the function f and another one containing the function g . |
Objects
euler |
Forward Euler state updater |
heun |
Stochastic Heun method (for multiplicative Stratonovic SDEs with non-diagonal diffusion matrix) |
milstein |
Derivative-free Milstein method |
rk2 |
Second order Runge-Kutta method (midpoint method) |
rk4 |
Classical Runge-Kutta method (RK4) |
exponential_euler
module
Exported members:
exponential_euler
Classes
Functions
Objects