Definitely exclude A devices from power probing (and others with less than 2 pins).

This commit is contained in:
Holger Vogt 2023-02-18 18:54:54 +01:00
parent 5924ae2dfb
commit 9c6fe3f8e4
1 changed files with 7 additions and 1 deletions

View File

@ -874,6 +874,12 @@ void inp_probe(struct card* deck)
else
numnodes = get_number_terminals(thisline);
if (numnodes < 2) {
fprintf(stderr, "Warning: Power mesasurement not available,\n .probe %s will be ignored\n", wltmp->wl_word);
tfree(instname);
continue;
}
int err = 0;
/* call fcn with power requested */
err = setallvsources(tmpcard, instances, instname, numnodes, haveall, TRUE);
@ -1266,7 +1272,7 @@ void modprobenames(INPtables* tab) {
If .probe p(Q1) is found, flag power is true, then do additional power calculations:
Define a reference voltage of an n-terminal device as Vref = (V(1) + V(2) +...+ V(n)) / n with terminal (node) voltages V(n).
Calculate power PQ1 = (v(1) - Vref) * i1 + (V(2) - Vref) * i2 + ... + (V(n) - Vref) * in) with terminal currents in.
See "Quantities of a Multiterminal Circuit Determined on the Basis of Kirchhoffs Laws", M. Depenbrock,
See "Quantities of a Multiterminal Circuit Determined on the Basis of Kirchhoff<EFBFBD>s Laws", M. Depenbrock,
ETEP Vol. 8, No. 4, July/August 1998.
probe_int_ is used to trigger supressing the vectors when saving the results. Internal vectors thus are
not saved. */