On Mar. 17, 2013, Raymond Toy wrote
Edwin> If I call adaptive-plot (plot.lisp) appropriately with a function
like
Edwin> exp(x^3) to see what overflow
Edwin> causes adaptive-plot to return, I get, for example,
Edwin> the lisp list
>What exactly are you trying to achieve?
>
>Note that adaptive-float actually expects the function to have been
>generated by coerce-float-fun, which takes care to handle arithmetic
>errors and converts them to t.
Thanks for the feedback.
Indeed, I use the line
(setq fcn (coerce-float-fun fcn `((mlist), (second range))))
in my code, modeled after a simplified version of draw2d,
which calls adaptive-plot and which wants to inspect the
"result" list returned by adaptive-plot for either overflow
or T values for each subregion (of the "plotting" range),
with the number of subregions determined by NTICKS,
as is done in draw2d.
I want to *first* check the returned list "result" for any function
overflows
which gcl indicates with the list element #<1.#INF00e+000> which
evidently is not directly accessible to current maxima functions
ordinarily used, since using neither (numberp #<1.#INF00e+000>)
nor (float-nan-p #<1.#INF00e+000>) nor (float-inf-p #<1.#INF00e+000>)
nor ($floatnump #<1.#INF00e+000>) avoids lisp errors.
So far, based on the responses from you and Richard Fateman, it appears
that I will have to convert the list elements to strings and work with
strings to detect an overflow return from adaptive-plot.
Ted Woollett