Dario Stepanos

Greenhorn

Posts: 14

posted 11 years ago

Hi,

I understand what the IEEEremainder method does, but could anyone give me a real-life application of why would I prefer using the IEEEremainder method rather than the modulo operation? (I don't need the code, it's just I can figure out what it would be useful for, and my search on the subject was inconclusive.)

Secondly, there are many articles related to IEEE 754 floating-point standard. Is it really important as a programmer to know those things? It's just because there's a 79 page document to read, and before reading it I'd like to know it is as much important as they say.

Thanks a lot to all of you ranchers!

I understand what the IEEEremainder method does, but could anyone give me a real-life application of why would I prefer using the IEEEremainder method rather than the modulo operation? (I don't need the code, it's just I can figure out what it would be useful for, and my search on the subject was inconclusive.)

Secondly, there are many articles related to IEEE 754 floating-point standard. Is it really important as a programmer to know those things? It's just because there's a 79 page document to read, and before reading it I'd like to know it is as much important as they say.

Thanks a lot to all of you ranchers!

posted 11 years ago

IEEEremainder() and a deep knowledge of the IEEE floating-point standard are important if, and probably only if, you're doing relatively serious numeric computing (Monte Carlo simulation, quantum chemistry, large-scale modeling or statistics). There are complex numerical algorithms in these areas whose results cannot be easily checked except by comparing their results to a "gold standard", some previous well-known good implementation. In this case, you need to ensure that your results are identical to the last bit to the gold standard, or your code is suspect.

Also, there are situations -- for example, adding very small and very large numbers -- where a relatively deep knowledge of floating-point math is necessary to ensure that you get the right results. But for computer graphics and other more common floating-point applications, none of this matters, at least not most of the time.

Also, there are situations -- for example, adding very small and very large numbers -- where a relatively deep knowledge of floating-point math is necessary to ensure that you get the right results. But for computer graphics and other more common floating-point applications, none of this matters, at least not most of the time.