Graphics.Rendering.Chart.Plot.AreaSpots:renderAreaSpots4D from Chart-1.5.3

Percentage Accurate: 84.4% → 95.6%
Time: 7.2s
Alternatives: 8
Speedup: 0.7×

Specification

?
\[\begin{array}{l} \\ \frac{x \cdot \left(y - z\right)}{t - z} \end{array} \]
(FPCore (x y z t) :precision binary64 (/ (* x (- y z)) (- t z)))
double code(double x, double y, double z, double t) {
	return (x * (y - z)) / (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)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    code = (x * (y - z)) / (t - z)
end function
public static double code(double x, double y, double z, double t) {
	return (x * (y - z)) / (t - z);
}
def code(x, y, z, t):
	return (x * (y - z)) / (t - z)
function code(x, y, z, t)
	return Float64(Float64(x * Float64(y - z)) / Float64(t - z))
end
function tmp = code(x, y, z, t)
	tmp = (x * (y - z)) / (t - z);
end
code[x_, y_, z_, t_] := N[(N[(x * N[(y - z), $MachinePrecision]), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\frac{x \cdot \left(y - z\right)}{t - z}
\end{array}

Sampling outcomes in binary64 precision:

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 8 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: 84.4% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \frac{x \cdot \left(y - z\right)}{t - z} \end{array} \]
(FPCore (x y z t) :precision binary64 (/ (* x (- y z)) (- t z)))
double code(double x, double y, double z, double t) {
	return (x * (y - z)) / (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)
use fmin_fmax_functions
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    code = (x * (y - z)) / (t - z)
end function
public static double code(double x, double y, double z, double t) {
	return (x * (y - z)) / (t - z);
}
def code(x, y, z, t):
	return (x * (y - z)) / (t - z)
function code(x, y, z, t)
	return Float64(Float64(x * Float64(y - z)) / Float64(t - z))
end
function tmp = code(x, y, z, t)
	tmp = (x * (y - z)) / (t - z);
end
code[x_, y_, z_, t_] := N[(N[(x * N[(y - z), $MachinePrecision]), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\frac{x \cdot \left(y - z\right)}{t - z}
\end{array}

Alternative 1: 95.6% accurate, 0.5× speedup?

\[\begin{array}{l} x\_m = \left|x\right| \\ x\_s = \mathsf{copysign}\left(1, x\right) \\ \begin{array}{l} t_1 := \frac{x\_m \cdot \left(y - z\right)}{t - z}\\ x\_s \cdot \begin{array}{l} \mathbf{if}\;t\_1 \leq 2 \cdot 10^{+298}:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;\frac{x\_m}{t - z} \cdot \left(y - z\right)\\ \end{array} \end{array} \end{array} \]
x\_m = (fabs.f64 x)
x\_s = (copysign.f64 #s(literal 1 binary64) x)
(FPCore (x_s x_m y z t)
 :precision binary64
 (let* ((t_1 (/ (* x_m (- y z)) (- t z))))
   (* x_s (if (<= t_1 2e+298) t_1 (* (/ x_m (- t z)) (- y z))))))
x\_m = fabs(x);
x\_s = copysign(1.0, x);
double code(double x_s, double x_m, double y, double z, double t) {
	double t_1 = (x_m * (y - z)) / (t - z);
	double tmp;
	if (t_1 <= 2e+298) {
		tmp = t_1;
	} else {
		tmp = (x_m / (t - z)) * (y - z);
	}
	return x_s * tmp;
}
x\_m =     private
x\_s =     private
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_s, x_m, y, z, t)
use fmin_fmax_functions
    real(8), intent (in) :: x_s
    real(8), intent (in) :: x_m
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: t_1
    real(8) :: tmp
    t_1 = (x_m * (y - z)) / (t - z)
    if (t_1 <= 2d+298) then
        tmp = t_1
    else
        tmp = (x_m / (t - z)) * (y - z)
    end if
    code = x_s * tmp
end function
x\_m = Math.abs(x);
x\_s = Math.copySign(1.0, x);
public static double code(double x_s, double x_m, double y, double z, double t) {
	double t_1 = (x_m * (y - z)) / (t - z);
	double tmp;
	if (t_1 <= 2e+298) {
		tmp = t_1;
	} else {
		tmp = (x_m / (t - z)) * (y - z);
	}
	return x_s * tmp;
}
x\_m = math.fabs(x)
x\_s = math.copysign(1.0, x)
def code(x_s, x_m, y, z, t):
	t_1 = (x_m * (y - z)) / (t - z)
	tmp = 0
	if t_1 <= 2e+298:
		tmp = t_1
	else:
		tmp = (x_m / (t - z)) * (y - z)
	return x_s * tmp
x\_m = abs(x)
x\_s = copysign(1.0, x)
function code(x_s, x_m, y, z, t)
	t_1 = Float64(Float64(x_m * Float64(y - z)) / Float64(t - z))
	tmp = 0.0
	if (t_1 <= 2e+298)
		tmp = t_1;
	else
		tmp = Float64(Float64(x_m / Float64(t - z)) * Float64(y - z));
	end
	return Float64(x_s * tmp)
end
x\_m = abs(x);
x\_s = sign(x) * abs(1.0);
function tmp_2 = code(x_s, x_m, y, z, t)
	t_1 = (x_m * (y - z)) / (t - z);
	tmp = 0.0;
	if (t_1 <= 2e+298)
		tmp = t_1;
	else
		tmp = (x_m / (t - z)) * (y - z);
	end
	tmp_2 = x_s * tmp;
end
x\_m = N[Abs[x], $MachinePrecision]
x\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[x]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[x$95$s_, x$95$m_, y_, z_, t_] := Block[{t$95$1 = N[(N[(x$95$m * N[(y - z), $MachinePrecision]), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision]}, N[(x$95$s * If[LessEqual[t$95$1, 2e+298], t$95$1, N[(N[(x$95$m / N[(t - z), $MachinePrecision]), $MachinePrecision] * N[(y - z), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]]
\begin{array}{l}
x\_m = \left|x\right|
\\
x\_s = \mathsf{copysign}\left(1, x\right)

\\
\begin{array}{l}
t_1 := \frac{x\_m \cdot \left(y - z\right)}{t - z}\\
x\_s \cdot \begin{array}{l}
\mathbf{if}\;t\_1 \leq 2 \cdot 10^{+298}:\\
\;\;\;\;t\_1\\

\mathbf{else}:\\
\;\;\;\;\frac{x\_m}{t - z} \cdot \left(y - z\right)\\


\end{array}
\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (/.f64 (*.f64 x (-.f64 y z)) (-.f64 t z)) < 1.9999999999999999e298

    1. Initial program 92.3%

      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
    2. Add Preprocessing

    if 1.9999999999999999e298 < (/.f64 (*.f64 x (-.f64 y z)) (-.f64 t z))

    1. Initial program 44.9%

      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
    2. Add Preprocessing
    3. Applied rewrites99.9%

      \[\leadsto \color{blue}{\frac{x}{t - z} \cdot \left(y - z\right)} \]
  3. Recombined 2 regimes into one program.
  4. Add Preprocessing

Alternative 2: 75.0% accurate, 0.6× speedup?

\[\begin{array}{l} x\_m = \left|x\right| \\ x\_s = \mathsf{copysign}\left(1, x\right) \\ \begin{array}{l} t_1 := \frac{z - y}{z} \cdot x\_m\\ x\_s \cdot \begin{array}{l} \mathbf{if}\;z \leq -1.15 \cdot 10^{-15}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq 920000000000:\\ \;\;\;\;\frac{y}{t - z} \cdot x\_m\\ \mathbf{elif}\;z \leq 7.6 \cdot 10^{+40}:\\ \;\;\;\;\frac{x\_m \cdot \left(-z\right)}{t - z}\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \end{array} \]
x\_m = (fabs.f64 x)
x\_s = (copysign.f64 #s(literal 1 binary64) x)
(FPCore (x_s x_m y z t)
 :precision binary64
 (let* ((t_1 (* (/ (- z y) z) x_m)))
   (*
    x_s
    (if (<= z -1.15e-15)
      t_1
      (if (<= z 920000000000.0)
        (* (/ y (- t z)) x_m)
        (if (<= z 7.6e+40) (/ (* x_m (- z)) (- t z)) t_1))))))
x\_m = fabs(x);
x\_s = copysign(1.0, x);
double code(double x_s, double x_m, double y, double z, double t) {
	double t_1 = ((z - y) / z) * x_m;
	double tmp;
	if (z <= -1.15e-15) {
		tmp = t_1;
	} else if (z <= 920000000000.0) {
		tmp = (y / (t - z)) * x_m;
	} else if (z <= 7.6e+40) {
		tmp = (x_m * -z) / (t - z);
	} else {
		tmp = t_1;
	}
	return x_s * tmp;
}
x\_m =     private
x\_s =     private
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_s, x_m, y, z, t)
use fmin_fmax_functions
    real(8), intent (in) :: x_s
    real(8), intent (in) :: x_m
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: t_1
    real(8) :: tmp
    t_1 = ((z - y) / z) * x_m
    if (z <= (-1.15d-15)) then
        tmp = t_1
    else if (z <= 920000000000.0d0) then
        tmp = (y / (t - z)) * x_m
    else if (z <= 7.6d+40) then
        tmp = (x_m * -z) / (t - z)
    else
        tmp = t_1
    end if
    code = x_s * tmp
end function
x\_m = Math.abs(x);
x\_s = Math.copySign(1.0, x);
public static double code(double x_s, double x_m, double y, double z, double t) {
	double t_1 = ((z - y) / z) * x_m;
	double tmp;
	if (z <= -1.15e-15) {
		tmp = t_1;
	} else if (z <= 920000000000.0) {
		tmp = (y / (t - z)) * x_m;
	} else if (z <= 7.6e+40) {
		tmp = (x_m * -z) / (t - z);
	} else {
		tmp = t_1;
	}
	return x_s * tmp;
}
x\_m = math.fabs(x)
x\_s = math.copysign(1.0, x)
def code(x_s, x_m, y, z, t):
	t_1 = ((z - y) / z) * x_m
	tmp = 0
	if z <= -1.15e-15:
		tmp = t_1
	elif z <= 920000000000.0:
		tmp = (y / (t - z)) * x_m
	elif z <= 7.6e+40:
		tmp = (x_m * -z) / (t - z)
	else:
		tmp = t_1
	return x_s * tmp
x\_m = abs(x)
x\_s = copysign(1.0, x)
function code(x_s, x_m, y, z, t)
	t_1 = Float64(Float64(Float64(z - y) / z) * x_m)
	tmp = 0.0
	if (z <= -1.15e-15)
		tmp = t_1;
	elseif (z <= 920000000000.0)
		tmp = Float64(Float64(y / Float64(t - z)) * x_m);
	elseif (z <= 7.6e+40)
		tmp = Float64(Float64(x_m * Float64(-z)) / Float64(t - z));
	else
		tmp = t_1;
	end
	return Float64(x_s * tmp)
end
x\_m = abs(x);
x\_s = sign(x) * abs(1.0);
function tmp_2 = code(x_s, x_m, y, z, t)
	t_1 = ((z - y) / z) * x_m;
	tmp = 0.0;
	if (z <= -1.15e-15)
		tmp = t_1;
	elseif (z <= 920000000000.0)
		tmp = (y / (t - z)) * x_m;
	elseif (z <= 7.6e+40)
		tmp = (x_m * -z) / (t - z);
	else
		tmp = t_1;
	end
	tmp_2 = x_s * tmp;
end
x\_m = N[Abs[x], $MachinePrecision]
x\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[x]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
code[x$95$s_, x$95$m_, y_, z_, t_] := Block[{t$95$1 = N[(N[(N[(z - y), $MachinePrecision] / z), $MachinePrecision] * x$95$m), $MachinePrecision]}, N[(x$95$s * If[LessEqual[z, -1.15e-15], t$95$1, If[LessEqual[z, 920000000000.0], N[(N[(y / N[(t - z), $MachinePrecision]), $MachinePrecision] * x$95$m), $MachinePrecision], If[LessEqual[z, 7.6e+40], N[(N[(x$95$m * (-z)), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision], t$95$1]]]), $MachinePrecision]]
\begin{array}{l}
x\_m = \left|x\right|
\\
x\_s = \mathsf{copysign}\left(1, x\right)

\\
\begin{array}{l}
t_1 := \frac{z - y}{z} \cdot x\_m\\
x\_s \cdot \begin{array}{l}
\mathbf{if}\;z \leq -1.15 \cdot 10^{-15}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;z \leq 920000000000:\\
\;\;\;\;\frac{y}{t - z} \cdot x\_m\\

\mathbf{elif}\;z \leq 7.6 \cdot 10^{+40}:\\
\;\;\;\;\frac{x\_m \cdot \left(-z\right)}{t - z}\\

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


\end{array}
\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -1.14999999999999995e-15 or 7.60000000000000009e40 < z

    1. Initial program 76.3%

      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
    2. Add Preprocessing
    3. Taylor expanded in t around 0

      \[\leadsto \color{blue}{-1 \cdot \frac{x \cdot \left(y - z\right)}{z}} \]
    4. Step-by-step derivation
      1. Applied rewrites82.0%

        \[\leadsto \color{blue}{\frac{z - y}{z} \cdot x} \]

      if -1.14999999999999995e-15 < z < 9.2e11

      1. Initial program 94.1%

        \[\frac{x \cdot \left(y - z\right)}{t - z} \]
      2. Add Preprocessing
      3. Taylor expanded in y around inf

        \[\leadsto \color{blue}{\frac{x \cdot y}{t - z}} \]
      4. Step-by-step derivation
        1. Applied rewrites80.9%

          \[\leadsto \color{blue}{\frac{y}{t - z} \cdot x} \]

        if 9.2e11 < z < 7.60000000000000009e40

        1. Initial program 99.3%

          \[\frac{x \cdot \left(y - z\right)}{t - z} \]
        2. Add Preprocessing
        3. Taylor expanded in y around 0

          \[\leadsto \frac{x \cdot \color{blue}{\left(-1 \cdot z\right)}}{t - z} \]
        4. Step-by-step derivation
          1. Applied rewrites99.3%

            \[\leadsto \frac{x \cdot \color{blue}{\left(-z\right)}}{t - z} \]
        5. Recombined 3 regimes into one program.
        6. Add Preprocessing

        Alternative 3: 90.1% accurate, 0.7× speedup?

        \[\begin{array}{l} x\_m = \left|x\right| \\ x\_s = \mathsf{copysign}\left(1, x\right) \\ x\_s \cdot \begin{array}{l} \mathbf{if}\;z \leq -1.7 \cdot 10^{+158} \lor \neg \left(z \leq 1.15 \cdot 10^{+160}\right):\\ \;\;\;\;\frac{z - y}{z} \cdot x\_m\\ \mathbf{else}:\\ \;\;\;\;\frac{x\_m}{t - z} \cdot \left(y - z\right)\\ \end{array} \end{array} \]
        x\_m = (fabs.f64 x)
        x\_s = (copysign.f64 #s(literal 1 binary64) x)
        (FPCore (x_s x_m y z t)
         :precision binary64
         (*
          x_s
          (if (or (<= z -1.7e+158) (not (<= z 1.15e+160)))
            (* (/ (- z y) z) x_m)
            (* (/ x_m (- t z)) (- y z)))))
        x\_m = fabs(x);
        x\_s = copysign(1.0, x);
        double code(double x_s, double x_m, double y, double z, double t) {
        	double tmp;
        	if ((z <= -1.7e+158) || !(z <= 1.15e+160)) {
        		tmp = ((z - y) / z) * x_m;
        	} else {
        		tmp = (x_m / (t - z)) * (y - z);
        	}
        	return x_s * tmp;
        }
        
        x\_m =     private
        x\_s =     private
        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_s, x_m, y, z, t)
        use fmin_fmax_functions
            real(8), intent (in) :: x_s
            real(8), intent (in) :: x_m
            real(8), intent (in) :: y
            real(8), intent (in) :: z
            real(8), intent (in) :: t
            real(8) :: tmp
            if ((z <= (-1.7d+158)) .or. (.not. (z <= 1.15d+160))) then
                tmp = ((z - y) / z) * x_m
            else
                tmp = (x_m / (t - z)) * (y - z)
            end if
            code = x_s * tmp
        end function
        
        x\_m = Math.abs(x);
        x\_s = Math.copySign(1.0, x);
        public static double code(double x_s, double x_m, double y, double z, double t) {
        	double tmp;
        	if ((z <= -1.7e+158) || !(z <= 1.15e+160)) {
        		tmp = ((z - y) / z) * x_m;
        	} else {
        		tmp = (x_m / (t - z)) * (y - z);
        	}
        	return x_s * tmp;
        }
        
        x\_m = math.fabs(x)
        x\_s = math.copysign(1.0, x)
        def code(x_s, x_m, y, z, t):
        	tmp = 0
        	if (z <= -1.7e+158) or not (z <= 1.15e+160):
        		tmp = ((z - y) / z) * x_m
        	else:
        		tmp = (x_m / (t - z)) * (y - z)
        	return x_s * tmp
        
        x\_m = abs(x)
        x\_s = copysign(1.0, x)
        function code(x_s, x_m, y, z, t)
        	tmp = 0.0
        	if ((z <= -1.7e+158) || !(z <= 1.15e+160))
        		tmp = Float64(Float64(Float64(z - y) / z) * x_m);
        	else
        		tmp = Float64(Float64(x_m / Float64(t - z)) * Float64(y - z));
        	end
        	return Float64(x_s * tmp)
        end
        
        x\_m = abs(x);
        x\_s = sign(x) * abs(1.0);
        function tmp_2 = code(x_s, x_m, y, z, t)
        	tmp = 0.0;
        	if ((z <= -1.7e+158) || ~((z <= 1.15e+160)))
        		tmp = ((z - y) / z) * x_m;
        	else
        		tmp = (x_m / (t - z)) * (y - z);
        	end
        	tmp_2 = x_s * tmp;
        end
        
        x\_m = N[Abs[x], $MachinePrecision]
        x\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[x]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
        code[x$95$s_, x$95$m_, y_, z_, t_] := N[(x$95$s * If[Or[LessEqual[z, -1.7e+158], N[Not[LessEqual[z, 1.15e+160]], $MachinePrecision]], N[(N[(N[(z - y), $MachinePrecision] / z), $MachinePrecision] * x$95$m), $MachinePrecision], N[(N[(x$95$m / N[(t - z), $MachinePrecision]), $MachinePrecision] * N[(y - z), $MachinePrecision]), $MachinePrecision]]), $MachinePrecision]
        
        \begin{array}{l}
        x\_m = \left|x\right|
        \\
        x\_s = \mathsf{copysign}\left(1, x\right)
        
        \\
        x\_s \cdot \begin{array}{l}
        \mathbf{if}\;z \leq -1.7 \cdot 10^{+158} \lor \neg \left(z \leq 1.15 \cdot 10^{+160}\right):\\
        \;\;\;\;\frac{z - y}{z} \cdot x\_m\\
        
        \mathbf{else}:\\
        \;\;\;\;\frac{x\_m}{t - z} \cdot \left(y - z\right)\\
        
        
        \end{array}
        \end{array}
        
        Derivation
        1. Split input into 2 regimes
        2. if z < -1.7e158 or 1.14999999999999994e160 < z

          1. Initial program 69.0%

            \[\frac{x \cdot \left(y - z\right)}{t - z} \]
          2. Add Preprocessing
          3. Taylor expanded in t around 0

            \[\leadsto \color{blue}{-1 \cdot \frac{x \cdot \left(y - z\right)}{z}} \]
          4. Step-by-step derivation
            1. Applied rewrites92.3%

              \[\leadsto \color{blue}{\frac{z - y}{z} \cdot x} \]

            if -1.7e158 < z < 1.14999999999999994e160

            1. Initial program 90.8%

              \[\frac{x \cdot \left(y - z\right)}{t - z} \]
            2. Add Preprocessing
            3. Applied rewrites93.8%

              \[\leadsto \color{blue}{\frac{x}{t - z} \cdot \left(y - z\right)} \]
          5. Recombined 2 regimes into one program.
          6. Final simplification93.4%

            \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.7 \cdot 10^{+158} \lor \neg \left(z \leq 1.15 \cdot 10^{+160}\right):\\ \;\;\;\;\frac{z - y}{z} \cdot x\\ \mathbf{else}:\\ \;\;\;\;\frac{x}{t - z} \cdot \left(y - z\right)\\ \end{array} \]
          7. Add Preprocessing

          Alternative 4: 74.8% accurate, 0.7× speedup?

          \[\begin{array}{l} x\_m = \left|x\right| \\ x\_s = \mathsf{copysign}\left(1, x\right) \\ x\_s \cdot \begin{array}{l} \mathbf{if}\;z \leq -1.15 \cdot 10^{-15} \lor \neg \left(z \leq 1080000000000\right):\\ \;\;\;\;\frac{z - y}{z} \cdot x\_m\\ \mathbf{else}:\\ \;\;\;\;\frac{y}{t - z} \cdot x\_m\\ \end{array} \end{array} \]
          x\_m = (fabs.f64 x)
          x\_s = (copysign.f64 #s(literal 1 binary64) x)
          (FPCore (x_s x_m y z t)
           :precision binary64
           (*
            x_s
            (if (or (<= z -1.15e-15) (not (<= z 1080000000000.0)))
              (* (/ (- z y) z) x_m)
              (* (/ y (- t z)) x_m))))
          x\_m = fabs(x);
          x\_s = copysign(1.0, x);
          double code(double x_s, double x_m, double y, double z, double t) {
          	double tmp;
          	if ((z <= -1.15e-15) || !(z <= 1080000000000.0)) {
          		tmp = ((z - y) / z) * x_m;
          	} else {
          		tmp = (y / (t - z)) * x_m;
          	}
          	return x_s * tmp;
          }
          
          x\_m =     private
          x\_s =     private
          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_s, x_m, y, z, t)
          use fmin_fmax_functions
              real(8), intent (in) :: x_s
              real(8), intent (in) :: x_m
              real(8), intent (in) :: y
              real(8), intent (in) :: z
              real(8), intent (in) :: t
              real(8) :: tmp
              if ((z <= (-1.15d-15)) .or. (.not. (z <= 1080000000000.0d0))) then
                  tmp = ((z - y) / z) * x_m
              else
                  tmp = (y / (t - z)) * x_m
              end if
              code = x_s * tmp
          end function
          
          x\_m = Math.abs(x);
          x\_s = Math.copySign(1.0, x);
          public static double code(double x_s, double x_m, double y, double z, double t) {
          	double tmp;
          	if ((z <= -1.15e-15) || !(z <= 1080000000000.0)) {
          		tmp = ((z - y) / z) * x_m;
          	} else {
          		tmp = (y / (t - z)) * x_m;
          	}
          	return x_s * tmp;
          }
          
          x\_m = math.fabs(x)
          x\_s = math.copysign(1.0, x)
          def code(x_s, x_m, y, z, t):
          	tmp = 0
          	if (z <= -1.15e-15) or not (z <= 1080000000000.0):
          		tmp = ((z - y) / z) * x_m
          	else:
          		tmp = (y / (t - z)) * x_m
          	return x_s * tmp
          
          x\_m = abs(x)
          x\_s = copysign(1.0, x)
          function code(x_s, x_m, y, z, t)
          	tmp = 0.0
          	if ((z <= -1.15e-15) || !(z <= 1080000000000.0))
          		tmp = Float64(Float64(Float64(z - y) / z) * x_m);
          	else
          		tmp = Float64(Float64(y / Float64(t - z)) * x_m);
          	end
          	return Float64(x_s * tmp)
          end
          
          x\_m = abs(x);
          x\_s = sign(x) * abs(1.0);
          function tmp_2 = code(x_s, x_m, y, z, t)
          	tmp = 0.0;
          	if ((z <= -1.15e-15) || ~((z <= 1080000000000.0)))
          		tmp = ((z - y) / z) * x_m;
          	else
          		tmp = (y / (t - z)) * x_m;
          	end
          	tmp_2 = x_s * tmp;
          end
          
          x\_m = N[Abs[x], $MachinePrecision]
          x\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[x]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
          code[x$95$s_, x$95$m_, y_, z_, t_] := N[(x$95$s * If[Or[LessEqual[z, -1.15e-15], N[Not[LessEqual[z, 1080000000000.0]], $MachinePrecision]], N[(N[(N[(z - y), $MachinePrecision] / z), $MachinePrecision] * x$95$m), $MachinePrecision], N[(N[(y / N[(t - z), $MachinePrecision]), $MachinePrecision] * x$95$m), $MachinePrecision]]), $MachinePrecision]
          
          \begin{array}{l}
          x\_m = \left|x\right|
          \\
          x\_s = \mathsf{copysign}\left(1, x\right)
          
          \\
          x\_s \cdot \begin{array}{l}
          \mathbf{if}\;z \leq -1.15 \cdot 10^{-15} \lor \neg \left(z \leq 1080000000000\right):\\
          \;\;\;\;\frac{z - y}{z} \cdot x\_m\\
          
          \mathbf{else}:\\
          \;\;\;\;\frac{y}{t - z} \cdot x\_m\\
          
          
          \end{array}
          \end{array}
          
          Derivation
          1. Split input into 2 regimes
          2. if z < -1.14999999999999995e-15 or 1.08e12 < z

            1. Initial program 77.5%

              \[\frac{x \cdot \left(y - z\right)}{t - z} \]
            2. Add Preprocessing
            3. Taylor expanded in t around 0

              \[\leadsto \color{blue}{-1 \cdot \frac{x \cdot \left(y - z\right)}{z}} \]
            4. Step-by-step derivation
              1. Applied rewrites79.2%

                \[\leadsto \color{blue}{\frac{z - y}{z} \cdot x} \]

              if -1.14999999999999995e-15 < z < 1.08e12

              1. Initial program 94.1%

                \[\frac{x \cdot \left(y - z\right)}{t - z} \]
              2. Add Preprocessing
              3. Taylor expanded in y around inf

                \[\leadsto \color{blue}{\frac{x \cdot y}{t - z}} \]
              4. Step-by-step derivation
                1. Applied rewrites80.9%

                  \[\leadsto \color{blue}{\frac{y}{t - z} \cdot x} \]
              5. Recombined 2 regimes into one program.
              6. Final simplification80.1%

                \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.15 \cdot 10^{-15} \lor \neg \left(z \leq 1080000000000\right):\\ \;\;\;\;\frac{z - y}{z} \cdot x\\ \mathbf{else}:\\ \;\;\;\;\frac{y}{t - z} \cdot x\\ \end{array} \]
              7. Add Preprocessing

              Alternative 5: 68.3% accurate, 0.7× speedup?

              \[\begin{array}{l} x\_m = \left|x\right| \\ x\_s = \mathsf{copysign}\left(1, x\right) \\ x\_s \cdot \begin{array}{l} \mathbf{if}\;z \leq -8.2 \cdot 10^{+145}:\\ \;\;\;\;x\_m\\ \mathbf{elif}\;z \leq 9.2 \cdot 10^{+98}:\\ \;\;\;\;\frac{y}{t - z} \cdot x\_m\\ \mathbf{else}:\\ \;\;\;\;x\_m\\ \end{array} \end{array} \]
              x\_m = (fabs.f64 x)
              x\_s = (copysign.f64 #s(literal 1 binary64) x)
              (FPCore (x_s x_m y z t)
               :precision binary64
               (*
                x_s
                (if (<= z -8.2e+145) x_m (if (<= z 9.2e+98) (* (/ y (- t z)) x_m) x_m))))
              x\_m = fabs(x);
              x\_s = copysign(1.0, x);
              double code(double x_s, double x_m, double y, double z, double t) {
              	double tmp;
              	if (z <= -8.2e+145) {
              		tmp = x_m;
              	} else if (z <= 9.2e+98) {
              		tmp = (y / (t - z)) * x_m;
              	} else {
              		tmp = x_m;
              	}
              	return x_s * tmp;
              }
              
              x\_m =     private
              x\_s =     private
              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_s, x_m, y, z, t)
              use fmin_fmax_functions
                  real(8), intent (in) :: x_s
                  real(8), intent (in) :: x_m
                  real(8), intent (in) :: y
                  real(8), intent (in) :: z
                  real(8), intent (in) :: t
                  real(8) :: tmp
                  if (z <= (-8.2d+145)) then
                      tmp = x_m
                  else if (z <= 9.2d+98) then
                      tmp = (y / (t - z)) * x_m
                  else
                      tmp = x_m
                  end if
                  code = x_s * tmp
              end function
              
              x\_m = Math.abs(x);
              x\_s = Math.copySign(1.0, x);
              public static double code(double x_s, double x_m, double y, double z, double t) {
              	double tmp;
              	if (z <= -8.2e+145) {
              		tmp = x_m;
              	} else if (z <= 9.2e+98) {
              		tmp = (y / (t - z)) * x_m;
              	} else {
              		tmp = x_m;
              	}
              	return x_s * tmp;
              }
              
              x\_m = math.fabs(x)
              x\_s = math.copysign(1.0, x)
              def code(x_s, x_m, y, z, t):
              	tmp = 0
              	if z <= -8.2e+145:
              		tmp = x_m
              	elif z <= 9.2e+98:
              		tmp = (y / (t - z)) * x_m
              	else:
              		tmp = x_m
              	return x_s * tmp
              
              x\_m = abs(x)
              x\_s = copysign(1.0, x)
              function code(x_s, x_m, y, z, t)
              	tmp = 0.0
              	if (z <= -8.2e+145)
              		tmp = x_m;
              	elseif (z <= 9.2e+98)
              		tmp = Float64(Float64(y / Float64(t - z)) * x_m);
              	else
              		tmp = x_m;
              	end
              	return Float64(x_s * tmp)
              end
              
              x\_m = abs(x);
              x\_s = sign(x) * abs(1.0);
              function tmp_2 = code(x_s, x_m, y, z, t)
              	tmp = 0.0;
              	if (z <= -8.2e+145)
              		tmp = x_m;
              	elseif (z <= 9.2e+98)
              		tmp = (y / (t - z)) * x_m;
              	else
              		tmp = x_m;
              	end
              	tmp_2 = x_s * tmp;
              end
              
              x\_m = N[Abs[x], $MachinePrecision]
              x\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[x]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
              code[x$95$s_, x$95$m_, y_, z_, t_] := N[(x$95$s * If[LessEqual[z, -8.2e+145], x$95$m, If[LessEqual[z, 9.2e+98], N[(N[(y / N[(t - z), $MachinePrecision]), $MachinePrecision] * x$95$m), $MachinePrecision], x$95$m]]), $MachinePrecision]
              
              \begin{array}{l}
              x\_m = \left|x\right|
              \\
              x\_s = \mathsf{copysign}\left(1, x\right)
              
              \\
              x\_s \cdot \begin{array}{l}
              \mathbf{if}\;z \leq -8.2 \cdot 10^{+145}:\\
              \;\;\;\;x\_m\\
              
              \mathbf{elif}\;z \leq 9.2 \cdot 10^{+98}:\\
              \;\;\;\;\frac{y}{t - z} \cdot x\_m\\
              
              \mathbf{else}:\\
              \;\;\;\;x\_m\\
              
              
              \end{array}
              \end{array}
              
              Derivation
              1. Split input into 2 regimes
              2. if z < -8.2000000000000003e145 or 9.20000000000000053e98 < z

                1. Initial program 73.1%

                  \[\frac{x \cdot \left(y - z\right)}{t - z} \]
                2. Add Preprocessing
                3. Taylor expanded in z around inf

                  \[\leadsto \color{blue}{x} \]
                4. Step-by-step derivation
                  1. Applied rewrites74.9%

                    \[\leadsto \color{blue}{x} \]

                  if -8.2000000000000003e145 < z < 9.20000000000000053e98

                  1. Initial program 91.4%

                    \[\frac{x \cdot \left(y - z\right)}{t - z} \]
                  2. Add Preprocessing
                  3. Taylor expanded in y around inf

                    \[\leadsto \color{blue}{\frac{x \cdot y}{t - z}} \]
                  4. Step-by-step derivation
                    1. Applied rewrites69.9%

                      \[\leadsto \color{blue}{\frac{y}{t - z} \cdot x} \]
                  5. Recombined 2 regimes into one program.
                  6. Add Preprocessing

                  Alternative 6: 61.2% accurate, 0.8× speedup?

                  \[\begin{array}{l} x\_m = \left|x\right| \\ x\_s = \mathsf{copysign}\left(1, x\right) \\ x\_s \cdot \begin{array}{l} \mathbf{if}\;z \leq -1.15 \cdot 10^{-15}:\\ \;\;\;\;x\_m\\ \mathbf{elif}\;z \leq 1080000000000:\\ \;\;\;\;\frac{y}{t} \cdot x\_m\\ \mathbf{else}:\\ \;\;\;\;x\_m\\ \end{array} \end{array} \]
                  x\_m = (fabs.f64 x)
                  x\_s = (copysign.f64 #s(literal 1 binary64) x)
                  (FPCore (x_s x_m y z t)
                   :precision binary64
                   (*
                    x_s
                    (if (<= z -1.15e-15) x_m (if (<= z 1080000000000.0) (* (/ y t) x_m) x_m))))
                  x\_m = fabs(x);
                  x\_s = copysign(1.0, x);
                  double code(double x_s, double x_m, double y, double z, double t) {
                  	double tmp;
                  	if (z <= -1.15e-15) {
                  		tmp = x_m;
                  	} else if (z <= 1080000000000.0) {
                  		tmp = (y / t) * x_m;
                  	} else {
                  		tmp = x_m;
                  	}
                  	return x_s * tmp;
                  }
                  
                  x\_m =     private
                  x\_s =     private
                  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_s, x_m, y, z, t)
                  use fmin_fmax_functions
                      real(8), intent (in) :: x_s
                      real(8), intent (in) :: x_m
                      real(8), intent (in) :: y
                      real(8), intent (in) :: z
                      real(8), intent (in) :: t
                      real(8) :: tmp
                      if (z <= (-1.15d-15)) then
                          tmp = x_m
                      else if (z <= 1080000000000.0d0) then
                          tmp = (y / t) * x_m
                      else
                          tmp = x_m
                      end if
                      code = x_s * tmp
                  end function
                  
                  x\_m = Math.abs(x);
                  x\_s = Math.copySign(1.0, x);
                  public static double code(double x_s, double x_m, double y, double z, double t) {
                  	double tmp;
                  	if (z <= -1.15e-15) {
                  		tmp = x_m;
                  	} else if (z <= 1080000000000.0) {
                  		tmp = (y / t) * x_m;
                  	} else {
                  		tmp = x_m;
                  	}
                  	return x_s * tmp;
                  }
                  
                  x\_m = math.fabs(x)
                  x\_s = math.copysign(1.0, x)
                  def code(x_s, x_m, y, z, t):
                  	tmp = 0
                  	if z <= -1.15e-15:
                  		tmp = x_m
                  	elif z <= 1080000000000.0:
                  		tmp = (y / t) * x_m
                  	else:
                  		tmp = x_m
                  	return x_s * tmp
                  
                  x\_m = abs(x)
                  x\_s = copysign(1.0, x)
                  function code(x_s, x_m, y, z, t)
                  	tmp = 0.0
                  	if (z <= -1.15e-15)
                  		tmp = x_m;
                  	elseif (z <= 1080000000000.0)
                  		tmp = Float64(Float64(y / t) * x_m);
                  	else
                  		tmp = x_m;
                  	end
                  	return Float64(x_s * tmp)
                  end
                  
                  x\_m = abs(x);
                  x\_s = sign(x) * abs(1.0);
                  function tmp_2 = code(x_s, x_m, y, z, t)
                  	tmp = 0.0;
                  	if (z <= -1.15e-15)
                  		tmp = x_m;
                  	elseif (z <= 1080000000000.0)
                  		tmp = (y / t) * x_m;
                  	else
                  		tmp = x_m;
                  	end
                  	tmp_2 = x_s * tmp;
                  end
                  
                  x\_m = N[Abs[x], $MachinePrecision]
                  x\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[x]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
                  code[x$95$s_, x$95$m_, y_, z_, t_] := N[(x$95$s * If[LessEqual[z, -1.15e-15], x$95$m, If[LessEqual[z, 1080000000000.0], N[(N[(y / t), $MachinePrecision] * x$95$m), $MachinePrecision], x$95$m]]), $MachinePrecision]
                  
                  \begin{array}{l}
                  x\_m = \left|x\right|
                  \\
                  x\_s = \mathsf{copysign}\left(1, x\right)
                  
                  \\
                  x\_s \cdot \begin{array}{l}
                  \mathbf{if}\;z \leq -1.15 \cdot 10^{-15}:\\
                  \;\;\;\;x\_m\\
                  
                  \mathbf{elif}\;z \leq 1080000000000:\\
                  \;\;\;\;\frac{y}{t} \cdot x\_m\\
                  
                  \mathbf{else}:\\
                  \;\;\;\;x\_m\\
                  
                  
                  \end{array}
                  \end{array}
                  
                  Derivation
                  1. Split input into 2 regimes
                  2. if z < -1.14999999999999995e-15 or 1.08e12 < z

                    1. Initial program 77.5%

                      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
                    2. Add Preprocessing
                    3. Taylor expanded in z around inf

                      \[\leadsto \color{blue}{x} \]
                    4. Step-by-step derivation
                      1. Applied rewrites59.7%

                        \[\leadsto \color{blue}{x} \]

                      if -1.14999999999999995e-15 < z < 1.08e12

                      1. Initial program 94.1%

                        \[\frac{x \cdot \left(y - z\right)}{t - z} \]
                      2. Add Preprocessing
                      3. Taylor expanded in y around inf

                        \[\leadsto \color{blue}{\frac{x \cdot y}{t - z}} \]
                      4. Step-by-step derivation
                        1. Applied rewrites80.9%

                          \[\leadsto \color{blue}{\frac{y}{t - z} \cdot x} \]
                        2. Taylor expanded in z around 0

                          \[\leadsto \frac{y}{t} \cdot x \]
                        3. Step-by-step derivation
                          1. Applied rewrites67.5%

                            \[\leadsto \frac{y}{t} \cdot x \]
                        4. Recombined 2 regimes into one program.
                        5. Add Preprocessing

                        Alternative 7: 60.1% accurate, 0.8× speedup?

                        \[\begin{array}{l} x\_m = \left|x\right| \\ x\_s = \mathsf{copysign}\left(1, x\right) \\ x\_s \cdot \begin{array}{l} \mathbf{if}\;z \leq -1.15 \cdot 10^{-15}:\\ \;\;\;\;x\_m\\ \mathbf{elif}\;z \leq 680000000000:\\ \;\;\;\;y \cdot \frac{x\_m}{t}\\ \mathbf{else}:\\ \;\;\;\;x\_m\\ \end{array} \end{array} \]
                        x\_m = (fabs.f64 x)
                        x\_s = (copysign.f64 #s(literal 1 binary64) x)
                        (FPCore (x_s x_m y z t)
                         :precision binary64
                         (*
                          x_s
                          (if (<= z -1.15e-15) x_m (if (<= z 680000000000.0) (* y (/ x_m t)) x_m))))
                        x\_m = fabs(x);
                        x\_s = copysign(1.0, x);
                        double code(double x_s, double x_m, double y, double z, double t) {
                        	double tmp;
                        	if (z <= -1.15e-15) {
                        		tmp = x_m;
                        	} else if (z <= 680000000000.0) {
                        		tmp = y * (x_m / t);
                        	} else {
                        		tmp = x_m;
                        	}
                        	return x_s * tmp;
                        }
                        
                        x\_m =     private
                        x\_s =     private
                        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_s, x_m, y, z, t)
                        use fmin_fmax_functions
                            real(8), intent (in) :: x_s
                            real(8), intent (in) :: x_m
                            real(8), intent (in) :: y
                            real(8), intent (in) :: z
                            real(8), intent (in) :: t
                            real(8) :: tmp
                            if (z <= (-1.15d-15)) then
                                tmp = x_m
                            else if (z <= 680000000000.0d0) then
                                tmp = y * (x_m / t)
                            else
                                tmp = x_m
                            end if
                            code = x_s * tmp
                        end function
                        
                        x\_m = Math.abs(x);
                        x\_s = Math.copySign(1.0, x);
                        public static double code(double x_s, double x_m, double y, double z, double t) {
                        	double tmp;
                        	if (z <= -1.15e-15) {
                        		tmp = x_m;
                        	} else if (z <= 680000000000.0) {
                        		tmp = y * (x_m / t);
                        	} else {
                        		tmp = x_m;
                        	}
                        	return x_s * tmp;
                        }
                        
                        x\_m = math.fabs(x)
                        x\_s = math.copysign(1.0, x)
                        def code(x_s, x_m, y, z, t):
                        	tmp = 0
                        	if z <= -1.15e-15:
                        		tmp = x_m
                        	elif z <= 680000000000.0:
                        		tmp = y * (x_m / t)
                        	else:
                        		tmp = x_m
                        	return x_s * tmp
                        
                        x\_m = abs(x)
                        x\_s = copysign(1.0, x)
                        function code(x_s, x_m, y, z, t)
                        	tmp = 0.0
                        	if (z <= -1.15e-15)
                        		tmp = x_m;
                        	elseif (z <= 680000000000.0)
                        		tmp = Float64(y * Float64(x_m / t));
                        	else
                        		tmp = x_m;
                        	end
                        	return Float64(x_s * tmp)
                        end
                        
                        x\_m = abs(x);
                        x\_s = sign(x) * abs(1.0);
                        function tmp_2 = code(x_s, x_m, y, z, t)
                        	tmp = 0.0;
                        	if (z <= -1.15e-15)
                        		tmp = x_m;
                        	elseif (z <= 680000000000.0)
                        		tmp = y * (x_m / t);
                        	else
                        		tmp = x_m;
                        	end
                        	tmp_2 = x_s * tmp;
                        end
                        
                        x\_m = N[Abs[x], $MachinePrecision]
                        x\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[x]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
                        code[x$95$s_, x$95$m_, y_, z_, t_] := N[(x$95$s * If[LessEqual[z, -1.15e-15], x$95$m, If[LessEqual[z, 680000000000.0], N[(y * N[(x$95$m / t), $MachinePrecision]), $MachinePrecision], x$95$m]]), $MachinePrecision]
                        
                        \begin{array}{l}
                        x\_m = \left|x\right|
                        \\
                        x\_s = \mathsf{copysign}\left(1, x\right)
                        
                        \\
                        x\_s \cdot \begin{array}{l}
                        \mathbf{if}\;z \leq -1.15 \cdot 10^{-15}:\\
                        \;\;\;\;x\_m\\
                        
                        \mathbf{elif}\;z \leq 680000000000:\\
                        \;\;\;\;y \cdot \frac{x\_m}{t}\\
                        
                        \mathbf{else}:\\
                        \;\;\;\;x\_m\\
                        
                        
                        \end{array}
                        \end{array}
                        
                        Derivation
                        1. Split input into 2 regimes
                        2. if z < -1.14999999999999995e-15 or 6.8e11 < z

                          1. Initial program 77.5%

                            \[\frac{x \cdot \left(y - z\right)}{t - z} \]
                          2. Add Preprocessing
                          3. Taylor expanded in z around inf

                            \[\leadsto \color{blue}{x} \]
                          4. Step-by-step derivation
                            1. Applied rewrites59.7%

                              \[\leadsto \color{blue}{x} \]

                            if -1.14999999999999995e-15 < z < 6.8e11

                            1. Initial program 94.1%

                              \[\frac{x \cdot \left(y - z\right)}{t - z} \]
                            2. Add Preprocessing
                            3. Taylor expanded in y around inf

                              \[\leadsto \color{blue}{\frac{x \cdot y}{t - z}} \]
                            4. Step-by-step derivation
                              1. Applied rewrites80.9%

                                \[\leadsto \color{blue}{\frac{y}{t - z} \cdot x} \]
                              2. Taylor expanded in z around 0

                                \[\leadsto \frac{y}{t} \cdot x \]
                              3. Step-by-step derivation
                                1. Applied rewrites67.5%

                                  \[\leadsto \frac{y}{t} \cdot x \]
                                2. Step-by-step derivation
                                  1. Applied rewrites64.8%

                                    \[\leadsto y \cdot \color{blue}{\frac{x}{t}} \]
                                3. Recombined 2 regimes into one program.
                                4. Add Preprocessing

                                Alternative 8: 35.4% accurate, 23.0× speedup?

                                \[\begin{array}{l} x\_m = \left|x\right| \\ x\_s = \mathsf{copysign}\left(1, x\right) \\ x\_s \cdot x\_m \end{array} \]
                                x\_m = (fabs.f64 x)
                                x\_s = (copysign.f64 #s(literal 1 binary64) x)
                                (FPCore (x_s x_m y z t) :precision binary64 (* x_s x_m))
                                x\_m = fabs(x);
                                x\_s = copysign(1.0, x);
                                double code(double x_s, double x_m, double y, double z, double t) {
                                	return x_s * x_m;
                                }
                                
                                x\_m =     private
                                x\_s =     private
                                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_s, x_m, y, z, t)
                                use fmin_fmax_functions
                                    real(8), intent (in) :: x_s
                                    real(8), intent (in) :: x_m
                                    real(8), intent (in) :: y
                                    real(8), intent (in) :: z
                                    real(8), intent (in) :: t
                                    code = x_s * x_m
                                end function
                                
                                x\_m = Math.abs(x);
                                x\_s = Math.copySign(1.0, x);
                                public static double code(double x_s, double x_m, double y, double z, double t) {
                                	return x_s * x_m;
                                }
                                
                                x\_m = math.fabs(x)
                                x\_s = math.copysign(1.0, x)
                                def code(x_s, x_m, y, z, t):
                                	return x_s * x_m
                                
                                x\_m = abs(x)
                                x\_s = copysign(1.0, x)
                                function code(x_s, x_m, y, z, t)
                                	return Float64(x_s * x_m)
                                end
                                
                                x\_m = abs(x);
                                x\_s = sign(x) * abs(1.0);
                                function tmp = code(x_s, x_m, y, z, t)
                                	tmp = x_s * x_m;
                                end
                                
                                x\_m = N[Abs[x], $MachinePrecision]
                                x\_s = N[With[{TMP1 = Abs[1.0], TMP2 = Sign[x]}, TMP1 * If[TMP2 == 0, 1, TMP2]], $MachinePrecision]
                                code[x$95$s_, x$95$m_, y_, z_, t_] := N[(x$95$s * x$95$m), $MachinePrecision]
                                
                                \begin{array}{l}
                                x\_m = \left|x\right|
                                \\
                                x\_s = \mathsf{copysign}\left(1, x\right)
                                
                                \\
                                x\_s \cdot x\_m
                                \end{array}
                                
                                Derivation
                                1. Initial program 85.6%

                                  \[\frac{x \cdot \left(y - z\right)}{t - z} \]
                                2. Add Preprocessing
                                3. Taylor expanded in z around inf

                                  \[\leadsto \color{blue}{x} \]
                                4. Step-by-step derivation
                                  1. Applied rewrites36.5%

                                    \[\leadsto \color{blue}{x} \]
                                  2. Add Preprocessing

                                  Developer Target 1: 97.1% accurate, 0.8× speedup?

                                  \[\begin{array}{l} \\ \frac{x}{\frac{t - z}{y - z}} \end{array} \]
                                  (FPCore (x y z t) :precision binary64 (/ x (/ (- t z) (- y z))))
                                  double code(double x, double y, double z, double t) {
                                  	return x / ((t - z) / (y - 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)
                                  use fmin_fmax_functions
                                      real(8), intent (in) :: x
                                      real(8), intent (in) :: y
                                      real(8), intent (in) :: z
                                      real(8), intent (in) :: t
                                      code = x / ((t - z) / (y - z))
                                  end function
                                  
                                  public static double code(double x, double y, double z, double t) {
                                  	return x / ((t - z) / (y - z));
                                  }
                                  
                                  def code(x, y, z, t):
                                  	return x / ((t - z) / (y - z))
                                  
                                  function code(x, y, z, t)
                                  	return Float64(x / Float64(Float64(t - z) / Float64(y - z)))
                                  end
                                  
                                  function tmp = code(x, y, z, t)
                                  	tmp = x / ((t - z) / (y - z));
                                  end
                                  
                                  code[x_, y_, z_, t_] := N[(x / N[(N[(t - z), $MachinePrecision] / N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
                                  
                                  \begin{array}{l}
                                  
                                  \\
                                  \frac{x}{\frac{t - z}{y - z}}
                                  \end{array}
                                  

                                  Reproduce

                                  ?
                                  herbie shell --seed 2025018 
                                  (FPCore (x y z t)
                                    :name "Graphics.Rendering.Chart.Plot.AreaSpots:renderAreaSpots4D from Chart-1.5.3"
                                    :precision binary64
                                  
                                    :alt
                                    (! :herbie-platform default (/ x (/ (- t z) (- y z))))
                                  
                                    (/ (* x (- y z)) (- t z)))