Functions used by neuron

Anything that doesn't fit elsewhere.
Post Reply
ReneM
Posts: 1
Joined: Thu Feb 09, 2017 9:49 am

Functions used by neuron

Post by ReneM » Fri Mar 03, 2017 7:31 am

Dear all,

I am trying to translate an Infior Olive model described in NeuroML to C++.
The model is described at https://github.com/MRIO/oliveML and can only be executed with NEURON.
Therefore I use the output of NEURON as a reference. For simplicity in my model description in C++ I use the forward Euler method.
I know that the the forward Euler method can be instable and inaccurate, but I expect that with a small enough step size the results will be similar(not equal).

The part of the model which for sure gives different results is the current between the compartments of the soma and the dendrite.
Before going to the calculations I want to give some parameters which I expect may be important for the problem (I converted the lengths and diameters of micron to cm in my code).

RA_dendrite = RA_axon = 3 [ohm * cm]
RA_soma = 0.1 [ohm * cm]
l_dendrite = 1000 [micron]
d_dendrite = 1 [micron]
l_soma = 20 [micron]
d_soma = 40 [micron]
l_axon = 3 [micron]
dProximal_axon = 40 [micron]
dDistal_axon = 22 [micron]

The cell.hoc file shows:

Code: Select all

proc geom_nseg() {
    // All sections not mentioned here have nseg = 1
}

and therefore I expect each compartment to have only one segment.


I calculate the current between compartments x and y as follows:
I_xy = (V_x - V_y) / Ra_xy
I_yx = -I_xy

Where:
V_x = V_x(0.5) in NEURON description [mV] (same for y)
Ra_xy = 0.5 * (Ra_x + Ra_y) [Ohm]
Ra_x = (4 * length * RA_x) / (PI * d_x * d_x); (same for y) [Ohm]

I isolated this behaviour by removing all the ion channels of the compartments and only use the soma and the dendrite.
And on the soma a current source (I_clamp) is added to create a voltage difference between the two compartments
Meaning that:
dV_soma/dt = I_dendrite_soma + I_clamp / Cm_soma
dV_dendrite/dt = I_soma_dendrite / Cm_dendrite

Intermezzo:
Because all the compartments show the right voltage curve without currents between the compartments I expect Cm_x to be calculated correctly.

This results in the following plots (I hope you can see them because the preview doesn't show them)
NEURON:
Image
(url: https://github.com/ReneM92/oliveML/blob ... ntraDS.png)
C:
Image
(url: https://github.com/ReneM92/oliveML/blob ... ntraDS.png)

This shows that in NEURON the voltage of the dendrite follows the voltage of the soma, while in C++ this doesn't happen.
The reason why in C++ the voltage of the dendrite doesn't follow the voltage is because of the large value of Ra_dendrite.

In addition I also checked the behaviour with the soma and the axon (without ion channels).
Those results showed similar plots and the values when I_clamp was equal to 0 were exactly equal.

Could somebody tell me what is wrong with my formulas and what I need to change/fix to get similar results?

Post Reply