0.1+0.2-0.3=?

Hello,
Apologies if I'm doing something stupid, but could someone please explain why 0.1+0.2-0.3 apparently equals 5.5511e-017?
If this is confirmed, I find it quite worrying, so are there other such "features" that may be quietly affecting my results without me being aware of them?
Many thanks, Jon.

 Respuesta aceptada

Sean de Wolski
Sean de Wolski el 7 de Jul. de 2011

0 votos

stupid, no; common, yes.
In fact this is the most frequently asked question on here and CSSM.

2 comentarios

Jon
Jon el 7 de Jul. de 2011
Many thanks, I missed previous mentions of this. Glad it's not just me!
Sean de Wolski
Sean de Wolski el 7 de Jul. de 2011
You're welcome; welcome to MATLAB Answers!

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Más información sobre Startup and Shutdown en Centro de ayuda y File Exchange.

Preguntada:

Jon
el 7 de Jul. de 2011

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by