Average Error: 0.4 → 0.2
Time: 23.9s
Precision: 64
Internal Precision: 384
\[\frac{x \cdot 100.0}{x + y}\]
\[\frac{x}{\frac{x + y}{100.0}}\]

Error

Bits error versus x

Bits error versus y

Target

Original0.4
Target0.2
Herbie0.2
\[\frac{x}{1} \cdot \frac{100.0}{x + y}\]

Derivation

  1. Initial program 0.4

    \[\frac{x \cdot 100.0}{x + y}\]
  2. Using strategy rm
  3. Applied associate-/l*0.2

    \[\leadsto \color{blue}{\frac{x}{\frac{x + y}{100.0}}}\]
  4. Removed slow pow expressions.

Runtime

Time bar (total: 23.9s)Debug log

herbie shell --seed '#(1567391828 2030694642 2833800258 828025724 3004380912 3532991858)' +o setup:early-exit
(FPCore (x y)
  :name "Development.Shake.Progress:message from shake-0.15.5"

  :herbie-target
  (* (/ x 1) (/ 100.0 (+ x y)))

  (/ (* x 100.0) (+ x y)))