The Designer's Guide Community Forum https://designers-guide.org/forum/YaBB.pl Analog Verification >> Analog Functional Verification >> Question about Offset-Simulation of comparators https://designers-guide.org/forum/YaBB.pl?num=1290584745 Message started by mate on Nov 23rd, 2010, 11:45pm

Title: Question about Offset-Simulation of comparators
Post by mate on Nov 23rd, 2010, 11:45pm

Hi all,

i designed a latched comparator and performed a simulation like the one described in the paper 'A Methology for the Offset-simulation of comparators' http://www.designers-guide.org/Analysis/comparator.pdf from this website.

No I have some questions:

1. During the post-analysis in Matlab (code is at the bottom of this post) one defines

Code:
 % select values within -2.5 .. 2.5 sigmai=find(v>-2.5 & v < 2.5)

Why choose sigma = 2.5? At the end one defines

Code:
 sigma = 1/p(1)

This should be the sigma_offset. This value changes if I use another value than 2.5 within the find function. I'm now not sure why he took 2.5 sigma.

2. My result gives me a mu of 30mV and a sigma of 30mV (when calculated like described). Is this interpretation correct:
My threshold is now: threshold_ideal+mu, but how do i interpret this sigma?

3. Does anyone know any material/website about how get sigma and mu from the polynomial coefficients?

Thanks for your help!

-----
complete code:

Code:
 % it is assumed that the simulation results are provided% in the matrix "ydata" and the array "xdata"% (1) ni/N, Figure 2y = sum(ydata)/length(ydata);plot(xdata, y)% (2) inverse erf for rising slope only% y(1:21) is this case contains the data% for the rising slopev = sqrt(2)∗erfinv(y(1:21)∗2−1);% select values within −2.5 ... 2.5 sigmai=find(v>−2.5 & v<2.5)% fit line through selected values% Figure 5[p,s]=polyfit(xdata(i), v(i), 1);plot(xdata(i), v(i), xdata(i), polyval(p,x(i)))% (4) compute mu and sigmasigma = 1/p(1);mu = −p(2)/p(1);

Title: Re: Question about Offset-Simulation of comparators
Post by mate on Nov 24th, 2010, 1:57am

Hi,

i just want to add some of my results.

i have used

Code:
 i = find(v>-3 & v<3)

the results are: μ: 2.5m σ: 25m

Is that σ value (25m) now my 3σ already or do i have to multiply that one with 3 to get 3σ (which would be 75m) :-?

 Title: Re: Question about Offset-Simulation of comparators Post by AnalogDE on Dec 18th, 2010, 8:38am 25mV is your one-sigma offset.  You multiply by 3 to get your 3sigma or you can also read it off the graph.  Mu is your systematic offset.