Page 1 of 1

Adding a spine correctly

Posted: Mon Dec 14, 2015 7:27 am
by MBeining
Hello,
if I want to add a spine with a neck of (for simplicity) 0.5 µm diameter and 2 µm length and a head of 1 µm diameter and length, I would naively use the following commands:

Code: Select all

create spine
pt3dclear()
pt3dadd(0,0,0,0.5)
pt3dadd(2,0,0,0.5)
pt3dadd(2,0,0,1)
pt3dadd(3,0,0,1)
The resulting area should be 2 * Pi, however area(0.5) (with nseg = 1) gives me 6.8722339.
I guess this is some problem of Neuron wanting to treat all information as frusta, but the problem is that I need to have the spine in NEURON having exactly the same surface area as calculated in Matlab, so any idea how I could do this correctly?

Thank you very much.

Re: Adding a spine correctly

Posted: Mon Dec 14, 2015 2:52 pm
by ted
The difference between 6.8722339 and 2*PI is indeed the area of a 1 cm diameter circle minus the area of a 0.5 cm diameter circle.

Do this instead:

Code: Select all

create neck, head
connect head(0), neck(1)
neck {
  pt3dclear()
  pt3dadd(0,0,0,0.5)
  pt3dadd(2,0,0,0.5)
}
head {
  pt3dclear()
  pt3dadd(0,0,0,1)
  pt3dadd(1,0,0,1)
}

Re: Adding a spine correctly

Posted: Tue Dec 15, 2015 2:34 am
by MBeining
That makes sense.
Thank you very much!