-
Notifications
You must be signed in to change notification settings - Fork 0
/
ic.mod
104 lines (66 loc) · 1.29 KB
/
ic.mod
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
: iC fast Ca2+/V-dependent K+ channel
NEURON {
SUFFIX iC
USEION k READ ki, ko WRITE ik
USEION ca READ cai
RANGE ik, gk, gkcbar
}
UNITS {
(mM) = (milli/liter)
(mA) = (milliamp)
(mV) = (millivolt)
}
INDEPENDENT {t FROM 0 TO 1 WITH 1 (ms)}
PARAMETER {
v (mV)
dt (ms)
cai (mM)
gkcbar= 0.0022 (mho/cm2)
}
STATE {
c
}
ASSIGNED {
ik (mA/cm2)
cinf
ctau (ms)
gk (mho/cm2)
ek (mV)
ki (mM)
ko (mM)
}
INITIAL {
rate()
c = cinf
}
BREAKPOINT {
SOLVE states METHOD cnexp
gk = gkcbar*c*c
ek = 25 * log(ko/ki)
ik = gk*(v-ek)
}
DERIVATIVE states {
rate()
c' = (cinf-c)/ctau
}
UNITSOFF
FUNCTION calf(v (mV), cai (mM)) (/ms) { LOCAL vs, va
vs=v+40*log10(1000*cai)
va=vs+18
if (fabs(va)<1e-04){ va=va+0.0001 }
calf = (-0.00642*vs-0.1152)/(-1+exp(-va/12))
}
FUNCTION cbet(v (mV), cai (mM))(/ms) { LOCAL vs, vb
vs=v+40*log10(cai*1000)
vb=vs+152
if (fabs(vb)<1e-04){ vb=vb+0.0001 }
cbet = 1.7*exp(-vb/30)
}
UNITSON
PROCEDURE rate() {LOCAL csum, ca, cb
ca=calf(v, cai) cb=cbet(v, cai)
csum = ca+cb
cinf = ca/csum
if ((1/csum)>1.1) { ctau = 1 / csum}
else { ctau = 1.1 }
}