The Designer's Guide Community Forum
https://designers-guide.org/forum/YaBB.pl
Simulators >> Circuit Simulators >> Transient Simulation in Cadence Spectre - Max Step vs. Strobe Delay
https://designers-guide.org/forum/YaBB.pl?num=1588778811

Message started by repah on May 6th, 2020, 8:26am

Title: Transient Simulation in Cadence Spectre - Max Step vs. Strobe Delay
Post by repah on May 6th, 2020, 8:26am

When doing an FFT in Cadence Spectre after running a transient simulation, what would be the difference between setting the Max Step vs. setting the strobe delay to the same value ?

What does one do vs. the other ?  What would the output represent with setting each ?


Title: Re: Transient Simulation in Cadence Spectre - Max Step vs. Strobe Delay
Post by Ken Kundert on May 6th, 2020, 11:59am

maxstep sets the maximum step size. It does not allow you to specify where the points are placed, just the maximum distance between points.

strobing does two things. First it forces time points to be placed at particular points in time that are equally spaced. Second, the simulator only outputs those points. In this sense, it works very much like a strobe light, if that is helpful. It is important the normal time step control is still operating, meaning that the simulator will place simulation points between the strobe points to maintain accuracy.

If you are interested in avoiding interpolation errors in your FFT, you should use strobing.

If your strobe points line up with your FFT sample points, then the spectrum you should see with or without strobing would be the same, except that the spectrum without strobing would be corrupted slightly by interpolation error.

-Ken

Title: Re: Transient Simulation in Cadence Spectre - Max Step vs. Strobe Delay
Post by Andrew Beckett on May 11th, 2020, 11:46pm

Also correcting an error in the title - it's strobeperiod not strobedelay that you should be setting. strobedelay is used to offset the strobe times by a certain amount of time, so for example strobeperiod=2u strobedelay=1u will strobe at 1u, 3u, 5u, 7u etc.

It's also possible to strobe (to get the points solved at the sample timepoints as Ken mentioned) but also output any other points which occur between. This is useful if you want to observe settling behaviour, and don't necessarily care about the data reduction benefits of strobing, and are only using it to produce sensible points for the DFT. That's achieved by setting strobeoutput=all

Andrew

Title: Re: Transient Simulation in Cadence Spectre - Max Step vs. Strobe Delay
Post by Ken Kundert on May 12th, 2020, 1:38am

Andrew, people often think of strobing as a data reduction technique. It almost never is, and if you think of it that way you can miss its true power.

I have found that strobing is useful for two things.

The most common is the FFT where it is used as a way to eliminate interpolation error. For this case, if you line things up just right, then you are free to use strobeoutput=all, however if you are not super careful and do not line things up just right, then using strobeoutput=all can re-introduce interpolation errors.  This is easy to do because if you output all points it is hard to know which points are the strobe points, and it is also very difficult to know where the FFT is placing its sample points.  This is a very error prone process where improvements the the environment would go a long way towards making FFT measurements easier and more accurate. What is needed is perhaps three things:
1. the best would be for environment to tell the simulator it is running and FFT and configure strobing so that the simulator places the points precisely where the FFT needs them. This is a rather obvious need that has been overlooked for a very long time.
2. without that, it would be nice if the simulator had the option to produce two data files, one with only the strobe points and one with all points. Then you could plot both and see exactly where the strobe points are, and what is happening between the strobe points (you generally want to be able to adjust strobe start so that strobe/sample points fall at the end of the cycle; this is easier if you can see both sets of points).
3. It would be great if the FFT produced two outputs as well, the time domain wafeform and the frequecy domain spectrum. That way a user could confirm that the FFT samples were placed where they are suppose to be (they could graphically confirm this important fact).  And with 2, the user could confirm that the stobe points and the FFT sample points were aligned.  It would be possible to do this with a Inverse FFT.

The second use of strobing is to suppress large periodic variations so as to be able to see small perturbations. For example, I often use strobing or sampling at the clock frequency when observing the output of switching power regulators as a way of suppressing the clock ripple. It makes my measurements much more sensitive and repeatable. I do the same with mixers, where I sample at the LO frequency.

-Ken

Title: Re: Transient Simulation in Cadence Spectre - Max Step vs. Strobe Delay
Post by Andrew Beckett on May 13th, 2020, 8:49am

Completely agree Ken, having this set up before you start the simulation would be a far better way to eliminate these kind of errors. I spend a lot of my time explaining how to correctly set up strobing for FFT, and why it matters if you get it wrong - and from a usage perspective it would be useful too.

With transient noise we do have the options to set up the Fourier analysis settings on the transient form (although there it's really about setting up the PSD), and then the direct plot form picks up the settings (which were provided to spectre) to ensure consistency in simulation setup and post-processing. It would be a natural thing to be able to do something similar with standard transient too.

When I have a moment, I'll see if I can push something like this along for transient setup. I think it would be worthwhile. I like some of your other suggestions too (not sure about creating a separate database for the strobed and non-strobed points - I can see why it's useful, but it could open up a can of worms). I'll have a think about those too...

Andrew.

Title: Re: Transient Simulation in Cadence Spectre - Max Step vs. Strobe Delay
Post by repah on May 28th, 2020, 2:59am

Thank you Andrew and Ken for your responses.

They have really informed my thinking about these issues.


The Designer's Guide Community Forum » Powered by YaBB 2.2.2!
YaBB © 2000-2008. All Rights Reserved.