voltage_integration_linear¶
- voltage_integration_linear(masked_inputs: Tensor, voltages: Tensor, *, step_time: float | Tensor, time_constant: float | Tensor, rest_v: float | Tensor, resistance: float | Tensor) Tensor[source]¶
Integrates input currents into membrane voltages using linear dynamics.
\[V_m(t + \Delta t) = \left[V_m(t) - V_\text{rest} - R_mI(t)\right] \exp(-\Delta t / \tau_m) + V_\text{rest} + R_mI(t)\]- Parameters:
masked_inputs (torch.Tensor) – presynaptic currents masked by neurons in their absolute refractory period, \(I(t)\), in \(\text{nA}\).
voltages (torch.Tensor) – membrane voltages \(V_m(t)\), in \(\text{mV}\).
step_time (float | torch.Tensor) – length of a simulation time step, \(\Delta t\), in \(\text{ms}\).
time_constant (float | torch.Tensor) – time constant of exponential decay for membrane voltage, \(\tau_m\), in \(\text{ms}\).
rest_v (float | torch.Tensor) – membrane potential difference at equilibrium, \(V_\text{rest}\), in \(\text{mV}\).
resistance (float | torch.Tensor) – resistance across the cell membrane, \(R_m\), in \(\text{M}\Omega\).
- Returns:
membrane voltages with inputs integrated, in \(\text{mV}\).
- Return type: