Average Error: 0.2 → 0.0
Time: 11.6s
Precision: 64
Internal Precision: 128
\[\left(d1 \cdot 10 + d1 \cdot d2\right) + d1 \cdot 20\]
\[\left(30 + d2\right) \cdot d1\]

Error

Bits error versus d1

Bits error versus d2

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Target

Original0.2
Target0.0
Herbie0.0
\[d1 \cdot \left(30 + d2\right)\]

Derivation

  1. Initial program 0.2

    \[\left(d1 \cdot 10 + d1 \cdot d2\right) + d1 \cdot 20\]
  2. Simplified0.0

    \[\leadsto \color{blue}{\left(d2 + 30\right) \cdot d1}\]
  3. Final simplification0.0

    \[\leadsto \left(30 + d2\right) \cdot d1\]

Reproduce

herbie shell --seed 2019002 +o rules:numerics
(FPCore (d1 d2)
  :name "FastMath test2"

  :herbie-target
  (* d1 (+ 30 d2))

  (+ (+ (* d1 10) (* d1 d2)) (* d1 20)))

Details

Time bar (total: 11.2s)Debug log

sample48.0ms

Algorithm
intervals

simplify66.0ms

Counts
1 → 1
Calls

1 calls. Slowest were:

66.0ms
(+ (+ (* d1 10) (* d1 d2)) (* d1 20))

prune15.0ms

Pruning

2 alts after pruning (2 fresh and 0 done)

Merged error: 0.0b

localize14.0ms

Local error

Found 1 expressions with local error:

0.0b
(* (+ d2 30) d1)

rewrite5.0ms

Algorithm
rewrite-expression-head
Counts
1 → 15
Calls

1 calls. Slowest were:

5.0ms
(* (+ d2 30) d1)

series25.0ms

Counts
1 → 3
Calls

1 calls. Slowest were:

25.0ms
(* (+ d2 30) d1)

simplify298.0ms

Counts
7 → 18
Calls

7 calls. Slowest were:

218.0ms
(* (- (* d2 d2) (* 30 30)) d1)
38.0ms
(* (+ (pow d2 3) (pow 30 3)) d1)
11.0ms
(+ (* d2 d1) (* 30 d1))

prune145.0ms

Pruning

3 alts after pruning (2 fresh and 1 done)

Merged error: 0b

localize22.0ms

Local error

Found 4 expressions with local error:

0.5b
(* (* (cbrt (+ d2 30)) (cbrt (+ d2 30))) (* (cbrt (+ d2 30)) d1))
0.3b
(* (cbrt (+ d2 30)) d1)
0.2b
(* (cbrt (+ d2 30)) (cbrt (+ d2 30)))
0.2b
(cbrt (+ d2 30))

rewrite45.0ms

Algorithm
rewrite-expression-head
Counts
4 → 115
Calls

4 calls. Slowest were:

35.0ms
(* (* (cbrt (+ d2 30)) (cbrt (+ d2 30))) (* (cbrt (+ d2 30)) d1))
5.0ms
(* (cbrt (+ d2 30)) (cbrt (+ d2 30)))
3.0ms
(* (cbrt (+ d2 30)) d1)

series261.0ms

Counts
4 → 12
Calls

4 calls. Slowest were:

135.0ms
(* (cbrt (+ d2 30)) d1)
56.0ms
(* (cbrt (+ d2 30)) (cbrt (+ d2 30)))
54.0ms
(cbrt (+ d2 30))
15.0ms
(* (* (cbrt (+ d2 30)) (cbrt (+ d2 30))) (* (cbrt (+ d2 30)) d1))

simplify7.2s

Counts
105 → 127
Calls

105 calls. Slowest were:

577.0ms
(- (+ (* 1/45 (* d2 (pow 900 1/3))) (pow 900 1/3)) (* 1/8100 (* (pow d2 2) (pow 900 1/3))))
494.0ms
(* (* (* (* (cbrt (+ d2 30)) (cbrt (+ d2 30))) (* (cbrt (+ d2 30)) (cbrt (+ d2 30)))) (* (cbrt (+ d2 30)) (cbrt (+ d2 30)))) (* (* (* (cbrt (+ d2 30)) d1) (* (cbrt (+ d2 30)) d1)) (* (cbrt (+ d2 30)) d1)))
431.0ms
(* (* (+ d2 30) (+ d2 30)) (* (* (* (cbrt (+ d2 30)) d1) (* (cbrt (+ d2 30)) d1)) (* (cbrt (+ d2 30)) d1)))

prune1.2s

Pruning

3 alts after pruning (1 fresh and 2 done)

Merged error: 0b

localize24.0ms

Local error

Found 2 expressions with local error:

7.2b
(/ (* (fma d2 d2 -900) d1) (+ d2 -30))
6.6b
(* (fma d2 d2 -900) d1)

rewrite17.0ms

Algorithm
rewrite-expression-head
Counts
2 → 36
Calls

2 calls. Slowest were:

11.0ms
(/ (* (fma d2 d2 -900) d1) (+ d2 -30))
5.0ms
(* (fma d2 d2 -900) d1)

series81.0ms

Counts
2 → 6
Calls

2 calls. Slowest were:

46.0ms
(/ (* (fma d2 d2 -900) d1) (+ d2 -30))
35.0ms
(* (fma d2 d2 -900) d1)

simplify426.0ms

Counts
22 → 42
Calls

22 calls. Slowest were:

142.0ms
(/ (* (* (* (fma d2 d2 -900) d1) (* (fma d2 d2 -900) d1)) (* (fma d2 d2 -900) d1)) (* (* (+ d2 -30) (+ d2 -30)) (+ d2 -30)))
58.0ms
(+ (* d2 d2) (- (* -30 -30) (* d2 -30)))
38.0ms
(- (log (* (fma d2 d2 -900) d1)) (log (+ d2 -30)))

prune252.0ms

Pruning

3 alts after pruning (0 fresh and 3 done)

Merged error: 0b

regimes44.0ms

Accuracy

0% (0.0b remaining)

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

bsearch1.0ms

end0.0ms

sample1.1s

Algorithm
intervals