Re: the sky is falling down again [message #52341] |
Wed, 31 January 2007 12:15  |
JD Smith
Messages: 850 Registered: December 1999
|
Senior Member |
|
|
On Wed, 31 Jan 2007 11:52:06 -0700, R.G. Stockwell wrote:
Bob C. offers a good case where this could actually get you. Imagine a
free form plotting widget which allows you to zoom in arbitrarily. Now
imagine a very irregular data set being plotting, with spacings along the
abscissa down at the 10^-7 range, and up to 10. Zooming in to very small
ranges will cause this bug to bite, if you simply replot the entire data
set without trimming.
a=(b=[indgen(10)*1D-7,5,6,10.])
window,xsize=800,ysize=300
plot,a,b,PSYM=-4,XRANGE=[0.,1.e-6]
I'm surprised they round trip the plotting code through device (integer)
coordinates in this way first, rather than sticking with double for
all plot layout calculations until the very last stage, at which point
they could detect and clip off floating numbers that are out of range in
device coordinates system. Seems like asking for trouble.
JD
|
|
|