Average Error: 4.1 → 1.9
Time: 50.7s
Precision: 64
Internal Precision: 128
\[\frac{x}{x + y \cdot e^{2.0 \cdot \left(\frac{z \cdot \sqrt{t + a}}{t} - \left(b - c\right) \cdot \left(\left(a + \frac{5.0}{6.0}\right) - \frac{2.0}{t \cdot 3.0}\right)\right)}}\]
\[\frac{x}{x + y \cdot e^{(\left(c - b\right) \cdot \left(\left(\frac{5.0}{6.0} + a\right) - \frac{2.0}{t \cdot 3.0}\right) + \left(\frac{z}{t} \cdot \sqrt{t + a}\right))_* \cdot 2.0}}\]

Error

Bits error versus x

Bits error versus y

Bits error versus z

Bits error versus t

Bits error versus a

Bits error versus b

Bits error versus c

Derivation

  1. Initial program 4.1

    \[\frac{x}{x + y \cdot e^{2.0 \cdot \left(\frac{z \cdot \sqrt{t + a}}{t} - \left(b - c\right) \cdot \left(\left(a + \frac{5.0}{6.0}\right) - \frac{2.0}{t \cdot 3.0}\right)\right)}}\]
  2. Using strategy rm
  3. Applied *-un-lft-identity4.1

    \[\leadsto \frac{x}{x + y \cdot e^{2.0 \cdot \left(\color{blue}{1 \cdot \frac{z \cdot \sqrt{t + a}}{t}} - \left(b - c\right) \cdot \left(\left(a + \frac{5.0}{6.0}\right) - \frac{2.0}{t \cdot 3.0}\right)\right)}}\]
  4. Applied prod-diff22.5

    \[\leadsto \frac{x}{x + y \cdot e^{2.0 \cdot \color{blue}{\left((1 \cdot \left(\frac{z \cdot \sqrt{t + a}}{t}\right) + \left(-\left(\left(a + \frac{5.0}{6.0}\right) - \frac{2.0}{t \cdot 3.0}\right) \cdot \left(b - c\right)\right))_* + (\left(-\left(\left(a + \frac{5.0}{6.0}\right) - \frac{2.0}{t \cdot 3.0}\right)\right) \cdot \left(b - c\right) + \left(\left(\left(a + \frac{5.0}{6.0}\right) - \frac{2.0}{t \cdot 3.0}\right) \cdot \left(b - c\right)\right))_*\right)}}}\]
  5. Simplified20.5

    \[\leadsto \frac{x}{x + y \cdot e^{2.0 \cdot \left(\color{blue}{(\left(c - b\right) \cdot \left(\left(\frac{5.0}{6.0} + a\right) - \frac{2.0}{t \cdot 3.0}\right) + \left(\frac{z}{t} \cdot \sqrt{a + t}\right))_*} + (\left(-\left(\left(a + \frac{5.0}{6.0}\right) - \frac{2.0}{t \cdot 3.0}\right)\right) \cdot \left(b - c\right) + \left(\left(\left(a + \frac{5.0}{6.0}\right) - \frac{2.0}{t \cdot 3.0}\right) \cdot \left(b - c\right)\right))_*\right)}}\]
  6. Simplified1.9

    \[\leadsto \frac{x}{x + y \cdot e^{2.0 \cdot \left((\left(c - b\right) \cdot \left(\left(\frac{5.0}{6.0} + a\right) - \frac{2.0}{t \cdot 3.0}\right) + \left(\frac{z}{t} \cdot \sqrt{a + t}\right))_* + \color{blue}{0}\right)}}\]
  7. Final simplification1.9

    \[\leadsto \frac{x}{x + y \cdot e^{(\left(c - b\right) \cdot \left(\left(\frac{5.0}{6.0} + a\right) - \frac{2.0}{t \cdot 3.0}\right) + \left(\frac{z}{t} \cdot \sqrt{t + a}\right))_* \cdot 2.0}}\]

Reproduce

herbie shell --seed 2019022 +o rules:numerics
(FPCore (x y z t a b c)
  :name "Numeric.SpecFunctions:invIncompleteBetaWorker from math-functions-0.1.5.2"
  (/ x (+ x (* y (exp (* 2.0 (- (/ (* z (sqrt (+ t a))) t) (* (- b c) (- (+ a (/ 5.0 6.0)) (/ 2.0 (* t 3.0)))))))))))

Details

Time bar (total: 50.1s)Debug log

sample170.0ms

Algorithm
intervals
Results
74.0ms262×body80nan
55.0ms256×body80valid

simplify283.0ms

Counts
1 → 1
Calls
1 calls:
Slowest
283.0ms
(/ x (+ x (* y (exp (* 2.0 (- (/ (* z (sqrt (+ t a))) t) (* (- b c) (- (+ a (/ 5.0 6.0)) (/ 2.0 (* t 3.0))))))))))

prune23.0ms

Pruning

1 alts after pruning (1 fresh and 0 done)

Merged error: 2.7b

localize61.0ms

Local error

Found 4 expressions with local error:

5.2b
(/ (* z (sqrt (+ t a))) t)
1.9b
(- (/ (* z (sqrt (+ t a))) t) (* (- b c) (- (+ a (/ 5.0 6.0)) (/ 2.0 (* t 3.0)))))
0.3b
(/ 2.0 (* t 3.0))
0.2b
(* z (sqrt (+ t a)))

rewrite19.0ms

Algorithm
rewrite-expression-head
Rules
30×associate--r+
28×prod-diff
22×add-cube-cbrt
22×*-un-lft-identity
22×add-sqr-sqrt
20×frac-sub
15×distribute-lft-in
15×distribute-rgt-in
10×div-inv
flip--
flip3--
associate-*r/
frac-times
add-log-exp
associate-*r*
flip-+
flip3-+
log1p-expm1-u
add-exp-log
sqrt-div
fma-neg
add-cbrt-cube
pow1
expm1-log1p-u
sqrt-prod
sub-neg
associate-/l/
associate--l+
associate-*l/
frac-2neg
clear-num
associate-/l*
*-commutative
diff-log
associate-/r*
Counts
4 → 112
Calls
4 calls:
Slowest
11.0ms
(- (/ (* z (sqrt (+ t a))) t) (* (- b c) (- (+ a (/ 5.0 6.0)) (/ 2.0 (* t 3.0)))))
4.0ms
(/ (* z (sqrt (+ t a))) t)
2.0ms
(* z (sqrt (+ t a)))
0.0ms
(/ 2.0 (* t 3.0))

series259.0ms

Counts
4 → 12
Calls
4 calls:
Slowest
155.0ms
(- (/ (* z (sqrt (+ t a))) t) (* (- b c) (- (+ a (/ 5.0 6.0)) (/ 2.0 (* t 3.0)))))
50.0ms
(/ (* z (sqrt (+ t a))) t)
41.0ms
(* z (sqrt (+ t a)))
12.0ms
(/ 2.0 (* t 3.0))

simplify16.1s

Counts
92 → 124
Calls
92 calls:
Slowest
662.0ms
(* t (* (+ b c) (* (- a (/ 5.0 6.0)) (* t 3.0))))
662.0ms
(- (* (* z (sqrt (+ t a))) (* (+ (* b b) (+ (* c c) (* b c))) (* (+ (* a a) (- (* (/ 5.0 6.0) (/ 5.0 6.0)) (* a (/ 5.0 6.0)))) (* t 3.0)))) (* t (* (- (pow b 3) (pow c 3)) (- (* (+ (pow a 3) (pow (/ 5.0 6.0) 3)) (* t 3.0)) (* (+ (* a a) (- (* (/ 5.0 6.0) (/ 5.0 6.0)) (* a (/ 5.0 6.0)))) 2.0)))))
558.0ms
(* (- b c) (fma (- (sqrt (/ 2.0 (* t 3.0)))) (sqrt (/ 2.0 (* t 3.0))) (* (sqrt (/ 2.0 (* t 3.0))) (sqrt (/ 2.0 (* t 3.0))))))
532.0ms
(- (* (* z (sqrt (+ t a))) (* (+ (* b b) (+ (* c c) (* b c))) (+ (* (+ a (/ 5.0 6.0)) (+ a (/ 5.0 6.0))) (+ (* (/ 2.0 (* t 3.0)) (/ 2.0 (* t 3.0))) (* (+ a (/ 5.0 6.0)) (/ 2.0 (* t 3.0))))))) (* t (* (- (pow b 3) (pow c 3)) (- (pow (+ a (/ 5.0 6.0)) 3) (pow (/ 2.0 (* t 3.0)) 3)))))
521.0ms
(* (fma (- (sqrt (/ 2.0 (* t 3.0)))) (sqrt (/ 2.0 (* t 3.0))) (* (sqrt (/ 2.0 (* t 3.0))) (sqrt (/ 2.0 (* t 3.0))))) (- b c))

prune2.7s

Pruning

2 alts after pruning (2 fresh and 0 done)

Merged error: 0b

localize61.0ms

Local error

Found 4 expressions with local error:

4.6b
(* (/ z t) (sqrt (+ a t)))
1.3b
(fma (- c b) (- (+ (/ 5.0 6.0) a) (/ 2.0 (* t 3.0))) (* (/ z t) (sqrt (+ a t))))
0.3b
(/ 2.0 (* t 3.0))
0.0b
(- (+ (/ 5.0 6.0) a) (/ 2.0 (* t 3.0)))

rewrite25.0ms

Algorithm
rewrite-expression-head
Rules
17×*-un-lft-identity
17×add-sqr-sqrt
15×add-cube-cbrt
12×prod-diff
add-log-exp
add-exp-log
associate-*r*
add-cbrt-cube
pow1
div-inv
log1p-expm1-u
associate-*l*
sqrt-div
expm1-log1p-u
flip-+
sqrt-prod
fma-neg
flip3-+
frac-sub
associate-*r/
frac-times
difference-of-squares
distribute-lft-out--
flip--
fma-udef
cbrt-unprod
*-commutative
associate--l+
prod-exp
associate-*l/
pow-prod-down
diff-log
flip3--
frac-2neg
sub-neg
associate-/r*
clear-num
Counts
4 → 85
Calls
4 calls:
Slowest
17.0ms
(- (+ (/ 5.0 6.0) a) (/ 2.0 (* t 3.0)))
7.0ms
(* (/ z t) (sqrt (+ a t)))
0.0ms
(/ 2.0 (* t 3.0))
0.0ms
(fma (- c b) (- (+ (/ 5.0 6.0) a) (/ 2.0 (* t 3.0))) (* (/ z t) (sqrt (+ a t))))

series192.0ms

Counts
4 → 12
Calls
4 calls:
Slowest
104.0ms
(fma (- c b) (- (+ (/ 5.0 6.0) a) (/ 2.0 (* t 3.0))) (* (/ z t) (sqrt (+ a t))))
59.0ms
(* (/ z t) (sqrt (+ a t)))
19.0ms
(- (+ (/ 5.0 6.0) a) (/ 2.0 (* t 3.0)))
10.0ms
(/ 2.0 (* t 3.0))

simplify5.8s

Counts
65 → 97
Calls
65 calls:
Slowest
495.0ms
(* (* (* (/ z t) (/ z t)) (/ z t)) (* (* (sqrt (+ a t)) (sqrt (+ a t))) (sqrt (+ a t))))
337.0ms
(fma (sqrt (+ (/ 5.0 6.0) a)) (sqrt (+ (/ 5.0 6.0) a)) (- (* (/ 1 (* t 3.0)) 2.0)))
291.0ms
(fma 1 (+ (/ 5.0 6.0) a) (- (* (/ 1 (* t 3.0)) 2.0)))
281.0ms
(fma 1 (+ (/ 5.0 6.0) a) (- (* (/ 2.0 (* t 3.0)) 1)))
269.0ms
(fma (* (cbrt (+ (/ 5.0 6.0) a)) (cbrt (+ (/ 5.0 6.0) a))) (cbrt (+ (/ 5.0 6.0) a)) (- (* (/ 1 (* t 3.0)) 2.0)))

prune2.4s

Pruning

2 alts after pruning (1 fresh and 1 done)

Merged error: 0b

localize32.0ms

Local error

Found 4 expressions with local error:

3.9b
(fma (* z (sqrt (+ t a))) (/ 1 t) (- (* (- b c) (- (+ a (/ 5.0 6.0)) (/ 2.0 (* t 3.0))))))
0.3b
(/ 2.0 (* t 3.0))
0.2b
(* z (sqrt (+ t a)))
0.1b
(* (- b c) (- (+ a (/ 5.0 6.0)) (/ 2.0 (* t 3.0))))

rewrite32.0ms

Algorithm
rewrite-expression-head
Rules
24×prod-diff
24×*-un-lft-identity
24×add-sqr-sqrt
22×add-cube-cbrt
15×distribute-lft-in
15×distribute-rgt-in
11×associate-*r*
flip--
flip3--
frac-times
div-inv
frac-sub
add-exp-log
associate-*r/
add-cbrt-cube
pow1
add-log-exp
log1p-expm1-u
flip-+
flip3-+
expm1-log1p-u
sqrt-prod
associate-*l*
*-commutative
associate--l+
associate-*l/
sqrt-div
sub-neg
difference-of-squares
distribute-lft-out--
fma-udef
cbrt-unprod
prod-exp
pow-prod-down
frac-2neg
associate-/r*
clear-num
Counts
4 → 106
Calls
4 calls:
Slowest
24.0ms
(* (- b c) (- (+ a (/ 5.0 6.0)) (/ 2.0 (* t 3.0))))
4.0ms
(* z (sqrt (+ t a)))
1.0ms
(/ 2.0 (* t 3.0))
0.0ms
(fma (* z (sqrt (+ t a))) (/ 1 t) (- (* (- b c) (- (+ a (/ 5.0 6.0)) (/ 2.0 (* t 3.0))))))

series300.0ms

Counts
4 → 12
Calls
4 calls:
Slowest
196.0ms
(fma (* z (sqrt (+ t a))) (/ 1 t) (- (* (- b c) (- (+ a (/ 5.0 6.0)) (/ 2.0 (* t 3.0))))))
61.0ms
(* (- b c) (- (+ a (/ 5.0 6.0)) (/ 2.0 (* t 3.0))))
36.0ms
(* z (sqrt (+ t a)))
7.0ms
(/ 2.0 (* t 3.0))

simplify12.2s

Counts
82 → 118
Calls
82 calls:
Slowest
664.0ms
(* (+ (* b b) (+ (* c c) (* b c))) (* (- a (/ 5.0 6.0)) (* t 3.0)))
573.0ms
(* (+ b c) (* (+ (* a a) (- (* (/ 5.0 6.0) (/ 5.0 6.0)) (* a (/ 5.0 6.0)))) (* t 3.0)))
514.0ms
(* (fma (- (sqrt (/ 2.0 (* t 3.0)))) (sqrt (/ 2.0 (* t 3.0))) (* (sqrt (/ 2.0 (* t 3.0))) (sqrt (/ 2.0 (* t 3.0))))) (- b c))
495.0ms
(* (fma (- (sqrt (/ 2.0 (* t 3.0)))) (sqrt (/ 2.0 (* t 3.0))) (* (sqrt (/ 2.0 (* t 3.0))) (sqrt (/ 2.0 (* t 3.0))))) (- b c))
485.0ms
(* (- (pow b 3) (pow c 3)) (- (* (- (* a a) (* (/ 5.0 6.0) (/ 5.0 6.0))) (* t 3.0)) (* (- a (/ 5.0 6.0)) 2.0)))

prune2.6s

Pruning

2 alts after pruning (0 fresh and 2 done)

Merged error: 0b

regimes512.0ms

Accuracy

0% (1.8b remaining)

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

bsearch4.0ms

end0.0ms

sample6.2s

Algorithm
intervals
Results
3.3s8000×body80valid
2.2s7953×body80nan