The simulation of the generation of action potentials in a neuron using the Hodgkin-Huxley model. It captures how membrane potential evolves due to ion channel dynamics, modeling the ionic currents responsible for neuronal firing.
The rate of change of the membrane potential is governed by the current flowing across the membrane and the cell's capacitance.
dv/dt = i / c
The membrane is depolarized and repolarized by ion channel activity, specifically potassium
I = G * (V - E)
Where:
-
$G$ is the ion channel conductance (voltage dependent) -
$V$ is the membrane potential -
$E$ is the reverse potential for the ion
Three different gates are used to simulate time evolution of voltage:
- Potassium -
ngate - Sodium -
mandhgates - Leak channel
It implements voltage-dependent rate equations for channel gating variables and injects a step current into the neuron and tracks the resulting action potential.
Gating Dynamics : Each gate (n, m, h) follows a first-order differential equation representing open/close probabilties.
Rate constants (
Channels
- Potassium
$(K^+)$ :$n^4$ dependence for conductance. - Sodium
$(Na^+)$ :$m^3h$ dependence for conductance. - Leak channel : passive, constant conductance.
The simulation plots membrane potential (V) vs. time (s) showing action potential behavior in response to current injection.