ngspice

Create and debug ngspice circuit simulation netlists and analysis workflows.

23|5|Updated Mar 2, 2026
One-click install
npx skills add https://github.com/Cognitohazard/ltspice-mcp --skill ngspice-cognitohazard
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: ngspice
Source: https://github.com/Cognitohazard/ltspice-mcp/tree/main/skills/ngspice
Command: npx skills add https://github.com/Cognitohazard/ltspice-mcp --skill ngspice-cognitohazard

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill helps engineers write, debug, and interpret ngspice circuit simulations by providing reliable guidance on SPICE syntax, simulation workflows, and common errors that can produce incorrect results.

Core Features & Use Cases

  • ngspice Netlist Development: Create and edit ngspice-compatible circuit descriptions, parameters, directives, subcircuits, and behavioral sources.
  • Simulation Analysis Support: Interpret measurements, operating points, saved signals, convergence issues, and scripting results for circuit verification.
  • Use Case: Use this Skill when developing analog, mixed-signal, or device-level simulations that require ngspice-specific syntax, Monte Carlo analysis, XSPICE features, or troubleshooting of failed simulations.

Quick Start

Ask the ngspice skill to review my circuit netlist for ngspice compatibility and identify simulation errors.

Frequently Asked Questions about ngspice

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I debug ngspice simulation convergence issues in my circuit netlist?

To debug ngspice simulation convergence issues, you must review your circuit netlist for incorrect device parameters, missing initial conditions, or inadequate simulation directives. Proper convergence handling requires ngspice-specific syntax to adjust simulation tolerances and algorithms.

What is the best way to write an ngspice netlist for analog circuit verification?

Writing an ngspice netlist for analog circuit verification involves using correct SPICE syntax to define components, subcircuits, and behavioral sources. You must apply ngspice-specific directives to configure operating point, transient, or parameter sweep analyses accurately.

Can I use XSPICE features for mixed-signal simulation in ngspice?

You can use XSPICE features for mixed-signal simulation in ngspice by incorporating specific code models and behavioral nodes into your netlist. This allows you to simulate digital and analog components together within the standard ngspice environment.

How do I set up Monte Carlo analysis and parameter sweeps in ngspice?

Setting up Monte Carlo analysis and parameter sweeps in ngspice requires writing control scripts that loop simulations while varying device parameters. You must use ngspice scripting features and measurement directives to automate runs and extract statistical results.

Why does my SPICE simulation produce incorrect measurement results?

Your SPICE simulation produces incorrect measurement results when netlist syntax errors, improper behavioral source definitions, or flawed measurement directives exist. You must interpret saved signals and operating points carefully to verify circuit behavior and identify modeling mistakes.