Linear.Matrix:det44 from linear-1.19.1.3

Percentage Accurate: 30.4% → 43.5%
Time: 28.6s
Alternatives: 33
Speedup: 5.6×

Specification

?
\[\begin{array}{l} \\ \left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (+
  (-
   (+
    (+
     (-
      (* (- (* x y) (* z t)) (- (* a b) (* c i)))
      (* (- (* x j) (* z k)) (- (* y0 b) (* y1 i))))
     (* (- (* x y2) (* z y3)) (- (* y0 c) (* y1 a))))
    (* (- (* t j) (* y k)) (- (* y4 b) (* y5 i))))
   (* (- (* t y2) (* y y3)) (- (* y4 c) (* y5 a))))
  (* (- (* k y2) (* j y3)) (- (* y4 y1) (* y5 y0)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	return (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - (((x * j) - (z * k)) * ((y0 * b) - (y1 * i)))) + (((x * y2) - (z * y3)) * ((y0 * c) - (y1 * a)))) + (((t * j) - (y * k)) * ((y4 * b) - (y5 * i)))) - (((t * y2) - (y * y3)) * ((y4 * c) - (y5 * a)))) + (((k * y2) - (j * y3)) * ((y4 * y1) - (y5 * y0)));
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8), intent (in) :: y0
    real(8), intent (in) :: y1
    real(8), intent (in) :: y2
    real(8), intent (in) :: y3
    real(8), intent (in) :: y4
    real(8), intent (in) :: y5
    code = (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - (((x * j) - (z * k)) * ((y0 * b) - (y1 * i)))) + (((x * y2) - (z * y3)) * ((y0 * c) - (y1 * a)))) + (((t * j) - (y * k)) * ((y4 * b) - (y5 * i)))) - (((t * y2) - (y * y3)) * ((y4 * c) - (y5 * a)))) + (((k * y2) - (j * y3)) * ((y4 * y1) - (y5 * y0)))
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	return (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - (((x * j) - (z * k)) * ((y0 * b) - (y1 * i)))) + (((x * y2) - (z * y3)) * ((y0 * c) - (y1 * a)))) + (((t * j) - (y * k)) * ((y4 * b) - (y5 * i)))) - (((t * y2) - (y * y3)) * ((y4 * c) - (y5 * a)))) + (((k * y2) - (j * y3)) * ((y4 * y1) - (y5 * y0)));
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5):
	return (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - (((x * j) - (z * k)) * ((y0 * b) - (y1 * i)))) + (((x * y2) - (z * y3)) * ((y0 * c) - (y1 * a)))) + (((t * j) - (y * k)) * ((y4 * b) - (y5 * i)))) - (((t * y2) - (y * y3)) * ((y4 * c) - (y5 * a)))) + (((k * y2) - (j * y3)) * ((y4 * y1) - (y5 * y0)))
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	return Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * y) - Float64(z * t)) * Float64(Float64(a * b) - Float64(c * i))) - Float64(Float64(Float64(x * j) - Float64(z * k)) * Float64(Float64(y0 * b) - Float64(y1 * i)))) + Float64(Float64(Float64(x * y2) - Float64(z * y3)) * Float64(Float64(y0 * c) - Float64(y1 * a)))) + Float64(Float64(Float64(t * j) - Float64(y * k)) * Float64(Float64(y4 * b) - Float64(y5 * i)))) - Float64(Float64(Float64(t * y2) - Float64(y * y3)) * Float64(Float64(y4 * c) - Float64(y5 * a)))) + Float64(Float64(Float64(k * y2) - Float64(j * y3)) * Float64(Float64(y4 * y1) - Float64(y5 * y0))))
end
function tmp = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	tmp = (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - (((x * j) - (z * k)) * ((y0 * b) - (y1 * i)))) + (((x * y2) - (z * y3)) * ((y0 * c) - (y1 * a)))) + (((t * j) - (y * k)) * ((y4 * b) - (y5 * i)))) - (((t * y2) - (y * y3)) * ((y4 * c) - (y5 * a)))) + (((k * y2) - (j * y3)) * ((y4 * y1) - (y5 * y0)));
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := N[(N[(N[(N[(N[(N[(N[(N[(x * y), $MachinePrecision] - N[(z * t), $MachinePrecision]), $MachinePrecision] * N[(N[(a * b), $MachinePrecision] - N[(c * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(N[(x * j), $MachinePrecision] - N[(z * k), $MachinePrecision]), $MachinePrecision] * N[(N[(y0 * b), $MachinePrecision] - N[(y1 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(x * y2), $MachinePrecision] - N[(z * y3), $MachinePrecision]), $MachinePrecision] * N[(N[(y0 * c), $MachinePrecision] - N[(y1 * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(t * j), $MachinePrecision] - N[(y * k), $MachinePrecision]), $MachinePrecision] * N[(N[(y4 * b), $MachinePrecision] - N[(y5 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision] * N[(N[(y4 * c), $MachinePrecision] - N[(y5 * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(k * y2), $MachinePrecision] - N[(j * y3), $MachinePrecision]), $MachinePrecision] * N[(N[(y4 * y1), $MachinePrecision] - N[(y5 * y0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right)
\end{array}

Local Percentage Accuracy vs ?

The average percentage accuracy by input value. Horizontal axis shows value of an input variable; the variable is choosen in the title. Vertical axis is accuracy; higher is better. Red represent the original program, while blue represents Herbie's suggestion. These can be toggled with buttons below the plot. The line is an average while dots represent individual samples.

Accuracy vs Speed?

Herbie found 33 alternatives:

AlternativeAccuracySpeedup
The accuracy (vertical axis) and speed (horizontal axis) of each alternatives. Up and to the right is better. The red square shows the initial program, and each blue circle shows an alternative.The line shows the best available speed-accuracy tradeoffs.

Initial Program: 30.4% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (+
  (-
   (+
    (+
     (-
      (* (- (* x y) (* z t)) (- (* a b) (* c i)))
      (* (- (* x j) (* z k)) (- (* y0 b) (* y1 i))))
     (* (- (* x y2) (* z y3)) (- (* y0 c) (* y1 a))))
    (* (- (* t j) (* y k)) (- (* y4 b) (* y5 i))))
   (* (- (* t y2) (* y y3)) (- (* y4 c) (* y5 a))))
  (* (- (* k y2) (* j y3)) (- (* y4 y1) (* y5 y0)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	return (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - (((x * j) - (z * k)) * ((y0 * b) - (y1 * i)))) + (((x * y2) - (z * y3)) * ((y0 * c) - (y1 * a)))) + (((t * j) - (y * k)) * ((y4 * b) - (y5 * i)))) - (((t * y2) - (y * y3)) * ((y4 * c) - (y5 * a)))) + (((k * y2) - (j * y3)) * ((y4 * y1) - (y5 * y0)));
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8), intent (in) :: y0
    real(8), intent (in) :: y1
    real(8), intent (in) :: y2
    real(8), intent (in) :: y3
    real(8), intent (in) :: y4
    real(8), intent (in) :: y5
    code = (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - (((x * j) - (z * k)) * ((y0 * b) - (y1 * i)))) + (((x * y2) - (z * y3)) * ((y0 * c) - (y1 * a)))) + (((t * j) - (y * k)) * ((y4 * b) - (y5 * i)))) - (((t * y2) - (y * y3)) * ((y4 * c) - (y5 * a)))) + (((k * y2) - (j * y3)) * ((y4 * y1) - (y5 * y0)))
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	return (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - (((x * j) - (z * k)) * ((y0 * b) - (y1 * i)))) + (((x * y2) - (z * y3)) * ((y0 * c) - (y1 * a)))) + (((t * j) - (y * k)) * ((y4 * b) - (y5 * i)))) - (((t * y2) - (y * y3)) * ((y4 * c) - (y5 * a)))) + (((k * y2) - (j * y3)) * ((y4 * y1) - (y5 * y0)));
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5):
	return (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - (((x * j) - (z * k)) * ((y0 * b) - (y1 * i)))) + (((x * y2) - (z * y3)) * ((y0 * c) - (y1 * a)))) + (((t * j) - (y * k)) * ((y4 * b) - (y5 * i)))) - (((t * y2) - (y * y3)) * ((y4 * c) - (y5 * a)))) + (((k * y2) - (j * y3)) * ((y4 * y1) - (y5 * y0)))
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	return Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * y) - Float64(z * t)) * Float64(Float64(a * b) - Float64(c * i))) - Float64(Float64(Float64(x * j) - Float64(z * k)) * Float64(Float64(y0 * b) - Float64(y1 * i)))) + Float64(Float64(Float64(x * y2) - Float64(z * y3)) * Float64(Float64(y0 * c) - Float64(y1 * a)))) + Float64(Float64(Float64(t * j) - Float64(y * k)) * Float64(Float64(y4 * b) - Float64(y5 * i)))) - Float64(Float64(Float64(t * y2) - Float64(y * y3)) * Float64(Float64(y4 * c) - Float64(y5 * a)))) + Float64(Float64(Float64(k * y2) - Float64(j * y3)) * Float64(Float64(y4 * y1) - Float64(y5 * y0))))
end
function tmp = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	tmp = (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - (((x * j) - (z * k)) * ((y0 * b) - (y1 * i)))) + (((x * y2) - (z * y3)) * ((y0 * c) - (y1 * a)))) + (((t * j) - (y * k)) * ((y4 * b) - (y5 * i)))) - (((t * y2) - (y * y3)) * ((y4 * c) - (y5 * a)))) + (((k * y2) - (j * y3)) * ((y4 * y1) - (y5 * y0)));
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := N[(N[(N[(N[(N[(N[(N[(N[(x * y), $MachinePrecision] - N[(z * t), $MachinePrecision]), $MachinePrecision] * N[(N[(a * b), $MachinePrecision] - N[(c * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(N[(x * j), $MachinePrecision] - N[(z * k), $MachinePrecision]), $MachinePrecision] * N[(N[(y0 * b), $MachinePrecision] - N[(y1 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(x * y2), $MachinePrecision] - N[(z * y3), $MachinePrecision]), $MachinePrecision] * N[(N[(y0 * c), $MachinePrecision] - N[(y1 * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(t * j), $MachinePrecision] - N[(y * k), $MachinePrecision]), $MachinePrecision] * N[(N[(y4 * b), $MachinePrecision] - N[(y5 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision] * N[(N[(y4 * c), $MachinePrecision] - N[(y5 * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(k * y2), $MachinePrecision] - N[(j * y3), $MachinePrecision]), $MachinePrecision] * N[(N[(y4 * y1), $MachinePrecision] - N[(y5 * y0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right)
\end{array}

Alternative 1: 43.5% accurate, 2.1× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := k \cdot y2 - j \cdot y3\\ t_2 := t \cdot y2 - y \cdot y3\\ t_3 := c \cdot y0 - a \cdot y1\\ t_4 := j \cdot t - k \cdot y\\ t_5 := a \cdot b - c \cdot i\\ t_6 := b \cdot y0 - i \cdot y1\\ t_7 := x \cdot \left(\mathsf{fma}\left(y, t\_5, y2 \cdot t\_3\right) - j \cdot t\_6\right)\\ \mathbf{if}\;x \leq -3.6 \cdot 10^{+101}:\\ \;\;\;\;t\_7\\ \mathbf{elif}\;x \leq -3.8 \cdot 10^{-26}:\\ \;\;\;\;-1 \cdot \left(z \cdot \left(\mathsf{fma}\left(t, t\_5, y3 \cdot t\_3\right) - k \cdot t\_6\right)\right)\\ \mathbf{elif}\;x \leq -4 \cdot 10^{-264}:\\ \;\;\;\;-1 \cdot \left(y5 \cdot \left(\mathsf{fma}\left(i, t\_4, y0 \cdot t\_1\right) - a \cdot t\_2\right)\right)\\ \mathbf{elif}\;x \leq 2.8 \cdot 10^{+22}:\\ \;\;\;\;y4 \cdot \left(\mathsf{fma}\left(b, t\_4, y1 \cdot t\_1\right) - c \cdot t\_2\right)\\ \mathbf{elif}\;x \leq 2.4 \cdot 10^{+150}:\\ \;\;\;\;t\_7\\ \mathbf{else}:\\ \;\;\;\;-1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (let* ((t_1 (- (* k y2) (* j y3)))
        (t_2 (- (* t y2) (* y y3)))
        (t_3 (- (* c y0) (* a y1)))
        (t_4 (- (* j t) (* k y)))
        (t_5 (- (* a b) (* c i)))
        (t_6 (- (* b y0) (* i y1)))
        (t_7 (* x (- (fma y t_5 (* y2 t_3)) (* j t_6)))))
   (if (<= x -3.6e+101)
     t_7
     (if (<= x -3.8e-26)
       (* -1.0 (* z (- (fma t t_5 (* y3 t_3)) (* k t_6))))
       (if (<= x -4e-264)
         (* -1.0 (* y5 (- (fma i t_4 (* y0 t_1)) (* a t_2))))
         (if (<= x 2.8e+22)
           (* y4 (- (fma b t_4 (* y1 t_1)) (* c t_2)))
           (if (<= x 2.4e+150)
             t_7
             (* -1.0 (* i (* x (- (* c y) (* j y1))))))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = (k * y2) - (j * y3);
	double t_2 = (t * y2) - (y * y3);
	double t_3 = (c * y0) - (a * y1);
	double t_4 = (j * t) - (k * y);
	double t_5 = (a * b) - (c * i);
	double t_6 = (b * y0) - (i * y1);
	double t_7 = x * (fma(y, t_5, (y2 * t_3)) - (j * t_6));
	double tmp;
	if (x <= -3.6e+101) {
		tmp = t_7;
	} else if (x <= -3.8e-26) {
		tmp = -1.0 * (z * (fma(t, t_5, (y3 * t_3)) - (k * t_6)));
	} else if (x <= -4e-264) {
		tmp = -1.0 * (y5 * (fma(i, t_4, (y0 * t_1)) - (a * t_2)));
	} else if (x <= 2.8e+22) {
		tmp = y4 * (fma(b, t_4, (y1 * t_1)) - (c * t_2));
	} else if (x <= 2.4e+150) {
		tmp = t_7;
	} else {
		tmp = -1.0 * (i * (x * ((c * y) - (j * y1))));
	}
	return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = Float64(Float64(k * y2) - Float64(j * y3))
	t_2 = Float64(Float64(t * y2) - Float64(y * y3))
	t_3 = Float64(Float64(c * y0) - Float64(a * y1))
	t_4 = Float64(Float64(j * t) - Float64(k * y))
	t_5 = Float64(Float64(a * b) - Float64(c * i))
	t_6 = Float64(Float64(b * y0) - Float64(i * y1))
	t_7 = Float64(x * Float64(fma(y, t_5, Float64(y2 * t_3)) - Float64(j * t_6)))
	tmp = 0.0
	if (x <= -3.6e+101)
		tmp = t_7;
	elseif (x <= -3.8e-26)
		tmp = Float64(-1.0 * Float64(z * Float64(fma(t, t_5, Float64(y3 * t_3)) - Float64(k * t_6))));
	elseif (x <= -4e-264)
		tmp = Float64(-1.0 * Float64(y5 * Float64(fma(i, t_4, Float64(y0 * t_1)) - Float64(a * t_2))));
	elseif (x <= 2.8e+22)
		tmp = Float64(y4 * Float64(fma(b, t_4, Float64(y1 * t_1)) - Float64(c * t_2)));
	elseif (x <= 2.4e+150)
		tmp = t_7;
	else
		tmp = Float64(-1.0 * Float64(i * Float64(x * Float64(Float64(c * y) - Float64(j * y1)))));
	end
	return tmp
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(N[(k * y2), $MachinePrecision] - N[(j * y3), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(c * y0), $MachinePrecision] - N[(a * y1), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(N[(j * t), $MachinePrecision] - N[(k * y), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$5 = N[(N[(a * b), $MachinePrecision] - N[(c * i), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$6 = N[(N[(b * y0), $MachinePrecision] - N[(i * y1), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$7 = N[(x * N[(N[(y * t$95$5 + N[(y2 * t$95$3), $MachinePrecision]), $MachinePrecision] - N[(j * t$95$6), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -3.6e+101], t$95$7, If[LessEqual[x, -3.8e-26], N[(-1.0 * N[(z * N[(N[(t * t$95$5 + N[(y3 * t$95$3), $MachinePrecision]), $MachinePrecision] - N[(k * t$95$6), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, -4e-264], N[(-1.0 * N[(y5 * N[(N[(i * t$95$4 + N[(y0 * t$95$1), $MachinePrecision]), $MachinePrecision] - N[(a * t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 2.8e+22], N[(y4 * N[(N[(b * t$95$4 + N[(y1 * t$95$1), $MachinePrecision]), $MachinePrecision] - N[(c * t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 2.4e+150], t$95$7, N[(-1.0 * N[(i * N[(x * N[(N[(c * y), $MachinePrecision] - N[(j * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := k \cdot y2 - j \cdot y3\\
t_2 := t \cdot y2 - y \cdot y3\\
t_3 := c \cdot y0 - a \cdot y1\\
t_4 := j \cdot t - k \cdot y\\
t_5 := a \cdot b - c \cdot i\\
t_6 := b \cdot y0 - i \cdot y1\\
t_7 := x \cdot \left(\mathsf{fma}\left(y, t\_5, y2 \cdot t\_3\right) - j \cdot t\_6\right)\\
\mathbf{if}\;x \leq -3.6 \cdot 10^{+101}:\\
\;\;\;\;t\_7\\

\mathbf{elif}\;x \leq -3.8 \cdot 10^{-26}:\\
\;\;\;\;-1 \cdot \left(z \cdot \left(\mathsf{fma}\left(t, t\_5, y3 \cdot t\_3\right) - k \cdot t\_6\right)\right)\\

\mathbf{elif}\;x \leq -4 \cdot 10^{-264}:\\
\;\;\;\;-1 \cdot \left(y5 \cdot \left(\mathsf{fma}\left(i, t\_4, y0 \cdot t\_1\right) - a \cdot t\_2\right)\right)\\

\mathbf{elif}\;x \leq 2.8 \cdot 10^{+22}:\\
\;\;\;\;y4 \cdot \left(\mathsf{fma}\left(b, t\_4, y1 \cdot t\_1\right) - c \cdot t\_2\right)\\

\mathbf{elif}\;x \leq 2.4 \cdot 10^{+150}:\\
\;\;\;\;t\_7\\

\mathbf{else}:\\
\;\;\;\;-1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if x < -3.60000000000000029e101 or 2.8e22 < x < 2.40000000000000003e150

    1. Initial program 25.0%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in x around inf

      \[\leadsto \color{blue}{x \cdot \left(\left(y \cdot \left(a \cdot b - c \cdot i\right) + y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto x \cdot \color{blue}{\left(\left(y \cdot \left(a \cdot b - c \cdot i\right) + y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto x \cdot \left(\left(y \cdot \left(a \cdot b - c \cdot i\right) + y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{j \cdot \left(b \cdot y0 - i \cdot y1\right)}\right) \]
    4. Applied rewrites49.9%

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

    if -3.60000000000000029e101 < x < -3.80000000000000015e-26

    1. Initial program 30.6%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in z around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(z \cdot \left(\left(t \cdot \left(a \cdot b - c \cdot i\right) + y3 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - k \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(z \cdot \left(\left(t \cdot \left(a \cdot b - c \cdot i\right) + y3 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - k \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(z \cdot \color{blue}{\left(\left(t \cdot \left(a \cdot b - c \cdot i\right) + y3 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - k \cdot \left(b \cdot y0 - i \cdot y1\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(z \cdot \left(\left(t \cdot \left(a \cdot b - c \cdot i\right) + y3 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{k \cdot \left(b \cdot y0 - i \cdot y1\right)}\right)\right) \]
    4. Applied rewrites40.1%

      \[\leadsto \color{blue}{-1 \cdot \left(z \cdot \left(\mathsf{fma}\left(t, a \cdot b - c \cdot i, y3 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - k \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\right)} \]

    if -3.80000000000000015e-26 < x < -4e-264

    1. Initial program 34.5%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y5 around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(y5 \cdot \left(\left(i \cdot \left(j \cdot t - k \cdot y\right) + y0 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - a \cdot \left(t \cdot y2 - y \cdot y3\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(y5 \cdot \left(\left(i \cdot \left(j \cdot t - k \cdot y\right) + y0 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - a \cdot \left(t \cdot y2 - y \cdot y3\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(y5 \cdot \color{blue}{\left(\left(i \cdot \left(j \cdot t - k \cdot y\right) + y0 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - a \cdot \left(t \cdot y2 - y \cdot y3\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(y5 \cdot \left(\left(i \cdot \left(j \cdot t - k \cdot y\right) + y0 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - \color{blue}{a \cdot \left(t \cdot y2 - y \cdot y3\right)}\right)\right) \]
    4. Applied rewrites41.2%

      \[\leadsto \color{blue}{-1 \cdot \left(y5 \cdot \left(\mathsf{fma}\left(i, j \cdot t - k \cdot y, y0 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - a \cdot \left(t \cdot y2 - y \cdot y3\right)\right)\right)} \]

    if -4e-264 < x < 2.8e22

    1. Initial program 35.1%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y4 around inf

      \[\leadsto \color{blue}{y4 \cdot \left(\left(b \cdot \left(j \cdot t - k \cdot y\right) + y1 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - c \cdot \left(t \cdot y2 - y \cdot y3\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto y4 \cdot \color{blue}{\left(\left(b \cdot \left(j \cdot t - k \cdot y\right) + y1 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - c \cdot \left(t \cdot y2 - y \cdot y3\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto y4 \cdot \left(\left(b \cdot \left(j \cdot t - k \cdot y\right) + y1 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - \color{blue}{c \cdot \left(t \cdot y2 - y \cdot y3\right)}\right) \]
    4. Applied rewrites39.5%

      \[\leadsto \color{blue}{y4 \cdot \left(\mathsf{fma}\left(b, j \cdot t - k \cdot y, y1 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - c \cdot \left(t \cdot y2 - y \cdot y3\right)\right)} \]

    if 2.40000000000000003e150 < x

    1. Initial program 24.8%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites36.3%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in x around inf

      \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \color{blue}{\left(c \cdot y - j \cdot y1\right)}\right)\right) \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - \color{blue}{j \cdot y1}\right)\right)\right) \]
      2. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot \color{blue}{y1}\right)\right)\right) \]
      3. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right) \]
      4. lower-*.f6445.4

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right) \]
    7. Applied rewrites45.4%

      \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \color{blue}{\left(c \cdot y - j \cdot y1\right)}\right)\right) \]
  3. Recombined 5 regimes into one program.
  4. Add Preprocessing

Alternative 2: 54.4% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := a \cdot b - c \cdot i\\ t_2 := \left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot t\_1 - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right)\\ \mathbf{if}\;t\_2 \leq \infty:\\ \;\;\;\;t\_2\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(\mathsf{fma}\left(y, t\_1, y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (let* ((t_1 (- (* a b) (* c i)))
        (t_2
         (+
          (-
           (+
            (+
             (-
              (* (- (* x y) (* z t)) t_1)
              (* (- (* x j) (* z k)) (- (* y0 b) (* y1 i))))
             (* (- (* x y2) (* z y3)) (- (* y0 c) (* y1 a))))
            (* (- (* t j) (* y k)) (- (* y4 b) (* y5 i))))
           (* (- (* t y2) (* y y3)) (- (* y4 c) (* y5 a))))
          (* (- (* k y2) (* j y3)) (- (* y4 y1) (* y5 y0))))))
   (if (<= t_2 INFINITY)
     t_2
     (*
      x
      (-
       (fma y t_1 (* y2 (- (* c y0) (* a y1))))
       (* j (- (* b y0) (* i y1))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = (a * b) - (c * i);
	double t_2 = (((((((x * y) - (z * t)) * t_1) - (((x * j) - (z * k)) * ((y0 * b) - (y1 * i)))) + (((x * y2) - (z * y3)) * ((y0 * c) - (y1 * a)))) + (((t * j) - (y * k)) * ((y4 * b) - (y5 * i)))) - (((t * y2) - (y * y3)) * ((y4 * c) - (y5 * a)))) + (((k * y2) - (j * y3)) * ((y4 * y1) - (y5 * y0)));
	double tmp;
	if (t_2 <= ((double) INFINITY)) {
		tmp = t_2;
	} else {
		tmp = x * (fma(y, t_1, (y2 * ((c * y0) - (a * y1)))) - (j * ((b * y0) - (i * y1))));
	}
	return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = Float64(Float64(a * b) - Float64(c * i))
	t_2 = Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * y) - Float64(z * t)) * t_1) - Float64(Float64(Float64(x * j) - Float64(z * k)) * Float64(Float64(y0 * b) - Float64(y1 * i)))) + Float64(Float64(Float64(x * y2) - Float64(z * y3)) * Float64(Float64(y0 * c) - Float64(y1 * a)))) + Float64(Float64(Float64(t * j) - Float64(y * k)) * Float64(Float64(y4 * b) - Float64(y5 * i)))) - Float64(Float64(Float64(t * y2) - Float64(y * y3)) * Float64(Float64(y4 * c) - Float64(y5 * a)))) + Float64(Float64(Float64(k * y2) - Float64(j * y3)) * Float64(Float64(y4 * y1) - Float64(y5 * y0))))
	tmp = 0.0
	if (t_2 <= Inf)
		tmp = t_2;
	else
		tmp = Float64(x * Float64(fma(y, t_1, Float64(y2 * Float64(Float64(c * y0) - Float64(a * y1)))) - Float64(j * Float64(Float64(b * y0) - Float64(i * y1)))));
	end
	return tmp
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(N[(a * b), $MachinePrecision] - N[(c * i), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(N[(N[(N[(N[(N[(x * y), $MachinePrecision] - N[(z * t), $MachinePrecision]), $MachinePrecision] * t$95$1), $MachinePrecision] - N[(N[(N[(x * j), $MachinePrecision] - N[(z * k), $MachinePrecision]), $MachinePrecision] * N[(N[(y0 * b), $MachinePrecision] - N[(y1 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(x * y2), $MachinePrecision] - N[(z * y3), $MachinePrecision]), $MachinePrecision] * N[(N[(y0 * c), $MachinePrecision] - N[(y1 * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(t * j), $MachinePrecision] - N[(y * k), $MachinePrecision]), $MachinePrecision] * N[(N[(y4 * b), $MachinePrecision] - N[(y5 * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision] * N[(N[(y4 * c), $MachinePrecision] - N[(y5 * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(k * y2), $MachinePrecision] - N[(j * y3), $MachinePrecision]), $MachinePrecision] * N[(N[(y4 * y1), $MachinePrecision] - N[(y5 * y0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, Infinity], t$95$2, N[(x * N[(N[(y * t$95$1 + N[(y2 * N[(N[(c * y0), $MachinePrecision] - N[(a * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(j * N[(N[(b * y0), $MachinePrecision] - N[(i * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := a \cdot b - c \cdot i\\
t_2 := \left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot t\_1 - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right)\\
\mathbf{if}\;t\_2 \leq \infty:\\
\;\;\;\;t\_2\\

\mathbf{else}:\\
\;\;\;\;x \cdot \left(\mathsf{fma}\left(y, t\_1, y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (+.f64 (-.f64 (+.f64 (+.f64 (-.f64 (*.f64 (-.f64 (*.f64 x y) (*.f64 z t)) (-.f64 (*.f64 a b) (*.f64 c i))) (*.f64 (-.f64 (*.f64 x j) (*.f64 z k)) (-.f64 (*.f64 y0 b) (*.f64 y1 i)))) (*.f64 (-.f64 (*.f64 x y2) (*.f64 z y3)) (-.f64 (*.f64 y0 c) (*.f64 y1 a)))) (*.f64 (-.f64 (*.f64 t j) (*.f64 y k)) (-.f64 (*.f64 y4 b) (*.f64 y5 i)))) (*.f64 (-.f64 (*.f64 t y2) (*.f64 y y3)) (-.f64 (*.f64 y4 c) (*.f64 y5 a)))) (*.f64 (-.f64 (*.f64 k y2) (*.f64 j y3)) (-.f64 (*.f64 y4 y1) (*.f64 y5 y0)))) < +inf.0

    1. Initial program 92.4%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]

    if +inf.0 < (+.f64 (-.f64 (+.f64 (+.f64 (-.f64 (*.f64 (-.f64 (*.f64 x y) (*.f64 z t)) (-.f64 (*.f64 a b) (*.f64 c i))) (*.f64 (-.f64 (*.f64 x j) (*.f64 z k)) (-.f64 (*.f64 y0 b) (*.f64 y1 i)))) (*.f64 (-.f64 (*.f64 x y2) (*.f64 z y3)) (-.f64 (*.f64 y0 c) (*.f64 y1 a)))) (*.f64 (-.f64 (*.f64 t j) (*.f64 y k)) (-.f64 (*.f64 y4 b) (*.f64 y5 i)))) (*.f64 (-.f64 (*.f64 t y2) (*.f64 y y3)) (-.f64 (*.f64 y4 c) (*.f64 y5 a)))) (*.f64 (-.f64 (*.f64 k y2) (*.f64 j y3)) (-.f64 (*.f64 y4 y1) (*.f64 y5 y0))))

    1. Initial program 0.0%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in x around inf

      \[\leadsto \color{blue}{x \cdot \left(\left(y \cdot \left(a \cdot b - c \cdot i\right) + y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto x \cdot \color{blue}{\left(\left(y \cdot \left(a \cdot b - c \cdot i\right) + y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto x \cdot \left(\left(y \cdot \left(a \cdot b - c \cdot i\right) + y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{j \cdot \left(b \cdot y0 - i \cdot y1\right)}\right) \]
    4. Applied rewrites35.8%

      \[\leadsto \color{blue}{x \cdot \left(\mathsf{fma}\left(y, a \cdot b - c \cdot i, y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)} \]
  3. Recombined 2 regimes into one program.
  4. Add Preprocessing

Alternative 3: 42.7% accurate, 2.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := k \cdot y2 - j \cdot y3\\ t_2 := x \cdot \left(\mathsf{fma}\left(y, a \cdot b - c \cdot i, y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\\ t_3 := t \cdot y2 - y \cdot y3\\ \mathbf{if}\;x \leq -1.55 \cdot 10^{+165}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;x \leq -1.45 \cdot 10^{-248}:\\ \;\;\;\;\left(-1 \cdot \left(y1 \cdot \left(i \cdot \left(k \cdot z\right)\right)\right) - t\_3 \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + t\_1 \cdot \left(y4 \cdot y1 - y5 \cdot y0\right)\\ \mathbf{elif}\;x \leq 2.8 \cdot 10^{+22}:\\ \;\;\;\;y4 \cdot \left(\mathsf{fma}\left(b, j \cdot t - k \cdot y, y1 \cdot t\_1\right) - c \cdot t\_3\right)\\ \mathbf{elif}\;x \leq 2.4 \cdot 10^{+150}:\\ \;\;\;\;t\_2\\ \mathbf{else}:\\ \;\;\;\;-1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (let* ((t_1 (- (* k y2) (* j y3)))
        (t_2
         (*
          x
          (-
           (fma y (- (* a b) (* c i)) (* y2 (- (* c y0) (* a y1))))
           (* j (- (* b y0) (* i y1))))))
        (t_3 (- (* t y2) (* y y3))))
   (if (<= x -1.55e+165)
     t_2
     (if (<= x -1.45e-248)
       (+
        (- (* -1.0 (* y1 (* i (* k z)))) (* t_3 (- (* y4 c) (* y5 a))))
        (* t_1 (- (* y4 y1) (* y5 y0))))
       (if (<= x 2.8e+22)
         (* y4 (- (fma b (- (* j t) (* k y)) (* y1 t_1)) (* c t_3)))
         (if (<= x 2.4e+150)
           t_2
           (* -1.0 (* i (* x (- (* c y) (* j y1)))))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = (k * y2) - (j * y3);
	double t_2 = x * (fma(y, ((a * b) - (c * i)), (y2 * ((c * y0) - (a * y1)))) - (j * ((b * y0) - (i * y1))));
	double t_3 = (t * y2) - (y * y3);
	double tmp;
	if (x <= -1.55e+165) {
		tmp = t_2;
	} else if (x <= -1.45e-248) {
		tmp = ((-1.0 * (y1 * (i * (k * z)))) - (t_3 * ((y4 * c) - (y5 * a)))) + (t_1 * ((y4 * y1) - (y5 * y0)));
	} else if (x <= 2.8e+22) {
		tmp = y4 * (fma(b, ((j * t) - (k * y)), (y1 * t_1)) - (c * t_3));
	} else if (x <= 2.4e+150) {
		tmp = t_2;
	} else {
		tmp = -1.0 * (i * (x * ((c * y) - (j * y1))));
	}
	return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = Float64(Float64(k * y2) - Float64(j * y3))
	t_2 = Float64(x * Float64(fma(y, Float64(Float64(a * b) - Float64(c * i)), Float64(y2 * Float64(Float64(c * y0) - Float64(a * y1)))) - Float64(j * Float64(Float64(b * y0) - Float64(i * y1)))))
	t_3 = Float64(Float64(t * y2) - Float64(y * y3))
	tmp = 0.0
	if (x <= -1.55e+165)
		tmp = t_2;
	elseif (x <= -1.45e-248)
		tmp = Float64(Float64(Float64(-1.0 * Float64(y1 * Float64(i * Float64(k * z)))) - Float64(t_3 * Float64(Float64(y4 * c) - Float64(y5 * a)))) + Float64(t_1 * Float64(Float64(y4 * y1) - Float64(y5 * y0))));
	elseif (x <= 2.8e+22)
		tmp = Float64(y4 * Float64(fma(b, Float64(Float64(j * t) - Float64(k * y)), Float64(y1 * t_1)) - Float64(c * t_3)));
	elseif (x <= 2.4e+150)
		tmp = t_2;
	else
		tmp = Float64(-1.0 * Float64(i * Float64(x * Float64(Float64(c * y) - Float64(j * y1)))));
	end
	return tmp
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(N[(k * y2), $MachinePrecision] - N[(j * y3), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x * N[(N[(y * N[(N[(a * b), $MachinePrecision] - N[(c * i), $MachinePrecision]), $MachinePrecision] + N[(y2 * N[(N[(c * y0), $MachinePrecision] - N[(a * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(j * N[(N[(b * y0), $MachinePrecision] - N[(i * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -1.55e+165], t$95$2, If[LessEqual[x, -1.45e-248], N[(N[(N[(-1.0 * N[(y1 * N[(i * N[(k * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(t$95$3 * N[(N[(y4 * c), $MachinePrecision] - N[(y5 * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(t$95$1 * N[(N[(y4 * y1), $MachinePrecision] - N[(y5 * y0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 2.8e+22], N[(y4 * N[(N[(b * N[(N[(j * t), $MachinePrecision] - N[(k * y), $MachinePrecision]), $MachinePrecision] + N[(y1 * t$95$1), $MachinePrecision]), $MachinePrecision] - N[(c * t$95$3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 2.4e+150], t$95$2, N[(-1.0 * N[(i * N[(x * N[(N[(c * y), $MachinePrecision] - N[(j * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := k \cdot y2 - j \cdot y3\\
t_2 := x \cdot \left(\mathsf{fma}\left(y, a \cdot b - c \cdot i, y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\\
t_3 := t \cdot y2 - y \cdot y3\\
\mathbf{if}\;x \leq -1.55 \cdot 10^{+165}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;x \leq -1.45 \cdot 10^{-248}:\\
\;\;\;\;\left(-1 \cdot \left(y1 \cdot \left(i \cdot \left(k \cdot z\right)\right)\right) - t\_3 \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + t\_1 \cdot \left(y4 \cdot y1 - y5 \cdot y0\right)\\

\mathbf{elif}\;x \leq 2.8 \cdot 10^{+22}:\\
\;\;\;\;y4 \cdot \left(\mathsf{fma}\left(b, j \cdot t - k \cdot y, y1 \cdot t\_1\right) - c \cdot t\_3\right)\\

\mathbf{elif}\;x \leq 2.4 \cdot 10^{+150}:\\
\;\;\;\;t\_2\\

\mathbf{else}:\\
\;\;\;\;-1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if x < -1.5500000000000001e165 or 2.8e22 < x < 2.40000000000000003e150

    1. Initial program 25.5%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in x around inf

      \[\leadsto \color{blue}{x \cdot \left(\left(y \cdot \left(a \cdot b - c \cdot i\right) + y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto x \cdot \color{blue}{\left(\left(y \cdot \left(a \cdot b - c \cdot i\right) + y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto x \cdot \left(\left(y \cdot \left(a \cdot b - c \cdot i\right) + y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{j \cdot \left(b \cdot y0 - i \cdot y1\right)}\right) \]
    4. Applied rewrites49.8%

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

    if -1.5500000000000001e165 < x < -1.4500000000000001e-248

    1. Initial program 31.4%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y1 around -inf

      \[\leadsto \left(\color{blue}{-1 \cdot \left(y1 \cdot \left(a \cdot \left(x \cdot y2 - y3 \cdot z\right) - i \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto \left(-1 \cdot \color{blue}{\left(y1 \cdot \left(a \cdot \left(x \cdot y2 - y3 \cdot z\right) - i \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
      2. lower-*.f64N/A

        \[\leadsto \left(-1 \cdot \left(y1 \cdot \color{blue}{\left(a \cdot \left(x \cdot y2 - y3 \cdot z\right) - i \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
      3. lower--.f64N/A

        \[\leadsto \left(-1 \cdot \left(y1 \cdot \left(a \cdot \left(x \cdot y2 - y3 \cdot z\right) - \color{blue}{i \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
      4. lower-*.f64N/A

        \[\leadsto \left(-1 \cdot \left(y1 \cdot \left(a \cdot \left(x \cdot y2 - y3 \cdot z\right) - \color{blue}{i} \cdot \left(j \cdot x - k \cdot z\right)\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
      5. lower--.f64N/A

        \[\leadsto \left(-1 \cdot \left(y1 \cdot \left(a \cdot \left(x \cdot y2 - y3 \cdot z\right) - i \cdot \left(j \cdot x - k \cdot z\right)\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
      6. lift-*.f64N/A

        \[\leadsto \left(-1 \cdot \left(y1 \cdot \left(a \cdot \left(x \cdot y2 - y3 \cdot z\right) - i \cdot \left(j \cdot x - k \cdot z\right)\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
      7. lower-*.f64N/A

        \[\leadsto \left(-1 \cdot \left(y1 \cdot \left(a \cdot \left(x \cdot y2 - y3 \cdot z\right) - i \cdot \left(j \cdot x - k \cdot z\right)\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
      8. lower-*.f64N/A

        \[\leadsto \left(-1 \cdot \left(y1 \cdot \left(a \cdot \left(x \cdot y2 - y3 \cdot z\right) - i \cdot \color{blue}{\left(j \cdot x - k \cdot z\right)}\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
      9. lower--.f64N/A

        \[\leadsto \left(-1 \cdot \left(y1 \cdot \left(a \cdot \left(x \cdot y2 - y3 \cdot z\right) - i \cdot \left(j \cdot x - \color{blue}{k \cdot z}\right)\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
      10. lower-*.f64N/A

        \[\leadsto \left(-1 \cdot \left(y1 \cdot \left(a \cdot \left(x \cdot y2 - y3 \cdot z\right) - i \cdot \left(j \cdot x - \color{blue}{k} \cdot z\right)\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
      11. lower-*.f6436.3

        \[\leadsto \left(-1 \cdot \left(y1 \cdot \left(a \cdot \left(x \cdot y2 - y3 \cdot z\right) - i \cdot \left(j \cdot x - k \cdot \color{blue}{z}\right)\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    4. Applied rewrites36.3%

      \[\leadsto \left(\color{blue}{-1 \cdot \left(y1 \cdot \left(a \cdot \left(x \cdot y2 - y3 \cdot z\right) - i \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    5. Taylor expanded in k around inf

      \[\leadsto \left(-1 \cdot \left(y1 \cdot \left(i \cdot \color{blue}{\left(k \cdot z\right)}\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto \left(-1 \cdot \left(y1 \cdot \left(i \cdot \left(k \cdot \color{blue}{z}\right)\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
      2. lift-*.f6439.7

        \[\leadsto \left(-1 \cdot \left(y1 \cdot \left(i \cdot \left(k \cdot z\right)\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    7. Applied rewrites39.7%

      \[\leadsto \left(-1 \cdot \left(y1 \cdot \left(i \cdot \color{blue}{\left(k \cdot z\right)}\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]

    if -1.4500000000000001e-248 < x < 2.8e22

    1. Initial program 35.1%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y4 around inf

      \[\leadsto \color{blue}{y4 \cdot \left(\left(b \cdot \left(j \cdot t - k \cdot y\right) + y1 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - c \cdot \left(t \cdot y2 - y \cdot y3\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto y4 \cdot \color{blue}{\left(\left(b \cdot \left(j \cdot t - k \cdot y\right) + y1 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - c \cdot \left(t \cdot y2 - y \cdot y3\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto y4 \cdot \left(\left(b \cdot \left(j \cdot t - k \cdot y\right) + y1 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - \color{blue}{c \cdot \left(t \cdot y2 - y \cdot y3\right)}\right) \]
    4. Applied rewrites39.5%

      \[\leadsto \color{blue}{y4 \cdot \left(\mathsf{fma}\left(b, j \cdot t - k \cdot y, y1 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - c \cdot \left(t \cdot y2 - y \cdot y3\right)\right)} \]

    if 2.40000000000000003e150 < x

    1. Initial program 24.8%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites36.3%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in x around inf

      \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \color{blue}{\left(c \cdot y - j \cdot y1\right)}\right)\right) \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - \color{blue}{j \cdot y1}\right)\right)\right) \]
      2. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot \color{blue}{y1}\right)\right)\right) \]
      3. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right) \]
      4. lower-*.f6445.4

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right) \]
    7. Applied rewrites45.4%

      \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \color{blue}{\left(c \cdot y - j \cdot y1\right)}\right)\right) \]
  3. Recombined 4 regimes into one program.
  4. Add Preprocessing

Alternative 4: 43.4% accurate, 2.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := k \cdot y2 - j \cdot y3\\ t_2 := t \cdot y2 - y \cdot y3\\ t_3 := x \cdot \left(\mathsf{fma}\left(y, a \cdot b - c \cdot i, y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\\ t_4 := j \cdot t - k \cdot y\\ \mathbf{if}\;x \leq -2.8 \cdot 10^{+102}:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;x \leq -4 \cdot 10^{-264}:\\ \;\;\;\;-1 \cdot \left(y5 \cdot \left(\mathsf{fma}\left(i, t\_4, y0 \cdot t\_1\right) - a \cdot t\_2\right)\right)\\ \mathbf{elif}\;x \leq 2.8 \cdot 10^{+22}:\\ \;\;\;\;y4 \cdot \left(\mathsf{fma}\left(b, t\_4, y1 \cdot t\_1\right) - c \cdot t\_2\right)\\ \mathbf{elif}\;x \leq 2.4 \cdot 10^{+150}:\\ \;\;\;\;t\_3\\ \mathbf{else}:\\ \;\;\;\;-1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (let* ((t_1 (- (* k y2) (* j y3)))
        (t_2 (- (* t y2) (* y y3)))
        (t_3
         (*
          x
          (-
           (fma y (- (* a b) (* c i)) (* y2 (- (* c y0) (* a y1))))
           (* j (- (* b y0) (* i y1))))))
        (t_4 (- (* j t) (* k y))))
   (if (<= x -2.8e+102)
     t_3
     (if (<= x -4e-264)
       (* -1.0 (* y5 (- (fma i t_4 (* y0 t_1)) (* a t_2))))
       (if (<= x 2.8e+22)
         (* y4 (- (fma b t_4 (* y1 t_1)) (* c t_2)))
         (if (<= x 2.4e+150)
           t_3
           (* -1.0 (* i (* x (- (* c y) (* j y1)))))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = (k * y2) - (j * y3);
	double t_2 = (t * y2) - (y * y3);
	double t_3 = x * (fma(y, ((a * b) - (c * i)), (y2 * ((c * y0) - (a * y1)))) - (j * ((b * y0) - (i * y1))));
	double t_4 = (j * t) - (k * y);
	double tmp;
	if (x <= -2.8e+102) {
		tmp = t_3;
	} else if (x <= -4e-264) {
		tmp = -1.0 * (y5 * (fma(i, t_4, (y0 * t_1)) - (a * t_2)));
	} else if (x <= 2.8e+22) {
		tmp = y4 * (fma(b, t_4, (y1 * t_1)) - (c * t_2));
	} else if (x <= 2.4e+150) {
		tmp = t_3;
	} else {
		tmp = -1.0 * (i * (x * ((c * y) - (j * y1))));
	}
	return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = Float64(Float64(k * y2) - Float64(j * y3))
	t_2 = Float64(Float64(t * y2) - Float64(y * y3))
	t_3 = Float64(x * Float64(fma(y, Float64(Float64(a * b) - Float64(c * i)), Float64(y2 * Float64(Float64(c * y0) - Float64(a * y1)))) - Float64(j * Float64(Float64(b * y0) - Float64(i * y1)))))
	t_4 = Float64(Float64(j * t) - Float64(k * y))
	tmp = 0.0
	if (x <= -2.8e+102)
		tmp = t_3;
	elseif (x <= -4e-264)
		tmp = Float64(-1.0 * Float64(y5 * Float64(fma(i, t_4, Float64(y0 * t_1)) - Float64(a * t_2))));
	elseif (x <= 2.8e+22)
		tmp = Float64(y4 * Float64(fma(b, t_4, Float64(y1 * t_1)) - Float64(c * t_2)));
	elseif (x <= 2.4e+150)
		tmp = t_3;
	else
		tmp = Float64(-1.0 * Float64(i * Float64(x * Float64(Float64(c * y) - Float64(j * y1)))));
	end
	return tmp
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(N[(k * y2), $MachinePrecision] - N[(j * y3), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(x * N[(N[(y * N[(N[(a * b), $MachinePrecision] - N[(c * i), $MachinePrecision]), $MachinePrecision] + N[(y2 * N[(N[(c * y0), $MachinePrecision] - N[(a * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(j * N[(N[(b * y0), $MachinePrecision] - N[(i * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(N[(j * t), $MachinePrecision] - N[(k * y), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -2.8e+102], t$95$3, If[LessEqual[x, -4e-264], N[(-1.0 * N[(y5 * N[(N[(i * t$95$4 + N[(y0 * t$95$1), $MachinePrecision]), $MachinePrecision] - N[(a * t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 2.8e+22], N[(y4 * N[(N[(b * t$95$4 + N[(y1 * t$95$1), $MachinePrecision]), $MachinePrecision] - N[(c * t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 2.4e+150], t$95$3, N[(-1.0 * N[(i * N[(x * N[(N[(c * y), $MachinePrecision] - N[(j * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := k \cdot y2 - j \cdot y3\\
t_2 := t \cdot y2 - y \cdot y3\\
t_3 := x \cdot \left(\mathsf{fma}\left(y, a \cdot b - c \cdot i, y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\\
t_4 := j \cdot t - k \cdot y\\
\mathbf{if}\;x \leq -2.8 \cdot 10^{+102}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;x \leq -4 \cdot 10^{-264}:\\
\;\;\;\;-1 \cdot \left(y5 \cdot \left(\mathsf{fma}\left(i, t\_4, y0 \cdot t\_1\right) - a \cdot t\_2\right)\right)\\

\mathbf{elif}\;x \leq 2.8 \cdot 10^{+22}:\\
\;\;\;\;y4 \cdot \left(\mathsf{fma}\left(b, t\_4, y1 \cdot t\_1\right) - c \cdot t\_2\right)\\

\mathbf{elif}\;x \leq 2.4 \cdot 10^{+150}:\\
\;\;\;\;t\_3\\

\mathbf{else}:\\
\;\;\;\;-1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if x < -2.80000000000000018e102 or 2.8e22 < x < 2.40000000000000003e150

    1. Initial program 25.0%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in x around inf

      \[\leadsto \color{blue}{x \cdot \left(\left(y \cdot \left(a \cdot b - c \cdot i\right) + y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto x \cdot \color{blue}{\left(\left(y \cdot \left(a \cdot b - c \cdot i\right) + y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto x \cdot \left(\left(y \cdot \left(a \cdot b - c \cdot i\right) + y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{j \cdot \left(b \cdot y0 - i \cdot y1\right)}\right) \]
    4. Applied rewrites49.8%

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

    if -2.80000000000000018e102 < x < -4e-264

    1. Initial program 33.1%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y5 around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(y5 \cdot \left(\left(i \cdot \left(j \cdot t - k \cdot y\right) + y0 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - a \cdot \left(t \cdot y2 - y \cdot y3\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(y5 \cdot \left(\left(i \cdot \left(j \cdot t - k \cdot y\right) + y0 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - a \cdot \left(t \cdot y2 - y \cdot y3\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(y5 \cdot \color{blue}{\left(\left(i \cdot \left(j \cdot t - k \cdot y\right) + y0 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - a \cdot \left(t \cdot y2 - y \cdot y3\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(y5 \cdot \left(\left(i \cdot \left(j \cdot t - k \cdot y\right) + y0 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - \color{blue}{a \cdot \left(t \cdot y2 - y \cdot y3\right)}\right)\right) \]
    4. Applied rewrites40.5%

      \[\leadsto \color{blue}{-1 \cdot \left(y5 \cdot \left(\mathsf{fma}\left(i, j \cdot t - k \cdot y, y0 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - a \cdot \left(t \cdot y2 - y \cdot y3\right)\right)\right)} \]

    if -4e-264 < x < 2.8e22

    1. Initial program 35.1%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y4 around inf

      \[\leadsto \color{blue}{y4 \cdot \left(\left(b \cdot \left(j \cdot t - k \cdot y\right) + y1 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - c \cdot \left(t \cdot y2 - y \cdot y3\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto y4 \cdot \color{blue}{\left(\left(b \cdot \left(j \cdot t - k \cdot y\right) + y1 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - c \cdot \left(t \cdot y2 - y \cdot y3\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto y4 \cdot \left(\left(b \cdot \left(j \cdot t - k \cdot y\right) + y1 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - \color{blue}{c \cdot \left(t \cdot y2 - y \cdot y3\right)}\right) \]
    4. Applied rewrites39.5%

      \[\leadsto \color{blue}{y4 \cdot \left(\mathsf{fma}\left(b, j \cdot t - k \cdot y, y1 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - c \cdot \left(t \cdot y2 - y \cdot y3\right)\right)} \]

    if 2.40000000000000003e150 < x

    1. Initial program 24.8%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites36.3%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in x around inf

      \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \color{blue}{\left(c \cdot y - j \cdot y1\right)}\right)\right) \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - \color{blue}{j \cdot y1}\right)\right)\right) \]
      2. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot \color{blue}{y1}\right)\right)\right) \]
      3. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right) \]
      4. lower-*.f6445.4

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right) \]
    7. Applied rewrites45.4%

      \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \color{blue}{\left(c \cdot y - j \cdot y1\right)}\right)\right) \]
  3. Recombined 4 regimes into one program.
  4. Add Preprocessing

Alternative 5: 42.7% accurate, 2.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := c \cdot y0 - a \cdot y1\\ t_2 := x \cdot \left(\mathsf{fma}\left(y, a \cdot b - c \cdot i, y2 \cdot t\_1\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\\ \mathbf{if}\;x \leq -3.1 \cdot 10^{+118}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;x \leq -1.55 \cdot 10^{-256}:\\ \;\;\;\;-1 \cdot \left(y3 \cdot \left(\mathsf{fma}\left(j, y1 \cdot y4 - y0 \cdot y5, z \cdot t\_1\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)\\ \mathbf{elif}\;x \leq 2.8 \cdot 10^{+22}:\\ \;\;\;\;y4 \cdot \left(\mathsf{fma}\left(b, j \cdot t - k \cdot y, y1 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - c \cdot \left(t \cdot y2 - y \cdot y3\right)\right)\\ \mathbf{elif}\;x \leq 2.4 \cdot 10^{+150}:\\ \;\;\;\;t\_2\\ \mathbf{else}:\\ \;\;\;\;-1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (let* ((t_1 (- (* c y0) (* a y1)))
        (t_2
         (*
          x
          (-
           (fma y (- (* a b) (* c i)) (* y2 t_1))
           (* j (- (* b y0) (* i y1)))))))
   (if (<= x -3.1e+118)
     t_2
     (if (<= x -1.55e-256)
       (*
        -1.0
        (*
         y3
         (-
          (fma j (- (* y1 y4) (* y0 y5)) (* z t_1))
          (* y (- (* c y4) (* a y5))))))
       (if (<= x 2.8e+22)
         (*
          y4
          (-
           (fma b (- (* j t) (* k y)) (* y1 (- (* k y2) (* j y3))))
           (* c (- (* t y2) (* y y3)))))
         (if (<= x 2.4e+150)
           t_2
           (* -1.0 (* i (* x (- (* c y) (* j y1)))))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = (c * y0) - (a * y1);
	double t_2 = x * (fma(y, ((a * b) - (c * i)), (y2 * t_1)) - (j * ((b * y0) - (i * y1))));
	double tmp;
	if (x <= -3.1e+118) {
		tmp = t_2;
	} else if (x <= -1.55e-256) {
		tmp = -1.0 * (y3 * (fma(j, ((y1 * y4) - (y0 * y5)), (z * t_1)) - (y * ((c * y4) - (a * y5)))));
	} else if (x <= 2.8e+22) {
		tmp = y4 * (fma(b, ((j * t) - (k * y)), (y1 * ((k * y2) - (j * y3)))) - (c * ((t * y2) - (y * y3))));
	} else if (x <= 2.4e+150) {
		tmp = t_2;
	} else {
		tmp = -1.0 * (i * (x * ((c * y) - (j * y1))));
	}
	return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = Float64(Float64(c * y0) - Float64(a * y1))
	t_2 = Float64(x * Float64(fma(y, Float64(Float64(a * b) - Float64(c * i)), Float64(y2 * t_1)) - Float64(j * Float64(Float64(b * y0) - Float64(i * y1)))))
	tmp = 0.0
	if (x <= -3.1e+118)
		tmp = t_2;
	elseif (x <= -1.55e-256)
		tmp = Float64(-1.0 * Float64(y3 * Float64(fma(j, Float64(Float64(y1 * y4) - Float64(y0 * y5)), Float64(z * t_1)) - Float64(y * Float64(Float64(c * y4) - Float64(a * y5))))));
	elseif (x <= 2.8e+22)
		tmp = Float64(y4 * Float64(fma(b, Float64(Float64(j * t) - Float64(k * y)), Float64(y1 * Float64(Float64(k * y2) - Float64(j * y3)))) - Float64(c * Float64(Float64(t * y2) - Float64(y * y3)))));
	elseif (x <= 2.4e+150)
		tmp = t_2;
	else
		tmp = Float64(-1.0 * Float64(i * Float64(x * Float64(Float64(c * y) - Float64(j * y1)))));
	end
	return tmp
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(N[(c * y0), $MachinePrecision] - N[(a * y1), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x * N[(N[(y * N[(N[(a * b), $MachinePrecision] - N[(c * i), $MachinePrecision]), $MachinePrecision] + N[(y2 * t$95$1), $MachinePrecision]), $MachinePrecision] - N[(j * N[(N[(b * y0), $MachinePrecision] - N[(i * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -3.1e+118], t$95$2, If[LessEqual[x, -1.55e-256], N[(-1.0 * N[(y3 * N[(N[(j * N[(N[(y1 * y4), $MachinePrecision] - N[(y0 * y5), $MachinePrecision]), $MachinePrecision] + N[(z * t$95$1), $MachinePrecision]), $MachinePrecision] - N[(y * N[(N[(c * y4), $MachinePrecision] - N[(a * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 2.8e+22], N[(y4 * N[(N[(b * N[(N[(j * t), $MachinePrecision] - N[(k * y), $MachinePrecision]), $MachinePrecision] + N[(y1 * N[(N[(k * y2), $MachinePrecision] - N[(j * y3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(c * N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 2.4e+150], t$95$2, N[(-1.0 * N[(i * N[(x * N[(N[(c * y), $MachinePrecision] - N[(j * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := c \cdot y0 - a \cdot y1\\
t_2 := x \cdot \left(\mathsf{fma}\left(y, a \cdot b - c \cdot i, y2 \cdot t\_1\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\\
\mathbf{if}\;x \leq -3.1 \cdot 10^{+118}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;x \leq -1.55 \cdot 10^{-256}:\\
\;\;\;\;-1 \cdot \left(y3 \cdot \left(\mathsf{fma}\left(j, y1 \cdot y4 - y0 \cdot y5, z \cdot t\_1\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)\\

\mathbf{elif}\;x \leq 2.8 \cdot 10^{+22}:\\
\;\;\;\;y4 \cdot \left(\mathsf{fma}\left(b, j \cdot t - k \cdot y, y1 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - c \cdot \left(t \cdot y2 - y \cdot y3\right)\right)\\

\mathbf{elif}\;x \leq 2.4 \cdot 10^{+150}:\\
\;\;\;\;t\_2\\

\mathbf{else}:\\
\;\;\;\;-1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if x < -3.09999999999999986e118 or 2.8e22 < x < 2.40000000000000003e150

    1. Initial program 25.0%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in x around inf

      \[\leadsto \color{blue}{x \cdot \left(\left(y \cdot \left(a \cdot b - c \cdot i\right) + y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto x \cdot \color{blue}{\left(\left(y \cdot \left(a \cdot b - c \cdot i\right) + y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto x \cdot \left(\left(y \cdot \left(a \cdot b - c \cdot i\right) + y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{j \cdot \left(b \cdot y0 - i \cdot y1\right)}\right) \]
    4. Applied rewrites49.8%

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

    if -3.09999999999999986e118 < x < -1.54999999999999993e-256

    1. Initial program 32.7%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y3 around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \color{blue}{\left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{y \cdot \left(c \cdot y4 - a \cdot y5\right)}\right)\right) \]
    4. Applied rewrites38.4%

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\mathsf{fma}\left(j, y1 \cdot y4 - y0 \cdot y5, z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]

    if -1.54999999999999993e-256 < x < 2.8e22

    1. Initial program 35.2%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y4 around inf

      \[\leadsto \color{blue}{y4 \cdot \left(\left(b \cdot \left(j \cdot t - k \cdot y\right) + y1 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - c \cdot \left(t \cdot y2 - y \cdot y3\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto y4 \cdot \color{blue}{\left(\left(b \cdot \left(j \cdot t - k \cdot y\right) + y1 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - c \cdot \left(t \cdot y2 - y \cdot y3\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto y4 \cdot \left(\left(b \cdot \left(j \cdot t - k \cdot y\right) + y1 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - \color{blue}{c \cdot \left(t \cdot y2 - y \cdot y3\right)}\right) \]
    4. Applied rewrites39.4%

      \[\leadsto \color{blue}{y4 \cdot \left(\mathsf{fma}\left(b, j \cdot t - k \cdot y, y1 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - c \cdot \left(t \cdot y2 - y \cdot y3\right)\right)} \]

    if 2.40000000000000003e150 < x

    1. Initial program 24.8%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites36.3%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in x around inf

      \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \color{blue}{\left(c \cdot y - j \cdot y1\right)}\right)\right) \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - \color{blue}{j \cdot y1}\right)\right)\right) \]
      2. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot \color{blue}{y1}\right)\right)\right) \]
      3. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right) \]
      4. lower-*.f6445.4

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right) \]
    7. Applied rewrites45.4%

      \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \color{blue}{\left(c \cdot y - j \cdot y1\right)}\right)\right) \]
  3. Recombined 4 regimes into one program.
  4. Add Preprocessing

Alternative 6: 42.2% accurate, 2.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := c \cdot y0 - a \cdot y1\\ t_2 := x \cdot \left(\mathsf{fma}\left(y, a \cdot b - c \cdot i, y2 \cdot t\_1\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\\ \mathbf{if}\;x \leq -3.2 \cdot 10^{+101}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;x \leq -8.8 \cdot 10^{-212}:\\ \;\;\;\;y2 \cdot \left(\mathsf{fma}\left(k, y1 \cdot y4 - y0 \cdot y5, x \cdot t\_1\right) - t \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\\ \mathbf{elif}\;x \leq 2.8 \cdot 10^{+22}:\\ \;\;\;\;y4 \cdot \left(\mathsf{fma}\left(b, j \cdot t - k \cdot y, y1 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - c \cdot \left(t \cdot y2 - y \cdot y3\right)\right)\\ \mathbf{elif}\;x \leq 2.4 \cdot 10^{+150}:\\ \;\;\;\;t\_2\\ \mathbf{else}:\\ \;\;\;\;-1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (let* ((t_1 (- (* c y0) (* a y1)))
        (t_2
         (*
          x
          (-
           (fma y (- (* a b) (* c i)) (* y2 t_1))
           (* j (- (* b y0) (* i y1)))))))
   (if (<= x -3.2e+101)
     t_2
     (if (<= x -8.8e-212)
       (*
        y2
        (-
         (fma k (- (* y1 y4) (* y0 y5)) (* x t_1))
         (* t (- (* c y4) (* a y5)))))
       (if (<= x 2.8e+22)
         (*
          y4
          (-
           (fma b (- (* j t) (* k y)) (* y1 (- (* k y2) (* j y3))))
           (* c (- (* t y2) (* y y3)))))
         (if (<= x 2.4e+150)
           t_2
           (* -1.0 (* i (* x (- (* c y) (* j y1)))))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = (c * y0) - (a * y1);
	double t_2 = x * (fma(y, ((a * b) - (c * i)), (y2 * t_1)) - (j * ((b * y0) - (i * y1))));
	double tmp;
	if (x <= -3.2e+101) {
		tmp = t_2;
	} else if (x <= -8.8e-212) {
		tmp = y2 * (fma(k, ((y1 * y4) - (y0 * y5)), (x * t_1)) - (t * ((c * y4) - (a * y5))));
	} else if (x <= 2.8e+22) {
		tmp = y4 * (fma(b, ((j * t) - (k * y)), (y1 * ((k * y2) - (j * y3)))) - (c * ((t * y2) - (y * y3))));
	} else if (x <= 2.4e+150) {
		tmp = t_2;
	} else {
		tmp = -1.0 * (i * (x * ((c * y) - (j * y1))));
	}
	return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = Float64(Float64(c * y0) - Float64(a * y1))
	t_2 = Float64(x * Float64(fma(y, Float64(Float64(a * b) - Float64(c * i)), Float64(y2 * t_1)) - Float64(j * Float64(Float64(b * y0) - Float64(i * y1)))))
	tmp = 0.0
	if (x <= -3.2e+101)
		tmp = t_2;
	elseif (x <= -8.8e-212)
		tmp = Float64(y2 * Float64(fma(k, Float64(Float64(y1 * y4) - Float64(y0 * y5)), Float64(x * t_1)) - Float64(t * Float64(Float64(c * y4) - Float64(a * y5)))));
	elseif (x <= 2.8e+22)
		tmp = Float64(y4 * Float64(fma(b, Float64(Float64(j * t) - Float64(k * y)), Float64(y1 * Float64(Float64(k * y2) - Float64(j * y3)))) - Float64(c * Float64(Float64(t * y2) - Float64(y * y3)))));
	elseif (x <= 2.4e+150)
		tmp = t_2;
	else
		tmp = Float64(-1.0 * Float64(i * Float64(x * Float64(Float64(c * y) - Float64(j * y1)))));
	end
	return tmp
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(N[(c * y0), $MachinePrecision] - N[(a * y1), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x * N[(N[(y * N[(N[(a * b), $MachinePrecision] - N[(c * i), $MachinePrecision]), $MachinePrecision] + N[(y2 * t$95$1), $MachinePrecision]), $MachinePrecision] - N[(j * N[(N[(b * y0), $MachinePrecision] - N[(i * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -3.2e+101], t$95$2, If[LessEqual[x, -8.8e-212], N[(y2 * N[(N[(k * N[(N[(y1 * y4), $MachinePrecision] - N[(y0 * y5), $MachinePrecision]), $MachinePrecision] + N[(x * t$95$1), $MachinePrecision]), $MachinePrecision] - N[(t * N[(N[(c * y4), $MachinePrecision] - N[(a * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 2.8e+22], N[(y4 * N[(N[(b * N[(N[(j * t), $MachinePrecision] - N[(k * y), $MachinePrecision]), $MachinePrecision] + N[(y1 * N[(N[(k * y2), $MachinePrecision] - N[(j * y3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(c * N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 2.4e+150], t$95$2, N[(-1.0 * N[(i * N[(x * N[(N[(c * y), $MachinePrecision] - N[(j * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := c \cdot y0 - a \cdot y1\\
t_2 := x \cdot \left(\mathsf{fma}\left(y, a \cdot b - c \cdot i, y2 \cdot t\_1\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\\
\mathbf{if}\;x \leq -3.2 \cdot 10^{+101}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;x \leq -8.8 \cdot 10^{-212}:\\
\;\;\;\;y2 \cdot \left(\mathsf{fma}\left(k, y1 \cdot y4 - y0 \cdot y5, x \cdot t\_1\right) - t \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\\

\mathbf{elif}\;x \leq 2.8 \cdot 10^{+22}:\\
\;\;\;\;y4 \cdot \left(\mathsf{fma}\left(b, j \cdot t - k \cdot y, y1 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - c \cdot \left(t \cdot y2 - y \cdot y3\right)\right)\\

\mathbf{elif}\;x \leq 2.4 \cdot 10^{+150}:\\
\;\;\;\;t\_2\\

\mathbf{else}:\\
\;\;\;\;-1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if x < -3.20000000000000005e101 or 2.8e22 < x < 2.40000000000000003e150

    1. Initial program 25.0%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in x around inf

      \[\leadsto \color{blue}{x \cdot \left(\left(y \cdot \left(a \cdot b - c \cdot i\right) + y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto x \cdot \color{blue}{\left(\left(y \cdot \left(a \cdot b - c \cdot i\right) + y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto x \cdot \left(\left(y \cdot \left(a \cdot b - c \cdot i\right) + y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{j \cdot \left(b \cdot y0 - i \cdot y1\right)}\right) \]
    4. Applied rewrites49.9%

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

    if -3.20000000000000005e101 < x < -8.80000000000000012e-212

    1. Initial program 32.7%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y2 around inf

      \[\leadsto \color{blue}{y2 \cdot \left(\left(k \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + x \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - t \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto y2 \cdot \color{blue}{\left(\left(k \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + x \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - t \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto y2 \cdot \left(\left(k \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + x \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{t \cdot \left(c \cdot y4 - a \cdot y5\right)}\right) \]
    4. Applied rewrites35.4%

      \[\leadsto \color{blue}{y2 \cdot \left(\mathsf{fma}\left(k, y1 \cdot y4 - y0 \cdot y5, x \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - t \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]

    if -8.80000000000000012e-212 < x < 2.8e22

    1. Initial program 35.1%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y4 around inf

      \[\leadsto \color{blue}{y4 \cdot \left(\left(b \cdot \left(j \cdot t - k \cdot y\right) + y1 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - c \cdot \left(t \cdot y2 - y \cdot y3\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto y4 \cdot \color{blue}{\left(\left(b \cdot \left(j \cdot t - k \cdot y\right) + y1 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - c \cdot \left(t \cdot y2 - y \cdot y3\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto y4 \cdot \left(\left(b \cdot \left(j \cdot t - k \cdot y\right) + y1 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - \color{blue}{c \cdot \left(t \cdot y2 - y \cdot y3\right)}\right) \]
    4. Applied rewrites39.6%

      \[\leadsto \color{blue}{y4 \cdot \left(\mathsf{fma}\left(b, j \cdot t - k \cdot y, y1 \cdot \left(k \cdot y2 - j \cdot y3\right)\right) - c \cdot \left(t \cdot y2 - y \cdot y3\right)\right)} \]

    if 2.40000000000000003e150 < x

    1. Initial program 24.8%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites36.3%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in x around inf

      \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \color{blue}{\left(c \cdot y - j \cdot y1\right)}\right)\right) \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - \color{blue}{j \cdot y1}\right)\right)\right) \]
      2. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot \color{blue}{y1}\right)\right)\right) \]
      3. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right) \]
      4. lower-*.f6445.4

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right) \]
    7. Applied rewrites45.4%

      \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \color{blue}{\left(c \cdot y - j \cdot y1\right)}\right)\right) \]
  3. Recombined 4 regimes into one program.
  4. Add Preprocessing

Alternative 7: 35.0% accurate, 2.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := x \cdot y - t \cdot z\\ \mathbf{if}\;y3 \leq -1.6 \cdot 10^{-17}:\\ \;\;\;\;y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)\\ \mathbf{elif}\;y3 \leq -1.22 \cdot 10^{-220}:\\ \;\;\;\;b \cdot \left(y4 \cdot \left(t \cdot \left(j + -1 \cdot \frac{k \cdot y}{t}\right)\right)\right)\\ \mathbf{elif}\;y3 \leq 3.7 \cdot 10^{-12}:\\ \;\;\;\;b \cdot \left(\mathsf{fma}\left(a, t\_1, y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)\\ \mathbf{elif}\;y3 \leq 2.1 \cdot 10^{+247}:\\ \;\;\;\;-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot t\_1\right) - -1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;a \cdot \left(y3 \cdot \left(y1 \cdot z - y \cdot y5\right)\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (let* ((t_1 (- (* x y) (* t z))))
   (if (<= y3 -1.6e-17)
     (* y3 (* y5 (- (* j y0) (* a y))))
     (if (<= y3 -1.22e-220)
       (* b (* y4 (* t (+ j (* -1.0 (/ (* k y) t))))))
       (if (<= y3 3.7e-12)
         (*
          b
          (-
           (fma a t_1 (* y4 (- (* j t) (* k y))))
           (* y0 (- (* j x) (* k z)))))
         (if (<= y3 2.1e+247)
           (*
            -1.0
            (*
             i
             (- (fma -1.0 (* k (* y y5)) (* c t_1)) (* -1.0 (* k (* y1 z))))))
           (* a (* y3 (- (* y1 z) (* y y5))))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = (x * y) - (t * z);
	double tmp;
	if (y3 <= -1.6e-17) {
		tmp = y3 * (y5 * ((j * y0) - (a * y)));
	} else if (y3 <= -1.22e-220) {
		tmp = b * (y4 * (t * (j + (-1.0 * ((k * y) / t)))));
	} else if (y3 <= 3.7e-12) {
		tmp = b * (fma(a, t_1, (y4 * ((j * t) - (k * y)))) - (y0 * ((j * x) - (k * z))));
	} else if (y3 <= 2.1e+247) {
		tmp = -1.0 * (i * (fma(-1.0, (k * (y * y5)), (c * t_1)) - (-1.0 * (k * (y1 * z)))));
	} else {
		tmp = a * (y3 * ((y1 * z) - (y * y5)));
	}
	return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = Float64(Float64(x * y) - Float64(t * z))
	tmp = 0.0
	if (y3 <= -1.6e-17)
		tmp = Float64(y3 * Float64(y5 * Float64(Float64(j * y0) - Float64(a * y))));
	elseif (y3 <= -1.22e-220)
		tmp = Float64(b * Float64(y4 * Float64(t * Float64(j + Float64(-1.0 * Float64(Float64(k * y) / t))))));
	elseif (y3 <= 3.7e-12)
		tmp = Float64(b * Float64(fma(a, t_1, Float64(y4 * Float64(Float64(j * t) - Float64(k * y)))) - Float64(y0 * Float64(Float64(j * x) - Float64(k * z)))));
	elseif (y3 <= 2.1e+247)
		tmp = Float64(-1.0 * Float64(i * Float64(fma(-1.0, Float64(k * Float64(y * y5)), Float64(c * t_1)) - Float64(-1.0 * Float64(k * Float64(y1 * z))))));
	else
		tmp = Float64(a * Float64(y3 * Float64(Float64(y1 * z) - Float64(y * y5))));
	end
	return tmp
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(N[(x * y), $MachinePrecision] - N[(t * z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y3, -1.6e-17], N[(y3 * N[(y5 * N[(N[(j * y0), $MachinePrecision] - N[(a * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y3, -1.22e-220], N[(b * N[(y4 * N[(t * N[(j + N[(-1.0 * N[(N[(k * y), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y3, 3.7e-12], N[(b * N[(N[(a * t$95$1 + N[(y4 * N[(N[(j * t), $MachinePrecision] - N[(k * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(y0 * N[(N[(j * x), $MachinePrecision] - N[(k * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y3, 2.1e+247], N[(-1.0 * N[(i * N[(N[(-1.0 * N[(k * N[(y * y5), $MachinePrecision]), $MachinePrecision] + N[(c * t$95$1), $MachinePrecision]), $MachinePrecision] - N[(-1.0 * N[(k * N[(y1 * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(a * N[(y3 * N[(N[(y1 * z), $MachinePrecision] - N[(y * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := x \cdot y - t \cdot z\\
\mathbf{if}\;y3 \leq -1.6 \cdot 10^{-17}:\\
\;\;\;\;y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)\\

\mathbf{elif}\;y3 \leq -1.22 \cdot 10^{-220}:\\
\;\;\;\;b \cdot \left(y4 \cdot \left(t \cdot \left(j + -1 \cdot \frac{k \cdot y}{t}\right)\right)\right)\\

\mathbf{elif}\;y3 \leq 3.7 \cdot 10^{-12}:\\
\;\;\;\;b \cdot \left(\mathsf{fma}\left(a, t\_1, y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)\\

\mathbf{elif}\;y3 \leq 2.1 \cdot 10^{+247}:\\
\;\;\;\;-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot t\_1\right) - -1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)\right)\right)\\

\mathbf{else}:\\
\;\;\;\;a \cdot \left(y3 \cdot \left(y1 \cdot z - y \cdot y5\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if y3 < -1.6000000000000001e-17

    1. Initial program 26.3%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y3 around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \color{blue}{\left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{y \cdot \left(c \cdot y4 - a \cdot y5\right)}\right)\right) \]
    4. Applied rewrites48.4%

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\mathsf{fma}\left(j, y1 \cdot y4 - y0 \cdot y5, z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    5. Taylor expanded in y5 around -inf

      \[\leadsto y3 \cdot \color{blue}{\left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \color{blue}{\left(j \cdot y0 - a \cdot y\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - \color{blue}{a \cdot y}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot \color{blue}{y}\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right) \]
      5. lower-*.f6432.4

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right) \]
    7. Applied rewrites32.4%

      \[\leadsto y3 \cdot \color{blue}{\left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)} \]

    if -1.6000000000000001e-17 < y3 < -1.22000000000000002e-220

    1. Initial program 33.3%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in b around inf

      \[\leadsto \color{blue}{b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto b \cdot \color{blue}{\left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y0 \cdot \left(j \cdot x - k \cdot z\right)}\right) \]
    4. Applied rewrites39.1%

      \[\leadsto \color{blue}{b \cdot \left(\mathsf{fma}\left(a, x \cdot y - t \cdot z, y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    5. Taylor expanded in y4 around inf

      \[\leadsto b \cdot \left(y4 \cdot \color{blue}{\left(j \cdot t - k \cdot y\right)}\right) \]
    6. Step-by-step derivation
      1. lift-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot y\right)\right) \]
      2. lift-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot y\right)\right) \]
      3. lift--.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot \color{blue}{y}\right)\right) \]
      4. lift-*.f6427.9

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - \color{blue}{k \cdot y}\right)\right) \]
    7. Applied rewrites27.9%

      \[\leadsto b \cdot \left(y4 \cdot \color{blue}{\left(j \cdot t - k \cdot y\right)}\right) \]
    8. Taylor expanded in t around inf

      \[\leadsto b \cdot \left(y4 \cdot \left(t \cdot \left(j + \color{blue}{-1 \cdot \frac{k \cdot y}{t}}\right)\right)\right) \]
    9. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(t \cdot \left(j + -1 \cdot \color{blue}{\frac{k \cdot y}{t}}\right)\right)\right) \]
      2. lower-+.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(t \cdot \left(j + -1 \cdot \frac{k \cdot y}{\color{blue}{t}}\right)\right)\right) \]
      3. lower-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(t \cdot \left(j + -1 \cdot \frac{k \cdot y}{t}\right)\right)\right) \]
      4. lower-/.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(t \cdot \left(j + -1 \cdot \frac{k \cdot y}{t}\right)\right)\right) \]
      5. lift-*.f6430.1

        \[\leadsto b \cdot \left(y4 \cdot \left(t \cdot \left(j + -1 \cdot \frac{k \cdot y}{t}\right)\right)\right) \]
    10. Applied rewrites30.1%

      \[\leadsto b \cdot \left(y4 \cdot \left(t \cdot \left(j + \color{blue}{-1 \cdot \frac{k \cdot y}{t}}\right)\right)\right) \]

    if -1.22000000000000002e-220 < y3 < 3.69999999999999999e-12

    1. Initial program 35.1%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in b around inf

      \[\leadsto \color{blue}{b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto b \cdot \color{blue}{\left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y0 \cdot \left(j \cdot x - k \cdot z\right)}\right) \]
    4. Applied rewrites39.2%

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

    if 3.69999999999999999e-12 < y3 < 2.1e247

    1. Initial program 28.6%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites35.5%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in j around 0

      \[\leadsto -1 \cdot \left(i \cdot \left(\left(-1 \cdot \left(k \cdot \left(y \cdot y5\right)\right) + c \cdot \left(x \cdot y - t \cdot z\right)\right) - \color{blue}{-1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)}\right)\right) \]
    6. Step-by-step derivation
      1. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(-1 \cdot \left(k \cdot \left(y \cdot y5\right)\right) + c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \color{blue}{\left(k \cdot \left(y1 \cdot z\right)\right)}\right)\right) \]
      2. lower-fma.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(\color{blue}{k} \cdot \left(y1 \cdot z\right)\right)\right)\right) \]
      3. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)\right)\right) \]
      5. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)\right)\right) \]
      6. lift-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)\right)\right) \]
      7. lift-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)\right)\right) \]
      8. lift--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)\right)\right) \]
      9. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \color{blue}{\left(y1 \cdot z\right)}\right)\right)\right) \]
      10. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \left(y1 \cdot \color{blue}{z}\right)\right)\right)\right) \]
      11. lower-*.f6431.5

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)\right)\right) \]
    7. Applied rewrites31.5%

      \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - \color{blue}{-1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)}\right)\right) \]

    if 2.1e247 < y3

    1. Initial program 19.8%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y3 around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \color{blue}{\left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{y \cdot \left(c \cdot y4 - a \cdot y5\right)}\right)\right) \]
    4. Applied rewrites64.6%

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\mathsf{fma}\left(j, y1 \cdot y4 - y0 \cdot y5, z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    5. Taylor expanded in a around -inf

      \[\leadsto a \cdot \color{blue}{\left(y3 \cdot \left(y1 \cdot z - y \cdot y5\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto a \cdot \left(y3 \cdot \color{blue}{\left(y1 \cdot z - y \cdot y5\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto a \cdot \left(y3 \cdot \left(y1 \cdot z - \color{blue}{y \cdot y5}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto a \cdot \left(y3 \cdot \left(y1 \cdot z - y \cdot \color{blue}{y5}\right)\right) \]
      4. lift-*.f64N/A

        \[\leadsto a \cdot \left(y3 \cdot \left(y1 \cdot z - y \cdot y5\right)\right) \]
      5. lift-*.f6453.2

        \[\leadsto a \cdot \left(y3 \cdot \left(y1 \cdot z - y \cdot y5\right)\right) \]
    7. Applied rewrites53.2%

      \[\leadsto a \cdot \color{blue}{\left(y3 \cdot \left(y1 \cdot z - y \cdot y5\right)\right)} \]
  3. Recombined 5 regimes into one program.
  4. Add Preprocessing

Alternative 8: 41.1% accurate, 2.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := c \cdot y0 - a \cdot y1\\ t_2 := y2 \cdot \left(\mathsf{fma}\left(k, y1 \cdot y4 - y0 \cdot y5, x \cdot t\_1\right) - t \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\\ \mathbf{if}\;y2 \leq -4.6 \cdot 10^{+27}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;y2 \leq 1.32 \cdot 10^{-274}:\\ \;\;\;\;x \cdot \left(\mathsf{fma}\left(y, a \cdot b - c \cdot i, y2 \cdot t\_1\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\\ \mathbf{elif}\;y2 \leq 1.45 \cdot 10^{+28}:\\ \;\;\;\;b \cdot \left(y4 \cdot \left(t \cdot \left(j + -1 \cdot \frac{k \cdot y}{t}\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;t\_2\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (let* ((t_1 (- (* c y0) (* a y1)))
        (t_2
         (*
          y2
          (-
           (fma k (- (* y1 y4) (* y0 y5)) (* x t_1))
           (* t (- (* c y4) (* a y5)))))))
   (if (<= y2 -4.6e+27)
     t_2
     (if (<= y2 1.32e-274)
       (*
        x
        (- (fma y (- (* a b) (* c i)) (* y2 t_1)) (* j (- (* b y0) (* i y1)))))
       (if (<= y2 1.45e+28)
         (* b (* y4 (* t (+ j (* -1.0 (/ (* k y) t))))))
         t_2)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = (c * y0) - (a * y1);
	double t_2 = y2 * (fma(k, ((y1 * y4) - (y0 * y5)), (x * t_1)) - (t * ((c * y4) - (a * y5))));
	double tmp;
	if (y2 <= -4.6e+27) {
		tmp = t_2;
	} else if (y2 <= 1.32e-274) {
		tmp = x * (fma(y, ((a * b) - (c * i)), (y2 * t_1)) - (j * ((b * y0) - (i * y1))));
	} else if (y2 <= 1.45e+28) {
		tmp = b * (y4 * (t * (j + (-1.0 * ((k * y) / t)))));
	} else {
		tmp = t_2;
	}
	return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = Float64(Float64(c * y0) - Float64(a * y1))
	t_2 = Float64(y2 * Float64(fma(k, Float64(Float64(y1 * y4) - Float64(y0 * y5)), Float64(x * t_1)) - Float64(t * Float64(Float64(c * y4) - Float64(a * y5)))))
	tmp = 0.0
	if (y2 <= -4.6e+27)
		tmp = t_2;
	elseif (y2 <= 1.32e-274)
		tmp = Float64(x * Float64(fma(y, Float64(Float64(a * b) - Float64(c * i)), Float64(y2 * t_1)) - Float64(j * Float64(Float64(b * y0) - Float64(i * y1)))));
	elseif (y2 <= 1.45e+28)
		tmp = Float64(b * Float64(y4 * Float64(t * Float64(j + Float64(-1.0 * Float64(Float64(k * y) / t))))));
	else
		tmp = t_2;
	end
	return tmp
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(N[(c * y0), $MachinePrecision] - N[(a * y1), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(y2 * N[(N[(k * N[(N[(y1 * y4), $MachinePrecision] - N[(y0 * y5), $MachinePrecision]), $MachinePrecision] + N[(x * t$95$1), $MachinePrecision]), $MachinePrecision] - N[(t * N[(N[(c * y4), $MachinePrecision] - N[(a * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y2, -4.6e+27], t$95$2, If[LessEqual[y2, 1.32e-274], N[(x * N[(N[(y * N[(N[(a * b), $MachinePrecision] - N[(c * i), $MachinePrecision]), $MachinePrecision] + N[(y2 * t$95$1), $MachinePrecision]), $MachinePrecision] - N[(j * N[(N[(b * y0), $MachinePrecision] - N[(i * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y2, 1.45e+28], N[(b * N[(y4 * N[(t * N[(j + N[(-1.0 * N[(N[(k * y), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$2]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := c \cdot y0 - a \cdot y1\\
t_2 := y2 \cdot \left(\mathsf{fma}\left(k, y1 \cdot y4 - y0 \cdot y5, x \cdot t\_1\right) - t \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\\
\mathbf{if}\;y2 \leq -4.6 \cdot 10^{+27}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;y2 \leq 1.32 \cdot 10^{-274}:\\
\;\;\;\;x \cdot \left(\mathsf{fma}\left(y, a \cdot b - c \cdot i, y2 \cdot t\_1\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\\

\mathbf{elif}\;y2 \leq 1.45 \cdot 10^{+28}:\\
\;\;\;\;b \cdot \left(y4 \cdot \left(t \cdot \left(j + -1 \cdot \frac{k \cdot y}{t}\right)\right)\right)\\

\mathbf{else}:\\
\;\;\;\;t\_2\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y2 < -4.6000000000000001e27 or 1.4500000000000001e28 < y2

    1. Initial program 24.8%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y2 around inf

      \[\leadsto \color{blue}{y2 \cdot \left(\left(k \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + x \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - t \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto y2 \cdot \color{blue}{\left(\left(k \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + x \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - t \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto y2 \cdot \left(\left(k \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + x \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{t \cdot \left(c \cdot y4 - a \cdot y5\right)}\right) \]
    4. Applied rewrites51.1%

      \[\leadsto \color{blue}{y2 \cdot \left(\mathsf{fma}\left(k, y1 \cdot y4 - y0 \cdot y5, x \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - t \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]

    if -4.6000000000000001e27 < y2 < 1.32e-274

    1. Initial program 34.9%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in x around inf

      \[\leadsto \color{blue}{x \cdot \left(\left(y \cdot \left(a \cdot b - c \cdot i\right) + y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto x \cdot \color{blue}{\left(\left(y \cdot \left(a \cdot b - c \cdot i\right) + y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto x \cdot \left(\left(y \cdot \left(a \cdot b - c \cdot i\right) + y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{j \cdot \left(b \cdot y0 - i \cdot y1\right)}\right) \]
    4. Applied rewrites35.9%

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

    if 1.32e-274 < y2 < 1.4500000000000001e28

    1. Initial program 35.1%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in b around inf

      \[\leadsto \color{blue}{b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto b \cdot \color{blue}{\left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y0 \cdot \left(j \cdot x - k \cdot z\right)}\right) \]
    4. Applied rewrites39.7%

      \[\leadsto \color{blue}{b \cdot \left(\mathsf{fma}\left(a, x \cdot y - t \cdot z, y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    5. Taylor expanded in y4 around inf

      \[\leadsto b \cdot \left(y4 \cdot \color{blue}{\left(j \cdot t - k \cdot y\right)}\right) \]
    6. Step-by-step derivation
      1. lift-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot y\right)\right) \]
      2. lift-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot y\right)\right) \]
      3. lift--.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot \color{blue}{y}\right)\right) \]
      4. lift-*.f6426.8

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - \color{blue}{k \cdot y}\right)\right) \]
    7. Applied rewrites26.8%

      \[\leadsto b \cdot \left(y4 \cdot \color{blue}{\left(j \cdot t - k \cdot y\right)}\right) \]
    8. Taylor expanded in t around inf

      \[\leadsto b \cdot \left(y4 \cdot \left(t \cdot \left(j + \color{blue}{-1 \cdot \frac{k \cdot y}{t}}\right)\right)\right) \]
    9. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(t \cdot \left(j + -1 \cdot \color{blue}{\frac{k \cdot y}{t}}\right)\right)\right) \]
      2. lower-+.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(t \cdot \left(j + -1 \cdot \frac{k \cdot y}{\color{blue}{t}}\right)\right)\right) \]
      3. lower-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(t \cdot \left(j + -1 \cdot \frac{k \cdot y}{t}\right)\right)\right) \]
      4. lower-/.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(t \cdot \left(j + -1 \cdot \frac{k \cdot y}{t}\right)\right)\right) \]
      5. lift-*.f6428.9

        \[\leadsto b \cdot \left(y4 \cdot \left(t \cdot \left(j + -1 \cdot \frac{k \cdot y}{t}\right)\right)\right) \]
    10. Applied rewrites28.9%

      \[\leadsto b \cdot \left(y4 \cdot \left(t \cdot \left(j + \color{blue}{-1 \cdot \frac{k \cdot y}{t}}\right)\right)\right) \]
  3. Recombined 3 regimes into one program.
  4. Add Preprocessing

Alternative 9: 32.3% accurate, 2.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;c \leq -5.5 \cdot 10^{-12}:\\ \;\;\;\;-1 \cdot \left(y3 \cdot \left(c \cdot \left(y0 \cdot z\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)\\ \mathbf{elif}\;c \leq 8.8 \cdot 10^{-131}:\\ \;\;\;\;i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\\ \mathbf{elif}\;c \leq 3.3 \cdot 10^{+22}:\\ \;\;\;\;y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)\\ \mathbf{else}:\\ \;\;\;\;-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)\right)\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (if (<= c -5.5e-12)
   (* -1.0 (* y3 (- (* c (* y0 z)) (* y (- (* c y4) (* a y5))))))
   (if (<= c 8.8e-131)
     (* i (* y1 (- (* j x) (* k z))))
     (if (<= c 3.3e+22)
       (* y3 (* y5 (- (* j y0) (* a y))))
       (*
        -1.0
        (*
         i
         (-
          (fma -1.0 (* k (* y y5)) (* c (- (* x y) (* t z))))
          (* -1.0 (* k (* y1 z))))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double tmp;
	if (c <= -5.5e-12) {
		tmp = -1.0 * (y3 * ((c * (y0 * z)) - (y * ((c * y4) - (a * y5)))));
	} else if (c <= 8.8e-131) {
		tmp = i * (y1 * ((j * x) - (k * z)));
	} else if (c <= 3.3e+22) {
		tmp = y3 * (y5 * ((j * y0) - (a * y)));
	} else {
		tmp = -1.0 * (i * (fma(-1.0, (k * (y * y5)), (c * ((x * y) - (t * z)))) - (-1.0 * (k * (y1 * z)))));
	}
	return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	tmp = 0.0
	if (c <= -5.5e-12)
		tmp = Float64(-1.0 * Float64(y3 * Float64(Float64(c * Float64(y0 * z)) - Float64(y * Float64(Float64(c * y4) - Float64(a * y5))))));
	elseif (c <= 8.8e-131)
		tmp = Float64(i * Float64(y1 * Float64(Float64(j * x) - Float64(k * z))));
	elseif (c <= 3.3e+22)
		tmp = Float64(y3 * Float64(y5 * Float64(Float64(j * y0) - Float64(a * y))));
	else
		tmp = Float64(-1.0 * Float64(i * Float64(fma(-1.0, Float64(k * Float64(y * y5)), Float64(c * Float64(Float64(x * y) - Float64(t * z)))) - Float64(-1.0 * Float64(k * Float64(y1 * z))))));
	end
	return tmp
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := If[LessEqual[c, -5.5e-12], N[(-1.0 * N[(y3 * N[(N[(c * N[(y0 * z), $MachinePrecision]), $MachinePrecision] - N[(y * N[(N[(c * y4), $MachinePrecision] - N[(a * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[c, 8.8e-131], N[(i * N[(y1 * N[(N[(j * x), $MachinePrecision] - N[(k * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[c, 3.3e+22], N[(y3 * N[(y5 * N[(N[(j * y0), $MachinePrecision] - N[(a * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(-1.0 * N[(i * N[(N[(-1.0 * N[(k * N[(y * y5), $MachinePrecision]), $MachinePrecision] + N[(c * N[(N[(x * y), $MachinePrecision] - N[(t * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(-1.0 * N[(k * N[(y1 * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;c \leq -5.5 \cdot 10^{-12}:\\
\;\;\;\;-1 \cdot \left(y3 \cdot \left(c \cdot \left(y0 \cdot z\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)\\

\mathbf{elif}\;c \leq 8.8 \cdot 10^{-131}:\\
\;\;\;\;i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\\

\mathbf{elif}\;c \leq 3.3 \cdot 10^{+22}:\\
\;\;\;\;y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)\\

\mathbf{else}:\\
\;\;\;\;-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if c < -5.5000000000000004e-12

    1. Initial program 28.0%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y3 around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \color{blue}{\left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{y \cdot \left(c \cdot y4 - a \cdot y5\right)}\right)\right) \]
    4. Applied rewrites36.9%

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\mathsf{fma}\left(j, y1 \cdot y4 - y0 \cdot y5, z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    5. Taylor expanded in c around inf

      \[\leadsto -1 \cdot \left(y3 \cdot \left(c \cdot \left(y0 \cdot z\right) - \color{blue}{y} \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right) \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \left(c \cdot \left(y0 \cdot z\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right) \]
      2. lower-*.f6437.6

        \[\leadsto -1 \cdot \left(y3 \cdot \left(c \cdot \left(y0 \cdot z\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right) \]
    7. Applied rewrites37.6%

      \[\leadsto -1 \cdot \left(y3 \cdot \left(c \cdot \left(y0 \cdot z\right) - \color{blue}{y} \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right) \]

    if -5.5000000000000004e-12 < c < 8.7999999999999999e-131

    1. Initial program 34.8%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites35.4%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in y1 around -inf

      \[\leadsto i \cdot \color{blue}{\left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \color{blue}{\left(j \cdot x - k \cdot z\right)}\right) \]
      2. lift-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right) \]
      3. lift-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right) \]
      4. lift--.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot \color{blue}{z}\right)\right) \]
      5. lift-*.f6427.6

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - \color{blue}{k \cdot z}\right)\right) \]
    7. Applied rewrites27.6%

      \[\leadsto i \cdot \color{blue}{\left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]

    if 8.7999999999999999e-131 < c < 3.2999999999999998e22

    1. Initial program 32.7%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y3 around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \color{blue}{\left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{y \cdot \left(c \cdot y4 - a \cdot y5\right)}\right)\right) \]
    4. Applied rewrites36.4%

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\mathsf{fma}\left(j, y1 \cdot y4 - y0 \cdot y5, z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    5. Taylor expanded in y5 around -inf

      \[\leadsto y3 \cdot \color{blue}{\left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \color{blue}{\left(j \cdot y0 - a \cdot y\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - \color{blue}{a \cdot y}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot \color{blue}{y}\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right) \]
      5. lower-*.f6426.4

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right) \]
    7. Applied rewrites26.4%

      \[\leadsto y3 \cdot \color{blue}{\left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)} \]

    if 3.2999999999999998e22 < c

    1. Initial program 24.5%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites38.1%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in j around 0

      \[\leadsto -1 \cdot \left(i \cdot \left(\left(-1 \cdot \left(k \cdot \left(y \cdot y5\right)\right) + c \cdot \left(x \cdot y - t \cdot z\right)\right) - \color{blue}{-1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)}\right)\right) \]
    6. Step-by-step derivation
      1. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(-1 \cdot \left(k \cdot \left(y \cdot y5\right)\right) + c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \color{blue}{\left(k \cdot \left(y1 \cdot z\right)\right)}\right)\right) \]
      2. lower-fma.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(\color{blue}{k} \cdot \left(y1 \cdot z\right)\right)\right)\right) \]
      3. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)\right)\right) \]
      5. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)\right)\right) \]
      6. lift-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)\right)\right) \]
      7. lift-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)\right)\right) \]
      8. lift--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)\right)\right) \]
      9. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \color{blue}{\left(y1 \cdot z\right)}\right)\right)\right) \]
      10. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \left(y1 \cdot \color{blue}{z}\right)\right)\right)\right) \]
      11. lower-*.f6437.2

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)\right)\right) \]
    7. Applied rewrites37.2%

      \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - \color{blue}{-1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)}\right)\right) \]
  3. Recombined 4 regimes into one program.
  4. Add Preprocessing

Alternative 10: 30.5% accurate, 2.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := i \cdot \left(y \cdot \left(y5 \cdot \left(k + -1 \cdot \frac{c \cdot x}{y5}\right)\right)\right)\\ t_2 := b \cdot \left(t \cdot \mathsf{fma}\left(-1, a \cdot z, j \cdot y4\right)\right)\\ \mathbf{if}\;k \leq -8.5 \cdot 10^{+209}:\\ \;\;\;\;i \cdot \left(z \cdot \left(c \cdot t - k \cdot y1\right)\right)\\ \mathbf{elif}\;k \leq -1.4 \cdot 10^{+77}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;k \leq -1.25 \cdot 10^{-177}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;k \leq 5.2 \cdot 10^{-248}:\\ \;\;\;\;-1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right)\\ \mathbf{elif}\;k \leq 2.2 \cdot 10^{-154}:\\ \;\;\;\;y1 \cdot \left(y3 \cdot \mathsf{fma}\left(-1, j \cdot y4, a \cdot z\right)\right)\\ \mathbf{elif}\;k \leq 16500000:\\ \;\;\;\;t\_2\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (let* ((t_1 (* i (* y (* y5 (+ k (* -1.0 (/ (* c x) y5)))))))
        (t_2 (* b (* t (fma -1.0 (* a z) (* j y4))))))
   (if (<= k -8.5e+209)
     (* i (* z (- (* c t) (* k y1))))
     (if (<= k -1.4e+77)
       t_1
       (if (<= k -1.25e-177)
         t_2
         (if (<= k 5.2e-248)
           (* -1.0 (* i (* x (- (* c y) (* j y1)))))
           (if (<= k 2.2e-154)
             (* y1 (* y3 (fma -1.0 (* j y4) (* a z))))
             (if (<= k 16500000.0) t_2 t_1))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = i * (y * (y5 * (k + (-1.0 * ((c * x) / y5)))));
	double t_2 = b * (t * fma(-1.0, (a * z), (j * y4)));
	double tmp;
	if (k <= -8.5e+209) {
		tmp = i * (z * ((c * t) - (k * y1)));
	} else if (k <= -1.4e+77) {
		tmp = t_1;
	} else if (k <= -1.25e-177) {
		tmp = t_2;
	} else if (k <= 5.2e-248) {
		tmp = -1.0 * (i * (x * ((c * y) - (j * y1))));
	} else if (k <= 2.2e-154) {
		tmp = y1 * (y3 * fma(-1.0, (j * y4), (a * z)));
	} else if (k <= 16500000.0) {
		tmp = t_2;
	} else {
		tmp = t_1;
	}
	return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = Float64(i * Float64(y * Float64(y5 * Float64(k + Float64(-1.0 * Float64(Float64(c * x) / y5))))))
	t_2 = Float64(b * Float64(t * fma(-1.0, Float64(a * z), Float64(j * y4))))
	tmp = 0.0
	if (k <= -8.5e+209)
		tmp = Float64(i * Float64(z * Float64(Float64(c * t) - Float64(k * y1))));
	elseif (k <= -1.4e+77)
		tmp = t_1;
	elseif (k <= -1.25e-177)
		tmp = t_2;
	elseif (k <= 5.2e-248)
		tmp = Float64(-1.0 * Float64(i * Float64(x * Float64(Float64(c * y) - Float64(j * y1)))));
	elseif (k <= 2.2e-154)
		tmp = Float64(y1 * Float64(y3 * fma(-1.0, Float64(j * y4), Float64(a * z))));
	elseif (k <= 16500000.0)
		tmp = t_2;
	else
		tmp = t_1;
	end
	return tmp
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(i * N[(y * N[(y5 * N[(k + N[(-1.0 * N[(N[(c * x), $MachinePrecision] / y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(b * N[(t * N[(-1.0 * N[(a * z), $MachinePrecision] + N[(j * y4), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[k, -8.5e+209], N[(i * N[(z * N[(N[(c * t), $MachinePrecision] - N[(k * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, -1.4e+77], t$95$1, If[LessEqual[k, -1.25e-177], t$95$2, If[LessEqual[k, 5.2e-248], N[(-1.0 * N[(i * N[(x * N[(N[(c * y), $MachinePrecision] - N[(j * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 2.2e-154], N[(y1 * N[(y3 * N[(-1.0 * N[(j * y4), $MachinePrecision] + N[(a * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 16500000.0], t$95$2, t$95$1]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := i \cdot \left(y \cdot \left(y5 \cdot \left(k + -1 \cdot \frac{c \cdot x}{y5}\right)\right)\right)\\
t_2 := b \cdot \left(t \cdot \mathsf{fma}\left(-1, a \cdot z, j \cdot y4\right)\right)\\
\mathbf{if}\;k \leq -8.5 \cdot 10^{+209}:\\
\;\;\;\;i \cdot \left(z \cdot \left(c \cdot t - k \cdot y1\right)\right)\\

\mathbf{elif}\;k \leq -1.4 \cdot 10^{+77}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;k \leq -1.25 \cdot 10^{-177}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;k \leq 5.2 \cdot 10^{-248}:\\
\;\;\;\;-1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right)\\

\mathbf{elif}\;k \leq 2.2 \cdot 10^{-154}:\\
\;\;\;\;y1 \cdot \left(y3 \cdot \mathsf{fma}\left(-1, j \cdot y4, a \cdot z\right)\right)\\

\mathbf{elif}\;k \leq 16500000:\\
\;\;\;\;t\_2\\

\mathbf{else}:\\
\;\;\;\;t\_1\\


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if k < -8.50000000000000062e209

    1. Initial program 22.2%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites35.9%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in z around -inf

      \[\leadsto i \cdot \color{blue}{\left(z \cdot \left(c \cdot t - k \cdot y1\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \color{blue}{\left(c \cdot t - k \cdot y1\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - \color{blue}{k \cdot y1}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot \color{blue}{y1}\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot y1\right)\right) \]
      5. lower-*.f6438.8

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot y1\right)\right) \]
    7. Applied rewrites38.8%

      \[\leadsto i \cdot \color{blue}{\left(z \cdot \left(c \cdot t - k \cdot y1\right)\right)} \]

    if -8.50000000000000062e209 < k < -1.4e77 or 1.65e7 < k

    1. Initial program 25.9%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites37.3%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in y around -inf

      \[\leadsto i \cdot \color{blue}{\left(y \cdot \left(-1 \cdot \left(c \cdot x\right) + k \cdot y5\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \color{blue}{\left(-1 \cdot \left(c \cdot x\right) + k \cdot y5\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot x\right) + \color{blue}{k \cdot y5}\right)\right) \]
      3. lower-fma.f64N/A

        \[\leadsto i \cdot \left(y \cdot \mathsf{fma}\left(-1, c \cdot \color{blue}{x}, k \cdot y5\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \mathsf{fma}\left(-1, c \cdot x, k \cdot y5\right)\right) \]
      5. lower-*.f6432.1

        \[\leadsto i \cdot \left(y \cdot \mathsf{fma}\left(-1, c \cdot x, k \cdot y5\right)\right) \]
    7. Applied rewrites32.1%

      \[\leadsto i \cdot \color{blue}{\left(y \cdot \mathsf{fma}\left(-1, c \cdot x, k \cdot y5\right)\right)} \]
    8. Taylor expanded in y5 around inf

      \[\leadsto i \cdot \left(y \cdot \left(y5 \cdot \left(k + \color{blue}{-1 \cdot \frac{c \cdot x}{y5}}\right)\right)\right) \]
    9. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \left(y5 \cdot \left(k + -1 \cdot \color{blue}{\frac{c \cdot x}{y5}}\right)\right)\right) \]
      2. lower-+.f64N/A

        \[\leadsto i \cdot \left(y \cdot \left(y5 \cdot \left(k + -1 \cdot \frac{c \cdot x}{\color{blue}{y5}}\right)\right)\right) \]
      3. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \left(y5 \cdot \left(k + -1 \cdot \frac{c \cdot x}{y5}\right)\right)\right) \]
      4. lower-/.f64N/A

        \[\leadsto i \cdot \left(y \cdot \left(y5 \cdot \left(k + -1 \cdot \frac{c \cdot x}{y5}\right)\right)\right) \]
      5. lift-*.f6434.9

        \[\leadsto i \cdot \left(y \cdot \left(y5 \cdot \left(k + -1 \cdot \frac{c \cdot x}{y5}\right)\right)\right) \]
    10. Applied rewrites34.9%

      \[\leadsto i \cdot \left(y \cdot \left(y5 \cdot \left(k + \color{blue}{-1 \cdot \frac{c \cdot x}{y5}}\right)\right)\right) \]

    if -1.4e77 < k < -1.25e-177 or 2.20000000000000007e-154 < k < 1.65e7

    1. Initial program 34.1%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in b around inf

      \[\leadsto \color{blue}{b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto b \cdot \color{blue}{\left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y0 \cdot \left(j \cdot x - k \cdot z\right)}\right) \]
    4. Applied rewrites37.6%

      \[\leadsto \color{blue}{b \cdot \left(\mathsf{fma}\left(a, x \cdot y - t \cdot z, y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    5. Taylor expanded in t around inf

      \[\leadsto b \cdot \left(t \cdot \color{blue}{\left(-1 \cdot \left(a \cdot z\right) + j \cdot y4\right)}\right) \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto b \cdot \left(t \cdot \left(-1 \cdot \left(a \cdot z\right) + \color{blue}{j \cdot y4}\right)\right) \]
      2. lower-fma.f64N/A

        \[\leadsto b \cdot \left(t \cdot \mathsf{fma}\left(-1, a \cdot \color{blue}{z}, j \cdot y4\right)\right) \]
      3. lower-*.f64N/A

        \[\leadsto b \cdot \left(t \cdot \mathsf{fma}\left(-1, a \cdot z, j \cdot y4\right)\right) \]
      4. lower-*.f6427.0

        \[\leadsto b \cdot \left(t \cdot \mathsf{fma}\left(-1, a \cdot z, j \cdot y4\right)\right) \]
    7. Applied rewrites27.0%

      \[\leadsto b \cdot \left(t \cdot \color{blue}{\mathsf{fma}\left(-1, a \cdot z, j \cdot y4\right)}\right) \]

    if -1.25e-177 < k < 5.20000000000000013e-248

    1. Initial program 34.7%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites34.6%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in x around inf

      \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \color{blue}{\left(c \cdot y - j \cdot y1\right)}\right)\right) \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - \color{blue}{j \cdot y1}\right)\right)\right) \]
      2. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot \color{blue}{y1}\right)\right)\right) \]
      3. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right) \]
      4. lower-*.f6425.9

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right) \]
    7. Applied rewrites25.9%

      \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \color{blue}{\left(c \cdot y - j \cdot y1\right)}\right)\right) \]

    if 5.20000000000000013e-248 < k < 2.20000000000000007e-154

    1. Initial program 35.3%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y3 around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \color{blue}{\left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{y \cdot \left(c \cdot y4 - a \cdot y5\right)}\right)\right) \]
    4. Applied rewrites38.8%

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\mathsf{fma}\left(j, y1 \cdot y4 - y0 \cdot y5, z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    5. Taylor expanded in y1 around -inf

      \[\leadsto y1 \cdot \color{blue}{\left(y3 \cdot \left(-1 \cdot \left(j \cdot y4\right) + a \cdot z\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto y1 \cdot \left(y3 \cdot \color{blue}{\left(-1 \cdot \left(j \cdot y4\right) + a \cdot z\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto y1 \cdot \left(y3 \cdot \left(-1 \cdot \left(j \cdot y4\right) + \color{blue}{a \cdot z}\right)\right) \]
      3. lower-fma.f64N/A

        \[\leadsto y1 \cdot \left(y3 \cdot \mathsf{fma}\left(-1, j \cdot \color{blue}{y4}, a \cdot z\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto y1 \cdot \left(y3 \cdot \mathsf{fma}\left(-1, j \cdot y4, a \cdot z\right)\right) \]
      5. lower-*.f6425.0

        \[\leadsto y1 \cdot \left(y3 \cdot \mathsf{fma}\left(-1, j \cdot y4, a \cdot z\right)\right) \]
    7. Applied rewrites25.0%

      \[\leadsto y1 \cdot \color{blue}{\left(y3 \cdot \mathsf{fma}\left(-1, j \cdot y4, a \cdot z\right)\right)} \]
  3. Recombined 5 regimes into one program.
  4. Add Preprocessing

Alternative 11: 37.6% accurate, 2.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;c \leq -4 \cdot 10^{-10}:\\ \;\;\;\;-1 \cdot \left(y3 \cdot \left(c \cdot \left(y0 \cdot z\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)\\ \mathbf{elif}\;c \leq 1.16 \cdot 10^{+62}:\\ \;\;\;\;x \cdot \left(\mathsf{fma}\left(y, a \cdot b - c \cdot i, y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\\ \mathbf{else}:\\ \;\;\;\;-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)\right)\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (if (<= c -4e-10)
   (* -1.0 (* y3 (- (* c (* y0 z)) (* y (- (* c y4) (* a y5))))))
   (if (<= c 1.16e+62)
     (*
      x
      (-
       (fma y (- (* a b) (* c i)) (* y2 (- (* c y0) (* a y1))))
       (* j (- (* b y0) (* i y1)))))
     (*
      -1.0
      (*
       i
       (-
        (fma -1.0 (* k (* y y5)) (* c (- (* x y) (* t z))))
        (* -1.0 (* k (* y1 z)))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double tmp;
	if (c <= -4e-10) {
		tmp = -1.0 * (y3 * ((c * (y0 * z)) - (y * ((c * y4) - (a * y5)))));
	} else if (c <= 1.16e+62) {
		tmp = x * (fma(y, ((a * b) - (c * i)), (y2 * ((c * y0) - (a * y1)))) - (j * ((b * y0) - (i * y1))));
	} else {
		tmp = -1.0 * (i * (fma(-1.0, (k * (y * y5)), (c * ((x * y) - (t * z)))) - (-1.0 * (k * (y1 * z)))));
	}
	return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	tmp = 0.0
	if (c <= -4e-10)
		tmp = Float64(-1.0 * Float64(y3 * Float64(Float64(c * Float64(y0 * z)) - Float64(y * Float64(Float64(c * y4) - Float64(a * y5))))));
	elseif (c <= 1.16e+62)
		tmp = Float64(x * Float64(fma(y, Float64(Float64(a * b) - Float64(c * i)), Float64(y2 * Float64(Float64(c * y0) - Float64(a * y1)))) - Float64(j * Float64(Float64(b * y0) - Float64(i * y1)))));
	else
		tmp = Float64(-1.0 * Float64(i * Float64(fma(-1.0, Float64(k * Float64(y * y5)), Float64(c * Float64(Float64(x * y) - Float64(t * z)))) - Float64(-1.0 * Float64(k * Float64(y1 * z))))));
	end
	return tmp
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := If[LessEqual[c, -4e-10], N[(-1.0 * N[(y3 * N[(N[(c * N[(y0 * z), $MachinePrecision]), $MachinePrecision] - N[(y * N[(N[(c * y4), $MachinePrecision] - N[(a * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[c, 1.16e+62], N[(x * N[(N[(y * N[(N[(a * b), $MachinePrecision] - N[(c * i), $MachinePrecision]), $MachinePrecision] + N[(y2 * N[(N[(c * y0), $MachinePrecision] - N[(a * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(j * N[(N[(b * y0), $MachinePrecision] - N[(i * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(-1.0 * N[(i * N[(N[(-1.0 * N[(k * N[(y * y5), $MachinePrecision]), $MachinePrecision] + N[(c * N[(N[(x * y), $MachinePrecision] - N[(t * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(-1.0 * N[(k * N[(y1 * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;c \leq -4 \cdot 10^{-10}:\\
\;\;\;\;-1 \cdot \left(y3 \cdot \left(c \cdot \left(y0 \cdot z\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)\\

\mathbf{elif}\;c \leq 1.16 \cdot 10^{+62}:\\
\;\;\;\;x \cdot \left(\mathsf{fma}\left(y, a \cdot b - c \cdot i, y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)\\

\mathbf{else}:\\
\;\;\;\;-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if c < -4.00000000000000015e-10

    1. Initial program 28.0%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y3 around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \color{blue}{\left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{y \cdot \left(c \cdot y4 - a \cdot y5\right)}\right)\right) \]
    4. Applied rewrites37.0%

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\mathsf{fma}\left(j, y1 \cdot y4 - y0 \cdot y5, z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    5. Taylor expanded in c around inf

      \[\leadsto -1 \cdot \left(y3 \cdot \left(c \cdot \left(y0 \cdot z\right) - \color{blue}{y} \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right) \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \left(c \cdot \left(y0 \cdot z\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right) \]
      2. lower-*.f6437.7

        \[\leadsto -1 \cdot \left(y3 \cdot \left(c \cdot \left(y0 \cdot z\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right) \]
    7. Applied rewrites37.7%

      \[\leadsto -1 \cdot \left(y3 \cdot \left(c \cdot \left(y0 \cdot z\right) - \color{blue}{y} \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right) \]

    if -4.00000000000000015e-10 < c < 1.16e62

    1. Initial program 34.1%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in x around inf

      \[\leadsto \color{blue}{x \cdot \left(\left(y \cdot \left(a \cdot b - c \cdot i\right) + y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto x \cdot \color{blue}{\left(\left(y \cdot \left(a \cdot b - c \cdot i\right) + y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - j \cdot \left(b \cdot y0 - i \cdot y1\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto x \cdot \left(\left(y \cdot \left(a \cdot b - c \cdot i\right) + y2 \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{j \cdot \left(b \cdot y0 - i \cdot y1\right)}\right) \]
    4. Applied rewrites37.1%

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

    if 1.16e62 < c

    1. Initial program 23.4%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites39.0%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in j around 0

      \[\leadsto -1 \cdot \left(i \cdot \left(\left(-1 \cdot \left(k \cdot \left(y \cdot y5\right)\right) + c \cdot \left(x \cdot y - t \cdot z\right)\right) - \color{blue}{-1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)}\right)\right) \]
    6. Step-by-step derivation
      1. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(-1 \cdot \left(k \cdot \left(y \cdot y5\right)\right) + c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \color{blue}{\left(k \cdot \left(y1 \cdot z\right)\right)}\right)\right) \]
      2. lower-fma.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(\color{blue}{k} \cdot \left(y1 \cdot z\right)\right)\right)\right) \]
      3. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)\right)\right) \]
      5. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)\right)\right) \]
      6. lift-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)\right)\right) \]
      7. lift-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)\right)\right) \]
      8. lift--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)\right)\right) \]
      9. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \color{blue}{\left(y1 \cdot z\right)}\right)\right)\right) \]
      10. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \left(y1 \cdot \color{blue}{z}\right)\right)\right)\right) \]
      11. lower-*.f6438.6

        \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - -1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)\right)\right) \]
    7. Applied rewrites38.6%

      \[\leadsto -1 \cdot \left(i \cdot \left(\mathsf{fma}\left(-1, k \cdot \left(y \cdot y5\right), c \cdot \left(x \cdot y - t \cdot z\right)\right) - \color{blue}{-1 \cdot \left(k \cdot \left(y1 \cdot z\right)\right)}\right)\right) \]
  3. Recombined 3 regimes into one program.
  4. Add Preprocessing

Alternative 12: 28.5% accurate, 2.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := i \cdot \left(y \cdot \mathsf{fma}\left(-1, c \cdot x, k \cdot y5\right)\right)\\ t_2 := b \cdot \left(t \cdot \mathsf{fma}\left(-1, a \cdot z, j \cdot y4\right)\right)\\ \mathbf{if}\;k \leq -8.5 \cdot 10^{+209}:\\ \;\;\;\;i \cdot \left(z \cdot \left(c \cdot t - k \cdot y1\right)\right)\\ \mathbf{elif}\;k \leq -1.5 \cdot 10^{+77}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;k \leq -5.8 \cdot 10^{-170}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;k \leq 5.3 \cdot 10^{-281}:\\ \;\;\;\;i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\\ \mathbf{elif}\;k \leq 8.2 \cdot 10^{-219}:\\ \;\;\;\;y0 \cdot \left(y3 \cdot \mathsf{fma}\left(-1, c \cdot z, j \cdot y5\right)\right)\\ \mathbf{elif}\;k \leq 2.2 \cdot 10^{-154}:\\ \;\;\;\;y1 \cdot \left(y3 \cdot \mathsf{fma}\left(-1, j \cdot y4, a \cdot z\right)\right)\\ \mathbf{elif}\;k \leq 5.7 \cdot 10^{+20}:\\ \;\;\;\;t\_2\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (let* ((t_1 (* i (* y (fma -1.0 (* c x) (* k y5)))))
        (t_2 (* b (* t (fma -1.0 (* a z) (* j y4))))))
   (if (<= k -8.5e+209)
     (* i (* z (- (* c t) (* k y1))))
     (if (<= k -1.5e+77)
       t_1
       (if (<= k -5.8e-170)
         t_2
         (if (<= k 5.3e-281)
           (* i (* y1 (- (* j x) (* k z))))
           (if (<= k 8.2e-219)
             (* y0 (* y3 (fma -1.0 (* c z) (* j y5))))
             (if (<= k 2.2e-154)
               (* y1 (* y3 (fma -1.0 (* j y4) (* a z))))
               (if (<= k 5.7e+20) t_2 t_1)))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = i * (y * fma(-1.0, (c * x), (k * y5)));
	double t_2 = b * (t * fma(-1.0, (a * z), (j * y4)));
	double tmp;
	if (k <= -8.5e+209) {
		tmp = i * (z * ((c * t) - (k * y1)));
	} else if (k <= -1.5e+77) {
		tmp = t_1;
	} else if (k <= -5.8e-170) {
		tmp = t_2;
	} else if (k <= 5.3e-281) {
		tmp = i * (y1 * ((j * x) - (k * z)));
	} else if (k <= 8.2e-219) {
		tmp = y0 * (y3 * fma(-1.0, (c * z), (j * y5)));
	} else if (k <= 2.2e-154) {
		tmp = y1 * (y3 * fma(-1.0, (j * y4), (a * z)));
	} else if (k <= 5.7e+20) {
		tmp = t_2;
	} else {
		tmp = t_1;
	}
	return tmp;
}
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = Float64(i * Float64(y * fma(-1.0, Float64(c * x), Float64(k * y5))))
	t_2 = Float64(b * Float64(t * fma(-1.0, Float64(a * z), Float64(j * y4))))
	tmp = 0.0
	if (k <= -8.5e+209)
		tmp = Float64(i * Float64(z * Float64(Float64(c * t) - Float64(k * y1))));
	elseif (k <= -1.5e+77)
		tmp = t_1;
	elseif (k <= -5.8e-170)
		tmp = t_2;
	elseif (k <= 5.3e-281)
		tmp = Float64(i * Float64(y1 * Float64(Float64(j * x) - Float64(k * z))));
	elseif (k <= 8.2e-219)
		tmp = Float64(y0 * Float64(y3 * fma(-1.0, Float64(c * z), Float64(j * y5))));
	elseif (k <= 2.2e-154)
		tmp = Float64(y1 * Float64(y3 * fma(-1.0, Float64(j * y4), Float64(a * z))));
	elseif (k <= 5.7e+20)
		tmp = t_2;
	else
		tmp = t_1;
	end
	return tmp
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(i * N[(y * N[(-1.0 * N[(c * x), $MachinePrecision] + N[(k * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(b * N[(t * N[(-1.0 * N[(a * z), $MachinePrecision] + N[(j * y4), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[k, -8.5e+209], N[(i * N[(z * N[(N[(c * t), $MachinePrecision] - N[(k * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, -1.5e+77], t$95$1, If[LessEqual[k, -5.8e-170], t$95$2, If[LessEqual[k, 5.3e-281], N[(i * N[(y1 * N[(N[(j * x), $MachinePrecision] - N[(k * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 8.2e-219], N[(y0 * N[(y3 * N[(-1.0 * N[(c * z), $MachinePrecision] + N[(j * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 2.2e-154], N[(y1 * N[(y3 * N[(-1.0 * N[(j * y4), $MachinePrecision] + N[(a * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[k, 5.7e+20], t$95$2, t$95$1]]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := i \cdot \left(y \cdot \mathsf{fma}\left(-1, c \cdot x, k \cdot y5\right)\right)\\
t_2 := b \cdot \left(t \cdot \mathsf{fma}\left(-1, a \cdot z, j \cdot y4\right)\right)\\
\mathbf{if}\;k \leq -8.5 \cdot 10^{+209}:\\
\;\;\;\;i \cdot \left(z \cdot \left(c \cdot t - k \cdot y1\right)\right)\\

\mathbf{elif}\;k \leq -1.5 \cdot 10^{+77}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;k \leq -5.8 \cdot 10^{-170}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;k \leq 5.3 \cdot 10^{-281}:\\
\;\;\;\;i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\\

\mathbf{elif}\;k \leq 8.2 \cdot 10^{-219}:\\
\;\;\;\;y0 \cdot \left(y3 \cdot \mathsf{fma}\left(-1, c \cdot z, j \cdot y5\right)\right)\\

\mathbf{elif}\;k \leq 2.2 \cdot 10^{-154}:\\
\;\;\;\;y1 \cdot \left(y3 \cdot \mathsf{fma}\left(-1, j \cdot y4, a \cdot z\right)\right)\\

\mathbf{elif}\;k \leq 5.7 \cdot 10^{+20}:\\
\;\;\;\;t\_2\\

\mathbf{else}:\\
\;\;\;\;t\_1\\


\end{array}
\end{array}
Derivation
  1. Split input into 6 regimes
  2. if k < -8.50000000000000062e209

    1. Initial program 22.2%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites35.9%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in z around -inf

      \[\leadsto i \cdot \color{blue}{\left(z \cdot \left(c \cdot t - k \cdot y1\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \color{blue}{\left(c \cdot t - k \cdot y1\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - \color{blue}{k \cdot y1}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot \color{blue}{y1}\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot y1\right)\right) \]
      5. lower-*.f6438.8

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot y1\right)\right) \]
    7. Applied rewrites38.8%

      \[\leadsto i \cdot \color{blue}{\left(z \cdot \left(c \cdot t - k \cdot y1\right)\right)} \]

    if -8.50000000000000062e209 < k < -1.4999999999999999e77 or 5.7e20 < k

    1. Initial program 25.5%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites37.3%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in y around -inf

      \[\leadsto i \cdot \color{blue}{\left(y \cdot \left(-1 \cdot \left(c \cdot x\right) + k \cdot y5\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \color{blue}{\left(-1 \cdot \left(c \cdot x\right) + k \cdot y5\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot x\right) + \color{blue}{k \cdot y5}\right)\right) \]
      3. lower-fma.f64N/A

        \[\leadsto i \cdot \left(y \cdot \mathsf{fma}\left(-1, c \cdot \color{blue}{x}, k \cdot y5\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \mathsf{fma}\left(-1, c \cdot x, k \cdot y5\right)\right) \]
      5. lower-*.f6432.4

        \[\leadsto i \cdot \left(y \cdot \mathsf{fma}\left(-1, c \cdot x, k \cdot y5\right)\right) \]
    7. Applied rewrites32.4%

      \[\leadsto i \cdot \color{blue}{\left(y \cdot \mathsf{fma}\left(-1, c \cdot x, k \cdot y5\right)\right)} \]

    if -1.4999999999999999e77 < k < -5.8000000000000001e-170 or 2.20000000000000007e-154 < k < 5.7e20

    1. Initial program 34.3%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in b around inf

      \[\leadsto \color{blue}{b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto b \cdot \color{blue}{\left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y0 \cdot \left(j \cdot x - k \cdot z\right)}\right) \]
    4. Applied rewrites37.7%

      \[\leadsto \color{blue}{b \cdot \left(\mathsf{fma}\left(a, x \cdot y - t \cdot z, y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    5. Taylor expanded in t around inf

      \[\leadsto b \cdot \left(t \cdot \color{blue}{\left(-1 \cdot \left(a \cdot z\right) + j \cdot y4\right)}\right) \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto b \cdot \left(t \cdot \left(-1 \cdot \left(a \cdot z\right) + \color{blue}{j \cdot y4}\right)\right) \]
      2. lower-fma.f64N/A

        \[\leadsto b \cdot \left(t \cdot \mathsf{fma}\left(-1, a \cdot \color{blue}{z}, j \cdot y4\right)\right) \]
      3. lower-*.f64N/A

        \[\leadsto b \cdot \left(t \cdot \mathsf{fma}\left(-1, a \cdot z, j \cdot y4\right)\right) \]
      4. lower-*.f6426.9

        \[\leadsto b \cdot \left(t \cdot \mathsf{fma}\left(-1, a \cdot z, j \cdot y4\right)\right) \]
    7. Applied rewrites26.9%

      \[\leadsto b \cdot \left(t \cdot \color{blue}{\mathsf{fma}\left(-1, a \cdot z, j \cdot y4\right)}\right) \]

    if -5.8000000000000001e-170 < k < 5.29999999999999995e-281

    1. Initial program 34.4%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites34.8%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in y1 around -inf

      \[\leadsto i \cdot \color{blue}{\left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \color{blue}{\left(j \cdot x - k \cdot z\right)}\right) \]
      2. lift-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right) \]
      3. lift-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right) \]
      4. lift--.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot \color{blue}{z}\right)\right) \]
      5. lift-*.f6417.0

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - \color{blue}{k \cdot z}\right)\right) \]
    7. Applied rewrites17.0%

      \[\leadsto i \cdot \color{blue}{\left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]

    if 5.29999999999999995e-281 < k < 8.2e-219

    1. Initial program 37.1%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y3 around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \color{blue}{\left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{y \cdot \left(c \cdot y4 - a \cdot y5\right)}\right)\right) \]
    4. Applied rewrites38.9%

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\mathsf{fma}\left(j, y1 \cdot y4 - y0 \cdot y5, z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    5. Taylor expanded in y0 around -inf

      \[\leadsto y0 \cdot \color{blue}{\left(y3 \cdot \left(-1 \cdot \left(c \cdot z\right) + j \cdot y5\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto y0 \cdot \left(y3 \cdot \color{blue}{\left(-1 \cdot \left(c \cdot z\right) + j \cdot y5\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto y0 \cdot \left(y3 \cdot \left(-1 \cdot \left(c \cdot z\right) + \color{blue}{j \cdot y5}\right)\right) \]
      3. lower-fma.f64N/A

        \[\leadsto y0 \cdot \left(y3 \cdot \mathsf{fma}\left(-1, c \cdot \color{blue}{z}, j \cdot y5\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto y0 \cdot \left(y3 \cdot \mathsf{fma}\left(-1, c \cdot z, j \cdot y5\right)\right) \]
      5. lower-*.f6428.2

        \[\leadsto y0 \cdot \left(y3 \cdot \mathsf{fma}\left(-1, c \cdot z, j \cdot y5\right)\right) \]
    7. Applied rewrites28.2%

      \[\leadsto y0 \cdot \color{blue}{\left(y3 \cdot \mathsf{fma}\left(-1, c \cdot z, j \cdot y5\right)\right)} \]

    if 8.2e-219 < k < 2.20000000000000007e-154

    1. Initial program 33.9%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y3 around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \color{blue}{\left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{y \cdot \left(c \cdot y4 - a \cdot y5\right)}\right)\right) \]
    4. Applied rewrites37.4%

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\mathsf{fma}\left(j, y1 \cdot y4 - y0 \cdot y5, z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    5. Taylor expanded in y1 around -inf

      \[\leadsto y1 \cdot \color{blue}{\left(y3 \cdot \left(-1 \cdot \left(j \cdot y4\right) + a \cdot z\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto y1 \cdot \left(y3 \cdot \color{blue}{\left(-1 \cdot \left(j \cdot y4\right) + a \cdot z\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto y1 \cdot \left(y3 \cdot \left(-1 \cdot \left(j \cdot y4\right) + \color{blue}{a \cdot z}\right)\right) \]
      3. lower-fma.f64N/A

        \[\leadsto y1 \cdot \left(y3 \cdot \mathsf{fma}\left(-1, j \cdot \color{blue}{y4}, a \cdot z\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto y1 \cdot \left(y3 \cdot \mathsf{fma}\left(-1, j \cdot y4, a \cdot z\right)\right) \]
      5. lower-*.f6425.6

        \[\leadsto y1 \cdot \left(y3 \cdot \mathsf{fma}\left(-1, j \cdot y4, a \cdot z\right)\right) \]
    7. Applied rewrites25.6%

      \[\leadsto y1 \cdot \color{blue}{\left(y3 \cdot \mathsf{fma}\left(-1, j \cdot y4, a \cdot z\right)\right)} \]
  3. Recombined 6 regimes into one program.
  4. Add Preprocessing

Alternative 13: 29.8% accurate, 3.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := b \cdot \left(y4 \cdot \left(t \cdot \left(j + -1 \cdot \frac{k \cdot y}{t}\right)\right)\right)\\ \mathbf{if}\;y1 \leq -1.2 \cdot 10^{-55}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y1 \leq -9.2 \cdot 10^{-269}:\\ \;\;\;\;t \cdot \left(c \cdot \left(i \cdot z - y2 \cdot y4\right)\right)\\ \mathbf{elif}\;y1 \leq 6.2 \cdot 10^{-211}:\\ \;\;\;\;-1 \cdot \left(y3 \cdot \left(c \cdot \left(y0 \cdot z\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)\\ \mathbf{elif}\;y1 \leq 7.6 \cdot 10^{-11}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y1 \leq 4.5 \cdot 10^{+82}:\\ \;\;\;\;y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)\\ \mathbf{else}:\\ \;\;\;\;-1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (let* ((t_1 (* b (* y4 (* t (+ j (* -1.0 (/ (* k y) t))))))))
   (if (<= y1 -1.2e-55)
     t_1
     (if (<= y1 -9.2e-269)
       (* t (* c (- (* i z) (* y2 y4))))
       (if (<= y1 6.2e-211)
         (* -1.0 (* y3 (- (* c (* y0 z)) (* y (- (* c y4) (* a y5))))))
         (if (<= y1 7.6e-11)
           t_1
           (if (<= y1 4.5e+82)
             (* y3 (* y5 (- (* j y0) (* a y))))
             (* -1.0 (* i (* x (- (* c y) (* j y1))))))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = b * (y4 * (t * (j + (-1.0 * ((k * y) / t)))));
	double tmp;
	if (y1 <= -1.2e-55) {
		tmp = t_1;
	} else if (y1 <= -9.2e-269) {
		tmp = t * (c * ((i * z) - (y2 * y4)));
	} else if (y1 <= 6.2e-211) {
		tmp = -1.0 * (y3 * ((c * (y0 * z)) - (y * ((c * y4) - (a * y5)))));
	} else if (y1 <= 7.6e-11) {
		tmp = t_1;
	} else if (y1 <= 4.5e+82) {
		tmp = y3 * (y5 * ((j * y0) - (a * y)));
	} else {
		tmp = -1.0 * (i * (x * ((c * y) - (j * y1))));
	}
	return tmp;
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8), intent (in) :: y0
    real(8), intent (in) :: y1
    real(8), intent (in) :: y2
    real(8), intent (in) :: y3
    real(8), intent (in) :: y4
    real(8), intent (in) :: y5
    real(8) :: t_1
    real(8) :: tmp
    t_1 = b * (y4 * (t * (j + ((-1.0d0) * ((k * y) / t)))))
    if (y1 <= (-1.2d-55)) then
        tmp = t_1
    else if (y1 <= (-9.2d-269)) then
        tmp = t * (c * ((i * z) - (y2 * y4)))
    else if (y1 <= 6.2d-211) then
        tmp = (-1.0d0) * (y3 * ((c * (y0 * z)) - (y * ((c * y4) - (a * y5)))))
    else if (y1 <= 7.6d-11) then
        tmp = t_1
    else if (y1 <= 4.5d+82) then
        tmp = y3 * (y5 * ((j * y0) - (a * y)))
    else
        tmp = (-1.0d0) * (i * (x * ((c * y) - (j * y1))))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = b * (y4 * (t * (j + (-1.0 * ((k * y) / t)))));
	double tmp;
	if (y1 <= -1.2e-55) {
		tmp = t_1;
	} else if (y1 <= -9.2e-269) {
		tmp = t * (c * ((i * z) - (y2 * y4)));
	} else if (y1 <= 6.2e-211) {
		tmp = -1.0 * (y3 * ((c * (y0 * z)) - (y * ((c * y4) - (a * y5)))));
	} else if (y1 <= 7.6e-11) {
		tmp = t_1;
	} else if (y1 <= 4.5e+82) {
		tmp = y3 * (y5 * ((j * y0) - (a * y)));
	} else {
		tmp = -1.0 * (i * (x * ((c * y) - (j * y1))));
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5):
	t_1 = b * (y4 * (t * (j + (-1.0 * ((k * y) / t)))))
	tmp = 0
	if y1 <= -1.2e-55:
		tmp = t_1
	elif y1 <= -9.2e-269:
		tmp = t * (c * ((i * z) - (y2 * y4)))
	elif y1 <= 6.2e-211:
		tmp = -1.0 * (y3 * ((c * (y0 * z)) - (y * ((c * y4) - (a * y5)))))
	elif y1 <= 7.6e-11:
		tmp = t_1
	elif y1 <= 4.5e+82:
		tmp = y3 * (y5 * ((j * y0) - (a * y)))
	else:
		tmp = -1.0 * (i * (x * ((c * y) - (j * y1))))
	return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = Float64(b * Float64(y4 * Float64(t * Float64(j + Float64(-1.0 * Float64(Float64(k * y) / t))))))
	tmp = 0.0
	if (y1 <= -1.2e-55)
		tmp = t_1;
	elseif (y1 <= -9.2e-269)
		tmp = Float64(t * Float64(c * Float64(Float64(i * z) - Float64(y2 * y4))));
	elseif (y1 <= 6.2e-211)
		tmp = Float64(-1.0 * Float64(y3 * Float64(Float64(c * Float64(y0 * z)) - Float64(y * Float64(Float64(c * y4) - Float64(a * y5))))));
	elseif (y1 <= 7.6e-11)
		tmp = t_1;
	elseif (y1 <= 4.5e+82)
		tmp = Float64(y3 * Float64(y5 * Float64(Float64(j * y0) - Float64(a * y))));
	else
		tmp = Float64(-1.0 * Float64(i * Float64(x * Float64(Float64(c * y) - Float64(j * y1)))));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = b * (y4 * (t * (j + (-1.0 * ((k * y) / t)))));
	tmp = 0.0;
	if (y1 <= -1.2e-55)
		tmp = t_1;
	elseif (y1 <= -9.2e-269)
		tmp = t * (c * ((i * z) - (y2 * y4)));
	elseif (y1 <= 6.2e-211)
		tmp = -1.0 * (y3 * ((c * (y0 * z)) - (y * ((c * y4) - (a * y5)))));
	elseif (y1 <= 7.6e-11)
		tmp = t_1;
	elseif (y1 <= 4.5e+82)
		tmp = y3 * (y5 * ((j * y0) - (a * y)));
	else
		tmp = -1.0 * (i * (x * ((c * y) - (j * y1))));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(b * N[(y4 * N[(t * N[(j + N[(-1.0 * N[(N[(k * y), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y1, -1.2e-55], t$95$1, If[LessEqual[y1, -9.2e-269], N[(t * N[(c * N[(N[(i * z), $MachinePrecision] - N[(y2 * y4), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y1, 6.2e-211], N[(-1.0 * N[(y3 * N[(N[(c * N[(y0 * z), $MachinePrecision]), $MachinePrecision] - N[(y * N[(N[(c * y4), $MachinePrecision] - N[(a * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y1, 7.6e-11], t$95$1, If[LessEqual[y1, 4.5e+82], N[(y3 * N[(y5 * N[(N[(j * y0), $MachinePrecision] - N[(a * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(-1.0 * N[(i * N[(x * N[(N[(c * y), $MachinePrecision] - N[(j * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := b \cdot \left(y4 \cdot \left(t \cdot \left(j + -1 \cdot \frac{k \cdot y}{t}\right)\right)\right)\\
\mathbf{if}\;y1 \leq -1.2 \cdot 10^{-55}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;y1 \leq -9.2 \cdot 10^{-269}:\\
\;\;\;\;t \cdot \left(c \cdot \left(i \cdot z - y2 \cdot y4\right)\right)\\

\mathbf{elif}\;y1 \leq 6.2 \cdot 10^{-211}:\\
\;\;\;\;-1 \cdot \left(y3 \cdot \left(c \cdot \left(y0 \cdot z\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)\\

\mathbf{elif}\;y1 \leq 7.6 \cdot 10^{-11}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;y1 \leq 4.5 \cdot 10^{+82}:\\
\;\;\;\;y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)\\

\mathbf{else}:\\
\;\;\;\;-1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if y1 < -1.19999999999999996e-55 or 6.1999999999999999e-211 < y1 < 7.5999999999999996e-11

    1. Initial program 29.5%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in b around inf

      \[\leadsto \color{blue}{b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto b \cdot \color{blue}{\left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y0 \cdot \left(j \cdot x - k \cdot z\right)}\right) \]
    4. Applied rewrites37.0%

      \[\leadsto \color{blue}{b \cdot \left(\mathsf{fma}\left(a, x \cdot y - t \cdot z, y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    5. Taylor expanded in y4 around inf

      \[\leadsto b \cdot \left(y4 \cdot \color{blue}{\left(j \cdot t - k \cdot y\right)}\right) \]
    6. Step-by-step derivation
      1. lift-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot y\right)\right) \]
      2. lift-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot y\right)\right) \]
      3. lift--.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot \color{blue}{y}\right)\right) \]
      4. lift-*.f6426.6

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - \color{blue}{k \cdot y}\right)\right) \]
    7. Applied rewrites26.6%

      \[\leadsto b \cdot \left(y4 \cdot \color{blue}{\left(j \cdot t - k \cdot y\right)}\right) \]
    8. Taylor expanded in t around inf

      \[\leadsto b \cdot \left(y4 \cdot \left(t \cdot \left(j + \color{blue}{-1 \cdot \frac{k \cdot y}{t}}\right)\right)\right) \]
    9. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(t \cdot \left(j + -1 \cdot \color{blue}{\frac{k \cdot y}{t}}\right)\right)\right) \]
      2. lower-+.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(t \cdot \left(j + -1 \cdot \frac{k \cdot y}{\color{blue}{t}}\right)\right)\right) \]
      3. lower-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(t \cdot \left(j + -1 \cdot \frac{k \cdot y}{t}\right)\right)\right) \]
      4. lower-/.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(t \cdot \left(j + -1 \cdot \frac{k \cdot y}{t}\right)\right)\right) \]
      5. lift-*.f6428.7

        \[\leadsto b \cdot \left(y4 \cdot \left(t \cdot \left(j + -1 \cdot \frac{k \cdot y}{t}\right)\right)\right) \]
    10. Applied rewrites28.7%

      \[\leadsto b \cdot \left(y4 \cdot \left(t \cdot \left(j + \color{blue}{-1 \cdot \frac{k \cdot y}{t}}\right)\right)\right) \]

    if -1.19999999999999996e-55 < y1 < -9.1999999999999999e-269

    1. Initial program 35.6%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in t around inf

      \[\leadsto \color{blue}{t \cdot \left(\left(-1 \cdot \left(z \cdot \left(a \cdot b - c \cdot i\right)\right) + j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - y2 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto t \cdot \color{blue}{\left(\left(-1 \cdot \left(z \cdot \left(a \cdot b - c \cdot i\right)\right) + j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - y2 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto t \cdot \left(\left(-1 \cdot \left(z \cdot \left(a \cdot b - c \cdot i\right)\right) + j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - \color{blue}{y2 \cdot \left(c \cdot y4 - a \cdot y5\right)}\right) \]
    4. Applied rewrites40.2%

      \[\leadsto \color{blue}{t \cdot \left(\mathsf{fma}\left(-1, z \cdot \left(a \cdot b - c \cdot i\right), j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - y2 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
    5. Taylor expanded in c around inf

      \[\leadsto t \cdot \left(c \cdot \color{blue}{\left(i \cdot z - y2 \cdot y4\right)}\right) \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto t \cdot \left(c \cdot \left(i \cdot z - \color{blue}{y2 \cdot y4}\right)\right) \]
      2. lower--.f64N/A

        \[\leadsto t \cdot \left(c \cdot \left(i \cdot z - y2 \cdot \color{blue}{y4}\right)\right) \]
      3. lower-*.f64N/A

        \[\leadsto t \cdot \left(c \cdot \left(i \cdot z - y2 \cdot y4\right)\right) \]
      4. lower-*.f6425.4

        \[\leadsto t \cdot \left(c \cdot \left(i \cdot z - y2 \cdot y4\right)\right) \]
    7. Applied rewrites25.4%

      \[\leadsto t \cdot \left(c \cdot \color{blue}{\left(i \cdot z - y2 \cdot y4\right)}\right) \]

    if -9.1999999999999999e-269 < y1 < 6.1999999999999999e-211

    1. Initial program 38.4%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y3 around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \color{blue}{\left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{y \cdot \left(c \cdot y4 - a \cdot y5\right)}\right)\right) \]
    4. Applied rewrites36.4%

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\mathsf{fma}\left(j, y1 \cdot y4 - y0 \cdot y5, z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    5. Taylor expanded in c around inf

      \[\leadsto -1 \cdot \left(y3 \cdot \left(c \cdot \left(y0 \cdot z\right) - \color{blue}{y} \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right) \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \left(c \cdot \left(y0 \cdot z\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right) \]
      2. lower-*.f6433.1

        \[\leadsto -1 \cdot \left(y3 \cdot \left(c \cdot \left(y0 \cdot z\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right) \]
    7. Applied rewrites33.1%

      \[\leadsto -1 \cdot \left(y3 \cdot \left(c \cdot \left(y0 \cdot z\right) - \color{blue}{y} \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right) \]

    if 7.5999999999999996e-11 < y1 < 4.4999999999999997e82

    1. Initial program 30.9%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y3 around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \color{blue}{\left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{y \cdot \left(c \cdot y4 - a \cdot y5\right)}\right)\right) \]
    4. Applied rewrites39.7%

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\mathsf{fma}\left(j, y1 \cdot y4 - y0 \cdot y5, z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    5. Taylor expanded in y5 around -inf

      \[\leadsto y3 \cdot \color{blue}{\left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \color{blue}{\left(j \cdot y0 - a \cdot y\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - \color{blue}{a \cdot y}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot \color{blue}{y}\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right) \]
      5. lower-*.f6428.2

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right) \]
    7. Applied rewrites28.2%

      \[\leadsto y3 \cdot \color{blue}{\left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)} \]

    if 4.4999999999999997e82 < y1

    1. Initial program 22.6%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites39.6%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in x around inf

      \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \color{blue}{\left(c \cdot y - j \cdot y1\right)}\right)\right) \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - \color{blue}{j \cdot y1}\right)\right)\right) \]
      2. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot \color{blue}{y1}\right)\right)\right) \]
      3. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right) \]
      4. lower-*.f6435.7

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right) \]
    7. Applied rewrites35.7%

      \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \color{blue}{\left(c \cdot y - j \cdot y1\right)}\right)\right) \]
  3. Recombined 5 regimes into one program.
  4. Add Preprocessing

Alternative 14: 32.0% accurate, 3.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\\ \mathbf{if}\;y1 \leq -1 \cdot 10^{+25}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y1 \leq -2.8 \cdot 10^{-64}:\\ \;\;\;\;j \cdot \left(t \cdot \left(b \cdot y4 - i \cdot y5\right)\right)\\ \mathbf{elif}\;y1 \leq 2.9 \cdot 10^{-181}:\\ \;\;\;\;t \cdot \left(c \cdot \left(i \cdot z - y2 \cdot y4\right)\right)\\ \mathbf{elif}\;y1 \leq 7.6 \cdot 10^{-23}:\\ \;\;\;\;b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot y\right)\right)\\ \mathbf{elif}\;y1 \leq 5.6 \cdot 10^{+88}:\\ \;\;\;\;y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (let* ((t_1 (* i (* y1 (- (* j x) (* k z))))))
   (if (<= y1 -1e+25)
     t_1
     (if (<= y1 -2.8e-64)
       (* j (* t (- (* b y4) (* i y5))))
       (if (<= y1 2.9e-181)
         (* t (* c (- (* i z) (* y2 y4))))
         (if (<= y1 7.6e-23)
           (* b (* y4 (- (* j t) (* k y))))
           (if (<= y1 5.6e+88) (* y3 (* y5 (- (* j y0) (* a y)))) t_1)))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = i * (y1 * ((j * x) - (k * z)));
	double tmp;
	if (y1 <= -1e+25) {
		tmp = t_1;
	} else if (y1 <= -2.8e-64) {
		tmp = j * (t * ((b * y4) - (i * y5)));
	} else if (y1 <= 2.9e-181) {
		tmp = t * (c * ((i * z) - (y2 * y4)));
	} else if (y1 <= 7.6e-23) {
		tmp = b * (y4 * ((j * t) - (k * y)));
	} else if (y1 <= 5.6e+88) {
		tmp = y3 * (y5 * ((j * y0) - (a * y)));
	} else {
		tmp = t_1;
	}
	return tmp;
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8), intent (in) :: y0
    real(8), intent (in) :: y1
    real(8), intent (in) :: y2
    real(8), intent (in) :: y3
    real(8), intent (in) :: y4
    real(8), intent (in) :: y5
    real(8) :: t_1
    real(8) :: tmp
    t_1 = i * (y1 * ((j * x) - (k * z)))
    if (y1 <= (-1d+25)) then
        tmp = t_1
    else if (y1 <= (-2.8d-64)) then
        tmp = j * (t * ((b * y4) - (i * y5)))
    else if (y1 <= 2.9d-181) then
        tmp = t * (c * ((i * z) - (y2 * y4)))
    else if (y1 <= 7.6d-23) then
        tmp = b * (y4 * ((j * t) - (k * y)))
    else if (y1 <= 5.6d+88) then
        tmp = y3 * (y5 * ((j * y0) - (a * y)))
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = i * (y1 * ((j * x) - (k * z)));
	double tmp;
	if (y1 <= -1e+25) {
		tmp = t_1;
	} else if (y1 <= -2.8e-64) {
		tmp = j * (t * ((b * y4) - (i * y5)));
	} else if (y1 <= 2.9e-181) {
		tmp = t * (c * ((i * z) - (y2 * y4)));
	} else if (y1 <= 7.6e-23) {
		tmp = b * (y4 * ((j * t) - (k * y)));
	} else if (y1 <= 5.6e+88) {
		tmp = y3 * (y5 * ((j * y0) - (a * y)));
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5):
	t_1 = i * (y1 * ((j * x) - (k * z)))
	tmp = 0
	if y1 <= -1e+25:
		tmp = t_1
	elif y1 <= -2.8e-64:
		tmp = j * (t * ((b * y4) - (i * y5)))
	elif y1 <= 2.9e-181:
		tmp = t * (c * ((i * z) - (y2 * y4)))
	elif y1 <= 7.6e-23:
		tmp = b * (y4 * ((j * t) - (k * y)))
	elif y1 <= 5.6e+88:
		tmp = y3 * (y5 * ((j * y0) - (a * y)))
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = Float64(i * Float64(y1 * Float64(Float64(j * x) - Float64(k * z))))
	tmp = 0.0
	if (y1 <= -1e+25)
		tmp = t_1;
	elseif (y1 <= -2.8e-64)
		tmp = Float64(j * Float64(t * Float64(Float64(b * y4) - Float64(i * y5))));
	elseif (y1 <= 2.9e-181)
		tmp = Float64(t * Float64(c * Float64(Float64(i * z) - Float64(y2 * y4))));
	elseif (y1 <= 7.6e-23)
		tmp = Float64(b * Float64(y4 * Float64(Float64(j * t) - Float64(k * y))));
	elseif (y1 <= 5.6e+88)
		tmp = Float64(y3 * Float64(y5 * Float64(Float64(j * y0) - Float64(a * y))));
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = i * (y1 * ((j * x) - (k * z)));
	tmp = 0.0;
	if (y1 <= -1e+25)
		tmp = t_1;
	elseif (y1 <= -2.8e-64)
		tmp = j * (t * ((b * y4) - (i * y5)));
	elseif (y1 <= 2.9e-181)
		tmp = t * (c * ((i * z) - (y2 * y4)));
	elseif (y1 <= 7.6e-23)
		tmp = b * (y4 * ((j * t) - (k * y)));
	elseif (y1 <= 5.6e+88)
		tmp = y3 * (y5 * ((j * y0) - (a * y)));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(i * N[(y1 * N[(N[(j * x), $MachinePrecision] - N[(k * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y1, -1e+25], t$95$1, If[LessEqual[y1, -2.8e-64], N[(j * N[(t * N[(N[(b * y4), $MachinePrecision] - N[(i * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y1, 2.9e-181], N[(t * N[(c * N[(N[(i * z), $MachinePrecision] - N[(y2 * y4), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y1, 7.6e-23], N[(b * N[(y4 * N[(N[(j * t), $MachinePrecision] - N[(k * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y1, 5.6e+88], N[(y3 * N[(y5 * N[(N[(j * y0), $MachinePrecision] - N[(a * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\\
\mathbf{if}\;y1 \leq -1 \cdot 10^{+25}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;y1 \leq -2.8 \cdot 10^{-64}:\\
\;\;\;\;j \cdot \left(t \cdot \left(b \cdot y4 - i \cdot y5\right)\right)\\

\mathbf{elif}\;y1 \leq 2.9 \cdot 10^{-181}:\\
\;\;\;\;t \cdot \left(c \cdot \left(i \cdot z - y2 \cdot y4\right)\right)\\

\mathbf{elif}\;y1 \leq 7.6 \cdot 10^{-23}:\\
\;\;\;\;b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot y\right)\right)\\

\mathbf{elif}\;y1 \leq 5.6 \cdot 10^{+88}:\\
\;\;\;\;y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)\\

\mathbf{else}:\\
\;\;\;\;t\_1\\


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if y1 < -1.00000000000000009e25 or 5.59999999999999977e88 < y1

    1. Initial program 24.5%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites39.4%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in y1 around -inf

      \[\leadsto i \cdot \color{blue}{\left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \color{blue}{\left(j \cdot x - k \cdot z\right)}\right) \]
      2. lift-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right) \]
      3. lift-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right) \]
      4. lift--.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot \color{blue}{z}\right)\right) \]
      5. lift-*.f6440.2

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - \color{blue}{k \cdot z}\right)\right) \]
    7. Applied rewrites40.2%

      \[\leadsto i \cdot \color{blue}{\left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]

    if -1.00000000000000009e25 < y1 < -2.80000000000000004e-64

    1. Initial program 30.6%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in t around inf

      \[\leadsto \color{blue}{t \cdot \left(\left(-1 \cdot \left(z \cdot \left(a \cdot b - c \cdot i\right)\right) + j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - y2 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto t \cdot \color{blue}{\left(\left(-1 \cdot \left(z \cdot \left(a \cdot b - c \cdot i\right)\right) + j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - y2 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto t \cdot \left(\left(-1 \cdot \left(z \cdot \left(a \cdot b - c \cdot i\right)\right) + j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - \color{blue}{y2 \cdot \left(c \cdot y4 - a \cdot y5\right)}\right) \]
    4. Applied rewrites34.1%

      \[\leadsto \color{blue}{t \cdot \left(\mathsf{fma}\left(-1, z \cdot \left(a \cdot b - c \cdot i\right), j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - y2 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
    5. Taylor expanded in j around inf

      \[\leadsto j \cdot \color{blue}{\left(t \cdot \left(b \cdot y4 - i \cdot y5\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto j \cdot \left(t \cdot \color{blue}{\left(b \cdot y4 - i \cdot y5\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto j \cdot \left(t \cdot \left(b \cdot y4 - \color{blue}{i \cdot y5}\right)\right) \]
      3. lift-*.f64N/A

        \[\leadsto j \cdot \left(t \cdot \left(b \cdot y4 - i \cdot y5\right)\right) \]
      4. lift-*.f64N/A

        \[\leadsto j \cdot \left(t \cdot \left(b \cdot y4 - i \cdot y5\right)\right) \]
      5. lift--.f6426.3

        \[\leadsto j \cdot \left(t \cdot \left(b \cdot y4 - i \cdot \color{blue}{y5}\right)\right) \]
    7. Applied rewrites26.3%

      \[\leadsto j \cdot \color{blue}{\left(t \cdot \left(b \cdot y4 - i \cdot y5\right)\right)} \]

    if -2.80000000000000004e-64 < y1 < 2.8999999999999998e-181

    1. Initial program 36.7%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in t around inf

      \[\leadsto \color{blue}{t \cdot \left(\left(-1 \cdot \left(z \cdot \left(a \cdot b - c \cdot i\right)\right) + j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - y2 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto t \cdot \color{blue}{\left(\left(-1 \cdot \left(z \cdot \left(a \cdot b - c \cdot i\right)\right) + j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - y2 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto t \cdot \left(\left(-1 \cdot \left(z \cdot \left(a \cdot b - c \cdot i\right)\right) + j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - \color{blue}{y2 \cdot \left(c \cdot y4 - a \cdot y5\right)}\right) \]
    4. Applied rewrites39.7%

      \[\leadsto \color{blue}{t \cdot \left(\mathsf{fma}\left(-1, z \cdot \left(a \cdot b - c \cdot i\right), j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - y2 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
    5. Taylor expanded in c around inf

      \[\leadsto t \cdot \left(c \cdot \color{blue}{\left(i \cdot z - y2 \cdot y4\right)}\right) \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto t \cdot \left(c \cdot \left(i \cdot z - \color{blue}{y2 \cdot y4}\right)\right) \]
      2. lower--.f64N/A

        \[\leadsto t \cdot \left(c \cdot \left(i \cdot z - y2 \cdot \color{blue}{y4}\right)\right) \]
      3. lower-*.f64N/A

        \[\leadsto t \cdot \left(c \cdot \left(i \cdot z - y2 \cdot y4\right)\right) \]
      4. lower-*.f6426.6

        \[\leadsto t \cdot \left(c \cdot \left(i \cdot z - y2 \cdot y4\right)\right) \]
    7. Applied rewrites26.6%

      \[\leadsto t \cdot \left(c \cdot \color{blue}{\left(i \cdot z - y2 \cdot y4\right)}\right) \]

    if 2.8999999999999998e-181 < y1 < 7.60000000000000023e-23

    1. Initial program 33.9%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in b around inf

      \[\leadsto \color{blue}{b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto b \cdot \color{blue}{\left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y0 \cdot \left(j \cdot x - k \cdot z\right)}\right) \]
    4. Applied rewrites37.6%

      \[\leadsto \color{blue}{b \cdot \left(\mathsf{fma}\left(a, x \cdot y - t \cdot z, y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    5. Taylor expanded in y4 around inf

      \[\leadsto b \cdot \left(y4 \cdot \color{blue}{\left(j \cdot t - k \cdot y\right)}\right) \]
    6. Step-by-step derivation
      1. lift-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot y\right)\right) \]
      2. lift-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot y\right)\right) \]
      3. lift--.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot \color{blue}{y}\right)\right) \]
      4. lift-*.f6425.5

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - \color{blue}{k \cdot y}\right)\right) \]
    7. Applied rewrites25.5%

      \[\leadsto b \cdot \left(y4 \cdot \color{blue}{\left(j \cdot t - k \cdot y\right)}\right) \]

    if 7.60000000000000023e-23 < y1 < 5.59999999999999977e88

    1. Initial program 30.9%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y3 around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \color{blue}{\left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{y \cdot \left(c \cdot y4 - a \cdot y5\right)}\right)\right) \]
    4. Applied rewrites38.3%

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\mathsf{fma}\left(j, y1 \cdot y4 - y0 \cdot y5, z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    5. Taylor expanded in y5 around -inf

      \[\leadsto y3 \cdot \color{blue}{\left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \color{blue}{\left(j \cdot y0 - a \cdot y\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - \color{blue}{a \cdot y}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot \color{blue}{y}\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right) \]
      5. lower-*.f6427.7

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right) \]
    7. Applied rewrites27.7%

      \[\leadsto y3 \cdot \color{blue}{\left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)} \]
  3. Recombined 5 regimes into one program.
  4. Add Preprocessing

Alternative 15: 32.3% accurate, 3.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\\ \mathbf{if}\;y1 \leq -1 \cdot 10^{+25}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y1 \leq -3 \cdot 10^{-64}:\\ \;\;\;\;j \cdot \left(t \cdot \left(b \cdot y4 - i \cdot y5\right)\right)\\ \mathbf{elif}\;y1 \leq 8.8 \cdot 10^{-153}:\\ \;\;\;\;c \cdot \left(t \cdot \left(i \cdot z - y2 \cdot y4\right)\right)\\ \mathbf{elif}\;y1 \leq 7.6 \cdot 10^{-23}:\\ \;\;\;\;b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot y\right)\right)\\ \mathbf{elif}\;y1 \leq 5.6 \cdot 10^{+88}:\\ \;\;\;\;y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (let* ((t_1 (* i (* y1 (- (* j x) (* k z))))))
   (if (<= y1 -1e+25)
     t_1
     (if (<= y1 -3e-64)
       (* j (* t (- (* b y4) (* i y5))))
       (if (<= y1 8.8e-153)
         (* c (* t (- (* i z) (* y2 y4))))
         (if (<= y1 7.6e-23)
           (* b (* y4 (- (* j t) (* k y))))
           (if (<= y1 5.6e+88) (* y3 (* y5 (- (* j y0) (* a y)))) t_1)))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = i * (y1 * ((j * x) - (k * z)));
	double tmp;
	if (y1 <= -1e+25) {
		tmp = t_1;
	} else if (y1 <= -3e-64) {
		tmp = j * (t * ((b * y4) - (i * y5)));
	} else if (y1 <= 8.8e-153) {
		tmp = c * (t * ((i * z) - (y2 * y4)));
	} else if (y1 <= 7.6e-23) {
		tmp = b * (y4 * ((j * t) - (k * y)));
	} else if (y1 <= 5.6e+88) {
		tmp = y3 * (y5 * ((j * y0) - (a * y)));
	} else {
		tmp = t_1;
	}
	return tmp;
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8), intent (in) :: y0
    real(8), intent (in) :: y1
    real(8), intent (in) :: y2
    real(8), intent (in) :: y3
    real(8), intent (in) :: y4
    real(8), intent (in) :: y5
    real(8) :: t_1
    real(8) :: tmp
    t_1 = i * (y1 * ((j * x) - (k * z)))
    if (y1 <= (-1d+25)) then
        tmp = t_1
    else if (y1 <= (-3d-64)) then
        tmp = j * (t * ((b * y4) - (i * y5)))
    else if (y1 <= 8.8d-153) then
        tmp = c * (t * ((i * z) - (y2 * y4)))
    else if (y1 <= 7.6d-23) then
        tmp = b * (y4 * ((j * t) - (k * y)))
    else if (y1 <= 5.6d+88) then
        tmp = y3 * (y5 * ((j * y0) - (a * y)))
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = i * (y1 * ((j * x) - (k * z)));
	double tmp;
	if (y1 <= -1e+25) {
		tmp = t_1;
	} else if (y1 <= -3e-64) {
		tmp = j * (t * ((b * y4) - (i * y5)));
	} else if (y1 <= 8.8e-153) {
		tmp = c * (t * ((i * z) - (y2 * y4)));
	} else if (y1 <= 7.6e-23) {
		tmp = b * (y4 * ((j * t) - (k * y)));
	} else if (y1 <= 5.6e+88) {
		tmp = y3 * (y5 * ((j * y0) - (a * y)));
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5):
	t_1 = i * (y1 * ((j * x) - (k * z)))
	tmp = 0
	if y1 <= -1e+25:
		tmp = t_1
	elif y1 <= -3e-64:
		tmp = j * (t * ((b * y4) - (i * y5)))
	elif y1 <= 8.8e-153:
		tmp = c * (t * ((i * z) - (y2 * y4)))
	elif y1 <= 7.6e-23:
		tmp = b * (y4 * ((j * t) - (k * y)))
	elif y1 <= 5.6e+88:
		tmp = y3 * (y5 * ((j * y0) - (a * y)))
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = Float64(i * Float64(y1 * Float64(Float64(j * x) - Float64(k * z))))
	tmp = 0.0
	if (y1 <= -1e+25)
		tmp = t_1;
	elseif (y1 <= -3e-64)
		tmp = Float64(j * Float64(t * Float64(Float64(b * y4) - Float64(i * y5))));
	elseif (y1 <= 8.8e-153)
		tmp = Float64(c * Float64(t * Float64(Float64(i * z) - Float64(y2 * y4))));
	elseif (y1 <= 7.6e-23)
		tmp = Float64(b * Float64(y4 * Float64(Float64(j * t) - Float64(k * y))));
	elseif (y1 <= 5.6e+88)
		tmp = Float64(y3 * Float64(y5 * Float64(Float64(j * y0) - Float64(a * y))));
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = i * (y1 * ((j * x) - (k * z)));
	tmp = 0.0;
	if (y1 <= -1e+25)
		tmp = t_1;
	elseif (y1 <= -3e-64)
		tmp = j * (t * ((b * y4) - (i * y5)));
	elseif (y1 <= 8.8e-153)
		tmp = c * (t * ((i * z) - (y2 * y4)));
	elseif (y1 <= 7.6e-23)
		tmp = b * (y4 * ((j * t) - (k * y)));
	elseif (y1 <= 5.6e+88)
		tmp = y3 * (y5 * ((j * y0) - (a * y)));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(i * N[(y1 * N[(N[(j * x), $MachinePrecision] - N[(k * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y1, -1e+25], t$95$1, If[LessEqual[y1, -3e-64], N[(j * N[(t * N[(N[(b * y4), $MachinePrecision] - N[(i * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y1, 8.8e-153], N[(c * N[(t * N[(N[(i * z), $MachinePrecision] - N[(y2 * y4), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y1, 7.6e-23], N[(b * N[(y4 * N[(N[(j * t), $MachinePrecision] - N[(k * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y1, 5.6e+88], N[(y3 * N[(y5 * N[(N[(j * y0), $MachinePrecision] - N[(a * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\\
\mathbf{if}\;y1 \leq -1 \cdot 10^{+25}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;y1 \leq -3 \cdot 10^{-64}:\\
\;\;\;\;j \cdot \left(t \cdot \left(b \cdot y4 - i \cdot y5\right)\right)\\

\mathbf{elif}\;y1 \leq 8.8 \cdot 10^{-153}:\\
\;\;\;\;c \cdot \left(t \cdot \left(i \cdot z - y2 \cdot y4\right)\right)\\

\mathbf{elif}\;y1 \leq 7.6 \cdot 10^{-23}:\\
\;\;\;\;b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot y\right)\right)\\

\mathbf{elif}\;y1 \leq 5.6 \cdot 10^{+88}:\\
\;\;\;\;y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)\\

\mathbf{else}:\\
\;\;\;\;t\_1\\


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if y1 < -1.00000000000000009e25 or 5.59999999999999977e88 < y1

    1. Initial program 24.5%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites39.4%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in y1 around -inf

      \[\leadsto i \cdot \color{blue}{\left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \color{blue}{\left(j \cdot x - k \cdot z\right)}\right) \]
      2. lift-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right) \]
      3. lift-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right) \]
      4. lift--.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot \color{blue}{z}\right)\right) \]
      5. lift-*.f6440.2

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - \color{blue}{k \cdot z}\right)\right) \]
    7. Applied rewrites40.2%

      \[\leadsto i \cdot \color{blue}{\left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]

    if -1.00000000000000009e25 < y1 < -3.0000000000000001e-64

    1. Initial program 30.6%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in t around inf

      \[\leadsto \color{blue}{t \cdot \left(\left(-1 \cdot \left(z \cdot \left(a \cdot b - c \cdot i\right)\right) + j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - y2 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto t \cdot \color{blue}{\left(\left(-1 \cdot \left(z \cdot \left(a \cdot b - c \cdot i\right)\right) + j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - y2 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto t \cdot \left(\left(-1 \cdot \left(z \cdot \left(a \cdot b - c \cdot i\right)\right) + j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - \color{blue}{y2 \cdot \left(c \cdot y4 - a \cdot y5\right)}\right) \]
    4. Applied rewrites34.1%

      \[\leadsto \color{blue}{t \cdot \left(\mathsf{fma}\left(-1, z \cdot \left(a \cdot b - c \cdot i\right), j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - y2 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
    5. Taylor expanded in j around inf

      \[\leadsto j \cdot \color{blue}{\left(t \cdot \left(b \cdot y4 - i \cdot y5\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto j \cdot \left(t \cdot \color{blue}{\left(b \cdot y4 - i \cdot y5\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto j \cdot \left(t \cdot \left(b \cdot y4 - \color{blue}{i \cdot y5}\right)\right) \]
      3. lift-*.f64N/A

        \[\leadsto j \cdot \left(t \cdot \left(b \cdot y4 - i \cdot y5\right)\right) \]
      4. lift-*.f64N/A

        \[\leadsto j \cdot \left(t \cdot \left(b \cdot y4 - i \cdot y5\right)\right) \]
      5. lift--.f6426.3

        \[\leadsto j \cdot \left(t \cdot \left(b \cdot y4 - i \cdot \color{blue}{y5}\right)\right) \]
    7. Applied rewrites26.3%

      \[\leadsto j \cdot \color{blue}{\left(t \cdot \left(b \cdot y4 - i \cdot y5\right)\right)} \]

    if -3.0000000000000001e-64 < y1 < 8.80000000000000003e-153

    1. Initial program 36.4%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in t around inf

      \[\leadsto \color{blue}{t \cdot \left(\left(-1 \cdot \left(z \cdot \left(a \cdot b - c \cdot i\right)\right) + j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - y2 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto t \cdot \color{blue}{\left(\left(-1 \cdot \left(z \cdot \left(a \cdot b - c \cdot i\right)\right) + j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - y2 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto t \cdot \left(\left(-1 \cdot \left(z \cdot \left(a \cdot b - c \cdot i\right)\right) + j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - \color{blue}{y2 \cdot \left(c \cdot y4 - a \cdot y5\right)}\right) \]
    4. Applied rewrites39.6%

      \[\leadsto \color{blue}{t \cdot \left(\mathsf{fma}\left(-1, z \cdot \left(a \cdot b - c \cdot i\right), j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - y2 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
    5. Taylor expanded in c around inf

      \[\leadsto c \cdot \color{blue}{\left(t \cdot \left(i \cdot z - y2 \cdot y4\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto c \cdot \left(t \cdot \color{blue}{\left(i \cdot z - y2 \cdot y4\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto c \cdot \left(t \cdot \left(i \cdot z - \color{blue}{y2 \cdot y4}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto c \cdot \left(t \cdot \left(i \cdot z - y2 \cdot \color{blue}{y4}\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto c \cdot \left(t \cdot \left(i \cdot z - y2 \cdot y4\right)\right) \]
      5. lower-*.f6427.2

        \[\leadsto c \cdot \left(t \cdot \left(i \cdot z - y2 \cdot y4\right)\right) \]
    7. Applied rewrites27.2%

      \[\leadsto c \cdot \color{blue}{\left(t \cdot \left(i \cdot z - y2 \cdot y4\right)\right)} \]

    if 8.80000000000000003e-153 < y1 < 7.60000000000000023e-23

    1. Initial program 34.2%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in b around inf

      \[\leadsto \color{blue}{b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto b \cdot \color{blue}{\left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y0 \cdot \left(j \cdot x - k \cdot z\right)}\right) \]
    4. Applied rewrites37.1%

      \[\leadsto \color{blue}{b \cdot \left(\mathsf{fma}\left(a, x \cdot y - t \cdot z, y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    5. Taylor expanded in y4 around inf

      \[\leadsto b \cdot \left(y4 \cdot \color{blue}{\left(j \cdot t - k \cdot y\right)}\right) \]
    6. Step-by-step derivation
      1. lift-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot y\right)\right) \]
      2. lift-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot y\right)\right) \]
      3. lift--.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot \color{blue}{y}\right)\right) \]
      4. lift-*.f6425.3

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - \color{blue}{k \cdot y}\right)\right) \]
    7. Applied rewrites25.3%

      \[\leadsto b \cdot \left(y4 \cdot \color{blue}{\left(j \cdot t - k \cdot y\right)}\right) \]

    if 7.60000000000000023e-23 < y1 < 5.59999999999999977e88

    1. Initial program 30.9%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y3 around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \color{blue}{\left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{y \cdot \left(c \cdot y4 - a \cdot y5\right)}\right)\right) \]
    4. Applied rewrites38.3%

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\mathsf{fma}\left(j, y1 \cdot y4 - y0 \cdot y5, z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    5. Taylor expanded in y5 around -inf

      \[\leadsto y3 \cdot \color{blue}{\left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \color{blue}{\left(j \cdot y0 - a \cdot y\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - \color{blue}{a \cdot y}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot \color{blue}{y}\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right) \]
      5. lower-*.f6427.7

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right) \]
    7. Applied rewrites27.7%

      \[\leadsto y3 \cdot \color{blue}{\left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)} \]
  3. Recombined 5 regimes into one program.
  4. Add Preprocessing

Alternative 16: 31.9% accurate, 3.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\\ t_2 := y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)\\ \mathbf{if}\;y5 \leq -2.8 \cdot 10^{+23}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;y5 \leq -4 \cdot 10^{-231}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y5 \leq -8 \cdot 10^{-300}:\\ \;\;\;\;a \cdot \left(b \cdot \left(x \cdot y - t \cdot z\right)\right)\\ \mathbf{elif}\;y5 \leq 1.6 \cdot 10^{-165}:\\ \;\;\;\;y \cdot \left(y3 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\\ \mathbf{elif}\;y5 \leq 2.55 \cdot 10^{+98}:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;t\_2\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (let* ((t_1 (* i (* y1 (- (* j x) (* k z)))))
        (t_2 (* y3 (* y5 (- (* j y0) (* a y))))))
   (if (<= y5 -2.8e+23)
     t_2
     (if (<= y5 -4e-231)
       t_1
       (if (<= y5 -8e-300)
         (* a (* b (- (* x y) (* t z))))
         (if (<= y5 1.6e-165)
           (* y (* y3 (- (* c y4) (* a y5))))
           (if (<= y5 2.55e+98) t_1 t_2)))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = i * (y1 * ((j * x) - (k * z)));
	double t_2 = y3 * (y5 * ((j * y0) - (a * y)));
	double tmp;
	if (y5 <= -2.8e+23) {
		tmp = t_2;
	} else if (y5 <= -4e-231) {
		tmp = t_1;
	} else if (y5 <= -8e-300) {
		tmp = a * (b * ((x * y) - (t * z)));
	} else if (y5 <= 1.6e-165) {
		tmp = y * (y3 * ((c * y4) - (a * y5)));
	} else if (y5 <= 2.55e+98) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	return tmp;
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8), intent (in) :: y0
    real(8), intent (in) :: y1
    real(8), intent (in) :: y2
    real(8), intent (in) :: y3
    real(8), intent (in) :: y4
    real(8), intent (in) :: y5
    real(8) :: t_1
    real(8) :: t_2
    real(8) :: tmp
    t_1 = i * (y1 * ((j * x) - (k * z)))
    t_2 = y3 * (y5 * ((j * y0) - (a * y)))
    if (y5 <= (-2.8d+23)) then
        tmp = t_2
    else if (y5 <= (-4d-231)) then
        tmp = t_1
    else if (y5 <= (-8d-300)) then
        tmp = a * (b * ((x * y) - (t * z)))
    else if (y5 <= 1.6d-165) then
        tmp = y * (y3 * ((c * y4) - (a * y5)))
    else if (y5 <= 2.55d+98) then
        tmp = t_1
    else
        tmp = t_2
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = i * (y1 * ((j * x) - (k * z)));
	double t_2 = y3 * (y5 * ((j * y0) - (a * y)));
	double tmp;
	if (y5 <= -2.8e+23) {
		tmp = t_2;
	} else if (y5 <= -4e-231) {
		tmp = t_1;
	} else if (y5 <= -8e-300) {
		tmp = a * (b * ((x * y) - (t * z)));
	} else if (y5 <= 1.6e-165) {
		tmp = y * (y3 * ((c * y4) - (a * y5)));
	} else if (y5 <= 2.55e+98) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5):
	t_1 = i * (y1 * ((j * x) - (k * z)))
	t_2 = y3 * (y5 * ((j * y0) - (a * y)))
	tmp = 0
	if y5 <= -2.8e+23:
		tmp = t_2
	elif y5 <= -4e-231:
		tmp = t_1
	elif y5 <= -8e-300:
		tmp = a * (b * ((x * y) - (t * z)))
	elif y5 <= 1.6e-165:
		tmp = y * (y3 * ((c * y4) - (a * y5)))
	elif y5 <= 2.55e+98:
		tmp = t_1
	else:
		tmp = t_2
	return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = Float64(i * Float64(y1 * Float64(Float64(j * x) - Float64(k * z))))
	t_2 = Float64(y3 * Float64(y5 * Float64(Float64(j * y0) - Float64(a * y))))
	tmp = 0.0
	if (y5 <= -2.8e+23)
		tmp = t_2;
	elseif (y5 <= -4e-231)
		tmp = t_1;
	elseif (y5 <= -8e-300)
		tmp = Float64(a * Float64(b * Float64(Float64(x * y) - Float64(t * z))));
	elseif (y5 <= 1.6e-165)
		tmp = Float64(y * Float64(y3 * Float64(Float64(c * y4) - Float64(a * y5))));
	elseif (y5 <= 2.55e+98)
		tmp = t_1;
	else
		tmp = t_2;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = i * (y1 * ((j * x) - (k * z)));
	t_2 = y3 * (y5 * ((j * y0) - (a * y)));
	tmp = 0.0;
	if (y5 <= -2.8e+23)
		tmp = t_2;
	elseif (y5 <= -4e-231)
		tmp = t_1;
	elseif (y5 <= -8e-300)
		tmp = a * (b * ((x * y) - (t * z)));
	elseif (y5 <= 1.6e-165)
		tmp = y * (y3 * ((c * y4) - (a * y5)));
	elseif (y5 <= 2.55e+98)
		tmp = t_1;
	else
		tmp = t_2;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(i * N[(y1 * N[(N[(j * x), $MachinePrecision] - N[(k * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(y3 * N[(y5 * N[(N[(j * y0), $MachinePrecision] - N[(a * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y5, -2.8e+23], t$95$2, If[LessEqual[y5, -4e-231], t$95$1, If[LessEqual[y5, -8e-300], N[(a * N[(b * N[(N[(x * y), $MachinePrecision] - N[(t * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y5, 1.6e-165], N[(y * N[(y3 * N[(N[(c * y4), $MachinePrecision] - N[(a * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y5, 2.55e+98], t$95$1, t$95$2]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\\
t_2 := y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)\\
\mathbf{if}\;y5 \leq -2.8 \cdot 10^{+23}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;y5 \leq -4 \cdot 10^{-231}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;y5 \leq -8 \cdot 10^{-300}:\\
\;\;\;\;a \cdot \left(b \cdot \left(x \cdot y - t \cdot z\right)\right)\\

\mathbf{elif}\;y5 \leq 1.6 \cdot 10^{-165}:\\
\;\;\;\;y \cdot \left(y3 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\\

\mathbf{elif}\;y5 \leq 2.55 \cdot 10^{+98}:\\
\;\;\;\;t\_1\\

\mathbf{else}:\\
\;\;\;\;t\_2\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if y5 < -2.8e23 or 2.54999999999999994e98 < y5

    1. Initial program 24.8%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y3 around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \color{blue}{\left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{y \cdot \left(c \cdot y4 - a \cdot y5\right)}\right)\right) \]
    4. Applied rewrites36.7%

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\mathsf{fma}\left(j, y1 \cdot y4 - y0 \cdot y5, z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    5. Taylor expanded in y5 around -inf

      \[\leadsto y3 \cdot \color{blue}{\left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \color{blue}{\left(j \cdot y0 - a \cdot y\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - \color{blue}{a \cdot y}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot \color{blue}{y}\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right) \]
      5. lower-*.f6440.4

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right) \]
    7. Applied rewrites40.4%

      \[\leadsto y3 \cdot \color{blue}{\left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)} \]

    if -2.8e23 < y5 < -4e-231 or 1.60000000000000006e-165 < y5 < 2.54999999999999994e98

    1. Initial program 34.1%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites36.4%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in y1 around -inf

      \[\leadsto i \cdot \color{blue}{\left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \color{blue}{\left(j \cdot x - k \cdot z\right)}\right) \]
      2. lift-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right) \]
      3. lift-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right) \]
      4. lift--.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot \color{blue}{z}\right)\right) \]
      5. lift-*.f6428.2

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - \color{blue}{k \cdot z}\right)\right) \]
    7. Applied rewrites28.2%

      \[\leadsto i \cdot \color{blue}{\left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]

    if -4e-231 < y5 < -8.0000000000000002e-300

    1. Initial program 31.2%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in b around inf

      \[\leadsto \color{blue}{b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto b \cdot \color{blue}{\left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y0 \cdot \left(j \cdot x - k \cdot z\right)}\right) \]
    4. Applied rewrites34.0%

      \[\leadsto \color{blue}{b \cdot \left(\mathsf{fma}\left(a, x \cdot y - t \cdot z, y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    5. Taylor expanded in a around inf

      \[\leadsto a \cdot \color{blue}{\left(b \cdot \left(x \cdot y - t \cdot z\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto a \cdot \left(b \cdot \color{blue}{\left(x \cdot y - t \cdot z\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto a \cdot \left(b \cdot \left(x \cdot y - \color{blue}{t \cdot z}\right)\right) \]
      3. lift-*.f64N/A

        \[\leadsto a \cdot \left(b \cdot \left(x \cdot y - t \cdot z\right)\right) \]
      4. lift-*.f64N/A

        \[\leadsto a \cdot \left(b \cdot \left(x \cdot y - t \cdot z\right)\right) \]
      5. lift--.f6424.8

        \[\leadsto a \cdot \left(b \cdot \left(x \cdot y - t \cdot \color{blue}{z}\right)\right) \]
    7. Applied rewrites24.8%

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

    if -8.0000000000000002e-300 < y5 < 1.60000000000000006e-165

    1. Initial program 35.6%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y3 around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \color{blue}{\left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{y \cdot \left(c \cdot y4 - a \cdot y5\right)}\right)\right) \]
    4. Applied rewrites36.7%

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\mathsf{fma}\left(j, y1 \cdot y4 - y0 \cdot y5, z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    5. Taylor expanded in y around -inf

      \[\leadsto y \cdot \color{blue}{\left(y3 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto y \cdot \left(y3 \cdot \color{blue}{\left(c \cdot y4 - a \cdot y5\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto y \cdot \left(y3 \cdot \left(c \cdot y4 - \color{blue}{a \cdot y5}\right)\right) \]
      3. lift-*.f64N/A

        \[\leadsto y \cdot \left(y3 \cdot \left(c \cdot y4 - a \cdot y5\right)\right) \]
      4. lift-*.f64N/A

        \[\leadsto y \cdot \left(y3 \cdot \left(c \cdot y4 - a \cdot y5\right)\right) \]
      5. lift--.f6420.2

        \[\leadsto y \cdot \left(y3 \cdot \left(c \cdot y4 - a \cdot \color{blue}{y5}\right)\right) \]
    7. Applied rewrites20.2%

      \[\leadsto y \cdot \color{blue}{\left(y3 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
  3. Recombined 4 regimes into one program.
  4. Add Preprocessing

Alternative 17: 32.2% accurate, 4.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\\ \mathbf{if}\;y1 \leq -1 \cdot 10^{+25}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y1 \leq -3 \cdot 10^{-64}:\\ \;\;\;\;j \cdot \left(t \cdot \left(b \cdot y4 - i \cdot y5\right)\right)\\ \mathbf{elif}\;y1 \leq 8.8 \cdot 10^{-153}:\\ \;\;\;\;c \cdot \left(t \cdot \left(i \cdot z - y2 \cdot y4\right)\right)\\ \mathbf{elif}\;y1 \leq 5.6 \cdot 10^{+88}:\\ \;\;\;\;y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (let* ((t_1 (* i (* y1 (- (* j x) (* k z))))))
   (if (<= y1 -1e+25)
     t_1
     (if (<= y1 -3e-64)
       (* j (* t (- (* b y4) (* i y5))))
       (if (<= y1 8.8e-153)
         (* c (* t (- (* i z) (* y2 y4))))
         (if (<= y1 5.6e+88) (* y3 (* y5 (- (* j y0) (* a y)))) t_1))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = i * (y1 * ((j * x) - (k * z)));
	double tmp;
	if (y1 <= -1e+25) {
		tmp = t_1;
	} else if (y1 <= -3e-64) {
		tmp = j * (t * ((b * y4) - (i * y5)));
	} else if (y1 <= 8.8e-153) {
		tmp = c * (t * ((i * z) - (y2 * y4)));
	} else if (y1 <= 5.6e+88) {
		tmp = y3 * (y5 * ((j * y0) - (a * y)));
	} else {
		tmp = t_1;
	}
	return tmp;
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8), intent (in) :: y0
    real(8), intent (in) :: y1
    real(8), intent (in) :: y2
    real(8), intent (in) :: y3
    real(8), intent (in) :: y4
    real(8), intent (in) :: y5
    real(8) :: t_1
    real(8) :: tmp
    t_1 = i * (y1 * ((j * x) - (k * z)))
    if (y1 <= (-1d+25)) then
        tmp = t_1
    else if (y1 <= (-3d-64)) then
        tmp = j * (t * ((b * y4) - (i * y5)))
    else if (y1 <= 8.8d-153) then
        tmp = c * (t * ((i * z) - (y2 * y4)))
    else if (y1 <= 5.6d+88) then
        tmp = y3 * (y5 * ((j * y0) - (a * y)))
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = i * (y1 * ((j * x) - (k * z)));
	double tmp;
	if (y1 <= -1e+25) {
		tmp = t_1;
	} else if (y1 <= -3e-64) {
		tmp = j * (t * ((b * y4) - (i * y5)));
	} else if (y1 <= 8.8e-153) {
		tmp = c * (t * ((i * z) - (y2 * y4)));
	} else if (y1 <= 5.6e+88) {
		tmp = y3 * (y5 * ((j * y0) - (a * y)));
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5):
	t_1 = i * (y1 * ((j * x) - (k * z)))
	tmp = 0
	if y1 <= -1e+25:
		tmp = t_1
	elif y1 <= -3e-64:
		tmp = j * (t * ((b * y4) - (i * y5)))
	elif y1 <= 8.8e-153:
		tmp = c * (t * ((i * z) - (y2 * y4)))
	elif y1 <= 5.6e+88:
		tmp = y3 * (y5 * ((j * y0) - (a * y)))
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = Float64(i * Float64(y1 * Float64(Float64(j * x) - Float64(k * z))))
	tmp = 0.0
	if (y1 <= -1e+25)
		tmp = t_1;
	elseif (y1 <= -3e-64)
		tmp = Float64(j * Float64(t * Float64(Float64(b * y4) - Float64(i * y5))));
	elseif (y1 <= 8.8e-153)
		tmp = Float64(c * Float64(t * Float64(Float64(i * z) - Float64(y2 * y4))));
	elseif (y1 <= 5.6e+88)
		tmp = Float64(y3 * Float64(y5 * Float64(Float64(j * y0) - Float64(a * y))));
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = i * (y1 * ((j * x) - (k * z)));
	tmp = 0.0;
	if (y1 <= -1e+25)
		tmp = t_1;
	elseif (y1 <= -3e-64)
		tmp = j * (t * ((b * y4) - (i * y5)));
	elseif (y1 <= 8.8e-153)
		tmp = c * (t * ((i * z) - (y2 * y4)));
	elseif (y1 <= 5.6e+88)
		tmp = y3 * (y5 * ((j * y0) - (a * y)));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(i * N[(y1 * N[(N[(j * x), $MachinePrecision] - N[(k * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y1, -1e+25], t$95$1, If[LessEqual[y1, -3e-64], N[(j * N[(t * N[(N[(b * y4), $MachinePrecision] - N[(i * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y1, 8.8e-153], N[(c * N[(t * N[(N[(i * z), $MachinePrecision] - N[(y2 * y4), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y1, 5.6e+88], N[(y3 * N[(y5 * N[(N[(j * y0), $MachinePrecision] - N[(a * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\\
\mathbf{if}\;y1 \leq -1 \cdot 10^{+25}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;y1 \leq -3 \cdot 10^{-64}:\\
\;\;\;\;j \cdot \left(t \cdot \left(b \cdot y4 - i \cdot y5\right)\right)\\

\mathbf{elif}\;y1 \leq 8.8 \cdot 10^{-153}:\\
\;\;\;\;c \cdot \left(t \cdot \left(i \cdot z - y2 \cdot y4\right)\right)\\

\mathbf{elif}\;y1 \leq 5.6 \cdot 10^{+88}:\\
\;\;\;\;y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)\\

\mathbf{else}:\\
\;\;\;\;t\_1\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if y1 < -1.00000000000000009e25 or 5.59999999999999977e88 < y1

    1. Initial program 24.5%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites39.4%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in y1 around -inf

      \[\leadsto i \cdot \color{blue}{\left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \color{blue}{\left(j \cdot x - k \cdot z\right)}\right) \]
      2. lift-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right) \]
      3. lift-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right) \]
      4. lift--.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot \color{blue}{z}\right)\right) \]
      5. lift-*.f6440.2

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - \color{blue}{k \cdot z}\right)\right) \]
    7. Applied rewrites40.2%

      \[\leadsto i \cdot \color{blue}{\left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]

    if -1.00000000000000009e25 < y1 < -3.0000000000000001e-64

    1. Initial program 30.6%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in t around inf

      \[\leadsto \color{blue}{t \cdot \left(\left(-1 \cdot \left(z \cdot \left(a \cdot b - c \cdot i\right)\right) + j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - y2 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto t \cdot \color{blue}{\left(\left(-1 \cdot \left(z \cdot \left(a \cdot b - c \cdot i\right)\right) + j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - y2 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto t \cdot \left(\left(-1 \cdot \left(z \cdot \left(a \cdot b - c \cdot i\right)\right) + j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - \color{blue}{y2 \cdot \left(c \cdot y4 - a \cdot y5\right)}\right) \]
    4. Applied rewrites34.1%

      \[\leadsto \color{blue}{t \cdot \left(\mathsf{fma}\left(-1, z \cdot \left(a \cdot b - c \cdot i\right), j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - y2 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
    5. Taylor expanded in j around inf

      \[\leadsto j \cdot \color{blue}{\left(t \cdot \left(b \cdot y4 - i \cdot y5\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto j \cdot \left(t \cdot \color{blue}{\left(b \cdot y4 - i \cdot y5\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto j \cdot \left(t \cdot \left(b \cdot y4 - \color{blue}{i \cdot y5}\right)\right) \]
      3. lift-*.f64N/A

        \[\leadsto j \cdot \left(t \cdot \left(b \cdot y4 - i \cdot y5\right)\right) \]
      4. lift-*.f64N/A

        \[\leadsto j \cdot \left(t \cdot \left(b \cdot y4 - i \cdot y5\right)\right) \]
      5. lift--.f6426.3

        \[\leadsto j \cdot \left(t \cdot \left(b \cdot y4 - i \cdot \color{blue}{y5}\right)\right) \]
    7. Applied rewrites26.3%

      \[\leadsto j \cdot \color{blue}{\left(t \cdot \left(b \cdot y4 - i \cdot y5\right)\right)} \]

    if -3.0000000000000001e-64 < y1 < 8.80000000000000003e-153

    1. Initial program 36.4%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in t around inf

      \[\leadsto \color{blue}{t \cdot \left(\left(-1 \cdot \left(z \cdot \left(a \cdot b - c \cdot i\right)\right) + j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - y2 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto t \cdot \color{blue}{\left(\left(-1 \cdot \left(z \cdot \left(a \cdot b - c \cdot i\right)\right) + j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - y2 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto t \cdot \left(\left(-1 \cdot \left(z \cdot \left(a \cdot b - c \cdot i\right)\right) + j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - \color{blue}{y2 \cdot \left(c \cdot y4 - a \cdot y5\right)}\right) \]
    4. Applied rewrites39.6%

      \[\leadsto \color{blue}{t \cdot \left(\mathsf{fma}\left(-1, z \cdot \left(a \cdot b - c \cdot i\right), j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - y2 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
    5. Taylor expanded in c around inf

      \[\leadsto c \cdot \color{blue}{\left(t \cdot \left(i \cdot z - y2 \cdot y4\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto c \cdot \left(t \cdot \color{blue}{\left(i \cdot z - y2 \cdot y4\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto c \cdot \left(t \cdot \left(i \cdot z - \color{blue}{y2 \cdot y4}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto c \cdot \left(t \cdot \left(i \cdot z - y2 \cdot \color{blue}{y4}\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto c \cdot \left(t \cdot \left(i \cdot z - y2 \cdot y4\right)\right) \]
      5. lower-*.f6427.2

        \[\leadsto c \cdot \left(t \cdot \left(i \cdot z - y2 \cdot y4\right)\right) \]
    7. Applied rewrites27.2%

      \[\leadsto c \cdot \color{blue}{\left(t \cdot \left(i \cdot z - y2 \cdot y4\right)\right)} \]

    if 8.80000000000000003e-153 < y1 < 5.59999999999999977e88

    1. Initial program 32.7%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y3 around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \color{blue}{\left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{y \cdot \left(c \cdot y4 - a \cdot y5\right)}\right)\right) \]
    4. Applied rewrites37.9%

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\mathsf{fma}\left(j, y1 \cdot y4 - y0 \cdot y5, z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    5. Taylor expanded in y5 around -inf

      \[\leadsto y3 \cdot \color{blue}{\left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \color{blue}{\left(j \cdot y0 - a \cdot y\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - \color{blue}{a \cdot y}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot \color{blue}{y}\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right) \]
      5. lower-*.f6426.3

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right) \]
    7. Applied rewrites26.3%

      \[\leadsto y3 \cdot \color{blue}{\left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)} \]
  3. Recombined 4 regimes into one program.
  4. Add Preprocessing

Alternative 18: 30.1% accurate, 4.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\\ t_2 := y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)\\ \mathbf{if}\;y5 \leq -2.8 \cdot 10^{+23}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;y5 \leq -4.7 \cdot 10^{-161}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y5 \leq 1.4 \cdot 10^{-127}:\\ \;\;\;\;i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot x\right)\right)\right)\\ \mathbf{elif}\;y5 \leq 2.55 \cdot 10^{+98}:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;t\_2\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (let* ((t_1 (* i (* y1 (- (* j x) (* k z)))))
        (t_2 (* y3 (* y5 (- (* j y0) (* a y))))))
   (if (<= y5 -2.8e+23)
     t_2
     (if (<= y5 -4.7e-161)
       t_1
       (if (<= y5 1.4e-127)
         (* i (* y (* -1.0 (* c x))))
         (if (<= y5 2.55e+98) t_1 t_2))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = i * (y1 * ((j * x) - (k * z)));
	double t_2 = y3 * (y5 * ((j * y0) - (a * y)));
	double tmp;
	if (y5 <= -2.8e+23) {
		tmp = t_2;
	} else if (y5 <= -4.7e-161) {
		tmp = t_1;
	} else if (y5 <= 1.4e-127) {
		tmp = i * (y * (-1.0 * (c * x)));
	} else if (y5 <= 2.55e+98) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	return tmp;
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8), intent (in) :: y0
    real(8), intent (in) :: y1
    real(8), intent (in) :: y2
    real(8), intent (in) :: y3
    real(8), intent (in) :: y4
    real(8), intent (in) :: y5
    real(8) :: t_1
    real(8) :: t_2
    real(8) :: tmp
    t_1 = i * (y1 * ((j * x) - (k * z)))
    t_2 = y3 * (y5 * ((j * y0) - (a * y)))
    if (y5 <= (-2.8d+23)) then
        tmp = t_2
    else if (y5 <= (-4.7d-161)) then
        tmp = t_1
    else if (y5 <= 1.4d-127) then
        tmp = i * (y * ((-1.0d0) * (c * x)))
    else if (y5 <= 2.55d+98) then
        tmp = t_1
    else
        tmp = t_2
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = i * (y1 * ((j * x) - (k * z)));
	double t_2 = y3 * (y5 * ((j * y0) - (a * y)));
	double tmp;
	if (y5 <= -2.8e+23) {
		tmp = t_2;
	} else if (y5 <= -4.7e-161) {
		tmp = t_1;
	} else if (y5 <= 1.4e-127) {
		tmp = i * (y * (-1.0 * (c * x)));
	} else if (y5 <= 2.55e+98) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5):
	t_1 = i * (y1 * ((j * x) - (k * z)))
	t_2 = y3 * (y5 * ((j * y0) - (a * y)))
	tmp = 0
	if y5 <= -2.8e+23:
		tmp = t_2
	elif y5 <= -4.7e-161:
		tmp = t_1
	elif y5 <= 1.4e-127:
		tmp = i * (y * (-1.0 * (c * x)))
	elif y5 <= 2.55e+98:
		tmp = t_1
	else:
		tmp = t_2
	return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = Float64(i * Float64(y1 * Float64(Float64(j * x) - Float64(k * z))))
	t_2 = Float64(y3 * Float64(y5 * Float64(Float64(j * y0) - Float64(a * y))))
	tmp = 0.0
	if (y5 <= -2.8e+23)
		tmp = t_2;
	elseif (y5 <= -4.7e-161)
		tmp = t_1;
	elseif (y5 <= 1.4e-127)
		tmp = Float64(i * Float64(y * Float64(-1.0 * Float64(c * x))));
	elseif (y5 <= 2.55e+98)
		tmp = t_1;
	else
		tmp = t_2;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = i * (y1 * ((j * x) - (k * z)));
	t_2 = y3 * (y5 * ((j * y0) - (a * y)));
	tmp = 0.0;
	if (y5 <= -2.8e+23)
		tmp = t_2;
	elseif (y5 <= -4.7e-161)
		tmp = t_1;
	elseif (y5 <= 1.4e-127)
		tmp = i * (y * (-1.0 * (c * x)));
	elseif (y5 <= 2.55e+98)
		tmp = t_1;
	else
		tmp = t_2;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(i * N[(y1 * N[(N[(j * x), $MachinePrecision] - N[(k * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(y3 * N[(y5 * N[(N[(j * y0), $MachinePrecision] - N[(a * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y5, -2.8e+23], t$95$2, If[LessEqual[y5, -4.7e-161], t$95$1, If[LessEqual[y5, 1.4e-127], N[(i * N[(y * N[(-1.0 * N[(c * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y5, 2.55e+98], t$95$1, t$95$2]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\\
t_2 := y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)\\
\mathbf{if}\;y5 \leq -2.8 \cdot 10^{+23}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;y5 \leq -4.7 \cdot 10^{-161}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;y5 \leq 1.4 \cdot 10^{-127}:\\
\;\;\;\;i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot x\right)\right)\right)\\

\mathbf{elif}\;y5 \leq 2.55 \cdot 10^{+98}:\\
\;\;\;\;t\_1\\

\mathbf{else}:\\
\;\;\;\;t\_2\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y5 < -2.8e23 or 2.54999999999999994e98 < y5

    1. Initial program 24.8%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y3 around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \color{blue}{\left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{y \cdot \left(c \cdot y4 - a \cdot y5\right)}\right)\right) \]
    4. Applied rewrites36.7%

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\mathsf{fma}\left(j, y1 \cdot y4 - y0 \cdot y5, z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    5. Taylor expanded in y5 around -inf

      \[\leadsto y3 \cdot \color{blue}{\left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \color{blue}{\left(j \cdot y0 - a \cdot y\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - \color{blue}{a \cdot y}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot \color{blue}{y}\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right) \]
      5. lower-*.f6440.4

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right) \]
    7. Applied rewrites40.4%

      \[\leadsto y3 \cdot \color{blue}{\left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)} \]

    if -2.8e23 < y5 < -4.7000000000000004e-161 or 1.4e-127 < y5 < 2.54999999999999994e98

    1. Initial program 33.1%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites37.2%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in y1 around -inf

      \[\leadsto i \cdot \color{blue}{\left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \color{blue}{\left(j \cdot x - k \cdot z\right)}\right) \]
      2. lift-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right) \]
      3. lift-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right) \]
      4. lift--.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot \color{blue}{z}\right)\right) \]
      5. lift-*.f6428.3

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - \color{blue}{k \cdot z}\right)\right) \]
    7. Applied rewrites28.3%

      \[\leadsto i \cdot \color{blue}{\left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]

    if -4.7000000000000004e-161 < y5 < 1.4e-127

    1. Initial program 35.3%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites34.3%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in y around -inf

      \[\leadsto i \cdot \color{blue}{\left(y \cdot \left(-1 \cdot \left(c \cdot x\right) + k \cdot y5\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \color{blue}{\left(-1 \cdot \left(c \cdot x\right) + k \cdot y5\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot x\right) + \color{blue}{k \cdot y5}\right)\right) \]
      3. lower-fma.f64N/A

        \[\leadsto i \cdot \left(y \cdot \mathsf{fma}\left(-1, c \cdot \color{blue}{x}, k \cdot y5\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \mathsf{fma}\left(-1, c \cdot x, k \cdot y5\right)\right) \]
      5. lower-*.f6418.5

        \[\leadsto i \cdot \left(y \cdot \mathsf{fma}\left(-1, c \cdot x, k \cdot y5\right)\right) \]
    7. Applied rewrites18.5%

      \[\leadsto i \cdot \color{blue}{\left(y \cdot \mathsf{fma}\left(-1, c \cdot x, k \cdot y5\right)\right)} \]
    8. Taylor expanded in x around inf

      \[\leadsto i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot \color{blue}{x}\right)\right)\right) \]
    9. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot x\right)\right)\right) \]
      2. lift-*.f6417.2

        \[\leadsto i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot x\right)\right)\right) \]
    10. Applied rewrites17.2%

      \[\leadsto i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot \color{blue}{x}\right)\right)\right) \]
  3. Recombined 3 regimes into one program.
  4. Add Preprocessing

Alternative 19: 32.5% accurate, 4.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)\\ \mathbf{if}\;y5 \leq -2.8 \cdot 10^{+23}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y5 \leq -2.25 \cdot 10^{-159}:\\ \;\;\;\;i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\\ \mathbf{elif}\;y5 \leq 2.9 \cdot 10^{+36}:\\ \;\;\;\;-1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (let* ((t_1 (* y3 (* y5 (- (* j y0) (* a y))))))
   (if (<= y5 -2.8e+23)
     t_1
     (if (<= y5 -2.25e-159)
       (* i (* y1 (- (* j x) (* k z))))
       (if (<= y5 2.9e+36) (* -1.0 (* i (* x (- (* c y) (* j y1))))) t_1)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = y3 * (y5 * ((j * y0) - (a * y)));
	double tmp;
	if (y5 <= -2.8e+23) {
		tmp = t_1;
	} else if (y5 <= -2.25e-159) {
		tmp = i * (y1 * ((j * x) - (k * z)));
	} else if (y5 <= 2.9e+36) {
		tmp = -1.0 * (i * (x * ((c * y) - (j * y1))));
	} else {
		tmp = t_1;
	}
	return tmp;
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8), intent (in) :: y0
    real(8), intent (in) :: y1
    real(8), intent (in) :: y2
    real(8), intent (in) :: y3
    real(8), intent (in) :: y4
    real(8), intent (in) :: y5
    real(8) :: t_1
    real(8) :: tmp
    t_1 = y3 * (y5 * ((j * y0) - (a * y)))
    if (y5 <= (-2.8d+23)) then
        tmp = t_1
    else if (y5 <= (-2.25d-159)) then
        tmp = i * (y1 * ((j * x) - (k * z)))
    else if (y5 <= 2.9d+36) then
        tmp = (-1.0d0) * (i * (x * ((c * y) - (j * y1))))
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = y3 * (y5 * ((j * y0) - (a * y)));
	double tmp;
	if (y5 <= -2.8e+23) {
		tmp = t_1;
	} else if (y5 <= -2.25e-159) {
		tmp = i * (y1 * ((j * x) - (k * z)));
	} else if (y5 <= 2.9e+36) {
		tmp = -1.0 * (i * (x * ((c * y) - (j * y1))));
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5):
	t_1 = y3 * (y5 * ((j * y0) - (a * y)))
	tmp = 0
	if y5 <= -2.8e+23:
		tmp = t_1
	elif y5 <= -2.25e-159:
		tmp = i * (y1 * ((j * x) - (k * z)))
	elif y5 <= 2.9e+36:
		tmp = -1.0 * (i * (x * ((c * y) - (j * y1))))
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = Float64(y3 * Float64(y5 * Float64(Float64(j * y0) - Float64(a * y))))
	tmp = 0.0
	if (y5 <= -2.8e+23)
		tmp = t_1;
	elseif (y5 <= -2.25e-159)
		tmp = Float64(i * Float64(y1 * Float64(Float64(j * x) - Float64(k * z))));
	elseif (y5 <= 2.9e+36)
		tmp = Float64(-1.0 * Float64(i * Float64(x * Float64(Float64(c * y) - Float64(j * y1)))));
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = y3 * (y5 * ((j * y0) - (a * y)));
	tmp = 0.0;
	if (y5 <= -2.8e+23)
		tmp = t_1;
	elseif (y5 <= -2.25e-159)
		tmp = i * (y1 * ((j * x) - (k * z)));
	elseif (y5 <= 2.9e+36)
		tmp = -1.0 * (i * (x * ((c * y) - (j * y1))));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(y3 * N[(y5 * N[(N[(j * y0), $MachinePrecision] - N[(a * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y5, -2.8e+23], t$95$1, If[LessEqual[y5, -2.25e-159], N[(i * N[(y1 * N[(N[(j * x), $MachinePrecision] - N[(k * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y5, 2.9e+36], N[(-1.0 * N[(i * N[(x * N[(N[(c * y), $MachinePrecision] - N[(j * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)\\
\mathbf{if}\;y5 \leq -2.8 \cdot 10^{+23}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;y5 \leq -2.25 \cdot 10^{-159}:\\
\;\;\;\;i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\\

\mathbf{elif}\;y5 \leq 2.9 \cdot 10^{+36}:\\
\;\;\;\;-1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right)\\

\mathbf{else}:\\
\;\;\;\;t\_1\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y5 < -2.8e23 or 2.9e36 < y5

    1. Initial program 25.1%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y3 around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \color{blue}{\left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{y \cdot \left(c \cdot y4 - a \cdot y5\right)}\right)\right) \]
    4. Applied rewrites36.7%

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\mathsf{fma}\left(j, y1 \cdot y4 - y0 \cdot y5, z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    5. Taylor expanded in y5 around -inf

      \[\leadsto y3 \cdot \color{blue}{\left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \color{blue}{\left(j \cdot y0 - a \cdot y\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - \color{blue}{a \cdot y}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot \color{blue}{y}\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right) \]
      5. lower-*.f6439.0

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right) \]
    7. Applied rewrites39.0%

      \[\leadsto y3 \cdot \color{blue}{\left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)} \]

    if -2.8e23 < y5 < -2.24999999999999994e-159

    1. Initial program 35.2%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites36.7%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in y1 around -inf

      \[\leadsto i \cdot \color{blue}{\left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \color{blue}{\left(j \cdot x - k \cdot z\right)}\right) \]
      2. lift-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right) \]
      3. lift-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right) \]
      4. lift--.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot \color{blue}{z}\right)\right) \]
      5. lift-*.f6427.6

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - \color{blue}{k \cdot z}\right)\right) \]
    7. Applied rewrites27.6%

      \[\leadsto i \cdot \color{blue}{\left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]

    if -2.24999999999999994e-159 < y5 < 2.9e36

    1. Initial program 34.5%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites35.3%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in x around inf

      \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \color{blue}{\left(c \cdot y - j \cdot y1\right)}\right)\right) \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - \color{blue}{j \cdot y1}\right)\right)\right) \]
      2. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot \color{blue}{y1}\right)\right)\right) \]
      3. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right) \]
      4. lower-*.f6427.2

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right) \]
    7. Applied rewrites27.2%

      \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \color{blue}{\left(c \cdot y - j \cdot y1\right)}\right)\right) \]
  3. Recombined 3 regimes into one program.
  4. Add Preprocessing

Alternative 20: 30.2% accurate, 4.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y1 \leq 7.6 \cdot 10^{-11}:\\ \;\;\;\;b \cdot \left(y4 \cdot \left(t \cdot \left(j + -1 \cdot \frac{k \cdot y}{t}\right)\right)\right)\\ \mathbf{elif}\;y1 \leq 4.5 \cdot 10^{+82}:\\ \;\;\;\;y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)\\ \mathbf{else}:\\ \;\;\;\;-1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (if (<= y1 7.6e-11)
   (* b (* y4 (* t (+ j (* -1.0 (/ (* k y) t))))))
   (if (<= y1 4.5e+82)
     (* y3 (* y5 (- (* j y0) (* a y))))
     (* -1.0 (* i (* x (- (* c y) (* j y1))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double tmp;
	if (y1 <= 7.6e-11) {
		tmp = b * (y4 * (t * (j + (-1.0 * ((k * y) / t)))));
	} else if (y1 <= 4.5e+82) {
		tmp = y3 * (y5 * ((j * y0) - (a * y)));
	} else {
		tmp = -1.0 * (i * (x * ((c * y) - (j * y1))));
	}
	return tmp;
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8), intent (in) :: y0
    real(8), intent (in) :: y1
    real(8), intent (in) :: y2
    real(8), intent (in) :: y3
    real(8), intent (in) :: y4
    real(8), intent (in) :: y5
    real(8) :: tmp
    if (y1 <= 7.6d-11) then
        tmp = b * (y4 * (t * (j + ((-1.0d0) * ((k * y) / t)))))
    else if (y1 <= 4.5d+82) then
        tmp = y3 * (y5 * ((j * y0) - (a * y)))
    else
        tmp = (-1.0d0) * (i * (x * ((c * y) - (j * y1))))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double tmp;
	if (y1 <= 7.6e-11) {
		tmp = b * (y4 * (t * (j + (-1.0 * ((k * y) / t)))));
	} else if (y1 <= 4.5e+82) {
		tmp = y3 * (y5 * ((j * y0) - (a * y)));
	} else {
		tmp = -1.0 * (i * (x * ((c * y) - (j * y1))));
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5):
	tmp = 0
	if y1 <= 7.6e-11:
		tmp = b * (y4 * (t * (j + (-1.0 * ((k * y) / t)))))
	elif y1 <= 4.5e+82:
		tmp = y3 * (y5 * ((j * y0) - (a * y)))
	else:
		tmp = -1.0 * (i * (x * ((c * y) - (j * y1))))
	return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	tmp = 0.0
	if (y1 <= 7.6e-11)
		tmp = Float64(b * Float64(y4 * Float64(t * Float64(j + Float64(-1.0 * Float64(Float64(k * y) / t))))));
	elseif (y1 <= 4.5e+82)
		tmp = Float64(y3 * Float64(y5 * Float64(Float64(j * y0) - Float64(a * y))));
	else
		tmp = Float64(-1.0 * Float64(i * Float64(x * Float64(Float64(c * y) - Float64(j * y1)))));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	tmp = 0.0;
	if (y1 <= 7.6e-11)
		tmp = b * (y4 * (t * (j + (-1.0 * ((k * y) / t)))));
	elseif (y1 <= 4.5e+82)
		tmp = y3 * (y5 * ((j * y0) - (a * y)));
	else
		tmp = -1.0 * (i * (x * ((c * y) - (j * y1))));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := If[LessEqual[y1, 7.6e-11], N[(b * N[(y4 * N[(t * N[(j + N[(-1.0 * N[(N[(k * y), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y1, 4.5e+82], N[(y3 * N[(y5 * N[(N[(j * y0), $MachinePrecision] - N[(a * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(-1.0 * N[(i * N[(x * N[(N[(c * y), $MachinePrecision] - N[(j * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y1 \leq 7.6 \cdot 10^{-11}:\\
\;\;\;\;b \cdot \left(y4 \cdot \left(t \cdot \left(j + -1 \cdot \frac{k \cdot y}{t}\right)\right)\right)\\

\mathbf{elif}\;y1 \leq 4.5 \cdot 10^{+82}:\\
\;\;\;\;y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)\\

\mathbf{else}:\\
\;\;\;\;-1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y1 < 7.5999999999999996e-11

    1. Initial program 32.2%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in b around inf

      \[\leadsto \color{blue}{b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto b \cdot \color{blue}{\left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y0 \cdot \left(j \cdot x - k \cdot z\right)}\right) \]
    4. Applied rewrites38.6%

      \[\leadsto \color{blue}{b \cdot \left(\mathsf{fma}\left(a, x \cdot y - t \cdot z, y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    5. Taylor expanded in y4 around inf

      \[\leadsto b \cdot \left(y4 \cdot \color{blue}{\left(j \cdot t - k \cdot y\right)}\right) \]
    6. Step-by-step derivation
      1. lift-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot y\right)\right) \]
      2. lift-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot y\right)\right) \]
      3. lift--.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot \color{blue}{y}\right)\right) \]
      4. lift-*.f6427.1

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - \color{blue}{k \cdot y}\right)\right) \]
    7. Applied rewrites27.1%

      \[\leadsto b \cdot \left(y4 \cdot \color{blue}{\left(j \cdot t - k \cdot y\right)}\right) \]
    8. Taylor expanded in t around inf

      \[\leadsto b \cdot \left(y4 \cdot \left(t \cdot \left(j + \color{blue}{-1 \cdot \frac{k \cdot y}{t}}\right)\right)\right) \]
    9. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(t \cdot \left(j + -1 \cdot \color{blue}{\frac{k \cdot y}{t}}\right)\right)\right) \]
      2. lower-+.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(t \cdot \left(j + -1 \cdot \frac{k \cdot y}{\color{blue}{t}}\right)\right)\right) \]
      3. lower-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(t \cdot \left(j + -1 \cdot \frac{k \cdot y}{t}\right)\right)\right) \]
      4. lower-/.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(t \cdot \left(j + -1 \cdot \frac{k \cdot y}{t}\right)\right)\right) \]
      5. lift-*.f6429.0

        \[\leadsto b \cdot \left(y4 \cdot \left(t \cdot \left(j + -1 \cdot \frac{k \cdot y}{t}\right)\right)\right) \]
    10. Applied rewrites29.0%

      \[\leadsto b \cdot \left(y4 \cdot \left(t \cdot \left(j + \color{blue}{-1 \cdot \frac{k \cdot y}{t}}\right)\right)\right) \]

    if 7.5999999999999996e-11 < y1 < 4.4999999999999997e82

    1. Initial program 30.9%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y3 around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \color{blue}{\left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{y \cdot \left(c \cdot y4 - a \cdot y5\right)}\right)\right) \]
    4. Applied rewrites39.7%

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\mathsf{fma}\left(j, y1 \cdot y4 - y0 \cdot y5, z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    5. Taylor expanded in y5 around -inf

      \[\leadsto y3 \cdot \color{blue}{\left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \color{blue}{\left(j \cdot y0 - a \cdot y\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - \color{blue}{a \cdot y}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot \color{blue}{y}\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right) \]
      5. lower-*.f6428.2

        \[\leadsto y3 \cdot \left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right) \]
    7. Applied rewrites28.2%

      \[\leadsto y3 \cdot \color{blue}{\left(y5 \cdot \left(j \cdot y0 - a \cdot y\right)\right)} \]

    if 4.4999999999999997e82 < y1

    1. Initial program 22.6%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites39.6%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in x around inf

      \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \color{blue}{\left(c \cdot y - j \cdot y1\right)}\right)\right) \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - \color{blue}{j \cdot y1}\right)\right)\right) \]
      2. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot \color{blue}{y1}\right)\right)\right) \]
      3. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right) \]
      4. lower-*.f6435.7

        \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \left(c \cdot y - j \cdot y1\right)\right)\right) \]
    7. Applied rewrites35.7%

      \[\leadsto -1 \cdot \left(i \cdot \left(x \cdot \color{blue}{\left(c \cdot y - j \cdot y1\right)}\right)\right) \]
  3. Recombined 3 regimes into one program.
  4. Add Preprocessing

Alternative 21: 26.9% accurate, 4.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := a \cdot \left(y3 \cdot \left(y1 \cdot z - y \cdot y5\right)\right)\\ \mathbf{if}\;y5 \leq -1.9 \cdot 10^{-158}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y5 \leq 1.4 \cdot 10^{-127}:\\ \;\;\;\;i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot x\right)\right)\right)\\ \mathbf{elif}\;y5 \leq 2.15 \cdot 10^{+98}:\\ \;\;\;\;i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (let* ((t_1 (* a (* y3 (- (* y1 z) (* y y5))))))
   (if (<= y5 -1.9e-158)
     t_1
     (if (<= y5 1.4e-127)
       (* i (* y (* -1.0 (* c x))))
       (if (<= y5 2.15e+98) (* i (* y1 (- (* j x) (* k z)))) t_1)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = a * (y3 * ((y1 * z) - (y * y5)));
	double tmp;
	if (y5 <= -1.9e-158) {
		tmp = t_1;
	} else if (y5 <= 1.4e-127) {
		tmp = i * (y * (-1.0 * (c * x)));
	} else if (y5 <= 2.15e+98) {
		tmp = i * (y1 * ((j * x) - (k * z)));
	} else {
		tmp = t_1;
	}
	return tmp;
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8), intent (in) :: y0
    real(8), intent (in) :: y1
    real(8), intent (in) :: y2
    real(8), intent (in) :: y3
    real(8), intent (in) :: y4
    real(8), intent (in) :: y5
    real(8) :: t_1
    real(8) :: tmp
    t_1 = a * (y3 * ((y1 * z) - (y * y5)))
    if (y5 <= (-1.9d-158)) then
        tmp = t_1
    else if (y5 <= 1.4d-127) then
        tmp = i * (y * ((-1.0d0) * (c * x)))
    else if (y5 <= 2.15d+98) then
        tmp = i * (y1 * ((j * x) - (k * z)))
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = a * (y3 * ((y1 * z) - (y * y5)));
	double tmp;
	if (y5 <= -1.9e-158) {
		tmp = t_1;
	} else if (y5 <= 1.4e-127) {
		tmp = i * (y * (-1.0 * (c * x)));
	} else if (y5 <= 2.15e+98) {
		tmp = i * (y1 * ((j * x) - (k * z)));
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5):
	t_1 = a * (y3 * ((y1 * z) - (y * y5)))
	tmp = 0
	if y5 <= -1.9e-158:
		tmp = t_1
	elif y5 <= 1.4e-127:
		tmp = i * (y * (-1.0 * (c * x)))
	elif y5 <= 2.15e+98:
		tmp = i * (y1 * ((j * x) - (k * z)))
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = Float64(a * Float64(y3 * Float64(Float64(y1 * z) - Float64(y * y5))))
	tmp = 0.0
	if (y5 <= -1.9e-158)
		tmp = t_1;
	elseif (y5 <= 1.4e-127)
		tmp = Float64(i * Float64(y * Float64(-1.0 * Float64(c * x))));
	elseif (y5 <= 2.15e+98)
		tmp = Float64(i * Float64(y1 * Float64(Float64(j * x) - Float64(k * z))));
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = a * (y3 * ((y1 * z) - (y * y5)));
	tmp = 0.0;
	if (y5 <= -1.9e-158)
		tmp = t_1;
	elseif (y5 <= 1.4e-127)
		tmp = i * (y * (-1.0 * (c * x)));
	elseif (y5 <= 2.15e+98)
		tmp = i * (y1 * ((j * x) - (k * z)));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(a * N[(y3 * N[(N[(y1 * z), $MachinePrecision] - N[(y * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y5, -1.9e-158], t$95$1, If[LessEqual[y5, 1.4e-127], N[(i * N[(y * N[(-1.0 * N[(c * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y5, 2.15e+98], N[(i * N[(y1 * N[(N[(j * x), $MachinePrecision] - N[(k * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := a \cdot \left(y3 \cdot \left(y1 \cdot z - y \cdot y5\right)\right)\\
\mathbf{if}\;y5 \leq -1.9 \cdot 10^{-158}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;y5 \leq 1.4 \cdot 10^{-127}:\\
\;\;\;\;i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot x\right)\right)\right)\\

\mathbf{elif}\;y5 \leq 2.15 \cdot 10^{+98}:\\
\;\;\;\;i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\\

\mathbf{else}:\\
\;\;\;\;t\_1\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y5 < -1.8999999999999999e-158 or 2.1500000000000001e98 < y5

    1. Initial program 27.6%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y3 around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \color{blue}{\left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{y \cdot \left(c \cdot y4 - a \cdot y5\right)}\right)\right) \]
    4. Applied rewrites37.2%

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\mathsf{fma}\left(j, y1 \cdot y4 - y0 \cdot y5, z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    5. Taylor expanded in a around -inf

      \[\leadsto a \cdot \color{blue}{\left(y3 \cdot \left(y1 \cdot z - y \cdot y5\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto a \cdot \left(y3 \cdot \color{blue}{\left(y1 \cdot z - y \cdot y5\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto a \cdot \left(y3 \cdot \left(y1 \cdot z - \color{blue}{y \cdot y5}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto a \cdot \left(y3 \cdot \left(y1 \cdot z - y \cdot \color{blue}{y5}\right)\right) \]
      4. lift-*.f64N/A

        \[\leadsto a \cdot \left(y3 \cdot \left(y1 \cdot z - y \cdot y5\right)\right) \]
      5. lift-*.f6431.2

        \[\leadsto a \cdot \left(y3 \cdot \left(y1 \cdot z - y \cdot y5\right)\right) \]
    7. Applied rewrites31.2%

      \[\leadsto a \cdot \color{blue}{\left(y3 \cdot \left(y1 \cdot z - y \cdot y5\right)\right)} \]

    if -1.8999999999999999e-158 < y5 < 1.4e-127

    1. Initial program 35.2%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites34.4%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in y around -inf

      \[\leadsto i \cdot \color{blue}{\left(y \cdot \left(-1 \cdot \left(c \cdot x\right) + k \cdot y5\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \color{blue}{\left(-1 \cdot \left(c \cdot x\right) + k \cdot y5\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot x\right) + \color{blue}{k \cdot y5}\right)\right) \]
      3. lower-fma.f64N/A

        \[\leadsto i \cdot \left(y \cdot \mathsf{fma}\left(-1, c \cdot \color{blue}{x}, k \cdot y5\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \mathsf{fma}\left(-1, c \cdot x, k \cdot y5\right)\right) \]
      5. lower-*.f6418.5

        \[\leadsto i \cdot \left(y \cdot \mathsf{fma}\left(-1, c \cdot x, k \cdot y5\right)\right) \]
    7. Applied rewrites18.5%

      \[\leadsto i \cdot \color{blue}{\left(y \cdot \mathsf{fma}\left(-1, c \cdot x, k \cdot y5\right)\right)} \]
    8. Taylor expanded in x around inf

      \[\leadsto i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot \color{blue}{x}\right)\right)\right) \]
    9. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot x\right)\right)\right) \]
      2. lift-*.f6417.2

        \[\leadsto i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot x\right)\right)\right) \]
    10. Applied rewrites17.2%

      \[\leadsto i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot \color{blue}{x}\right)\right)\right) \]

    if 1.4e-127 < y5 < 2.1500000000000001e98

    1. Initial program 31.5%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites37.5%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in y1 around -inf

      \[\leadsto i \cdot \color{blue}{\left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \color{blue}{\left(j \cdot x - k \cdot z\right)}\right) \]
      2. lift-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right) \]
      3. lift-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right) \]
      4. lift--.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot \color{blue}{z}\right)\right) \]
      5. lift-*.f6428.6

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - \color{blue}{k \cdot z}\right)\right) \]
    7. Applied rewrites28.6%

      \[\leadsto i \cdot \color{blue}{\left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
  3. Recombined 3 regimes into one program.
  4. Add Preprocessing

Alternative 22: 27.5% accurate, 4.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot x\right)\right)\right)\\ \mathbf{if}\;c \leq -3.25 \cdot 10^{+112}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;c \leq -7.6 \cdot 10^{-8}:\\ \;\;\;\;b \cdot \left(y4 \cdot \left(j \cdot t\right)\right)\\ \mathbf{elif}\;c \leq 2.3 \cdot 10^{+25}:\\ \;\;\;\;i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (let* ((t_1 (* i (* y (* -1.0 (* c x))))))
   (if (<= c -3.25e+112)
     t_1
     (if (<= c -7.6e-8)
       (* b (* y4 (* j t)))
       (if (<= c 2.3e+25) (* i (* y1 (- (* j x) (* k z)))) t_1)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = i * (y * (-1.0 * (c * x)));
	double tmp;
	if (c <= -3.25e+112) {
		tmp = t_1;
	} else if (c <= -7.6e-8) {
		tmp = b * (y4 * (j * t));
	} else if (c <= 2.3e+25) {
		tmp = i * (y1 * ((j * x) - (k * z)));
	} else {
		tmp = t_1;
	}
	return tmp;
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8), intent (in) :: y0
    real(8), intent (in) :: y1
    real(8), intent (in) :: y2
    real(8), intent (in) :: y3
    real(8), intent (in) :: y4
    real(8), intent (in) :: y5
    real(8) :: t_1
    real(8) :: tmp
    t_1 = i * (y * ((-1.0d0) * (c * x)))
    if (c <= (-3.25d+112)) then
        tmp = t_1
    else if (c <= (-7.6d-8)) then
        tmp = b * (y4 * (j * t))
    else if (c <= 2.3d+25) then
        tmp = i * (y1 * ((j * x) - (k * z)))
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = i * (y * (-1.0 * (c * x)));
	double tmp;
	if (c <= -3.25e+112) {
		tmp = t_1;
	} else if (c <= -7.6e-8) {
		tmp = b * (y4 * (j * t));
	} else if (c <= 2.3e+25) {
		tmp = i * (y1 * ((j * x) - (k * z)));
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5):
	t_1 = i * (y * (-1.0 * (c * x)))
	tmp = 0
	if c <= -3.25e+112:
		tmp = t_1
	elif c <= -7.6e-8:
		tmp = b * (y4 * (j * t))
	elif c <= 2.3e+25:
		tmp = i * (y1 * ((j * x) - (k * z)))
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = Float64(i * Float64(y * Float64(-1.0 * Float64(c * x))))
	tmp = 0.0
	if (c <= -3.25e+112)
		tmp = t_1;
	elseif (c <= -7.6e-8)
		tmp = Float64(b * Float64(y4 * Float64(j * t)));
	elseif (c <= 2.3e+25)
		tmp = Float64(i * Float64(y1 * Float64(Float64(j * x) - Float64(k * z))));
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = i * (y * (-1.0 * (c * x)));
	tmp = 0.0;
	if (c <= -3.25e+112)
		tmp = t_1;
	elseif (c <= -7.6e-8)
		tmp = b * (y4 * (j * t));
	elseif (c <= 2.3e+25)
		tmp = i * (y1 * ((j * x) - (k * z)));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(i * N[(y * N[(-1.0 * N[(c * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[c, -3.25e+112], t$95$1, If[LessEqual[c, -7.6e-8], N[(b * N[(y4 * N[(j * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[c, 2.3e+25], N[(i * N[(y1 * N[(N[(j * x), $MachinePrecision] - N[(k * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot x\right)\right)\right)\\
\mathbf{if}\;c \leq -3.25 \cdot 10^{+112}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;c \leq -7.6 \cdot 10^{-8}:\\
\;\;\;\;b \cdot \left(y4 \cdot \left(j \cdot t\right)\right)\\

\mathbf{elif}\;c \leq 2.3 \cdot 10^{+25}:\\
\;\;\;\;i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\\

\mathbf{else}:\\
\;\;\;\;t\_1\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if c < -3.2499999999999999e112 or 2.2999999999999998e25 < c

    1. Initial program 24.8%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites40.3%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in y around -inf

      \[\leadsto i \cdot \color{blue}{\left(y \cdot \left(-1 \cdot \left(c \cdot x\right) + k \cdot y5\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \color{blue}{\left(-1 \cdot \left(c \cdot x\right) + k \cdot y5\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot x\right) + \color{blue}{k \cdot y5}\right)\right) \]
      3. lower-fma.f64N/A

        \[\leadsto i \cdot \left(y \cdot \mathsf{fma}\left(-1, c \cdot \color{blue}{x}, k \cdot y5\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \mathsf{fma}\left(-1, c \cdot x, k \cdot y5\right)\right) \]
      5. lower-*.f6434.5

        \[\leadsto i \cdot \left(y \cdot \mathsf{fma}\left(-1, c \cdot x, k \cdot y5\right)\right) \]
    7. Applied rewrites34.5%

      \[\leadsto i \cdot \color{blue}{\left(y \cdot \mathsf{fma}\left(-1, c \cdot x, k \cdot y5\right)\right)} \]
    8. Taylor expanded in x around inf

      \[\leadsto i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot \color{blue}{x}\right)\right)\right) \]
    9. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot x\right)\right)\right) \]
      2. lift-*.f6429.5

        \[\leadsto i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot x\right)\right)\right) \]
    10. Applied rewrites29.5%

      \[\leadsto i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot \color{blue}{x}\right)\right)\right) \]

    if -3.2499999999999999e112 < c < -7.60000000000000056e-8

    1. Initial program 32.3%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in b around inf

      \[\leadsto \color{blue}{b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto b \cdot \color{blue}{\left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y0 \cdot \left(j \cdot x - k \cdot z\right)}\right) \]
    4. Applied rewrites36.8%

      \[\leadsto \color{blue}{b \cdot \left(\mathsf{fma}\left(a, x \cdot y - t \cdot z, y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    5. Taylor expanded in y4 around inf

      \[\leadsto b \cdot \left(y4 \cdot \color{blue}{\left(j \cdot t - k \cdot y\right)}\right) \]
    6. Step-by-step derivation
      1. lift-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot y\right)\right) \]
      2. lift-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot y\right)\right) \]
      3. lift--.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot \color{blue}{y}\right)\right) \]
      4. lift-*.f6425.4

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - \color{blue}{k \cdot y}\right)\right) \]
    7. Applied rewrites25.4%

      \[\leadsto b \cdot \left(y4 \cdot \color{blue}{\left(j \cdot t - k \cdot y\right)}\right) \]
    8. Taylor expanded in y around 0

      \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t\right)\right) \]
    9. Step-by-step derivation
      1. lift-*.f6417.4

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t\right)\right) \]
    10. Applied rewrites17.4%

      \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t\right)\right) \]

    if -7.60000000000000056e-8 < c < 2.2999999999999998e25

    1. Initial program 34.2%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites35.5%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in y1 around -inf

      \[\leadsto i \cdot \color{blue}{\left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \color{blue}{\left(j \cdot x - k \cdot z\right)}\right) \]
      2. lift-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right) \]
      3. lift-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right) \]
      4. lift--.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot \color{blue}{z}\right)\right) \]
      5. lift-*.f6428.0

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - \color{blue}{k \cdot z}\right)\right) \]
    7. Applied rewrites28.0%

      \[\leadsto i \cdot \color{blue}{\left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
  3. Recombined 3 regimes into one program.
  4. Add Preprocessing

Alternative 23: 21.2% accurate, 5.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := b \cdot \left(y4 \cdot \left(j \cdot t\right)\right)\\ \mathbf{if}\;j \leq -1 \cdot 10^{+106}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;j \leq -1.55 \cdot 10^{-268}:\\ \;\;\;\;i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot x\right)\right)\right)\\ \mathbf{elif}\;j \leq 3.3 \cdot 10^{-36}:\\ \;\;\;\;-1 \cdot \left(a \cdot \left(b \cdot \left(t \cdot z\right)\right)\right)\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (let* ((t_1 (* b (* y4 (* j t)))))
   (if (<= j -1e+106)
     t_1
     (if (<= j -1.55e-268)
       (* i (* y (* -1.0 (* c x))))
       (if (<= j 3.3e-36) (* -1.0 (* a (* b (* t z)))) t_1)))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = b * (y4 * (j * t));
	double tmp;
	if (j <= -1e+106) {
		tmp = t_1;
	} else if (j <= -1.55e-268) {
		tmp = i * (y * (-1.0 * (c * x)));
	} else if (j <= 3.3e-36) {
		tmp = -1.0 * (a * (b * (t * z)));
	} else {
		tmp = t_1;
	}
	return tmp;
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8), intent (in) :: y0
    real(8), intent (in) :: y1
    real(8), intent (in) :: y2
    real(8), intent (in) :: y3
    real(8), intent (in) :: y4
    real(8), intent (in) :: y5
    real(8) :: t_1
    real(8) :: tmp
    t_1 = b * (y4 * (j * t))
    if (j <= (-1d+106)) then
        tmp = t_1
    else if (j <= (-1.55d-268)) then
        tmp = i * (y * ((-1.0d0) * (c * x)))
    else if (j <= 3.3d-36) then
        tmp = (-1.0d0) * (a * (b * (t * z)))
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = b * (y4 * (j * t));
	double tmp;
	if (j <= -1e+106) {
		tmp = t_1;
	} else if (j <= -1.55e-268) {
		tmp = i * (y * (-1.0 * (c * x)));
	} else if (j <= 3.3e-36) {
		tmp = -1.0 * (a * (b * (t * z)));
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5):
	t_1 = b * (y4 * (j * t))
	tmp = 0
	if j <= -1e+106:
		tmp = t_1
	elif j <= -1.55e-268:
		tmp = i * (y * (-1.0 * (c * x)))
	elif j <= 3.3e-36:
		tmp = -1.0 * (a * (b * (t * z)))
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = Float64(b * Float64(y4 * Float64(j * t)))
	tmp = 0.0
	if (j <= -1e+106)
		tmp = t_1;
	elseif (j <= -1.55e-268)
		tmp = Float64(i * Float64(y * Float64(-1.0 * Float64(c * x))));
	elseif (j <= 3.3e-36)
		tmp = Float64(-1.0 * Float64(a * Float64(b * Float64(t * z))));
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = b * (y4 * (j * t));
	tmp = 0.0;
	if (j <= -1e+106)
		tmp = t_1;
	elseif (j <= -1.55e-268)
		tmp = i * (y * (-1.0 * (c * x)));
	elseif (j <= 3.3e-36)
		tmp = -1.0 * (a * (b * (t * z)));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(b * N[(y4 * N[(j * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[j, -1e+106], t$95$1, If[LessEqual[j, -1.55e-268], N[(i * N[(y * N[(-1.0 * N[(c * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[j, 3.3e-36], N[(-1.0 * N[(a * N[(b * N[(t * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := b \cdot \left(y4 \cdot \left(j \cdot t\right)\right)\\
\mathbf{if}\;j \leq -1 \cdot 10^{+106}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;j \leq -1.55 \cdot 10^{-268}:\\
\;\;\;\;i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot x\right)\right)\right)\\

\mathbf{elif}\;j \leq 3.3 \cdot 10^{-36}:\\
\;\;\;\;-1 \cdot \left(a \cdot \left(b \cdot \left(t \cdot z\right)\right)\right)\\

\mathbf{else}:\\
\;\;\;\;t\_1\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if j < -1.00000000000000009e106 or 3.29999999999999991e-36 < j

    1. Initial program 25.7%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in b around inf

      \[\leadsto \color{blue}{b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto b \cdot \color{blue}{\left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y0 \cdot \left(j \cdot x - k \cdot z\right)}\right) \]
    4. Applied rewrites36.6%

      \[\leadsto \color{blue}{b \cdot \left(\mathsf{fma}\left(a, x \cdot y - t \cdot z, y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    5. Taylor expanded in y4 around inf

      \[\leadsto b \cdot \left(y4 \cdot \color{blue}{\left(j \cdot t - k \cdot y\right)}\right) \]
    6. Step-by-step derivation
      1. lift-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot y\right)\right) \]
      2. lift-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot y\right)\right) \]
      3. lift--.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot \color{blue}{y}\right)\right) \]
      4. lift-*.f6432.4

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - \color{blue}{k \cdot y}\right)\right) \]
    7. Applied rewrites32.4%

      \[\leadsto b \cdot \left(y4 \cdot \color{blue}{\left(j \cdot t - k \cdot y\right)}\right) \]
    8. Taylor expanded in y around 0

      \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t\right)\right) \]
    9. Step-by-step derivation
      1. lift-*.f6426.7

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t\right)\right) \]
    10. Applied rewrites26.7%

      \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t\right)\right) \]

    if -1.00000000000000009e106 < j < -1.5499999999999999e-268

    1. Initial program 33.1%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites36.4%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in y around -inf

      \[\leadsto i \cdot \color{blue}{\left(y \cdot \left(-1 \cdot \left(c \cdot x\right) + k \cdot y5\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \color{blue}{\left(-1 \cdot \left(c \cdot x\right) + k \cdot y5\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot x\right) + \color{blue}{k \cdot y5}\right)\right) \]
      3. lower-fma.f64N/A

        \[\leadsto i \cdot \left(y \cdot \mathsf{fma}\left(-1, c \cdot \color{blue}{x}, k \cdot y5\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \mathsf{fma}\left(-1, c \cdot x, k \cdot y5\right)\right) \]
      5. lower-*.f6426.1

        \[\leadsto i \cdot \left(y \cdot \mathsf{fma}\left(-1, c \cdot x, k \cdot y5\right)\right) \]
    7. Applied rewrites26.1%

      \[\leadsto i \cdot \color{blue}{\left(y \cdot \mathsf{fma}\left(-1, c \cdot x, k \cdot y5\right)\right)} \]
    8. Taylor expanded in x around inf

      \[\leadsto i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot \color{blue}{x}\right)\right)\right) \]
    9. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot x\right)\right)\right) \]
      2. lift-*.f6416.7

        \[\leadsto i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot x\right)\right)\right) \]
    10. Applied rewrites16.7%

      \[\leadsto i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot \color{blue}{x}\right)\right)\right) \]

    if -1.5499999999999999e-268 < j < 3.29999999999999991e-36

    1. Initial program 35.3%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in t around inf

      \[\leadsto \color{blue}{t \cdot \left(\left(-1 \cdot \left(z \cdot \left(a \cdot b - c \cdot i\right)\right) + j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - y2 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto t \cdot \color{blue}{\left(\left(-1 \cdot \left(z \cdot \left(a \cdot b - c \cdot i\right)\right) + j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - y2 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto t \cdot \left(\left(-1 \cdot \left(z \cdot \left(a \cdot b - c \cdot i\right)\right) + j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - \color{blue}{y2 \cdot \left(c \cdot y4 - a \cdot y5\right)}\right) \]
    4. Applied rewrites33.7%

      \[\leadsto \color{blue}{t \cdot \left(\mathsf{fma}\left(-1, z \cdot \left(a \cdot b - c \cdot i\right), j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - y2 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
    5. Taylor expanded in a around -inf

      \[\leadsto -1 \cdot \color{blue}{\left(a \cdot \left(t \cdot \left(b \cdot z - y2 \cdot y5\right)\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(a \cdot \color{blue}{\left(t \cdot \left(b \cdot z - y2 \cdot y5\right)\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(a \cdot \left(t \cdot \color{blue}{\left(b \cdot z - y2 \cdot y5\right)}\right)\right) \]
      3. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(a \cdot \left(t \cdot \left(b \cdot z - \color{blue}{y2 \cdot y5}\right)\right)\right) \]
      4. lower--.f64N/A

        \[\leadsto -1 \cdot \left(a \cdot \left(t \cdot \left(b \cdot z - y2 \cdot \color{blue}{y5}\right)\right)\right) \]
      5. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(a \cdot \left(t \cdot \left(b \cdot z - y2 \cdot y5\right)\right)\right) \]
      6. lower-*.f6427.0

        \[\leadsto -1 \cdot \left(a \cdot \left(t \cdot \left(b \cdot z - y2 \cdot y5\right)\right)\right) \]
    7. Applied rewrites27.0%

      \[\leadsto -1 \cdot \color{blue}{\left(a \cdot \left(t \cdot \left(b \cdot z - y2 \cdot y5\right)\right)\right)} \]
    8. Taylor expanded in z around inf

      \[\leadsto -1 \cdot \left(a \cdot \left(b \cdot \left(t \cdot \color{blue}{z}\right)\right)\right) \]
    9. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(a \cdot \left(b \cdot \left(t \cdot z\right)\right)\right) \]
      2. lower-*.f6416.9

        \[\leadsto -1 \cdot \left(a \cdot \left(b \cdot \left(t \cdot z\right)\right)\right) \]
    10. Applied rewrites16.9%

      \[\leadsto -1 \cdot \left(a \cdot \left(b \cdot \left(t \cdot \color{blue}{z}\right)\right)\right) \]
  3. Recombined 3 regimes into one program.
  4. Add Preprocessing

Alternative 24: 32.5% accurate, 5.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\\ \mathbf{if}\;y1 \leq -1.26 \cdot 10^{+25}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y1 \leq 8.5 \cdot 10^{+87}:\\ \;\;\;\;y \cdot \left(y3 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (let* ((t_1 (* i (* y1 (- (* j x) (* k z))))))
   (if (<= y1 -1.26e+25)
     t_1
     (if (<= y1 8.5e+87) (* y (* y3 (- (* c y4) (* a y5)))) t_1))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = i * (y1 * ((j * x) - (k * z)));
	double tmp;
	if (y1 <= -1.26e+25) {
		tmp = t_1;
	} else if (y1 <= 8.5e+87) {
		tmp = y * (y3 * ((c * y4) - (a * y5)));
	} else {
		tmp = t_1;
	}
	return tmp;
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8), intent (in) :: y0
    real(8), intent (in) :: y1
    real(8), intent (in) :: y2
    real(8), intent (in) :: y3
    real(8), intent (in) :: y4
    real(8), intent (in) :: y5
    real(8) :: t_1
    real(8) :: tmp
    t_1 = i * (y1 * ((j * x) - (k * z)))
    if (y1 <= (-1.26d+25)) then
        tmp = t_1
    else if (y1 <= 8.5d+87) then
        tmp = y * (y3 * ((c * y4) - (a * y5)))
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = i * (y1 * ((j * x) - (k * z)));
	double tmp;
	if (y1 <= -1.26e+25) {
		tmp = t_1;
	} else if (y1 <= 8.5e+87) {
		tmp = y * (y3 * ((c * y4) - (a * y5)));
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5):
	t_1 = i * (y1 * ((j * x) - (k * z)))
	tmp = 0
	if y1 <= -1.26e+25:
		tmp = t_1
	elif y1 <= 8.5e+87:
		tmp = y * (y3 * ((c * y4) - (a * y5)))
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = Float64(i * Float64(y1 * Float64(Float64(j * x) - Float64(k * z))))
	tmp = 0.0
	if (y1 <= -1.26e+25)
		tmp = t_1;
	elseif (y1 <= 8.5e+87)
		tmp = Float64(y * Float64(y3 * Float64(Float64(c * y4) - Float64(a * y5))));
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = i * (y1 * ((j * x) - (k * z)));
	tmp = 0.0;
	if (y1 <= -1.26e+25)
		tmp = t_1;
	elseif (y1 <= 8.5e+87)
		tmp = y * (y3 * ((c * y4) - (a * y5)));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(i * N[(y1 * N[(N[(j * x), $MachinePrecision] - N[(k * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y1, -1.26e+25], t$95$1, If[LessEqual[y1, 8.5e+87], N[(y * N[(y3 * N[(N[(c * y4), $MachinePrecision] - N[(a * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\\
\mathbf{if}\;y1 \leq -1.26 \cdot 10^{+25}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;y1 \leq 8.5 \cdot 10^{+87}:\\
\;\;\;\;y \cdot \left(y3 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\\

\mathbf{else}:\\
\;\;\;\;t\_1\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y1 < -1.26000000000000008e25 or 8.5000000000000001e87 < y1

    1. Initial program 24.5%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites39.4%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in y1 around -inf

      \[\leadsto i \cdot \color{blue}{\left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \color{blue}{\left(j \cdot x - k \cdot z\right)}\right) \]
      2. lift-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right) \]
      3. lift-*.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right) \]
      4. lift--.f64N/A

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - k \cdot \color{blue}{z}\right)\right) \]
      5. lift-*.f6440.2

        \[\leadsto i \cdot \left(y1 \cdot \left(j \cdot x - \color{blue}{k \cdot z}\right)\right) \]
    7. Applied rewrites40.2%

      \[\leadsto i \cdot \color{blue}{\left(y1 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]

    if -1.26000000000000008e25 < y1 < 8.5000000000000001e87

    1. Initial program 34.5%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in y3 around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \color{blue}{\left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(y3 \cdot \left(\left(j \cdot \left(y1 \cdot y4 - y0 \cdot y5\right) + z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - \color{blue}{y \cdot \left(c \cdot y4 - a \cdot y5\right)}\right)\right) \]
    4. Applied rewrites37.1%

      \[\leadsto \color{blue}{-1 \cdot \left(y3 \cdot \left(\mathsf{fma}\left(j, y1 \cdot y4 - y0 \cdot y5, z \cdot \left(c \cdot y0 - a \cdot y1\right)\right) - y \cdot \left(c \cdot y4 - a \cdot y5\right)\right)\right)} \]
    5. Taylor expanded in y around -inf

      \[\leadsto y \cdot \color{blue}{\left(y3 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto y \cdot \left(y3 \cdot \color{blue}{\left(c \cdot y4 - a \cdot y5\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto y \cdot \left(y3 \cdot \left(c \cdot y4 - \color{blue}{a \cdot y5}\right)\right) \]
      3. lift-*.f64N/A

        \[\leadsto y \cdot \left(y3 \cdot \left(c \cdot y4 - a \cdot y5\right)\right) \]
      4. lift-*.f64N/A

        \[\leadsto y \cdot \left(y3 \cdot \left(c \cdot y4 - a \cdot y5\right)\right) \]
      5. lift--.f6427.2

        \[\leadsto y \cdot \left(y3 \cdot \left(c \cdot y4 - a \cdot \color{blue}{y5}\right)\right) \]
    7. Applied rewrites27.2%

      \[\leadsto y \cdot \color{blue}{\left(y3 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
  3. Recombined 2 regimes into one program.
  4. Add Preprocessing

Alternative 25: 29.0% accurate, 5.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;t \leq -3.4 \cdot 10^{+114}:\\ \;\;\;\;i \cdot \left(z \cdot \left(c \cdot t\right)\right)\\ \mathbf{elif}\;t \leq 1.25 \cdot 10^{+89}:\\ \;\;\;\;i \cdot \left(k \cdot \left(y \cdot y5 - y1 \cdot z\right)\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot \left(y4 \cdot \left(j \cdot t\right)\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (if (<= t -3.4e+114)
   (* i (* z (* c t)))
   (if (<= t 1.25e+89)
     (* i (* k (- (* y y5) (* y1 z))))
     (* b (* y4 (* j t))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double tmp;
	if (t <= -3.4e+114) {
		tmp = i * (z * (c * t));
	} else if (t <= 1.25e+89) {
		tmp = i * (k * ((y * y5) - (y1 * z)));
	} else {
		tmp = b * (y4 * (j * t));
	}
	return tmp;
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8), intent (in) :: y0
    real(8), intent (in) :: y1
    real(8), intent (in) :: y2
    real(8), intent (in) :: y3
    real(8), intent (in) :: y4
    real(8), intent (in) :: y5
    real(8) :: tmp
    if (t <= (-3.4d+114)) then
        tmp = i * (z * (c * t))
    else if (t <= 1.25d+89) then
        tmp = i * (k * ((y * y5) - (y1 * z)))
    else
        tmp = b * (y4 * (j * t))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double tmp;
	if (t <= -3.4e+114) {
		tmp = i * (z * (c * t));
	} else if (t <= 1.25e+89) {
		tmp = i * (k * ((y * y5) - (y1 * z)));
	} else {
		tmp = b * (y4 * (j * t));
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5):
	tmp = 0
	if t <= -3.4e+114:
		tmp = i * (z * (c * t))
	elif t <= 1.25e+89:
		tmp = i * (k * ((y * y5) - (y1 * z)))
	else:
		tmp = b * (y4 * (j * t))
	return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	tmp = 0.0
	if (t <= -3.4e+114)
		tmp = Float64(i * Float64(z * Float64(c * t)));
	elseif (t <= 1.25e+89)
		tmp = Float64(i * Float64(k * Float64(Float64(y * y5) - Float64(y1 * z))));
	else
		tmp = Float64(b * Float64(y4 * Float64(j * t)));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	tmp = 0.0;
	if (t <= -3.4e+114)
		tmp = i * (z * (c * t));
	elseif (t <= 1.25e+89)
		tmp = i * (k * ((y * y5) - (y1 * z)));
	else
		tmp = b * (y4 * (j * t));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := If[LessEqual[t, -3.4e+114], N[(i * N[(z * N[(c * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.25e+89], N[(i * N[(k * N[(N[(y * y5), $MachinePrecision] - N[(y1 * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(b * N[(y4 * N[(j * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;t \leq -3.4 \cdot 10^{+114}:\\
\;\;\;\;i \cdot \left(z \cdot \left(c \cdot t\right)\right)\\

\mathbf{elif}\;t \leq 1.25 \cdot 10^{+89}:\\
\;\;\;\;i \cdot \left(k \cdot \left(y \cdot y5 - y1 \cdot z\right)\right)\\

\mathbf{else}:\\
\;\;\;\;b \cdot \left(y4 \cdot \left(j \cdot t\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -3.4000000000000001e114

    1. Initial program 23.6%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites39.5%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in z around -inf

      \[\leadsto i \cdot \color{blue}{\left(z \cdot \left(c \cdot t - k \cdot y1\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \color{blue}{\left(c \cdot t - k \cdot y1\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - \color{blue}{k \cdot y1}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot \color{blue}{y1}\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot y1\right)\right) \]
      5. lower-*.f6436.5

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot y1\right)\right) \]
    7. Applied rewrites36.5%

      \[\leadsto i \cdot \color{blue}{\left(z \cdot \left(c \cdot t - k \cdot y1\right)\right)} \]
    8. Taylor expanded in t around inf

      \[\leadsto i \cdot \left(z \cdot \left(c \cdot t\right)\right) \]
    9. Step-by-step derivation
      1. lift-*.f6431.4

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t\right)\right) \]
    10. Applied rewrites31.4%

      \[\leadsto i \cdot \left(z \cdot \left(c \cdot t\right)\right) \]

    if -3.4000000000000001e114 < t < 1.24999999999999996e89

    1. Initial program 33.7%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites37.6%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in k around -inf

      \[\leadsto i \cdot \color{blue}{\left(k \cdot \left(y \cdot y5 - y1 \cdot z\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(k \cdot \color{blue}{\left(y \cdot y5 - y1 \cdot z\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5 - \color{blue}{y1 \cdot z}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5 - y1 \cdot \color{blue}{z}\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5 - y1 \cdot z\right)\right) \]
      5. lower-*.f6428.0

        \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5 - y1 \cdot z\right)\right) \]
    7. Applied rewrites28.0%

      \[\leadsto i \cdot \color{blue}{\left(k \cdot \left(y \cdot y5 - y1 \cdot z\right)\right)} \]

    if 1.24999999999999996e89 < t

    1. Initial program 23.6%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in b around inf

      \[\leadsto \color{blue}{b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto b \cdot \color{blue}{\left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y0 \cdot \left(j \cdot x - k \cdot z\right)}\right) \]
    4. Applied rewrites38.1%

      \[\leadsto \color{blue}{b \cdot \left(\mathsf{fma}\left(a, x \cdot y - t \cdot z, y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    5. Taylor expanded in y4 around inf

      \[\leadsto b \cdot \left(y4 \cdot \color{blue}{\left(j \cdot t - k \cdot y\right)}\right) \]
    6. Step-by-step derivation
      1. lift-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot y\right)\right) \]
      2. lift-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot y\right)\right) \]
      3. lift--.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot \color{blue}{y}\right)\right) \]
      4. lift-*.f6436.7

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - \color{blue}{k \cdot y}\right)\right) \]
    7. Applied rewrites36.7%

      \[\leadsto b \cdot \left(y4 \cdot \color{blue}{\left(j \cdot t - k \cdot y\right)}\right) \]
    8. Taylor expanded in y around 0

      \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t\right)\right) \]
    9. Step-by-step derivation
      1. lift-*.f6431.0

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t\right)\right) \]
    10. Applied rewrites31.0%

      \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t\right)\right) \]
  3. Recombined 3 regimes into one program.
  4. Add Preprocessing

Alternative 26: 21.8% accurate, 6.1× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot x\right)\right)\right)\\ \mathbf{if}\;c \leq -3.25 \cdot 10^{+112}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;c \leq 3.1 \cdot 10^{-5}:\\ \;\;\;\;b \cdot \left(y4 \cdot \left(j \cdot t\right)\right)\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (let* ((t_1 (* i (* y (* -1.0 (* c x))))))
   (if (<= c -3.25e+112) t_1 (if (<= c 3.1e-5) (* b (* y4 (* j t))) t_1))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = i * (y * (-1.0 * (c * x)));
	double tmp;
	if (c <= -3.25e+112) {
		tmp = t_1;
	} else if (c <= 3.1e-5) {
		tmp = b * (y4 * (j * t));
	} else {
		tmp = t_1;
	}
	return tmp;
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8), intent (in) :: y0
    real(8), intent (in) :: y1
    real(8), intent (in) :: y2
    real(8), intent (in) :: y3
    real(8), intent (in) :: y4
    real(8), intent (in) :: y5
    real(8) :: t_1
    real(8) :: tmp
    t_1 = i * (y * ((-1.0d0) * (c * x)))
    if (c <= (-3.25d+112)) then
        tmp = t_1
    else if (c <= 3.1d-5) then
        tmp = b * (y4 * (j * t))
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = i * (y * (-1.0 * (c * x)));
	double tmp;
	if (c <= -3.25e+112) {
		tmp = t_1;
	} else if (c <= 3.1e-5) {
		tmp = b * (y4 * (j * t));
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5):
	t_1 = i * (y * (-1.0 * (c * x)))
	tmp = 0
	if c <= -3.25e+112:
		tmp = t_1
	elif c <= 3.1e-5:
		tmp = b * (y4 * (j * t))
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = Float64(i * Float64(y * Float64(-1.0 * Float64(c * x))))
	tmp = 0.0
	if (c <= -3.25e+112)
		tmp = t_1;
	elseif (c <= 3.1e-5)
		tmp = Float64(b * Float64(y4 * Float64(j * t)));
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = i * (y * (-1.0 * (c * x)));
	tmp = 0.0;
	if (c <= -3.25e+112)
		tmp = t_1;
	elseif (c <= 3.1e-5)
		tmp = b * (y4 * (j * t));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(i * N[(y * N[(-1.0 * N[(c * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[c, -3.25e+112], t$95$1, If[LessEqual[c, 3.1e-5], N[(b * N[(y4 * N[(j * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot x\right)\right)\right)\\
\mathbf{if}\;c \leq -3.25 \cdot 10^{+112}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;c \leq 3.1 \cdot 10^{-5}:\\
\;\;\;\;b \cdot \left(y4 \cdot \left(j \cdot t\right)\right)\\

\mathbf{else}:\\
\;\;\;\;t\_1\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if c < -3.2499999999999999e112 or 3.10000000000000014e-5 < c

    1. Initial program 25.3%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites40.0%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in y around -inf

      \[\leadsto i \cdot \color{blue}{\left(y \cdot \left(-1 \cdot \left(c \cdot x\right) + k \cdot y5\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \color{blue}{\left(-1 \cdot \left(c \cdot x\right) + k \cdot y5\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot x\right) + \color{blue}{k \cdot y5}\right)\right) \]
      3. lower-fma.f64N/A

        \[\leadsto i \cdot \left(y \cdot \mathsf{fma}\left(-1, c \cdot \color{blue}{x}, k \cdot y5\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \mathsf{fma}\left(-1, c \cdot x, k \cdot y5\right)\right) \]
      5. lower-*.f6434.1

        \[\leadsto i \cdot \left(y \cdot \mathsf{fma}\left(-1, c \cdot x, k \cdot y5\right)\right) \]
    7. Applied rewrites34.1%

      \[\leadsto i \cdot \color{blue}{\left(y \cdot \mathsf{fma}\left(-1, c \cdot x, k \cdot y5\right)\right)} \]
    8. Taylor expanded in x around inf

      \[\leadsto i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot \color{blue}{x}\right)\right)\right) \]
    9. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot x\right)\right)\right) \]
      2. lift-*.f6428.5

        \[\leadsto i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot x\right)\right)\right) \]
    10. Applied rewrites28.5%

      \[\leadsto i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot \color{blue}{x}\right)\right)\right) \]

    if -3.2499999999999999e112 < c < 3.10000000000000014e-5

    1. Initial program 33.9%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in b around inf

      \[\leadsto \color{blue}{b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto b \cdot \color{blue}{\left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y0 \cdot \left(j \cdot x - k \cdot z\right)}\right) \]
    4. Applied rewrites39.1%

      \[\leadsto \color{blue}{b \cdot \left(\mathsf{fma}\left(a, x \cdot y - t \cdot z, y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    5. Taylor expanded in y4 around inf

      \[\leadsto b \cdot \left(y4 \cdot \color{blue}{\left(j \cdot t - k \cdot y\right)}\right) \]
    6. Step-by-step derivation
      1. lift-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot y\right)\right) \]
      2. lift-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot y\right)\right) \]
      3. lift--.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot \color{blue}{y}\right)\right) \]
      4. lift-*.f6427.5

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - \color{blue}{k \cdot y}\right)\right) \]
    7. Applied rewrites27.5%

      \[\leadsto b \cdot \left(y4 \cdot \color{blue}{\left(j \cdot t - k \cdot y\right)}\right) \]
    8. Taylor expanded in y around 0

      \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t\right)\right) \]
    9. Step-by-step derivation
      1. lift-*.f6417.1

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t\right)\right) \]
    10. Applied rewrites17.1%

      \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t\right)\right) \]
  3. Recombined 2 regimes into one program.
  4. Add Preprocessing

Alternative 27: 22.5% accurate, 7.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := b \cdot \left(y4 \cdot \left(j \cdot t\right)\right)\\ \mathbf{if}\;t \leq -7.3 \cdot 10^{+47}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;t \leq 1.65 \cdot 10^{+86}:\\ \;\;\;\;i \cdot \left(k \cdot \left(y \cdot y5\right)\right)\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (let* ((t_1 (* b (* y4 (* j t)))))
   (if (<= t -7.3e+47) t_1 (if (<= t 1.65e+86) (* i (* k (* y y5))) t_1))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = b * (y4 * (j * t));
	double tmp;
	if (t <= -7.3e+47) {
		tmp = t_1;
	} else if (t <= 1.65e+86) {
		tmp = i * (k * (y * y5));
	} else {
		tmp = t_1;
	}
	return tmp;
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8), intent (in) :: y0
    real(8), intent (in) :: y1
    real(8), intent (in) :: y2
    real(8), intent (in) :: y3
    real(8), intent (in) :: y4
    real(8), intent (in) :: y5
    real(8) :: t_1
    real(8) :: tmp
    t_1 = b * (y4 * (j * t))
    if (t <= (-7.3d+47)) then
        tmp = t_1
    else if (t <= 1.65d+86) then
        tmp = i * (k * (y * y5))
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = b * (y4 * (j * t));
	double tmp;
	if (t <= -7.3e+47) {
		tmp = t_1;
	} else if (t <= 1.65e+86) {
		tmp = i * (k * (y * y5));
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5):
	t_1 = b * (y4 * (j * t))
	tmp = 0
	if t <= -7.3e+47:
		tmp = t_1
	elif t <= 1.65e+86:
		tmp = i * (k * (y * y5))
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = Float64(b * Float64(y4 * Float64(j * t)))
	tmp = 0.0
	if (t <= -7.3e+47)
		tmp = t_1;
	elseif (t <= 1.65e+86)
		tmp = Float64(i * Float64(k * Float64(y * y5)));
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = b * (y4 * (j * t));
	tmp = 0.0;
	if (t <= -7.3e+47)
		tmp = t_1;
	elseif (t <= 1.65e+86)
		tmp = i * (k * (y * y5));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(b * N[(y4 * N[(j * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -7.3e+47], t$95$1, If[LessEqual[t, 1.65e+86], N[(i * N[(k * N[(y * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := b \cdot \left(y4 \cdot \left(j \cdot t\right)\right)\\
\mathbf{if}\;t \leq -7.3 \cdot 10^{+47}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;t \leq 1.65 \cdot 10^{+86}:\\
\;\;\;\;i \cdot \left(k \cdot \left(y \cdot y5\right)\right)\\

\mathbf{else}:\\
\;\;\;\;t\_1\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -7.3000000000000001e47 or 1.65e86 < t

    1. Initial program 24.6%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in b around inf

      \[\leadsto \color{blue}{b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto b \cdot \color{blue}{\left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y0 \cdot \left(j \cdot x - k \cdot z\right)}\right) \]
    4. Applied rewrites38.2%

      \[\leadsto \color{blue}{b \cdot \left(\mathsf{fma}\left(a, x \cdot y - t \cdot z, y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    5. Taylor expanded in y4 around inf

      \[\leadsto b \cdot \left(y4 \cdot \color{blue}{\left(j \cdot t - k \cdot y\right)}\right) \]
    6. Step-by-step derivation
      1. lift-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot y\right)\right) \]
      2. lift-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot y\right)\right) \]
      3. lift--.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot \color{blue}{y}\right)\right) \]
      4. lift-*.f6435.2

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - \color{blue}{k \cdot y}\right)\right) \]
    7. Applied rewrites35.2%

      \[\leadsto b \cdot \left(y4 \cdot \color{blue}{\left(j \cdot t - k \cdot y\right)}\right) \]
    8. Taylor expanded in y around 0

      \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t\right)\right) \]
    9. Step-by-step derivation
      1. lift-*.f6429.6

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t\right)\right) \]
    10. Applied rewrites29.6%

      \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t\right)\right) \]

    if -7.3000000000000001e47 < t < 1.65e86

    1. Initial program 33.9%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites37.9%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in k around -inf

      \[\leadsto i \cdot \color{blue}{\left(k \cdot \left(y \cdot y5 - y1 \cdot z\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(k \cdot \color{blue}{\left(y \cdot y5 - y1 \cdot z\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5 - \color{blue}{y1 \cdot z}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5 - y1 \cdot \color{blue}{z}\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5 - y1 \cdot z\right)\right) \]
      5. lower-*.f6428.3

        \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5 - y1 \cdot z\right)\right) \]
    7. Applied rewrites28.3%

      \[\leadsto i \cdot \color{blue}{\left(k \cdot \left(y \cdot y5 - y1 \cdot z\right)\right)} \]
    8. Taylor expanded in y around inf

      \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5\right)\right) \]
    9. Step-by-step derivation
      1. lift-*.f6418.1

        \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5\right)\right) \]
    10. Applied rewrites18.1%

      \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5\right)\right) \]
  3. Recombined 2 regimes into one program.
  4. Add Preprocessing

Alternative 28: 22.0% accurate, 7.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;t \leq -3.8 \cdot 10^{+113}:\\ \;\;\;\;i \cdot \left(z \cdot \left(c \cdot t\right)\right)\\ \mathbf{elif}\;t \leq 1.25 \cdot 10^{+89}:\\ \;\;\;\;i \cdot \left(k \cdot \left(y \cdot y5\right)\right)\\ \mathbf{else}:\\ \;\;\;\;b \cdot \left(j \cdot \left(t \cdot y4\right)\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (if (<= t -3.8e+113)
   (* i (* z (* c t)))
   (if (<= t 1.25e+89) (* i (* k (* y y5))) (* b (* j (* t y4))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double tmp;
	if (t <= -3.8e+113) {
		tmp = i * (z * (c * t));
	} else if (t <= 1.25e+89) {
		tmp = i * (k * (y * y5));
	} else {
		tmp = b * (j * (t * y4));
	}
	return tmp;
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8), intent (in) :: y0
    real(8), intent (in) :: y1
    real(8), intent (in) :: y2
    real(8), intent (in) :: y3
    real(8), intent (in) :: y4
    real(8), intent (in) :: y5
    real(8) :: tmp
    if (t <= (-3.8d+113)) then
        tmp = i * (z * (c * t))
    else if (t <= 1.25d+89) then
        tmp = i * (k * (y * y5))
    else
        tmp = b * (j * (t * y4))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double tmp;
	if (t <= -3.8e+113) {
		tmp = i * (z * (c * t));
	} else if (t <= 1.25e+89) {
		tmp = i * (k * (y * y5));
	} else {
		tmp = b * (j * (t * y4));
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5):
	tmp = 0
	if t <= -3.8e+113:
		tmp = i * (z * (c * t))
	elif t <= 1.25e+89:
		tmp = i * (k * (y * y5))
	else:
		tmp = b * (j * (t * y4))
	return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	tmp = 0.0
	if (t <= -3.8e+113)
		tmp = Float64(i * Float64(z * Float64(c * t)));
	elseif (t <= 1.25e+89)
		tmp = Float64(i * Float64(k * Float64(y * y5)));
	else
		tmp = Float64(b * Float64(j * Float64(t * y4)));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	tmp = 0.0;
	if (t <= -3.8e+113)
		tmp = i * (z * (c * t));
	elseif (t <= 1.25e+89)
		tmp = i * (k * (y * y5));
	else
		tmp = b * (j * (t * y4));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := If[LessEqual[t, -3.8e+113], N[(i * N[(z * N[(c * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.25e+89], N[(i * N[(k * N[(y * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(b * N[(j * N[(t * y4), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;t \leq -3.8 \cdot 10^{+113}:\\
\;\;\;\;i \cdot \left(z \cdot \left(c \cdot t\right)\right)\\

\mathbf{elif}\;t \leq 1.25 \cdot 10^{+89}:\\
\;\;\;\;i \cdot \left(k \cdot \left(y \cdot y5\right)\right)\\

\mathbf{else}:\\
\;\;\;\;b \cdot \left(j \cdot \left(t \cdot y4\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -3.8000000000000003e113

    1. Initial program 23.6%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites39.4%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in z around -inf

      \[\leadsto i \cdot \color{blue}{\left(z \cdot \left(c \cdot t - k \cdot y1\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \color{blue}{\left(c \cdot t - k \cdot y1\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - \color{blue}{k \cdot y1}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot \color{blue}{y1}\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot y1\right)\right) \]
      5. lower-*.f6436.3

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot y1\right)\right) \]
    7. Applied rewrites36.3%

      \[\leadsto i \cdot \color{blue}{\left(z \cdot \left(c \cdot t - k \cdot y1\right)\right)} \]
    8. Taylor expanded in t around inf

      \[\leadsto i \cdot \left(z \cdot \left(c \cdot t\right)\right) \]
    9. Step-by-step derivation
      1. lift-*.f6431.2

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t\right)\right) \]
    10. Applied rewrites31.2%

      \[\leadsto i \cdot \left(z \cdot \left(c \cdot t\right)\right) \]

    if -3.8000000000000003e113 < t < 1.24999999999999996e89

    1. Initial program 33.7%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites37.6%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in k around -inf

      \[\leadsto i \cdot \color{blue}{\left(k \cdot \left(y \cdot y5 - y1 \cdot z\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(k \cdot \color{blue}{\left(y \cdot y5 - y1 \cdot z\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5 - \color{blue}{y1 \cdot z}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5 - y1 \cdot \color{blue}{z}\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5 - y1 \cdot z\right)\right) \]
      5. lower-*.f6428.0

        \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5 - y1 \cdot z\right)\right) \]
    7. Applied rewrites28.0%

      \[\leadsto i \cdot \color{blue}{\left(k \cdot \left(y \cdot y5 - y1 \cdot z\right)\right)} \]
    8. Taylor expanded in y around inf

      \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5\right)\right) \]
    9. Step-by-step derivation
      1. lift-*.f6417.8

        \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5\right)\right) \]
    10. Applied rewrites17.8%

      \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5\right)\right) \]

    if 1.24999999999999996e89 < t

    1. Initial program 23.6%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in b around inf

      \[\leadsto \color{blue}{b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto b \cdot \color{blue}{\left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto b \cdot \left(\left(a \cdot \left(x \cdot y - t \cdot z\right) + y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y0 \cdot \left(j \cdot x - k \cdot z\right)}\right) \]
    4. Applied rewrites38.1%

      \[\leadsto \color{blue}{b \cdot \left(\mathsf{fma}\left(a, x \cdot y - t \cdot z, y4 \cdot \left(j \cdot t - k \cdot y\right)\right) - y0 \cdot \left(j \cdot x - k \cdot z\right)\right)} \]
    5. Taylor expanded in y4 around inf

      \[\leadsto b \cdot \left(y4 \cdot \color{blue}{\left(j \cdot t - k \cdot y\right)}\right) \]
    6. Step-by-step derivation
      1. lift-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot y\right)\right) \]
      2. lift-*.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot y\right)\right) \]
      3. lift--.f64N/A

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - k \cdot \color{blue}{y}\right)\right) \]
      4. lift-*.f6436.7

        \[\leadsto b \cdot \left(y4 \cdot \left(j \cdot t - \color{blue}{k \cdot y}\right)\right) \]
    7. Applied rewrites36.7%

      \[\leadsto b \cdot \left(y4 \cdot \color{blue}{\left(j \cdot t - k \cdot y\right)}\right) \]
    8. Taylor expanded in y around 0

      \[\leadsto b \cdot \left(j \cdot \left(t \cdot \color{blue}{y4}\right)\right) \]
    9. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto b \cdot \left(j \cdot \left(t \cdot y4\right)\right) \]
      2. lower-*.f6430.0

        \[\leadsto b \cdot \left(j \cdot \left(t \cdot y4\right)\right) \]
    10. Applied rewrites30.0%

      \[\leadsto b \cdot \left(j \cdot \left(t \cdot \color{blue}{y4}\right)\right) \]
  3. Recombined 3 regimes into one program.
  4. Add Preprocessing

Alternative 29: 22.2% accurate, 7.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := i \cdot \left(k \cdot \left(y \cdot y5\right)\right)\\ \mathbf{if}\;y \leq -450000:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \leq 1.02 \cdot 10^{+96}:\\ \;\;\;\;a \cdot \left(t \cdot \left(y2 \cdot y5\right)\right)\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (let* ((t_1 (* i (* k (* y y5)))))
   (if (<= y -450000.0) t_1 (if (<= y 1.02e+96) (* a (* t (* y2 y5))) t_1))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = i * (k * (y * y5));
	double tmp;
	if (y <= -450000.0) {
		tmp = t_1;
	} else if (y <= 1.02e+96) {
		tmp = a * (t * (y2 * y5));
	} else {
		tmp = t_1;
	}
	return tmp;
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8), intent (in) :: y0
    real(8), intent (in) :: y1
    real(8), intent (in) :: y2
    real(8), intent (in) :: y3
    real(8), intent (in) :: y4
    real(8), intent (in) :: y5
    real(8) :: t_1
    real(8) :: tmp
    t_1 = i * (k * (y * y5))
    if (y <= (-450000.0d0)) then
        tmp = t_1
    else if (y <= 1.02d+96) then
        tmp = a * (t * (y2 * y5))
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = i * (k * (y * y5));
	double tmp;
	if (y <= -450000.0) {
		tmp = t_1;
	} else if (y <= 1.02e+96) {
		tmp = a * (t * (y2 * y5));
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5):
	t_1 = i * (k * (y * y5))
	tmp = 0
	if y <= -450000.0:
		tmp = t_1
	elif y <= 1.02e+96:
		tmp = a * (t * (y2 * y5))
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = Float64(i * Float64(k * Float64(y * y5)))
	tmp = 0.0
	if (y <= -450000.0)
		tmp = t_1;
	elseif (y <= 1.02e+96)
		tmp = Float64(a * Float64(t * Float64(y2 * y5)));
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = i * (k * (y * y5));
	tmp = 0.0;
	if (y <= -450000.0)
		tmp = t_1;
	elseif (y <= 1.02e+96)
		tmp = a * (t * (y2 * y5));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(i * N[(k * N[(y * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -450000.0], t$95$1, If[LessEqual[y, 1.02e+96], N[(a * N[(t * N[(y2 * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := i \cdot \left(k \cdot \left(y \cdot y5\right)\right)\\
\mathbf{if}\;y \leq -450000:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;y \leq 1.02 \cdot 10^{+96}:\\
\;\;\;\;a \cdot \left(t \cdot \left(y2 \cdot y5\right)\right)\\

\mathbf{else}:\\
\;\;\;\;t\_1\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y < -4.5e5 or 1.02000000000000001e96 < y

    1. Initial program 24.5%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites37.6%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in k around -inf

      \[\leadsto i \cdot \color{blue}{\left(k \cdot \left(y \cdot y5 - y1 \cdot z\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(k \cdot \color{blue}{\left(y \cdot y5 - y1 \cdot z\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5 - \color{blue}{y1 \cdot z}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5 - y1 \cdot \color{blue}{z}\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5 - y1 \cdot z\right)\right) \]
      5. lower-*.f6434.3

        \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5 - y1 \cdot z\right)\right) \]
    7. Applied rewrites34.3%

      \[\leadsto i \cdot \color{blue}{\left(k \cdot \left(y \cdot y5 - y1 \cdot z\right)\right)} \]
    8. Taylor expanded in y around inf

      \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5\right)\right) \]
    9. Step-by-step derivation
      1. lift-*.f6429.2

        \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5\right)\right) \]
    10. Applied rewrites29.2%

      \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5\right)\right) \]

    if -4.5e5 < y < 1.02000000000000001e96

    1. Initial program 34.7%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in t around inf

      \[\leadsto \color{blue}{t \cdot \left(\left(-1 \cdot \left(z \cdot \left(a \cdot b - c \cdot i\right)\right) + j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - y2 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto t \cdot \color{blue}{\left(\left(-1 \cdot \left(z \cdot \left(a \cdot b - c \cdot i\right)\right) + j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - y2 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
      2. lower--.f64N/A

        \[\leadsto t \cdot \left(\left(-1 \cdot \left(z \cdot \left(a \cdot b - c \cdot i\right)\right) + j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - \color{blue}{y2 \cdot \left(c \cdot y4 - a \cdot y5\right)}\right) \]
    4. Applied rewrites38.6%

      \[\leadsto \color{blue}{t \cdot \left(\mathsf{fma}\left(-1, z \cdot \left(a \cdot b - c \cdot i\right), j \cdot \left(b \cdot y4 - i \cdot y5\right)\right) - y2 \cdot \left(c \cdot y4 - a \cdot y5\right)\right)} \]
    5. Taylor expanded in a around -inf

      \[\leadsto -1 \cdot \color{blue}{\left(a \cdot \left(t \cdot \left(b \cdot z - y2 \cdot y5\right)\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(a \cdot \color{blue}{\left(t \cdot \left(b \cdot z - y2 \cdot y5\right)\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(a \cdot \left(t \cdot \color{blue}{\left(b \cdot z - y2 \cdot y5\right)}\right)\right) \]
      3. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(a \cdot \left(t \cdot \left(b \cdot z - \color{blue}{y2 \cdot y5}\right)\right)\right) \]
      4. lower--.f64N/A

        \[\leadsto -1 \cdot \left(a \cdot \left(t \cdot \left(b \cdot z - y2 \cdot \color{blue}{y5}\right)\right)\right) \]
      5. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(a \cdot \left(t \cdot \left(b \cdot z - y2 \cdot y5\right)\right)\right) \]
      6. lower-*.f6427.4

        \[\leadsto -1 \cdot \left(a \cdot \left(t \cdot \left(b \cdot z - y2 \cdot y5\right)\right)\right) \]
    7. Applied rewrites27.4%

      \[\leadsto -1 \cdot \color{blue}{\left(a \cdot \left(t \cdot \left(b \cdot z - y2 \cdot y5\right)\right)\right)} \]
    8. Taylor expanded in z around 0

      \[\leadsto a \cdot \left(t \cdot \color{blue}{\left(y2 \cdot y5\right)}\right) \]
    9. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto a \cdot \left(t \cdot \left(y2 \cdot \color{blue}{y5}\right)\right) \]
      2. lower-*.f64N/A

        \[\leadsto a \cdot \left(t \cdot \left(y2 \cdot y5\right)\right) \]
      3. lift-*.f6417.0

        \[\leadsto a \cdot \left(t \cdot \left(y2 \cdot y5\right)\right) \]
    10. Applied rewrites17.0%

      \[\leadsto a \cdot \left(t \cdot \color{blue}{\left(y2 \cdot y5\right)}\right) \]
  3. Recombined 2 regimes into one program.
  4. Add Preprocessing

Alternative 30: 22.0% accurate, 7.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;t \leq -3.8 \cdot 10^{+113}:\\ \;\;\;\;i \cdot \left(z \cdot \left(c \cdot t\right)\right)\\ \mathbf{elif}\;t \leq 7.2 \cdot 10^{+52}:\\ \;\;\;\;i \cdot \left(k \cdot \left(y \cdot y5\right)\right)\\ \mathbf{else}:\\ \;\;\;\;c \cdot \left(i \cdot \left(t \cdot z\right)\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (if (<= t -3.8e+113)
   (* i (* z (* c t)))
   (if (<= t 7.2e+52) (* i (* k (* y y5))) (* c (* i (* t z))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double tmp;
	if (t <= -3.8e+113) {
		tmp = i * (z * (c * t));
	} else if (t <= 7.2e+52) {
		tmp = i * (k * (y * y5));
	} else {
		tmp = c * (i * (t * z));
	}
	return tmp;
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8), intent (in) :: y0
    real(8), intent (in) :: y1
    real(8), intent (in) :: y2
    real(8), intent (in) :: y3
    real(8), intent (in) :: y4
    real(8), intent (in) :: y5
    real(8) :: tmp
    if (t <= (-3.8d+113)) then
        tmp = i * (z * (c * t))
    else if (t <= 7.2d+52) then
        tmp = i * (k * (y * y5))
    else
        tmp = c * (i * (t * z))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double tmp;
	if (t <= -3.8e+113) {
		tmp = i * (z * (c * t));
	} else if (t <= 7.2e+52) {
		tmp = i * (k * (y * y5));
	} else {
		tmp = c * (i * (t * z));
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5):
	tmp = 0
	if t <= -3.8e+113:
		tmp = i * (z * (c * t))
	elif t <= 7.2e+52:
		tmp = i * (k * (y * y5))
	else:
		tmp = c * (i * (t * z))
	return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	tmp = 0.0
	if (t <= -3.8e+113)
		tmp = Float64(i * Float64(z * Float64(c * t)));
	elseif (t <= 7.2e+52)
		tmp = Float64(i * Float64(k * Float64(y * y5)));
	else
		tmp = Float64(c * Float64(i * Float64(t * z)));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	tmp = 0.0;
	if (t <= -3.8e+113)
		tmp = i * (z * (c * t));
	elseif (t <= 7.2e+52)
		tmp = i * (k * (y * y5));
	else
		tmp = c * (i * (t * z));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := If[LessEqual[t, -3.8e+113], N[(i * N[(z * N[(c * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 7.2e+52], N[(i * N[(k * N[(y * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(c * N[(i * N[(t * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;t \leq -3.8 \cdot 10^{+113}:\\
\;\;\;\;i \cdot \left(z \cdot \left(c \cdot t\right)\right)\\

\mathbf{elif}\;t \leq 7.2 \cdot 10^{+52}:\\
\;\;\;\;i \cdot \left(k \cdot \left(y \cdot y5\right)\right)\\

\mathbf{else}:\\
\;\;\;\;c \cdot \left(i \cdot \left(t \cdot z\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -3.8000000000000003e113

    1. Initial program 23.6%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites39.4%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in z around -inf

      \[\leadsto i \cdot \color{blue}{\left(z \cdot \left(c \cdot t - k \cdot y1\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \color{blue}{\left(c \cdot t - k \cdot y1\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - \color{blue}{k \cdot y1}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot \color{blue}{y1}\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot y1\right)\right) \]
      5. lower-*.f6436.3

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot y1\right)\right) \]
    7. Applied rewrites36.3%

      \[\leadsto i \cdot \color{blue}{\left(z \cdot \left(c \cdot t - k \cdot y1\right)\right)} \]
    8. Taylor expanded in t around inf

      \[\leadsto i \cdot \left(z \cdot \left(c \cdot t\right)\right) \]
    9. Step-by-step derivation
      1. lift-*.f6431.2

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t\right)\right) \]
    10. Applied rewrites31.2%

      \[\leadsto i \cdot \left(z \cdot \left(c \cdot t\right)\right) \]

    if -3.8000000000000003e113 < t < 7.2e52

    1. Initial program 33.8%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites37.7%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in k around -inf

      \[\leadsto i \cdot \color{blue}{\left(k \cdot \left(y \cdot y5 - y1 \cdot z\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(k \cdot \color{blue}{\left(y \cdot y5 - y1 \cdot z\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5 - \color{blue}{y1 \cdot z}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5 - y1 \cdot \color{blue}{z}\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5 - y1 \cdot z\right)\right) \]
      5. lower-*.f6428.2

        \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5 - y1 \cdot z\right)\right) \]
    7. Applied rewrites28.2%

      \[\leadsto i \cdot \color{blue}{\left(k \cdot \left(y \cdot y5 - y1 \cdot z\right)\right)} \]
    8. Taylor expanded in y around inf

      \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5\right)\right) \]
    9. Step-by-step derivation
      1. lift-*.f6417.9

        \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5\right)\right) \]
    10. Applied rewrites17.9%

      \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5\right)\right) \]

    if 7.2e52 < t

    1. Initial program 24.6%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites35.8%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in z around -inf

      \[\leadsto i \cdot \color{blue}{\left(z \cdot \left(c \cdot t - k \cdot y1\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \color{blue}{\left(c \cdot t - k \cdot y1\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - \color{blue}{k \cdot y1}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot \color{blue}{y1}\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot y1\right)\right) \]
      5. lower-*.f6433.4

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot y1\right)\right) \]
    7. Applied rewrites33.4%

      \[\leadsto i \cdot \color{blue}{\left(z \cdot \left(c \cdot t - k \cdot y1\right)\right)} \]
    8. Taylor expanded in t around inf

      \[\leadsto c \cdot \left(i \cdot \color{blue}{\left(t \cdot z\right)}\right) \]
    9. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto c \cdot \left(i \cdot \left(t \cdot \color{blue}{z}\right)\right) \]
      2. lower-*.f64N/A

        \[\leadsto c \cdot \left(i \cdot \left(t \cdot z\right)\right) \]
      3. lift-*.f6428.3

        \[\leadsto c \cdot \left(i \cdot \left(t \cdot z\right)\right) \]
    10. Applied rewrites28.3%

      \[\leadsto c \cdot \left(i \cdot \color{blue}{\left(t \cdot z\right)}\right) \]
  3. Recombined 3 regimes into one program.
  4. Add Preprocessing

Alternative 31: 22.4% accurate, 7.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -1.9 \cdot 10^{+16}:\\ \;\;\;\;i \cdot \left(c \cdot \left(t \cdot z\right)\right)\\ \mathbf{elif}\;z \leq 2.7 \cdot 10^{-10}:\\ \;\;\;\;i \cdot \left(y \cdot \left(k \cdot y5\right)\right)\\ \mathbf{else}:\\ \;\;\;\;c \cdot \left(i \cdot \left(t \cdot z\right)\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (if (<= z -1.9e+16)
   (* i (* c (* t z)))
   (if (<= z 2.7e-10) (* i (* y (* k y5))) (* c (* i (* t z))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double tmp;
	if (z <= -1.9e+16) {
		tmp = i * (c * (t * z));
	} else if (z <= 2.7e-10) {
		tmp = i * (y * (k * y5));
	} else {
		tmp = c * (i * (t * z));
	}
	return tmp;
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8), intent (in) :: y0
    real(8), intent (in) :: y1
    real(8), intent (in) :: y2
    real(8), intent (in) :: y3
    real(8), intent (in) :: y4
    real(8), intent (in) :: y5
    real(8) :: tmp
    if (z <= (-1.9d+16)) then
        tmp = i * (c * (t * z))
    else if (z <= 2.7d-10) then
        tmp = i * (y * (k * y5))
    else
        tmp = c * (i * (t * z))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double tmp;
	if (z <= -1.9e+16) {
		tmp = i * (c * (t * z));
	} else if (z <= 2.7e-10) {
		tmp = i * (y * (k * y5));
	} else {
		tmp = c * (i * (t * z));
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5):
	tmp = 0
	if z <= -1.9e+16:
		tmp = i * (c * (t * z))
	elif z <= 2.7e-10:
		tmp = i * (y * (k * y5))
	else:
		tmp = c * (i * (t * z))
	return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	tmp = 0.0
	if (z <= -1.9e+16)
		tmp = Float64(i * Float64(c * Float64(t * z)));
	elseif (z <= 2.7e-10)
		tmp = Float64(i * Float64(y * Float64(k * y5)));
	else
		tmp = Float64(c * Float64(i * Float64(t * z)));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	tmp = 0.0;
	if (z <= -1.9e+16)
		tmp = i * (c * (t * z));
	elseif (z <= 2.7e-10)
		tmp = i * (y * (k * y5));
	else
		tmp = c * (i * (t * z));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := If[LessEqual[z, -1.9e+16], N[(i * N[(c * N[(t * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2.7e-10], N[(i * N[(y * N[(k * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(c * N[(i * N[(t * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.9 \cdot 10^{+16}:\\
\;\;\;\;i \cdot \left(c \cdot \left(t \cdot z\right)\right)\\

\mathbf{elif}\;z \leq 2.7 \cdot 10^{-10}:\\
\;\;\;\;i \cdot \left(y \cdot \left(k \cdot y5\right)\right)\\

\mathbf{else}:\\
\;\;\;\;c \cdot \left(i \cdot \left(t \cdot z\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -1.9e16

    1. Initial program 24.8%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites39.1%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in z around -inf

      \[\leadsto i \cdot \color{blue}{\left(z \cdot \left(c \cdot t - k \cdot y1\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \color{blue}{\left(c \cdot t - k \cdot y1\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - \color{blue}{k \cdot y1}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot \color{blue}{y1}\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot y1\right)\right) \]
      5. lower-*.f6440.2

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot y1\right)\right) \]
    7. Applied rewrites40.2%

      \[\leadsto i \cdot \color{blue}{\left(z \cdot \left(c \cdot t - k \cdot y1\right)\right)} \]
    8. Taylor expanded in t around inf

      \[\leadsto i \cdot \left(c \cdot \left(t \cdot \color{blue}{z}\right)\right) \]
    9. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(c \cdot \left(t \cdot z\right)\right) \]
      2. lift-*.f6429.4

        \[\leadsto i \cdot \left(c \cdot \left(t \cdot z\right)\right) \]
    10. Applied rewrites29.4%

      \[\leadsto i \cdot \left(c \cdot \left(t \cdot \color{blue}{z}\right)\right) \]

    if -1.9e16 < z < 2.7e-10

    1. Initial program 34.1%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites37.9%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in y around -inf

      \[\leadsto i \cdot \color{blue}{\left(y \cdot \left(-1 \cdot \left(c \cdot x\right) + k \cdot y5\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \color{blue}{\left(-1 \cdot \left(c \cdot x\right) + k \cdot y5\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \left(-1 \cdot \left(c \cdot x\right) + \color{blue}{k \cdot y5}\right)\right) \]
      3. lower-fma.f64N/A

        \[\leadsto i \cdot \left(y \cdot \mathsf{fma}\left(-1, c \cdot \color{blue}{x}, k \cdot y5\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto i \cdot \left(y \cdot \mathsf{fma}\left(-1, c \cdot x, k \cdot y5\right)\right) \]
      5. lower-*.f6428.4

        \[\leadsto i \cdot \left(y \cdot \mathsf{fma}\left(-1, c \cdot x, k \cdot y5\right)\right) \]
    7. Applied rewrites28.4%

      \[\leadsto i \cdot \color{blue}{\left(y \cdot \mathsf{fma}\left(-1, c \cdot x, k \cdot y5\right)\right)} \]
    8. Taylor expanded in x around 0

      \[\leadsto i \cdot \left(y \cdot \left(k \cdot y5\right)\right) \]
    9. Step-by-step derivation
      1. lift-*.f6418.0

        \[\leadsto i \cdot \left(y \cdot \left(k \cdot y5\right)\right) \]
    10. Applied rewrites18.0%

      \[\leadsto i \cdot \left(y \cdot \left(k \cdot y5\right)\right) \]

    if 2.7e-10 < z

    1. Initial program 28.1%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites35.5%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in z around -inf

      \[\leadsto i \cdot \color{blue}{\left(z \cdot \left(c \cdot t - k \cdot y1\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \color{blue}{\left(c \cdot t - k \cdot y1\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - \color{blue}{k \cdot y1}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot \color{blue}{y1}\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot y1\right)\right) \]
      5. lower-*.f6435.9

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot y1\right)\right) \]
    7. Applied rewrites35.9%

      \[\leadsto i \cdot \color{blue}{\left(z \cdot \left(c \cdot t - k \cdot y1\right)\right)} \]
    8. Taylor expanded in t around inf

      \[\leadsto c \cdot \left(i \cdot \color{blue}{\left(t \cdot z\right)}\right) \]
    9. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto c \cdot \left(i \cdot \left(t \cdot \color{blue}{z}\right)\right) \]
      2. lower-*.f64N/A

        \[\leadsto c \cdot \left(i \cdot \left(t \cdot z\right)\right) \]
      3. lift-*.f6424.7

        \[\leadsto c \cdot \left(i \cdot \left(t \cdot z\right)\right) \]
    10. Applied rewrites24.7%

      \[\leadsto c \cdot \left(i \cdot \color{blue}{\left(t \cdot z\right)}\right) \]
  3. Recombined 3 regimes into one program.
  4. Add Preprocessing

Alternative 32: 22.2% accurate, 7.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;t \leq -3.8 \cdot 10^{+113}:\\ \;\;\;\;i \cdot \left(c \cdot \left(t \cdot z\right)\right)\\ \mathbf{elif}\;t \leq 7.2 \cdot 10^{+52}:\\ \;\;\;\;i \cdot \left(k \cdot \left(y \cdot y5\right)\right)\\ \mathbf{else}:\\ \;\;\;\;c \cdot \left(i \cdot \left(t \cdot z\right)\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (if (<= t -3.8e+113)
   (* i (* c (* t z)))
   (if (<= t 7.2e+52) (* i (* k (* y y5))) (* c (* i (* t z))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double tmp;
	if (t <= -3.8e+113) {
		tmp = i * (c * (t * z));
	} else if (t <= 7.2e+52) {
		tmp = i * (k * (y * y5));
	} else {
		tmp = c * (i * (t * z));
	}
	return tmp;
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8), intent (in) :: y0
    real(8), intent (in) :: y1
    real(8), intent (in) :: y2
    real(8), intent (in) :: y3
    real(8), intent (in) :: y4
    real(8), intent (in) :: y5
    real(8) :: tmp
    if (t <= (-3.8d+113)) then
        tmp = i * (c * (t * z))
    else if (t <= 7.2d+52) then
        tmp = i * (k * (y * y5))
    else
        tmp = c * (i * (t * z))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double tmp;
	if (t <= -3.8e+113) {
		tmp = i * (c * (t * z));
	} else if (t <= 7.2e+52) {
		tmp = i * (k * (y * y5));
	} else {
		tmp = c * (i * (t * z));
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5):
	tmp = 0
	if t <= -3.8e+113:
		tmp = i * (c * (t * z))
	elif t <= 7.2e+52:
		tmp = i * (k * (y * y5))
	else:
		tmp = c * (i * (t * z))
	return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	tmp = 0.0
	if (t <= -3.8e+113)
		tmp = Float64(i * Float64(c * Float64(t * z)));
	elseif (t <= 7.2e+52)
		tmp = Float64(i * Float64(k * Float64(y * y5)));
	else
		tmp = Float64(c * Float64(i * Float64(t * z)));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	tmp = 0.0;
	if (t <= -3.8e+113)
		tmp = i * (c * (t * z));
	elseif (t <= 7.2e+52)
		tmp = i * (k * (y * y5));
	else
		tmp = c * (i * (t * z));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := If[LessEqual[t, -3.8e+113], N[(i * N[(c * N[(t * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 7.2e+52], N[(i * N[(k * N[(y * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(c * N[(i * N[(t * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;t \leq -3.8 \cdot 10^{+113}:\\
\;\;\;\;i \cdot \left(c \cdot \left(t \cdot z\right)\right)\\

\mathbf{elif}\;t \leq 7.2 \cdot 10^{+52}:\\
\;\;\;\;i \cdot \left(k \cdot \left(y \cdot y5\right)\right)\\

\mathbf{else}:\\
\;\;\;\;c \cdot \left(i \cdot \left(t \cdot z\right)\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if t < -3.8000000000000003e113

    1. Initial program 23.6%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites39.4%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in z around -inf

      \[\leadsto i \cdot \color{blue}{\left(z \cdot \left(c \cdot t - k \cdot y1\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \color{blue}{\left(c \cdot t - k \cdot y1\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - \color{blue}{k \cdot y1}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot \color{blue}{y1}\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot y1\right)\right) \]
      5. lower-*.f6436.3

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot y1\right)\right) \]
    7. Applied rewrites36.3%

      \[\leadsto i \cdot \color{blue}{\left(z \cdot \left(c \cdot t - k \cdot y1\right)\right)} \]
    8. Taylor expanded in t around inf

      \[\leadsto i \cdot \left(c \cdot \left(t \cdot \color{blue}{z}\right)\right) \]
    9. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(c \cdot \left(t \cdot z\right)\right) \]
      2. lift-*.f6432.1

        \[\leadsto i \cdot \left(c \cdot \left(t \cdot z\right)\right) \]
    10. Applied rewrites32.1%

      \[\leadsto i \cdot \left(c \cdot \left(t \cdot \color{blue}{z}\right)\right) \]

    if -3.8000000000000003e113 < t < 7.2e52

    1. Initial program 33.8%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites37.7%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in k around -inf

      \[\leadsto i \cdot \color{blue}{\left(k \cdot \left(y \cdot y5 - y1 \cdot z\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(k \cdot \color{blue}{\left(y \cdot y5 - y1 \cdot z\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5 - \color{blue}{y1 \cdot z}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5 - y1 \cdot \color{blue}{z}\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5 - y1 \cdot z\right)\right) \]
      5. lower-*.f6428.2

        \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5 - y1 \cdot z\right)\right) \]
    7. Applied rewrites28.2%

      \[\leadsto i \cdot \color{blue}{\left(k \cdot \left(y \cdot y5 - y1 \cdot z\right)\right)} \]
    8. Taylor expanded in y around inf

      \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5\right)\right) \]
    9. Step-by-step derivation
      1. lift-*.f6417.9

        \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5\right)\right) \]
    10. Applied rewrites17.9%

      \[\leadsto i \cdot \left(k \cdot \left(y \cdot y5\right)\right) \]

    if 7.2e52 < t

    1. Initial program 24.6%

      \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
    2. Taylor expanded in i around -inf

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    3. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
      2. lower-*.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
      3. lower--.f64N/A

        \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
    4. Applied rewrites35.8%

      \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    5. Taylor expanded in z around -inf

      \[\leadsto i \cdot \color{blue}{\left(z \cdot \left(c \cdot t - k \cdot y1\right)\right)} \]
    6. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \color{blue}{\left(c \cdot t - k \cdot y1\right)}\right) \]
      2. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - \color{blue}{k \cdot y1}\right)\right) \]
      3. lower--.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot \color{blue}{y1}\right)\right) \]
      4. lower-*.f64N/A

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot y1\right)\right) \]
      5. lower-*.f6433.4

        \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot y1\right)\right) \]
    7. Applied rewrites33.4%

      \[\leadsto i \cdot \color{blue}{\left(z \cdot \left(c \cdot t - k \cdot y1\right)\right)} \]
    8. Taylor expanded in t around inf

      \[\leadsto c \cdot \left(i \cdot \color{blue}{\left(t \cdot z\right)}\right) \]
    9. Step-by-step derivation
      1. lower-*.f64N/A

        \[\leadsto c \cdot \left(i \cdot \left(t \cdot \color{blue}{z}\right)\right) \]
      2. lower-*.f64N/A

        \[\leadsto c \cdot \left(i \cdot \left(t \cdot z\right)\right) \]
      3. lift-*.f6428.3

        \[\leadsto c \cdot \left(i \cdot \left(t \cdot z\right)\right) \]
    10. Applied rewrites28.3%

      \[\leadsto c \cdot \left(i \cdot \color{blue}{\left(t \cdot z\right)}\right) \]
  3. Recombined 3 regimes into one program.
  4. Add Preprocessing

Alternative 33: 16.9% accurate, 12.6× speedup?

\[\begin{array}{l} \\ c \cdot \left(i \cdot \left(t \cdot z\right)\right) \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (* c (* i (* t z))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	return c * (i * (t * z));
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8), intent (in) :: y0
    real(8), intent (in) :: y1
    real(8), intent (in) :: y2
    real(8), intent (in) :: y3
    real(8), intent (in) :: y4
    real(8), intent (in) :: y5
    code = c * (i * (t * z))
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	return c * (i * (t * z));
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5):
	return c * (i * (t * z))
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	return Float64(c * Float64(i * Float64(t * z)))
end
function tmp = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	tmp = c * (i * (t * z));
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := N[(c * N[(i * N[(t * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
c \cdot \left(i \cdot \left(t \cdot z\right)\right)
\end{array}
Derivation
  1. Initial program 30.4%

    \[\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(x \cdot j - z \cdot k\right) \cdot \left(y0 \cdot b - y1 \cdot i\right)\right) + \left(x \cdot y2 - z \cdot y3\right) \cdot \left(y0 \cdot c - y1 \cdot a\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot \left(y4 \cdot b - y5 \cdot i\right)\right) - \left(t \cdot y2 - y \cdot y3\right) \cdot \left(y4 \cdot c - y5 \cdot a\right)\right) + \left(k \cdot y2 - j \cdot y3\right) \cdot \left(y4 \cdot y1 - y5 \cdot y0\right) \]
  2. Taylor expanded in i around -inf

    \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
  3. Step-by-step derivation
    1. lower-*.f64N/A

      \[\leadsto -1 \cdot \color{blue}{\left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
    2. lower-*.f64N/A

      \[\leadsto -1 \cdot \left(i \cdot \color{blue}{\left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)}\right) \]
    3. lower--.f64N/A

      \[\leadsto -1 \cdot \left(i \cdot \left(\left(c \cdot \left(x \cdot y - t \cdot z\right) + y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - \color{blue}{y1 \cdot \left(j \cdot x - k \cdot z\right)}\right)\right) \]
  4. Applied rewrites37.5%

    \[\leadsto \color{blue}{-1 \cdot \left(i \cdot \left(\mathsf{fma}\left(c, x \cdot y - t \cdot z, y5 \cdot \left(j \cdot t - k \cdot y\right)\right) - y1 \cdot \left(j \cdot x - k \cdot z\right)\right)\right)} \]
  5. Taylor expanded in z around -inf

    \[\leadsto i \cdot \color{blue}{\left(z \cdot \left(c \cdot t - k \cdot y1\right)\right)} \]
  6. Step-by-step derivation
    1. lower-*.f64N/A

      \[\leadsto i \cdot \left(z \cdot \color{blue}{\left(c \cdot t - k \cdot y1\right)}\right) \]
    2. lower-*.f64N/A

      \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - \color{blue}{k \cdot y1}\right)\right) \]
    3. lower--.f64N/A

      \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot \color{blue}{y1}\right)\right) \]
    4. lower-*.f64N/A

      \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot y1\right)\right) \]
    5. lower-*.f6426.8

      \[\leadsto i \cdot \left(z \cdot \left(c \cdot t - k \cdot y1\right)\right) \]
  7. Applied rewrites26.8%

    \[\leadsto i \cdot \color{blue}{\left(z \cdot \left(c \cdot t - k \cdot y1\right)\right)} \]
  8. Taylor expanded in t around inf

    \[\leadsto c \cdot \left(i \cdot \color{blue}{\left(t \cdot z\right)}\right) \]
  9. Step-by-step derivation
    1. lower-*.f64N/A

      \[\leadsto c \cdot \left(i \cdot \left(t \cdot \color{blue}{z}\right)\right) \]
    2. lower-*.f64N/A

      \[\leadsto c \cdot \left(i \cdot \left(t \cdot z\right)\right) \]
    3. lift-*.f6416.9

      \[\leadsto c \cdot \left(i \cdot \left(t \cdot z\right)\right) \]
  10. Applied rewrites16.9%

    \[\leadsto c \cdot \left(i \cdot \color{blue}{\left(t \cdot z\right)}\right) \]
  11. Add Preprocessing

Developer Target 1: 28.0% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := y4 \cdot c - y5 \cdot a\\ t_2 := x \cdot y2 - z \cdot y3\\ t_3 := y2 \cdot t - y3 \cdot y\\ t_4 := k \cdot y2 - j \cdot y3\\ t_5 := y4 \cdot b - y5 \cdot i\\ t_6 := \left(j \cdot t - k \cdot y\right) \cdot t\_5\\ t_7 := b \cdot a - i \cdot c\\ t_8 := t\_7 \cdot \left(y \cdot x - t \cdot z\right)\\ t_9 := j \cdot x - k \cdot z\\ t_10 := \left(b \cdot y0 - i \cdot y1\right) \cdot t\_9\\ t_11 := t\_9 \cdot \left(y0 \cdot b - i \cdot y1\right)\\ t_12 := y4 \cdot y1 - y5 \cdot y0\\ t_13 := t\_4 \cdot t\_12\\ t_14 := \left(y2 \cdot k - y3 \cdot j\right) \cdot t\_12\\ t_15 := \left(\left(\left(\left(k \cdot y\right) \cdot \left(y5 \cdot i\right) - \left(y \cdot b\right) \cdot \left(y4 \cdot k\right)\right) - \left(y5 \cdot t\right) \cdot \left(i \cdot j\right)\right) - \left(t\_3 \cdot t\_1 - t\_14\right)\right) + \left(t\_8 - \left(t\_11 - \left(y2 \cdot x - y3 \cdot z\right) \cdot \left(c \cdot y0 - y1 \cdot a\right)\right)\right)\\ t_16 := \left(\left(t\_6 - \left(y3 \cdot y\right) \cdot \left(y5 \cdot a - y4 \cdot c\right)\right) + \left(\left(y5 \cdot a\right) \cdot \left(t \cdot y2\right) + t\_13\right)\right) + \left(t\_2 \cdot \left(c \cdot y0 - a \cdot y1\right) - \left(t\_10 - \left(y \cdot x - z \cdot t\right) \cdot t\_7\right)\right)\\ t_17 := t \cdot y2 - y \cdot y3\\ \mathbf{if}\;y4 < -7.206256231996481 \cdot 10^{+60}:\\ \;\;\;\;\left(t\_8 - \left(t\_11 - t\_6\right)\right) - \left(\frac{t\_3}{\frac{1}{t\_1}} - t\_14\right)\\ \mathbf{elif}\;y4 < -3.364603505246317 \cdot 10^{-66}:\\ \;\;\;\;\left(\left(\left(\left(t \cdot c\right) \cdot \left(i \cdot z\right) - \left(a \cdot t\right) \cdot \left(b \cdot z\right)\right) - \left(y \cdot c\right) \cdot \left(i \cdot x\right)\right) - t\_10\right) + \left(\left(y0 \cdot c - a \cdot y1\right) \cdot t\_2 - \left(t\_17 \cdot \left(y4 \cdot c - a \cdot y5\right) - \left(y1 \cdot y4 - y5 \cdot y0\right) \cdot t\_4\right)\right)\\ \mathbf{elif}\;y4 < -1.2000065055686116 \cdot 10^{-105}:\\ \;\;\;\;t\_16\\ \mathbf{elif}\;y4 < 6.718963124057495 \cdot 10^{-279}:\\ \;\;\;\;t\_15\\ \mathbf{elif}\;y4 < 4.77962681403792 \cdot 10^{-222}:\\ \;\;\;\;t\_16\\ \mathbf{elif}\;y4 < 2.2852241541266835 \cdot 10^{-175}:\\ \;\;\;\;t\_15\\ \mathbf{else}:\\ \;\;\;\;\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(k \cdot \left(i \cdot \left(z \cdot y1\right)\right) - \left(j \cdot \left(i \cdot \left(x \cdot y1\right)\right) + y0 \cdot \left(k \cdot \left(z \cdot b\right)\right)\right)\right)\right) + \left(z \cdot \left(y3 \cdot \left(a \cdot y1\right)\right) - \left(y2 \cdot \left(x \cdot \left(a \cdot y1\right)\right) + y0 \cdot \left(z \cdot \left(c \cdot y3\right)\right)\right)\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot t\_5\right) - t\_17 \cdot t\_1\right) + t\_13\\ \end{array} \end{array} \]
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
 :precision binary64
 (let* ((t_1 (- (* y4 c) (* y5 a)))
        (t_2 (- (* x y2) (* z y3)))
        (t_3 (- (* y2 t) (* y3 y)))
        (t_4 (- (* k y2) (* j y3)))
        (t_5 (- (* y4 b) (* y5 i)))
        (t_6 (* (- (* j t) (* k y)) t_5))
        (t_7 (- (* b a) (* i c)))
        (t_8 (* t_7 (- (* y x) (* t z))))
        (t_9 (- (* j x) (* k z)))
        (t_10 (* (- (* b y0) (* i y1)) t_9))
        (t_11 (* t_9 (- (* y0 b) (* i y1))))
        (t_12 (- (* y4 y1) (* y5 y0)))
        (t_13 (* t_4 t_12))
        (t_14 (* (- (* y2 k) (* y3 j)) t_12))
        (t_15
         (+
          (-
           (-
            (- (* (* k y) (* y5 i)) (* (* y b) (* y4 k)))
            (* (* y5 t) (* i j)))
           (- (* t_3 t_1) t_14))
          (- t_8 (- t_11 (* (- (* y2 x) (* y3 z)) (- (* c y0) (* y1 a)))))))
        (t_16
         (+
          (+
           (- t_6 (* (* y3 y) (- (* y5 a) (* y4 c))))
           (+ (* (* y5 a) (* t y2)) t_13))
          (-
           (* t_2 (- (* c y0) (* a y1)))
           (- t_10 (* (- (* y x) (* z t)) t_7)))))
        (t_17 (- (* t y2) (* y y3))))
   (if (< y4 -7.206256231996481e+60)
     (- (- t_8 (- t_11 t_6)) (- (/ t_3 (/ 1.0 t_1)) t_14))
     (if (< y4 -3.364603505246317e-66)
       (+
        (-
         (- (- (* (* t c) (* i z)) (* (* a t) (* b z))) (* (* y c) (* i x)))
         t_10)
        (-
         (* (- (* y0 c) (* a y1)) t_2)
         (- (* t_17 (- (* y4 c) (* a y5))) (* (- (* y1 y4) (* y5 y0)) t_4))))
       (if (< y4 -1.2000065055686116e-105)
         t_16
         (if (< y4 6.718963124057495e-279)
           t_15
           (if (< y4 4.77962681403792e-222)
             t_16
             (if (< y4 2.2852241541266835e-175)
               t_15
               (+
                (-
                 (+
                  (+
                   (-
                    (* (- (* x y) (* z t)) (- (* a b) (* c i)))
                    (-
                     (* k (* i (* z y1)))
                     (+ (* j (* i (* x y1))) (* y0 (* k (* z b))))))
                   (-
                    (* z (* y3 (* a y1)))
                    (+ (* y2 (* x (* a y1))) (* y0 (* z (* c y3))))))
                  (* (- (* t j) (* y k)) t_5))
                 (* t_17 t_1))
                t_13)))))))))
double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = (y4 * c) - (y5 * a);
	double t_2 = (x * y2) - (z * y3);
	double t_3 = (y2 * t) - (y3 * y);
	double t_4 = (k * y2) - (j * y3);
	double t_5 = (y4 * b) - (y5 * i);
	double t_6 = ((j * t) - (k * y)) * t_5;
	double t_7 = (b * a) - (i * c);
	double t_8 = t_7 * ((y * x) - (t * z));
	double t_9 = (j * x) - (k * z);
	double t_10 = ((b * y0) - (i * y1)) * t_9;
	double t_11 = t_9 * ((y0 * b) - (i * y1));
	double t_12 = (y4 * y1) - (y5 * y0);
	double t_13 = t_4 * t_12;
	double t_14 = ((y2 * k) - (y3 * j)) * t_12;
	double t_15 = (((((k * y) * (y5 * i)) - ((y * b) * (y4 * k))) - ((y5 * t) * (i * j))) - ((t_3 * t_1) - t_14)) + (t_8 - (t_11 - (((y2 * x) - (y3 * z)) * ((c * y0) - (y1 * a)))));
	double t_16 = ((t_6 - ((y3 * y) * ((y5 * a) - (y4 * c)))) + (((y5 * a) * (t * y2)) + t_13)) + ((t_2 * ((c * y0) - (a * y1))) - (t_10 - (((y * x) - (z * t)) * t_7)));
	double t_17 = (t * y2) - (y * y3);
	double tmp;
	if (y4 < -7.206256231996481e+60) {
		tmp = (t_8 - (t_11 - t_6)) - ((t_3 / (1.0 / t_1)) - t_14);
	} else if (y4 < -3.364603505246317e-66) {
		tmp = (((((t * c) * (i * z)) - ((a * t) * (b * z))) - ((y * c) * (i * x))) - t_10) + ((((y0 * c) - (a * y1)) * t_2) - ((t_17 * ((y4 * c) - (a * y5))) - (((y1 * y4) - (y5 * y0)) * t_4)));
	} else if (y4 < -1.2000065055686116e-105) {
		tmp = t_16;
	} else if (y4 < 6.718963124057495e-279) {
		tmp = t_15;
	} else if (y4 < 4.77962681403792e-222) {
		tmp = t_16;
	} else if (y4 < 2.2852241541266835e-175) {
		tmp = t_15;
	} else {
		tmp = (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - ((k * (i * (z * y1))) - ((j * (i * (x * y1))) + (y0 * (k * (z * b)))))) + ((z * (y3 * (a * y1))) - ((y2 * (x * (a * y1))) + (y0 * (z * (c * y3)))))) + (((t * j) - (y * k)) * t_5)) - (t_17 * t_1)) + t_13;
	}
	return tmp;
}
module fmin_fmax_functions
    implicit none
    private
    public fmax
    public fmin

    interface fmax
        module procedure fmax88
        module procedure fmax44
        module procedure fmax84
        module procedure fmax48
    end interface
    interface fmin
        module procedure fmin88
        module procedure fmin44
        module procedure fmin84
        module procedure fmin48
    end interface
contains
    real(8) function fmax88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(4) function fmax44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, max(x, y), y /= y), x /= x)
    end function
    real(8) function fmax84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, max(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmax48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), max(dble(x), y), y /= y), x /= x)
    end function
    real(8) function fmin88(x, y) result (res)
        real(8), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(4) function fmin44(x, y) result (res)
        real(4), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(y, merge(x, min(x, y), y /= y), x /= x)
    end function
    real(8) function fmin84(x, y) result(res)
        real(8), intent (in) :: x
        real(4), intent (in) :: y
        res = merge(dble(y), merge(x, min(x, dble(y)), y /= y), x /= x)
    end function
    real(8) function fmin48(x, y) result(res)
        real(4), intent (in) :: x
        real(8), intent (in) :: y
        res = merge(y, merge(dble(x), min(dble(x), y), y /= y), x /= x)
    end function
end module

real(8) function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8), intent (in) :: b
    real(8), intent (in) :: c
    real(8), intent (in) :: i
    real(8), intent (in) :: j
    real(8), intent (in) :: k
    real(8), intent (in) :: y0
    real(8), intent (in) :: y1
    real(8), intent (in) :: y2
    real(8), intent (in) :: y3
    real(8), intent (in) :: y4
    real(8), intent (in) :: y5
    real(8) :: t_1
    real(8) :: t_10
    real(8) :: t_11
    real(8) :: t_12
    real(8) :: t_13
    real(8) :: t_14
    real(8) :: t_15
    real(8) :: t_16
    real(8) :: t_17
    real(8) :: t_2
    real(8) :: t_3
    real(8) :: t_4
    real(8) :: t_5
    real(8) :: t_6
    real(8) :: t_7
    real(8) :: t_8
    real(8) :: t_9
    real(8) :: tmp
    t_1 = (y4 * c) - (y5 * a)
    t_2 = (x * y2) - (z * y3)
    t_3 = (y2 * t) - (y3 * y)
    t_4 = (k * y2) - (j * y3)
    t_5 = (y4 * b) - (y5 * i)
    t_6 = ((j * t) - (k * y)) * t_5
    t_7 = (b * a) - (i * c)
    t_8 = t_7 * ((y * x) - (t * z))
    t_9 = (j * x) - (k * z)
    t_10 = ((b * y0) - (i * y1)) * t_9
    t_11 = t_9 * ((y0 * b) - (i * y1))
    t_12 = (y4 * y1) - (y5 * y0)
    t_13 = t_4 * t_12
    t_14 = ((y2 * k) - (y3 * j)) * t_12
    t_15 = (((((k * y) * (y5 * i)) - ((y * b) * (y4 * k))) - ((y5 * t) * (i * j))) - ((t_3 * t_1) - t_14)) + (t_8 - (t_11 - (((y2 * x) - (y3 * z)) * ((c * y0) - (y1 * a)))))
    t_16 = ((t_6 - ((y3 * y) * ((y5 * a) - (y4 * c)))) + (((y5 * a) * (t * y2)) + t_13)) + ((t_2 * ((c * y0) - (a * y1))) - (t_10 - (((y * x) - (z * t)) * t_7)))
    t_17 = (t * y2) - (y * y3)
    if (y4 < (-7.206256231996481d+60)) then
        tmp = (t_8 - (t_11 - t_6)) - ((t_3 / (1.0d0 / t_1)) - t_14)
    else if (y4 < (-3.364603505246317d-66)) then
        tmp = (((((t * c) * (i * z)) - ((a * t) * (b * z))) - ((y * c) * (i * x))) - t_10) + ((((y0 * c) - (a * y1)) * t_2) - ((t_17 * ((y4 * c) - (a * y5))) - (((y1 * y4) - (y5 * y0)) * t_4)))
    else if (y4 < (-1.2000065055686116d-105)) then
        tmp = t_16
    else if (y4 < 6.718963124057495d-279) then
        tmp = t_15
    else if (y4 < 4.77962681403792d-222) then
        tmp = t_16
    else if (y4 < 2.2852241541266835d-175) then
        tmp = t_15
    else
        tmp = (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - ((k * (i * (z * y1))) - ((j * (i * (x * y1))) + (y0 * (k * (z * b)))))) + ((z * (y3 * (a * y1))) - ((y2 * (x * (a * y1))) + (y0 * (z * (c * y3)))))) + (((t * j) - (y * k)) * t_5)) - (t_17 * t_1)) + t_13
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c, double i, double j, double k, double y0, double y1, double y2, double y3, double y4, double y5) {
	double t_1 = (y4 * c) - (y5 * a);
	double t_2 = (x * y2) - (z * y3);
	double t_3 = (y2 * t) - (y3 * y);
	double t_4 = (k * y2) - (j * y3);
	double t_5 = (y4 * b) - (y5 * i);
	double t_6 = ((j * t) - (k * y)) * t_5;
	double t_7 = (b * a) - (i * c);
	double t_8 = t_7 * ((y * x) - (t * z));
	double t_9 = (j * x) - (k * z);
	double t_10 = ((b * y0) - (i * y1)) * t_9;
	double t_11 = t_9 * ((y0 * b) - (i * y1));
	double t_12 = (y4 * y1) - (y5 * y0);
	double t_13 = t_4 * t_12;
	double t_14 = ((y2 * k) - (y3 * j)) * t_12;
	double t_15 = (((((k * y) * (y5 * i)) - ((y * b) * (y4 * k))) - ((y5 * t) * (i * j))) - ((t_3 * t_1) - t_14)) + (t_8 - (t_11 - (((y2 * x) - (y3 * z)) * ((c * y0) - (y1 * a)))));
	double t_16 = ((t_6 - ((y3 * y) * ((y5 * a) - (y4 * c)))) + (((y5 * a) * (t * y2)) + t_13)) + ((t_2 * ((c * y0) - (a * y1))) - (t_10 - (((y * x) - (z * t)) * t_7)));
	double t_17 = (t * y2) - (y * y3);
	double tmp;
	if (y4 < -7.206256231996481e+60) {
		tmp = (t_8 - (t_11 - t_6)) - ((t_3 / (1.0 / t_1)) - t_14);
	} else if (y4 < -3.364603505246317e-66) {
		tmp = (((((t * c) * (i * z)) - ((a * t) * (b * z))) - ((y * c) * (i * x))) - t_10) + ((((y0 * c) - (a * y1)) * t_2) - ((t_17 * ((y4 * c) - (a * y5))) - (((y1 * y4) - (y5 * y0)) * t_4)));
	} else if (y4 < -1.2000065055686116e-105) {
		tmp = t_16;
	} else if (y4 < 6.718963124057495e-279) {
		tmp = t_15;
	} else if (y4 < 4.77962681403792e-222) {
		tmp = t_16;
	} else if (y4 < 2.2852241541266835e-175) {
		tmp = t_15;
	} else {
		tmp = (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - ((k * (i * (z * y1))) - ((j * (i * (x * y1))) + (y0 * (k * (z * b)))))) + ((z * (y3 * (a * y1))) - ((y2 * (x * (a * y1))) + (y0 * (z * (c * y3)))))) + (((t * j) - (y * k)) * t_5)) - (t_17 * t_1)) + t_13;
	}
	return tmp;
}
def code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5):
	t_1 = (y4 * c) - (y5 * a)
	t_2 = (x * y2) - (z * y3)
	t_3 = (y2 * t) - (y3 * y)
	t_4 = (k * y2) - (j * y3)
	t_5 = (y4 * b) - (y5 * i)
	t_6 = ((j * t) - (k * y)) * t_5
	t_7 = (b * a) - (i * c)
	t_8 = t_7 * ((y * x) - (t * z))
	t_9 = (j * x) - (k * z)
	t_10 = ((b * y0) - (i * y1)) * t_9
	t_11 = t_9 * ((y0 * b) - (i * y1))
	t_12 = (y4 * y1) - (y5 * y0)
	t_13 = t_4 * t_12
	t_14 = ((y2 * k) - (y3 * j)) * t_12
	t_15 = (((((k * y) * (y5 * i)) - ((y * b) * (y4 * k))) - ((y5 * t) * (i * j))) - ((t_3 * t_1) - t_14)) + (t_8 - (t_11 - (((y2 * x) - (y3 * z)) * ((c * y0) - (y1 * a)))))
	t_16 = ((t_6 - ((y3 * y) * ((y5 * a) - (y4 * c)))) + (((y5 * a) * (t * y2)) + t_13)) + ((t_2 * ((c * y0) - (a * y1))) - (t_10 - (((y * x) - (z * t)) * t_7)))
	t_17 = (t * y2) - (y * y3)
	tmp = 0
	if y4 < -7.206256231996481e+60:
		tmp = (t_8 - (t_11 - t_6)) - ((t_3 / (1.0 / t_1)) - t_14)
	elif y4 < -3.364603505246317e-66:
		tmp = (((((t * c) * (i * z)) - ((a * t) * (b * z))) - ((y * c) * (i * x))) - t_10) + ((((y0 * c) - (a * y1)) * t_2) - ((t_17 * ((y4 * c) - (a * y5))) - (((y1 * y4) - (y5 * y0)) * t_4)))
	elif y4 < -1.2000065055686116e-105:
		tmp = t_16
	elif y4 < 6.718963124057495e-279:
		tmp = t_15
	elif y4 < 4.77962681403792e-222:
		tmp = t_16
	elif y4 < 2.2852241541266835e-175:
		tmp = t_15
	else:
		tmp = (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - ((k * (i * (z * y1))) - ((j * (i * (x * y1))) + (y0 * (k * (z * b)))))) + ((z * (y3 * (a * y1))) - ((y2 * (x * (a * y1))) + (y0 * (z * (c * y3)))))) + (((t * j) - (y * k)) * t_5)) - (t_17 * t_1)) + t_13
	return tmp
function code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = Float64(Float64(y4 * c) - Float64(y5 * a))
	t_2 = Float64(Float64(x * y2) - Float64(z * y3))
	t_3 = Float64(Float64(y2 * t) - Float64(y3 * y))
	t_4 = Float64(Float64(k * y2) - Float64(j * y3))
	t_5 = Float64(Float64(y4 * b) - Float64(y5 * i))
	t_6 = Float64(Float64(Float64(j * t) - Float64(k * y)) * t_5)
	t_7 = Float64(Float64(b * a) - Float64(i * c))
	t_8 = Float64(t_7 * Float64(Float64(y * x) - Float64(t * z)))
	t_9 = Float64(Float64(j * x) - Float64(k * z))
	t_10 = Float64(Float64(Float64(b * y0) - Float64(i * y1)) * t_9)
	t_11 = Float64(t_9 * Float64(Float64(y0 * b) - Float64(i * y1)))
	t_12 = Float64(Float64(y4 * y1) - Float64(y5 * y0))
	t_13 = Float64(t_4 * t_12)
	t_14 = Float64(Float64(Float64(y2 * k) - Float64(y3 * j)) * t_12)
	t_15 = Float64(Float64(Float64(Float64(Float64(Float64(k * y) * Float64(y5 * i)) - Float64(Float64(y * b) * Float64(y4 * k))) - Float64(Float64(y5 * t) * Float64(i * j))) - Float64(Float64(t_3 * t_1) - t_14)) + Float64(t_8 - Float64(t_11 - Float64(Float64(Float64(y2 * x) - Float64(y3 * z)) * Float64(Float64(c * y0) - Float64(y1 * a))))))
	t_16 = Float64(Float64(Float64(t_6 - Float64(Float64(y3 * y) * Float64(Float64(y5 * a) - Float64(y4 * c)))) + Float64(Float64(Float64(y5 * a) * Float64(t * y2)) + t_13)) + Float64(Float64(t_2 * Float64(Float64(c * y0) - Float64(a * y1))) - Float64(t_10 - Float64(Float64(Float64(y * x) - Float64(z * t)) * t_7))))
	t_17 = Float64(Float64(t * y2) - Float64(y * y3))
	tmp = 0.0
	if (y4 < -7.206256231996481e+60)
		tmp = Float64(Float64(t_8 - Float64(t_11 - t_6)) - Float64(Float64(t_3 / Float64(1.0 / t_1)) - t_14));
	elseif (y4 < -3.364603505246317e-66)
		tmp = Float64(Float64(Float64(Float64(Float64(Float64(t * c) * Float64(i * z)) - Float64(Float64(a * t) * Float64(b * z))) - Float64(Float64(y * c) * Float64(i * x))) - t_10) + Float64(Float64(Float64(Float64(y0 * c) - Float64(a * y1)) * t_2) - Float64(Float64(t_17 * Float64(Float64(y4 * c) - Float64(a * y5))) - Float64(Float64(Float64(y1 * y4) - Float64(y5 * y0)) * t_4))));
	elseif (y4 < -1.2000065055686116e-105)
		tmp = t_16;
	elseif (y4 < 6.718963124057495e-279)
		tmp = t_15;
	elseif (y4 < 4.77962681403792e-222)
		tmp = t_16;
	elseif (y4 < 2.2852241541266835e-175)
		tmp = t_15;
	else
		tmp = Float64(Float64(Float64(Float64(Float64(Float64(Float64(Float64(x * y) - Float64(z * t)) * Float64(Float64(a * b) - Float64(c * i))) - Float64(Float64(k * Float64(i * Float64(z * y1))) - Float64(Float64(j * Float64(i * Float64(x * y1))) + Float64(y0 * Float64(k * Float64(z * b)))))) + Float64(Float64(z * Float64(y3 * Float64(a * y1))) - Float64(Float64(y2 * Float64(x * Float64(a * y1))) + Float64(y0 * Float64(z * Float64(c * y3)))))) + Float64(Float64(Float64(t * j) - Float64(y * k)) * t_5)) - Float64(t_17 * t_1)) + t_13);
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a, b, c, i, j, k, y0, y1, y2, y3, y4, y5)
	t_1 = (y4 * c) - (y5 * a);
	t_2 = (x * y2) - (z * y3);
	t_3 = (y2 * t) - (y3 * y);
	t_4 = (k * y2) - (j * y3);
	t_5 = (y4 * b) - (y5 * i);
	t_6 = ((j * t) - (k * y)) * t_5;
	t_7 = (b * a) - (i * c);
	t_8 = t_7 * ((y * x) - (t * z));
	t_9 = (j * x) - (k * z);
	t_10 = ((b * y0) - (i * y1)) * t_9;
	t_11 = t_9 * ((y0 * b) - (i * y1));
	t_12 = (y4 * y1) - (y5 * y0);
	t_13 = t_4 * t_12;
	t_14 = ((y2 * k) - (y3 * j)) * t_12;
	t_15 = (((((k * y) * (y5 * i)) - ((y * b) * (y4 * k))) - ((y5 * t) * (i * j))) - ((t_3 * t_1) - t_14)) + (t_8 - (t_11 - (((y2 * x) - (y3 * z)) * ((c * y0) - (y1 * a)))));
	t_16 = ((t_6 - ((y3 * y) * ((y5 * a) - (y4 * c)))) + (((y5 * a) * (t * y2)) + t_13)) + ((t_2 * ((c * y0) - (a * y1))) - (t_10 - (((y * x) - (z * t)) * t_7)));
	t_17 = (t * y2) - (y * y3);
	tmp = 0.0;
	if (y4 < -7.206256231996481e+60)
		tmp = (t_8 - (t_11 - t_6)) - ((t_3 / (1.0 / t_1)) - t_14);
	elseif (y4 < -3.364603505246317e-66)
		tmp = (((((t * c) * (i * z)) - ((a * t) * (b * z))) - ((y * c) * (i * x))) - t_10) + ((((y0 * c) - (a * y1)) * t_2) - ((t_17 * ((y4 * c) - (a * y5))) - (((y1 * y4) - (y5 * y0)) * t_4)));
	elseif (y4 < -1.2000065055686116e-105)
		tmp = t_16;
	elseif (y4 < 6.718963124057495e-279)
		tmp = t_15;
	elseif (y4 < 4.77962681403792e-222)
		tmp = t_16;
	elseif (y4 < 2.2852241541266835e-175)
		tmp = t_15;
	else
		tmp = (((((((x * y) - (z * t)) * ((a * b) - (c * i))) - ((k * (i * (z * y1))) - ((j * (i * (x * y1))) + (y0 * (k * (z * b)))))) + ((z * (y3 * (a * y1))) - ((y2 * (x * (a * y1))) + (y0 * (z * (c * y3)))))) + (((t * j) - (y * k)) * t_5)) - (t_17 * t_1)) + t_13;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_, b_, c_, i_, j_, k_, y0_, y1_, y2_, y3_, y4_, y5_] := Block[{t$95$1 = N[(N[(y4 * c), $MachinePrecision] - N[(y5 * a), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(x * y2), $MachinePrecision] - N[(z * y3), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(y2 * t), $MachinePrecision] - N[(y3 * y), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(N[(k * y2), $MachinePrecision] - N[(j * y3), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$5 = N[(N[(y4 * b), $MachinePrecision] - N[(y5 * i), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$6 = N[(N[(N[(j * t), $MachinePrecision] - N[(k * y), $MachinePrecision]), $MachinePrecision] * t$95$5), $MachinePrecision]}, Block[{t$95$7 = N[(N[(b * a), $MachinePrecision] - N[(i * c), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$8 = N[(t$95$7 * N[(N[(y * x), $MachinePrecision] - N[(t * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$9 = N[(N[(j * x), $MachinePrecision] - N[(k * z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$10 = N[(N[(N[(b * y0), $MachinePrecision] - N[(i * y1), $MachinePrecision]), $MachinePrecision] * t$95$9), $MachinePrecision]}, Block[{t$95$11 = N[(t$95$9 * N[(N[(y0 * b), $MachinePrecision] - N[(i * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$12 = N[(N[(y4 * y1), $MachinePrecision] - N[(y5 * y0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$13 = N[(t$95$4 * t$95$12), $MachinePrecision]}, Block[{t$95$14 = N[(N[(N[(y2 * k), $MachinePrecision] - N[(y3 * j), $MachinePrecision]), $MachinePrecision] * t$95$12), $MachinePrecision]}, Block[{t$95$15 = N[(N[(N[(N[(N[(N[(k * y), $MachinePrecision] * N[(y5 * i), $MachinePrecision]), $MachinePrecision] - N[(N[(y * b), $MachinePrecision] * N[(y4 * k), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(y5 * t), $MachinePrecision] * N[(i * j), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(t$95$3 * t$95$1), $MachinePrecision] - t$95$14), $MachinePrecision]), $MachinePrecision] + N[(t$95$8 - N[(t$95$11 - N[(N[(N[(y2 * x), $MachinePrecision] - N[(y3 * z), $MachinePrecision]), $MachinePrecision] * N[(N[(c * y0), $MachinePrecision] - N[(y1 * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$16 = N[(N[(N[(t$95$6 - N[(N[(y3 * y), $MachinePrecision] * N[(N[(y5 * a), $MachinePrecision] - N[(y4 * c), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(y5 * a), $MachinePrecision] * N[(t * y2), $MachinePrecision]), $MachinePrecision] + t$95$13), $MachinePrecision]), $MachinePrecision] + N[(N[(t$95$2 * N[(N[(c * y0), $MachinePrecision] - N[(a * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(t$95$10 - N[(N[(N[(y * x), $MachinePrecision] - N[(z * t), $MachinePrecision]), $MachinePrecision] * t$95$7), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$17 = N[(N[(t * y2), $MachinePrecision] - N[(y * y3), $MachinePrecision]), $MachinePrecision]}, If[Less[y4, -7.206256231996481e+60], N[(N[(t$95$8 - N[(t$95$11 - t$95$6), $MachinePrecision]), $MachinePrecision] - N[(N[(t$95$3 / N[(1.0 / t$95$1), $MachinePrecision]), $MachinePrecision] - t$95$14), $MachinePrecision]), $MachinePrecision], If[Less[y4, -3.364603505246317e-66], N[(N[(N[(N[(N[(N[(t * c), $MachinePrecision] * N[(i * z), $MachinePrecision]), $MachinePrecision] - N[(N[(a * t), $MachinePrecision] * N[(b * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(y * c), $MachinePrecision] * N[(i * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$10), $MachinePrecision] + N[(N[(N[(N[(y0 * c), $MachinePrecision] - N[(a * y1), $MachinePrecision]), $MachinePrecision] * t$95$2), $MachinePrecision] - N[(N[(t$95$17 * N[(N[(y4 * c), $MachinePrecision] - N[(a * y5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(N[(y1 * y4), $MachinePrecision] - N[(y5 * y0), $MachinePrecision]), $MachinePrecision] * t$95$4), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[Less[y4, -1.2000065055686116e-105], t$95$16, If[Less[y4, 6.718963124057495e-279], t$95$15, If[Less[y4, 4.77962681403792e-222], t$95$16, If[Less[y4, 2.2852241541266835e-175], t$95$15, N[(N[(N[(N[(N[(N[(N[(N[(x * y), $MachinePrecision] - N[(z * t), $MachinePrecision]), $MachinePrecision] * N[(N[(a * b), $MachinePrecision] - N[(c * i), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(k * N[(i * N[(z * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(j * N[(i * N[(x * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(y0 * N[(k * N[(z * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(z * N[(y3 * N[(a * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(y2 * N[(x * N[(a * y1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(y0 * N[(z * N[(c * y3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(t * j), $MachinePrecision] - N[(y * k), $MachinePrecision]), $MachinePrecision] * t$95$5), $MachinePrecision]), $MachinePrecision] - N[(t$95$17 * t$95$1), $MachinePrecision]), $MachinePrecision] + t$95$13), $MachinePrecision]]]]]]]]]]]]]]]]]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := y4 \cdot c - y5 \cdot a\\
t_2 := x \cdot y2 - z \cdot y3\\
t_3 := y2 \cdot t - y3 \cdot y\\
t_4 := k \cdot y2 - j \cdot y3\\
t_5 := y4 \cdot b - y5 \cdot i\\
t_6 := \left(j \cdot t - k \cdot y\right) \cdot t\_5\\
t_7 := b \cdot a - i \cdot c\\
t_8 := t\_7 \cdot \left(y \cdot x - t \cdot z\right)\\
t_9 := j \cdot x - k \cdot z\\
t_10 := \left(b \cdot y0 - i \cdot y1\right) \cdot t\_9\\
t_11 := t\_9 \cdot \left(y0 \cdot b - i \cdot y1\right)\\
t_12 := y4 \cdot y1 - y5 \cdot y0\\
t_13 := t\_4 \cdot t\_12\\
t_14 := \left(y2 \cdot k - y3 \cdot j\right) \cdot t\_12\\
t_15 := \left(\left(\left(\left(k \cdot y\right) \cdot \left(y5 \cdot i\right) - \left(y \cdot b\right) \cdot \left(y4 \cdot k\right)\right) - \left(y5 \cdot t\right) \cdot \left(i \cdot j\right)\right) - \left(t\_3 \cdot t\_1 - t\_14\right)\right) + \left(t\_8 - \left(t\_11 - \left(y2 \cdot x - y3 \cdot z\right) \cdot \left(c \cdot y0 - y1 \cdot a\right)\right)\right)\\
t_16 := \left(\left(t\_6 - \left(y3 \cdot y\right) \cdot \left(y5 \cdot a - y4 \cdot c\right)\right) + \left(\left(y5 \cdot a\right) \cdot \left(t \cdot y2\right) + t\_13\right)\right) + \left(t\_2 \cdot \left(c \cdot y0 - a \cdot y1\right) - \left(t\_10 - \left(y \cdot x - z \cdot t\right) \cdot t\_7\right)\right)\\
t_17 := t \cdot y2 - y \cdot y3\\
\mathbf{if}\;y4 < -7.206256231996481 \cdot 10^{+60}:\\
\;\;\;\;\left(t\_8 - \left(t\_11 - t\_6\right)\right) - \left(\frac{t\_3}{\frac{1}{t\_1}} - t\_14\right)\\

\mathbf{elif}\;y4 < -3.364603505246317 \cdot 10^{-66}:\\
\;\;\;\;\left(\left(\left(\left(t \cdot c\right) \cdot \left(i \cdot z\right) - \left(a \cdot t\right) \cdot \left(b \cdot z\right)\right) - \left(y \cdot c\right) \cdot \left(i \cdot x\right)\right) - t\_10\right) + \left(\left(y0 \cdot c - a \cdot y1\right) \cdot t\_2 - \left(t\_17 \cdot \left(y4 \cdot c - a \cdot y5\right) - \left(y1 \cdot y4 - y5 \cdot y0\right) \cdot t\_4\right)\right)\\

\mathbf{elif}\;y4 < -1.2000065055686116 \cdot 10^{-105}:\\
\;\;\;\;t\_16\\

\mathbf{elif}\;y4 < 6.718963124057495 \cdot 10^{-279}:\\
\;\;\;\;t\_15\\

\mathbf{elif}\;y4 < 4.77962681403792 \cdot 10^{-222}:\\
\;\;\;\;t\_16\\

\mathbf{elif}\;y4 < 2.2852241541266835 \cdot 10^{-175}:\\
\;\;\;\;t\_15\\

\mathbf{else}:\\
\;\;\;\;\left(\left(\left(\left(\left(x \cdot y - z \cdot t\right) \cdot \left(a \cdot b - c \cdot i\right) - \left(k \cdot \left(i \cdot \left(z \cdot y1\right)\right) - \left(j \cdot \left(i \cdot \left(x \cdot y1\right)\right) + y0 \cdot \left(k \cdot \left(z \cdot b\right)\right)\right)\right)\right) + \left(z \cdot \left(y3 \cdot \left(a \cdot y1\right)\right) - \left(y2 \cdot \left(x \cdot \left(a \cdot y1\right)\right) + y0 \cdot \left(z \cdot \left(c \cdot y3\right)\right)\right)\right)\right) + \left(t \cdot j - y \cdot k\right) \cdot t\_5\right) - t\_17 \cdot t\_1\right) + t\_13\\


\end{array}
\end{array}

Reproduce

?
herbie shell --seed 2025095 
(FPCore (x y z t a b c i j k y0 y1 y2 y3 y4 y5)
  :name "Linear.Matrix:det44 from linear-1.19.1.3"
  :precision binary64

  :alt
  (! :herbie-platform default (if (< y4 -7206256231996481000000000000000000000000000000000000000000000) (- (- (* (- (* b a) (* i c)) (- (* y x) (* t z))) (- (* (- (* j x) (* k z)) (- (* y0 b) (* i y1))) (* (- (* j t) (* k y)) (- (* y4 b) (* y5 i))))) (- (/ (- (* y2 t) (* y3 y)) (/ 1 (- (* y4 c) (* y5 a)))) (* (- (* y2 k) (* y3 j)) (- (* y4 y1) (* y5 y0))))) (if (< y4 -3364603505246317/1000000000000000000000000000000000000000000000000000000000000000000000000000000000) (+ (- (- (- (* (* t c) (* i z)) (* (* a t) (* b z))) (* (* y c) (* i x))) (* (- (* b y0) (* i y1)) (- (* j x) (* k z)))) (- (* (- (* y0 c) (* a y1)) (- (* x y2) (* z y3))) (- (* (- (* t y2) (* y y3)) (- (* y4 c) (* a y5))) (* (- (* y1 y4) (* y5 y0)) (- (* k y2) (* j y3)))))) (if (< y4 -3000016263921529/2500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (+ (+ (- (* (- (* j t) (* k y)) (- (* y4 b) (* y5 i))) (* (* y3 y) (- (* y5 a) (* y4 c)))) (+ (* (* y5 a) (* t y2)) (* (- (* k y2) (* j y3)) (- (* y4 y1) (* y5 y0))))) (- (* (- (* x y2) (* z y3)) (- (* c y0) (* a y1))) (- (* (- (* b y0) (* i y1)) (- (* j x) (* k z))) (* (- (* y x) (* z t)) (- (* b a) (* i c)))))) (if (< y4 1343792624811499/200000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (+ (- (- (- (* (* k y) (* y5 i)) (* (* y b) (* y4 k))) (* (* y5 t) (* i j))) (- (* (- (* y2 t) (* y3 y)) (- (* y4 c) (* y5 a))) (* (- (* y2 k) (* y3 j)) (- (* y4 y1) (* y5 y0))))) (- (* (- (* b a) (* i c)) (- (* y x) (* t z))) (- (* (- (* j x) (* k z)) (- (* y0 b) (* i y1))) (* (- (* y2 x) (* y3 z)) (- (* c y0) (* y1 a)))))) (if (< y4 29872667587737/6250000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (+ (+ (- (* (- (* j t) (* k y)) (- (* y4 b) (* y5 i))) (* (* y3 y) (- (* y5 a) (* y4 c)))) (+ (* (* y5 a) (* t y2)) (* (- (* k y2) (* j y3)) (- (* y4 y1) (* y5 y0))))) (- (* (- (* x y2) (* z y3)) (- (* c y0) (* a y1))) (- (* (- (* b y0) (* i y1)) (- (* j x) (* k z))) (* (- (* y x) (* z t)) (- (* b a) (* i c)))))) (if (< y4 4570448308253367/20000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (+ (- (- (- (* (* k y) (* y5 i)) (* (* y b) (* y4 k))) (* (* y5 t) (* i j))) (- (* (- (* y2 t) (* y3 y)) (- (* y4 c) (* y5 a))) (* (- (* y2 k) (* y3 j)) (- (* y4 y1) (* y5 y0))))) (- (* (- (* b a) (* i c)) (- (* y x) (* t z))) (- (* (- (* j x) (* k z)) (- (* y0 b) (* i y1))) (* (- (* y2 x) (* y3 z)) (- (* c y0) (* y1 a)))))) (+ (- (+ (+ (- (* (- (* x y) (* z t)) (- (* a b) (* c i))) (- (* k (* i (* z y1))) (+ (* j (* i (* x y1))) (* y0 (* k (* z b)))))) (- (* z (* y3 (* a y1))) (+ (* y2 (* x (* a y1))) (* y0 (* z (* c y3)))))) (* (- (* t j) (* y k)) (- (* y4 b) (* y5 i)))) (* (- (* t y2) (* y y3)) (- (* y4 c) (* y5 a)))) (* (- (* k y2) (* j y3)) (- (* y4 y1) (* y5 y0)))))))))))

  (+ (- (+ (+ (- (* (- (* x y) (* z t)) (- (* a b) (* c i))) (* (- (* x j) (* z k)) (- (* y0 b) (* y1 i)))) (* (- (* x y2) (* z y3)) (- (* y0 c) (* y1 a)))) (* (- (* t j) (* y k)) (- (* y4 b) (* y5 i)))) (* (- (* t y2) (* y y3)) (- (* y4 c) (* y5 a)))) (* (- (* k y2) (* j y3)) (- (* y4 y1) (* y5 y0)))))