LTSpice - Internal error 44 - Oscillator simulation! - Page 1
Forum section: electronics / projects

author: ruiseixas
author_rank: Contributor
timestamp: June 09, 2016, 12:16:07 am
content: Hi,I try the following circuit and besides the error 44 I also got a very delayed simulated oscillator graph! Any one knows why?This schematic worked as expected in a breadboard and was taken from the book Tab Electronics Guide to Understanding Electricity and Electronics 2nd Edition!Thanks

author: Audioguru
author_rank: Super Contributor
timestamp: June 09, 2016, 03:29:23 am
content: Unlike a real circuit, the parts on each side are exactly the same so the oscillator cannot start running. Change the value a little of one of the timing resistors or capacitors.

author: ZeTeX
author_rank: Frequent Contributor
timestamp: June 09, 2016, 07:13:21 am
content: You should also give model to the led, and choose realistic .tran time, something like 10s top..tran 10s startup

author: ruiseixas
author_rank: Contributor
timestamp: June 09, 2016, 04:02:50 pm
content: Quote from: Audioguru on June 09, 2016, 03:29:23 amSo, LTSpice is a simulator that fails given some types of circuits...Sorry but that makes no sense at all, because all point of a simulator is to replace a breadboard with reliable results, mainly with a very simple circuit like this one!Nevertheless, I changed one capacitor to 11uF and this is what I got with specified and not specified LEDs:Thanks

author: ataradov
author_rank: Super Contributor
timestamp: June 09, 2016, 04:17:10 pm
content: Quote from: ruiseixas on June 09, 2016, 04:02:50 pmYou are really missing the point. And if you expect LTSpice to "just work", then you need to look elsewhere. LTSpice (and any other *Spice) is an equation solving tool, every time you work with it you are required to have understanding of what is going on in the background, otherwise you will never use it efficiently.Some things are hard or impossible to simulate, that's just how it works. And nobody claimed that LTSpice can solve all your problems, in fact, it is a very specialized tool for people who know what they are doing.Specify types of transistors and add mismatching of the resistors as well. And attach your LTSpice project.

author: ruiseixas
author_rank: Contributor
timestamp: June 09, 2016, 05:19:20 pm
content: Quote from: ataradov on June 09, 2016, 04:17:10 pmOk, so, there is no way to simulate this simple circuit...Maybe you are an specialist in LTSpice, but the knowledge I have about other types of simulators from other fields than electronics, it's all about random generated values and independent behavior of each component in the system. So, the system itself has no global formula but each component in relation with it, and the result of the system comes mainly from that interaction of each well defined component and not from any global fancy "equation"! Simulators in general work like a Monte Carlo simulation, designed specifically to avoid big and complicated equations trough the independent behavior of each component where only the relationships of those components with the system are established. This system is a Simulation Environment not a big equation!My first screenshot shows that at 800s LTSpice is able to simulate the circuit correctly, so the question, why all this delay in LTSpice if it's able to simulate correctly after 800 seconds?

author: ataradov
author_rank: Super Contributor
timestamp: June 09, 2016, 05:25:13 pm
content: Quote from: ruiseixas on June 09, 2016, 05:19:20 pmThere is, you just need to remove all ideal stuff and replace it with real stuff, just as in real life. Mathematical models have limitations. And circuits with feedback are the hardest in this respect. Complexity of the circuit is defined not by the number of components, or how simple it looks.Quote from: ruiseixas on June 09, 2016, 05:19:20 pmLTSpice has many modes. And it is designed to work in a predictable way as a solver of a system of equations in a transient analysis mode.Quote from: ruiseixas on June 09, 2016, 05:19:20 pmBecause by that time round-off errors in the calculations become too big, so imbalance is introduced. If you introduce this imbalance yourself from the start, then it will start working faster.BTW, the real circuit takes time to get going as well.

author: ruiseixas
author_rank: Contributor
timestamp: June 09, 2016, 05:34:10 pm
content: Quote from: ataradov on June 09, 2016, 05:25:13 pmI did that in my second post with 11uF vs 10uF with no better results! Is this imbalance you are talking about? If not, how to do it?

author: Audioguru
author_rank: Super Contributor
timestamp: June 09, 2016, 05:34:28 pm
content: If you build the circuit with identical parts on both sides like your 1st simulation then it will not work or it will have a long delay before it starts!Your second circuit with one part value changed a little was beginning to work but your timer was too short to show much.A real circuit is kicked when the supply is turned on and has random noise to cause it to start but a simulation does not have them.

author: ataradov
author_rank: Super Contributor
timestamp: June 09, 2016, 05:36:39 pm
content: Quote from: ruiseixas on June 09, 2016, 05:34:10 pmIntroduce imbalance into resistors as well. It does not have to be huge, minor variations will be sufficient.I would also pick real transistors. I have no idea what parameters are used for the ideal model.

author: ruiseixas
author_rank: Contributor
timestamp: June 09, 2016, 05:55:42 pm
content: Quote from: Audioguru on June 09, 2016, 05:34:28 pmI gave 6 seconds in the parameters but I can't make it visible in the graph all the period as much I click in the zoom out button!Amazingly, while switching windows to try zoom out again, I was surprised by this:I don't know what happen, maybe screen refresh?By the way, the voltage in blue is the one relative to the base of the Q2 transistor (n006).

author: macboy
author_rank: Super Contributor
timestamp: June 09, 2016, 06:13:33 pm
content: Always choose actual models for transistors and diodes. The default model is far from any real component.With 2n3904 and a random LED, it works fine for me.I also always add some series R to voltage sources and capacitors, because in real life there is always some there. You would be amazed at the bad things that large "ideal" capacitors can do.

author: ZeTeX
author_rank: Frequent Contributor
timestamp: June 09, 2016, 08:23:03 pm
content: Quote from: macboy on June 09, 2016, 06:13:33 pmits called ESR and you don't need to add external resistors, you can just right click on the component and write the resistance you need. All it does is it adds a resistor in series with the component but without showing the resistor, just quicker and more elegant.

author: macboy
author_rank: Super Contributor
timestamp: June 09, 2016, 08:43:22 pm
content: Quote from: ZeTeX on June 09, 2016, 08:23:03 pmOf course. And you can add the series resistance to the supply the same way, as a parasitic in its own definition rather than a discrete component. You can make the ESR of the capacitor visible by Control-Right-Clicking on the cap, and ticking the "visible" column for "Rser".

author: Siwastaja
author_rank: Super Contributor
timestamp: June 10, 2016, 06:02:48 am
content: LTSpice is the easiest simulator (in this contex, a real electronics simulator, not "it blinks a led easily" type) I have ever seen, but with knowledge lacking this much combined to horribly arrogant attitude, it's just easier to give up.LTSpice is easy and nice enough for a total beginner, but you need the right attitude, because it's not a demo, it's a real tool.Of course, a perfect software shouldn't crash, and LTspice occasionally does, especially if you give it problems it's not meant to solve, because it's used by people who want to have the job done, not play around testing whether it crashes if you try to do irrational things.For a beginner, the best part about a real simulator together with a actual prototypingisexactly that you can see the differences. This lets you learn the fact that all real components have more to them what they seem. In this case, the simulator is right, and your actual circuit is "wrong", and only works because it's "wrong"! This is often, actuallyalmost alwaysthe case!

author: Unknown
author_rank: Unknown
timestamp: June 10, 2016, 06:59:20 am
content: Quote from: ruiseixas on June 09, 2016, 05:19:20 pmNice rant. Did you set up the components in your LTspice simulation as Monte Carlo models?No, of course not ...Try reading the instructions or a few tutorials - or just try replacing your component values with something like{mc(component_value,tolerance_as_decimal)}e.g. R1 becomes{mc(470R,0.05)}It's a poor workman who blames his tools - particularly when the tools are more than capable of doing what is needed.

author: Zero999
author_rank: Super Contributor
timestamp: June 10, 2016, 10:09:16 am
content: A SPICE simulator only gives decent results, when given the correct circuit and models.You gave the simulator the wrong circuit and models so it didn't work properly.

author: ruiseixas
author_rank: Contributor
timestamp: June 11, 2016, 04:52:50 am
content: Quote from: macboy on June 09, 2016, 06:13:33 pmYep, you are absolutely right, I just specified the transistors as 2N3904 and all worked like a charm!Thanks