Average Error: 44.8 → 13.4
Time: 36.2s
Precision: 64
Internal Precision: 2368
\[(x \cdot y + z)_* - \left(1 + \left(x \cdot y + z\right)\right)\]
\[-1 + \left(\left((x \cdot y + z)_* - x \cdot y\right) - z\right)\]

Error

Bits error versus x

Bits error versus y

Bits error versus z

Target

Original44.8
Target0
Herbie13.4
\[-1\]

Derivation

  1. Initial program 44.8

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

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

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

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

Runtime

Time bar (total: 36.2s)Debug logProfile

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

  :herbie-target
  -1

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