help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: spectral density plot


From: Paul Kienzle
Subject: Re: spectral density plot
Date: Wed, 14 Feb 2001 18:21:50 +0000
User-agent: Mutt/1.2.5i

Here is a signal sampled at 11025 with spikes at 500, 1000, 1500, 2000, 2500 Hz

        fs=11025; t=0:1/fs:1; t=t(1:8192); x=sum(sin(2*pi*500*[1:5]'*t));

Here is its spectral plot:

        r = spectral_xdf(x);
        plot(r(:,1)*fs, r(:,2));

In your case, use fs=5000 and label your x-axis in MHz.

Paul Kienzle
address@hidden

On Wed, Feb 14, 2001 at 09:53:19AM -0700, Ben Sapp wrote:
> Hello, 
> 
> I am having a little trouble using the spectral density estimators in
> Octave.   I have a waveform with 500 samples.  Each sample is 200
> picoseconds apart.   I would like to make a plot of the spectral density
> vs. frequency.   Using spectral_xdf I am able to get a vector that is
> supposed to represents the spectral density.   The first column is a set
> of numbers from 0-1.  Should I scale these by some factor to get the
> frequencies? 
> 
> Thanks  
> 
> -- 
> Ben Sapp                         Los Alamos National Laboratory
> email: <mailto:address@hidden>   Phone: (505)667-3277
> Fax:   (505)665-7920             URL:   http://www.neutrino.lanl.gov/
> --
> 
> 
> 
> -------------------------------------------------------------
> Octave is freely available under the terms of the GNU GPL.
> 
> Octave's home on the web:  http://www.octave.org
> How to fund new projects:  http://www.octave.org/funding.html
> Subscription information:  http://www.octave.org/archive.html
> -------------------------------------------------------------
> 
> 



-------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.

Octave's home on the web:  http://www.octave.org
How to fund new projects:  http://www.octave.org/funding.html
Subscription information:  http://www.octave.org/archive.html
-------------------------------------------------------------



reply via email to

[Prev in Thread] Current Thread [Next in Thread]