Average Error: 11.8 → 11.9
Time: 29.1s
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 -1.968353631039049 \cdot 10^{-186}:\\ \;\;\;\;\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 \cdot j\right) \cdot \left(-i\right)\right)\\ \mathbf{elif}\;x \le 4.3723546946334725 \cdot 10^{-246}:\\ \;\;\;\;\left(\left(i \cdot y\right) \cdot \left(-j\right) + j \cdot \left(c \cdot t\right)\right) + \left(-b\right) \cdot \left(z \cdot c - i \cdot a\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(y \cdot z - a \cdot t\right) \cdot x - b \cdot \left(z \cdot c - i \cdot a\right)\right) + \left(\left(\sqrt[3]{-i} \cdot \sqrt[3]{-i}\right) \cdot \left(\sqrt[3]{-i} \cdot \left(y \cdot j\right)\right) + j \cdot \left(c \cdot t\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 3 regimes
  2. if x < -1.968353631039049e-186

    1. Initial program 10.3

      \[\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.3

      \[\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-rgt-in10.3

      \[\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(\left(c \cdot t\right) \cdot j + \left(-i \cdot y\right) \cdot j\right)}\]
    5. Using strategy rm
    6. Applied distribute-lft-neg-in10.3

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

      \[\leadsto \left(x \cdot \left(y \cdot z - t \cdot a\right) - b \cdot \left(c \cdot z - i \cdot a\right)\right) + \left(\left(c \cdot t\right) \cdot j + \color{blue}{\left(-i\right) \cdot \left(y \cdot j\right)}\right)\]
    8. Using strategy rm
    9. Applied associate-*l*10.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}{c \cdot \left(t \cdot j\right)} + \left(-i\right) \cdot \left(y \cdot j\right)\right)\]

    if -1.968353631039049e-186 < x < 4.3723546946334725e-246

    1. Initial program 15.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-neg15.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-rgt-in15.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(\left(c \cdot t\right) \cdot j + \left(-i \cdot y\right) \cdot j\right)}\]
    5. Taylor expanded around 0 15.9

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

    if 4.3723546946334725e-246 < x

    1. Initial program 11.3

      \[\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-neg11.3

      \[\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-rgt-in11.3

      \[\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(\left(c \cdot t\right) \cdot j + \left(-i \cdot y\right) \cdot j\right)}\]
    5. Using strategy rm
    6. Applied distribute-lft-neg-in11.3

      \[\leadsto \left(x \cdot \left(y \cdot z - t \cdot a\right) - b \cdot \left(c \cdot z - i \cdot a\right)\right) + \left(\left(c \cdot t\right) \cdot j + \color{blue}{\left(\left(-i\right) \cdot y\right)} \cdot j\right)\]
    7. Applied associate-*l*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(\left(c \cdot t\right) \cdot j + \color{blue}{\left(-i\right) \cdot \left(y \cdot j\right)}\right)\]
    8. Using strategy rm
    9. Applied add-cube-cbrt11.2

      \[\leadsto \left(x \cdot \left(y \cdot z - t \cdot a\right) - b \cdot \left(c \cdot z - i \cdot a\right)\right) + \left(\left(c \cdot t\right) \cdot j + \color{blue}{\left(\left(\sqrt[3]{-i} \cdot \sqrt[3]{-i}\right) \cdot \sqrt[3]{-i}\right)} \cdot \left(y \cdot j\right)\right)\]
    10. Applied associate-*l*11.2

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;x \le -1.968353631039049 \cdot 10^{-186}:\\ \;\;\;\;\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 \cdot j\right) \cdot \left(-i\right)\right)\\ \mathbf{elif}\;x \le 4.3723546946334725 \cdot 10^{-246}:\\ \;\;\;\;\left(\left(i \cdot y\right) \cdot \left(-j\right) + j \cdot \left(c \cdot t\right)\right) + \left(-b\right) \cdot \left(z \cdot c - i \cdot a\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\left(y \cdot z - a \cdot t\right) \cdot x - b \cdot \left(z \cdot c - i \cdot a\right)\right) + \left(\left(\sqrt[3]{-i} \cdot \sqrt[3]{-i}\right) \cdot \left(\sqrt[3]{-i} \cdot \left(y \cdot j\right)\right) + j \cdot \left(c \cdot t\right)\right)\\ \end{array}\]

Reproduce

herbie shell --seed 2019010 +o rules:numerics
(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: 26.0s)Debug log

sample156.0ms

Algorithm
intervals

simplify162.0ms

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

prune25.0ms

Pruning

2 alts after pruning (2 fresh and 0 done)

Merged error: 12.2b

localize39.0ms

Local error

Found 4 expressions with local error:

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

rewrite18.0ms

Algorithm
rewrite-expression-head
Rules
add-log-exp
add-cube-cbrt
associate-*l*
*-un-lft-identity
add-sqr-sqrt
log1p-expm1-u
add-exp-log
associate-*l/
add-cbrt-cube
pow1
expm1-log1p-u
flip--
flip3--
*-commutative
fma-udef
prod-diff
diff-log
fma-neg
sub-neg
Counts
4 → 56
Calls
4 calls:
Slowest
10.0ms
(* (- (* t c) (* y i)) j)
5.0ms
(* (- (* z c) (* i a)) b)
2.0ms
(- (* z y) (* t a))
0.0ms
(fma (- (* z y) (* t a)) x (- (* (- (* t c) (* y i)) j) (* (- (* z c) (* i a)) b)))

series553.0ms

Counts
4 → 12
Calls
4 calls:
Slowest
435.0ms
(fma (- (* z y) (* t a)) x (- (* (- (* t c) (* y i)) j) (* (- (* z c) (* i a)) b)))
47.0ms
(* (- (* z c) (* i a)) b)
43.0ms
(* (- (* t c) (* y i)) j)
28.0ms
(- (* z y) (* t a))

simplify1.5s

Counts
23 → 68
Calls
23 calls:
Slowest
263.0ms
(- (* a (* i b)) (+ (* z (* b c)) (* i (* j y))))
219.0ms
(- (* a (* i b)) (+ (* z (* b c)) (* i (* j y))))
204.0ms
(* (- (pow (* z c) 3) (pow (* i a) 3)) b)
140.0ms
(* (- (* (* z c) (* z c)) (* (* i a) (* i a))) b)
139.0ms
(* (- (pow (* t c) 3) (pow (* y i) 3)) j)

prune1.2s

Pruning

17 alts after pruning (17 fresh and 0 done)

Merged error: 7.6b

localize33.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))

rewrite19.0ms

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

series228.0ms

Counts
4 → 12
Calls
4 calls:
Slowest
64.0ms
(* b (- (* c z) (* i a)))
62.0ms
(* j (- (* c t) (* i y)))
55.0ms
(* x (- (* y z) (* t a)))
46.0ms
(- (* y z) (* t a))

simplify2.0s

Counts
48 → 91
Calls
48 calls:
Slowest
299.0ms
(* (fma (- y) i (* y i)) j)
211.0ms
(+ (* (* c t) (* c t)) (+ (* (* i y) (* i y)) (* (* c t) (* i y))))
173.0ms
(+ (* (* c z) (* c z)) (+ (* (* i a) (* i a)) (* (* c z) (* i a))))
150.0ms
(+ (* (* y z) (* y z)) (+ (* (* t a) (* t a)) (* (* y z) (* t a))))
109.0ms
(- (* x (* z y)) (* a (* x t)))

prune1.9s

Pruning

18 alts after pruning (18 fresh and 0 done)

Merged error: 7.6b

localize15.0ms

Local error

Found 4 expressions with local error:

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

rewrite16.0ms

Algorithm
rewrite-expression-head
Rules
add-cube-cbrt
associate-*l*
*-un-lft-identity
add-sqr-sqrt
associate-*r*
distribute-lft-in
distribute-rgt-in
add-log-exp
log1p-expm1-u
*-commutative
add-exp-log
associate-*r/
prod-diff
add-cbrt-cube
sub-neg
pow1
expm1-log1p-u
flip--
flip3--
distribute-rgt-neg-in
neg-mul-1
distribute-lft-neg-in
distribute-lft-neg-out
Counts
4 → 70
Calls
4 calls:
Slowest
5.0ms
(* (* c t) j)
4.0ms
(* b (- (* c z) (* i a)))
4.0ms
(* x (- (* y z) (* t a)))
3.0ms
(* (- (* i y)) j)

series169.0ms

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

simplify1.4s

Counts
38 → 82
Calls
38 calls:
Slowest
211.0ms
(+ (* (* y z) (* y z)) (+ (* (* t a) (* t a)) (* (* y z) (* t a))))
185.0ms
(+ (* (* c z) (* c z)) (+ (* (* i a) (* i a)) (* (* c z) (* i a))))
96.0ms
(- (* x (* z y)) (* a (* x t)))
69.0ms
(- (* x (* z y)) (* a (* x t)))
66.0ms
(- (* z (* b c)) (* a (* i b)))

prune1.9s

Pruning

18 alts after pruning (18 fresh and 0 done)

Merged error: 6.2b

localize15.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
(* (* c t) j)
4.6b
(* (- i) (* y j))

rewrite20.0ms

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

series173.0ms

Counts
4 → 12
Calls
4 calls:
Slowest
72.0ms
(* b (- (* c z) (* i a)))
45.0ms
(* x (- (* y z) (* t a)))
29.0ms
(* (- i) (* y j))
26.0ms
(* (* c t) j)

simplify2.1s

Counts
40 → 84
Calls
40 calls:
Slowest
613.0ms
(* (* (* (- i) (- i)) (- i)) (* (* (* y j) (* y j)) (* y j)))
227.0ms
(+ (* (* c z) (* c z)) (+ (* (* i a) (* i a)) (* (* c z) (* i a))))
185.0ms
(+ (* (* y z) (* y z)) (+ (* (* t a) (* t a)) (* (* y z) (* t a))))
90.0ms
(- (* x (* z y)) (* a (* x t)))
88.0ms
(- (* x (* z y)) (* a (* x t)))

prune1.9s

Pruning

17 alts after pruning (17 fresh and 0 done)

Merged error: 6.2b

regimes2.2s

Accuracy

-0.8% (5.9b remaining)

Error of 11.9b against oracle of 6.0b and baseline of 11.8b

bsearch565.0ms

end0.0ms

sample7.7s

Algorithm
intervals