![]() In this example, the difference is 6 x 10 29. Two numbers can differ by 6 x 10 29 and still have the same floating-point form. On most machines, these exceptions simply abort the run. See the Floating-Point Arithmetic chapter in this Guide, or the man page ieee_handler(3m) for instructions on how to trap the various exceptions. It is quite common for many numerical applications to produce slightly different results on each floating-point implementation.Ĭheck for NaN, +Inf, and other signs of probable errors. If you have access to a VAX or some other system, run it there also. ![]() Doing so can also improve performance considerably, and make your Sun workstation behave more like a VAX system. Try running with a call nonstandard_arithmetic(). Review the Floating-Point Arithmetic chapter in this Guide. There can be subtle differences, even between IEEE machines. These functions are much more complicated than one might think, and the standard defines only the basic arithmetic functions. ![]() This is especially true if the mathematics involves many trigonometric functions. VAX math is not as good as IEEE math, and even different IEEE processors may differ. ![]() ![]() Numbers very close to zero can appear to be different, but the difference is not significant, especially if this number is the difference between two large numbers, such as the distance across the continent in feet, as calculated on two different computers. Pay attention to the size and the engineering units. Here are a few suggestions for what to try when programs ported to Sun Fortran do not run as expected. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |