Help with NetCon
Posted: Sat Jul 07, 2012 7:24 am
hello ,
I am trying to connect 3 neurons with synapses. My code looks like
I'm constantly getting syntax error at the line marked in red..I tried many combinations but nothing seems to be working. Could someone suggest if there might be something important that I'm missing out on?
Regards,
Priti
I am trying to connect 3 neurons with synapses. My code looks like
Code: Select all
create neuron[3]
// create standard hh neurons
proc NeuronGeometry(){ local i,dlamda,n
if(numarg()!=2){
print "Create neurons with cell length(um),cell diameter(um)"
return
}
// create standard hh neurons
for(i=0; i<3; i+=1){
access neuron[i]
cm = 1
Ra = 35.4
L = $1
diam = $2
insert hh
ena = 50
ek = -77
gnabar_hh = 0.12
gkbar_hh = 0.036
gl_hh = 0.0003
el_hh = -54.3
dlamda = lambda(Ra,1.0/gl_hh,diam)/50
n= L/dlamda
n = int(n/2)*2+1
nseg=n
}
}
// adding synapses in each neuron
maxsyn = 3
objectvar syn[maxsyn], nclist, netcon
nclist = new List()
//adding synapse to the postsynaptic neuron
neuron[1] syn[0] = new ExpSyn(0)
section netcon = new NetCon(&v(1), syn[0], -20, 1, 0.5)
//defining the presynaptic cell as neuron 0 and adding it to the list of post-synaptic neuron 1
[color=#FF0000]neuron[0] neuron[1].nclist.append(netcon))[/color]
NeuronGeometry(5000,25)
Regards,
Priti