Average Error: 11.8 → 11.9
Time: 22.4s
Precision: 64
Internal Precision: 128
\[\left(x \cdot \left(y \cdot z - t \cdot a\right) - b \cdot \left(c \cdot z - i \cdot a\right)\right) + j \cdot \left(c \cdot t - i \cdot y\right)\]
\[\begin{array}{l} \mathbf{if}\;x \le -3.7473322553187984 \cdot 10^{-211}:\\ \;\;\;\;\left(\left(y \cdot z - a \cdot t\right) \cdot x - b \cdot \left(z \cdot c - i \cdot a\right)\right) + \left(\left(t \cdot j\right) \cdot c + \left(-y\right) \cdot \left(i \cdot j\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(c \cdot t\right) \cdot j + \left(-i\right) \cdot \left(y \cdot j\right)\right) + \left(\left(y \cdot z - a \cdot t\right) \cdot x - b \cdot \left(z \cdot c - i \cdot a\right)\right)\\ \end{array}\]

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

Bits error versus j

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Split input into 2 regimes
  2. if x < -3.7473322553187984e-211

    1. Initial program 10.8

      \[\left(x \cdot \left(y \cdot z - t \cdot a\right) - b \cdot \left(c \cdot z - i \cdot a\right)\right) + j \cdot \left(c \cdot t - i \cdot y\right)\]
    2. Using strategy rm
    3. Applied sub-neg10.8

      \[\leadsto \left(x \cdot \left(y \cdot z - t \cdot a\right) - b \cdot \left(c \cdot z - i \cdot a\right)\right) + j \cdot \color{blue}{\left(c \cdot t + \left(-i \cdot y\right)\right)}\]
    4. Applied distribute-lft-in10.8

      \[\leadsto \left(x \cdot \left(y \cdot z - t \cdot a\right) - b \cdot \left(c \cdot z - i \cdot a\right)\right) + \color{blue}{\left(j \cdot \left(c \cdot t\right) + j \cdot \left(-i \cdot y\right)\right)}\]
    5. Using strategy rm
    6. Applied distribute-rgt-neg-in10.8

      \[\leadsto \left(x \cdot \left(y \cdot z - t \cdot a\right) - b \cdot \left(c \cdot z - i \cdot a\right)\right) + \left(j \cdot \left(c \cdot t\right) + j \cdot \color{blue}{\left(i \cdot \left(-y\right)\right)}\right)\]
    7. Applied associate-*r*11.4

      \[\leadsto \left(x \cdot \left(y \cdot z - t \cdot a\right) - b \cdot \left(c \cdot z - i \cdot a\right)\right) + \left(j \cdot \left(c \cdot t\right) + \color{blue}{\left(j \cdot i\right) \cdot \left(-y\right)}\right)\]
    8. Taylor expanded around inf 11.5

      \[\leadsto \left(x \cdot \left(y \cdot z - t \cdot a\right) - b \cdot \left(c \cdot z - i \cdot a\right)\right) + \left(\color{blue}{t \cdot \left(j \cdot c\right)} + \left(j \cdot i\right) \cdot \left(-y\right)\right)\]
    9. Using strategy rm
    10. Applied associate-*r*11.0

      \[\leadsto \left(x \cdot \left(y \cdot z - t \cdot a\right) - b \cdot \left(c \cdot z - i \cdot a\right)\right) + \left(\color{blue}{\left(t \cdot j\right) \cdot c} + \left(j \cdot i\right) \cdot \left(-y\right)\right)\]

    if -3.7473322553187984e-211 < x

    1. Initial program 12.4

      \[\left(x \cdot \left(y \cdot z - t \cdot a\right) - b \cdot \left(c \cdot z - i \cdot a\right)\right) + j \cdot \left(c \cdot t - i \cdot y\right)\]
    2. Using strategy rm
    3. Applied sub-neg12.4

      \[\leadsto \left(x \cdot \left(y \cdot z - t \cdot a\right) - b \cdot \left(c \cdot z - i \cdot a\right)\right) + j \cdot \color{blue}{\left(c \cdot t + \left(-i \cdot y\right)\right)}\]
    4. Applied distribute-lft-in12.4

      \[\leadsto \left(x \cdot \left(y \cdot z - t \cdot a\right) - b \cdot \left(c \cdot z - i \cdot a\right)\right) + \color{blue}{\left(j \cdot \left(c \cdot t\right) + j \cdot \left(-i \cdot y\right)\right)}\]
    5. Using strategy rm
    6. Applied distribute-rgt-neg-in12.4

      \[\leadsto \left(x \cdot \left(y \cdot z - t \cdot a\right) - b \cdot \left(c \cdot z - i \cdot a\right)\right) + \left(j \cdot \left(c \cdot t\right) + j \cdot \color{blue}{\left(i \cdot \left(-y\right)\right)}\right)\]
    7. Applied associate-*r*12.4

      \[\leadsto \left(x \cdot \left(y \cdot z - t \cdot a\right) - b \cdot \left(c \cdot z - i \cdot a\right)\right) + \left(j \cdot \left(c \cdot t\right) + \color{blue}{\left(j \cdot i\right) \cdot \left(-y\right)}\right)\]
    8. Taylor expanded around -inf 12.5

      \[\leadsto \left(x \cdot \left(y \cdot z - t \cdot a\right) - b \cdot \left(c \cdot z - i \cdot a\right)\right) + \left(j \cdot \left(c \cdot t\right) + \color{blue}{-1 \cdot \left(i \cdot \left(y \cdot j\right)\right)}\right)\]
    9. Simplified12.5

      \[\leadsto \left(x \cdot \left(y \cdot z - t \cdot a\right) - b \cdot \left(c \cdot z - i \cdot a\right)\right) + \left(j \cdot \left(c \cdot t\right) + \color{blue}{\left(y \cdot j\right) \cdot \left(-i\right)}\right)\]
  3. Recombined 2 regimes into one program.
  4. Final simplification11.9

    \[\leadsto \begin{array}{l} \mathbf{if}\;x \le -3.7473322553187984 \cdot 10^{-211}:\\ \;\;\;\;\left(\left(y \cdot z - a \cdot t\right) \cdot x - b \cdot \left(z \cdot c - i \cdot a\right)\right) + \left(\left(t \cdot j\right) \cdot c + \left(-y\right) \cdot \left(i \cdot j\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(c \cdot t\right) \cdot j + \left(-i\right) \cdot \left(y \cdot j\right)\right) + \left(\left(y \cdot z - a \cdot t\right) \cdot x - b \cdot \left(z \cdot c - i \cdot a\right)\right)\\ \end{array}\]

Reproduce

herbie shell --seed 2019010 
(FPCore (x y z t a b c i j)
  :name "Linear.Matrix:det33 from linear-1.19.1.3"
  (+ (- (* x (- (* y z) (* t a))) (* b (- (* c z) (* i a)))) (* j (- (* c t) (* i y)))))

Details

Time bar (total: 20.1s)Debug log

sample231.0ms

Algorithm
intervals

simplify133.0ms

Counts
1 → 1
Calls
1 calls:
Slowest
133.0ms
(+ (- (* x (- (* y z) (* t a))) (* b (- (* c z) (* i a)))) (* j (- (* c t) (* i y))))

prune11.0ms

Pruning

1 alts after pruning (1 fresh and 0 done)

Merged error: 12.2b

localize61.0ms

Local error

Found 4 expressions with local error:

6.3b
(* j (- (* c t) (* i y)))
6.1b
(* x (- (* y z) (* t a)))
4.8b
(* b (- (* c z) (* i a)))
0.2b
(- (* y z) (* t a))

rewrite18.0ms

Algorithm
rewrite-expression-head
Rules
associate-*r*
add-cube-cbrt
*-un-lft-identity
sub-neg
add-sqr-sqrt
add-log-exp
associate-*r/
distribute-lft-in
distribute-rgt-in
flip--
add-exp-log
add-cbrt-cube
flip3--
pow1
*-commutative
diff-log
Counts
4 → 63
Calls
4 calls:
Slowest
9.0ms
(* x (- (* y z) (* t a)))
3.0ms
(* j (- (* c t) (* i y)))
3.0ms
(* b (- (* c z) (* i a)))
2.0ms
(- (* y z) (* t a))

series212.0ms

Counts
4 → 12
Calls
4 calls:
Slowest
61.0ms
(* j (- (* c t) (* i y)))
57.0ms
(* x (- (* y z) (* t a)))
49.0ms
(* b (- (* c z) (* i a)))
44.0ms
(- (* y z) (* t a))

simplify1.3s

Counts
40 → 75
Calls
40 calls:
Slowest
148.0ms
(+ (* (* c z) (* c z)) (+ (* (* i a) (* i a)) (* (* c z) (* i a))))
114.0ms
(+ (* (* c t) (* c t)) (+ (* (* i y) (* i y)) (* (* c t) (* i y))))
113.0ms
(+ (* (* y z) (* y z)) (+ (* (* t a) (* t a)) (* (* y z) (* t a))))
91.0ms
(- (* z (* b c)) (* a (* i b)))
86.0ms
(- (* t (* j c)) (* i (* y j)))

prune1.5s

Pruning

19 alts after pruning (19 fresh and 0 done)

Merged error: 8.8b

localize13.0ms

Local error

Found 4 expressions with local error:

6.6b
(* j (- (* i y)))
6.1b
(* x (- (* y z) (* t a)))
4.8b
(* b (- (* c z) (* i a)))
4.8b
(* j (* c t))

rewrite10.0ms

Algorithm
rewrite-expression-head
Rules
13×associate-*r*
add-cube-cbrt
*-un-lft-identity
add-sqr-sqrt
add-log-exp
*-commutative
add-exp-log
associate-*r/
add-cbrt-cube
distribute-lft-in
sub-neg
pow1
distribute-rgt-in
flip--
flip3--
distribute-rgt-neg-out
distribute-rgt-neg-in
neg-mul-1
distribute-lft-neg-in
Counts
4 → 58
Calls
4 calls:
Slowest
3.0ms
(* b (- (* c z) (* i a)))
3.0ms
(* x (- (* y z) (* t a)))
2.0ms
(* j (- (* i y)))
1.0ms
(* j (* c t))

series162.0ms

Counts
4 → 12
Calls
4 calls:
Slowest
62.0ms
(* b (- (* c z) (* i a)))
57.0ms
(* x (- (* y z) (* t a)))
26.0ms
(* j (* c t))
18.0ms
(* j (- (* i y)))

simplify894.0ms

Counts
35 → 70
Calls
35 calls:
Slowest
135.0ms
(+ (* (* c z) (* c z)) (+ (* (* i a) (* i a)) (* (* c z) (* i a))))
120.0ms
(+ (* (* y z) (* y z)) (+ (* (* t a) (* t a)) (* (* y z) (* t a))))
92.0ms
(- (* z (* b c)) (* a (* i b)))
91.0ms
(- (* z (* b c)) (* a (* i b)))
49.0ms
(- (* x (* z y)) (* a (* x t)))

prune1.4s

Pruning

17 alts after pruning (17 fresh and 0 done)

Merged error: 6.4b

localize16.0ms

Local error

Found 4 expressions with local error:

6.1b
(* x (- (* y z) (* t a)))
4.8b
(* b (- (* c z) (* i a)))
4.8b
(* j (* c t))
4.3b
(* (* j i) (- y))

rewrite17.0ms

Algorithm
rewrite-expression-head
Rules
11×associate-*r*
add-cube-cbrt
*-un-lft-identity
add-sqr-sqrt
add-exp-log
add-cbrt-cube
pow1
add-log-exp
*-commutative
associate-*r/
distribute-lft-in
sub-neg
distribute-rgt-in
flip--
flip3--
cbrt-unprod
distribute-rgt-neg-out
prod-exp
pow-prod-down
associate-*l*
neg-mul-1
Counts
4 → 60
Calls
4 calls:
Slowest
7.0ms
(* (* j i) (- y))
4.0ms
(* b (- (* c z) (* i a)))
3.0ms
(* x (- (* y z) (* t a)))
2.0ms
(* j (* c t))

series176.0ms

Counts
4 → 12
Calls
4 calls:
Slowest
70.0ms
(* x (- (* y z) (* t a)))
55.0ms
(* b (- (* c z) (* i a)))
27.0ms
(* (* j i) (- y))
25.0ms
(* j (* c t))

simplify1.4s

Counts
36 → 72
Calls
36 calls:
Slowest
459.0ms
(* (* (* (* j i) (* j i)) (* j i)) (* (* (- y) (- y)) (- y)))
134.0ms
(+ (* (* c z) (* c z)) (+ (* (* i a) (* i a)) (* (* c z) (* i a))))
134.0ms
(+ (* (* y z) (* y z)) (+ (* (* t a) (* t a)) (* (* y z) (* t a))))
50.0ms
(- (* x (* z y)) (* a (* x t)))
44.0ms
(- (* z (* b c)) (* a (* i b)))

prune1.5s

Pruning

17 alts after pruning (17 fresh and 0 done)

Merged error: 6.2b

localize24.0ms

Local error

Found 4 expressions with local error:

6.1b
(* x (- (* y z) (* t a)))
4.8b
(* b (- (* c z) (* i a)))
4.3b
(* (* j i) (- y))
4.0b
(* t (* j c))

rewrite28.0ms

Algorithm
rewrite-expression-head
Rules
11×associate-*r*
add-cube-cbrt
*-un-lft-identity
add-sqr-sqrt
add-exp-log
add-cbrt-cube
pow1
add-log-exp
*-commutative
associate-*r/
distribute-lft-in
sub-neg
distribute-rgt-in
flip--
flip3--
cbrt-unprod
distribute-rgt-neg-out
prod-exp
pow-prod-down
associate-*l*
neg-mul-1
Counts
4 → 60
Calls
4 calls:
Slowest
7.0ms
(* x (- (* y z) (* t a)))
7.0ms
(* (* j i) (- y))
6.0ms
(* b (- (* c z) (* i a)))
2.0ms
(* t (* j c))

series170.0ms

Counts
4 → 12
Calls
4 calls:
Slowest
70.0ms
(* x (- (* y z) (* t a)))
44.0ms
(* b (- (* c z) (* i a)))
29.0ms
(* (* j i) (- y))
27.0ms
(* t (* j c))

simplify1.5s

Counts
36 → 72
Calls
36 calls:
Slowest
532.0ms
(* (* (* (* j i) (* j i)) (* j i)) (* (* (- y) (- y)) (- y)))
142.0ms
(+ (* (* c z) (* c z)) (+ (* (* i a) (* i a)) (* (* c z) (* i a))))
107.0ms
(+ (* (* y z) (* y z)) (+ (* (* t a) (* t a)) (* (* y z) (* t a))))
78.0ms
(- (* z (* b c)) (* a (* i b)))
63.0ms
(- (* x (* z y)) (* a (* x t)))

prune1.3s

Pruning

16 alts after pruning (16 fresh and 0 done)

Merged error: 6.0b

regimes1.6s

Accuracy

-3% (6.0b remaining)

Error of 11.9b against oracle of 5.9b and baseline of 11.7b

bsearch503.0ms

end0.0ms

sample6.1s

Algorithm
intervals