bugGNU Octave - Bugs: bug #51861, loglog() does not handle negative...

 
 

bug #51861: loglog() does not handle negative data and zero properly

Submitted by:  Dmitri A. Sergatskov <dasergatskov>
Submitted on:  Sun 27 Aug 2017 02:15:33 AM UTC  
 
Category: PlottingSeverity: 3 - Normal
Priority: 5 - NormalItem Group: Unexpected Error
Status: FixedAssigned to: None
Originator Name: Open/Closed: Closed
Release: devOperating System: Any

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

(Jump to the original submission Jump to the original submission)

Tue 29 Aug 2017 05:54:14 PM UTC, comment #8:

Dmitri, that error is caused by manually setting the axes limits to invalid limits with "axis" (a(1) is 0). The code path for auto limits and manual limits is different. Manually setting the limits still results in the error you see. This is indeed bug #43606.

The patch there no longer applies to a current tip. I will have a look whether I can refresh it.

Markus Mützel <mmuetzel>
Project Member
Tue 29 Aug 2017 03:09:43 PM UTC, comment #7:

Unfortunately it still does not fix the original issue

I still get misterious

but perhaps this is for another bug report.

Dmitri.
--

Dmitri A. Sergatskov <dasergatskov>
Tue 29 Aug 2017 02:55:33 PM UTC, comment #6:

Markus: I checked and 4.0.3 handled this correctly so I pushed your changeset to stable and merged with default.

http://hg.savannah.gnu.org/hgweb/octave/rev/20dd13700c08
http://hg.savannah.gnu.org/hgweb/octave/rev/882dd1c0017f

It seems to work for me, so I'm closing as fixed.

John W. Eaton <jwe>
Project Administrator
Sun 27 Aug 2017 11:30:42 AM UTC, comment #5:

The patch in bug #43606 does NOT fix the problem here. (Although it fixes a similar issue with manually set limits.)

The attached patch fixes the calculation of automatic limits on logarithmic axes if the maximum value is at exactly 0.

(file #41678)

Markus Mützel <mmuetzel>
Project Member
Sun 27 Aug 2017 08:22:05 AM UTC, comment #4:

This might be due to bug #43606. Plotting the 3 points intermittently sets the xlim to [-1 -0] (invalid for a log axis). This messes up the axes to a state from which it cannot recover. The following slightly reduced example also triggers the bug for me:

I will try whether the patch in that bug report also prevents the issue here.

Markus Mützel <mmuetzel>
Project Member
Sun 27 Aug 2017 07:49:05 AM UTC, comment #3:

Perhaps. I see the same. Still a problem though.

Dmitri.
--

Dmitri A. Sergatskov <dasergatskov>
Sun 27 Aug 2017 05:48:15 AM UTC, comment #2:

Actually, isn't this a problem with broadcasting or some such? The code that causes the issue has 3 x-values but only 1 y-value. If I modify it to have an equal number of x and y values then I get the expected error:

Rik <rik5>
Project Administrator
Sun 27 Aug 2017 02:16:59 AM UTC, comment #1:

I should have said "non-positive" rather than negative...

Dmitri.
--

Dmitri A. Sergatskov <dasergatskov>
Sun 27 Aug 2017 02:15:33 AM UTC, original submission:

With either 4.2.1 or recent hg:

That actually messes up graphics subsystem for good, e.g. doing
simple plot(1:3) results in the same "error: set: "cameratarget" must be finite"

Note, one needs more than one illegal data to trigger this problem:

looks fine.

Dmitri.
--

Dmitri A. Sergatskov <dasergatskov>

 

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

Attach File(s):
   
   
Comment:
   

Attached Files
file #41678:  bug58161_logaxis_autolimit.patch added by mmuetzel (1KiB - application/octet-stream)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by jwe (Posted a comment)
  • -unavailable- added by mmuetzel (Posted a comment)
  • -unavailable- added by rik5 (Posted a comment)
  • -unavailable- added by dasergatskov (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only project members can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 7 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Tue 29 Aug 2017 02:55:33 PM UTCjweStatusPatch Submitted=>Fixed
      Open/ClosedOpen=>Closed
    Sun 27 Aug 2017 11:32:14 AM UTCmmuetzelStatusNeed Info=>Patch Submitted
      Releaseother=>dev
      Summaryloglog() does not handle multiple negative data properly=>loglog() does not handle negative data and zero properly
    Sun 27 Aug 2017 11:30:42 AM UTCmmuetzelAttached File-=>Added bug58161_logaxis_autolimit.patch, #41678
    Sun 27 Aug 2017 05:48:15 AM UTCrik5StatusNone=>Need Info

    Back to the top


    Powered by Savane 3.1-cleanup1