Average Error: 0.0 → 0.0
Time: 2.1s
Precision: 64
Internal Precision: 128
\[x \cdot \left(x \cdot x\right) + x \cdot x\]
\[x \cdot x + x \cdot \left(x \cdot x\right)\]

Error

Bits error versus x

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Target

Original0.0
Target0.0
Herbie0.0
\[\left(\left(1.0 + x\right) \cdot x\right) \cdot x\]

Derivation

  1. Initial program 0.0

    \[x \cdot \left(x \cdot x\right) + x \cdot x\]
  2. Final simplification0.0

    \[\leadsto x \cdot x + x \cdot \left(x \cdot x\right)\]

Reproduce

herbie shell --seed 2019010 
(FPCore (x)
  :name "Expression 3, p15"
  :pre (<= 0 x 2)

  :herbie-target
  (* (* (+ 1.0 x) x) x)

  (+ (* x (* x x)) (* x x)))

Details

Time bar (total: 1.8s)Debug log

sample16.0ms

Algorithm
intervals

simplify34.0ms

Counts
1 → 1
Calls
1 calls:
Slowest
34.0ms
(+ (* x (* x x)) (* x x))

prune10.0ms

Pruning

2 alts after pruning (2 fresh and 0 done)

Merged error: 0b

localize10.0ms

Local error

Found 2 expressions with local error:

0.1b
(* x (* x x))
0.0b
(+ (* x (* x x)) (* x x))

rewrite7.0ms

Algorithm
rewrite-expression-head
Rules
add-log-exp
add-cube-cbrt
add-exp-log
add-cbrt-cube
*-un-lft-identity
pow1
add-sqr-sqrt
distribute-lft-out
flip-+
*-commutative
associate-*r*
cube-unmult
flip3-+
distribute-lft1-in
sum-log
+-commutative
Counts
2 → 23
Calls
2 calls:
Slowest
5.0ms
(+ (* x (* x x)) (* x x))
2.0ms
(* x (* x x))

series57.0ms

Counts
2 → 6
Calls
2 calls:
Slowest
36.0ms
(+ (* x (* x x)) (* x x))
21.0ms
(* x (* x x))

simplify95.0ms

Counts
9 → 29
Calls
9 calls:
Slowest
39.0ms
(* (exp (* x (* x x))) (exp (* x x)))
12.0ms
(+ (pow x 3) (pow x 2))
12.0ms
(+ (pow x 3) (pow x 2))
12.0ms
(+ (pow x 3) (pow x 2))
11.0ms
(+ (* x x) x)

prune185.0ms

Pruning

2 alts after pruning (1 fresh and 1 done)

Merged error: 0b

localize5.0ms

Local error

Found 1 expressions with local error:

0.0b
(* x (+ (* x x) x))

rewrite3.0ms

Algorithm
rewrite-expression-head
Rules
associate-*r*
add-cube-cbrt
associate-*r/
*-un-lft-identity
add-sqr-sqrt
add-log-exp
flip-+
*-commutative
add-exp-log
add-cbrt-cube
flip3-+
distribute-lft1-in
distribute-lft-in
pow1
distribute-rgt-in
Counts
1 → 16
Calls
1 calls:
Slowest
3.0ms
(* x (+ (* x x) x))

series35.0ms

Counts
1 → 3
Calls
1 calls:
Slowest
35.0ms
(* x (+ (* x x) x))

simplify578.0ms

Counts
10 → 19
Calls
10 calls:
Slowest
530.0ms
(+ (* (* x x) (* x x)) (- (* x x) (* (* x x) x)))
9.0ms
(+ (pow x 3) (pow x 2))
8.0ms
(+ (* x x) x)
7.0ms
(+ (pow x 3) (pow x 2))
6.0ms
(sqrt (+ (* x x) x))

prune102.0ms

Pruning

2 alts after pruning (0 fresh and 2 done)

Merged error: 0b

regimes61.0ms

Accuracy

0% (0.0b remaining)

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

bsearch1.0ms

end0.0ms

sample639.0ms

Algorithm
intervals