Average Error: 29.3 → 0.5
Time: 12.3s
Precision: 64
Internal Precision: 128
\[\sqrt[3]{x + 1} - \sqrt[3]{x}\]
\[\frac{1}{\left(\sqrt[3]{x + 1} \cdot \sqrt[3]{x} + \sqrt[3]{x} \cdot \sqrt[3]{x}\right) + \sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1}}\]

Error

Bits error versus x

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 29.3

    \[\sqrt[3]{x + 1} - \sqrt[3]{x}\]
  2. Using strategy rm
  3. Applied flip3--29.3

    \[\leadsto \color{blue}{\frac{{\left(\sqrt[3]{x + 1}\right)}^{3} - {\left(\sqrt[3]{x}\right)}^{3}}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)}}\]
  4. Taylor expanded around -inf 0.5

    \[\leadsto \frac{\color{blue}{1}}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)}\]
  5. Final simplification0.5

    \[\leadsto \frac{1}{\left(\sqrt[3]{x + 1} \cdot \sqrt[3]{x} + \sqrt[3]{x} \cdot \sqrt[3]{x}\right) + \sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1}}\]

Reproduce

herbie shell --seed 2019021 
(FPCore (x)
  :name "2cbrt (problem 3.3.4)"
  (- (cbrt (+ x 1)) (cbrt x)))

Details

Time bar (total: 11.8s)Debug log

sample71.0ms

Algorithm
intervals
Results
16.0ms42×body640valid
13.0ms49×body1280valid
13.0ms263×body80nan
7.0ms138×body80valid
3.0ms21×body320valid
1.0msbody160valid

simplify8.0ms

Counts
1 → 1
Calls
1 calls:
Slowest
8.0ms
(- (cbrt (+ x 1)) (cbrt x))

prune8.0ms

Pruning

1 alts after pruning (1 fresh and 0 done)

Merged error: 28.5b

localize19.0ms

Local error

Found 3 expressions with local error:

2.4b
(- (cbrt (+ x 1)) (cbrt x))
0.6b
(cbrt x)
0.2b
(cbrt (+ x 1))

rewrite12.0ms

Algorithm
rewrite-expression-head
Rules
add-sqr-sqrt
*-un-lft-identity
add-log-exp
add-cube-cbrt
cbrt-prod
add-exp-log
add-cbrt-cube
pow1
difference-of-squares
pow1/3
cbrt-div
distribute-lft-out--
flip--
flip-+
diff-log
flip3--
flip3-+
sub-neg
Counts
3 → 36
Calls
3 calls:
Slowest
10.0ms
(- (cbrt (+ x 1)) (cbrt x))
1.0ms
(cbrt (+ x 1))
0.0ms
(cbrt x)

series386.0ms

Counts
3 → 9
Calls
3 calls:
Slowest
231.0ms
(cbrt x)
103.0ms
(- (cbrt (+ x 1)) (cbrt x))
53.0ms
(cbrt (+ x 1))

simplify940.0ms

Counts
20 → 45
Calls
20 calls:
Slowest
256.0ms
(- (+ (exp (* 1/3 (- (log -1) (log (/ -1 x))))) (* 1/3 (/ (exp (* 1/3 (- (log -1) (log (/ -1 x))))) x))) (+ (* (pow (* x -1) 1/3) (cbrt -1)) (* 1/9 (/ (exp (* 1/3 (- (log -1) (log (/ -1 x))))) (pow x 2)))))
231.0ms
(- (+ (* 1/3 x) 1) (+ (* 1/9 (pow x 2)) (pow x 1/3)))
162.0ms
(- (+ (exp (* 1/3 (- (log -1) (log (/ -1 x))))) (* 1/3 (/ (exp (* 1/3 (- (log -1) (log (/ -1 x))))) x))) (* 1/9 (/ (exp (* 1/3 (- (log -1) (log (/ -1 x))))) (pow x 2))))
62.0ms
(- (+ (* 1/3 (pow (/ 1 (pow x 2)) 1/3)) (* 5/81 (pow (/ 1 (pow x 8)) 1/3))) (* 1/9 (pow (/ 1 (pow x 5)) 1/3)))
53.0ms
(- (+ (* 1/3 (pow (/ 1 (pow x 2)) 1/3)) (pow (/ 1 x) -1/3)) (* 1/9 (pow (/ 1 (pow x 5)) 1/3)))

prune402.0ms

Pruning

9 alts after pruning (9 fresh and 0 done)

Merged error: 14.5b

localize13.0ms

Local error

Found 3 expressions with local error:

28.8b
(- (cbrt (+ x 1)) (pow x 1/3))
5.1b
(pow x 1/3)
0.2b
(cbrt (+ x 1))

rewrite13.0ms

Algorithm
rewrite-expression-head
Rules
add-sqr-sqrt
*-un-lft-identity
add-log-exp
add-cube-cbrt
cbrt-prod
add-exp-log
add-cbrt-cube
pow1
difference-of-squares
cbrt-div
distribute-lft-out--
flip--
flip-+
diff-log
pow1/3
unpow1/3
flip3--
flip3-+
sub-neg
pow-to-exp
Counts
3 → 37
Calls
3 calls:
Slowest
11.0ms
(- (cbrt (+ x 1)) (pow x 1/3))
1.0ms
(cbrt (+ x 1))
0.0ms
(pow x 1/3)

series375.0ms

Counts
3 → 9
Calls
3 calls:
Slowest
229.0ms
(pow x 1/3)
105.0ms
(- (cbrt (+ x 1)) (pow x 1/3))
41.0ms
(cbrt (+ x 1))

simplify992.0ms

Counts
20 → 46
Calls
20 calls:
Slowest
272.0ms
(- (+ (* 5/81 (/ (exp (* 1/3 (- (log -1) (log (/ -1 x))))) (pow x 3))) (* 1/3 (/ (exp (* 1/3 (- (log -1) (log (/ -1 x))))) x))) (* 1/9 (/ (exp (* 1/3 (- (log -1) (log (/ -1 x))))) (pow x 2))))
209.0ms
(- (+ (* 1/3 x) 1) (+ (* 1/9 (pow x 2)) (pow x 1/3)))
170.0ms
(- (+ (exp (* 1/3 (- (log -1) (log (/ -1 x))))) (* 1/3 (/ (exp (* 1/3 (- (log -1) (log (/ -1 x))))) x))) (* 1/9 (/ (exp (* 1/3 (- (log -1) (log (/ -1 x))))) (pow x 2))))
96.0ms
(exp (* 1/3 (- (log -1) (log (/ -1 x)))))
53.0ms
(- (+ (* 1/3 (pow (/ 1 (pow x 2)) 1/3)) (* 5/81 (pow (/ 1 (pow x 8)) 1/3))) (* 1/9 (pow (/ 1 (pow x 5)) 1/3)))

prune392.0ms

Pruning

5 alts after pruning (5 fresh and 0 done)

Merged error: 0.3b

localize18.0ms

Local error

Found 4 expressions with local error:

28.8b
(- (cbrt (+ x 1)) (pow x 1/3))
28.8b
(- (cbrt (+ x 1)) (pow x 1/3))
28.8b
(- (cbrt (+ x 1)) (pow x 1/3))
5.1b
(pow x 1/3)

rewrite17.0ms

Algorithm
rewrite-expression-head
Rules
16×add-sqr-sqrt
10×add-log-exp
10×*-un-lft-identity
difference-of-squares
add-cube-cbrt
add-exp-log
add-cbrt-cube
pow1
distribute-lft-out--
flip--
diff-log
flip3--
sub-neg
cbrt-prod
unpow1/3
pow-to-exp
Counts
4 → 54
Calls
4 calls:
Slowest
5.0ms
(- (cbrt (+ x 1)) (pow x 1/3))
5.0ms
(- (cbrt (+ x 1)) (pow x 1/3))
5.0ms
(- (cbrt (+ x 1)) (pow x 1/3))
0.0ms
(pow x 1/3)

series691.0ms

Counts
4 → 12
Calls
4 calls:
Slowest
279.0ms
(pow x 1/3)
144.0ms
(- (cbrt (+ x 1)) (pow x 1/3))
138.0ms
(- (cbrt (+ x 1)) (pow x 1/3))
130.0ms
(- (cbrt (+ x 1)) (pow x 1/3))

simplify1.9s

Counts
30 → 66
Calls
30 calls:
Slowest
303.0ms
(- (+ (* 5/81 (/ (exp (* 1/3 (- (log -1) (log (/ -1 x))))) (pow x 3))) (* 1/3 (/ (exp (* 1/3 (- (log -1) (log (/ -1 x))))) x))) (* 1/9 (/ (exp (* 1/3 (- (log -1) (log (/ -1 x))))) (pow x 2))))
276.0ms
(- (+ (* 5/81 (/ (exp (* 1/3 (- (log -1) (log (/ -1 x))))) (pow x 3))) (* 1/3 (/ (exp (* 1/3 (- (log -1) (log (/ -1 x))))) x))) (* 1/9 (/ (exp (* 1/3 (- (log -1) (log (/ -1 x))))) (pow x 2))))
247.0ms
(- (+ (* 5/81 (/ (exp (* 1/3 (- (log -1) (log (/ -1 x))))) (pow x 3))) (* 1/3 (/ (exp (* 1/3 (- (log -1) (log (/ -1 x))))) x))) (* 1/9 (/ (exp (* 1/3 (- (log -1) (log (/ -1 x))))) (pow x 2))))
206.0ms
(- (+ (* 1/3 x) 1) (+ (* 1/9 (pow x 2)) (pow x 1/3)))
178.0ms
(- (+ (* 1/3 x) 1) (+ (* 1/9 (pow x 2)) (pow x 1/3)))

prune567.0ms

Pruning

5 alts after pruning (4 fresh and 1 done)

Merged error: 0.3b

localize33.0ms

Local error

Found 4 expressions with local error:

1.9b
(- (pow (cbrt (+ x 1)) 3) (pow (cbrt x) 3))
0.7b
(pow (cbrt x) 3)
0.6b
(cbrt x)
0.6b
(cbrt x)

rewrite22.0ms

Algorithm
rewrite-expression-head
Rules
36×add-sqr-sqrt
18×cube-prod
18×unpow-prod-down
16×*-un-lft-identity
15×difference-of-squares
add-log-exp
add-cube-cbrt
cbrt-prod
distribute-lft-out--
add-exp-log
pow1
add-cbrt-cube
pow1/3
pow-pow
rem-cube-cbrt
flip--
pow-exp
unpow3
diff-log
flip3--
sub-neg
difference-cubes
pow-to-exp
cube-mult
Counts
4 → 69
Calls
4 calls:
Slowest
19.0ms
(- (pow (cbrt (+ x 1)) 3) (pow (cbrt x) 3))
1.0ms
(pow (cbrt x) 3)
0.0ms
(cbrt x)
0.0ms
(cbrt x)

series976.0ms

Counts
4 → 12
Calls
4 calls:
Slowest
320.0ms
(pow (cbrt x) 3)
314.0ms
(cbrt x)
268.0ms
(cbrt x)
74.0ms
(- (pow (cbrt (+ x 1)) 3) (pow (cbrt x) 3))

simplify675.0ms

Counts
62 → 81
Calls
62 calls:
Slowest
44.0ms
(/ (exp (pow (cbrt (+ x 1)) 3)) (exp (pow (cbrt x) 3)))
34.0ms
(+ (* (cbrt (+ x 1)) (cbrt (+ x 1))) (+ (* (cbrt x) (cbrt x)) (* (cbrt (+ x 1)) (cbrt x))))
28.0ms
(- (pow (cbrt (sqrt (+ x 1))) 3) (pow (sqrt (cbrt x)) 3))
27.0ms
(pow (* (cbrt (cbrt x)) (cbrt (cbrt x))) 3)
27.0ms
(- (pow (sqrt (cbrt (+ x 1))) 3) (pow (sqrt (cbrt x)) 3))

prune790.0ms

Pruning

5 alts after pruning (4 fresh and 1 done)

Merged error: 0.1b

regimes33.0ms

Accuracy

0% (0.3b remaining)

Error of 0.5b against oracle of 0.2b and baseline of 0.5b

bsearch2.0ms

end0.0ms

sample2.5s

Algorithm
intervals
Results
1.0s1690×body1280valid
600.0ms7849×body80nan
308.0ms1223×body640valid
277.0ms4150×body80valid
105.0ms617×body320valid
76.0ms321×body160valid