Page 1 of 1

Input impedance

Posted: Thu Jun 16, 2011 5:41 pm
by Sherif
Hi all,

I used the following function to measure the input impedance of a neuron model; however, when I printed the variable Zin I got "nan". Any advice on what could be the reason for that?

Code: Select all

proc Compute_Zin() { localobj z

	z = new Impedance()		
	soma { z.loc(0.5) } 
	z.compute(1, 1) 								
	Zin = 0
	soma { Zin = z.input(0.5) } 
	print "Input impedance: ", Zin
By the way, when I removed the line on "z.compute(1, 1)", Zin printed 0. No extracellular or LinearMechanism is included in the model, just standard active conductances.


Re: Input impedance

Posted: Fri Jun 17, 2011 3:43 am
by ted
Seems strange to me. Does
soma psection()
What happens if you execute
before doing any impedance calculation?

Re: Input impedance

Posted: Mon Jun 20, 2011 1:30 pm
by Sherif
psection() works fine before or after calling the impedance calculations. Also, finitialize(-65) works fine (prints 1 on the command line) with no error messages before or after the impedance calculations.

Re: Input impedance

Posted: Mon Jun 20, 2011 2:30 pm
by ted
OK, guess I'll have to be able to reproduce the problem in order to figure out what's wrong. If you zip up the necessary hoc, ses, and mod files, and email it to me
ted dot carnevale at yale dot edu
I'll take a look.

Re: Input impedance

Posted: Mon Jun 27, 2011 12:15 pm
by Sherif
Hi All,

Ted was able to fix the problem. The fix was placing an finitialize(-65) statement at the beginning of the Compute_Zin() procedure. This statrement was necessary for initializing the gating states properly.

Re: Input impedance

Posted: Mon Jun 27, 2011 1:29 pm
by ted
And if you had a model that has a different resting potential, just finitialize() to that potential instead of -65.