Why is the current represented as a function vs. a given value? I am trying to solve the H-H equations that he did in this simulation, and have no problems execpt for understanding why Current is not a given value. I want someone to go to the demonstrations page a look up the the program at the Demonstrations site page and look at the code. I also just tired putting in the code. Here is the code, I finally found a way to post it, I hope. The line that is I do not understand is starts with this
Istim . Why is not a consant. The way I look at it, is the neuron fired a current (just one current) to the axon.
GK = 36; GNa = 120; VL = 10.6;
alpham[V_] := (0.1 (25 - V))/(Exp[(25 - V)/10] - 1);
betam[V_] := 4 Exp[-V/18];
alphan[V_] := (0.01 (10 - V))/(Exp[(10 - V)/10] - 1);
betan[V_] := 0.125 Exp[-V/80];
alphah[V_] := 0.07 Exp[-V/20];
betah[V_] := 1/(Exp[(30 - V)/10] + 1);
gNa[t_] := ((m[t])^3) h[t];
gK[t_] := (n[t])^4;
Istim[t_, duration_, strength_] := If[0 < t < 100, strength, 0];
Manipulate[
Show[
Plot[
Evaluate[
V[t] /. NDSolve[{V'[t] ==
1/Cm (Istim[t, duration,
strength] - ((GNa) gNa[t] (V[t] - VNa)) - ((GK) gK[
t] (V[t] - VK)) - ((GL) (V[t] - VL))),
m'[t] == (alpham[V[t]] (1 - m[t])) - (betam[V[t]] m[t]),
n'[t] == (alphan[V[t]] (1 - n[t])) - (betan[V[t]] n[t]),
h'[t] == (alphah[V[t]] (1 - h[t])) - (betah[V[t]] h[t]),
V[0] == -0.0741, m[0] == 0.0525, n[0] == 0.3183,
h[0] == 0.588}, {V, m, n, h}, {t, 0, 80},
MaxSteps -> 100000]],
{t, 0, 60}, PlotRange -> {-20, (VNa + 10)}, AspectRatio -> 1,
PlotLabel -> "membrane voltage versus time",
AxesLabel -> {"time (msec)", "membrane voltage (mV)"},
ImageSize -> {550, 300}, PlotStyle -> {Thickness[.015], Blue}],
Graphics[{Thickness[0.008], Dashed, Red,
Line[{{0, VNa}, {60, VNa}}], Line[{{0, VK}, {60, VK}}]}]],
{{strength, 6.3, "applied current"}, 0, 18,
Appearance -> "Labeled"},
{{VNa, 115, "sodium equilibrium potential"}, 110, 150,
Appearance -> "Labeled"},
{{VK, -12, "potassium equilibrium potential"}, -15, 5,
Appearance -> "Labeled"},
Delimiter,
{{Cm, 1, "membrane capacitance"}, {1, 10^-2.99}, Checkbox},
{{GL, 0.3, "leakage channel conductance"}, {0.3, 0}, Checkbox},
SaveDefinitions -> True]