Craig Citro wrote: >> Okay, that seems like a valid point, though I still disagree. I think >> that we have two levels of consistency here: consistency with the >> function and consistency with the concept of interval arithmetic. I >> think that in this case, the interval arithmetic requirement is more >> specific, so you should be consistent with having intervals. >> > > Well, I guess this depends on your point of view. Robert B. and I > chatted about this thread when it started, and I think he convinced me > that the "right" point of view is that RIF is supposed to be a model > of \mathbb{R} that keeps track of errors for you -- that RIF is a > drop-in replacement for, say, RDF, and that it keeps track of > precision as you go. From this point of view, I think there's no > question of what the behavior of floor() should be. > > On the other hand, if you're just thinking of intervals as > intrinsically interesting objects, maybe this isn't as natural? I > guess I can just put the ball back in your court: Jason, what do > intervals mean to you? ;)
I agree with Robert; at least, that is my use-case for using intervals next semester in teaching numerical analysis. I speak from a programmatic point of view, though. I'd like to not be surprised that the following doesn't work: a=sin(floor(RIF( (1.1,1.2) ))) a.lower() a.upper() versus a=sin(floor(RIF((1.5,2.5)))) a.lower() a.upper() In other words, I don't think that the return type of floor() should depend on how big the interval is. If you are keeping track of errors, then I think floor(RIF(1.5, 2.5)) should return an interval (possibly a discrete analog, i.e., just the integers [1,2] in a class that acts like an interval). Thus, I think that floor(an interval in which all numbers have the same interval) ought to return an interval, where both endpoints are the same. Jason -- Jason Grout --~--~---------~--~----~------------~-------~--~----~ To post to this group, send an email to sage-devel@googlegroups.com To unsubscribe from this group, send an email to sage-devel-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-devel URL: http://www.sagemath.org -~----------~----~----~----~------~----~------~--~---