Average Error: 45.0 → 13.1
Time: 2.9m
Precision: 64
Internal Precision: 2368
\[(x \cdot y + z)_* - \left(1 + \left(x \cdot y + z\right)\right)\]
\[\left(\left((x \cdot y + z)_* - x \cdot y\right) - z\right) - 1\]

Error

Bits error versus x

Bits error versus y

Bits error versus z

Target

Original45.0
Target0
Herbie13.1
\[-1\]

Derivation

  1. Initial program 45.0

    \[(x \cdot y + z)_* - \left(1 + \left(x \cdot y + z\right)\right)\]
  2. Initial simplification34.0

    \[\leadsto \left((x \cdot y + z)_* - x \cdot y\right) - \left(z + 1\right)\]
  3. Using strategy rm
  4. Applied associate--r+13.1

    \[\leadsto \color{blue}{\left(\left((x \cdot y + z)_* - x \cdot y\right) - z\right) - 1}\]
  5. Final simplification13.1

    \[\leadsto \left(\left((x \cdot y + z)_* - x \cdot y\right) - z\right) - 1\]

Runtime

Time bar (total: 2.9m)Debug logProfile

herbie shell --seed 2018220 
(FPCore (x y z)
  :name "simple fma test"

  :herbie-target
  -1

  (- (fma x y z) (+ 1 (+ (* x y) z))))