Installing and using LTspice IV (now including LTXVII), From beginner to advanced

Thank you, Mooly...

slight ommision: to be able to add custom component libraries, one sometimes is required to take ownership of the LTC directory, since Windows installations are likely to grant full-access only to the "Trusted installer" and blocking the user (administrator) from write/delete actions.
 
Administrator
Joined 2007
Paid Member
Thank you, Mooly...

slight ommision: to be able to add custom component libraries..........

You're welcome :)

If you have a worked example showing what you want then we can include that in the thread. I've tended to steer clear of altering libraries, preferring to add any 'one offs' individually to the relevant project... which is also another way of saying I'd be starting from zero on that one ;)
 
Question about adding models

I wanted to use an OA2 tube regulator in a sim, so I found a model and added it to the library in the file library>cmp>standard.dio. Now when I run the sim it says it can't find the OA2 model. What am I doing wrong?

This is the model (it is modeled as a zener)
.model 0A2 D(Is=10u Rs=50 Cjo=10p nbv=147 bv=150 Ibv=20m Vpk=150 mfg=steve type=zener )

The sim does run fine if I change the OA2 callout to a zener number.
 
THD calculation

Does anyone know how THD is calculated in LTSpice? Is it documented somewhere? Is it the rms sum of the 1st 10 harmonics or something else?

This came about as I noticed something strange. I have 2 circuits A & B, same Vout and frequency, A has higher harmonics h2 through h5 (as read from the Fourier plot) but lower THD than circuit B. Not a huge difference, but a lot more than could be explained by rounding errors, etc.
 
Question about adding models

I wanted to use an OA2 tube regulator in a sim, so I found a model and added it to the library in the file library>cmp>standard.dio. Now when I run the sim it says it can't find the OA2 model. What am I doing wrong?

This is the model (it is modeled as a zener)
.model 0A2 D(Is=10u Rs=50 Cjo=10p nbv=147 bv=150 Ibv=20m Vpk=150 mfg=steve type=zener )

The sim does run fine if I change the OA2 callout to a zener number.

If We could use your post as a hint, in one place you have said OA2 (letter O),
and in another place 0A2 (number 0). They aren't the same...maybe the same problem in your sim?
 
Not a THD calculator (sorry) but a resistor calculator, just one of the uses for a simulator (as a calculator). This was actualy an interesting problem, I wanted to calculate op-amp-gain-setting resistors for equal voltages (against ground) on both input pins. Demonstrates using the voltage-dependent-voltage-source :)
 

Attachments

  • Compute Amplifier Input Voltages Against Ground.PNG
    Compute Amplifier Input Voltages Against Ground.PNG
    112.4 KB · Views: 243
  • Equal Balanced Input Loading.asc
    5.1 KB · Views: 57
Last edited:
Question about adding models:

I did read your post #85 but it's not working for my issue so perhaps we need further clarification.

I added a triode by going to lib\sym\Misc and selecting the generic triode. Then on the schematic I changed "triode" to the actual one I want to use, let's say 6XX7. Then I added the directive .inc 6XX7.inc and stuck the model file 6XX7.inc both in the folder containing the sim and also in the folder lib\sub. Still, when I run the sim it can't find the model. What am I doing wrong?
I get the error "Unknown subcircuit called in"
 
Last edited: