Thread Links Date Links
Thread Prev Thread Next Thread Index Date Prev Date Next Date Index

Re: text2interval again /



RF> set_rounding_mode(negative_infinity)
RF> y:=sin(x)
RF>
RF>   is not the kind of thing supported anyplace I know of, to get
RF> a lower bound on sin(x). Perhaps you know of such a system?


I think IBM's AIX on PowerPC, Linux on PowerPC, z/OS on z/Series, and others support this, not just for sin() but also for things like printf().

- Ian McIntosh          IBM Canada Lab         Compiler Back End Support and Development


Inactive hide details for Richard Fateman ---03/08/2013 02:39:51 AM---On 3/7/2013 8:52 PM, Michel Hack wrote: > Richard FatemanRichard Fateman ---03/08/2013 02:39:51 AM---On 3/7/2013 8:52 PM, Michel Hack wrote: > Richard Fateman wrote:


    From:

Richard Fateman <fateman@xxxxxxxxxxxxxxxxx>

    To:

Ian McIntosh/Toronto/IBM@IBMCA

    Date:

03/08/2013 02:39 AM

    Subject:

Re: text2interval again /




. . .
On 3/7/2013 8:52 PM, Michel Hack wrote:
    . . .
    If the sign of the error is known -- and it can be known when directed
    rounding is used appropriately -- then this is perfectly ok.
This is pretty unlikely, it seems to me.  Most programming environments do not
support directed rounding in any convenient or portable fashion and so few
mathematical libraries use them.  And if they were used, it would be in internal
forms to achieve a final result which was correctly rounded to nearest.

That is, something like:

set_rounding_mode(negative_infinity)
y:=sin(x)

 is not the kind of thing supported anyplace I know of, to get
a lower bound on sin(x). Perhaps you know of such a system?
I suspect that most subroutines assume the rounding mode is
set to nearest.  If it is not, they get some  answer, possibly not the
right answer. After all, a negative number rounded would be reversed
in direction....   Or perhaps some system routines set the rounding mode,
thereby ignoring any prior specification. Or the rounding mode is reset
in some context switch in the operating system and the user has no
real control of it, anyway.

. . .

GIF image

GIF image