Maker Pro
Maker Pro

Stability analysis with PSpice

  • Thread starter Oliver Friedrich
  • Start date
O

Oliver Friedrich

Jan 1, 1970
0
Hallo,

I'm designing discrete amplifiers for ultrasonic frontends. Are there
methods to examine stability of the amplifiers with PSpice. I did something
of stability by applying a Dirac-like pulse on the input and looked on the
pulse response if there are any more or less damped oscillations on
characteristic frequencies. But sure there are some more sophisticated
methods.
Unfortunately, I can't draw any Pole-Zero plots with SPice..or is there
someone out there contradicting?

Hope to get a lot of discussion.

Oliver Friedrich
 
J

Jim Thompson

Jan 1, 1970
0
Hallo,

I'm designing discrete amplifiers for ultrasonic frontends. Are there
methods to examine stability of the amplifiers with PSpice. I did something
of stability by applying a Dirac-like pulse on the input and looked on the
pulse response if there are any more or less damped oscillations on
characteristic frequencies. But sure there are some more sophisticated
methods.
Unfortunately, I can't draw any Pole-Zero plots with SPice..or is there
someone out there contradicting?

Hope to get a lot of discussion.

Oliver Friedrich

You can do gain and phase analysis, for instance use the LoopGain part
from my website. (Not for version 10.0 until I have time to post a
fix... some dumb-ass programmer broke the syntax by requiring a
newline to be \n<space> instead of \n<no-space> :-(

...Jim Thompson
 
M

Mike Engelhardt

Jan 1, 1970
0
Oliver,
I'm designing discrete amplifiers for ultrasonic frontends. Are
there methods to examine stability of the amplifiers with PSpice.
I did something of stability by applying a Dirac-like pulse on
the input and looked on the pulse response if there are any more
or less damped oscillations on characteristic frequencies. But
sure there are some more sophisticated methods.

Transient analysis is probably the best means of verifying
stability of an amplifier, as long as you excite every possible
mode of oscillation.

To understand *why* an amplifier is stable or not, is usually
easier to get out of a .ac analysis. You want to be able to
see the open loop response as a function of frequency and
check the gain and phase margin. You probably can't get a valid
operating point for your discrete amp by cutting the feedback
loop, so you would have to insert a floating ac source in the
feedback loop at a point of low to high impedance and plot the
negative ratio of complex voltages to either side of the floating
source. This method is only exact if you insert the source at a
point after a voltage and working into an infinite impedance point,
otherwise you have to consider only the voltage gain, but also
the current gain and combine the two to the true open loop gain.
I believe this method was first put in print by Middlebrook, R.D.,
"Measurement of Loop Gain in Feedback Systems", Int. J. Electronics,
vol 38, No. 4, pp. 485-512, 1975. There's a concrete example of
method this in the LTspice distribution as
../examples/Educational/LoopGain.asc.

There's two cautions about using small signal response to determine
stability. One is that you have to check every feedback path,
which can be laborious for some big state variable design. The
other is that stability depends on operating point and load. That
is, you can put in a large signal sine wave and see rf oscillations
only during a part of the cycle. The advantage of doing stability
verification with a .tran analysis instead of a .ac analysis is
that it's often easier to check all these concerns at once.

--Mike
 
J

Jim Thompson

Jan 1, 1970
0
Oliver,


Transient analysis is probably the best means of verifying
stability of an amplifier, as long as you excite every possible
mode of oscillation.

To understand *why* an amplifier is stable or not, is usually
easier to get out of a .ac analysis. You want to be able to
see the open loop response as a function of frequency and
check the gain and phase margin. You probably can't get a valid
operating point for your discrete amp by cutting the feedback
loop, so you would have to insert a floating ac source in the
feedback loop at a point of low to high impedance and plot the
negative ratio of complex voltages to either side of the floating
source. This method is only exact if you insert the source at a
point after a voltage and working into an infinite impedance point,
otherwise you have to consider only the voltage gain, but also
the current gain and combine the two to the true open loop gain.
I believe this method was first put in print by Middlebrook, R.D.,
"Measurement of Loop Gain in Feedback Systems", Int. J. Electronics,
vol 38, No. 4, pp. 485-512, 1975. There's a concrete example of
method this in the LTspice distribution as
./examples/Educational/LoopGain.asc.

There's two cautions about using small signal response to determine
stability. One is that you have to check every feedback path,
which can be laborious for some big state variable design. The
other is that stability depends on operating point and load. That
is, you can put in a large signal sine wave and see rf oscillations
only during a part of the cycle. The advantage of doing stability
verification with a .tran analysis instead of a .ac analysis is
that it's often easier to check all these concerns at once.

--Mike

And implemented (and automated) in my PSpice LoopGain part.

...Jim Thompson
 
K

Kevin Aylward

Jan 1, 1970
0
Oliver said:
Hallo,

I'm designing discrete amplifiers for ultrasonic frontends. Are there
methods to examine stability of the amplifiers with PSpice. I did
something of stability by applying a Dirac-like pulse on the input
and looked on the pulse response if there are any more or less damped
oscillations on characteristic frequencies. But sure there are some
more sophisticated methods.
Unfortunately, I can't draw any Pole-Zero plots with SPice..or is
there someone out there contradicting?

In general, now that we have spice, pole-zero plots are pretty much
useless, imo.

The sophisticated method *is* to do transient runs. It is the *only* way
to *guarantee* that the results will be correct. Unfortunately, the
small signal responses are only a guide. A simple bode plot is usually
sufficient. Many systems oscillate even when the small signal response
indicates otherwise. This is because all sorts of non-linear effect in a
real system come into play. e.g. saturation and clipping where small
signal frequency responses about those points are unstable.

Old habits die hard. Stability theory was invented when computers didn't
exist.

Kevin Aylward
[email protected]
http://www.anasoft.co.uk
SuperSpice, a very affordable Mixed-Mode
Windows Simulator with Schematic Capture,
Waveform Display, FFT's and Filter Design.
 
P

Paul Burridge

Jan 1, 1970
0
The sophisticated method *is* to do transient runs. It is the *only* way
to *guarantee* that the results will be correct. Unfortunately, the
small signal responses are only a guide. A simple bode plot is usually
sufficient. Many systems oscillate even when the small signal response
indicates otherwise. This is because all sorts of non-linear effect in a
real system come into play. e.g. saturation and clipping where small
signal frequency responses about those points are unstable.

So what are you saying - that ac analysis lacks sufficient 'drive'?
 
J

Jim Thompson

Jan 1, 1970
0
So what are you saying - that ac analysis lacks sufficient 'drive'?

AC Analysis: LINEAR model of the device at the present operating
point... so there are no effects due to non-linearities.

...Jim Thompson
 
P

Paul Burridge

Jan 1, 1970
0
AC Analysis: LINEAR model of the device at the present operating
point... so there are no effects due to non-linearities.

In that case, how is this kind of analysis *kept* linear?
 
J

Jim Thompson

Jan 1, 1970
0
In that case, how is this kind of analysis *kept* linear?

Controlled sources and passive components have NO non-linearities.

During an AC analysis each device instance is replaced with an
Ebers-Moll equivalent for the bias conditions....

See: http://jas2.eng.buffalo.edu/applets/education/system/bjtequi/

Mikey seems quite rigorous in adhering to Spice standards, so I would
imagine you can look at the .OUT file and see the values for the
linearized version.

...Jim Thompson
 
M

Mike Engelhardt

Jan 1, 1970
0
Jim,
...During an AC analysis each device instance is replaced with an
Ebers-Moll equivalent for the bias conditions....

Well, each non-linear device is replaced with so many conductances,
linear transconductances, and reactances for the small signal .ac
analysis. After all, frequency domain doesn't mean much without a
linear(ized) circuit. This linearized version of the circuit
represents the linear behavior infinitesimally about the solved
operating point. Whichever non-linear device model equations,
Ebers-Moll vs. Spice Gummel-Poon vs Unified Bipolar vs. VBIC vs.
HICUM vs. MEXTRAN hasn't much to do with it, except the more
advanced models look less and less like a linearized hybrid pi
transistor. Basically, strickly speaking, I think JT meant
hybrid-pi, not Ebers-Moll.

--Mike
 
J

Jim Thompson

Jan 1, 1970
0
Jim,


Well, each non-linear device is replaced with so many conductances,
linear transconductances, and reactances for the small signal .ac
analysis. After all, frequency domain doesn't mean much without a
linear(ized) circuit. This linearized version of the circuit
represents the linear behavior infinitesimally about the solved
operating point. Whichever non-linear device model equations,
Ebers-Moll vs. Spice Gummel-Poon vs Unified Bipolar vs. VBIC vs.
HICUM vs. MEXTRAN hasn't much to do with it, except the more
advanced models look less and less like a linearized hybrid pi
transistor. Basically, strickly speaking, I think JT meant
hybrid-pi, not Ebers-Moll.

--Mike

Yes, After all I'm getting senile.

But I still feel young, just got off the phone talking to my father
;-)

...Jim Thompson
 
K

Kevin Aylward

Jan 1, 1970
0
Paul said:
So what are you saying - that ac analysis lacks sufficient 'drive'?


Consider an amp at its bias point. Do a small signal analysis of it. Now
dc move the bias point so that the dc output level is somewhere in
saturation or clipping. Now do a small signal analysis. Its not the
same. Usually, there is much more delay at these extremes, and less
gain, causing instability. In addition, even if it is not oscillating
around these points, this extra delay for large signals can still result
in the system oscillating. Often, this is the type where you must give
it a kick start to get it going. Technically its called a limit cycle,
look up attracters, chaos and non-linear dynamics.

Kevin Aylward
[email protected]
http://www.anasoft.co.uk
SuperSpice, a very affordable Mixed-Mode
Windows Simulator with Schematic Capture,
Waveform Display, FFT's and Filter Design.
 
O

Oliver Friedrich

Jan 1, 1970
0
Wow, what a response, thanks alot.

And what's best: No one seems to feel offended and no one kicked somebody
elses a...

Now for the technical: Open all the feedback paths and measure gain and
phase is a method I know. But first it is very much work, second sure
there are feedback paths which you hardly identify as them. I mean
parasitic capacitance in transistors and so on.
After all, even when I've identified all this paths, how can I open a
feedback path made of a capacitor which is buried in a trnsistor model?
Maybe set its capacitance to 0.000001fF in the .MODEL statement ;-)
Very weird method.
New idea: Having the pole/zero in mind (It's yet not useless, gentlemen)
only poles near the jw axis contribute to any instability in a
significant way. These poles could be identified by making a .TRAN with
some sort of apprpriate input signal (ideally a DIRAC, practically I
would prefer a periodical needle-like pulse.
Next step I FFT the output of the amp and should get the jw values of the
poles (peaks in the "frequency response".
Then I excite the system with sine bursts or wavelets where the sine has
one of the found frequencies. This could enable me to determine the
damping factor and thus the sigma of the investigated pole.

Is this nonsense, did I invent the wheel twice or am I super smart;-)?

Looking forward to a lot more discussion

Oliver Friedrich
 
K

Kevin Aylward

Jan 1, 1970
0
Oliver Friedrich said:
Wow, what a response, thanks alot.

And what's best: No one seems to feel offended and no one kicked somebody
elses a...

Now for the technical: Open all the feedback paths and measure gain and
phase is a method I know. But first it is very much work, second sure
there are feedback paths which you hardly identify as them. I mean
parasitic capacitance in transistors and so on.
After all, even when I've identified all this paths, how can I open a
feedback path made of a capacitor which is buried in a trnsistor model?
Maybe set its capacitance to 0.000001fF in the .MODEL statement ;-)
Very weird method.
New idea: Having the pole/zero in mind (It's yet not useless, gentlemen)
only poles near the jw axis contribute to any instability in a
significant way. These poles could be identified by making a .TRAN with
some sort of apprpriate input signal (ideally a DIRAC, practically I
would prefer a periodical needle-like pulse.
Next step I FFT the output of the amp and should get the jw values of the
poles (peaks in the "frequency response".
Then I excite the system with sine bursts or wavelets where the sine has
one of the found frequencies. This could enable me to determine the
damping factor and thus the sigma of the investigated pole.

Is this nonsense, did I invent the wheel twice or am I super smart;-)?

Looking forward to a lot more discussion

Oliver Friedrich

Your being way, way to complicated. Whacking it between the rails should
be enough. The rate at which oscillations increases or die down gives a
good indication of how stable it is. Do this for lots of component
variations, especially worst case.

Kevin Aylward
[email protected]
http://www.anasoft.co.uk
SuperSpice, a very affordable Mixed-Mode
Windows Simulator with Schematic Capture,
Waveform Display, FFT's and Filter Design.
 
M

Mike Engelhardt

Jan 1, 1970
0
Oliver,
...Then I excite the system with sine bursts or wavelets where the
sine has one of the found frequencies. This could enable me to
determine the damping factor and thus the sigma of the
investigated pole...

Extracting frequency domain behavior from the time domain circuit
is a common method seen in SMPS design both on the bench and in
simulation and is called frequency response analysis. Its an
important method anytime you're looking at closing a feedback loop
about a modulated switching carrier, since the standard SPICE
linearized circuit has no applicability as it doesn't average
the response over a cycle. However, I won't bother with it
for your circuit, since you can look right at the open loop
response from the closed loop circuit by Middlebrook's method
recommended previously. While yes, there are potentially many
feedback loops to check, intuition with usually help you pick
the important ones.

BTW, one problem with using time domain simulations to verify
stability in PSpice is that PSpice is unfortunately stuck on Gear
integration, a numerical method that adds non-physical damping
that increases with step size. PSpice is the only SPICE I know
of with this defect and I have seen it mislead people into
believing an unstable circuit was stable. You will need to run
the simulations also at a very small step size, some small fraction
of the highest frequency period you wish to investigate the
possiblity of instability, before relying on results from PSpice.

--Mike
 
Top