LTSpice taking longer than normal....  - Page 1
Forum section: electronics / projects

author: Smokey
author_rank: Super Contributor
timestamp: October 07, 2015, 02:04:24 am
content: Anyone notice LTSpice taking way longer than it used to to solve some circuits?I have some standard simulations that used to always solve essentially instantly that now take like 10 seconds to finish. I didn't even change anything in the circuit or LTSpice settings. Been going on for a couple weeks now.Anyone else see any weirdness there?

author: T3sl4co1l
author_rank: Super Contributor
timestamp: October 07, 2015, 03:12:04 am
content: As in, new version? Or just in general?Computational solutions are amazingly difficult to realize. As powerful as SPICE is, there are still a multitude of "correct", reasonably sized circuits, which will not simulate in a reasonable time frame, for any environment parameters.The best approach is to minimize unstable, poorly defined nodes, and get as many continuous derivatives as possible. Examples of bad circuits: capacitors in series (degenerate voltages -- if Rshunt = inf, gives "singular matrix" error), inductors in parallel (same thing, but for Rseries = 0, and currents being undefined), behavioral blocks using discontinuous (e.g., IF, SGN) or piecewise-continuous (TABLE, LIMIT, etc.) functions, circuits that are highly nonlinear (e.g., oscillators, switchers, discrete (usually non-behavioral*) logic) that don't also have realistic parasitics included in the model (ESR, ESL, strays, etc.).*Behavioral logic runs in a different subsystem, and only interfaces with analog simulation at port pins. Which have their own range of concerns, so I'll just leave that out for now..Of course, rich, relatively accurate models (those including most nonlinearities, parasitics, time and state dependencies, etc.) tend to run very slowly, for the fact that they have a lot to do... but they also tend to go more smoothly. At least... in as much as, when they don't get randomly hung up on a small timestep, and judging performance relative to the number of nodes in the model.Tim

author: macboy
author_rank: Super Contributor
timestamp: October 07, 2015, 02:10:26 pm
content: Quote from: Smokey on October 07, 2015, 02:04:24 amThis happens. Something in the circuit is oscillating or near oscillating and LTSpice is dutifully using small simulation time steps to try to capture the additional detail, which may or may not actually show up in the eventual output.Sometimes when this happens I add a pF (or less) cap from an op-amp output to in-, or a RC snubber (again with very small C) to a critical node, usually an output. This usually resolves the problem entirely without having any substantial effect on the circuit. Remember that real circuit construction introduces all kinds of parasitic capacitances and inductances, and this is just adding some of those into the simulation

author: Smokey
author_rank: Super Contributor
timestamp: October 07, 2015, 07:18:50 pm
content: Thanks for the good feedback. I was just curious if they maybe changed the way something worked behind the scenes that was causing anyone else problems. I don't have any evidence, or even remember when the last time I did an update was. Just a shot in the dark.I like the suggestion of adding some parasitic capacitance. I'll do that and see if it helps.

author: exmadscientist
author_rank: Frequent Contributor
timestamp: October 08, 2015, 04:39:05 am
content: I've also noticed that it's worth trying the Alternate solver mode when things are having trouble converging. "Alternate" is supposed to use higher internal precision and runslower, so I assume the situations where it's actually faster are a sign of severe ill-conditioning somewhere, as others have described above.