I am interested in the steady-state relationship.
The way to do this is to create a model that contains the mechanism you're interested in,
then execute this loop (which I have written in human-readable pseudocode):
Code: Select all
v = vstart
while (v<=vend) {
hold the model at v until all mechanisms reach steady state
measure the desired current
plot the current vs. v
increase v by (vend - vstart)/numsteps
}
Very easy to do for a distributed mechanism. Here's how.
Create a single compartment model and insert the mechanism.
Make sure that parameters have the desired values, e.g. channel density and reversal potential.
Bring up a Grapher
NEURON Main Menu / Graph / Grapher
This graphical tool can be used to implement the loop I wrote above.
If you click on its Plot button, it does the following (more pseudocode!):
Code: Select all
set "Independent Var" equal to "Indep Begin"
while ("Independent Var" <= "Indep End") {
execute the "Generator" statement
for every variable y in the Graph's plot list, plot a new point at coordinates
(X-expr, y)
increase "Independent Var" by ("Indep End" - "Indep Begin") / "Steps"
}
So use the Grapher's "Indep Begin" and "Indep End" to specify what I called vstart and vend.
Example: if you want v to go from -100 to 50 mV, Indep Begin should be -100, and
Indep End should be 50.
"Steps" is what I called numsteps above. This is 1 less than the number of points at
which you want to plot the current. For example, if v runs from -100 to 50 you'd want
Steps to be 150.
The Grapher comes up with t as its independent variable.
Click on the Grapher's "Independent Var" button and change this to v.
Notice that the X-expr (the x coordinate of the points that the Grapher will plot)
automatically changes to v. This is just what we want. Leave it alone.
Next, make sure that, at each new value of v, the Grapher will force the mechanism to its
steady state at that value of v. The way to do this is to use the standard run system's
finitialize(). So click on the Grapher's "Generator" button. This pops up a window that
asks for a Generator statement. Click in the window's edit field and type the following:
Be sure to type a space between finitialize(v) and fcurrent().
Calling finitialize(v) makes all voltage-gated mechanisms reach steady-state at that value
of membrane potential. Calling fcurrent() makes sure that all assigned variables, such as
currents, are computed from the new values of v and gating variables.
All that remains is to add the name of the current to the Graph's plot list. To do this, use
the Graph's Plot what? tool (click on the menu square, select Plot what?, then type the
name of the variable in the edit field, or browse the list of mechanisms and variables
until you have assembled the variable name). For example, to see the hh mechanism's
ina, double click on soma in the left column, then click on ina(0.5) in the middle column.
Or you could simply have typed ina(0.5) in the Plot what? tool's edit field. Click on the
Accept button, and the Plot what? tool will vanish and the current's name will appear
on the Grapher's canvas.
Now click on the Grapher's Plot button.
Use File / save session to save the whole thing to a ses file, for future re-use.
You can plot several different variables in a single Grapher, and you can have as many
different Graphers as you like, each one with its own plot list. They won't interfere with
each other. You can plot gating variables, ionic conductances, currents, or anything you
like.