Forum Discussion

JLV_96's avatar
JLV_96
Copper Contributor
May 26, 2020
Solved

Sum function not working properly

I have an issue with the SUM function in excel where I have it sum numbers with only 2 decimals but the result is a longer decimal (example: 2.00000001). Here is my specific example I have a basic ...
  • JMB17's avatar
    May 27, 2020

    It is a rounding problem. The computer converts your numbers to binary, performs the calculations, then converts it back to base 10. There are some base 10 decimals that cannot be represented exactly as binary fractions. So, you can get small rounding errors.

    Any time you are working with decimals, you should round your calculations even if all of the inputs are only to a certain decimal place (especially if you are using something like IF(calcresult=x...).

    http://www.cpearson.com/Excel/rounding.htm

     

    Edit: but I'm assuming you've already checked the inputs and any precedent calculations as already suggested and confirmed that's not the problem.

Resources