


Bits error versus x



Bits error versus eps
Results
if eps < -6.030207407183357e-05 or 4.096802796851688e-05 < eps Initial program 30.9
Initial simplification30.9
rmApplied cos-sum0.9
Applied associate--l-0.9
if -6.030207407183357e-05 < eps < 4.096802796851688e-05Initial program 49.3
Initial simplification49.3
rmApplied diff-cos37.8
Simplified0.5
rmApplied log1p-expm1-u0.5
Final simplification0.7
herbie shell --seed 2018362 +o rules:numerics
(FPCore (x eps)
:name "2cos (problem 3.3.5)"
(- (cos (+ x eps)) (cos x)))
Time bar (total: 9.1s)Debug log
1 alts after pruning (1 fresh and 0 done)
Merged error: 39.6b
Found 2 expressions with local error:
| 3.1b | (cos (+ eps x)) |
| 2.0b | (- (cos (+ eps x)) (cos x)) |
2 calls. Slowest were:
| 7.0ms | (- (cos (+ eps x)) (cos x)) |
| 2.0ms | (cos (+ eps x)) |
2 calls. Slowest were:
| 68.0ms | (- (cos (+ eps x)) (cos x)) |
| 22.0ms | (cos (+ eps x)) |
33 calls. Slowest were:
| 166.0ms | (- (* 1/24 (pow eps 4)) (+ (* x eps) (* 1/2 (pow eps 2)))) |
| 125.0ms | (- 1 (+ (* x eps) (* 1/2 (pow eps 2)))) |
| 41.0ms | (fma (sqrt (cos (+ eps x))) (sqrt (cos (+ eps x))) (- (* (sqrt (cos x)) (sqrt (cos x))))) |
7 alts after pruning (7 fresh and 0 done)
Merged error: 0.2b
Found 3 expressions with local error:
| 3.1b | (sin (/ (+ (+ x x) eps) 2)) |
| 0.2b | (* (sin (/ (+ (+ x x) eps) 2)) (sin (/ eps 2))) |
| 0.0b | (* -2 (* (sin (/ (+ (+ x x) eps) 2)) (sin (/ eps 2)))) |
3 calls. Slowest were:
| 11.0ms | (sin (/ (+ (+ x x) eps) 2)) |
| 9.0ms | (* (sin (/ (+ (+ x x) eps) 2)) (sin (/ eps 2))) |
| 9.0ms | (* -2 (* (sin (/ (+ (+ x x) eps) 2)) (sin (/ eps 2)))) |
3 calls. Slowest were:
| 97.0ms | (* -2 (* (sin (/ (+ (+ x x) eps) 2)) (sin (/ eps 2)))) |
| 77.0ms | (* (sin (/ (+ (+ x x) eps) 2)) (sin (/ eps 2))) |
| 31.0ms | (sin (/ (+ (+ x x) eps) 2)) |
19 calls. Slowest were:
| 454.0ms | (- (+ (* 1/4 (pow eps 2)) (* 1/2 (* x eps))) (* 1/12 (* (pow x 3) eps))) |
| 252.0ms | (- (* 1/6 (* (pow x 3) eps)) (+ (* 1/2 (pow eps 2)) (* x eps))) |
| 155.0ms | (- (+ x (* 1/2 eps)) (* 1/6 (pow x 3))) |
10 alts after pruning (9 fresh and 1 done)
Merged error: 0.2b
Found 4 expressions with local error:
| 3.1b | (sin (/ (+ (+ x x) eps) 2)) |
| 0.2b | (* (sin (/ (+ (+ x x) eps) 2)) (sin (/ eps 2))) |
| 0.1b | (log1p (expm1 (* -2 (* (sin (/ (+ (+ x x) eps) 2)) (sin (/ eps 2)))))) |
| 0.1b | (expm1 (* -2 (* (sin (/ (+ (+ x x) eps) 2)) (sin (/ eps 2))))) |
4 calls. Slowest were:
| 19.0ms | (* (sin (/ (+ (+ x x) eps) 2)) (sin (/ eps 2))) |
| 9.0ms | (sin (/ (+ (+ x x) eps) 2)) |
| 1.0ms | (expm1 (* -2 (* (sin (/ (+ (+ x x) eps) 2)) (sin (/ eps 2))))) |
4 calls. Slowest were:
| 217.0ms | (expm1 (* -2 (* (sin (/ (+ (+ x x) eps) 2)) (sin (/ eps 2))))) |
| 200.0ms | (log1p (expm1 (* -2 (* (sin (/ (+ (+ x x) eps) 2)) (sin (/ eps 2)))))) |
| 83.0ms | (* (sin (/ (+ (+ x x) eps) 2)) (sin (/ eps 2))) |
| 27.0ms | (sin (/ (+ (+ x x) eps) 2)) |
22 calls. Slowest were:
| 340.0ms | (- (+ (* 1/4 (pow eps 2)) (* 1/2 (* x eps))) (* 1/12 (* (pow x 3) eps))) |
| 309.0ms | (- (* 1/6 (* (pow x 3) eps)) (+ (* 1/2 (pow eps 2)) (* x eps))) |
| 228.0ms | (- (* 1/6 (* (pow x 3) eps)) (+ (* 1/2 (pow eps 2)) (* x eps))) |
10 alts after pruning (8 fresh and 2 done)
Merged error: 0.2b
Found 4 expressions with local error:
| 3.1b | (sin (/ (+ (+ x x) eps) 2)) |
| 0.6b | (cbrt (sin (/ eps 2))) |
| 0.6b | (cbrt (sin (/ eps 2))) |
| 0.6b | (cbrt (sin (/ eps 2))) |
4 calls. Slowest were:
| 6.0ms | (sin (/ (+ (+ x x) eps) 2)) |
| 1.0ms | (cbrt (sin (/ eps 2))) |
| 1.0ms | (cbrt (sin (/ eps 2))) |
4 calls. Slowest were:
| 188.0ms | (cbrt (sin (/ eps 2))) |
| 176.0ms | (cbrt (sin (/ eps 2))) |
| 152.0ms | (cbrt (sin (/ eps 2))) |
| 21.0ms | (sin (/ (+ (+ x x) eps) 2)) |
21 calls. Slowest were:
| 146.0ms | (- (exp (* 1/3 (+ (log 1/2) (log eps)))) (+ (* 1/51840 (* (exp (* 1/3 (+ (log 1/2) (log eps)))) (pow eps 4))) (* 1/72 (* (exp (* 1/3 (+ (log 1/2) (log eps)))) (pow eps 2))))) |
| 135.0ms | (- (exp (* 1/3 (+ (log 1/2) (log eps)))) (+ (* 1/51840 (* (exp (* 1/3 (+ (log 1/2) (log eps)))) (pow eps 4))) (* 1/72 (* (exp (* 1/3 (+ (log 1/2) (log eps)))) (pow eps 2))))) |
| 126.0ms | (- (+ x (* 1/2 eps)) (* 1/6 (pow x 3))) |
10 alts after pruning (7 fresh and 3 done)
Merged error: 0.2b
97.8% (0.3b remaining)
Error of 0.7b against oracle of 0.4b and baseline of 15.3b