


Bits error versus x
Results
Initial program 39.5
Simplified0.0
rmApplied flip-+0.0
Applied associate-*l/6.6
rmApplied *-un-lft-identity6.6
Applied times-frac0.0
Simplified0.0
Final simplification0.0
herbie shell --seed 2019010 +o rules:numerics
(FPCore (x)
:name "Expanding a square"
(- (* (+ x 1) (+ x 1)) 1))
Time bar (total: 8.0s)Debug log
| 419.0ms | (- (* (+ x 1) (+ x 1)) 1) |
1 alts after pruning (1 fresh and 0 done)
Merged error: 0.0b
Found 1 expressions with local error:
| 0.0b | (* (+ 2 x) x) |
| 3× | associate-*l* |
| 2× | add-cube-cbrt |
| 2× | associate-*l/ |
| 2× | *-un-lft-identity |
| 2× | add-sqr-sqrt |
| 1× | add-log-exp |
| 1× | log1p-expm1-u |
| 1× | flip-+ |
| 1× | *-commutative |
| 1× | add-exp-log |
| 1× | add-cbrt-cube |
| 1× | flip3-+ |
| 1× | pow1 |
| 1× | expm1-log1p-u |
| 4.0ms | (* (+ 2 x) x) |
| 25.0ms | (* (+ 2 x) x) |
| 216.0ms | (* (- (* 2 2) (* x x)) x) |
| 15.0ms | (* (+ (pow 2 3) (pow x 3)) x) |
| 6.0ms | (+ (* 2 x) (pow x 2)) |
| 6.0ms | (+ (* 2 x) (pow x 2)) |
| 6.0ms | (+ (* 2 x) (pow x 2)) |
3 alts after pruning (3 fresh and 0 done)
Merged error: 0.0b
Found 2 expressions with local error:
| 7.0b | (/ (* (- (* 2 2) (* x x)) x) (- 2 x)) |
| 0.1b | (* (- (* 2 2) (* x x)) x) |
| 5× | add-cube-cbrt |
| 5× | *-un-lft-identity |
| 5× | add-sqr-sqrt |
| 4× | add-exp-log |
| 4× | associate-*l/ |
| 4× | associate-*l* |
| 4× | add-cbrt-cube |
| 3× | flip-- |
| 3× | flip3-- |
| 3× | times-frac |
| 3× | associate-/r* |
| 2× | associate-/l/ |
| 2× | add-log-exp |
| 2× | log1p-expm1-u |
| 2× | associate-/r/ |
| 2× | pow1 |
| 2× | expm1-log1p-u |
| 1× | difference-of-squares |
| 1× | associate-/l* |
| 1× | div-inv |
| 1× | *-commutative |
| 1× | div-exp |
| 1× | frac-2neg |
| 1× | clear-num |
| 1× | cbrt-undiv |
| 6.0ms | (/ (* (- (* 2 2) (* x x)) x) (- 2 x)) |
| 4.0ms | (* (- (* 2 2) (* x x)) x) |
| 46.0ms | (/ (* (- (* 2 2) (* x x)) x) (- 2 x)) |
| 28.0ms | (* (- (* 2 2) (* x x)) x) |
| 191.0ms | (/ (- (* 2 2) (* x x)) (* (cbrt (- 2 x)) (cbrt (- 2 x)))) |
| 176.0ms | (* (- (* (* 2 2) (* 2 2)) (* (* x x) (* x x))) x) |
| 173.0ms | (* (- (* (* 2 2) (* 2 2)) (* (* x x) (* x x))) x) |
| 163.0ms | (- (log (* (- (* 2 2) (* x x)) x)) (log (- 2 x))) |
| 137.0ms | (/ (- (* 2 2) (* x x)) 1) |
4 alts after pruning (3 fresh and 1 done)
Merged error: 0b
Found 2 expressions with local error:
| 0.0b | (* (- 4 (* x x)) (/ x (- 2 x))) |
| 0.0b | (/ x (- 2 x)) |
| 6× | associate-*r* |
| 5× | add-cube-cbrt |
| 5× | *-un-lft-identity |
| 5× | add-sqr-sqrt |
| 4× | flip-- |
| 4× | associate-/r/ |
| 4× | add-exp-log |
| 4× | add-cbrt-cube |
| 4× | flip3-- |
| 4× | pow1 |
| 3× | associate-*l* |
| 3× | associate-/r* |
| 2× | add-log-exp |
| 2× | div-inv |
| 2× | log1p-expm1-u |
| 2× | associate-*l/ |
| 2× | frac-times |
| 2× | expm1-log1p-u |
| 1× | cbrt-unprod |
| 1× | *-commutative |
| 1× | associate-*r/ |
| 1× | prod-exp |
| 1× | pow-prod-down |
| 1× | frac-2neg |
| 1× | clear-num |
| 4.0ms | (* (- 4 (* x x)) (/ x (- 2 x))) |
| 0.0ms | (/ x (- 2 x)) |
| 42.0ms | (* (- 4 (* x x)) (/ x (- 2 x))) |
| 12.0ms | (/ x (- 2 x)) |
| 301.0ms | (* (* (* (- 4 (* x x)) (- 4 (* x x))) (- 4 (* x x))) (* (* (/ x (- 2 x)) (/ x (- 2 x))) (/ x (- 2 x)))) |
| 258.0ms | (* (- (* 4 4) (* (* x x) (* x x))) (/ x (- 2 x))) |
| 204.0ms | (* (- (pow 4 3) (pow (* x x) 3)) (/ x (- 2 x))) |
| 134.0ms | (+ (* 1/2 x) (+ (* 1/8 (pow x 3)) (* 1/4 (pow x 2)))) |
| 129.0ms | (- (+ (* 4 (/ 1 (pow x 2))) (+ (* 2 (/ 1 x)) 1))) |
3 alts after pruning (2 fresh and 1 done)
Merged error: 0b
Found 4 expressions with local error:
| 0.8b | (cbrt (- 2 x)) |
| 0.8b | (cbrt (- 2 x)) |
| 0.8b | (cbrt (- 2 x)) |
| 0.4b | (/ x (* (cbrt (- 2 x)) (cbrt (- 2 x)))) |
| 18× | cbrt-div |
| 9× | flip-- |
| 9× | flip3-- |
| 9× | cbrt-prod |
| 8× | associate-/r/ |
| 7× | add-cube-cbrt |
| 7× | *-un-lft-identity |
| 7× | add-sqr-sqrt |
| 4× | add-log-exp |
| 4× | log1p-expm1-u |
| 4× | add-exp-log |
| 4× | add-cbrt-cube |
| 4× | pow1 |
| 4× | frac-times |
| 4× | expm1-log1p-u |
| 3× | pow1/3 |
| 2× | associate-*r/ |
| 2× | associate-*l/ |
| 1× | div-inv |
| 1× | frac-2neg |
| 1× | associate-/r* |
| 1× | clear-num |
| 2.0ms | (/ x (* (cbrt (- 2 x)) (cbrt (- 2 x)))) |
| 1.0ms | (cbrt (- 2 x)) |
| 1.0ms | (cbrt (- 2 x)) |
| 0.0ms | (cbrt (- 2 x)) |
| 48.0ms | (/ x (* (cbrt (- 2 x)) (cbrt (- 2 x)))) |
| 34.0ms | (cbrt (- 2 x)) |
| 33.0ms | (cbrt (- 2 x)) |
| 31.0ms | (cbrt (- 2 x)) |
| 184.0ms | (+ (* 1/3 (* (pow 1/4 1/3) (pow x 2))) (+ (* (pow 1/4 1/3) x) (* 5/36 (* (pow 1/4 1/3) (pow x 3))))) |
| 156.0ms | (- (pow 2 1/3) (+ (* 1/36 (* (pow x 2) (pow 2 1/3))) (* 1/6 (* x (pow 2 1/3))))) |
| 155.0ms | (- (pow 2 1/3) (+ (* 1/36 (* (pow x 2) (pow 2 1/3))) (* 1/6 (* x (pow 2 1/3))))) |
| 154.0ms | (- (pow 2 1/3) (+ (* 1/36 (* (pow x 2) (pow 2 1/3))) (* 1/6 (* x (pow 2 1/3))))) |
| 132.0ms | (- (exp (* 1/3 (- (log -1) (log (/ 1 x))))) (+ (* 2/3 (/ (exp (* 1/3 (- (log -1) (log (/ 1 x))))) x)) (* 4/9 (/ (exp (* 1/3 (- (log -1) (log (/ 1 x))))) (pow x 2))))) |
3 alts after pruning (1 fresh and 2 done)
Merged error: 0b
0% (0.0b remaining)
Error of 0.0b against oracle of 0.0b and baseline of 0.0b