Search found 5 matches

by yuzhou
Sat Sep 10, 2016 11:40 am
Forum: Other questions
Topic: Generate multiple files using loop statement
Replies: 3
Views: 3939

Re: Generate multiple files using loop statement

The code works if I move "objref savedata" before the loop block: strdef tname objref savedata for a=1,3 { printf("Simulation %d .\n", a) savedata = new File () sprint(tname, "file%d.dat", a) savedata.wopen(tname) savedata.printf(tname, "\n") savedata.close() } quit() Now the script generates three ...
by yuzhou
Fri Sep 09, 2016 5:19 pm
Forum: Other questions
Topic: Generate multiple files using loop statement
Replies: 3
Views: 3939

Generate multiple files using loop statement

Here's the hoc code strdef tname for a=1,3 { objref savedata savedata = new File() sprint(tname, "file%d.dat", a) savedata.wopen(tname) savedata.printf (tname, "\n") savedata.close() } Run this script in Nenuron and I got following information without any file generated: oc>load_file("temp.hoc") nrn...
by yuzhou
Tue Sep 06, 2016 11:10 am
Forum: Reaction-diffusion in NEURON
Topic: Intracellular potassium depletion
Replies: 2
Views: 8821

Re: Intracellular potassium depletion

Dear Ted,

Thank you so much for pointing out my mistakes on current unit and NMODL coding. Now the simulation works as expected.

Yu
by yuzhou
Sun Sep 04, 2016 12:26 am
Forum: Reaction-diffusion in NEURON
Topic: Intracellular potassium depletion
Replies: 2
Views: 8821

Intracellular potassium depletion

I want to simulate intracellular K+ depletion by outward K+ current in a semi-sphere space with radius of 1 uM and volume of 2.1 um3. The outward K+ current is set to be 5 nA with duration of 3 ms, which equals to an efflux of 1.55e-16 mole of K+. Thus the intracellular K+ should be reduced by 74 mM...