Average Error: 11.5 → 4.5
Time: 1.7m
Precision: 64
Internal Precision: 384
\[\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}\;(\left(z \cdot y - a \cdot t\right) \cdot x + \left(\left(i \cdot a\right) \cdot b\right))_* + (\left(c \cdot t - i \cdot y\right) \cdot j + \left(\left(-z\right) \cdot \left(c \cdot b\right)\right))_* = -\infty:\\ \;\;\;\;(t \cdot \left(c \cdot j - x \cdot a\right) + \left(y \cdot \left(z \cdot x\right)\right))_* - (\left(z \cdot c - a \cdot i\right) \cdot b + \left(i \cdot \left(j \cdot y\right)\right))_*\\ \mathbf{if}\;(\left(z \cdot y - a \cdot t\right) \cdot x + \left(\left(i \cdot a\right) \cdot b\right))_* + (\left(c \cdot t - i \cdot y\right) \cdot j + \left(\left(-z\right) \cdot \left(c \cdot b\right)\right))_* \le 7.411284714648475 \cdot 10^{+306}:\\ \;\;\;\;(\left(z \cdot y - a \cdot t\right) \cdot x + \left(\left(i \cdot a\right) \cdot b\right))_* + (\left(c \cdot t - i \cdot y\right) \cdot j + \left(\left(-z\right) \cdot \left(c \cdot b\right)\right))_*\\ \mathbf{else}:\\ \;\;\;\;(t \cdot \left(c \cdot j - x \cdot a\right) + \left(y \cdot \left(z \cdot x\right)\right))_* - (\left(z \cdot c - a \cdot i\right) \cdot b + \left(i \cdot \left(j \cdot y\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

Derivation

  1. Split input into 2 regimes
  2. if (+ (fma (- (* z y) (* a t)) x (* (* i a) b)) (fma (- (* c t) (* i y)) j (* (- z) (* c b)))) or 7.411284714648475e+306 < (+ (fma (- (* z y) (* a t)) x (* (* i a) b)) (fma (- (* c t) (* i y)) j (* (- z) (* c b))))

    1. Initial program 48.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-neg48.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-in48.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. Applied associate-+r+48.8

      \[\leadsto \color{blue}{\left(\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\right)\right) + j \cdot \left(-i \cdot y\right)}\]
    6. Applied simplify41.4

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

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

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

    if (+ (fma (- (* z y) (* a t)) x (* (* i a) b)) (fma (- (* c t) (* i y)) j (* (- z) (* c b)))) < 7.411284714648475e+306

    1. Initial program 3.7

      \[\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. Taylor expanded around inf 2.0

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

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

Runtime

Time bar (total: 1.7m)Debug logProfile

herbie shell --seed '#(1064397287 3527694221 3797617954 1138343853 2854031332 1153838279)' +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)))))