[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #37410] image.m has a wrong check for linearly
From: |
Andreas Weber |
Subject: |
[Octave-bug-tracker] [bug #37410] image.m has a wrong check for linearly-spaced x and y |
Date: |
Sat, 12 Oct 2013 14:18:31 +0000 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130917 Firefox/17.0 Iceweasel/17.0.9 |
Follow-up Comment #5, bug #37410 (project octave):
I guess your testcase is
n = 743;
img = rand (n)*255;
x = y = linspace (0, 10.43, n);
image(x, y, img)
Why do we need std in the linearity check? Isn't something like
tol = 10 * eps;
dx = diff (x);
dy = diff (y);
dx_maxmin = max (dx) - min(dx);
dy_maxmin = max (dy) - min(dy);
if (dx_maxmin > tol || dy_maxmin > tol)
...
sufficient? Regards, Andy
_______________________________________________________
Reply to this item at:
<http://savannah.gnu.org/bugs/?37410>
_______________________________________________
Nachricht gesendet von/durch Savannah
http://savannah.gnu.org/
- [Octave-bug-tracker] [bug #37410] image.m has a wrong check for linearly-spaced x and y,
Andreas Weber <=