bugGNU Octave - Bugs: bug #66241, [octave forge] (signal)...

 
 

bug #66241: [octave forge] (signal) findpeaks.m: wrong calculation of width

Submitter:  Andreas Weber <andy1978>
Submitted:  Sat 21 Sep 2024 06:50:23 AM UTC
   
 
Category:  Octave Package Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Incorrect Result
Status:  Ready For Test Assigned to:  lostbard
Originator Name:  Open/Closed:  * Open
Release:  * 9.2.0 Operating System:  * Any
Fixed Release:  None Planned Release:  None
* Mandatory Fields

Post a Comment

Add a New Comment Rich Markup
   

Discussion

Sun 22 Sep 2024 08:23:40 PM UTC, comment #1: 

patch pushed to repo - it will appear in the next release

John Donoghue <lostbard>
Group Member
Sat 21 Sep 2024 06:50:23 AM UTC, original submission:  

signal 1.4.6

findpeaks.m around line 295

width = sqrt (abs(1 / pp(1))) + xm;
if ( (width > maxW || width < minW) || ...
...
extra.roots(struct_count,1:2)= xm + [-width width]/2;
-veratim-

This raises two problems:
1.) The check for MaxPeakWidth and MinPeakWidth are position dependent
(a peak with higher X-position would excess the MaxPeakWidth boundary although it has the same width as a previous one)
2.) The returned roots are not symmetrical to the position of the peak because xm is also added to width.

The comming patch fixed both and adds a test

Andreas Weber <andy1978>
Group Member

 

Attached Files

Attached Files
file #56442:  findpeaks_width.patch added by andy1978 (2.3KiB - text/x-patch)

(Note: upload size limit is set to 4.0MiB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

 

Dependencies

This item does not depend on any other items.

No items depend on this one.

 

Mail Notification Carbon-Copy List

Carbon-Copy List
  • -email is unavailable- added by lostbard (Updated the item)
  • -email is unavailable- added by andy1978 (Submitted the item)
  •  

    Votes

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only group members can vote.

     

    History

    Follow 4 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2024-09-22 lostbard StatusPatch Submitted Ready For Test
    2024-09-21 lostbard Assigned toNone lostbard
    2024-09-21 andy1978 StatusNone Patch Submitted
    2024-09-21 andy1978 Attached File- Added findpeaks_width.patch, #56442

    Back to the top

    Powered by Savane 3.16-11ef.
    Corresponding source code