Average Error: 0.0 → 0.0
Time: 1.4m
Precision: 64
Internal Precision: 128
\[\frac{1 + \frac{2 \cdot t}{1 + t} \cdot \frac{2 \cdot t}{1 + t}}{2 + \frac{2 \cdot t}{1 + t} \cdot \frac{2 \cdot t}{1 + t}}\]
\[\frac{1 + \frac{t \cdot 2}{1 + t} \cdot \frac{t \cdot 2}{1 + t}}{\log \left(e^{\frac{t \cdot 2}{1 + t} \cdot \frac{t \cdot 2}{1 + t}}\right) + 2}\]

Error

Bits error versus t

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0.0

    \[\frac{1 + \frac{2 \cdot t}{1 + t} \cdot \frac{2 \cdot t}{1 + t}}{2 + \frac{2 \cdot t}{1 + t} \cdot \frac{2 \cdot t}{1 + t}}\]
  2. Using strategy rm
  3. Applied add-log-exp0.0

    \[\leadsto \frac{1 + \frac{2 \cdot t}{1 + t} \cdot \frac{2 \cdot t}{1 + t}}{2 + \color{blue}{\log \left(e^{\frac{2 \cdot t}{1 + t} \cdot \frac{2 \cdot t}{1 + t}}\right)}}\]
  4. Final simplification0.0

    \[\leadsto \frac{1 + \frac{t \cdot 2}{1 + t} \cdot \frac{t \cdot 2}{1 + t}}{\log \left(e^{\frac{t \cdot 2}{1 + t} \cdot \frac{t \cdot 2}{1 + t}}\right) + 2}\]

Reproduce

herbie shell --seed 2019022 
(FPCore (t)
  :name "Kahan p13 Example 1"
  (/ (+ 1 (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))) (+ 2 (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))))))

Details

Time bar (total: 1.4m)Debug log

sample26.0ms

Algorithm
intervals
Results
18.0ms256×body80valid

simplify524.0ms

Counts
1 → 1
Calls
1 calls:
Slowest
524.0ms
(/ (+ 1 (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))) (+ 2 (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))))

prune7.0ms

Pruning

1 alts after pruning (1 fresh and 0 done)

Merged error: 0.0b

localize37.0ms

Local error

Found 4 expressions with local error:

0.0b
(* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))
0.0b
(* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))
0.0b
(/ (+ 1 (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))) (+ 2 (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))))
0.0b
(/ (* 2 t) (+ 1 t))

rewrite66.0ms

Algorithm
rewrite-expression-head
Rules
32×add-exp-log
32×add-cbrt-cube
24×times-frac
22×add-cube-cbrt
22×*-un-lft-identity
22×add-sqr-sqrt
18×associate-*l*
18×associate-*r*
14×pow1
12×associate-/r/
10×div-exp
10×cbrt-undiv
cbrt-unprod
prod-exp
flip-+
flip3-+
div-inv
associate-/r*
add-log-exp
associate-/l*
associate-/l/
pow-prod-up
*-commutative
associate-*r/
associate-*l/
pow-prod-down
pow-plus
frac-2neg
clear-num
frac-times
pow2
Counts
4 → 134
Calls
4 calls:
Slowest
23.0ms
(/ (+ 1 (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))) (+ 2 (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))))
20.0ms
(* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))
14.0ms
(* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))
6.0ms
(/ (* 2 t) (+ 1 t))

series89.0ms

Counts
4 → 12
Calls
4 calls:
Slowest
35.0ms
(/ (+ 1 (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))) (+ 2 (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))))
20.0ms
(* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))
20.0ms
(/ (* 2 t) (+ 1 t))
13.0ms
(* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))

simplify22.1s

Counts
120 → 146
Calls
120 calls:
Slowest
960.0ms
(sqrt (+ 2 (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))))
731.0ms
(* (* (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))) (/ (* 2 t) (+ 1 t))) (* (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))) (/ (* 2 t) (+ 1 t))))
654.0ms
(* (* (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))) (/ (* 2 t) (+ 1 t))) (* (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))) (/ (* 2 t) (+ 1 t))))
556.0ms
(+ (* 2 2) (- (* (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))) (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))) (* 2 (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))))))
544.0ms
(/ (+ 1 (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))) (cbrt (+ 2 (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))))))

prune1.3s

Pruning

2 alts after pruning (2 fresh and 0 done)

Merged error: 0b

localize11.0ms

Local error

Found 4 expressions with local error:

0.6b
(log (exp (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))))
0.0b
(exp (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))))
0.0b
(* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))
0.0b
(* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))

rewrite25.0ms

Algorithm
rewrite-expression-head
Rules
28×add-exp-log
28×add-cbrt-cube
18×associate-*l*
18×associate-*r*
15×pow1
13×add-cube-cbrt
13×*-un-lft-identity
13×add-sqr-sqrt
12×times-frac
cbrt-unprod
associate-/r/
prod-exp
div-exp
cbrt-undiv
add-log-exp
div-inv
flip-+
flip3-+
log-pow
log-prod
pow-prod-up
*-commutative
associate-*r/
associate-*l/
pow-prod-down
exp-to-pow
pow-plus
exp-prod
frac-times
pow2
rem-exp-log
rem-log-exp
Counts
4 → 106
Calls
4 calls:
Slowest
10.0ms
(* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))
7.0ms
(* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))
3.0ms
(log (exp (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))))
3.0ms
(exp (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))))

series69.0ms

Counts
4 → 12
Calls
4 calls:
Slowest
32.0ms
(exp (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))))
13.0ms
(* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))
12.0ms
(log (exp (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))))
12.0ms
(* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))

simplify9.6s

Counts
87 → 118
Calls
87 calls:
Slowest
673.0ms
(* (* (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))) (/ (* 2 t) (+ 1 t))) (* (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))) (/ (* 2 t) (+ 1 t))))
639.0ms
(* (* (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))) (/ (* 2 t) (+ 1 t))) (* (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))) (/ (* 2 t) (+ 1 t))))
468.0ms
(* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))
461.0ms
(log (* (cbrt (exp (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))))) (cbrt (exp (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))))))
453.0ms
(* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))

prune1.1s

Pruning

2 alts after pruning (1 fresh and 1 done)

Merged error: 0b

localize34.0ms

Local error

Found 4 expressions with local error:

0.1b
(* (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))) (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))))
0.0b
(- 2 (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))))
0.0b
(* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))
0.0b
(* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))

rewrite86.0ms

Algorithm
rewrite-expression-head
Rules
158×add-exp-log
158×add-cbrt-cube
73×cbrt-unprod
73×prod-exp
71×pow1
48×div-exp
48×cbrt-undiv
25×pow-prod-up
20×pow-prod-down
19×associate-*l*
19×associate-*r*
19×frac-times
14×pow-plus
13×associate-*r/
13×associate-*l/
12×add-cube-cbrt
12×times-frac
12×*-un-lft-identity
12×add-sqr-sqrt
11×pow2
associate-/r/
add-log-exp
div-inv
flip-+
flip3-+
*-commutative
flip--
flip3--
sub-neg
Counts
4 → 193
Calls
4 calls:
Slowest
49.0ms
(* (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))) (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))))
17.0ms
(* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))
14.0ms
(* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))
2.0ms
(- 2 (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))))

series71.0ms

Counts
4 → 12
Calls
4 calls:
Slowest
20.0ms
(* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))
20.0ms
(* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))
16.0ms
(* (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))) (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))))
15.0ms
(- 2 (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))))

simplify44.2s

Counts
195 → 205
Calls
195 calls:
Slowest
1.2s
(* (* (* (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))) (/ (* 2 t) (+ 1 t))) (/ (* (* (* 2 t) (* 2 t)) (* 2 t)) (* (* (+ 1 t) (+ 1 t)) (+ 1 t)))) (* (/ (* (* (* 2 t) (* 2 t)) (* 2 t)) (* (* (+ 1 t) (+ 1 t)) (+ 1 t))) (* (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))) (/ (* 2 t) (+ 1 t)))))
1.1s
(* (* (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))) (/ (* 2 t) (+ 1 t))) (* (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))) (/ (* 2 t) (+ 1 t))))
978.0ms
(* (* (+ 1 t) (+ 1 t)) (* (+ 1 t) (+ 1 t)))
867.0ms
(* (* (/ (* (* (* 2 t) (* 2 t)) (* 2 t)) (* (* (+ 1 t) (+ 1 t)) (+ 1 t))) (* (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))) (/ (* 2 t) (+ 1 t)))) (* (* (* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t))) (/ (* 2 t) (+ 1 t))) (/ (* (* (* 2 t) (* 2 t)) (* 2 t)) (* (* (+ 1 t) (+ 1 t)) (+ 1 t)))))
833.0ms
(* (/ (* 2 t) (+ 1 t)) (/ (* 2 t) (+ 1 t)))

prune2.0s

Pruning

2 alts after pruning (0 fresh and 2 done)

Merged error: 0b

regimes94.0ms

Accuracy

0% (0.0b remaining)

Error of 0.0b against oracle of 0.0b and baseline of 0.0b

bsearch2.0ms

end0.0ms

sample940.0ms

Algorithm
intervals
Results
853.0ms8000×body80valid