Average Error: 0.0 → 0.0
Time: 3.6m
Precision: 64
Internal Precision: 128
\[\frac{1 + \frac{2 \cdot t}{1 + t} \cdot \frac{2 \cdot t}{1 + t}}{2 + \frac{2 \cdot t}{1 + t} \cdot \frac{2 \cdot t}{1 + t}}\]
\[\frac{1 - \left(\frac{2 \cdot t}{t + 1} \cdot \frac{2 \cdot t}{t + 1}\right) \cdot \left(\frac{2 \cdot t}{t + 1} \cdot \frac{2 \cdot t}{t + 1}\right)}{\left(\frac{2 \cdot t}{t + 1} \cdot \frac{2 \cdot t}{t + 1} + 2\right) \cdot \left(1 - \frac{2 \cdot t}{t + 1} \cdot \frac{2 \cdot t}{t + 1}\right)}\]

Error

Bits error versus t

Derivation

  1. Initial program 0.0

    \[\frac{1 + \frac{2 \cdot t}{1 + t} \cdot \frac{2 \cdot t}{1 + t}}{2 + \frac{2 \cdot t}{1 + t} \cdot \frac{2 \cdot t}{1 + t}}\]
  2. Using strategy rm
  3. Applied flip-+0.0

    \[\leadsto \frac{\color{blue}{\frac{1 \cdot 1 - \left(\frac{2 \cdot t}{1 + t} \cdot \frac{2 \cdot t}{1 + t}\right) \cdot \left(\frac{2 \cdot t}{1 + t} \cdot \frac{2 \cdot t}{1 + t}\right)}{1 - \frac{2 \cdot t}{1 + t} \cdot \frac{2 \cdot t}{1 + t}}}}{2 + \frac{2 \cdot t}{1 + t} \cdot \frac{2 \cdot t}{1 + t}}\]
  4. Applied associate-/l/0.0

    \[\leadsto \color{blue}{\frac{1 \cdot 1 - \left(\frac{2 \cdot t}{1 + t} \cdot \frac{2 \cdot t}{1 + t}\right) \cdot \left(\frac{2 \cdot t}{1 + t} \cdot \frac{2 \cdot t}{1 + t}\right)}{\left(2 + \frac{2 \cdot t}{1 + t} \cdot \frac{2 \cdot t}{1 + t}\right) \cdot \left(1 - \frac{2 \cdot t}{1 + t} \cdot \frac{2 \cdot t}{1 + t}\right)}}\]
  5. Final simplification0.0

    \[\leadsto \frac{1 - \left(\frac{2 \cdot t}{t + 1} \cdot \frac{2 \cdot t}{t + 1}\right) \cdot \left(\frac{2 \cdot t}{t + 1} \cdot \frac{2 \cdot t}{t + 1}\right)}{\left(\frac{2 \cdot t}{t + 1} \cdot \frac{2 \cdot t}{t + 1} + 2\right) \cdot \left(1 - \frac{2 \cdot t}{t + 1} \cdot \frac{2 \cdot t}{t + 1}\right)}\]

Reproduce

herbie shell --seed 2019089 
(FPCore (t)
  :name "Kahan p13 Example 1"
  (/ (+ 1 (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))) (+ 2 (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))))))