Mathemetical modeling and computer simulation of analog electronic circuits

From Elliptic Curve Crypto
Revision as of 18:56, 3 May 2026 by Rational Point (talk | contribs) (A-stable and/or L-stable)

The overriding assumptions are that “good programs” already exist to solve any given problem of basic circuit simulation, and to some extent, they do [1][2][3][4].

First-order systems of ordinary differential equations

Analog electronic circuit simulation problems are first-order systems of ordinary differential equations to be solved numerically or approximately.

Every node in a circuit has an electric potential, and every device carries an electric current. (Transistor base and collector currents are considered separate variables in the simulation, while the emitter current is constrained to be equal to the negative sum of them.)

The differential equations are ordinary and of the first order, because they involve these potentials and currents and their first derivatives with respect to time only.

Problems of convergence and so-called “stiffness”

Convergence problems [5] have plagued many SPICE (Simulation Program with Integrated Circuit Emphasis) implementations.

During the space race, Erwin Fehlberg found that many of the Runge-Kutta methods then in use, including many he had earlier proposed himself, were too complicated, requiring too many evaluations and calculations per time step without achieving any better accuracy. The best he presented at the time of Neil Armstrong’s moon landing [6] is a particular RK1(2) method which is little more than a modified first-order Euler-Cauchy method with a simple error estimate fed back to the algorithm to adjust the step size or time increment.

Systems of differential equations whose solutions do not converge to within an acceptable error bound using these fairly simply, naïve, elementary methods are often said to be “stiff.” We would generally prefer to avoid the math jock lingo, but that is the classic terminology from the Hippie era. “Math is hard.”

If the easy way doesn’t work, we have to do it the hard way

When “non-stiff” methods of solving differential equations fail, according to the literature, we must turn to “stiff” methods [7]. Many of these methods have the theoretical properties of being A-stable and/or L-stable [8][9].

  1. LTspice: Fast • Free • Unlimited https://www.analog.com/en/resources/design-tools-and-calculators/ltspice-simulator.html
  2. ngspice - open source spice simulator https://ngspice.sourceforge.io/
  3. Circuit simulation and schematics. https://www.circuitlab.com/
  4. Circuit Design and Simulation Software https://www.keysight.com/us/en/products/software/pathwave-design-software/eda-software-for-circuit-design.html
  5. LT wiki: Convergence Problems. https://ltwiki.org/index.php?title=Convergence_problems%3F
  6. Erwin Fehlberg. Low-order classical Runge-Kutta formulas with stepsize control and their application to some heat transfer problems. NASA TR R-315 https://ntrs.nasa.gov/api/citations/19690021375/downloads/19690021375.pdf
  7. Chris Rackauckas. Solving Stiff Ordinary Differential Equations. October 14th, 2020 https://book.sciml.ai/notes/09-Solving_Stiff_Ordinary_Differential_Equations/
  8. T. D. Bui. Some A-Stable and L-Stable Methods for the Numerical Integration of Stiff Ordinary Differential Equations. Journal of the ACM (JACM), Volume 26, Issue 3. Pages 483 - 493. https://dl.acm.org/doi/10.1145/322139.322147
  9. K. Selva Kumar and K. Jason. L-Stable and A-Stable numerical method of order two for stiff differential equation. April 2022. https://www.researchgate.net/publication/367887368_L-Stable_and_A-Stable_numerical_method_of_order_two_for_stiff_differential_equation