Services & Resources / Wolfram Forums
-----
 /
MathGroup Archive
2001
*January
*February
*March
*April
*May
*June
*July
*August
*September
*October
*November
*December
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 2001

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Zero does not equal Zero

  • To: mathgroup at smc.vnet.net
  • Subject: [mg31412] Re: Zero does not equal Zero
  • From: Mark Sofroniou <marks at wolfram.com>
  • Date: Sat, 3 Nov 2001 05:29:18 -0500 (EST)
  • Organization: Wolfram Research Inc
  • References: <9rlt9k$o10$1@smc.vnet.net>
  • Sender: owner-wri-mathgroup at wolfram.com

You can't use Equal or SameQ for you wants because they have a built in
tolerance that is larger than the difference you are seeking.

However, you can get the closest two bigfloats (1 significant ULP either
side) by simply using Interval.

In[1]:= x=Exp[ N[Pi/3, 20] ];

In[2]:= Interval[x]

Out[2]= Interval[{2.8496539082263614974, 2.8496539082263614975}]

Mark Sofroniou
Wolfram Research




  • Prev by Date: Re: Aligning equal signs
  • Next by Date: Mathematica 4.0 features
  • Previous by thread: Re: Foldlist Question
  • Next by thread: Re: Zero does not equal Zero