exprel class¶
(Shortest import: from brian2.core.functions import exprel)
-
class
brian2.core.functions.
exprel
(arg)[source]¶ Bases:
sympy.core.function.Function
Represents
(exp(x) - 1)/x
.The benefit of using
exprel(x)
over(exp(x) - 1)/x
is that the latter is prone to cancellation under finite precision arithmetic when x is close to zero, and cannot be evaluated when x is equal to zero.Methods
eval
(arg)Returns a canonical form of cls applied to arguments args.
fdiff
([argindex])Returns the first derivative of this function.
Details
Tutorials and examples using this¶
Example IF_curve_Hodgkin_Huxley
Example COBAHH
Example frompapers/Wang_Buszaki_1996
Example compartmental/hh_with_spikes
Example compartmental/lfp
Example advanced/float_32_64_benchmark
Example advanced/exprel_function