



Bits error versus x
| Original | 14.9 |
|---|---|
| Target | 0.1 |
| Herbie | 0.0 |
if x < -1.3803995254788722e+154 or 521.0581431275527 < x Initial program 39.6
Simplified39.6
Taylor expanded around inf 0.0
if -1.3803995254788722e+154 < x < 521.0581431275527Initial program 0.1
Simplified0.1
rmApplied add-sqr-sqrt0.1
Applied associate-/r*0.0
Final simplification0.0
herbie shell --seed 2019022 +o rules:numerics
(FPCore (x)
:name "x / (x^2 + 1)"
:herbie-target
(/ 1 (+ x (/ 1 x)))
(/ x (+ (* x x) 1)))
Time bar (total: 15.6s)Debug log
| 10.0ms | 256× | body | 80 | valid |
| 3.0ms | (/ x (+ (* x x) 1)) |
1 alts after pruning (1 fresh and 0 done)
Merged error: 13.7b
Found 1 expressions with local error:
| 13.7b | (/ x (fma x x 1)) |
| 3× | associate-/r* |
| 2× | add-cube-cbrt |
| 2× | *-un-lft-identity |
| 2× | add-sqr-sqrt |
| 1× | add-log-exp |
| 1× | div-inv |
| 1× | log1p-expm1-u |
| 1× | add-exp-log |
| 1× | add-cbrt-cube |
| 1× | frac-2neg |
| 1× | clear-num |
| 1× | pow1 |
| 1× | expm1-log1p-u |
| 1.0ms | (/ x (fma x x 1)) |
| 26.0ms | (/ x (fma x x 1)) |
| 38.0ms | (- (+ (/ 1 (pow x 5)) (/ 1 x)) (/ 1 (pow x 3))) |
| 28.0ms | (- (+ (/ 1 (pow x 5)) (/ 1 x)) (/ 1 (pow x 3))) |
| 20.0ms | (- (+ x (pow x 5)) (pow x 3)) |
| 2.0ms | (cbrt (fma x x 1)) |
| 2.0ms | (sqrt (fma x x 1)) |
3 alts after pruning (3 fresh and 0 done)
Merged error: 0b
Found 4 expressions with local error:
| 13.6b | (sqrt (fma x x 1)) |
| 13.6b | (sqrt (fma x x 1)) |
| 0.0b | (/ x (sqrt (fma x x 1))) |
| 0.0b | (/ (/ x (sqrt (fma x x 1))) (sqrt (fma x x 1))) |
| 27× | add-sqr-sqrt |
| 25× | add-cube-cbrt |
| 25× | *-un-lft-identity |
| 24× | sqrt-prod |
| 24× | times-frac |
| 12× | associate-/r* |
| 9× | div-inv |
| 6× | add-exp-log |
| 6× | add-cbrt-cube |
| 4× | add-log-exp |
| 4× | associate-/l* |
| 4× | log1p-expm1-u |
| 4× | pow1 |
| 4× | expm1-log1p-u |
| 2× | pow1/2 |
| 2× | frac-2neg |
| 2× | clear-num |
| 2× | rem-sqrt-square |
| 1× | associate-/l/ |
| 1× | div-exp |
| 1× | cbrt-undiv |
| 7.0ms | (/ (/ x (sqrt (fma x x 1))) (sqrt (fma x x 1))) |
| 2.0ms | (sqrt (fma x x 1)) |
| 1.0ms | (sqrt (fma x x 1)) |
| 1.0ms | (/ x (sqrt (fma x x 1))) |
| 31.0ms | (/ x (sqrt (fma x x 1))) |
| 23.0ms | (/ (/ x (sqrt (fma x x 1))) (sqrt (fma x x 1))) |
| 20.0ms | (sqrt (fma x x 1)) |
| 20.0ms | (sqrt (fma x x 1)) |
| 197.0ms | (/ (* (* (/ x (sqrt (fma x x 1))) (/ x (sqrt (fma x x 1)))) (/ x (sqrt (fma x x 1)))) (* (* (sqrt (fma x x 1)) (sqrt (fma x x 1))) (sqrt (fma x x 1)))) |
| 172.0ms | (- (+ x (* 1/2 (/ 1 x))) (* 1/8 (/ 1 (pow x 3)))) |
| 171.0ms | (- (* 1/8 (/ 1 (pow x 3))) (+ x (* 1/2 (/ 1 x)))) |
| 159.0ms | (- (+ x (* 1/2 (/ 1 x))) (* 1/8 (/ 1 (pow x 3)))) |
| 150.0ms | (- (* 1/8 (/ 1 (pow x 3))) (+ x (* 1/2 (/ 1 x)))) |
3 alts after pruning (2 fresh and 1 done)
Merged error: 0b
Found 2 expressions with local error:
| 16.4b | (- (+ x (pow x 5)) (pow x 3)) |
| 0.0b | (+ x (pow x 5)) |
| 15× | prod-diff |
| 13× | *-un-lft-identity |
| 13× | add-sqr-sqrt |
| 11× | add-cube-cbrt |
| 4× | add-log-exp |
| 3× | unpow3 |
| 3× | fma-neg |
| 3× | cube-mult |
| 2× | log1p-expm1-u |
| 2× | add-exp-log |
| 2× | add-cbrt-cube |
| 2× | pow1 |
| 2× | expm1-log1p-u |
| 1× | difference-of-squares |
| 1× | distribute-lft-out-- |
| 1× | flip-- |
| 1× | flip-+ |
| 1× | associate--l+ |
| 1× | diff-log |
| 1× | flip3-- |
| 1× | flip3-+ |
| 1× | sub-neg |
| 1× | +-commutative |
| 12.0ms | (- (+ x (pow x 5)) (pow x 3)) |
| 2.0ms | (+ x (pow x 5)) |
| 40.0ms | (+ x (pow x 5)) |
| 30.0ms | (- (+ x (pow x 5)) (pow x 3)) |
| 270.0ms | (fma (- (cbrt (pow x 3))) (* (cbrt (pow x 3)) (cbrt (pow x 3))) (* (cbrt (pow x 3)) (* (cbrt (pow x 3)) (cbrt (pow x 3))))) |
| 249.0ms | (fma (- (cbrt (pow x 3))) (* (cbrt (pow x 3)) (cbrt (pow x 3))) (* (cbrt (pow x 3)) (* (cbrt (pow x 3)) (cbrt (pow x 3))))) |
| 203.0ms | (fma (- (cbrt (pow x 3))) (* (cbrt (pow x 3)) (cbrt (pow x 3))) (* (cbrt (pow x 3)) (* (cbrt (pow x 3)) (cbrt (pow x 3))))) |
| 199.0ms | (fma (sqrt (+ x (pow x 5))) (sqrt (+ x (pow x 5))) (- (* (cbrt (pow x 3)) (* (cbrt (pow x 3)) (cbrt (pow x 3)))))) |
| 166.0ms | (fma 1 (+ x (pow x 5)) (- (* (cbrt (pow x 3)) (* (cbrt (pow x 3)) (cbrt (pow x 3)))))) |
3 alts after pruning (1 fresh and 2 done)
Merged error: 0b
Found 4 expressions with local error:
| 21.4b | (- (+ (/ 1 (pow x 5)) (/ 1 x)) (/ 1 (pow x 3))) |
| 0.3b | (/ 1 (pow x 5)) |
| 0.2b | (/ 1 (pow x 3)) |
| 0.0b | (+ (/ 1 (pow x 5)) (/ 1 x)) |
| 58× | *-un-lft-identity |
| 47× | div-inv |
| 32× | distribute-lft-out |
| 28× | prod-diff |
| 21× | add-sqr-sqrt |
| 19× | add-cube-cbrt |
| 11× | add-log-exp |
| 10× | distribute-lft-out-- |
| 8× | associate-/r* |
| 7× | fma-neg |
| 6× | add-exp-log |
| 4× | log1p-expm1-u |
| 4× | add-cbrt-cube |
| 4× | fma-def |
| 4× | rec-exp |
| 4× | pow1 |
| 4× | expm1-log1p-u |
| 3× | frac-sub |
| 2× | inv-pow |
| 2× | pow-flip |
| 2× | flip-+ |
| 2× | frac-add |
| 2× | diff-log |
| 2× | flip3-+ |
| 2× | frac-2neg |
| 2× | sum-log |
| 2× | clear-num |
| 2× | pow-to-exp |
| 1× | difference-of-squares |
| 1× | flip-- |
| 1× | associate--l+ |
| 1× | unpow3 |
| 1× | flip3-- |
| 1× | sub-neg |
| 1× | +-commutative |
| 1× | cube-mult |
| 37.0ms | (- (+ (/ 1 (pow x 5)) (/ 1 x)) (/ 1 (pow x 3))) |
| 5.0ms | (+ (/ 1 (pow x 5)) (/ 1 x)) |
| 1.0ms | (/ 1 (pow x 5)) |
| 1.0ms | (/ 1 (pow x 3)) |
| 38.0ms | (+ (/ 1 (pow x 5)) (/ 1 x)) |
| 21.0ms | (/ 1 (pow x 5)) |
| 17.0ms | (- (+ (/ 1 (pow x 5)) (/ 1 x)) (/ 1 (pow x 3))) |
| 13.0ms | (/ 1 (pow x 3)) |
| 428.0ms | (* (- (/ 1 (pow x 5)) (/ 1 x)) (pow x 3)) |
| 260.0ms | (- (* (+ (pow (/ 1 (pow x 5)) 3) (pow (/ 1 x) 3)) (pow x 3)) (* (+ (* (/ 1 (pow x 5)) (/ 1 (pow x 5))) (- (* (/ 1 x) (/ 1 x)) (* (/ 1 (pow x 5)) (/ 1 x)))) 1)) |
| 246.0ms | (- (* (- (* (/ 1 (pow x 5)) (/ 1 (pow x 5))) (* (/ 1 x) (/ 1 x))) (pow x 3)) (* (- (/ 1 (pow x 5)) (/ 1 x)) 1)) |
| 215.0ms | (fma 1 (+ (/ 1 (pow x 5)) (/ 1 x)) (- (* (/ 1 (pow x 3)) 1))) |
| 202.0ms | (- (* (+ (* 1 x) (* (pow x 5) 1)) (pow x 3)) (* (* (pow x 5) x) 1)) |
3 alts after pruning (0 fresh and 3 done)
Merged error: 0b
99.9% (0.0b remaining)
Error of 0.0b against oracle of 0.0b and baseline of 14.8b
| 573.0ms | 8000× | body | 80 | valid |