Average Error: 28.7 → 28.8
Time: 1.3m
Precision: 64
Internal Precision: 128
\[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i}\]
\[\left(t + \left(y \cdot \left(y \cdot \left(z + x \cdot y\right) + 27464.7644705\right) + 230661.510616\right) \cdot y\right) \cdot \frac{1}{i + y \cdot \left(\left(\left(a + y\right) \cdot y + b\right) \cdot y + c\right)}\]

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

Bits error versus i

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 28.7

    \[\frac{\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i}\]
  2. Using strategy rm
  3. Applied div-inv28.8

    \[\leadsto \color{blue}{\left(\left(\left(\left(x \cdot y + z\right) \cdot y + 27464.7644705\right) \cdot y + 230661.510616\right) \cdot y + t\right) \cdot \frac{1}{\left(\left(\left(y + a\right) \cdot y + b\right) \cdot y + c\right) \cdot y + i}}\]
  4. Final simplification28.8

    \[\leadsto \left(t + \left(y \cdot \left(y \cdot \left(z + x \cdot y\right) + 27464.7644705\right) + 230661.510616\right) \cdot y\right) \cdot \frac{1}{i + y \cdot \left(\left(\left(a + y\right) \cdot y + b\right) \cdot y + c\right)}\]

Reproduce

herbie shell --seed 2019016 +o rules:numerics
(FPCore (x y z t a b c i)
  :name "Numeric.SpecFunctions:logGamma from math-functions-0.1.5.2"
  (/ (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t) (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i)))

Details

Time bar (total: 1.3m)Debug log

sample83.0ms

Algorithm
intervals
Results
264×(pre true 80)
264×(body real 80)

simplify221.0ms

Counts
1 → 1
Calls
1 calls:
Slowest
221.0ms
(/ (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t) (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i))

prune36.0ms

Pruning

2 alts after pruning (2 fresh and 0 done)

Merged error: 28.0b

localize67.0ms

Local error

Found 4 expressions with local error:

28.0b
(/ (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t) (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i))
0.1b
(* (+ (* x y) z) y)
0.1b
(* (+ (* (+ y a) y) b) y)
0.1b
(* (+ (* (+ (* x y) z) y) 27464.7644705) y)

rewrite94.0ms

Algorithm
rewrite-expression-head
Rules
15×add-cube-cbrt
15×*-un-lft-identity
15×add-sqr-sqrt
associate-*l*
times-frac
add-exp-log
associate-*l/
add-cbrt-cube
flip-+
flip3-+
add-log-exp
log1p-expm1-u
pow1
expm1-log1p-u
associate-/l*
*-commutative
associate-/r*
associate-/l/
associate-/r/
div-inv
div-exp
frac-2neg
clear-num
cbrt-undiv
Counts
4 → 78
Calls
4 calls:
Slowest
69.0ms
(/ (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t) (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i))
11.0ms
(* (+ (* (+ (* x y) z) y) 27464.7644705) y)
8.0ms
(* (+ (* (+ y a) y) b) y)
5.0ms
(* (+ (* x y) z) y)

series447.0ms

Counts
4 → 12
Calls
4 calls:
Slowest
360.0ms
(/ (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t) (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i))
36.0ms
(* (+ (* (+ (* x y) z) y) 27464.7644705) y)
29.0ms
(* (+ (* (+ y a) y) b) y)
21.0ms
(* (+ (* x y) z) y)

simplify10.1s

Counts
53 → 90
Calls
53 calls:
Slowest
591.0ms
(+ (* (* (+ (* (+ (* (+ y a) y) b) y) c) y) (* (+ (* (+ (* (+ y a) y) b) y) c) y)) (- (* i i) (* (* (+ (* (+ (* (+ y a) y) b) y) c) y) i)))
442.0ms
(+ (pow (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) 3) (pow t 3))
440.0ms
(- (* (+ (* (+ (* (+ y a) y) b) y) c) y) i)
436.0ms
(sqrt (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t))
410.0ms
(/ (sqrt (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t)) 1)

prune2.1s

Pruning

10 alts after pruning (10 fresh and 0 done)

Merged error: 27.5b

localize8.0ms

Local error

Found 4 expressions with local error:

27.6b
(* (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t) (/ 1 (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i)))
0.4b
(/ 1 (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i))
0.1b
(* (+ (* x y) z) y)
0.1b
(* (+ (* (+ y a) y) b) y)

rewrite107.0ms

Algorithm
rewrite-expression-head
Rules
add-cube-cbrt
add-exp-log
associate-*l*
*-un-lft-identity
add-sqr-sqrt
pow1
flip-+
associate-*l/
associate-*r*
add-cbrt-cube
flip3-+
add-log-exp
log1p-expm1-u
associate-/r/
expm1-log1p-u
*-commutative
associate-/r*
div-inv
prod-exp
rec-exp
frac-times
inv-pow
pow-flip
cbrt-unprod
un-div-inv
associate-*r/
pow-prod-down
frac-2neg
clear-num
Counts
4 → 79
Calls
4 calls:
Slowest
77.0ms
(* (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t) (/ 1 (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i)))
15.0ms
(/ 1 (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i))
9.0ms
(* (+ (* (+ y a) y) b) y)
5.0ms
(* (+ (* x y) z) y)

series441.0ms

Counts
4 → 12
Calls
4 calls:
Slowest
311.0ms
(* (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t) (/ 1 (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i)))
68.0ms
(/ 1 (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i))
40.0ms
(* (+ (* x y) z) y)
22.0ms
(* (+ (* (+ y a) y) b) y)

simplify9.5s

Counts
46 → 91
Calls
46 calls:
Slowest
972.0ms
(* (+ (pow (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) 3) (pow t 3)) 1)
528.0ms
(* (- (* (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y)) (* t t)) 1)
450.0ms
(+ (* (* (+ (* (+ (* (+ y a) y) b) y) c) y) (* (+ (* (+ (* (+ y a) y) b) y) c) y)) (- (* i i) (* (* (+ (* (+ (* (+ y a) y) b) y) c) y) i)))
423.0ms
(sqrt (/ 1 (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i)))
400.0ms
(- (* (+ (* (+ (* (+ y a) y) b) y) c) y) i)

prune2.1s

Pruning

10 alts after pruning (9 fresh and 1 done)

Merged error: 27.5b

localize40.0ms

Local error

Found 4 expressions with local error:

28.0b
(/ (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t) (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i))
28.0b
(/ (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t) (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i))
28.0b
(/ (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t) (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i))
2.7b
(cbrt (/ (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t) (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i)))

rewrite209.0ms

Algorithm
rewrite-expression-head
Rules
36×times-frac
35×add-cube-cbrt
35×*-un-lft-identity
35×add-sqr-sqrt
15×cbrt-prod
10×add-exp-log
10×add-cbrt-cube
associate-/l*
associate-/r*
associate-/r/
flip-+
flip3-+
associate-/l/
add-log-exp
div-inv
log1p-expm1-u
pow1
expm1-log1p-u
div-exp
frac-2neg
clear-num
cbrt-undiv
pow1/3
cbrt-div
Counts
4 → 125
Calls
4 calls:
Slowest
82.0ms
(/ (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t) (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i))
59.0ms
(/ (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t) (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i))
51.0ms
(/ (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t) (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i))
15.0ms
(cbrt (/ (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t) (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i)))

series1.6s

Counts
4 → 12
Calls
4 calls:
Slowest
677.0ms
(cbrt (/ (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t) (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i)))
363.0ms
(/ (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t) (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i))
294.0ms
(/ (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t) (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i))
288.0ms
(/ (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t) (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i))

simplify26.3s

Counts
115 → 137
Calls
115 calls:
Slowest
550.0ms
(cbrt (/ (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t) (+ (pow (* (+ (* (+ (* (+ y a) y) b) y) c) y) 3) (pow i 3))))
506.0ms
(/ (sqrt (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t)) 1)
489.0ms
(+ (pow (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) 3) (pow t 3))
474.0ms
(+ (pow (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) 3) (pow t 3))
424.0ms
(cbrt (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t))

prune4.2s

Pruning

10 alts after pruning (8 fresh and 2 done)

Merged error: 27.5b

localize36.0ms

Local error

Found 4 expressions with local error:

24.6b
(/ (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t) (* (cbrt (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i)) (cbrt (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i))))
18.5b
(cbrt (fma (fma (+ a y) y b) (* y y) (fma c y i)))
18.5b
(cbrt (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i))
18.5b
(cbrt (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i))

rewrite107.0ms

Algorithm
rewrite-expression-head
Rules
16×cbrt-div
flip-+
add-cube-cbrt
add-exp-log
flip3-+
*-un-lft-identity
add-sqr-sqrt
cbrt-prod
associate-/r/
add-cbrt-cube
add-log-exp
log1p-expm1-u
pow1
frac-times
expm1-log1p-u
associate-/l*
pow1/3
times-frac
associate-/l/
associate-*r/
associate-*l/
div-exp
cbrt-undiv
div-inv
cbrt-unprod
prod-exp
frac-2neg
associate-/r*
clear-num
Counts
4 → 76
Calls
4 calls:
Slowest
80.0ms
(/ (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t) (* (cbrt (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i)) (cbrt (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i))))
15.0ms
(cbrt (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i))
10.0ms
(cbrt (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i))
1.0ms
(cbrt (fma (fma (+ a y) y b) (* y y) (fma c y i)))

series1.1s

Counts
4 → 12
Calls
4 calls:
Slowest
520.0ms
(/ (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t) (* (cbrt (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i)) (cbrt (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i))))
271.0ms
(cbrt (fma (fma (+ a y) y b) (* y y) (fma c y i)))
139.0ms
(cbrt (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i))
127.0ms
(cbrt (+ (* (+ (* (+ (* (+ y a) y) b) y) c) y) i))

simplify9.9s

Counts
48 → 88
Calls
48 calls:
Slowest
512.0ms
(cbrt (sqrt (fma (fma (+ a y) y b) (* y y) (fma c y i))))
468.0ms
(* (cbrt (+ (* (* (+ (* (+ (* (+ y a) y) b) y) c) y) (* (+ (* (+ (* (+ y a) y) b) y) c) y)) (- (* i i) (* (* (+ (* (+ (* (+ y a) y) b) y) c) y) i)))) (cbrt (+ (* (* (+ (* (+ (* (+ y a) y) b) y) c) y) (* (+ (* (+ (* (+ y a) y) b) y) c) y)) (- (* i i) (* (* (+ (* (+ (* (+ y a) y) b) y) c) y) i)))))
412.0ms
(cbrt (+ (* (* (+ (* (+ (* (+ y a) y) b) y) c) y) (* (+ (* (+ (* (+ y a) y) b) y) c) y)) (- (* i i) (* (* (+ (* (+ (* (+ y a) y) b) y) c) y) i))))
398.0ms
(cbrt (* (cbrt (fma (fma (+ a y) y b) (* y y) (fma c y i))) (cbrt (fma (fma (+ a y) y b) (* y y) (fma c y i)))))
396.0ms
(sqrt (+ (* (+ (* (+ (* (+ (* x y) z) y) 27464.7644705) y) 230661.510616) y) t))

prune2.6s

Pruning

11 alts after pruning (8 fresh and 3 done)

Merged error: 27.0b

regimes1.7s

Accuracy

0% (1.2b remaining)

Error of 28.8b against oracle of 27.6b and baseline of 28.8b

bsearch5.0ms

end0.0ms

sample3.4s

Algorithm
intervals
Results
8252×(pre true 80)
8251×(body real 80)
(body real 160)