HopfStep#
- class brainmass.HopfStep(in_size, a=0.25, w=0.2, beta=1.0, noise_x=None, noise_y=None, init_x=ZeroInit(unit=1), init_y=ZeroInit(unit=1), method='exp_euler')#
Normal-form Hopf oscillator (two-dimensional rate model).
This model implements the supercritical Hopf normal form for a single node in terms of its real and imaginary components, often used as a simple mesoscopic model of oscillatory neural population activity.
The complex form is
\[\frac{dz}{dt} = (a + i\,\omega)\,z - \beta\,|z|^{2} z + I_{\text{ext}}(t),\]where \(z = x + i y\) and \(|z|^2 = x^2 + y^2\). In real variables:
\[\begin{split}\begin{aligned} \dot x &= (a - \beta r)\,x - \omega\,y + \text{coupled}_x + I_x(t),\\ \dot y &= (a - \beta r)\,y + \omega\,x + \text{coupled}_y + I_y(t), \\ r &= x^2 + y^2. \end{aligned}\end{split}\]- Parameters:
in_size (
int|Sequence[int] |integer|Sequence[integer]) – Spatial shape of the node. Can be an int or tuple of ints.a (
Callable|Array|ndarray|bool|number|bool|int|float|complex|Quantity|Param) – Bifurcation parameter (dimensionless). Fora > 0the system exhibits a stable limit cycle; fora < 0the origin is a stable focus. Broadcastable toin_size. Default is0.25.w (
Callable|Array|ndarray|bool|number|bool|int|float|complex|Quantity|Param) – Angular frequency \(\omega\) (dimensionless in this implementation). Broadcastable toin_size. Default is0.2.beta (
Callable|Array|ndarray|bool|number|bool|int|float|complex|Quantity|Param) – Nonlinear saturation coefficient (dimensionless) setting the limit-cycle amplitude (approximately \(\sqrt{a/\beta}\) whena>0). Broadcastable toin_size. Default is1.0.noise_x (
Noise) – Additive noise process tox. If provided, called each step and added toext_x. Default isNone.noise_y (
Noise) – Additive noise process toy. If provided, called each step and added toext_y. Default isNone.
- Return type:
Any
- x#
State container for the real component
x.- Type:
brainstate.HiddenState
- y#
State container for the imaginary component
y.- Type:
brainstate.HiddenState
Notes
Time derivatives returned by
dxanddycarry unit1/msso that an explicit (exponential) Euler integrator with time stepdthaving unitmsevolves the state consistently with units.- dx(x, y, inp)[source]#
Right-hand side for
x.- Parameters:
x (array-like) – Current real component.
y (array-like) – Current imaginary component (broadcastable to
x).inp (array-like or scalar) – External input to
x(includes coupling and noise).
- Returns:
Time derivative
dx/dtwith unit1/ms.- Return type:
array-like
- dy(y, x, inp)[source]#
Right-hand side for
y.- Parameters:
y (array-like) – Current imaginary component.
x (array-like) – Current real component (broadcastable to
y).inp (array-like or scalar) – External input to
y(includes coupling and noise).
- Returns:
Time derivative
dy/dtwith unit1/ms.- Return type:
array-like