Source code for pbrt, the renderer described in the third edition of "Physically Based Rendering: From Theory To Implementation", by Matt Pharr, Wenzel Jakob, and Greg Humphreys.
The current implementation is based on maintaining an interval, which is fine, but has diverged (already) from the book text.
Krämer's paper "A priori worst-case error bounds for floating-point computation" (http://www.acsel-lab.com/arithmetic/arith13/papers/ARITH13_Kramer.pdf) outlines how to compute bounds using a computed value and an error interval; it would be nice to use his method to fix the bugs that caused the original shift to the interval-based approach (46de256c0f4dab46af04da4e2436a61d10625e23) and get things back in better sync with the book text.
The current implementation is based on maintaining an interval, which is fine, but has diverged (already) from the book text.
Krämer's paper "A priori worst-case error bounds for floating-point computation" (http://www.acsel-lab.com/arithmetic/arith13/papers/ARITH13_Kramer.pdf) outlines how to compute bounds using a computed value and an error interval; it would be nice to use his method to fix the bugs that caused the original shift to the interval-based approach (46de256c0f4dab46af04da4e2436a61d10625e23) and get things back in better sync with the book text.