Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
M8
 
Posts: n/a
Default ROUNDDOWN Excell function

I can't get ROUNDDOWN to work with embedded operations.
For instance:
=ROUNDDOWN(7-1,0) returns 6
BUT
=ROUNDDOWN(((7-1)/3),0) will return 1 instead of 2

what is going on?
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Bob Phillips
 
Posts: n/a
Default ROUNDDOWN Excell function

I get 2. Excel 2000, XP Pro

--

HTH

Bob Phillips

(remove nothere from the email address if mailing direct)

"M8" wrote in message
...
I can't get ROUNDDOWN to work with embedded operations.
For instance:
=ROUNDDOWN(7-1,0) returns 6
BUT
=ROUNDDOWN(((7-1)/3),0) will return 1 instead of 2

what is going on?



  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Roger Govier
 
Posts: n/a
Default ROUNDDOWN Excell function

Hi

It quite rightly returns 2 for me. Are you sure that's what you have
typed in your cell? What happens if you press F9?

--
Regards

Roger Govier


M8 wrote
I can't get ROUNDDOWN to work with embedded operations.
For instance:
=ROUNDDOWN(7-1,0) returns 6
BUT
=ROUNDDOWN(((7-1)/3),0) will return 1 instead of 2
what is going on?






  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
JE McGimpsey
 
Posts: n/a
Default ROUNDDOWN Excell function

What version of XL are you using?

=ROUNDDOWN(((7-1)/3),0)

returns 2 in Mac XL04.

If instead of 7, 1 and 3, you're using references to cells with
formulae, it's possible that there are rounding errors in your formulae
that are causing the ROUNDDOWN() to round to 1.

For instance, if the cell displaying 7 instead contains a formula
returning

6.999999999999993

due to rounding errors, the ROUNDDOWN will operate on the stored value,
rather than the displayed value.

In article ,
"M8" wrote:

I can't get ROUNDDOWN to work with embedded operations.
For instance:
=ROUNDDOWN(7-1,0) returns 6
BUT
=ROUNDDOWN(((7-1)/3),0) will return 1 instead of 2

what is going on?

  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Jerry W. Lewis
 
Posts: n/a
Default ROUNDDOWN Excell function

As other's have noted, no version of Excel behaves as you describe. Assuming
that you have simplified from calculated values to constants as the arguments
to ROUNDDOWN, you may find the D2D() function at
http://groups.google.com/group/micro...06871cf92f8465
to be helpful in understanding.

Excel will display no more than 15 digits, but it takes 17 digits to
uniquely identify an IEEE standard double precision number. Excel (and
almost all general purpose software) follows the IEEE standard for double
precision storage of binary numbers. Most terminating decimal fractions are
non-terminating binary fractions that can only be approximated (just as 1/3
can only be approximated in decimal). As a result, floating point
calculations that you may think should result in an integer result, may
actually have a very small difference from that result due to binary
approximation. Normally this has no more impact on calculations than the
expected approximations associated with irrational numbers or non-terminating
decimal fractions, but it can be magnified by rounding to produce unexpected
results.

To work around this unavoidable consequence of finite precision binary math,
you might need to include a protective fuzz factor. For instance, if the
numerator calculation should produce a 3 decimal place result, then you might
use something like
=ROUNDDOWN((calc+.00001)/3,0)

Jerry

"M8" wrote:

I can't get ROUNDDOWN to work with embedded operations.
For instance:
=ROUNDDOWN(7-1,0) returns 6
BUT
=ROUNDDOWN(((7-1)/3),0) will return 1 instead of 2

what is going on?

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
UDF help please Adam Kroger Excel Discussion (Misc queries) 3 December 17th 05 07:21 PM
Date & Time mully New Users to Excel 4 May 23rd 05 11:56 AM
Conversion SVC Excel Worksheet Functions 9 February 28th 05 02:29 PM
Using the mail merge function from excell Sheila Excel Discussion (Misc queries) 1 February 18th 05 11:45 PM
HOW CAN I GET OFFICE 2003 EXCEL BASIC TO NEST FUNCTIONS LIKE EXCE. Robert AS Excel Worksheet Functions 4 December 2nd 04 10:49 AM


All times are GMT +1. The time now is 01:51 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"