[Kst] [Bug 164466] New: The Peak of the Kst Amplitude Spectrum is lower than the Amplitude Spectrum in Octave

Yiwen Mao yiwenv at live.ca
Thu Jun 19 19:51:57 CEST 2008


------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
         
http://bugs.kde.org/show_bug.cgi?id=164466         
           Summary: The Peak of the Kst Amplitude Spectrum is lower than the
                    Amplitude Spectrum in Octave
           Product: kst
           Version: unspecified
          Platform: unspecified
        OS/Version: Linux
            Status: UNCONFIRMED
          Severity: normal
          Priority: NOR
         Component: general
        AssignedTo: kst kde org
        ReportedBy: yiwenv live ca


Version:           1.7.0 (using KDE 4.0.1)
Installed from:    Unspecified
Compiler:          Fedora 6 
OS:                Linux

Problem: Use both Octave and Kst to plot the amplitude spectrum of the following function
f=(sin(5*pi*t)).^4+(cos(5*pi*t)).^5,where t ranges from 0 to 3

In Kst, the spectrum is set up as shown below:
The FFT length is 2^7
The sample rate is 265.99
The resulting spectrum is not viewed by an apodization function.
The mean is not removed

In Octave, the following is calculated before plotting the spectrum:
N=2^7;
t=linspace(0,3,N); %t is a vector with N linearly spaced elements between 0 and 3
Ts=t(2)-t(s); %sampling period
Ws=2*pi/Ts; %sampling rate = 265.99
W=Ws*(-N/2:(N/2)-1)/N; %frequecny vector


More information about the Kst mailing list