classes compute input_phase ratio transfer_phase input loc transferFor calculating input and transfer impedances at an instant of time Usage involves first defining a location either for the current stimulus or else the voltage measuring electrode, then computing the global transfer and input impedance function at a particular frequency, then retrieving values of the complex transfer and input impedance.
Impedance
.loc(x)
v(x)/i(loc) == v(loc)/i(x)
where loc
is the fixed location and
x ranges over every position of every section.
Impedance
.compute(freq)
v(x)/i(x)
Frequency specified in Hz.
All membrane conductances are computed and used in the
calculation as if fcurrent()
was called.
The compute call is expensive but as a rule of thumb is not
as expensive as fadvance()
.
Impedance
.transfer(x)
loc(x)
call above and 0<=x<=1 of
currently accessed section at the freq specified by a previous
compute(freq). The value returned can be thought of as either
|v(loc)/i(x)| or |v(x)/i(loc)|
Probably the more useful way of thinking about it is to assume
a current stimulus of 1nA injected at x and the voltage in mV
recorded at loc.
Return value has the units of Megohms and can be thought of as the amplitude of the voltage (mV) at one location that would result from the injection of 1nA at the other.
Impedance
.input(x)
v(x)/i(x)
of the currently accessed section
Impedance
.ratio(x)
|v(loc)/v(x)|
Think of it as voltage clamping to 1mV at x at some
frequency and recording the voltage at loc.
Impedance
.transfer_phase(x)
Impedance
.input_phase(x)
Note: Impedance makes heavy use of memory since four complex
vectors are allocated with size equal to the total number of
segments. After compute is called two of these vectors holds
the input and transfer impedance for a given loc, freq, and
neuron state. Because
of the way results of calculations are stored it is very efficient
to access amp and phase; reasonably efficient to change freq or loc,
and inefficient to vary neuron state, eg, diameters. The last case
implies at least the overhead of a call like fcurrent()
.(actually
the present implementation calls fcurrent()
on every compute()
call
but that could be fixed if increased performance was needed).