which these days is guaranteed to be provided by <math.h>
note,
our own implementation was incorrect anyway.
it evaluated to
erfc_ngspice(x) = erfc(fabs(x))
which moved processing of several parameters into a new function
ACM_SourceDrainResistances()
but did so incompletely.
As a consequence the matrix footprint was not correctly modified
when source or drainresistance is zero
Thanks for the bug report by "Sto" in message
> bug: mosfet models with deliberate NRD=0 (ngspice-27)
https://sourceforge.net/p/ngspice/discussion/133842/thread/fa39228d
This function is invoked several times during initialisation,
possibly with yet incomplete model and instance parameter settings.
And it might be invoked many times during dc sweep.
When "alter" is invoked after a break-point stopped a transient simulation,
then it might be necessary to update RESconductance
before continuing the transient simulation.
Thanks for the bug report to An Zou
in message "alter resistor value" on the ngspice-users forum
https://sourceforge.net/p/ngspice/discussion/133842/thread/33ce6855/
Note:
RESresist and RESacResist are device parameters
they do not reflect effective resistance when "ask"'ed
(don't reflect tc1, tc2, tce, m, scale, temp ...)
RESconduct and RESacConduct are "query-only" parameters
these report the effective conductance when "ask"'ed
(including tc1, tc2, tce, m, scale, temp ...)
Customers have been mislead to invoke them with tclsh or wish.
Actually some are indeed tcl scripts which could be invoked with "wish"
All these scripts include a #!/bin/sh trampoline to the proper interpreter.
No script was meant to be interpreted by tclsh
search for three variants
-lBLT (for debian and gentoo)
-lBLT24 (for redhat and centos)
-lBLT25 (might be usefull for someone else)
The advertised configure incantation is now:
configure --enable-shared=yes --with-tcl=/usr/lib/tcl8.6
In case you need a special "BLT" you can still use
LIBS=-lBLTfoobar configure --enable-shared=yes --with-tcl=/usr/lib/tcl8.6
to override the automatic search