← SciSim / Neuroscience

Action Potential

🧠 Tier: HSC / Early Undergraduate · Membrane Voltage Dynamics
§ 01
Interactive Simulation
Resting
Depolarization
Repolarization
AHP
Abs. Refractory
Rel. Refractory
Voltage V
–65.0
mV
Iext
10.0
μA/cm²
AP Phase
Resting
Firing Rate
0.0
Hz
Spike Count
0
spikes
Peak AP
mV
Sim Time
0.0
ms
Iext (μA/cm²) 10.0
Na (mS/cm²) 120
K (mS/cm²) 36
gL (mS/cm²) 0.30
Cm (μF/cm²) 1.0
Vthresh (mV) -55
Noise σ (μA/cm²) 0.0
T sim (ms) 100
§ 02
The Idea, Step by Step
▸ From a Light Switch to the Hodgkin–Huxley Equation

Flip a light switch and the bulb is either on or off — there is no "half on." A neuron's action potential works the same way. Nudge the cell a little and nothing happens; nudge it past a tipping point and it fires one full, fixed-size electrical spike — every single time. That spike is how one brain cell shouts a message to the next.

BUILD IT UP — what is actually moving
What moves is electric charge. The inside of a resting neuron sits about $-65$ mV below the outside. Two kinds of doorways in the membrane — sodium (Na⁺) channels and potassium (K⁺) channels — open and close depending on this voltage. Push the voltage past the threshold (around $-55$ mV) and the Na⁺ doors fly open: sodium rushes in and the voltage rockets up toward $+40$ mV. A heartbeat later the Na⁺ doors slam shut while the K⁺ doors open; potassium leaves, and the voltage crashes back down. One whole spike, start to finish, in about $2$ ms. A quick number: with threshold at $-55$ mV and rest at $-65$ mV, you only have to lift the membrane by roughly $10$ mV to set the entire avalanche off.
DEEPEN IT — the one balance equation
All of this is captured by a single statement: the membrane is a capacitor being charged and drained by ionic currents, so $$C_m\,\frac{dV}{dt}=I_{\text{ext}}-\bar{g}_{Na}\,m^3h\,(V-E_{Na})-\bar{g}_K\,n^4\,(V-E_K)-g_L\,(V-E_L).$$ The gating variables $m$, $h$, and $n$ slide between $0$ and $1$ to track how open each channel population is, and $\frac{dV}{dt}$ is just "how fast the voltage is changing right now." On the control panel to the right, the $I_{\text{ext}}$ slider is your stimulating electrode, $\bar{g}_{Na}$ and $\bar{g}_K$ set how powerful each channel type is, and $C_m$ sets how sluggishly the voltage responds to current.
TRY THIS IN THE SIM ABOVE
(1) Drag $I_{\text{ext}}$ slowly upward and watch nothing happen until you cross threshold — then a full-height spike suddenly appears. That jump is the all-or-nothing law in action. (2) Set $\bar{g}_K$ near $0$ and notice repolarization stalls: the cell shoots up but struggles to reset. (3) Double $C_m$ from $1$ to $2$ and watch every spike grow wider and slower while its peak height stays the same — proof that amplitude is set by the ion gradients, not by how hard you push.
§ 03
Equation Derivation — Action Potential Biophysics
▸ The Five Phases of an Action Potential — Mathematical Signatures

An action potential is a stereotyped, all-or-nothing electrical event generated when membrane voltage crosses a threshold, driven by voltage-dependent ionic conductances. The five phases each correspond to distinct mathematical regimes of the Hodgkin-Huxley system.

PhaseVoltage RangeDominant CurrentGate DynamicsDuration
① RestingV ≈ −65 mV\(I_L\) (leak, small)m≈0.05, h≈0.6, n≈0.32 (near steady state)Indefinite
② Depolarization−55 → +40 mV\(I_{Na}\) inward (dominant)m rises fast (τ_m ≈ 0.4 ms), h begins falling~0.5–1 ms
③ Repolarization+40 → −65 mV\(I_K\) outward (dominant)h → 0 (Na⁺ inactivated), n rises (τ_n ≈ 5 ms)~1–2 ms
④ AHP−65 → −80 mV\(I_K\) still outwardn slowly returning to rest; V briefly below E_rest~3–5 ms
⑤ Recovery−80 → −65 mV\(I_L\) drives returnAll gates return to resting values via \(x_\infty(V)\)~5–15 ms
▸ Core Equations Governing the Action Potential

The membrane voltage obeys the cable/capacitor equation. At threshold, the net ionic current becomes regenerative — a positive feedback loop:

$$C_m \dfrac{dV}{dt} = I_{\text{ext}} - \underbrace{\bar{g}_{Na} m^3 h (V - E_{Na})}_{\text{inward Na}^+\text{ (depolarising)}} - \underbrace{\bar{g}_K n^4 (V - E_K)}_{\text{outward K}^+\text{ (repolarising)}} - \underbrace{g_L (V - E_L)}_{\text{leak}}$$

The threshold condition — the voltage at which inward Na⁺ current exactly balances all outward currents:

$$\text{Threshold}: \quad \bar{g}_{Na} m_\infty^3(V_{th}) h_\infty(V_{th}) (V_{th} - E_{Na}) + \bar{g}_K n_\infty^4(V_{th})(V_{th}-E_K) + g_L(V_{th}-E_L) = I_{\text{ext}}$$

Nernst equation — the equilibrium (reversal) potential for ion species X with valence z:

$$E_X = \dfrac{RT}{zF} \ln\!\left(\dfrac{[X]_{\text{out}}}{[X]_{\text{in}}}\right) \qquad \text{at } 37°\text{C}: \quad E_{Na} \approx +60\text{ mV}, \quad E_K \approx -88\text{ mV}$$

Overton/Goldman equation — resting potential set by weighted ion permeabilities:

$$\boxed{V_{\text{rest}} = \dfrac{RT}{F} \ln\!\left(\dfrac{P_K[K^+]_o + P_{Na}[Na^+]_o + P_{Cl}[Cl^-]_i}{P_K[K^+]_i + P_{Na}[Na^+]_i + P_{Cl}[Cl^-]_o}\right)}$$
▸ Symbol Table
SymbolMeaningUnitTypical Value
\(V\)Membrane potentialmV−65 (rest) to +40 (peak AP)
\(C_m\)Membrane capacitance per areaμF/cm²1.0
\(I_{\text{ext}}\)Injected current densityμA/cm²0–20
\(E_{Na}\)Sodium Nernst potentialmV+50 (squid), +60 (mammal)
\(E_K\)Potassium Nernst potentialmV−77 (squid), −88 (mammal)
\(E_L\)Leak reversal potentialmV−54.4
\(V_{th}\)Threshold voltagemV−55 to −50
\(V_{AHP}\)After-hyperpolarisation troughmV−75 to −80
\(R, T, F\)Gas const, temperature, Faraday constJ/mol/K, K, C/mol8.314, 310, 96485
\(P_K, P_{Na}\)Ion permeabilities (Goldman eq.)cm/s\(P_{Na}/P_K \approx 0.04\) at rest
\(m, h, n\)HH gating variables[0,1]
▸ Step-by-Step Derivation — From Membrane to Action Potential
STEP 1 — The Neuron as an RC Circuit
The cell membrane acts as a capacitor (dielectric lipid bilayer, C_m ≈ 1 μF/cm²) in parallel with resistors (ion channels). Any net ionic current either charges the capacitor (changes V) or flows through the channels. Kirchhoff's current law: total current in = capacitive current + sum of ionic currents. Rearranged: \(C_m \frac{dV}{dt} = I_{\text{ext}} - \sum_i I_i\).
STEP 2 — Resting Potential via Goldman-Hodgkin-Katz Equation
At rest, the membrane is ~40× more permeable to K⁺ than Na⁺. K⁺ diffuses outward (down its concentration gradient), leaving behind negative charge. This builds an electrical gradient opposing further K⁺ efflux. The resting potential (≈ −65 mV) is close to the K⁺ Nernst potential (≈ −77 mV) but shifted positive by the small Na⁺ leak. The Goldman equation gives the exact value as a function of all permeant ion concentrations and permeabilities.
STEP 3 — The Threshold and Positive Feedback
When V is depolarized above threshold (≈ −55 mV), voltage-gated Na⁺ channels begin to open. The inward Na⁺ current further depolarizes V, which opens more Na⁺ channels — a positive feedback (regenerative) loop. This is the Hodgkin cycle: \(\uparrow V \Rightarrow \uparrow g_{Na} \Rightarrow \uparrow I_{Na}\text{ (inward)} \Rightarrow \uparrow V\). Below threshold, the leak + K⁺ outward currents overpower Na⁺ and V returns to rest (all-or-nothing law).
STEP 4 — Depolarization Phase (~0.5 ms)
Once threshold is crossed, m (Na⁺ activation) rises with time constant τ_m ≈ 0.4 ms at −40 mV. Sodium current \(I_{Na} = \bar{g}_{Na} m^3 h (V - E_{Na})\) becomes enormous — V shoots toward E_Na (+50 mV) but overshoots only to +30–40 mV because h begins inactivating and n begins activating. The rate of rise (dV/dt) at the peak of the upstroke can exceed 500 mV/ms in fast Na⁺ channels.
STEP 5 — Repolarization Phase (~1–2 ms)
Two simultaneous processes terminate the AP: (1) Na⁺ inactivation — h gate closes (τ_h ≈ 1–2 ms at depolarized V), shutting off I_Na; (2) K⁺ activation — n gate opens (τ_n ≈ 3–5 ms), producing large outward I_K that drives V back toward E_K. This is the negative feedback that terminates the depolarization. The K⁺ current is sometimes called the "delayed rectifier" because it activates more slowly than Na⁺.
STEP 6 — After-Hyperpolarisation (AHP, ~3–5 ms)
K⁺ channels remain open after V passes E_rest, because n relaxes toward its resting value slowly (τ_n ≈ 5–8 ms near rest). This drives V below the resting potential toward E_K ≈ −77 mV. The AHP depth is \(V_{AHP} \approx E_K + (V_{\text{rest}} - E_K) \cdot e^{-t/\tau_n}\), roughly −72 to −80 mV. This temporarily increases the firing threshold — this is the relative refractory period.
STEP 7 — Absolute vs Relative Refractory Periods
Absolute refractory period (ARP, ~1–2 ms): Na⁺ channels are fully inactivated (h ≈ 0); no stimulus regardless of magnitude can trigger another AP. This enforces the all-or-nothing law and sets maximum firing rate (~500–1000 Hz). Relative refractory period (RRP, ~3–10 ms): h partially recovered, n still elevated; a suprathreshold stimulus can fire an AP, but it will be smaller and require higher current. The RRP enables frequency encoding — stronger inputs drive higher firing rates.
STEP 8 — All-or-Nothing Law and the Threshold as a Separatrix
In phase space, the threshold acts as a saddle point (unstable equilibrium) of the 4D HH system. Stimuli that push V just below threshold produce subthreshold responses that decay back to rest; stimuli just above threshold produce full APs. Mathematically, the threshold is the stable manifold of the saddle point separating the basin of attraction of the resting state from the limit cycle (repetitive firing) or return trajectory (single AP).

▸ Worked Numerical Example — Identifying the AP Phase from Gating Variables

Given the following state at time t = 1.2 ms into a simulation: V = +32 mV, m = 0.98, h = 0.08, n = 0.61. Identify the AP phase and dominant current.

$$g_{Na} = \bar{g}_{Na} m^3 h = 120 \times (0.98)^3 \times 0.08 \approx 120 \times 0.941 \times 0.08 \approx 9.03 \;\text{mS/cm}^2$$ $$g_K = \bar{g}_K n^4 = 36 \times (0.61)^4 \approx 36 \times 0.138 \approx 4.97 \;\text{mS/cm}^2$$ $$I_{Na} = 9.03 \times (32 - 50) = 9.03 \times (-18) \approx -163 \;\mu\text{A/cm}^2 \;\text{(inward, small — Na already inactivating)}$$ $$I_K = 4.97 \times (32 - (-77)) = 4.97 \times 109 \approx +541 \;\mu\text{A/cm}^2 \;\text{(large outward — repolarizing)}$$

Conclusion: V = +32 mV (near peak), m ≈ 1 (Na⁺ fully activated), h = 0.08 (Na⁺ nearly fully inactivated), large I_K outward. This is the early Repolarization phase — Na⁺ inactivation plus K⁺ activation are driving V back down. dV/dt = (10 − (−163) − 541 − (32−(−54.4))×0.3)/1 = (10 + 163 − 541 − 25.9)/1 ≈ −394 mV/ms (rapidly falling).

▸ Primary References — Section 2
[HH52]Hodgkin & Huxley — A quantitative description of membrane current, J. Physiol. 117:500–544, 1952
[Pur21]Purves et al. — Neuroscience (6th ed.), Sinauer, 2018. Ch. 2: "Electrical Signals of Nerve Cells" & Ch. 3: "Voltage-Dependent Membrane Permeability"
[Kan21]Kandel et al. — Principles of Neural Science (6th ed.), McGraw-Hill, 2021. Ch. 6–9: Action potential, ion channels
[DA01]Dayan & Abbott — Theoretical Neuroscience, MIT Press, 2001. Ch. 5
[JW95]Johnston & Wu — Foundations of Cellular Neurophysiology, MIT Press, 1995. Ch. 6–8
§ 04
Frequently Asked Questions
🔬 Simulation What does the "AP Phases" tab show, and how does it map onto biology?
The AP Phases tab colour-codes the voltage trace by the current physiological phase: grey for resting state (V near −65 mV, all gates near equilibrium), orange-red for depolarisation (V rising above threshold, Na⁺ channels rapidly opening), blue for repolarisation (V falling from peak, K⁺ channels dominating), purple for after-hyperpolarisation (V below rest, n gate still elevated), and shaded bands for absolute and relative refractory periods. Each colour boundary is computed from the instantaneous gating variable state rather than a fixed voltage cutoff — so the phase timing is biophysically accurate and changes when you alter parameters like ḡ_Na or C_m. The simulation detects threshold crossing (V rising through −55 mV) as spike onset; spike peak is the maximum V before the next downward crossing.
Key takeaway: The five AP phases are not arbitrary textbook labels — each corresponds to a distinct mathematical regime with a characteristic sign and magnitude of dV/dt and dominant ionic current.
🧠 Conceptual Why is the action potential "all-or-nothing"? Can you get a half-sized AP?
The all-or-nothing law arises from the positive feedback (regenerative) nature of Na⁺ channel opening: once threshold is crossed, the Hodgkin cycle (more depolarisation → more Na⁺ channels open → more inward current → more depolarisation) drives V to the Na⁺ equilibrium potential regardless of how much extra stimulus was applied. Below threshold, this feedback is overcome by K⁺ and leak currents, which restore V to rest. There is no intermediate stable trajectory — the phase-space geometry forces V to either the rest fixed point or the full action-potential orbit. You cannot get a "half-sized" AP with standard channels, though you can reduce the AP amplitude by pre-inactivating some Na⁺ channels (e.g., applying a conditioning depolarisation to reduce h), which is exactly what the relative refractory period does. In the simulation, set I_ext just barely above threshold to see the AP trigger with only a tiny margin.
Key takeaway: "All-or-nothing" is a consequence of the bistability near threshold in the fast Na⁺ subsystem — a topological property of the phase portrait, not a design rule.
🌍 Applied Where does action potential physiology appear in medicine and neural technology?
Action potential biophysics underpins virtually all of clinical neurology and pharmacology. Local anaesthetics (lidocaine, tetrodotoxin) block voltage-gated Na⁺ channels, preventing AP initiation — the same channels that are defective in channelopathies like long-QT syndrome (cardiac Na⁺/K⁺ channels), paramyotonia congenita (skeletal muscle Na⁺ channels), and SCN1A epilepsies. Anticonvulsants (phenytoin, carbamazepine) stabilise Na⁺ channel inactivation to reduce abnormal firing. Deep brain stimulation (DBS) for Parkinson's and tremor works by overriding pathological AP patterns in the subthalamic nucleus. Cochlear implants and retinal prostheses use precisely timed current pulses to trigger APs in specific neural populations. Brain-computer interfaces (Neuralink, Utah array) record single-unit APs to decode motor intention for paralysed patients.
Key takeaway: Every device or drug that modifies neural function — from pain relief to neuroprosthetics — acts by modifying one or more of the four variables (V, m, h, n) in the action potential model.
💡 Non-Obvious Why does the membrane OVERSHOOT zero — what stops it from reaching +50 mV (E_Na)?
During the rising phase, V indeed overshoots 0 mV (inner face becomes transiently positive) and reaches +30–40 mV — this overshoot was considered impossible before Hodgkin and Katz (1949) and was experimentally surprising. V does not reach E_Na (+50 mV) for two reasons: (1) Na⁺ inactivation — the h gate begins closing with τ_h ≈ 1–2 ms, reducing g_Na before V has time to equilibrate; (2) K⁺ activation — the n gate is already opening, injecting outward current that partially counteracts the inward Na⁺ current. The peak voltage reflects a dynamic balance, not a simple equilibrium. In the HH model, if you set ḡ_K = 0 and artificially hold h = 1 (no inactivation), V does climb closer to E_Na ≈ +50 mV, demonstrating that these two opposing processes together set the AP peak.
Key takeaway: The AP peak voltage is a transient dynamical maximum, not a Nernst equilibrium — it reflects the competition between accelerating Na⁺ influx and the onset of Na⁺ inactivation plus K⁺ activation.
📐 Computational How does changing C_m affect the action potential, and why?
The membrane capacitance C_m scales the rate at which voltage changes for a given current: \(\frac{dV}{dt} = \frac{I_{\text{net}}}{C_m}\). Doubling C_m doubles the "inertia" of the membrane — the AP takes twice as long to rise and fall, and the maximum dV/dt is halved. However, the peak voltage and AHP depth are largely unaffected (they are set by the gating variables' quasi-steady-state values, which are voltage-dependent but not C_m-dependent). In the simulation, increase C_m from 1 to 2 μF/cm²: you will see a wider, slower AP. Biologically, myelinated axons have very low effective C_m per unit length (myelin adds extra insulation, reducing capacitance ~100-fold), which is why saltatory conduction in myelinated axons is so much faster — each node of Ranvier needs to charge only a tiny patch of bare membrane.
Key takeaway: C_m sets the membrane time constant τ_m = C_m / g — increasing it slows all voltage dynamics but does not change the final amplitude of the AP, which is determined by gating variable steady states.
🎓 Deep / Advanced What does the action potential look like in the ion channel's "Markov chain" view vs the HH gating variable view?
The HH gating variables m, h, n describe the mean-field average over many independent, identical channels. Each individual channel is a stochastic protein that randomly transitions between a finite set of conformational states (closed, open, inactivated). For a Na⁺ channel with 3 independent m-gates and 1 h-gate, the Markov model has 8 states: C₀, C₁, C₂, O (open), I₀, I₁, I₂, I (inactivated). The HH equations emerge exactly from the mean-field limit of this Markov model when channel number → ∞ and all m-gates are assumed independent. With ~10,000 channels per μm², the mean-field approximation is excellent. For a patch with only ~100 channels (e.g., a small dendritic spine), individual channel noise produces significant trial-to-trial variability in spike timing. This "channel noise" is modelled by the stochastic HH model (Fox & Lu, 1994) and is biologically relevant for small neurons, sensory hair cells, and signal detection near threshold.
Key takeaway: The HH model is the law-of-large-numbers limit of the true stochastic Markov channel model — it is exact only when the membrane area (and thus channel number) is large, and breaks down for small membrane patches.
🧠 Conceptual What is the difference between the absolute and relative refractory periods, and why do they matter for neural coding?
The absolute refractory period (ARP, ~1–2 ms) is the interval immediately after a spike during which h ≈ 0 — Na⁺ channels are fully inactivated and no amount of current can trigger another AP. The ARP sets a hard upper limit on firing rate: 1/ARP ≈ 500–1000 Hz. The relative refractory period (RRP, ~3–10 ms after the ARP) occurs while h is partially recovered and n is still elevated (AHP phase). A second AP can be triggered, but requires more current and produces a smaller, faster-repolarizing AP. The RRP enables frequency-modulated coding: stronger stimuli produce higher firing rates by effectively shortening the functional refractory period (the neuron fires again as soon as V can reach threshold, which happens earlier when I_ext is large enough to push V up despite the AHP). This is why firing rate increases smoothly with stimulus intensity — the f-I curve — rather than being binary.
Key takeaway: The refractory period is not a design flaw but a coding feature — it converts stimulus intensity into firing rate by setting the minimum inter-spike interval as a function of the applied current.
§ 04 Best Learning Resources
§ 05
Misconceptions & Common Errors
Sub-block A — Conceptual Misconceptions
"During an action potential, the sodium-potassium pump (Na⁺/K⁺-ATPase) drives the depolarisation by pumping Na⁺ in."
The Na⁺/K⁺-ATPase pump is not involved in generating individual action potentials. It is a slow, ATP-driven pump that restores ionic concentrations over many seconds — it exchanges 3 Na⁺ out for 2 K⁺ in per ATP hydrolysed. The action potential is driven entirely by passive flow of Na⁺ and K⁺ through voltage-gated channels down pre-existing electrochemical gradients. The pump maintains those gradients over long timescales but plays no role in the millisecond timescale of spike generation. In fact, a neuron can fire thousands of action potentials before ionic concentration gradients collapse enough to affect AP shape — the concentration changes per spike are tiny (e.g., ~1 μM change in [Na⁺]_i per AP in a large soma).
📖 Purves et al. — Neuroscience (6th ed.), Ch. 2; Kandel et al. — Principles of Neural Science (6th ed.), Ch. 7
"The action potential amplitude (peak voltage) gets larger with stronger stimuli — a bigger current gives a bigger spike."
This is a direct violation of the all-or-nothing law. Once threshold is exceeded, the AP amplitude is fixed by the electrochemical driving forces (V → near E_Na) and gating kinetics — it does not depend on how much the stimulus exceeded threshold. A stimulus of 7 μA/cm² and one of 20 μA/cm² will produce action potentials of identical peak voltage (≈ +30–40 mV). What changes with stimulus intensity is the firing rate (f-I curve), not the spike amplitude. The only exception is during the relative refractory period, where h is still partially inactivated — the AP amplitude can be genuinely reduced, not because the stimulus was larger but because fewer Na⁺ channels are available.
📖 Hodgkin & Huxley (1952), Fig. 3; Gerstner et al. — Neuronal Dynamics, Ch. 2.1
"The resting potential of −70 mV means the inside of the neuron is at −70 mV and the outside is at 0 mV."
Membrane potential is a difference measurement: V = V_inside − V_outside. The convention is to define V_outside = 0 mV by grounding the reference electrode in the extracellular solution. The "−70 mV" means the inside is 70 mV below the outside, not that either compartment has an absolute charge. There is no such thing as a neuron "floating at −70 mV" in absolute terms. Changing this convention (e.g., as Hodgkin and Huxley originally used V_outside − V_inside, giving a +70 mV resting potential) is equivalent physics — only the sign convention changes. Modern electrophysiology universally uses V = V_inside − V_outside, with V_outside ≡ 0.
📖 Johnston & Wu — Foundations of Cellular Neurophysiology, Ch. 1 §1.2; Hille — Ion Channels of Excitable Membranes (3rd ed.), Ch. 1
Sub-block B — Common Numerical & Modeling Errors
Detecting spikes by checking only V[t] > threshold — this counts the same spike multiple times during the plateau above threshold.
Use a threshold-crossing detector: a spike occurs when V crosses threshold from below, i.e., V[t] > V_thresh AND V[t-1] <= V_thresh. This detects exactly one event per upstroke. Alternative: detect the voltage peak (local maximum) using V[t] > V[t-1] AND V[t] > V[t+1] AND V[t] > 0. Never count samples above threshold — during the repolarisation phase V remains above −55 mV for ~1 ms, which would falsely inflate the spike count by ~40 steps at dt = 0.025 ms. This simulation uses the upward-crossing method with a brief refractory lockout of 2 ms to prevent double-counting.
🔍 Why students do this: The simplest check is V > threshold, which is correct logically but not temporally — fails to account for the duration of the supra-threshold phase.
Setting V_rest = −70 mV in the HH model by changing the initial condition while keeping E_L = −54.4 mV — the neuron "drifts" and does not fire normally.
The resting potential in the HH model is not a free parameter you set by initial condition — it is the stable fixed point of the ODE system, determined by the intersection of the V-nullcline and the gating variable nullclines. To shift V_rest from −65 to −70 mV, you must change E_L or g_L (which shifts the leak current's contribution to the equilibrium). If you initialize V = −70 mV but keep E_L = −54.4 mV, the model will drift back to its true rest (≈ −65 mV) within a few milliseconds via the leak current. The correct procedure: set E_L = −70 mV and adjust g_L so the fixed point satisfies \(g_L(V_{\text{rest}} - E_L) = \bar{g}_{Na}m_\infty^3 h_\infty(V_{\text{rest}} - E_{Na}) + \bar{g}_K n_\infty^4(V_{\text{rest}} - E_K)\).
🔍 Why students do this: They conflate "initial condition" with "steady state" — forgetting that the rest state is a dynamical attractor, not a set value.
Computing the firing rate as rate = spike_count / dt_per_step or using wall-clock time rather than simulation time.
Firing rate must be computed in simulation time units (ms), not wall-clock time or integration steps. The correct formula is rate_Hz = (spike_count / t_simulation_ms) × 1000. Equivalently, the mean firing rate over the simulation window T_ms is spike_count / (T_ms × 1e-3). For instantaneous firing rate (between consecutive spikes), use f_inst = 1000 / ISI_ms where ISI is the inter-spike interval in milliseconds. Confusing simulation time steps with real time is especially common in JavaScript simulations where animation frames and integration steps are decoupled.
🔍 Why students do this: Lose track of the dt unit conversion — the simulation clock advances by P.dt ms per step, not by 1 ms per step.
§ 05 References for Misconceptions & Errors