Re: why float

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



Waaaay back in my university days, in my Numerical Analysis course, I
remember one example in which using doubles everywhere (the obvious
solution) actually increased error and gave a less precise answer than
judicious application of floats in the right places.

Don't ask me to remember the precise example. That was a long time ago.

So, yes, even when memory is not an issue floats have their uses...
mostly for engineering applications, I would imagine.

.



Relevant Pages

  • Re: why float
    ... Aren't arithemetical operations with floats much ... remember one example in which using doubles everywhere (the obvious ... solution) actually increased error and gave a less precise answer than ... judicious application of floats in the right places. ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: When to use float (in teaching)
    ... the Turing Award in 1989 for his work on floating-point computations, ... initially floats or doubles. ... transferred to said hardware. ...
    (comp.lang.java.programmer)
  • Re: C performance
    ... >> This is why I was curious about promotion of floats to doubles and back to ... there's no implicit promotion of float to double. ... there's no support for long double wider than ... support 80 bit long doubles very will in Windows. ...
    (comp.lang.c)
  • Re: Rounding by prayer?
    ... John Harrison wrote: ... > You should normally use doubles. ... So the only reason to use floats is to save space, ...
    (comp.lang.cpp)
  • Re: float, double and decimal
    ... floats and doubles - like a wrapper around floats and doubles. ... Double is an approximated format; ...
    (microsoft.public.dotnet.languages.csharp)