



Bits error versus x




Bits error versus eps
Results
| Original | 37.2 |
|---|---|
| Target | 15.6 |
| Herbie | 15.4 |
if eps < -5.137551519123668e-87 or 7.274589610278849e-41 < eps Initial program 30.6
rmApplied tan-quot30.5
Applied tan-sum4.8
Applied frac-sub4.8
if -5.137551519123668e-87 < eps < 7.274589610278849e-41Initial program 47.2
rmApplied tan-sum47.2
Taylor expanded around 0 31.2
Simplified31.2
Final simplification15.4
herbie shell --seed 2019008
(FPCore (x eps)
:name "2tan (problem 3.3.2)"
:herbie-target
(/ (sin eps) (* (cos x) (cos (+ x eps))))
(- (tan (+ x eps)) (tan x)))
Time bar (total: 31.4s)Debug log
1 calls. Slowest were:
| 4.0ms | (- (tan (+ x eps)) (tan x)) |
1 alts after pruning (1 fresh and 0 done)
Merged error: 38.3b
Found 2 expressions with local error:
| 4.4b | (tan (+ x eps)) |
| 2.3b | (- (tan (+ x eps)) (tan x)) |
2 calls. Slowest were:
| 11.0ms | (- (tan (+ x eps)) (tan x)) |
| 3.0ms | (tan (+ x eps)) |
2 calls. Slowest were:
| 116.0ms | (tan (+ x eps)) |
| 82.0ms | (- (tan (+ x eps)) (tan x)) |
15 calls. Slowest were:
| 142.0ms | (+ (* x (pow eps 2)) (+ eps (* (pow x 2) eps))) |
| 141.0ms | (- (* (+ (tan x) (tan eps)) (cos x)) (* (- 1 (* (tan x) (tan eps))) (sin x))) |
| 102.0ms | (* (- 1 (* (tan x) (tan eps))) (cos x)) |
8 alts after pruning (8 fresh and 0 done)
Merged error: 16.9b
Found 4 expressions with local error:
| 3.0b | (- (/ (+ (tan x) (tan eps)) (- 1 (* (tan x) (tan eps)))) (tan x)) |
| 0.2b | (* (tan x) (tan eps)) |
| 0.1b | (+ (tan x) (tan eps)) |
| 0.1b | (- 1 (* (tan x) (tan eps))) |
4 calls. Slowest were:
| 31.0ms | (- (/ (+ (tan x) (tan eps)) (- 1 (* (tan x) (tan eps)))) (tan x)) |
| 8.0ms | (* (tan x) (tan eps)) |
| 7.0ms | (+ (tan x) (tan eps)) |
4 calls. Slowest were:
| 378.0ms | (- (/ (+ (tan x) (tan eps)) (- 1 (* (tan x) (tan eps)))) (tan x)) |
| 120.0ms | (+ (tan x) (tan eps)) |
| 117.0ms | (* (tan x) (tan eps)) |
| 113.0ms | (- 1 (* (tan x) (tan eps))) |
36 calls. Slowest were:
| 397.0ms | (- 1 (+ (* 1/3 (* (pow x 3) eps)) (* x eps))) |
| 263.0ms | (- (+ (/ (sin eps) (* (cos eps) (- 1 (/ (* (sin x) (sin eps)) (* (cos x) (cos eps)))))) (/ (sin x) (* (cos x) (- 1 (/ (* (sin x) (sin eps)) (* (cos x) (cos eps))))))) (/ (sin x) (cos x))) |
| 262.0ms | (+ (* 1/3 (* (pow x 3) eps)) (+ (* 1/3 (* x (pow eps 3))) (* x eps))) |
16 alts after pruning (16 fresh and 0 done)
Merged error: 16.8b
Found 4 expressions with local error:
| 3.0b | (- (/ (+ (tan x) (tan eps)) (log (exp (- 1 (* (tan x) (tan eps)))))) (tan x)) |
| 0.2b | (exp (- 1 (* (tan x) (tan eps)))) |
| 0.2b | (* (tan x) (tan eps)) |
| 0.1b | (log (exp (- 1 (* (tan x) (tan eps))))) |
4 calls. Slowest were:
| 45.0ms | (- (/ (+ (tan x) (tan eps)) (log (exp (- 1 (* (tan x) (tan eps)))))) (tan x)) |
| 8.0ms | (* (tan x) (tan eps)) |
| 4.0ms | (exp (- 1 (* (tan x) (tan eps)))) |
4 calls. Slowest were:
| 367.0ms | (- (/ (+ (tan x) (tan eps)) (log (exp (- 1 (* (tan x) (tan eps)))))) (tan x)) |
| 150.0ms | (exp (- 1 (* (tan x) (tan eps)))) |
| 118.0ms | (log (exp (- 1 (* (tan x) (tan eps))))) |
| 103.0ms | (* (tan x) (tan eps)) |
48 calls. Slowest were:
| 356.0ms | (- 1 (+ (* 1/3 (* (pow x 3) eps)) (* x eps))) |
| 317.0ms | (- (* (+ (tan x) (tan eps)) (cos x)) (* (log (exp (- 1 (* (tan x) (tan eps))))) (sin x))) |
| 290.0ms | (+ (* 1/3 (* (pow x 3) eps)) (+ (* 1/3 (* x (pow eps 3))) (* x eps))) |
16 alts after pruning (16 fresh and 0 done)
Merged error: 16.8b
Found 4 expressions with local error:
| 3.0b | (- (/ (+ (tan x) (tan eps)) (log (exp (- 1 (* (tan x) (tan eps)))))) (tan x)) |
| 0.2b | (exp (- 1 (* (tan x) (tan eps)))) |
| 0.2b | (* (tan x) (tan eps)) |
| 0.1b | (log (exp (- 1 (* (tan x) (tan eps))))) |
4 calls. Slowest were:
| 43.0ms | (- (/ (+ (tan x) (tan eps)) (log (exp (- 1 (* (tan x) (tan eps)))))) (tan x)) |
| 4.0ms | (* (tan x) (tan eps)) |
| 3.0ms | (exp (- 1 (* (tan x) (tan eps)))) |
4 calls. Slowest were:
| 355.0ms | (- (/ (+ (tan x) (tan eps)) (log (exp (- 1 (* (tan x) (tan eps)))))) (tan x)) |
| 146.0ms | (exp (- 1 (* (tan x) (tan eps)))) |
| 125.0ms | (log (exp (- 1 (* (tan x) (tan eps))))) |
| 96.0ms | (* (tan x) (tan eps)) |
48 calls. Slowest were:
| 456.0ms | (- 1 (+ (* 1/3 (* (pow x 3) eps)) (* x eps))) |
| 351.0ms | (- (* (+ (tan x) (tan eps)) (cos x)) (* (log (exp (- 1 (* (tan x) (tan eps))))) (sin x))) |
| 290.0ms | (+ (* 1/3 (* (pow x 3) eps)) (+ (* 1/3 (* x (pow eps 3))) (* x eps))) |
16 alts after pruning (15 fresh and 1 done)
Merged error: 16.8b
87.5% (0.9b remaining)
Error of 15.4b against oracle of 14.4b and baseline of 21.8b