Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Difference between PSD ( power density spectrum ) and Spectrum measurement in Cadence

Status
Not open for further replies.

NikosTS

Advanced Member level 4
Joined
Jan 30, 2017
Messages
119
Helped
1
Reputation
2
Reaction score
2
Trophy points
18
Activity points
1,054
Hello there,

I am doing a transient analysis on a 3rd order SD modulator ( MASH topology ) and i want to plot the power spectrum of the quantization noise.

Thing is, that i am confused on how to do that.
My first try was sending the output sequence to Measurement tab---> Spectrum and ploting the curve.
My second try was sending the output sequence to the calculator and using the psd() function , afterwards use db10() function and finally plotting.

The 2 above mentioned curves have the same slope but a constant difference between them of about 40 dB ( e.g the first curve has peak at -20 dB and the second at -60 dB).

Could you enlighten me as to which is the correct way?

Thank you
 

Use correct terminology.
There is no tool Cadence.

Must have exceeded the title length. It is in Virtuoso.

You use db20( dfft() ) not db10( psd() ) there.
However they have to be almost same if you use Cadence OCEAN functions.

Yes, one plot is dB20(dfft()) that is generated automatically when i process the output sequence through the Measurement Tab--->Spectrum
The second plot is dB10(psd()) and is generated if I send the output data to the calculator and use the psd() function.

The 2 plots are far from same though, they have around 40 dB constant difference.
 

Use correct terminology.
There is no tool Cadence.


Surely answer my questions in your previous thread.
https://www.edaboard.com/threads/364412/#8

You use db20( dfft() ) not db10( psd() ) there.
However they have to be almost same if you use Cadence OCEAN functions, if you set parameters correctly.

https://www.designers-guide.org/Forum/YaBB.pl?num=1242749411/3#3

Surely answer my questions in your previous thread.
https://www.edaboard.com/threads/364412/#8

Show us all results and their settings correctly with including the following.
https://www.edaboard.com/threads/364219/
 
Last edited:

I post again in case my previous posts weren't submitted correctly.
For all the following plots , the number of accumulator bits are N=14 and the input fractional word is 2037.
1) Scilab , using fft.
scilab_fft.jpg

2)Scilab, using pspect() function ( equivalent to periodogram function in Matlab )
scilab_pspect.jpg

3) Cadence Virtuoso, using fft() ( from Measurement tab---> Spectrum )
virtuoso_fft.jpg

4) Cadence Virtuoso, using psd() function ( from calculator )
virtuoso_psd.jpg

5) Ideal curve, plotted in Scilab
ideal.jpg
 

Ok, for all cases N=14 and input 2037 as before. Also sampling frequency is 1Ghz (10^9), let's call it Fs.

"Cout" is the output carry sequence with range [-3,4] from the 3rd order SD modulator and length 2*2^(N+1)=65536 samples ( 2 full sequence cycles as with an odd input , max sequence 2^(N+1) is guaranteed).

For SciLab:
Frequency construction : f=Fs*(1:length/2)/length -- ( frequency vector from 0 to Fs/2)

1) SciLab plot using fft()
spectrum=abs(fft(Cout)/(length/2))
spectrum=spectrum(1:length/2)^2
plot2d("ln",f(1:length-1),10*log10(spectrum)) -- (argument "ln" means that the x axis is logarithmic and the y axis is normal )

2) SciLab plot using pspect() function
spectrum=pspect(length/2,length,'hn',Cout)
plot2d("ln",f,10*log10(Cout(1:length)))

The arguments in pspect() function are : offset of each data window,number of points in window, window type (here Hanning), sampled vector)

3) Cadence Virtuoso using fft()
Start time : x ns
Stop time : (x + 2*length) ns
sample count/Freq= 2*length -- ( same result if i chose "length" sample count , but the maximum frequency would be Fs/2 )
Start/end Freq= 15.26k to 1G
Window type : Rectangular -- ( little to no difference with Hanning)

4) Cadence Virtuoso using psd()
Start/Stop : Same as above
Number of samples : 2*length
Window : Hanning
Smoothing factor : 1
Windows size : 2*length
Detrending Mode : Mean
Coherent gain : default
Coherent gain factor : 1

5) Ideal curve
spectrum= 1/(12*2^(N+1))* (2*sin(pi*f/Fs))^6 -- ( 3rd order SD modulator )
plot2d("ln",f,10*log10(spectrum))
 

Last edited by a moderator:

Last edited by a moderator:

........................................................................................
length 2*2^(N+1)=65536 samples ( 2 full sequence cycles as with an odd input , max sequence 2^(N+1) is guaranteed).
........................................................................................
3) Cadence Virtuoso using fft()
Start time : x ns
Stop time : (x + 2*length) ns
What value for them ?
What is x ?
What is x +. 2*length = x + 2*2*2^(N+1) = x + 2*65536 ?

Surely consider.

Start Time is x/fs ?
Stop Time is (x + 2*length)/fs ?

fs=1GHz
Nfft=2*2^(Nbit+1)=2*2^(14+1)=2^16=65536
 
Last edited:

What value for them ?
What is x ?
What is x +. 2*length = x + 2*2*2^(N+1) = x + 2*65536 ?

Surely consider.

For this simulation, x =2.125 ns approximately
So start time is : 2.125n and
stop time is : 2.125 + 2*2^15= (2.125 + 2*32768) ns
 


As you can see on the screenshot that i uploaded on the other thread, i have the correct values on the required fields.
( Start time : 2.125 ns
Stop time : (2.215 + 2*2^15) ns )
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top