The model of a synaptic depression I wrote means that my network model takes 105s to run (instead of 45s using the in-built ExpSyn). I appreciate that I'm asking NEURON to solve 4 exponential equations rather than just 1 for each synaptic mechanism; but if that was the sole cause of the increase (and the work load increase linearly with the number of exponents), that would mean that solving the expsyn mechanism was taking nearly half of the computational time in the original network (i.e. each exponential requires 20s). That seems hard to believe with all the huge number of computations that must be going on in the network. Is there some mistake I have made in this model that causes it's inclusion to be so deleterious to computational efficiency?
Code: Select all
NEURON {
POINT_PROCESS expi
NONSPECIFIC_CURRENT i
RANGE i, e, tau, kA, kB, kC, dec
}
PARAMETER {
e = 0 (millivolts)
tau = 4 (ms)
kA = 0.00017 (/ms)
kB = 0.012 (/ms)
kC = 0.05 (/ms)
dec = 0.6
}
STATE {
O
A
B
C
F
g
}
INITIAL {
A = 0
B = 0
C = 0
O = 1
g = 0
}
ASSIGNED {
v (millivolt)
i (nanoamp)
}
BREAKPOINT {
SOLVE state METHOD cnexp
F = A * 0.4 + B * 0.4 + C/3 * 0.2
O = 1 - F
i = g * (v - e)
}
DERIVATIVE state {
A' = -kA * A
B' = -kB * B
C' = -kC * C
g' = -g/tau
}
NET_RECEIVE(weight (microsiemens)) {
g = (g + weight) * O
O = O * O * dec
F = 1 - O
A = F
B = F
C = F
}