-
Notifications
You must be signed in to change notification settings - Fork 1
/
BS_morphology.hoc
76 lines (63 loc) · 1.58 KB
/
BS_morphology.hoc
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
/*
This file inits the ball-and-stick neuron model, i.e., a passive dendritic cable attached to a somatic compartment, exposed to an extracellular field.
*/
create soma, dend
// Soma
soma {
nseg = 1
diam = 10.0 // um
L = 10.0 // um
Ra = 200.0 // Ohm cm
cm = 1.5 // uF/cm2
}
soma insert pas
soma.g_pas = 1/30000.0 // S/cm2
soma.e_pas = -60.0 // mV - Reversal potential
soma insert extracellular
soma insert xtra
// Dendritic tree
dend.L = 700 // um
dend.diam = 1.2 // um
dend.Ra = 200 // Ohm cm
dend.cm = 1.5 // uF/cm2
dend insert pas
dend.g_pas = 1/30000.0 // S/cm2
dend.e_pas = -60.0 // mV - Reversal potential
dend.nseg = 50
// Connect the dendritic tree to the soma
connect dend(0), soma(0)
dend insert extracellular
dend insert xtra
// Sinusoidal simulation
objref fsin
dend fsin = new Fsin(0.5)
fsin.del = 100
fsin.amp = 10 // Amplitude in V/m
fsin.f = 10
fsin.n = 10
forall {
for (x,0) {
setpointer im_xtra(x), i_membrane(x)
setpointer ex_xtra(x), e_extracellular(x)
setpointer fsin.x, is_xtra
}
}
push_section("soma")
for (x,0) {
rx_xtra(x) = 0 * 1e-3 * 1e-6
}
pop_section()
push_section("dend")
for (x,0) {
// Transfer from E field to extracellular potential.
// 1e-6 since rx_xtra s in megaOhm and 1e3 since dend.L is in um and not mm
rx_xtra(x) = -x * dend.L * 1e-3 * 1e-6 // Megohm (mV/nA)
}
pop_section()
// Init the membrane potential
forall{
for (x) {
v(x) = -60 // (mV) Value of the initial potential
}
}
tstop = 500