Re: Interval arithmetic bug

*To*: mathgroup at smc.vnet.net*Subject*: [mg90793] Re: Interval arithmetic bug*From*: "David W.Cantrell" <DWCantrell at sigmaxi.net>*Date*: Thu, 24 Jul 2008 04:54:06 -0400 (EDT)*References*: <g670mq$s3n$1@smc.vnet.net>

green tea <cetech07 at gmail.com> wrote: > In[1]:= Limit[Sin[x], x -> Infinity] > > Out[1]= Interval[{-1, 1}] > > In[2]:= Limit[Sin[x + Pi/4], x -> Infinity] > > Out[2]= Interval[{-Sqrt[2], Sqrt[2]}] Of course, we would like Out[2] to be the same as Out[1]. But I'm not sure this behavior, shown in Out[2], should be called a bug. It's not new to version 6, and I suppose that WR has long been aware of it. Note that Out[2] contains Out[1] as a subinterval. Thus, containment has not been violated. David > In[3]:= TrigExpand[Sin[x + Pi/4]] > > Out[3]= Cos[x]/Sqrt[2] + Sin[x]/Sqrt[2] > > In[4]:= (Limit[#1, x -> Infinity] & ) /@ {Cos[x]/Sqrt[2], > Sin[x]/Sqrt[2]} > > Out[4]= {Interval[{-(1/Sqrt[2]), 1/Sqrt[2]}], > Interval[{-(1/Sqrt[2]), 1/Sqrt[2]}]} > > In[5]:= Plus @@ % > > Out[5]= Interval[{-Sqrt[2], Sqrt[2]}] > > In[6]:= $Version > > Out[6]= "6.0 for Microsoft Windows (32-bit) (May 21, 2008)" > > oh my god..