Meilleur auteur de réponses
Excel 2010 calculation inexact

Question
-
Hello Everyone,
It is found
-------------------
Put 1.01 in one cell (for example in A1).
1.01*1.01*1.01=1.030301.
However if one calculates formula
(1) =A1*A1*A1-A1
(2) =A1*(A1+1)*(A1-1)
(3) =1.030301-A1
(4) =1.030301-1.01
(1),(3),(4) give 0.0203009999999999
(2) gives 0.02030100000000000.
If one uses (2)-(4), then Excel 2010 shows -1.14492E-16.
The calculation can be done as the integer multiplication/subtract and should return the exact result. Only (2) gives the correct answer.-------------------
Can anyone replicate this? Is it a known bug?
Thanks.
Réponses
-
Bonjour,Regarde ici (have a look here) :http://blogs.office.com/b/microsoft-excel/archive/2008/04/10/understanding-floating-point-precision-aka-why-does-excel-give-me-seemingly-wrong-answers.aspxDaniel
- Marqué comme réponse Aurel Bera jeudi 8 novembre 2012 10:56
Toutes les réponses
-
Bonjour,Regarde ici (have a look here) :http://blogs.office.com/b/microsoft-excel/archive/2008/04/10/understanding-floating-point-precision-aka-why-does-excel-give-me-seemingly-wrong-answers.aspxDaniel
- Marqué comme réponse Aurel Bera jeudi 8 novembre 2012 10:56
-
Bonjour,
Pouvons-nous considérer que vous avez résolu votre problème?
N'hésitez pas à revenir et supprimer la réponse marquée si la solution n’est pas correcte. Merci !
Cordialement,
Aurel
-
Thanks for the response. As end user, I would consider that this problem at least existed since 2008. Why should I care how Microsoft implemented the above calculations? I could use the `scientific calculator` within accessories to get the correct answer however Excel is giving me the wrong answer. Many banks are using spreadsheet to produce the risk reports. ...
-