Average Error: 15.2 → 0.8
Time: 10.2s
Precision: 64
Internal Precision: 128
\[\sqrt[3]{\frac{g}{2 \cdot a}}\]
\[\left(\sqrt[3]{\frac{1}{2}} \cdot \sqrt[3]{\frac{1}{a}}\right) \cdot \sqrt[3]{g}\]

Error

Bits error versus g

Bits error versus a

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 15.2

    \[\sqrt[3]{\frac{g}{2 \cdot a}}\]
  2. Using strategy rm
  3. Applied div-inv15.2

    \[\leadsto \sqrt[3]{\color{blue}{g \cdot \frac{1}{2 \cdot a}}}\]
  4. Applied cbrt-prod0.9

    \[\leadsto \color{blue}{\sqrt[3]{g} \cdot \sqrt[3]{\frac{1}{2 \cdot a}}}\]
  5. Taylor expanded around inf 33.6

    \[\leadsto \sqrt[3]{g} \cdot \color{blue}{\left(\sqrt[3]{\frac{1}{2}} \cdot {\left(\frac{1}{a}\right)}^{\frac{1}{3}}\right)}\]
  6. Simplified0.8

    \[\leadsto \sqrt[3]{g} \cdot \color{blue}{\left(\sqrt[3]{\frac{1}{a}} \cdot \sqrt[3]{\frac{1}{2}}\right)}\]
  7. Final simplification0.8

    \[\leadsto \left(\sqrt[3]{\frac{1}{2}} \cdot \sqrt[3]{\frac{1}{a}}\right) \cdot \sqrt[3]{g}\]

Reproduce

herbie shell --seed 2019016 
(FPCore (g a)
  :name "2-ancestry mixing, zero discriminant"
  (cbrt (/ g (* 2 a))))

Details

Time bar (total: 8.3s)Debug log

sample76.0ms

Algorithm
intervals
Results
508×(pre true 80)
257×(body real 80)
251×(body nan 80)

simplify2.0ms

Counts
1 → 1
Calls
1 calls:
Slowest
2.0ms
(cbrt (/ g (* 2 a)))

prune4.0ms

Pruning

1 alts after pruning (1 fresh and 0 done)

Merged error: 14.8b

localize8.0ms

Local error

Found 1 expressions with local error:

14.8b
(cbrt (/ g (* 2 a)))

rewrite1.0ms

Algorithm
rewrite-expression-head
Rules
cbrt-prod
add-cube-cbrt
*-un-lft-identity
add-sqr-sqrt
add-log-exp
div-inv
add-exp-log
pow1/3
add-cbrt-cube
cbrt-div
pow1
Counts
1 → 13
Calls
1 calls:
Slowest
1.0ms
(cbrt (/ g (* 2 a)))

series120.0ms

Counts
1 → 3
Calls
1 calls:
Slowest
120.0ms
(cbrt (/ g (* 2 a)))

simplify349.0ms

Counts
8 → 16
Calls
8 calls:
Slowest
172.0ms
(* (cbrt 1/2) (exp (* 1/3 (- (log (/ 1 a)) (log (/ 1 g))))))
115.0ms
(* (cbrt 1/2) (exp (* 1/3 (- (log (/ -1 a)) (log (/ -1 g))))))
47.0ms
(* (cbrt 1/2) (exp (* 1/3 (- (log g) (log a)))))
6.0ms
(cbrt (* (cbrt (/ g (* 2 a))) (cbrt (/ g (* 2 a)))))
5.0ms
(cbrt (sqrt (/ g (* 2 a))))

prune146.0ms

Pruning

10 alts after pruning (9 fresh and 1 done)

Merged error: 0.2b

localize8.0ms

Local error

Found 3 expressions with local error:

0.6b
(cbrt (* 2 a))
0.6b
(cbrt g)
0.3b
(/ (cbrt g) (cbrt (* 2 a)))

rewrite4.0ms

Algorithm
rewrite-expression-head
Rules
12×add-cube-cbrt
12×times-frac
12×*-un-lft-identity
12×add-sqr-sqrt
add-exp-log
cbrt-prod
associate-/r*
add-log-exp
associate-/l*
add-cbrt-cube
pow1
pow1/3
div-inv
div-exp
frac-2neg
clear-num
cbrt-undiv
Counts
3 → 48
Calls
3 calls:
Slowest
3.0ms
(/ (cbrt g) (cbrt (* 2 a)))
1.0ms
(cbrt (* 2 a))
0.0ms
(cbrt g)

series793.0ms

Counts
3 → 9
Calls
3 calls:
Slowest
384.0ms
(cbrt (* 2 a))
264.0ms
(cbrt g)
144.0ms
(/ (cbrt g) (cbrt (* 2 a)))

simplify521.0ms

Counts
42 → 57
Calls
42 calls:
Slowest
171.0ms
(/ (exp (* 1/3 (- (log (/ 1 a)) (log (/ 1 g))))) (cbrt 2))
159.0ms
(/ (* (exp (* 1/3 (- (log (/ -1 a)) (log (/ -1 g))))) (cbrt -1)) (cbrt -2))
45.0ms
(/ (exp (* 1/3 (- (log g) (log a)))) (cbrt 2))
28.0ms
(/ (* (cbrt (cbrt g)) (cbrt (cbrt g))) (* (cbrt (cbrt (* 2 a))) (cbrt (cbrt (* 2 a)))))
13.0ms
(/ (* (cbrt (cbrt g)) (cbrt (cbrt g))) 1)

prune547.0ms

Pruning

15 alts after pruning (14 fresh and 1 done)

Merged error: 0.1b

localize1.0ms

Local error

Found 3 expressions with local error:

0.6b
(cbrt (* 2 a))
0.6b
(cbrt g)
0.3b
(/ (cbrt g) (cbrt (* 2 a)))

rewrite8.0ms

Algorithm
rewrite-expression-head
Rules
12×add-cube-cbrt
12×times-frac
12×*-un-lft-identity
12×add-sqr-sqrt
add-exp-log
cbrt-prod
associate-/r*
add-log-exp
associate-/l*
add-cbrt-cube
pow1
pow1/3
div-inv
div-exp
frac-2neg
clear-num
cbrt-undiv
Counts
3 → 48
Calls
3 calls:
Slowest
6.0ms
(/ (cbrt g) (cbrt (* 2 a)))
1.0ms
(cbrt (* 2 a))
0.0ms
(cbrt g)

series666.0ms

Counts
3 → 9
Calls
3 calls:
Slowest
320.0ms
(cbrt (* 2 a))
209.0ms
(cbrt g)
137.0ms
(/ (cbrt g) (cbrt (* 2 a)))

simplify532.0ms

Counts
42 → 57
Calls
42 calls:
Slowest
162.0ms
(/ (* (exp (* 1/3 (- (log (/ -1 a)) (log (/ -1 g))))) (cbrt -1)) (cbrt -2))
151.0ms
(/ (exp (* 1/3 (- (log (/ 1 a)) (log (/ 1 g))))) (cbrt 2))
37.0ms
(/ (exp (* 1/3 (- (log g) (log a)))) (cbrt 2))
18.0ms
(/ (* (cbrt (cbrt g)) (cbrt (cbrt g))) 1)
17.0ms
(/ (* (cbrt (cbrt g)) (cbrt (cbrt g))) (* (cbrt (cbrt (* 2 a))) (cbrt (cbrt (* 2 a)))))

prune507.0ms

Pruning

15 alts after pruning (13 fresh and 2 done)

Merged error: 0.1b

localize8.0ms

Local error

Found 3 expressions with local error:

0.6b
(cbrt g)
0.6b
(cbrt (/ 1 (* 2 a)))
0.4b
(* (cbrt g) (cbrt (/ 1 (* 2 a))))

rewrite5.0ms

Algorithm
rewrite-expression-head
Rules
cbrt-prod
add-cube-cbrt
associate-*r*
*-un-lft-identity
add-sqr-sqrt
add-exp-log
pow1
pow1/3
add-log-exp
associate-*l*
add-cbrt-cube
div-inv
pow-prod-down
cbrt-div
cbrt-unprod
*-commutative
associate-*r/
prod-exp
Counts
3 → 44
Calls
3 calls:
Slowest
4.0ms
(* (cbrt g) (cbrt (/ 1 (* 2 a))))
1.0ms
(cbrt (/ 1 (* 2 a)))
0.0ms
(cbrt g)

series756.0ms

Counts
3 → 9
Calls
3 calls:
Slowest
324.0ms
(cbrt g)
320.0ms
(cbrt (/ 1 (* 2 a)))
111.0ms
(* (cbrt g) (cbrt (/ 1 (* 2 a))))

simplify542.0ms

Counts
28 → 53
Calls
28 calls:
Slowest
180.0ms
(* (cbrt 1/2) (exp (* 1/3 (- (log (/ 1 a)) (log (/ 1 g))))))
122.0ms
(* (exp (* 1/3 (- (log (/ -1 a)) (log (/ -1 g))))) (* (cbrt -1) (cbrt -1/2)))
72.0ms
(* (cbrt 1/2) (exp (* 1/3 (- (log g) (log a)))))
45.0ms
(* g (/ 1 (* 2 a)))
25.0ms
(* g (/ 1 (* 2 a)))

prune422.0ms

Pruning

15 alts after pruning (13 fresh and 2 done)

Merged error: 0.0b

regimes497.0ms

Accuracy

0% (0.8b remaining)

Error of 0.8b against oracle of 0.1b and baseline of 0.8b

bsearch2.0ms

end0.0ms

sample1.8s

Algorithm
intervals
Results
15853×(pre true 80)
8001×(body real 80)
7852×(body nan 80)