plot2d evaluates the function being plotted outside the
f(x):= if (x>1) then 0 else x^2$
The plot shows the function dropping to 0 at x=1+eps.
This is bad for three reasons:
1) I explicitly asked for the range [0,1]. I do not want to
see the behavior for x>1.
2) I don't want the y-range to be distorted by an outlier at
3) the function may not be well-defined, and may cause
errors, outside the range I gave. (This is how I
discovered the issue.)
Plot2d also evaluates the function at twice as many
values as it uses (to check for smoothness) -- I'd think
we could do better than that, but maybe not.
Log in to post a comment.