octave-bug-tracker
[Top][All Lists]
Advanced

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

[Octave-bug-tracker] [bug #50820] pwelch incorrectly discards DC compone


From: Shri
Subject: [Octave-bug-tracker] [bug #50820] pwelch incorrectly discards DC component
Date: Mon, 17 Apr 2017 17:39:48 -0400 (EDT)
User-agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:52.0) Gecko/20100101 Firefox/52.0

URL:
  <http://savannah.gnu.org/bugs/?50820>

                 Summary: pwelch incorrectly discards DC component
                 Project: GNU Octave
            Submitted by: theillusiveman
            Submitted on: Mon 17 Apr 2017 09:39:47 PM UTC
                Category: Octave Forge Package
                Severity: 3 - Normal
                Priority: 5 - Normal
              Item Group: Incorrect Result
                  Status: None
             Assigned to: None
         Originator Name: 
        Originator Email: 
             Open/Closed: Open
         Discussion Lock: Any
                 Release: 4.2.1
        Operating System: Any

    _______________________________________________________

Details:

Current setup:
Windows 10, GNU Octave 4.2.1, Signal Package 1.3.2.

Procedure to replicate issue:

Generate any signal (or use existing one if desired) with a non-zero DC. Use
the pwelch() method using one second window, no overlap to get the power
spectrum. Observe the DC coefficient on the result.

What to expect?: 

The DC term to be the actual average of the signal.

What happens?:

The DC term is zero.

Additional info:

I used the attached code to test for the issue. I generated a sinusoid with
some DC offset. As a comparison, I generated the same graph on MATLAB. MATLAB
has the correct DC term while Octave does not. See the attached graphs to
observe the results. The graph name *_ML.png was generated in MATLAB. This
shows the proper DC term. Octave does not.



    _______________________________________________________

File Attachments:


-------------------------------------------------------
Date: Mon 17 Apr 2017 09:39:47 PM UTC  Name: pwtest.m  Size: 259B   By:
theillusiveman

<http://savannah.gnu.org/bugs/download.php?file_id=40424>
-------------------------------------------------------
Date: Mon 17 Apr 2017 09:39:47 PM UTC  Name: PW_Test_ML.png  Size: 23kB   By:
theillusiveman

<http://savannah.gnu.org/bugs/download.php?file_id=40425>
-------------------------------------------------------
Date: Mon 17 Apr 2017 09:39:47 PM UTC  Name: PW_Test_Oct.png  Size: 14kB   By:
theillusiveman

<http://savannah.gnu.org/bugs/download.php?file_id=40426>

    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?50820>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

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