The standard seems to have a bad example value for TINY(0.0)
41 views
Skip to first unread message
pmk
unread,
Jun 17, 2022, 8:05:29 PM6/17/22
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Sign in to report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to
According to the standard (F'2018: 16.9.191), TINY(0.0) is 2**(-127) for 32-bit IEEE. I think that's off by a factor of 0.5. The smallest normal 32-bit IEEE-754 number is actually 2**(-126).
Every Fortran compiler to which I have access agrees with me and has TINY(0.0) == 2**(-126).
This error, if it is one, may also affect the example results for RANGE().
gah4
unread,
Jun 17, 2022, 8:37:33 PM6/17/22
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Sign in to report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to
Smallest significand of 1.0000000000000 and exponent of -126 agrees with you.
Personally, I think denormals were a bad idea. They give a tiny bit more exponent
range, but a lot more work.