Pulp 1.88.0
Cross-platform audio plugin framework
Loading...
Searching...
No Matches
pulp::signal::junction Namespace Reference

Classes

struct  JunctionPair
 One junction network: the exponential law over one or two antiparallel legs. More...

Functions

double safe_exp (double x)
 exp(x) with the argument clamped into the safe range.
double exprel (double x)
 (exp(x) − 1) / x, with the removable singularity at 0 handled.

Variables

constexpr double kThermalVoltage = 0.02585
 Thermal voltage k·T/q at 300 K, in volts.
constexpr double kMaxExponent = 80.0
 Ceiling on an exponent argument, so a transient overshoot cannot produce inf.

Function Documentation

◆ exprel()

double pulp::signal::junction::exprel ( double x)
inline

(exp(x) − 1) / x, with the removable singularity at 0 handled.

Two Taylor terms are already below double precision at the cutoff, so the branch is exact rather than approximate where it matters.

◆ safe_exp()

double pulp::signal::junction::safe_exp ( double x)
inline

exp(x) with the argument clamped into the safe range.

Variable Documentation

◆ kMaxExponent

double pulp::signal::junction::kMaxExponent = 80.0
inlineconstexpr

Ceiling on an exponent argument, so a transient overshoot cannot produce inf.

exp(80) ≈ 5.5e34 is far past any current a real collector load will admit, and well short of exp's overflow near 709.

◆ kThermalVoltage

double pulp::signal::junction::kThermalVoltage = 0.02585
inlineconstexpr

Thermal voltage k·T/q at 300 K, in volts.

A physical constant derived from k/q = 8.617e-5 V/K, not a fitted value.