Average Error: 12.1 → 11.0
Time: 30.0s
Precision: 64
\[\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}\;t \le -8.726925738034539270507380773704722857084 \cdot 10^{-133} \lor \neg \left(t \le 5.076318876201314174297201710312870570435 \cdot 10^{-117}\right):\\ \;\;\;\;\mathsf{fma}\left(x, y \cdot z - t \cdot a, b \cdot \left(i \cdot a - c \cdot z\right) + \left(\left(j \cdot c\right) \cdot t + \left(-y \cdot \left(i \cdot j\right)\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\sqrt[3]{\mathsf{fma}\left(y \cdot z - t \cdot a, x, \mathsf{fma}\left(j, \mathsf{fma}\left(-i, y, c \cdot t\right), b \cdot \left(i \cdot a - c \cdot z\right)\right)\right)} \cdot \sqrt[3]{\mathsf{fma}\left(y \cdot z - t \cdot a, x, \mathsf{fma}\left(j, \mathsf{fma}\left(-i, y, c \cdot t\right), b \cdot \left(i \cdot a - c \cdot z\right)\right)\right)}\right) \cdot \sqrt[3]{\mathsf{fma}\left(y \cdot z - t \cdot a, x, \mathsf{fma}\left(j, \mathsf{fma}\left(-i, y, c \cdot t\right), b \cdot \left(i \cdot a - c \cdot z\right)\right)\right)}\\ \end{array}\]
\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}\;t \le -8.726925738034539270507380773704722857084 \cdot 10^{-133} \lor \neg \left(t \le 5.076318876201314174297201710312870570435 \cdot 10^{-117}\right):\\
\;\;\;\;\mathsf{fma}\left(x, y \cdot z - t \cdot a, b \cdot \left(i \cdot a - c \cdot z\right) + \left(\left(j \cdot c\right) \cdot t + \left(-y \cdot \left(i \cdot j\right)\right)\right)\right)\\

\mathbf{else}:\\
\;\;\;\;\left(\sqrt[3]{\mathsf{fma}\left(y \cdot z - t \cdot a, x, \mathsf{fma}\left(j, \mathsf{fma}\left(-i, y, c \cdot t\right), b \cdot \left(i \cdot a - c \cdot z\right)\right)\right)} \cdot \sqrt[3]{\mathsf{fma}\left(y \cdot z - t \cdot a, x, \mathsf{fma}\left(j, \mathsf{fma}\left(-i, y, c \cdot t\right), b \cdot \left(i \cdot a - c \cdot z\right)\right)\right)}\right) \cdot \sqrt[3]{\mathsf{fma}\left(y \cdot z - t \cdot a, x, \mathsf{fma}\left(j, \mathsf{fma}\left(-i, y, c \cdot t\right), b \cdot \left(i \cdot a - c \cdot z\right)\right)\right)}\\

\end{array}
double f(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
        double r110066 = x;
        double r110067 = y;
        double r110068 = z;
        double r110069 = r110067 * r110068;
        double r110070 = t;
        double r110071 = a;
        double r110072 = r110070 * r110071;
        double r110073 = r110069 - r110072;
        double r110074 = r110066 * r110073;
        double r110075 = b;
        double r110076 = c;
        double r110077 = r110076 * r110068;
        double r110078 = i;
        double r110079 = r110078 * r110071;
        double r110080 = r110077 - r110079;
        double r110081 = r110075 * r110080;
        double r110082 = r110074 - r110081;
        double r110083 = j;
        double r110084 = r110076 * r110070;
        double r110085 = r110078 * r110067;
        double r110086 = r110084 - r110085;
        double r110087 = r110083 * r110086;
        double r110088 = r110082 + r110087;
        return r110088;
}

double f(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
        double r110089 = t;
        double r110090 = -8.72692573803454e-133;
        bool r110091 = r110089 <= r110090;
        double r110092 = 5.076318876201314e-117;
        bool r110093 = r110089 <= r110092;
        double r110094 = !r110093;
        bool r110095 = r110091 || r110094;
        double r110096 = x;
        double r110097 = y;
        double r110098 = z;
        double r110099 = r110097 * r110098;
        double r110100 = a;
        double r110101 = r110089 * r110100;
        double r110102 = r110099 - r110101;
        double r110103 = b;
        double r110104 = i;
        double r110105 = r110104 * r110100;
        double r110106 = c;
        double r110107 = r110106 * r110098;
        double r110108 = r110105 - r110107;
        double r110109 = r110103 * r110108;
        double r110110 = j;
        double r110111 = r110110 * r110106;
        double r110112 = r110111 * r110089;
        double r110113 = r110104 * r110110;
        double r110114 = r110097 * r110113;
        double r110115 = -r110114;
        double r110116 = r110112 + r110115;
        double r110117 = r110109 + r110116;
        double r110118 = fma(r110096, r110102, r110117);
        double r110119 = -r110104;
        double r110120 = r110106 * r110089;
        double r110121 = fma(r110119, r110097, r110120);
        double r110122 = fma(r110110, r110121, r110109);
        double r110123 = fma(r110102, r110096, r110122);
        double r110124 = cbrt(r110123);
        double r110125 = r110124 * r110124;
        double r110126 = r110125 * r110124;
        double r110127 = r110095 ? r110118 : r110126;
        return r110127;
}

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 t < -8.72692573803454e-133 or 5.076318876201314e-117 < t

    1. Initial program 13.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. Simplified13.8

      \[\leadsto \color{blue}{\mathsf{fma}\left(x, y \cdot z - t \cdot a, \mathsf{fma}\left(b, i \cdot a - c \cdot z, j \cdot \left(c \cdot t - i \cdot y\right)\right)\right)}\]
    3. Using strategy rm
    4. Applied sub-neg13.8

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

      \[\leadsto \mathsf{fma}\left(x, y \cdot z - t \cdot a, \mathsf{fma}\left(b, i \cdot a - c \cdot z, \color{blue}{j \cdot \left(c \cdot t\right) + j \cdot \left(-i \cdot y\right)}\right)\right)\]
    6. Simplified13.8

      \[\leadsto \mathsf{fma}\left(x, y \cdot z - t \cdot a, \mathsf{fma}\left(b, i \cdot a - c \cdot z, j \cdot \left(c \cdot t\right) + \color{blue}{\left(-i \cdot y\right) \cdot j}\right)\right)\]
    7. Using strategy rm
    8. Applied associate-*r*11.8

      \[\leadsto \mathsf{fma}\left(x, y \cdot z - t \cdot a, \mathsf{fma}\left(b, i \cdot a - c \cdot z, \color{blue}{\left(j \cdot c\right) \cdot t} + \left(-i \cdot y\right) \cdot j\right)\right)\]
    9. Using strategy rm
    10. Applied distribute-lft-neg-out11.8

      \[\leadsto \mathsf{fma}\left(x, y \cdot z - t \cdot a, \mathsf{fma}\left(b, i \cdot a - c \cdot z, \left(j \cdot c\right) \cdot t + \color{blue}{\left(-\left(i \cdot y\right) \cdot j\right)}\right)\right)\]
    11. Simplified11.5

      \[\leadsto \mathsf{fma}\left(x, y \cdot z - t \cdot a, \mathsf{fma}\left(b, i \cdot a - c \cdot z, \left(j \cdot c\right) \cdot t + \left(-\color{blue}{y \cdot \left(i \cdot j\right)}\right)\right)\right)\]
    12. Using strategy rm
    13. Applied fma-udef11.5

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

    if -8.72692573803454e-133 < t < 5.076318876201314e-117

    1. Initial program 9.2

      \[\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. Simplified9.2

      \[\leadsto \color{blue}{\mathsf{fma}\left(x, y \cdot z - t \cdot a, \mathsf{fma}\left(b, i \cdot a - c \cdot z, j \cdot \left(c \cdot t - i \cdot y\right)\right)\right)}\]
    3. Using strategy rm
    4. Applied sub-neg9.2

      \[\leadsto \mathsf{fma}\left(x, y \cdot z - t \cdot a, \mathsf{fma}\left(b, i \cdot a - c \cdot z, j \cdot \color{blue}{\left(c \cdot t + \left(-i \cdot y\right)\right)}\right)\right)\]
    5. Applied distribute-lft-in9.2

      \[\leadsto \mathsf{fma}\left(x, y \cdot z - t \cdot a, \mathsf{fma}\left(b, i \cdot a - c \cdot z, \color{blue}{j \cdot \left(c \cdot t\right) + j \cdot \left(-i \cdot y\right)}\right)\right)\]
    6. Simplified9.2

      \[\leadsto \mathsf{fma}\left(x, y \cdot z - t \cdot a, \mathsf{fma}\left(b, i \cdot a - c \cdot z, j \cdot \left(c \cdot t\right) + \color{blue}{\left(-i \cdot y\right) \cdot j}\right)\right)\]
    7. Using strategy rm
    8. Applied associate-*r*13.1

      \[\leadsto \mathsf{fma}\left(x, y \cdot z - t \cdot a, \mathsf{fma}\left(b, i \cdot a - c \cdot z, \color{blue}{\left(j \cdot c\right) \cdot t} + \left(-i \cdot y\right) \cdot j\right)\right)\]
    9. Using strategy rm
    10. Applied add-cube-cbrt14.0

      \[\leadsto \color{blue}{\left(\sqrt[3]{\mathsf{fma}\left(x, y \cdot z - t \cdot a, \mathsf{fma}\left(b, i \cdot a - c \cdot z, \left(j \cdot c\right) \cdot t + \left(-i \cdot y\right) \cdot j\right)\right)} \cdot \sqrt[3]{\mathsf{fma}\left(x, y \cdot z - t \cdot a, \mathsf{fma}\left(b, i \cdot a - c \cdot z, \left(j \cdot c\right) \cdot t + \left(-i \cdot y\right) \cdot j\right)\right)}\right) \cdot \sqrt[3]{\mathsf{fma}\left(x, y \cdot z - t \cdot a, \mathsf{fma}\left(b, i \cdot a - c \cdot z, \left(j \cdot c\right) \cdot t + \left(-i \cdot y\right) \cdot j\right)\right)}}\]
    11. Simplified14.1

      \[\leadsto \color{blue}{\left(\sqrt[3]{\mathsf{fma}\left(y \cdot z - t \cdot a, x, \mathsf{fma}\left(j, \mathsf{fma}\left(-i, y, c \cdot t\right), b \cdot \left(i \cdot a - c \cdot z\right)\right)\right)} \cdot \sqrt[3]{\mathsf{fma}\left(y \cdot z - t \cdot a, x, \mathsf{fma}\left(j, \mathsf{fma}\left(-i, y, c \cdot t\right), b \cdot \left(i \cdot a - c \cdot z\right)\right)\right)}\right)} \cdot \sqrt[3]{\mathsf{fma}\left(x, y \cdot z - t \cdot a, \mathsf{fma}\left(b, i \cdot a - c \cdot z, \left(j \cdot c\right) \cdot t + \left(-i \cdot y\right) \cdot j\right)\right)}\]
    12. Simplified10.1

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \le -8.726925738034539270507380773704722857084 \cdot 10^{-133} \lor \neg \left(t \le 5.076318876201314174297201710312870570435 \cdot 10^{-117}\right):\\ \;\;\;\;\mathsf{fma}\left(x, y \cdot z - t \cdot a, b \cdot \left(i \cdot a - c \cdot z\right) + \left(\left(j \cdot c\right) \cdot t + \left(-y \cdot \left(i \cdot j\right)\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\sqrt[3]{\mathsf{fma}\left(y \cdot z - t \cdot a, x, \mathsf{fma}\left(j, \mathsf{fma}\left(-i, y, c \cdot t\right), b \cdot \left(i \cdot a - c \cdot z\right)\right)\right)} \cdot \sqrt[3]{\mathsf{fma}\left(y \cdot z - t \cdot a, x, \mathsf{fma}\left(j, \mathsf{fma}\left(-i, y, c \cdot t\right), b \cdot \left(i \cdot a - c \cdot z\right)\right)\right)}\right) \cdot \sqrt[3]{\mathsf{fma}\left(y \cdot z - t \cdot a, x, \mathsf{fma}\left(j, \mathsf{fma}\left(-i, y, c \cdot t\right), b \cdot \left(i \cdot a - c \cdot z\right)\right)\right)}\\ \end{array}\]

Reproduce

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