From: "John Miles" <[EMAIL PROTECTED]> Subject: Re: [time-nuts] Help w/integration problem Date: Mon, 2 Jan 2006 00:49:19 -0800 Message-ID: <[EMAIL PROTECTED]>
> Never mind, I think I see what's wrong... you can't integrate the dBc/Hz > values directly. You have to turn them back into linear ratios, do the > interval sum, and then, if you want dBc coming out, take 10*log10(sum). You are almost there... you need to square the linears sum, which is quickly done... sum = 0 sum = sum + pow(10,value[1]/10) sum = sum + pow(10,value[2]/10) ... sum = sum + pow(10,value[n]/10) rms = sqrt(sum) dBc = 10 * log10(sum) Normally you would use pow(10,value[1]/20) etc. to get the amplitudes back, but RMS is about summing the power and that is the amplitude square as you recall. Hmm... I'm less a math-freak this morning than usual. A good morning it is anyway. Cheers, Magnus > -- john, KE5FX > > > -----Original Message----- > > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] > > Behalf Of John Miles > > Sent: Monday, January 02, 2006 12:00 AM > > To: Discussion of precise time and frequency measurement > > Subject: [time-nuts] Help w/integration problem > > > > > > Does anyone have a piece of C (BASIC, whatever) code that turns > > an array of > > dBc/Hz values into integrated RMS noise? > > > > I'm trying to use a simple rectangular integrator to divide a log-log plot > > into "bins": > > > > for (i=L_column; i < U_column-1; i++) > > { > > sum += ((value[i] - ((value[i] - value[i+1]) / 2.0)) * > > (frequency[i+1] - frequency[i])); > > } > > > > This just takes the midpoint dBc/Hz value between successive columns of a > > phase-noise plot, multiplies it by the frequency step between the > > columns in > > question, and sums the result for all columns in the range of interest. > > > > The output of this process, when I feed a typical noise graph with values > > around -110 dBc/Hz to it, with frequency values at the lower and upper > > limits of 1000 and 10000 Hz, is around -1E+6. What I'd *like* is a value > > corresponding to the "-63 dBc" value cited on pages 7 and 8 in > > this Zarlink > > app note: > > > > http://assets.zarlink.com/CA/Phase_Noise_and_Jitter_Article.pdf > > > > In this note, the author shows a noise curve similar to the ones > > I'm working > > with, and magically pulls -63 dBc out of the ether with no explanation of > > the integration process that obtained it. (What does it mean, in the > > author's words, to take the area "under" a phase-noise curve, anyway? > > What's the bottom dBc/Hz value?) > > > > Being from the instant-gratification generation, I really don't want (and > > won't understand) a calculus lecture. I want the 5 lines of code that do > > the integration. :-) This is for the next release of my freeware GPIB > > noise-measurement app, so your karma will be integrated along > > with the noise > > if you're able to help! > > > > -- john, KE5FX > > > > > > _______________________________________________ > > time-nuts mailing list > > [email protected] > > https://www.febo.com/cgi-bin/mailman/listinfo/time-nuts > > > > > _______________________________________________ > time-nuts mailing list > [email protected] > https://www.febo.com/cgi-bin/mailman/listinfo/time-nuts _______________________________________________ time-nuts mailing list [email protected] https://www.febo.com/cgi-bin/mailman/listinfo/time-nuts
