EDA > General PCB/EDA/CAD Discussions

Equivalent circuit of a PCB for SPICE simulation

(1/3) > >>

I want to make a simulation of a simple PCB to understand how the currents flow in the ground plane.

I don’t want to reinvent the wheel, I’m happy to use something already written, either open-source or commercial, but I cannot find anything! Commercial options are not in my budget.

I would solve this by making a spice network which represents the geometry of a simple PCB, say with a single trace on the top and a ground plane on the bottom. The simulation could be built up from two equivalent circuit unit cells: PCB with track and PCB without track.

Any idea about this in general or a good equivalent circuit model for a PCB?

In SPICE, you can insert voltage generators ("Vxx") with value 0 in series with any branch where you want to measure the current, and see the current through each generator.

I don't think you can model that with spice perhaps unless you created your "ground plane"
as some kind of 2D L-C-R matrix of cells that created a lumped circuit approximation of the electromagnetic and transmission line impedance effects associated with a conductor plane.

A 2D or 2.5D computational electromagnetics program would seem to be the more appropriate choice for this than SPICE.

But if there is an easy / good way I'd be interested to know how, too.

I recall ANSYS has a tool that can generate an equivalent N-port from the PCB fab.  But good luck with that...

Not aware of any free, open tools to do same.

Next best thing is perhaps simply learning how the fields work, and setting up environments to 1. prove out the theory by experiment, and 2. apply theory in practice.  Namely, we do #2 most often by using ground planes, so that traces manifest as transmission lines, with reasonable isolation between them (typically <10% coupling even for minimum-spaced buses), and low ground-return impedance, so that we can mostly ignore common mode effects.  With these factors being relatively small, it isn't important what the exact coupling is, because it's small enough everywhere to assume equal to zero.  Put another way: the coupling matrix is sparse.

I'm not sure what angle you're coming at this from -- it could be a relative beginner question, looking to just see the pretty pictures and play with a reasonably-realistic simulator (at least, if it's easy enough to work with), and in that way, perform those experiments and build up the knowledge level.  Or it could be a professional in-depth level, where you already know generally how things work, but due to strict constraints on a given project, you need to evaluate tighter-coupled designs, and thus cannot make use of the design rules / assumptions listed above.  (Or anything inbetween, like, say: getting a quantitative measure of ground bounce, coupling, etc., rather than just a hand-waving approximation to it.)


It might be possible to obtain an impedance model of the PCB tracks using an impedance extractor. Then, that model could be included in your spice schematic. For that purpose there are many programs available, but FastHenry and FastCap are completely free (https://www.fastfieldsolvers.com/software.htm). However, if you have an Ansys Electromagnetics Desktop license I think HFSS is also able to do that.

On the other hand, you might be interested in using a FEA simulator directly instead of adding those models to your Spice model as it might be less time consuming. HFSS even allows co-simulating the pcb and a circuit. Nevertheless, I think OpenEMS (https://openems.de/start/)can also be used for simulating pcbs (at least it allows simulating pcb antennas) if you can’t afford an Ansys license


[0] Message Index

[#] Next page

There was an error while thanking
Go to full version