We summarize a workflow to computationally model a retinal neuron’s behaviors in response to electrical stimulation. The computational model is versatile and includes automation steps that are useful in simulating a range of physiological scenarios and anticipating the outcomes of future in vivo/in vitro studies.
Computational modeling has become an increasingly important method in neural engineering due to its capacity to predict behaviors of in vivo and in vitro systems. This has the key advantage of minimizing the number of animals required in a given study by providing an often very precise prediction of physiological outcomes. In the field of visual prosthesis, computational modeling has an array of practical applications, including informing the design of an implantable electrode array and prediction of visual percepts that may be elicited through the delivery of electrical impulses from the said array. Some models described in the literature combine a three-dimensional (3D) morphology to compute the electric field and a cable model of the neuron or neural network of interest. To increase the accessibility of this two-step method to researchers who may have limited prior experience in computational modeling, we provide a video of the fundamental approaches to be taken in order to construct a computational model and utilize it in predicting the physiological and psychophysical outcomes of stimulation protocols deployed via a visual prosthesis. The guide comprises the steps to build a 3D model in a finite element modeling (FEM) software, the construction of a retinal ganglion cell model in a multi-compartmental neuron computational software, followed by the amalgamation of the two. A finite element modeling software to numerically solve physical equations would be used to solve electric field distribution in the electrical stimulations of tissue. Then, specialized software to simulate the electrical activities of a neural cell or network was used. To follow this tutorial, familiarity with the working principle of a neuroprosthesis, as well as neurophysiological concepts (e.g., action potential mechanism and an understanding of the Hodgkin-Huxley model), would be required.
Visual neuroprostheses are a group of devices that deliver stimulations (electrical, light, etc.) to the neural cells in the visual pathway to create phosphenes or sensation of seeing the light. It is a treatment strategy that has been in clinical use for almost a decade for people with permanent blindness caused by degenerative retinal diseases. Typically, a complete system would include an external camera that captures the visual information around the user, a power supply and computing unit to process and translate the image to a series of electrical pulses, and an implanted electrode array that interfaces the neural tissue and deliver the electrical pulses to the neural cells. The working principle allows a visual neuroprosthesis to be placed in different sites along the visual pathway from the retina to the visual cortex, as long as it is downstream from the damaged tissue. A majority of current research in visual neuroprostheses focuses on increasing the efficacy of the stimulation and improving the spatial acuity to provide a more natural vision.
In the efforts to improve the efficacy of the stimulation, computational modeling has been a cost- and time-effective method to validate a prosthesis design and simulate its visual outcome. Computational modeling in this field gained popularity since 1999 as Greenberg1 modeled the response of a retinal ganglion cell to extracellular electrical stimuli. Since then, computational modeling has been used to optimize the parameters of the electrical pulse2,3 or the geometrical design of the electrode4,5. Despite the variation in complexity and research questions, these models work by determining the electrical voltage distribution in the medium (e.g., neural tissue) and estimating the electrical response that the neurons in the vicinity will produce due to the electrical voltage.
The electrical voltage distribution in a conductor can be found by solving the Poisson equations6 at all locations:
where E is the electric field, V the electric potential, J the current density, and σ is the electrical conductivity. The in the equation indicates a gradient operator. In the case of stationary current, the following boundary conditions are imposed on the model:
where n is the normal to the surface, Ω represents the boundary, and I0 represents the specific current. Together, they create electrical insulation at the external boundaries and create a current source for a selected boundary. If we assume a monopolar point source in a homogeneous medium with an isotropic conductivity, the extracellular electric potential at an arbitrary location can be calculated by7:
where Ie is the current and is the distance between the electrode and the point of measurement. When the medium is inhomogeneous or anisotropic, or the electrode array has multiple electrodes, a computational suite to numerically solve the equations can be convenient. A finite-element modeling software6 breaks up the volume conductor into small sections known as 'elements'. The elements are interconnected with each other such that the effects of change in one element influence change in others, and it solves the physical equations that serve to describe these elements. With the increasing computational speed of modern computers, this process can be completed within seconds. Once the electric potential is calculated, one can then estimate the electrical response of the neuron.
A neuron sends and receives information in the form of electrical signals. Such signals come in two forms – graded potentials and action potentials. Graded potentials are temporary changes to the membrane potential wherein the voltage across the membrane becomes more positive (depolarization) or negative (hyperpolarization). Graded potentials typically have localized effects. In cells that produce them, action potentials are all-or-nothing responses that can travel long distances along the length of an axon. Both graded and action potentials are sensitive to the electrical as well as the chemical environment. An action potential spike can be produced by various neuronal cell types, including the retinal ganglion cells, when a threshold transmembrane potential is crossed. The action potential spiking and propagation then trigger synaptic transmission of signals to downstream neurons. A neuron can be modeled as a cable that is divided into cylindrical segments, where each segment has capacitance and resistance due to the lipid bilayer membrane8. A neuron computational programme9 can estimate the electrical activity of an electrically-excitable cell by discretizing the cell into multiple compartments and solving the mathematical model10:
In this equation, Cm is the membrane capacitance, Ve,n is the extracellular potential at node n, Vi,n the intracellular potential at node n, Rn the intracellular (longitudinal) resistance at node n, and Iion is the ionic current going through the ion channels at node n. The values of V from the FEM model are implemented as Ve,n for all nodes in the neuron when the stimulation is active.
The transmembrane currents from ion channels can be modeled by using Hodgkin-Huxley formulations11:
where gi is the specific conductance of the channel, Vm the transmembrane potential (Vi,n – Ve,n) and Eion the reversal potential of the ion channel. For voltage-gated channels, such as Na channel, dimensionless parameters, m, and h, that describe the probability of opening or closing of the channels are introduced:
where is the maximum membrane conductance for the particular ion channel, and the values of parameters m and h are defined by differential equations:
where αx and βx are voltage-dependent functions that define the rate constants of the ion channel. They generally take the form:
The values of the parameters in these equations, including maximal conductance, as well as the constants A, B, C, and D, were typically found from empirical measurements.
With these building blocks, models of different complexities can be built by following the steps described. An FEM software is useful when the Poisson equation cannot be solved analytically, such as in the case of inhomogeneous or anisotropic conductance in the volume conductor or when the geometry of the electrode array is complex. After the extracellular potential values have been solved, the neuron cable model can then be numerically solved in the neuron computational software. Combining the two software enables the computation of a complex neuron cell or network to a non-uniform electric field.
A simple two-step model of a retinal ganglion cell under a suprachoroidal stimulation will be built using the aforementioned programs. In this study, the retinal ganglion cell will be subjected to a range of magnitudes of electrical current pulses. The location of the cell relative to the stimulus is also varied to show the distance-threshold relationship. Moreover, the study includes a validation of the computational result against an in vivo study of the cortical activation threshold using different sizes of stimulation electrode12, as well as an in vitro study showing the relationship between the electrode-neuron distance and the activation threshold13.
1. Setting up the finite element model for electric potential calculations
Figure 1: Creating the tisssue geometry. A block geometry was inserted into the FEM model to represent the tissue. Please click here to view a larger version of this figure.
Figure 2: Creating the electrode's geometry. (A) Making a work plane to draw the disk electrode. (B) Sketching a circle on a work plane to create a disk electrode. Please click here to view a larger version of this figure.
Figure 3: The element quality histogram of the FEM model. The histogram showed the quality of the elements throughout the model. Mesh refinements are needed if a significant portion of the elements are in the low quality region. Please click here to view a larger version of this figure.
Figure 4: Assigning a current value to the electrode. A unitary current applied to the electrode's geometry in the FEM software. Please click here to view a larger version of this figure.
2. Importing the geometry of the neural cell in the neuron computational suite's GUI
Figure 5: Exporting the neuron model information as a .hoc file. The geometry of the neuron was exported to a .hoc file to allow further modifications. Please click here to view a larger version of this figure.
Figure 6: Measuring the dimension of the neuron. The morphology of the neuron (top view) was displayed in the GUI of the neuron computational suite with the x-y axes superimposed. The scale was in µm. Please click here to view a larger version of this figure.
3. Programming the NEURON computation simulation
4. Running and automating multiple simulations
Figure 7: Displaying and exporting the FEM computation results to a text file. The Graphics window showing a Multislice plot of the electric potential in V. The options in the Data Export Setting allowed exporting the calculated variable into a text file. Please click here to view a larger version of this figure.
Figure 8: Displaying the graph of the transmembrane potential using a voltage graph. The neuron transmembrane potential was displayed in the GUI of the neuron computational suite. The x-axis is time in ms, while the y-axis is the transmembrane potential of the chosen neuron segment in mV. Please click here to view a larger version of this figure.
We conducted two simulation protocols to demonstrate the use of the model. The first protocol involved varying the electrode size while keeping the location of the neuron and the electrical pulse parameters the same. The second protocol involved shifting the neuron in the x-direction in 100 µm steps, while the size of the electrode remained constant. For both protocols, the pulse used was a single cathodic-first biphasic pulse of 0.25 ms width with a 0.05 ms interphase gap. For the first protocol, the radius of the electrode was varied to be 50, 150, 350, and 500 µm, while for the second protocol, the radius of the electrode was kept at a constant 50 µm.
The model described here showed that increasing the suprachoroidal electrode size at 0.25 ms pulse width increased the activation threshold of the model neuron (Figure 9A). This result reflected the in vivo findings from Liang et al.12, who showed that the cortical activation threshold increases with the increasing electrode size at this pulse width.
The magnitudes of the model's activation thresholds differ from the empirical findings because of several factors. Firstly, this model only involves a single RGC of a specific type, which may not be present in the group of cells being activated in the in vivo study. Next, this model did not include a retinal network, which may facilitate the activation of RGCs through excitatory inputs from the bipolar cells. Another possible reason for the discrepancy is the electrode-retina distance. It is possible that the electrode-retina distance in the in vivo study was lower than in this model due to anatomical variability or the surgery. Consequently, we overestimated the electrode-retina distance and thus the activation threshold. It is also important to note that, although this was not demonstrated in our results, modeling a single cell threshold would often underestimate the in vivo cortical threshold. This is due to the technical limitations in cortical measurements (primarily relating to the signal-to-noise ratio) that the cortical activity is typically only detected after multiple retinal ganglion cells have been activated. As a result, a discrepancy in the magnitude of the retinal and cortical activation thresholds is to be expected. Despite these differences, this model successfully showed the increasing trend of the activation threshold due to the increase in the electrode size. This resulted from the absence of an area of high electric field compared to its surroundings when the electrode size is increased, which did not favor neural activation22.
Next, we observed the action potential characteristics to validate the model described here. The latency, or the time between the stimulus onset and the peak of the action potential spike, ranged from 1-2.2 ms (Figure 9B). This corresponded to the short-latency spiking due to non-network mediated retinal activation23. The spike width of this model was 1 ms, and this is in the same range as the spike widths of rabbit RGCs measured in vitro24.
In the second stimulation protocol, only the location of the neuron in the x-axis (along the axon's length) relative to the electrode was varied. At a distance 0, the centroid of the soma section was immediately above the center of the disk electrode. Negative distance means that the disk electrode was positioned closer to the axonal side, while positive distance means that the disk electrode was positioned closer to the dendritic side. The model showed that the lowest threshold was achieved when the narrow segment of the axon was immediately above the disk electrode, and it increased as the x-distance became larger (Figure 9C). Moving the electrode further toward the distal axon produced a lower threshold as compared to moving the electrode toward the dendrites due to the presence of the axon initial segment and the narrow segment where the sodium channels are more prevalent. This result agreed with the in vitro finding from Jensen et al.13, where rabbit RGCs were stimulated with an ultrafine microelectrode, and the activation threshold was the highest when the electrode was shifted closer to the dendrites.
Figure 9: The results of the modeling method. (A) The activation thresholds for a retinal ganglion cell located above the disk electrode. The electrode radius was varied (50, 150, 350, and 500 µm) and the threshold increased with increasing electrode size. (B) The neuron model's action potential shape at 0.25 ms pulse width. The action potentials at threshold for different electrode sizes have the same spike width of 1 ms, but the latency increased with increasing electrode size. The stimulus onset time was 1 ms and the cathodic phase caused a depolarization at the membrane but not enough to cause an action potential. (C) The neuron was shifted along the x-axis and the thresholds of activation showed that the lowest threshold was achieved by the neuron whose soma was located right above the center of the electrode. The radius of the electrode was 50 µm. Please click here to view a larger version of this figure.
Supplementary Figure 1: Initialization of the finite element model. The types of Study and Physics determine the list of equations solved in the model. These were set during the initial creation of the FEM model file, but can also be modified/added after the model has been created. Please click here to download this File.
Supplementary Figure 2: Changing the unit of length. The length unit and angular unit determine the units used in the geometry definition process. Please click here to download this File.
Supplementary Figure 3: Inserting a material property. The material properties were defined for each domain in a 3D model. The available material properties were listed in the Material Properties in the Material Setting window. For the electric potential calculation, only the Electrical Conductivity property was defined. Please click here to download this File.
Supplementary Figure 4: Creating a parametric study to loop over a list of parameter values. A parametric study allowed the FEM software to automatically repeat the computations and change the electrode radius value for each repeat. The calculation results were stored for each repeat. Please click here to download this File.
Supplementary Figure 5: Importing the neuron morphology from the SWC file. The neuron computational suite was capable of reading SWC file acquired from neuronal tracing. The imported file contains information on the morphology and topology of each neuron segment. Please click here to download this File.
Supplementary Figure 6: Automating FEM operations by defining a method. A method was defined by writing a script to automate processes in the FEM software that cannot be done by defining a parametric study. Please click here to download this File.
Supplementary Figure 7: Integrating the models and automating the simulations using a general purpose programming language. The general purpose programming language was used to loop the neuron simulations, while changing the extracellular voltage file used as an input and the neural response voltage file as an output for each step in the loop. Please click here to download this File.
Supplementary Material: Command lines for (1) Defining a voltage-dependent Cat channel. (2) Voltage- and concentration-dependent ion channels. (3) Complete .mod file. (4) Creating a biphasic pulse in the neuron simulation. (5) Calculating the coordinate of each node. (6) Application of the biphasic pulse. (7) Executing the neuron simulation. (8) Looping over a range of current amplitudes. (9) Defining a method to automate FEM simulations. (10) Running the simulations in a general purpose programming language. Please click here to download this File.
In this paper, we have demonstrated a modeling workflow that combined finite element and biophysical neuron modeling. The model is highly flexible, as it can be modified in its complexity to fit different purposes, and it provides a way to validate the results against empirical findings. We also demonstrated how we parameterized the model to enable automation.
The two-step modeling method combines the advantages of using FEM and neuron computational suite to solve the neuron’s cable equation in the presence of an extracellular stimulation. An FEM is useful in accurately computing the extracellular field across the volume conductor, which often is impractical to solve analytically in the case of complex geometry or inhomogeneity of conductivity. The computational cost of this model is also relatively low, as a static condition is assumed.
While the described modeling method is advantageous in its ease of use and flexibility, there are limitations to this modeling workflow. Firstly, this method did not allow the presence of a neural membrane in calculating the electric field. Joucla et al.25 compared the two-step method to the whole FEM method, where the neural geometry and membrane properties were included in the FEM model. They showed that including the neuron in the electric field calculation would change the transmembrane potential calculation when a larger cell structure, such as a cell body, was included in the geometry. Specifically, the simplification of the neuron geometry in the two-step method means that the transmembrane potential of any point in a compartment is represented by the transmembrane potential at the node or the center point of the compartment. In contrast, the whole-FEM model proposed by Joucla included an explicit representation of the 3D geometry of the neuron, which enabled the individual evaluation of transmembrane potential on any point inside the compartment. Thus, the whole-FEM model might be more suitable if the exact shape and location of the transmembrane potential are needed. However, this method is computationally more expensive than the two-step method.
The second limitation of the modeling method concerns the availability of morphology and ion kinetics data. The model used here was based on the tiger salamander data, which has been used to model RGCs from other species, but there might have been differences in the types of ion channels present that have not been elucidated. Hence, it might be necessary in some cases to perform in vitro works to adjust the ion channel parameters.
Thirdly, the cost of the FEM software might be a constraint. In this case, an open-source FEM programme26 that has a built-in Poisson equations solver might be an alternative. Apart from the FEM software used, the software used in this workflow is free. While the FEM software used offers an intuitive GUI and a ready-to-use electric current modeling, it is possible to perform the extracellular value calculations in a general purpose programming software. However, this would necessitate manually defining the physical equations and the numerical methods to solve the equations27. Moreover, this method might be tedious when a complex tissue or electrode array geometry is to be used.
The authors have nothing to disclose.
This research is funded by The National Health and Medical Research Council Project Grant (Grant Number 1109056).
Computer workstation | N/A | N/A | Windows 64-bit operating system, at least 4GB of RAM, at least 3 GB of disk space |
Anaconda Python | Anaconda Inc. | Version 3.9 | The open source Individual Edition containing Python 3.9 and preinstalled packages to perform data manipulation, as well as Spyder Integrated Development Environment. It could be used to control the simulation, as well as to display and analyse the simulation data. |
COMSOL Multiphysics | COMSOL | Version 5.6 | The simulation suite to perform finite element modelling. The licence for the AC/DC module should be purchased. The Application Builder capability should be included in the licence to follow the automation tutorial. |
NEURON | NEURON | Version 8.0 | A freely-distributed software to perform the computation of neuronal cells and/or neural networks. |