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

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

[Octave-bug-tracker] [bug #58540] logscale does not handle very small po


From: Rik
Subject: [Octave-bug-tracker] [bug #58540] logscale does not handle very small positive data properly
Date: Wed, 10 Jun 2020 19:42:17 -0400 (EDT)
User-agent: Mozilla/5.0 (Windows NT 10.0; WOW64; Trident/7.0; rv:11.0) like Gecko

Update of bug #58540 (project octave):

                Priority:              5 - Normal => 3 - Low                
              Item Group:                    None => Unexpected Error       
                  Status:                    None => Confirmed              

    _______________________________________________________

Follow-up Comment #1:

Confirmed.  It's not just logscale.  Any very small values are likely to be a
problem.  Here is an example with plot().


x = 1:20;
y = eps(0)*x;
plot (x,y)
error: set: "dataaspectratio" must be finite
error: called from
    __plt__>__plt2vv__ at line 500 column 10
    __plt__>__plt2__ at line 247 column 14
    __plt__ at line 112 column 18
    plot at line 228 column 10


But, I think this may be an infrequent problem.  The magnitude of the numbers
you are working with are very, very small.


eps (0)
ans = 4.9407e-324
eps (1)
ans = 2.2204e-16


This is yet another example of the problems that OpenGL has because it uses
single precision rather than double precision.  This plot works


x = 1:20;
y = 1e-37 * x;
plot (x,y)


But this one already starts to show degradation


x = 1:20;
y = 1e-38 * x;
plot (x,y)


And it is no coincidence that


realmin ('single')
ans = 1.1755e-38


I'm marking as confirmed, but lowering the priority.  Octave probably needs to
switch to using double precision for plotting, but this is a big overhaul and
has been a requested feature for many years.


    _______________________________________________________

Reply to this item at:

  <https://savannah.gnu.org/bugs/?58540>

_______________________________________________
  Message sent via Savannah
  https://savannah.gnu.org/




reply via email to

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