Get Ngspice essential facts below. View Videos or join the Ngspice discussion. Add Ngspice to your topic list for future reference or share this resource on social media.
Stable release
ngspice-28 / June 1st, 2018
Written in C
Platform Linux, Windows, macOS, BSD, others
Available in English
Type Electronic circuit simulation
License New BSD license (free software)

Ngspice[1][2] is a mixed-level/mixed-signal circuit simulator. It is the open-source successor of Spice3f5. A small group of maintainers and the community of motivated users contribute to the ngspice project by providing new features, enhancements and bug fixes.

Ngspice is based on three free-software packages: Spice3f5, Xspice and Cider1b1:

  • SPICE[3] is the origin of all electronic circuit simulators, its successors are widely used in the electronics community.
  • Xspice[4] is an extension to Spice3 that provides additional C language code models to support analog behavioral modeling and co-simulation of digital components through a fast event-driven algorithm.
  • Cider[5] adds a numerical device simulator to ngspice. It couples the circuit-level simulator to the device simulator to provide enhanced simulation accuracy (at the expense of increased simulation time). Critical devices can be described with their technology parameters (numerical models), all others may use the original ngspice compact models.

Ngspice is, anyway, more than the simple sum of the packages above, as many people are contributing to the project with their experience, their bug fixes and their improvements giving ngspice additional features and improved robustness.

Status of Ngspice simulator

Ngspice implements three classes of analysis:

  • Nonlinear DC analyses
  • Nonlinear transient analyses
  • Linear AC analyses

Transient analysis includes transient noise simulation. AC analysis includes small-signal noise simulation, pole-zero and transfer function analysis.

Ngspice implements various circuits elements, like resistors, capacitors, inductors (single or mutual), transmission lines and a growing number of semiconductor devices like diodes, bipolar transistors, MOSFETs (both bulk and SOI), MESFETs, JFETs and HFETs.

New models can be added to the simulator using:

  • Behavioral modeling: Internal B-, E-, and G-sources, as well as R, C and L devices, offer modeling by mathematical expressions, driven by node voltages, branch currents, parameters and constants.
  • The Xspice codemodel interface: This is a C-code interface that helps the modeling process by simplifying the access to simulator's internal structure.
  • ADMS verilog model compiler: The ADMS model compiler generates C code from Verilog-A model descriptions for integration into ngspice.
  • C language coded models with spice format: As an open-source project, Ngspice allows new models to be linked to the sources and compiled.

Ngspice supports parametric netlists (i.e. netlists can contain parameters and expressions). PSPICE compatible parametric macromodels, often released by manufacturers, can be imported as-is into the simulator. Polynomial sources are available. Ngspice provides an internal scripting language to facilitate complex simulation and evaluation control flows.

Ngspice may be compiled into a shared library (*.dll or *.so) readily to be integrated into a calling program. Its interface provides access to all simulation parameters, input and output data. tclspice, another shared library version, offers an interface to Tcl/Tk (software).

Ngspice is licensed under the New BSD license.

Ngspice has a command line input interface and offers plotting capability. An open source GUI with schematic entry, simulation and plotting is provided by Qucs-S.

Ngspice has been integrated as a simulation engine into several free or commercial EDA tools: KiCad[6], EAGLE (program)[7], CoolSPICE, EasyEDA and others.

See also


  1. ^ NGSPICE: recent progresses and future plans, P. Nenzi e.a., MOS-AK, Bucharest 2014,
  2. ^ The NGSPICE circuit simulator, P. Nenzi e.a., FOSDEM, Brussels 2015,
  3. ^ Analysis of Performance and Convergence Issues for Circuit Simulation, T. Quarles, PhD dissertation, Memorandum No. UCB/ERL M89/42, Berkeley 1989,
  4. ^ Code-level modeling in XSPICE, F. L. Cox e.a., Proceedings IEEE International Symposium on Circuits and Systems, 1992 (ISCAS 92), vol. 2, pp. 871-874, 10-13 May, 1992
  5. ^ CODECS: A Mixed-Level Circuit and Device Simulator, K. Mayaram, Memorandum No. UCB/ERL M88/71, Berkeley, 1988,
  6. ^ Integrated Spice Simulation with Kicad, T. Wlostowski, FOSDEM, Brussels 2017,
  7. ^ SPICE Simulation Part 1, S. Sattel, Autodesk Support and Learning, 2017,

External links

  This article uses material from the Wikipedia page available here. It is released under the Creative Commons Attribution-Share-Alike License 3.0.



Music Scenes