Moving on from identity and equality of objects, different notions of equality are also surprisingly subtle in some numerical realms.As comes up from time to...
Moving on from identity and equality of objects, different notions of equality are also surprisingly subtle in some numerical realms.As comes up from time to time and is often surprising, the "==" operator defined by IEEE 754 and used by Java for comparing floating-point values (JLSv3 §15.21.1)is not an equivalence relation. Equivalence relations satisfy three properties, reflexivity (something is equivalent to itself), symmetry (if a is equivalent to b, b is equivalent to...
Moving on from identity and equality of objects, different notions of equality are also surprisingly subtle in some numerical realms.As comes up from time to time and is often surprising, the "=="...
Catching up on writing about more numerical work from years past, the second article in a two-part series finished last year discusses some low-level...
Catching up on writing about more numerical work from years past, the second article in a two-part series finished last year discusses some low-level floating-point manipulations methods I added to the platform over the course of JDKs 5 and 6.Previously, I published a blog entry reacting to the first part of the series.JDK 6 enjoyed several numerics-related library changes. Constants for MIN_NORMAL, MIN_EXPONENT, and MAX_EXPONENT were added to the Float and Double classes. I...
Catching up on writing about more numerical work from years past, the second article in a two-part series finished last year discusses some low-level floating-point manipulations methods I added to...
Writing up a piece of old work for some more Friday fun, an example oftesting where the failures are likely to be led to my independent discovery of a bug in...
Writing up a piece of old work for some more Friday fun, an example oftesting where the failures are likely to be led to my independent discovery of a bug in the FDLIBM pow function, one of only two bugs fixed in FDLIBM 5.3.Even back when this bug was fixed for Java some time ago (5033578), the FDLIBM library was well-established, widely used in the Java platform and elsewhere, and already thoroughly tested so I was quite proud my tests found a new problem. The next most...
Writing up a piece of old work for some more Friday fun, an example oftesting where the failures are likely to be led to my independent discovery of a bug in the FDLIBM pow function, one of only two...
One of the more obscure language changes included back in JDK 5 was the addition of hexadecimal floating-point literals to the platform. As the name implies,...
One of the more obscure language changes included back in JDK 5 was the addition of hexadecimal floating-point literals to the platform. As the name implies, hexadecimal floating-point literals allow literals of the float and double types to be written primarily in base 16 rather than base 10. The underlying primitive types use binary floating-point so a base 16 literal avoids various decimal ↔ binary rounding issues when there is a need to specify a floating-point value with...
One of the more obscure language changes included back in JDK 5 was the addition of hexadecimal floating-point literals to the platform. As the name implies, hexadecimal floating-point literals allow...
I was heartened to recently come across the article Java's new math, Part 1: Real numberswhich detailed some of the additions I made to Java's math libraries...
I was heartened to recently come across the article Java's new math, Part 1: Real numberswhich detailed some of the additions I made to Java's math libraries over the years in JDK 5 and 6, including hyperbolic trigonometric functions (sinh, cosh, tanh),cube root, and base-10 log.A few comments on the article itself, I would describe java.lang.StrictMath as java.lang.Math's fussy twin rather than evil twin. The availability of the StrictMath class allows developers who need...
I was heartened to recently come across the article Java's new math, Part 1: Real numberswhich detailed some of the additions I made to Java's math libraries over the years in JDK 5 and 6, including...
At times it is useful to summarize a set of values, say a vector of real numbers, as a single number representing the set's size. For example, distilling...
At times it is useful to summarize a set of values, say a vector of real numbers, as a single number representing the set's size. For example, distilling benchmark subcomponent scores into an overall score. One way to do this is to use a norm. Mathematically, a norm maps from a vector V of a given number of elements to a real number length such that the following properties hold: norm(V) ≥ 0 for all V and norm(V) = 0 if and only if V = 0 (positive definiteness) norm(c · V) =...
At times it is useful to summarize a set of values, say a vector of real numbers, as a single number representing the set's size. For example, distilling benchmark subcomponent scores into an...
Next week on Wednesday, October 11, at the Silicon Valley ACCU meeting in San Jose, I'll be giving a version of my talk on What Every Computer Programmer Should...
Next week on Wednesday, October 11, at the Silicon Valley ACCU meeting in San Jose, I'll be giving a version of my talk on What Every Computer Programmer Should Know About Floating-Point Arithmetic, previously seen at Stanford and JavaOne. The meeting is open to the public and free of charge, so if you've ever wondered why adding up ten copies of 0.1d doesn't equal 1.0 or doubted the need for a floating-point value that is not a number, come on by.After the talk, I'll post a...
Next week on Wednesday, October 11, at the Silicon Valley ACCU meeting in San Jose, I'll be giving a version of my talk on What Every Computer Programmer Should Know About Floating-Point Arithmetic,...
For a number of years, the venerable IEEE 754 standard for binary floating-point arithmetic has been undergoing revision and the committee's results will soon...
For a number of years, the venerable IEEE 754 standard for binary floating-point arithmetic has been undergoing revision and the committee's results will soon be up for ballot. Back in 2003, I was editor of the draft for a few months and helped incorporate the decimal material.The balloting process provides the opportunity for interested parties, such as consumers of the standard, to weigh in with comments; instructions for joining the ballot are available. The deadline for...
For a number of years, the venerable IEEE 754 standard for binary floating-point arithmetic has been undergoing revision and the committee's results will soon be up for ballot. Back in 2003, I...
I'm a part-time master's student in Stanford's ICME program and at the departmental seminar I recently gave a talk, What Every Computer Programmer Should Know...
I'm a part-time master's student in Stanford's ICME program and at the departmental seminar I recently gave a talk, What Every Computer Programmer Should Know About Floating-Point Arithmetic. This is a refinement and update of JavaOne talks I've given with a similar title.
I'm a part-time master's student in Stanford's ICME program and at the departmental seminar I recently gave a talk, What Every Computer Programmer Should Know About Floating-Point Arithmetic. This is...