Skip to main content

1. About SpicePy

SpicePy is a name coming from the merge of SPICE (Simulation Program with Integrated Circuit Emphasis) and Python, hence, it goes without saying that it is a Circuit simulator written in python

SpicePy borns as a teaching project. It is shared with students of basic circuit theory with two aims:

  • to allow them to check the results of exercises solved analytically
  • to show them how a numerical code to solve circuit is made

This document provides information basic about features and installation procedure. For the user's guide please refer to the Wiki section.

1.1 What can I do with SpicePy?

SpicePy allows you to simulate

  1. linear circuits
    • operating point
    • transient simulation
    • alternating current simulation
  2. the following components:
    • resistor
    • capacitor
    • inductor
    • independent voltage source
    • independent current source
    • dependent sources (VCVS, VCCS, CCVS, CCCS)
  3. transient sources (pwl, pulse, sin, exp)

2. Installation

This project is based on Python 3 (version >= 3.6 is constrained in the setup). I'm use to run this project on the latest version provided by miniconda. For the sake of completeness, Python 2 is not supported.

The project makes use of the following Python modules:

  • numpy
  • scipy
  • matplotlib

Usually, the last version of these Python modules is the one under use.

In the following three options for the installation are described.

2.1 Install from Pypi

Run this command (optionally, you can activate you virtual environment first):

pip install spicepy

2.2 Install (manually) from GitHub

  1. Clone the repository:

git clone https://github.com/giaccone/SpicePy.git

  1. put the project in the desired location
  2. add SpicePy folder to the path of your interpreter

2.3 Install within Google Colab

  1. Open a notebook in google colab
  2. install spicepy with
!pip install spicepy    # please note the exclamation mark before 'pip'
  1. now you can use spicepy within the notebook

3. Verify the installation

  • Download the benchmark and the demo folder from the GitHub project,
  • put the two folder at the same location,
  • enter the benchmark folder and run the script run_benckmark.py.

If everything is configured correctly, you will obtain the following results:

4. Work in progress

Here you can read about aspects that I'm thinking to include in this project. The list does not certifies that I will integrate all it is described. It's a simple list of the topics that potentially will be developed.

  • non-linearity: I'm planning to implement a non-linear solver based on Newthon-Rapshon method. A rough implementation already exists but it is far from be harmonized to the entire project. Since I prefer stability over new features I will include non-linearity when I will have some more (free) time that currently I do not have.
  • GUI: a small project was developed in order to create a text editor with tools to write netlists and with SpicePy integrated. But It is not sufficiently stable.

Metadata

Release files for spicepy 1.0.5

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for spicepy 1.0.5
File Size Uploaded Provenance Actions
spicepy-1.0.5.tar.gz 18.3 kB Without provenance Details for spicepy-1.0.5.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for spicepy 1.0.5
File Interpreter ABI Platform Actions
spicepy-1.0.5-py3-none-any.whl Python 3 none any Details for spicepy-1.0.5-py3-none-any.whl

Total release size: 36.0 kB

Release files / spicepy-1.0.5.tar.gz

Download URL spicepy-1.0.5.tar.gz
Size 18.3 kB
Tags Source
SHA-256 checksum
How to use checksums
27fe3fd4ae91bf75d9858a06f5a0d06d02aacebdf1df0e6de5585d4b0118015d
BLAKE2b-256 checksum
How to use checksums
8cc0c72eba4380326a8893b4e8a53f0f7f6c541d1fdcfe494e517309f850672d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.10.8

Release files / spicepy-1.0.5-py3-none-any.whl

Download URL spicepy-1.0.5-py3-none-any.whl
Size 17.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
c26da1b2efc7eeb05343bd2edbfa41117983091621ef1651658644768a418cce
BLAKE2b-256 checksum
How to use checksums
749f901682bb4dadaa3a3ebabcc5c6b6263904f7a8da43a098d106c625e58e70
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.10.8

Security for spicepy 1.0.5

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page