Average Error: 12.1 → 11.1
Time: 11.8s
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}\;z \le -5.207284225159117405901576869261924607312 \cdot 10^{75} \lor \neg \left(z \le 1.132227610475922696553611274989143960938 \cdot 10^{-172}\right):\\ \;\;\;\;\mathsf{fma}\left(c \cdot t - i \cdot y, j, x \cdot \left(y \cdot z - t \cdot a\right) - \left(z \cdot \left(b \cdot c\right) + \left(-a \cdot \left(i \cdot b\right)\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\mathsf{fma}\left(c \cdot t - i \cdot y, j, x \cdot \left(y \cdot z - t \cdot a\right) - \left(\sqrt[3]{b} \cdot \sqrt[3]{b}\right) \cdot \left(\left(c \cdot z - i \cdot a\right) \cdot \sqrt[3]{b}\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}\;z \le -5.207284225159117405901576869261924607312 \cdot 10^{75} \lor \neg \left(z \le 1.132227610475922696553611274989143960938 \cdot 10^{-172}\right):\\
\;\;\;\;\mathsf{fma}\left(c \cdot t - i \cdot y, j, x \cdot \left(y \cdot z - t \cdot a\right) - \left(z \cdot \left(b \cdot c\right) + \left(-a \cdot \left(i \cdot b\right)\right)\right)\right)\\

\mathbf{else}:\\
\;\;\;\;\mathsf{fma}\left(c \cdot t - i \cdot y, j, x \cdot \left(y \cdot z - t \cdot a\right) - \left(\sqrt[3]{b} \cdot \sqrt[3]{b}\right) \cdot \left(\left(c \cdot z - i \cdot a\right) \cdot \sqrt[3]{b}\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 r111951 = x;
        double r111952 = y;
        double r111953 = z;
        double r111954 = r111952 * r111953;
        double r111955 = t;
        double r111956 = a;
        double r111957 = r111955 * r111956;
        double r111958 = r111954 - r111957;
        double r111959 = r111951 * r111958;
        double r111960 = b;
        double r111961 = c;
        double r111962 = r111961 * r111953;
        double r111963 = i;
        double r111964 = r111963 * r111956;
        double r111965 = r111962 - r111964;
        double r111966 = r111960 * r111965;
        double r111967 = r111959 - r111966;
        double r111968 = j;
        double r111969 = r111961 * r111955;
        double r111970 = r111963 * r111952;
        double r111971 = r111969 - r111970;
        double r111972 = r111968 * r111971;
        double r111973 = r111967 + r111972;
        return r111973;
}

double f(double x, double y, double z, double t, double a, double b, double c, double i, double j) {
        double r111974 = z;
        double r111975 = -5.2072842251591174e+75;
        bool r111976 = r111974 <= r111975;
        double r111977 = 1.1322276104759227e-172;
        bool r111978 = r111974 <= r111977;
        double r111979 = !r111978;
        bool r111980 = r111976 || r111979;
        double r111981 = c;
        double r111982 = t;
        double r111983 = r111981 * r111982;
        double r111984 = i;
        double r111985 = y;
        double r111986 = r111984 * r111985;
        double r111987 = r111983 - r111986;
        double r111988 = j;
        double r111989 = x;
        double r111990 = r111985 * r111974;
        double r111991 = a;
        double r111992 = r111982 * r111991;
        double r111993 = r111990 - r111992;
        double r111994 = r111989 * r111993;
        double r111995 = b;
        double r111996 = r111995 * r111981;
        double r111997 = r111974 * r111996;
        double r111998 = r111984 * r111995;
        double r111999 = r111991 * r111998;
        double r112000 = -r111999;
        double r112001 = r111997 + r112000;
        double r112002 = r111994 - r112001;
        double r112003 = fma(r111987, r111988, r112002);
        double r112004 = cbrt(r111995);
        double r112005 = r112004 * r112004;
        double r112006 = r111981 * r111974;
        double r112007 = r111984 * r111991;
        double r112008 = r112006 - r112007;
        double r112009 = r112008 * r112004;
        double r112010 = r112005 * r112009;
        double r112011 = r111994 - r112010;
        double r112012 = fma(r111987, r111988, r112011);
        double r112013 = r111980 ? r112003 : r112012;
        return r112013;
}

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 z < -5.2072842251591174e+75 or 1.1322276104759227e-172 < z

    1. Initial program 14.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. Simplified14.7

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

      \[\leadsto \mathsf{fma}\left(c \cdot t - i \cdot y, j, x \cdot \left(y \cdot z - t \cdot a\right) - \color{blue}{\left(\left(\sqrt[3]{b} \cdot \sqrt[3]{b}\right) \cdot \sqrt[3]{b}\right)} \cdot \left(c \cdot z - i \cdot a\right)\right)\]
    5. Applied associate-*l*15.0

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

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

      \[\leadsto \mathsf{fma}\left(c \cdot t - i \cdot y, j, x \cdot \left(y \cdot z - t \cdot a\right) - \left(\sqrt[3]{b} \cdot \sqrt[3]{b}\right) \cdot \color{blue}{\left(\sqrt[3]{b} \cdot \left(c \cdot z\right) + \sqrt[3]{b} \cdot \left(-i \cdot a\right)\right)}\right)\]
    9. Applied distribute-lft-in15.0

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

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

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

    if -5.2072842251591174e+75 < z < 1.1322276104759227e-172

    1. Initial program 9.5

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

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

      \[\leadsto \mathsf{fma}\left(c \cdot t - i \cdot y, j, x \cdot \left(y \cdot z - t \cdot a\right) - \color{blue}{\left(\left(\sqrt[3]{b} \cdot \sqrt[3]{b}\right) \cdot \sqrt[3]{b}\right)} \cdot \left(c \cdot z - i \cdot a\right)\right)\]
    5. Applied associate-*l*9.8

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

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

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

Reproduce

herbie shell --seed 2019352 +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)))))