LTspice time step too small problem

I am trying to use a ring oscillator with seven inverters. Instead of inverters I tried using basic ttl inverters (which gave me an output but no oscillation), I tried using some of the .option commands as well. Is my circuit layout wrong? Also not sure if I needed to connect that 5V supply or needed to connect ground there. But doesn't the inverters need power to do the inverting? Can someone help?

  • 2
    \$\begingroup\$ Read the help under LTspice > Circuit Elements > A. .... TLDR: you need to add at the very least some sort of delay, td=<...> because it's zero by default, otherwise you create a race condition. Why did you connect the ground to 5 V? Also, "I tried a lot of things" -- what exactly have you tried? \$\endgroup\$ Commented Dec 24, 2022 at 9:44

1 Answer 1


If you'll read the help under LTspice > Circuit Elements > A. ... you'll see this passage:

The propagation delay defaults to zero and is set with instance parameter Td.

That means that, when you connect logical gates with feedback and nothing to delay the signal, you create a race condition: applying a change at one input means the output changes state instantaneously and, through feedback, it changes the input, thus the program cannot know which state to consider. It then tries to reduce the timestep, over and over, until it fails because it cannot solve a problem that requires a node to have two values at once. That's why you need to specify a delay with the help of the parameter td.

Also, where did you see that schematic? If you meant to use V1 as a supply then, again, you should read the help (same page), where you'll see this, right in the beginning:

These gates require no external power.

That is accomplished with the parameters vhigh, vlow. As for the "supply":

Current is sourced or sunk from the complementary outputs, terminals 6 and 7, and returned through device common, terminal 8. (and the following)

With these in mind, here's how it should look like:

ring oscillator

It's not set in stone -- not the number of gates, or the parameters; use it as inspiration. In addition to the already mentioned 3 parameters, you see tau and tripdt. The first one makes the output have an RC-like characteristic, smotthing the edges (and, sometimes, helping the solver), while the second is a temporal helper that tells the engine "whenever you see a change that happens faster than 1 V in tripdt seconds, reduce the timestep and preserve the resolution; otherwise, don't stop. It's not mandatory but, just like tau, it can help.

  • 1
    \$\begingroup\$ I forgot to add: the first gate, A1, has an additional ic=1 -- that specifies the initial conditions for its output. You can run the circuit without it but, the solver will first try to determine the operating point and that will be a bit problematic due to the possible race condition (time has not advanced yet). You may see that LTspice will get stuck at the initial op point solving. The output might also not be correct. So, to help, ic is added to force the voltage at one node so that will provide a hint for the solver. \$\endgroup\$ Commented Dec 24, 2022 at 12:58
  • 1
    \$\begingroup\$ Would a .nodeset on the output node also solve the op point problem? \$\endgroup\$
    – Ste Kulov
    Commented Dec 26, 2022 at 3:15
  • 1
    \$\begingroup\$ @SteKulov Yes, or .ic, anything that serves as a nudge in the right direction. \$\endgroup\$ Commented Dec 26, 2022 at 9:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.