I’m not too familiar with Brian2, so I apologise if this is a stupid question, but is it possible to excite a particular neuron only when another condition is true.
To be brief, I’ve got 5 neurons, neuron 0 is connected to neurons 1, 2, 3, 4
When there is an input voltage to neuron 0, I want it to excite neuron 1 if condition 1 is true, neuron 2 if condition 2 is true etc.
I apologise if this was an awful way to explain my problem, all I know is, I want the system to do a particular thing, but I don’t know how to do it.
lif = ''' dv/dt = -(gl * (v - vl) + ge * (v - ve) + gi *(ve - vi) - I)/c : volt dge/dt = -ge / ge_tau : siemens dgi/dt = -gi / gi_tau : siemens I : amp ''' ''' If neuron 0 has an input voltage AND cell0 = True, excite neuron 1 If neuron 0 has an input voltage AND cell1 = True, excite neuron 2 If neuron 0 has an input voltage AND cell2 = True, excite neuron 3 If neuron 0 has an input voltage AND cell3 = True, excite neuron 4 ''' # 1st to 2nd layer G = NeuronGroup(5, lif, threshold='v > -40*mV', reset='v = vl', refractory=3*ms, method='euler') G.I = [0.7, 0, 0, 0, 0]*nA # input current for 0, 1, 2, 3, 4 neurons, G.v = [-70, -70, -70, -70, -70]*mV # intial voltage for 0, 1, 2, 3, 4 neurons (resting V) # Se = excitory connection # Si = inhibitory connection Se = Synapses(G, G, on_pre='ge_post += w_ge') Se.connect(i=0, j=1) Se.connect(i=0, j=2) Se.connect(i=0, j=3) Se.connect(i=0, j=4)
I’ve looked through the documentation several times, but I cannot find something that answers my problem