Average Error: 0.0 → 0.0
Time: 26.8s
Precision: 64
Internal Precision: 128
\[\frac{-\left(f + n\right)}{f - n}\]
\[-\frac{n + f}{f - n}\]

Error

Bits error versus f

Bits error versus n

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0.0

    \[\frac{-\left(f + n\right)}{f - n}\]
  2. Final simplification0.0

    \[\leadsto -\frac{n + f}{f - n}\]

Reproduce

herbie shell --seed 2019005 
(FPCore (f n)
  :name "subtraction fraction"
  (/ (- (+ f n)) (- f n)))

Details

Time bar (total: 25.9s)Debug log

sample131.0ms

Algorithm
intervals

simplify25.0ms

Counts
1 → 1
Calls

1 calls. Slowest were:

23.0ms
(/ (- (+ f n)) (- f n))

prune6.0ms

Pruning

1 alts after pruning (1 fresh and 0 done)

Merged error: 0.0b

localize35.0ms

Local error

Found 1 expressions with local error:

0.0b
(/ (- (+ f n)) (- f n))

rewrite8.0ms

Algorithm
rewrite-expression-head
Counts
1 → 61
Calls

1 calls. Slowest were:

6.0ms
(/ (- (+ f n)) (- f n))

series40.0ms

Counts
1 → 3
Calls

1 calls. Slowest were:

40.0ms
(/ (- (+ f n)) (- f n))

simplify1.1s

Counts
81 → 64
Calls

81 calls. Slowest were:

206.0ms
(- (- (* f f) (* n n)))
73.0ms
(/ (* (* (- (+ f n)) (- (+ f n))) (- (+ f n))) (* (* (- f n) (- f n)) (- f n)))
41.0ms
(/ (- (* (cbrt (+ f n)) (cbrt (+ f n)))) (* (cbrt (- f n)) (cbrt (- f n))))

prune483.0ms

Pruning

7 alts after pruning (6 fresh and 1 done)

Merged error: 0b

localize9.0ms

Local error

Found 4 expressions with local error:

0.0b
(/ (- (+ f n)) (- f n))
0.0b
(/ (- (+ f n)) (- f n))
0.0b
(/ (- (+ f n)) (- f n))
0.0b
(cbrt (* (* (/ (- (+ f n)) (- f n)) (/ (- (+ f n)) (- f n))) (/ (- (+ f n)) (- f n))))

rewrite44.0ms

Algorithm
rewrite-expression-head
Counts
4 → 200
Calls

4 calls. Slowest were:

15.0ms
(cbrt (* (* (/ (- (+ f n)) (- f n)) (/ (- (+ f n)) (- f n))) (/ (- (+ f n)) (- f n))))
9.0ms
(/ (- (+ f n)) (- f n))
9.0ms
(/ (- (+ f n)) (- f n))

series239.0ms

Counts
4 → 12
Calls

4 calls. Slowest were:

119.0ms
(cbrt (* (* (/ (- (+ f n)) (- f n)) (/ (- (+ f n)) (- f n))) (/ (- (+ f n)) (- f n))))
50.0ms
(/ (- (+ f n)) (- f n))
39.0ms
(/ (- (+ f n)) (- f n))
31.0ms
(/ (- (+ f n)) (- f n))

simplify5.8s

Counts
255 → 212
Calls

255 calls. Slowest were:

413.0ms
(/ (cbrt (- (+ f n))) (sqrt (- f n)))
369.0ms
(cbrt (* (* (/ (- (+ f n)) (- f n)) (- (+ f n))) (- (+ f n))))
321.0ms
(cbrt (* (* (- (+ f n)) (- (+ f n))) (/ (- (+ f n)) (- f n))))

prune2.1s

Pruning

6 alts after pruning (5 fresh and 1 done)

Merged error: 0b

localize31.0ms

Local error

Found 4 expressions with local error:

0.2b
(* (- (+ f n)) (/ 1 (- f n)))
0.0b
(/ (- (+ f n)) (- f n))
0.0b
(/ (- (+ f n)) (- f n))
0.0b
(cbrt (* (* (/ (- (+ f n)) (- f n)) (* (- (+ f n)) (/ 1 (- f n)))) (/ (- (+ f n)) (- f n))))

rewrite61.0ms

Algorithm
rewrite-expression-head
Counts
4 → 193
Calls

4 calls. Slowest were:

32.0ms
(cbrt (* (* (/ (- (+ f n)) (- f n)) (* (- (+ f n)) (/ 1 (- f n)))) (/ (- (+ f n)) (- f n))))
10.0ms
(* (- (+ f n)) (/ 1 (- f n)))
8.0ms
(/ (- (+ f n)) (- f n))

series282.0ms

Counts
4 → 12
Calls

4 calls. Slowest were:

146.0ms
(cbrt (* (* (/ (- (+ f n)) (- f n)) (* (- (+ f n)) (/ 1 (- f n)))) (/ (- (+ f n)) (- f n))))
52.0ms
(/ (- (+ f n)) (- f n))
49.0ms
(/ (- (+ f n)) (- f n))
34.0ms
(* (- (+ f n)) (/ 1 (- f n)))

simplify8.9s

Counts
222 → 205
Calls

222 calls. Slowest were:

636.0ms
(cbrt (* (* (- (+ f n)) (* (- (- (* f f) (* n n))) 1)) (- (+ f n))))
492.0ms
(cbrt (* (* (- (+ f n)) (* (- (+ f n)) 1)) (- (+ f n))))
410.0ms
(cbrt (* (/ (- (+ f n)) (- f n)) (* (- (+ f n)) (/ 1 (- f n)))))

prune2.3s

Pruning

6 alts after pruning (4 fresh and 2 done)

Merged error: 0b

localize32.0ms

Local error

Found 4 expressions with local error:

0.6b
(cbrt (- f n))
0.6b
(cbrt (- f n))
0.6b
(cbrt (- f n))
0.6b
(cbrt (- (+ f n)))

rewrite4.0ms

Algorithm
rewrite-expression-head
Counts
4 → 59
Calls

4 calls. Slowest were:

1.0ms
(cbrt (- (+ f n)))
1.0ms
(cbrt (- f n))
1.0ms
(cbrt (- f n))

series655.0ms

Counts
4 → 12
Calls

4 calls. Slowest were:

177.0ms
(cbrt (- f n))
175.0ms
(cbrt (- (+ f n)))
171.0ms
(cbrt (- f n))
132.0ms
(cbrt (- f n))

simplify1.7s

Counts
39 → 71
Calls

39 calls. Slowest were:

233.0ms
(- (exp (* 1/3 (+ (log -1) (log n)))) (+ (* 1/9 (* (pow f 2) (exp (* 1/3 (- (log -1) (* 5 (log n))))))) (* 1/3 (* (exp (* 1/3 (- (log -1) (* 2 (log n))))) f))))
229.0ms
(- (exp (* 1/3 (+ (log -1) (log n)))) (+ (* 1/9 (* (pow f 2) (exp (* 1/3 (- (log -1) (* 5 (log n))))))) (* 1/3 (* (exp (* 1/3 (- (log -1) (* 2 (log n))))) f))))
218.0ms
(- (exp (* 1/3 (+ (log -1) (log n)))) (+ (* 1/9 (* (pow f 2) (exp (* 1/3 (- (log -1) (* 5 (log n))))))) (* 1/3 (* (exp (* 1/3 (- (log -1) (* 2 (log n))))) f))))

prune1.1s

Pruning

5 alts after pruning (3 fresh and 2 done)

Merged error: 0b

regimes168.0ms

Accuracy

0% (0.0b remaining)

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

bsearch2.0ms

end0.0ms

sample762.0ms

Algorithm
intervals