Oscillator simulation in LTspice

Thread Starter

PeteHL

Joined Dec 17, 2014
475
Can this be done with LTspice? When I ran the simulation of the below phase-shift oscillator, I received the error message that my sim lacked an AC source.

The circuit constructed at my bench using the op amp LM307 gave me a sine wave output of freq. = 1.4 kHz.

So far I've used LTspice very little, so hopefully I overlooked something. Lacking a spectrum analyzer at my bench, I was hoping that I could determine by simulation the extent of harmonic distortion.

Thanks for any advice,

Pete

P.S.: It is not possible to convert *.asc to for example *.jpg with LTspice, is that true?
 

Attachments

AlbertHall

Joined Jun 4, 2014
12,347
Use transient analysis with a start and stop time instead of AC analysis. AC analysis expects an AC source and it will sweep the frequency of the source to plot the frequency response of a circuit.
 

ericgibbs

Joined Jan 29, 2010
18,865
hi Pete,
Note your Cap values are Farads.
E

EDIT:

Where did you get the OP07 model.?
With another OPA model it runs OK in .tran

Update:
Added a sim with LM324
 

Attachments

Last edited:

Thread Starter

PeteHL

Joined Dec 17, 2014
475
Thanks very much @AlbertHall and @ericgibbs. I see the error of my ways.

The OP07 is one in the LTspice op amp library. I forget now, but somehow I arrived at the conclusion that the OP07 is close to a general purpose op amp such as LM307.
 

Thread Starter

PeteHL

Joined Dec 17, 2014
475
Thanks again. Copying how to do it was a little bit tricky as I found that the parameters of the AC analysis must be entered before the transient parameters to get the simulation to work.

It looks like the only way that I could determine harmonic distortion would be to simulate band-pass and notch filters connected to the output of the oscillator.
 

RichardO

Joined May 4, 2013
2,270
It looks like the only way that I could determine harmonic distortion would be to simulate band-pass and notch filters connected to the output of the oscillator.
You can do an FFT from the waveform window. It is in the "View" drop down menu.
 

Bordodynov

Joined May 20, 2015
3,180
You can use the .FOUR command to get harmonics info.
In my example, I did so. Using the "Meas" command, I determined the duration of 1000 periods and calculated the signal frequency. Then I used the "Four" command and ran the calculation again and calculated the harmonics. I made a calculation for 100 periods.
I also did an FFT analysis.
 

Thread Starter

PeteHL

Joined Dec 17, 2014
475
In my example, I did so. Using the "Meas" command, I determined the duration of 1000 periods and calculated the signal frequency. Then I used the "Four" command and ran the calculation again and calculated the harmonics. I made a calculation for 100 periods.
I also did an FFT analysis.
Very Impressive! Even though I did make some effort to do what you did, I could not duplicate. I am currently not familiar enough with the software and I found little to no guidance in LTspice Help for much of the procedure that you followed. Is it possible to do what you did in LTspice IV?
 
Top