If function causing 'accuracy' problem

GuyE

New Member
Joined
Nov 29, 2005
Messages
4
I placed a question here yesterday and I guess It wasn't clear enough. I am attaching an excel sheet example but In case it doesn't show up properly, I will describe my problem. I have two identical cells B8=C5, both with positive values. in addition I have a positive value in cell C4. I wrote the following formula in cell C6: "=IF(C4>0,C5-B8,0)". since C5=B8, C5-B8=0, therefore the only solution to the formula has to be 0. for some reson I am receiving a n answer close to 0 but not accurat )9.09494701772928E-13). WHY?
Please see the displayes sheet.
Cell C6 returns an unwanted answer using "IF".
Cell C7 returns the 'proper' answer.
Why aren't the answers identical?
Book2.xls
ABCDE
4condition8000
5Openingbalance50675067
6using"if"function9.09495E-13
7the'required'answerofthe"if"function-
8closingbalance50675067
Sheet1


Thanks for any help here. and sorry again for not being clear yesterday
 

Excel Facts

Does the VLOOKUP table have to be sorted?
No! when you are using an exact match, the VLOOKUP table can be in any order. Best-selling items at the top is actually the best.
I can't reproduce that given what you have posted.

What's in C5, B8, C6 and C7 when formatted as General? Floating point arithmetic can return very small numbers instead of zero when subtracting.
 
Upvote 0
Is it just a formatting issue? What if you copy the format from C7 to C6?
 
Upvote 0

Forum statistics

Threads
1,224,586
Messages
6,179,730
Members
452,939
Latest member
WCrawford

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top