• We are sorry, but NCBI web applications do not support your browser and may not function properly. More information
Logo of nihpaAbout Author manuscriptsSubmit a manuscriptNIH Public Access; Author Manuscript; Accepted for publication in peer reviewed journal;
Phys Rev E Stat Nonlin Soft Matter Phys. Author manuscript; available in PMC Jul 21, 2009.
Published in final edited form as:
Phys Rev E Stat Nonlin Soft Matter Phys. Apr 2009; 79(4 Pt 1): 040901.
Published online Apr 13, 2009.
PMCID: PMC2713719

Tracking and control of neuronal Hodgkin-Huxley dynamics


Nonlinear ensemble state estimation offers a paradigm-shifting improvement in our ability to observe, predict, and control the state of spiking neuronal systems. We use an ensemble Kalman filter to predict hidden states and future trajectories in the Hodgkin-Huxley equations, reconstruct ion dynamics, control neuronal activity including a strategy for dynamic conductance clamping, and show the feasibility of controlling pathological cellular activity such as seizures.

In 1952, Hodgkin and Huxley [1] created a set of equations which modeled the dynamics of ion current flow across the neuronal membrane, which formed the foundation for our understanding of the excitable dynamics of nonlinear action potential wave propagation in neurons [2]. Hodgkin and Huxley (HH) based their formulation on experiments that used voltage clamp, a proportional feedback system that delivered current to the interior of a neuron to maintain the transmembrane potential at a given value [3]. The transient dynamics that resulted from such step changes in membrane potential are reflected in the HH equations. More recently, dynamic clamp techniques have introduced the manipulation of a conductance by adjusting the amount of current injected into a neuron while measuring membrane potential [4].

However, despite the existence of this multivariable ionic model for neuronal spiking, neuronal activity is almost always measured through observing just a single variable such as voltage (or calcium, using optical techniques). Such measurements are always uncertain, due to a combination of noise in neurons and amplifiers, as well as uncertainties in recording equipment such as electrode access resistance and capacitance. The introduction of ensemble [5] or unscented [6,7] Kalman filtering (UKF) has enabled the prospect of efficient state estimation of noisy systems with the degree of nonlinearity present in neurons [8]. UKF has recently been extended to tracking spatiotemporal neuronal networks [9]. These works demonstrated such control theory frameworks only on reduced dynamical models of neurons [8,9]. To our knowledge, no one has applied such model-based control theory to reconstruct the full ionic dynamics of neurons.

We here demonstrate that a nonlinear ensemble Kalman filter framework can assimilate neuronal data from single voltage measurements alone and reconstruct the full HH ionic dynamics. We further demonstrate that such a strategy can reconstruct additional extracellular ionic dynamics, which are critical in defining the stability and pattern formation of neuronal networks [10]. We show the ability to measure nonvoltage variables from which reconstructions of the unobserved voltage dependent variables and parameters can be performed, and also introduce a strategy for dynamic conductance clamping. Lastly, we demonstrate the use of such a framework to control pathological seizure dynamics.

The transmembrane potential V of a single neuron, normalized to zero in the resting state, is modeled with the HH equations [1]:


where e is the V measurement noise, n4 and m3h represent gating variables for potassium, IK, and sodium, INa, currents, and Il is the leak current. The rate equations for the gating variables are αn=(0.1−0.01V)/[exp(1−0.1V)−1], βn=0.125 exp(−V/80), αm=(2.5−0.1V)/[exp(2.5−0.1V)−1], βm=4 exp(−V/18), αh=0.07 exp(−V/20), and βh = 1/[exp(3−0.1V) + 1].

Recently [10], we have shown that extracellular potassium dynamics, [K]o, can be represented in a model based on IK, activity of the pump exchanging K+ and Na+, Ipump, diffusion of potassium to the microenvironment, Idiff, and glial buffering, Iglia [Fig. 1(a)],


where eK is the [K]o measurement noise, Ipump=Imax/[1+exp(8−[K]o)], Idiff=κ([K]oko,∞), Iglia=Gglia/{1+exp[(18−[K]o)/2.5]}. The potassium and leak reversal potentials are updated based on the instantaneous [K]o using the Nernst equations,


We consider a spherical cell with a radius of 13 μm and parameters given in [22]. We set K+ in the nearby infinite reservoir (bath solution in a slice preparation, or vasculature in the intact brain) ko,∞=4.0 mM, and intra- to extracellular volume ratio β=7 [11].

FIG. 1
(Color online)(a) A schematic of the model dynamics: the cell releases K+ through IK, which is either pumped back into the cell through K+-Na+ exchange pumps or buffered by the glia from the extracellular region. K+ can also diffuse to the nearby reservoir ...

The UKF approximates the a posteriori probability density of the estimated state by a Gaussian distribution, and propagates the estimated system state mean and covariance by specifying an ensemble of points that characterize the state variability—sigma points (σ). Given a function F describing the dynamics of the system [Eqs. (1)(3)], and observation function W contaminated by uncertainty characterized by the covariance matrix R, for a D-dimensional estimated state [x with macron] the UKF generates the 2D sigma points X1, ... ,X2D which are the 2D columns of the matrix x±DP, where P is the estimated covariance matrix of the state x. Increasing the number of sigma points increases accuracy but reduces efficiency [6]. Applying one step of the dynamics F to the sigma points, Xi=F(Xi), and denoting the observations of the new states by i=W(Xi), we define the means x~=(12D)Σi=12DX~i,y~=(12D)Σi=12DY~i, where x and are the a priori state and measurement estimates, respectively. Now define the a priori covariances P~xx=(12D)Σi=12D(X~ix~)(X~ix~)T,P~xy=(12D)Σi=12D(X~ix~)(Y~iy~)T, and P~yy=(12D)Σi=12D(Y~iy~)(Y~iy~)T of the ensemble members. The Kalman filter estimates of the new state and uncertainty are given by the a posteriori quantities x̂=x+K(y) and Pxx=PxxKPxx, where K=P~xyP~yy1 is the Kalman gain matrix and y is the actual observation (see [79]). Thus x̂ and Pxx are the updated estimated state x and covariance P for the next step. The a posteriori estimate of the observation ŷ is recovered by ŷ=W(x̂). Thus, by augmenting the observed state variables with unobserved state variables and system parameters, UKF can estimate and track both unobserved variables and system parameters. Although there are more sophisticated methods to explicitly account for model inadequacy [12], we here minimize model inadequacy by carefully choosing the process noise added to state x.

In contrast with recent work on reduced models [8,9], we seek to reconstruct the full HH ionic dynamics using noisy voltage measurements. Conversely, we wish to employ [K]o measurements to reconstruct voltage and other gating variables and parameters. We want to generate control signals based on the measured and estimated variables while at the same time optimizing the energy requirements.

As a first example we use the original HH model [Eq. (1)] to demonstrate that all variables and parameters can be reconstructed from the measurements of a single variable (Fig. 1). In Fig. 1(b) we show the voltage measurements while the estimated gating variables m, h, and n are shown in Figs. 1(c)–1(e). We also tracked the three current conductances gNa, gK, and gl in Figs. 1(f)–1(h), respectively.

To illustrate the power of this technique under significant model inadequacy [12], we set αm constant, and track it as a parameter rather than a function of V (with trivial dynamics as in [8]) in Figs. 1(i) and 1(j). Although this model by itself is incapable of spiking (black traces), when the data from Fig. 1(b) are assimilated, the UKF framework reconstructs spiking sufficiently well to track the dynamics [dark gray (blue) traces]. This αm tracked by UKF is within 20−30% root mean square (time step dependent) of the full functional form of αm, and is sufficiently close to enable the generation of spike dynamics. A universal need in neuroscience is to be able to track and control systems with incomplete knowledge of the underlying equations [12].

We next add a variable [K]o parameter to the HH equations. Thus our function F now consists of Eqs. (1) and (3). In Fig. 2 we show the measured membrane potential (top) and the estimated [K]o (bottom). The filter does a very good job in tracking this additional parameter. All other gating variables and parameters can be estimated and tracked along with [K]o (not shown).

FIG. 2
(Color online) Tracking a variable parameter [K]o given as [K]o=3.5+6{exp[−(t−100)2/2c2]+exp[−(t−350)2/2c2] +exp[−(t−600)2/2c2]}, c=65. Measured V (top) and estimated [K]o (bottom) in dark gray (blue), true ...

We followed the strategy of [9] to estimate a control vector [Fig. 3(a)]. In the left panel we show direct proportional control, where control signal c is generated from the noisy measurement y, which is generated by adding noise e to observation variable b following application of observation function W. In the right panel we show Kalman observer control, where the model observer system is used to generate the control vector from the estimated observable ŷ. In both schemes the control vector is applied to both the system and observer. In Fig. 3(b) we demonstrate use of voltage measurements (top) to control the dynamics of the cell. The extracted Na+ channel gating variable m is shown in the middle panel. As is clear from the bottom panel, the energy required for the control vector estimation through Kalman observer control is smaller than that used in direct proportional control. In fact, the energy requirements for direct proportional control relative to the energy requirements for Kalman observer control increases exponentially with increased noise in the measurements (inset right bottom), although beyond a certain limit the direct proportional controller becomes unstable (not shown).

FIG. 3
(Color online)(a) Schematic of Kalman filter observer. System function F acts upon state variable x, and observation function W produces output vector b. Output observable y is generated by adding measurement noise e to b. In the left panel the control ...

Since we can estimate the gating variables and parameters along with [K]o, it is possible to construct control signals based on the estimated gating variables. Such a control framework offers a novel means to modulate neuronal dynamics through various conductances using dynamic clamp [4]. In Fig. 4(a) we show a dynamic clamp simulation where seizure-like activity is controlled through gK. In previous dynamic clamp methods, the current corresponding to a given ion species, Ii, is calculated in isolation from the relation Ii=gi(VVi), where gi is the voltage-dependent conductance, and Vi is the reversal potential for an ion species i [4]. In the bottom panel we show [K]o estimated by the filter. Our state estimation framework has an advantage over this previous methodology in that the current to be injected into the cell to modulate a conductance can be calculated from more complete dynamical descriptions of conductance and gating parameters [from Eqs. (1)(3)], combined with an optimal strategy for handling model and measurement uncertainty, which, heightened by computational constraints, are major issues in applying dynamic clamp [13].

FIG. 4
(Color online) Single cell seizures controlled through gK (a), V (b), and [K]o (c). In (a) top panel shows V measurements with [light gray (orange)] and without [dark gray (blue)] control. At t=500 ms, gK is doubled using dynamic conductance clamp, which ...

In Fig. 4(b) we use V measurements to control seizurelike events by applying the control signal to V (top). Such control strategy can be employed experimentally by controlling seizures using an adaptive electric field [14]. Here we place a frequency gate on the filter, tuning the filter such that it applies the control signal only when the frequency of measured or estimated neuronal spiking goes above a certain value (50 Hz). The frequency gate (50 Hz) in the filter allows the controller to modulate only the high-frequency spiking attributed to seizurelike behavior, while allowing the neurons to perform their more normal (low-frequency) functions. This not only minimizes the energy requirements by shutting the controller off when not needed, but can also minimize the long-term damage to brain tissue due to continuous electrical stimulation.

There is considerable evidence relating increased [K]o to the abnormal patterns of activity during epilepsy and spreading depression [15]. The relatively small extracellular space causes a small IK to generate moderate changes in [K]o, which enhances the membrane excitability significantly by changing the reversal potentials for K+ channels. Recent work has explored the bifurcation dynamics of K+ in single cells and the influence of K+ on network stability [10].

We therefore reconstruct neuronal dynamics including V based on [K]o measurements. In the top panel of Fig. 4(c) we show [K]o measurements, and apply K+ control at t=250 ms. Driving [K]o to lower levels causes the seizure-like burst firing in V to go to silence (bottom). Controlling seizures with [K]o has two major advantages: (1) the time scale for [K]o is slower than the fast dynamics of V and gating variables, and hence can be more easily implemented in real time, and (2) the [K]o controller allows us to control the neuronal network rather than a single cell. It has been shown, using ion-selective microelectrodes to measure K+ activity changes in extracellular space that electrical current could be used to decrease or increase [K]o [16]. A recent theoretical study [17] predicts a functional block along axons due to K+ accumulation in the extracellular (submyelinated) space during deep brain stimulation. Recent optical techniques offer the prospect of increasing the speed and decreasing the scale of [K]o measurements [18].

In conclusion, we have laid the foundation for the framework of model-based data assimilation and control for spiking neuronal systems based on the foundational HH ionic model. This framework has a wide range of potential applications to various systems in biology, where one can use a single measured variable to estimate the variables and parameters that are experimentally inaccessible, and allows us to predict the system trajectory. Examples of similar nonlinearities include the spiking dynamics of heart cells, or the insulin-secreting cells in the pancreas. The prospect of employing our framework in dynamic conductance clamp offers possibilities of addressing the well-known limitations of this technique [4,13]: the need to reconstruct spatial dynamics from point measurements, the need to account for signal transduction analyte concentration changes (such as calcium), and of course the ubiquitous need to account for errors in measurements, modeling, and discrete computation.


This work was supported by NIH Grants No. R01MH50006 and No. K02MH01493, the Pennsylvania Keystone Innovation Zone Program and Tobacco Settlement.


1. Hodgkin AL, Huxley A. J. Physiol. (London) 1952;117:500. [PMC free article] [PubMed]
2. Izhikevich EM. Dynamical Systems in Neuroscience: The Geometry of Excitability and Bursting. MIT Press; Cambridge, MA: 2005.
3. Cole KS. Membranes, Ions and Impulses. University of California Press; Berkeley: 1972.
4. Goaillard JM, Marder E. Physiologie. 2006;21:197. [PubMed]Prinz AA, et al. Trends Neurosci. 2004;27:218. [PubMed]
5. Evensen G. J. Geophys. Res. 1994;99:10143.
6. Julier SJ, Uhlmann JK. Proc. SPIE. 1997;3068:110.
7. Simon D. Optimal State Estimation. Wiley-Interscience; New York: 2006.
8. Voss HU, Timmer J. Int. J. Bifurcation Chaos Appl. Sci. Eng. 2004;14:1905.
9. Schiff SJ, Sauer T. J. Neural Eng. 2008;5:1. [PMC free article] [PubMed]
10. Cressman J, et al. J. Comput. Neurosci. 2009;26:159. [PubMed]Ullah G, et al. J. Comput. Neurosci. 2009;26:171. [PubMed]
11. McBain CJ, et al. Science. 1990;249:674. [PubMed]
12. Toth Z, Pena M. Physica D. 2007;230:146.Baek S, et al. Tellus, Ser. A. 2006;58:293.
13. Bettencourt JC, et al. J. Neurosci. Methods. 2008;169:282. [PubMed]Butera RJ, McCarthy ML. J. Neural Eng. 2004;1:187. [PubMed]Raikov I, et al. J. Neurosci. Methods. 2004;132:109. [PubMed]
14. Gluckman BJ, et al. J. Neurosci. 2001;15:590. [PubMed]
15. Kager H, et al. J. Comput. Neurosci. 2007;22:105. [PubMed]Konnerth A, et al. Nature. 1984;307:69. [PubMed]
16. Gardner AR, Nicholson C. J. Physiol. (London) 1983;335:375. [PMC free article] [PubMed]
17. Bellinger SC, et al. J. Neural Eng. 2008;5:263. [PubMed]
18. Montana V, et al. Biochemistry. 1989;28:4536. [PubMed]Brasuel M, et al. Anal. Chem. 2001;73:2221. [PubMed]
19. Bazhenov M, et al. J. Neurophysiol. 2004;92:1116. [PMC free article] [PubMed]
20. Fisher RS, et al. Brain Res. 1976;101:223. [PubMed]
21. Scharrer E. Q. Rev. Biol. 1944;19:308.
22. Membrane capacitance Cm = 1 μF/cm2; maximum conductances (mS/cm2) gNa = 120, gK = 36, gl = 0.3; sodium reversal VNa = 115 mV; ion concentrations (mM) intracellular [K]i = 130, extracellular [Na]o = 130, intracellular [Na]i = 20, extracellular [Cl]o = 130, intracellular [Cl]i = 8 [19]; maximum pump flux Imax = 0.1 mM/s; and glial buffer strength Gglia = 100 mM/s. Diffusion coefficient of [K]o to the nearby reservoir κ, from Fick's law, is κ=2Dx2 = 4.0 s−1, where D = 400 × 10−6 cm2/s is K+ diffusion constant in neocortex [20] and Δx ≈ 15 μm for brain reflecting average distance between capillaries [21]. The factor 0.165 mM cm2/μC in Eq. (2) converts ionic current to concentration rate of change and is calculated using βA/FV [10], where A, V, and F represent cell area, volume, and Faraday constant, respectively.
PubReader format: click here to try


Related citations in PubMed

See reviews...See all...

Cited by other articles in PMC

See all...


  • Compound
    PubChem Compound links
  • PubMed
    PubMed citations for these articles
  • Substance
    PubChem Substance links

Recent Activity

Your browsing activity is empty.

Activity recording is turned off.

Turn recording back on

See more...