I have a feeling this is a pretty simple one, but I'm having trouble with it. I'm implementing the Mainen and Senowski model layer V cell http://senselab.med.yale.edu/modeldb/sh ... model=2488. What I'd like to do is calculate the electric potential V_e(x,t) around the cell. My plan is:
1. At the start of simulation, print the xyz endpoints and surface area of all straight line segments.
2. At each time point, print the membrane current density for each segment.
I'm having problems with 1. Specifically, the xyz positions for the segment nodes are all output as identical, although the area and i_membrane changes between segments. I'm guessing I'm not using x3d() etc correctly. What am I doing wrong? My simple code and example output are below.
Code: Select all
forall for(x) {print secname(), x3d(x), y3d(x), z3d(x), area(x), i_membrane(x)}
...
dend1[2]33.085873 2.6565194 2.1262903 0 -0.00039796857
dend1[2]33.085873 2.6565194 2.1262903 275.99687 -0.00039796857
dend1[2]33.085873 2.6565194 2.1262903 245.31708 -0.001138171
dend1[2]33.085873 2.6565194 2.1262903 201.44638 -0.0020566937
dend1[2]33.085873 2.6565194 2.1262903 153.20219 -0.0032314412
dend1[2]33.085873 2.6565194 2.1262903 116.6775 -0.0043818951
dend1[2]32.499405 2.6565194 2.1262903 0 -0.0043818951
dend1[3]33.085873 2.6565194 2.1262903 0 -0.0003648783
dend1[3]33.085873 2.6565194 2.1262903 145.06896 -0.0003648783
dend1[3]33.085873 2.6565194 2.1262903 145.86006 -0.00098885899
dend1[3]36.483166 4.0154371 2.1262903 0 -0.00098885899
...