Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Strange math problem

2 views
Skip to first unread message

Curtis Coughlin

unread,
Dec 9, 2002, 11:25:29 PM12/9/02
to
When I enter the same formula one with paren's the other
without, I get a different value. The formulas are:
1) =ay54-ay140 --> result ""
2) =(ay54-ay140)--> result (0).

Simply adding the paren's creates some sort of remainder
where none should exist. I have the "Explode" add-in
installed and it confirms that there should be no
remainder. What gives?

Otto Moehrbach

unread,
Dec 10, 2002, 7:59:08 AM12/10/02
to
Curtis
I can't duplicate your problem on my 2002. Do your reference cells have
a value or are they blank? What do you mean when you say you get ""?
Nothing? A blank cell?
HTH Otto
"Curtis Coughlin" <ccou...@landservicesgroup.com> wrote in message
news:0bea01c2a004$2c093730$8df82ecf@TK2MSFTNGXA02...

BrianB

unread,
Dec 10, 2002, 8:28:23 AM12/10/02
to
1. Is it something to do with the cell formatting ?

2. Try formatting the cell with, say, 10 numbers after the decimal to
see if Excel shows anything.

Regards
BrianB
=================================================


"Curtis Coughlin" <ccou...@landservicesgroup.com> wrote in message news:<0bea01c2a004$2c093730$8df82ecf@TK2MSFTNGXA02>...

Jerry W. Lewis

unread,
Dec 10, 2002, 9:25:57 AM12/10/02
to
Not enough information given. What are in ay54 and ay140

In the absence of that information, I am guessing that you have checked
Tools|Options|View|Zero values, so that 1) is actually 0, not "". I am
also guessing that you have formatted the cell 2) to display negative
numbers in parentheses.

What is the rest of your format for the cell in 2)? If it is a fixed
decimal format, try changing to a General format, and you will likely
see a non-zero negative number. Most decimal fractions can only be
approximated in binary, so the Google archives contain numerous posts
where the user was expecting zero, but only got approximately zero.

An unlikely possibility is that you are actually getting negative zero.
IEEE 754 actually defines negative zero, which has some minor
advantage in working with complex numbers.

http://groups.google.com/groups?selm=6omfkn%24nsl%241%40joe.rice.edu

It is not at all clear to many mathematicians that this minor advantage
is worth the violence done to basic arithmetic properties of the reals.
Excel does have limited support for negative zero

http://groups.google.com/groups?selm=3DEF479F.4020003%40no_e-mail.com

but this may be an oversight. I have yet to find any way to produce
negative zero strictly within a worksheet or strictly within VBA. If
you have, please provide the details.

Jerry

Jerry W. Lewis

unread,
Dec 10, 2002, 10:05:01 AM12/10/02
to
I failed to mention that the reason for the difference with and without
parentheses (assuming that a fixed decimal format is preventing you from
seeing a number that is approximately zero) is that Excel attempts to
minimize questions due to finite precision arithmetic by zeroing out the
result of final subtractions if the result is beyond the precision of
the calculation. Adding parentheses around the formula bypasses this
feature, since the subtraction is then no longer the final operation.

Jerry

0 new messages