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

Percentage Accurate: 83.9% → 96.9%
Time: 9.0s
Alternatives: 10
Speedup: 1.0×

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);
}
real(8) function code(x, y, z, t)
    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 10 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: 83.9% 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);
}
real(8) function code(x, y, z, t)
    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: 96.9% accurate, 1.0× speedup?

\[\begin{array}{l} \\ x \cdot \frac{y - z}{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));
}
real(8) function code(x, y, z, t)
    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(x * Float64(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[(x * N[(N[(y - z), $MachinePrecision] / N[(t - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
x \cdot \frac{y - z}{t - z}
\end{array}
Derivation
  1. Initial program 85.9%

    \[\frac{x \cdot \left(y - z\right)}{t - z} \]
  2. Step-by-step derivation
    1. associate-*r/97.3%

      \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
  3. Simplified97.3%

    \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
  4. Final simplification97.3%

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

Alternative 2: 74.4% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -2.8 \cdot 10^{+56}:\\ \;\;\;\;x \cdot \frac{z}{z - t}\\ \mathbf{elif}\;z \leq 1.4 \cdot 10^{-229}:\\ \;\;\;\;\frac{x}{\frac{t - z}{y}}\\ \mathbf{elif}\;z \leq 1.7 \cdot 10^{-113}:\\ \;\;\;\;\left(y - z\right) \cdot \frac{x}{t}\\ \mathbf{elif}\;z \leq 4.9 \cdot 10^{+72}:\\ \;\;\;\;x \cdot \left(\frac{y}{t} - \frac{z}{t}\right)\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(1 - \frac{y}{z}\right)\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (if (<= z -2.8e+56)
   (* x (/ z (- z t)))
   (if (<= z 1.4e-229)
     (/ x (/ (- t z) y))
     (if (<= z 1.7e-113)
       (* (- y z) (/ x t))
       (if (<= z 4.9e+72) (* x (- (/ y t) (/ z t))) (* x (- 1.0 (/ y z))))))))
double code(double x, double y, double z, double t) {
	double tmp;
	if (z <= -2.8e+56) {
		tmp = x * (z / (z - t));
	} else if (z <= 1.4e-229) {
		tmp = x / ((t - z) / y);
	} else if (z <= 1.7e-113) {
		tmp = (y - z) * (x / t);
	} else if (z <= 4.9e+72) {
		tmp = x * ((y / t) - (z / t));
	} else {
		tmp = x * (1.0 - (y / z));
	}
	return tmp;
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: tmp
    if (z <= (-2.8d+56)) then
        tmp = x * (z / (z - t))
    else if (z <= 1.4d-229) then
        tmp = x / ((t - z) / y)
    else if (z <= 1.7d-113) then
        tmp = (y - z) * (x / t)
    else if (z <= 4.9d+72) then
        tmp = x * ((y / t) - (z / t))
    else
        tmp = x * (1.0d0 - (y / z))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double tmp;
	if (z <= -2.8e+56) {
		tmp = x * (z / (z - t));
	} else if (z <= 1.4e-229) {
		tmp = x / ((t - z) / y);
	} else if (z <= 1.7e-113) {
		tmp = (y - z) * (x / t);
	} else if (z <= 4.9e+72) {
		tmp = x * ((y / t) - (z / t));
	} else {
		tmp = x * (1.0 - (y / z));
	}
	return tmp;
}
def code(x, y, z, t):
	tmp = 0
	if z <= -2.8e+56:
		tmp = x * (z / (z - t))
	elif z <= 1.4e-229:
		tmp = x / ((t - z) / y)
	elif z <= 1.7e-113:
		tmp = (y - z) * (x / t)
	elif z <= 4.9e+72:
		tmp = x * ((y / t) - (z / t))
	else:
		tmp = x * (1.0 - (y / z))
	return tmp
function code(x, y, z, t)
	tmp = 0.0
	if (z <= -2.8e+56)
		tmp = Float64(x * Float64(z / Float64(z - t)));
	elseif (z <= 1.4e-229)
		tmp = Float64(x / Float64(Float64(t - z) / y));
	elseif (z <= 1.7e-113)
		tmp = Float64(Float64(y - z) * Float64(x / t));
	elseif (z <= 4.9e+72)
		tmp = Float64(x * Float64(Float64(y / t) - Float64(z / t)));
	else
		tmp = Float64(x * Float64(1.0 - Float64(y / z)));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if (z <= -2.8e+56)
		tmp = x * (z / (z - t));
	elseif (z <= 1.4e-229)
		tmp = x / ((t - z) / y);
	elseif (z <= 1.7e-113)
		tmp = (y - z) * (x / t);
	elseif (z <= 4.9e+72)
		tmp = x * ((y / t) - (z / t));
	else
		tmp = x * (1.0 - (y / z));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := If[LessEqual[z, -2.8e+56], N[(x * N[(z / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.4e-229], N[(x / N[(N[(t - z), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.7e-113], N[(N[(y - z), $MachinePrecision] * N[(x / t), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 4.9e+72], N[(x * N[(N[(y / t), $MachinePrecision] - N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(1.0 - N[(y / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.8 \cdot 10^{+56}:\\
\;\;\;\;x \cdot \frac{z}{z - t}\\

\mathbf{elif}\;z \leq 1.4 \cdot 10^{-229}:\\
\;\;\;\;\frac{x}{\frac{t - z}{y}}\\

\mathbf{elif}\;z \leq 1.7 \cdot 10^{-113}:\\
\;\;\;\;\left(y - z\right) \cdot \frac{x}{t}\\

\mathbf{elif}\;z \leq 4.9 \cdot 10^{+72}:\\
\;\;\;\;x \cdot \left(\frac{y}{t} - \frac{z}{t}\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if z < -2.80000000000000008e56

    1. Initial program 75.0%

      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
    2. Step-by-step derivation
      1. associate-*r/99.9%

        \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    3. Simplified99.9%

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

      \[\leadsto x \cdot \color{blue}{\left(-1 \cdot \frac{z}{t - z}\right)} \]
    5. Step-by-step derivation
      1. neg-mul-189.6%

        \[\leadsto x \cdot \color{blue}{\left(-\frac{z}{t - z}\right)} \]
      2. distribute-neg-frac89.6%

        \[\leadsto x \cdot \color{blue}{\frac{-z}{t - z}} \]
    6. Simplified89.6%

      \[\leadsto x \cdot \color{blue}{\frac{-z}{t - z}} \]
    7. Step-by-step derivation
      1. frac-2neg89.6%

        \[\leadsto x \cdot \color{blue}{\frac{-\left(-z\right)}{-\left(t - z\right)}} \]
      2. div-inv89.6%

        \[\leadsto x \cdot \color{blue}{\left(\left(-\left(-z\right)\right) \cdot \frac{1}{-\left(t - z\right)}\right)} \]
      3. remove-double-neg89.6%

        \[\leadsto x \cdot \left(\color{blue}{z} \cdot \frac{1}{-\left(t - z\right)}\right) \]
      4. sub-neg89.6%

        \[\leadsto x \cdot \left(z \cdot \frac{1}{-\color{blue}{\left(t + \left(-z\right)\right)}}\right) \]
      5. distribute-neg-in89.6%

        \[\leadsto x \cdot \left(z \cdot \frac{1}{\color{blue}{\left(-t\right) + \left(-\left(-z\right)\right)}}\right) \]
      6. remove-double-neg89.6%

        \[\leadsto x \cdot \left(z \cdot \frac{1}{\left(-t\right) + \color{blue}{z}}\right) \]
    8. Applied egg-rr89.6%

      \[\leadsto x \cdot \color{blue}{\left(z \cdot \frac{1}{\left(-t\right) + z}\right)} \]
    9. Step-by-step derivation
      1. associate-*r/89.6%

        \[\leadsto x \cdot \color{blue}{\frac{z \cdot 1}{\left(-t\right) + z}} \]
      2. *-rgt-identity89.6%

        \[\leadsto x \cdot \frac{\color{blue}{z}}{\left(-t\right) + z} \]
      3. +-commutative89.6%

        \[\leadsto x \cdot \frac{z}{\color{blue}{z + \left(-t\right)}} \]
      4. unsub-neg89.6%

        \[\leadsto x \cdot \frac{z}{\color{blue}{z - t}} \]
    10. Simplified89.6%

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

    if -2.80000000000000008e56 < z < 1.39999999999999995e-229

    1. Initial program 93.0%

      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
    2. Step-by-step derivation
      1. associate-/l*97.4%

        \[\leadsto \color{blue}{\frac{x}{\frac{t - z}{y - z}}} \]
    3. Simplified97.4%

      \[\leadsto \color{blue}{\frac{x}{\frac{t - z}{y - z}}} \]
    4. Taylor expanded in y around inf 81.9%

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

    if 1.39999999999999995e-229 < z < 1.7000000000000001e-113

    1. Initial program 99.8%

      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
    2. Step-by-step derivation
      1. associate-*l/93.4%

        \[\leadsto \color{blue}{\frac{x}{t - z} \cdot \left(y - z\right)} \]
    3. Simplified93.4%

      \[\leadsto \color{blue}{\frac{x}{t - z} \cdot \left(y - z\right)} \]
    4. Taylor expanded in t around inf 87.1%

      \[\leadsto \color{blue}{\frac{x}{t}} \cdot \left(y - z\right) \]

    if 1.7000000000000001e-113 < z < 4.90000000000000006e72

    1. Initial program 88.7%

      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
    2. Step-by-step derivation
      1. associate-*r/97.7%

        \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    3. Simplified97.7%

      \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    4. Taylor expanded in t around inf 72.9%

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

      \[\leadsto x \cdot \color{blue}{\left(-1 \cdot \frac{z}{t} + \frac{y}{t}\right)} \]
    6. Step-by-step derivation
      1. +-commutative72.9%

        \[\leadsto x \cdot \color{blue}{\left(\frac{y}{t} + -1 \cdot \frac{z}{t}\right)} \]
      2. neg-mul-172.9%

        \[\leadsto x \cdot \left(\frac{y}{t} + \color{blue}{\left(-\frac{z}{t}\right)}\right) \]
      3. sub-neg72.9%

        \[\leadsto x \cdot \color{blue}{\left(\frac{y}{t} - \frac{z}{t}\right)} \]
    7. Simplified72.9%

      \[\leadsto x \cdot \color{blue}{\left(\frac{y}{t} - \frac{z}{t}\right)} \]

    if 4.90000000000000006e72 < z

    1. Initial program 75.2%

      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
    2. Step-by-step derivation
      1. associate-*r/99.9%

        \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    3. Simplified99.9%

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

        \[\leadsto x \cdot \color{blue}{\left(\frac{y}{t - z} - \frac{z}{t - z}\right)} \]
    5. Applied egg-rr99.9%

      \[\leadsto x \cdot \color{blue}{\left(\frac{y}{t - z} - \frac{z}{t - z}\right)} \]
    6. Taylor expanded in t around 0 83.7%

      \[\leadsto \color{blue}{x \cdot \left(1 + -1 \cdot \frac{y}{z}\right)} \]
    7. Step-by-step derivation
      1. mul-1-neg83.7%

        \[\leadsto x \cdot \left(1 + \color{blue}{\left(-\frac{y}{z}\right)}\right) \]
      2. unsub-neg83.7%

        \[\leadsto x \cdot \color{blue}{\left(1 - \frac{y}{z}\right)} \]
    8. Simplified83.7%

      \[\leadsto \color{blue}{x \cdot \left(1 - \frac{y}{z}\right)} \]
  3. Recombined 5 regimes into one program.
  4. Final simplification83.0%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -2.8 \cdot 10^{+56}:\\ \;\;\;\;x \cdot \frac{z}{z - t}\\ \mathbf{elif}\;z \leq 1.4 \cdot 10^{-229}:\\ \;\;\;\;\frac{x}{\frac{t - z}{y}}\\ \mathbf{elif}\;z \leq 1.7 \cdot 10^{-113}:\\ \;\;\;\;\left(y - z\right) \cdot \frac{x}{t}\\ \mathbf{elif}\;z \leq 4.9 \cdot 10^{+72}:\\ \;\;\;\;x \cdot \left(\frac{y}{t} - \frac{z}{t}\right)\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(1 - \frac{y}{z}\right)\\ \end{array} \]

Alternative 3: 74.3% accurate, 0.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -1.62 \cdot 10^{+59}:\\ \;\;\;\;x \cdot \frac{z}{z - t}\\ \mathbf{elif}\;z \leq 4.7 \cdot 10^{-228}:\\ \;\;\;\;\frac{x}{\frac{t - z}{y}}\\ \mathbf{elif}\;z \leq 1.5 \cdot 10^{-113}:\\ \;\;\;\;\left(y - z\right) \cdot \frac{x}{t}\\ \mathbf{elif}\;z \leq 4.5 \cdot 10^{+71}:\\ \;\;\;\;x \cdot \frac{y - z}{t}\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(1 - \frac{y}{z}\right)\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (if (<= z -1.62e+59)
   (* x (/ z (- z t)))
   (if (<= z 4.7e-228)
     (/ x (/ (- t z) y))
     (if (<= z 1.5e-113)
       (* (- y z) (/ x t))
       (if (<= z 4.5e+71) (* x (/ (- y z) t)) (* x (- 1.0 (/ y z))))))))
double code(double x, double y, double z, double t) {
	double tmp;
	if (z <= -1.62e+59) {
		tmp = x * (z / (z - t));
	} else if (z <= 4.7e-228) {
		tmp = x / ((t - z) / y);
	} else if (z <= 1.5e-113) {
		tmp = (y - z) * (x / t);
	} else if (z <= 4.5e+71) {
		tmp = x * ((y - z) / t);
	} else {
		tmp = x * (1.0 - (y / z));
	}
	return tmp;
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: tmp
    if (z <= (-1.62d+59)) then
        tmp = x * (z / (z - t))
    else if (z <= 4.7d-228) then
        tmp = x / ((t - z) / y)
    else if (z <= 1.5d-113) then
        tmp = (y - z) * (x / t)
    else if (z <= 4.5d+71) then
        tmp = x * ((y - z) / t)
    else
        tmp = x * (1.0d0 - (y / z))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double tmp;
	if (z <= -1.62e+59) {
		tmp = x * (z / (z - t));
	} else if (z <= 4.7e-228) {
		tmp = x / ((t - z) / y);
	} else if (z <= 1.5e-113) {
		tmp = (y - z) * (x / t);
	} else if (z <= 4.5e+71) {
		tmp = x * ((y - z) / t);
	} else {
		tmp = x * (1.0 - (y / z));
	}
	return tmp;
}
def code(x, y, z, t):
	tmp = 0
	if z <= -1.62e+59:
		tmp = x * (z / (z - t))
	elif z <= 4.7e-228:
		tmp = x / ((t - z) / y)
	elif z <= 1.5e-113:
		tmp = (y - z) * (x / t)
	elif z <= 4.5e+71:
		tmp = x * ((y - z) / t)
	else:
		tmp = x * (1.0 - (y / z))
	return tmp
function code(x, y, z, t)
	tmp = 0.0
	if (z <= -1.62e+59)
		tmp = Float64(x * Float64(z / Float64(z - t)));
	elseif (z <= 4.7e-228)
		tmp = Float64(x / Float64(Float64(t - z) / y));
	elseif (z <= 1.5e-113)
		tmp = Float64(Float64(y - z) * Float64(x / t));
	elseif (z <= 4.5e+71)
		tmp = Float64(x * Float64(Float64(y - z) / t));
	else
		tmp = Float64(x * Float64(1.0 - Float64(y / z)));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if (z <= -1.62e+59)
		tmp = x * (z / (z - t));
	elseif (z <= 4.7e-228)
		tmp = x / ((t - z) / y);
	elseif (z <= 1.5e-113)
		tmp = (y - z) * (x / t);
	elseif (z <= 4.5e+71)
		tmp = x * ((y - z) / t);
	else
		tmp = x * (1.0 - (y / z));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := If[LessEqual[z, -1.62e+59], N[(x * N[(z / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 4.7e-228], N[(x / N[(N[(t - z), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.5e-113], N[(N[(y - z), $MachinePrecision] * N[(x / t), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 4.5e+71], N[(x * N[(N[(y - z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision], N[(x * N[(1.0 - N[(y / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.62 \cdot 10^{+59}:\\
\;\;\;\;x \cdot \frac{z}{z - t}\\

\mathbf{elif}\;z \leq 4.7 \cdot 10^{-228}:\\
\;\;\;\;\frac{x}{\frac{t - z}{y}}\\

\mathbf{elif}\;z \leq 1.5 \cdot 10^{-113}:\\
\;\;\;\;\left(y - z\right) \cdot \frac{x}{t}\\

\mathbf{elif}\;z \leq 4.5 \cdot 10^{+71}:\\
\;\;\;\;x \cdot \frac{y - z}{t}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if z < -1.6200000000000001e59

    1. Initial program 75.0%

      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
    2. Step-by-step derivation
      1. associate-*r/99.9%

        \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    3. Simplified99.9%

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

      \[\leadsto x \cdot \color{blue}{\left(-1 \cdot \frac{z}{t - z}\right)} \]
    5. Step-by-step derivation
      1. neg-mul-189.6%

        \[\leadsto x \cdot \color{blue}{\left(-\frac{z}{t - z}\right)} \]
      2. distribute-neg-frac89.6%

        \[\leadsto x \cdot \color{blue}{\frac{-z}{t - z}} \]
    6. Simplified89.6%

      \[\leadsto x \cdot \color{blue}{\frac{-z}{t - z}} \]
    7. Step-by-step derivation
      1. frac-2neg89.6%

        \[\leadsto x \cdot \color{blue}{\frac{-\left(-z\right)}{-\left(t - z\right)}} \]
      2. div-inv89.6%

        \[\leadsto x \cdot \color{blue}{\left(\left(-\left(-z\right)\right) \cdot \frac{1}{-\left(t - z\right)}\right)} \]
      3. remove-double-neg89.6%

        \[\leadsto x \cdot \left(\color{blue}{z} \cdot \frac{1}{-\left(t - z\right)}\right) \]
      4. sub-neg89.6%

        \[\leadsto x \cdot \left(z \cdot \frac{1}{-\color{blue}{\left(t + \left(-z\right)\right)}}\right) \]
      5. distribute-neg-in89.6%

        \[\leadsto x \cdot \left(z \cdot \frac{1}{\color{blue}{\left(-t\right) + \left(-\left(-z\right)\right)}}\right) \]
      6. remove-double-neg89.6%

        \[\leadsto x \cdot \left(z \cdot \frac{1}{\left(-t\right) + \color{blue}{z}}\right) \]
    8. Applied egg-rr89.6%

      \[\leadsto x \cdot \color{blue}{\left(z \cdot \frac{1}{\left(-t\right) + z}\right)} \]
    9. Step-by-step derivation
      1. associate-*r/89.6%

        \[\leadsto x \cdot \color{blue}{\frac{z \cdot 1}{\left(-t\right) + z}} \]
      2. *-rgt-identity89.6%

        \[\leadsto x \cdot \frac{\color{blue}{z}}{\left(-t\right) + z} \]
      3. +-commutative89.6%

        \[\leadsto x \cdot \frac{z}{\color{blue}{z + \left(-t\right)}} \]
      4. unsub-neg89.6%

        \[\leadsto x \cdot \frac{z}{\color{blue}{z - t}} \]
    10. Simplified89.6%

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

    if -1.6200000000000001e59 < z < 4.7000000000000002e-228

    1. Initial program 93.0%

      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
    2. Step-by-step derivation
      1. associate-/l*97.4%

        \[\leadsto \color{blue}{\frac{x}{\frac{t - z}{y - z}}} \]
    3. Simplified97.4%

      \[\leadsto \color{blue}{\frac{x}{\frac{t - z}{y - z}}} \]
    4. Taylor expanded in y around inf 81.9%

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

    if 4.7000000000000002e-228 < z < 1.5e-113

    1. Initial program 99.8%

      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
    2. Step-by-step derivation
      1. associate-*l/93.4%

        \[\leadsto \color{blue}{\frac{x}{t - z} \cdot \left(y - z\right)} \]
    3. Simplified93.4%

      \[\leadsto \color{blue}{\frac{x}{t - z} \cdot \left(y - z\right)} \]
    4. Taylor expanded in t around inf 87.1%

      \[\leadsto \color{blue}{\frac{x}{t}} \cdot \left(y - z\right) \]

    if 1.5e-113 < z < 4.50000000000000043e71

    1. Initial program 88.7%

      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
    2. Step-by-step derivation
      1. associate-*r/97.7%

        \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    3. Simplified97.7%

      \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    4. Taylor expanded in t around inf 72.9%

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

    if 4.50000000000000043e71 < z

    1. Initial program 75.2%

      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
    2. Step-by-step derivation
      1. associate-*r/99.9%

        \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    3. Simplified99.9%

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

        \[\leadsto x \cdot \color{blue}{\left(\frac{y}{t - z} - \frac{z}{t - z}\right)} \]
    5. Applied egg-rr99.9%

      \[\leadsto x \cdot \color{blue}{\left(\frac{y}{t - z} - \frac{z}{t - z}\right)} \]
    6. Taylor expanded in t around 0 83.7%

      \[\leadsto \color{blue}{x \cdot \left(1 + -1 \cdot \frac{y}{z}\right)} \]
    7. Step-by-step derivation
      1. mul-1-neg83.7%

        \[\leadsto x \cdot \left(1 + \color{blue}{\left(-\frac{y}{z}\right)}\right) \]
      2. unsub-neg83.7%

        \[\leadsto x \cdot \color{blue}{\left(1 - \frac{y}{z}\right)} \]
    8. Simplified83.7%

      \[\leadsto \color{blue}{x \cdot \left(1 - \frac{y}{z}\right)} \]
  3. Recombined 5 regimes into one program.
  4. Final simplification83.0%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.62 \cdot 10^{+59}:\\ \;\;\;\;x \cdot \frac{z}{z - t}\\ \mathbf{elif}\;z \leq 4.7 \cdot 10^{-228}:\\ \;\;\;\;\frac{x}{\frac{t - z}{y}}\\ \mathbf{elif}\;z \leq 1.5 \cdot 10^{-113}:\\ \;\;\;\;\left(y - z\right) \cdot \frac{x}{t}\\ \mathbf{elif}\;z \leq 4.5 \cdot 10^{+71}:\\ \;\;\;\;x \cdot \frac{y - z}{t}\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(1 - \frac{y}{z}\right)\\ \end{array} \]

Alternative 4: 60.4% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -9.5 \cdot 10^{+83}:\\ \;\;\;\;x\\ \mathbf{elif}\;z \leq -4.6 \cdot 10^{-8}:\\ \;\;\;\;x \cdot \frac{-z}{t}\\ \mathbf{elif}\;z \leq 2.05 \cdot 10^{+71}:\\ \;\;\;\;x \cdot \frac{y}{t}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (if (<= z -9.5e+83)
   x
   (if (<= z -4.6e-8) (* x (/ (- z) t)) (if (<= z 2.05e+71) (* x (/ y t)) x))))
double code(double x, double y, double z, double t) {
	double tmp;
	if (z <= -9.5e+83) {
		tmp = x;
	} else if (z <= -4.6e-8) {
		tmp = x * (-z / t);
	} else if (z <= 2.05e+71) {
		tmp = x * (y / t);
	} else {
		tmp = x;
	}
	return tmp;
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: tmp
    if (z <= (-9.5d+83)) then
        tmp = x
    else if (z <= (-4.6d-8)) then
        tmp = x * (-z / t)
    else if (z <= 2.05d+71) then
        tmp = x * (y / t)
    else
        tmp = x
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double tmp;
	if (z <= -9.5e+83) {
		tmp = x;
	} else if (z <= -4.6e-8) {
		tmp = x * (-z / t);
	} else if (z <= 2.05e+71) {
		tmp = x * (y / t);
	} else {
		tmp = x;
	}
	return tmp;
}
def code(x, y, z, t):
	tmp = 0
	if z <= -9.5e+83:
		tmp = x
	elif z <= -4.6e-8:
		tmp = x * (-z / t)
	elif z <= 2.05e+71:
		tmp = x * (y / t)
	else:
		tmp = x
	return tmp
function code(x, y, z, t)
	tmp = 0.0
	if (z <= -9.5e+83)
		tmp = x;
	elseif (z <= -4.6e-8)
		tmp = Float64(x * Float64(Float64(-z) / t));
	elseif (z <= 2.05e+71)
		tmp = Float64(x * Float64(y / t));
	else
		tmp = x;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if (z <= -9.5e+83)
		tmp = x;
	elseif (z <= -4.6e-8)
		tmp = x * (-z / t);
	elseif (z <= 2.05e+71)
		tmp = x * (y / t);
	else
		tmp = x;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := If[LessEqual[z, -9.5e+83], x, If[LessEqual[z, -4.6e-8], N[(x * N[((-z) / t), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2.05e+71], N[(x * N[(y / t), $MachinePrecision]), $MachinePrecision], x]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -9.5 \cdot 10^{+83}:\\
\;\;\;\;x\\

\mathbf{elif}\;z \leq -4.6 \cdot 10^{-8}:\\
\;\;\;\;x \cdot \frac{-z}{t}\\

\mathbf{elif}\;z \leq 2.05 \cdot 10^{+71}:\\
\;\;\;\;x \cdot \frac{y}{t}\\

\mathbf{else}:\\
\;\;\;\;x\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -9.5000000000000002e83 or 2.0500000000000001e71 < z

    1. Initial program 73.9%

      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
    2. Step-by-step derivation
      1. associate-*r/99.9%

        \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    3. Simplified99.9%

      \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    4. Taylor expanded in z around inf 75.3%

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

    if -9.5000000000000002e83 < z < -4.6000000000000002e-8

    1. Initial program 90.0%

      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
    2. Step-by-step derivation
      1. associate-*r/99.5%

        \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    3. Simplified99.5%

      \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    4. Taylor expanded in t around inf 60.3%

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

      \[\leadsto x \cdot \color{blue}{\left(-1 \cdot \frac{z}{t}\right)} \]
    6. Step-by-step derivation
      1. neg-mul-147.4%

        \[\leadsto x \cdot \color{blue}{\left(-\frac{z}{t}\right)} \]
      2. distribute-neg-frac47.4%

        \[\leadsto x \cdot \color{blue}{\frac{-z}{t}} \]
    7. Simplified47.4%

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

    if -4.6000000000000002e-8 < z < 2.0500000000000001e71

    1. Initial program 93.8%

      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
    2. Step-by-step derivation
      1. associate-*r/95.1%

        \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    3. Simplified95.1%

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

      \[\leadsto x \cdot \color{blue}{\frac{y}{t}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification68.5%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -9.5 \cdot 10^{+83}:\\ \;\;\;\;x\\ \mathbf{elif}\;z \leq -4.6 \cdot 10^{-8}:\\ \;\;\;\;x \cdot \frac{-z}{t}\\ \mathbf{elif}\;z \leq 2.05 \cdot 10^{+71}:\\ \;\;\;\;x \cdot \frac{y}{t}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]

Alternative 5: 60.1% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -1.05 \cdot 10^{+101}:\\ \;\;\;\;x\\ \mathbf{elif}\;z \leq -1.35:\\ \;\;\;\;\frac{-x}{\frac{t}{z}}\\ \mathbf{elif}\;z \leq 1.6 \cdot 10^{+72}:\\ \;\;\;\;x \cdot \frac{y}{t}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (if (<= z -1.05e+101)
   x
   (if (<= z -1.35) (/ (- x) (/ t z)) (if (<= z 1.6e+72) (* x (/ y t)) x))))
double code(double x, double y, double z, double t) {
	double tmp;
	if (z <= -1.05e+101) {
		tmp = x;
	} else if (z <= -1.35) {
		tmp = -x / (t / z);
	} else if (z <= 1.6e+72) {
		tmp = x * (y / t);
	} else {
		tmp = x;
	}
	return tmp;
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: tmp
    if (z <= (-1.05d+101)) then
        tmp = x
    else if (z <= (-1.35d0)) then
        tmp = -x / (t / z)
    else if (z <= 1.6d+72) then
        tmp = x * (y / t)
    else
        tmp = x
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double tmp;
	if (z <= -1.05e+101) {
		tmp = x;
	} else if (z <= -1.35) {
		tmp = -x / (t / z);
	} else if (z <= 1.6e+72) {
		tmp = x * (y / t);
	} else {
		tmp = x;
	}
	return tmp;
}
def code(x, y, z, t):
	tmp = 0
	if z <= -1.05e+101:
		tmp = x
	elif z <= -1.35:
		tmp = -x / (t / z)
	elif z <= 1.6e+72:
		tmp = x * (y / t)
	else:
		tmp = x
	return tmp
function code(x, y, z, t)
	tmp = 0.0
	if (z <= -1.05e+101)
		tmp = x;
	elseif (z <= -1.35)
		tmp = Float64(Float64(-x) / Float64(t / z));
	elseif (z <= 1.6e+72)
		tmp = Float64(x * Float64(y / t));
	else
		tmp = x;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if (z <= -1.05e+101)
		tmp = x;
	elseif (z <= -1.35)
		tmp = -x / (t / z);
	elseif (z <= 1.6e+72)
		tmp = x * (y / t);
	else
		tmp = x;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := If[LessEqual[z, -1.05e+101], x, If[LessEqual[z, -1.35], N[((-x) / N[(t / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.6e+72], N[(x * N[(y / t), $MachinePrecision]), $MachinePrecision], x]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.05 \cdot 10^{+101}:\\
\;\;\;\;x\\

\mathbf{elif}\;z \leq -1.35:\\
\;\;\;\;\frac{-x}{\frac{t}{z}}\\

\mathbf{elif}\;z \leq 1.6 \cdot 10^{+72}:\\
\;\;\;\;x \cdot \frac{y}{t}\\

\mathbf{else}:\\
\;\;\;\;x\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -1.05e101 or 1.6000000000000001e72 < z

    1. Initial program 73.3%

      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
    2. Step-by-step derivation
      1. associate-*r/99.9%

        \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    3. Simplified99.9%

      \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    4. Taylor expanded in z around inf 75.8%

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

    if -1.05e101 < z < -1.3500000000000001

    1. Initial program 90.9%

      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
    2. Step-by-step derivation
      1. associate-*r/99.5%

        \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    3. Simplified99.5%

      \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    4. Taylor expanded in t around inf 59.5%

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

      \[\leadsto \color{blue}{-1 \cdot \frac{x \cdot z}{t}} \]
    6. Step-by-step derivation
      1. mul-1-neg47.9%

        \[\leadsto \color{blue}{-\frac{x \cdot z}{t}} \]
      2. associate-/l*48.0%

        \[\leadsto -\color{blue}{\frac{x}{\frac{t}{z}}} \]
      3. distribute-neg-frac48.0%

        \[\leadsto \color{blue}{\frac{-x}{\frac{t}{z}}} \]
    7. Simplified48.0%

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

    if -1.3500000000000001 < z < 1.6000000000000001e72

    1. Initial program 93.8%

      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
    2. Step-by-step derivation
      1. associate-*r/95.1%

        \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    3. Simplified95.1%

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

      \[\leadsto x \cdot \color{blue}{\frac{y}{t}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification68.5%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.05 \cdot 10^{+101}:\\ \;\;\;\;x\\ \mathbf{elif}\;z \leq -1.35:\\ \;\;\;\;\frac{-x}{\frac{t}{z}}\\ \mathbf{elif}\;z \leq 1.6 \cdot 10^{+72}:\\ \;\;\;\;x \cdot \frac{y}{t}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]

Alternative 6: 69.6% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -9 \cdot 10^{-21} \lor \neg \left(z \leq 5.5 \cdot 10^{+32}\right):\\ \;\;\;\;x \cdot \left(1 - \frac{y}{z}\right)\\ \mathbf{else}:\\ \;\;\;\;x \cdot \frac{y}{t}\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (if (or (<= z -9e-21) (not (<= z 5.5e+32)))
   (* x (- 1.0 (/ y z)))
   (* x (/ y t))))
double code(double x, double y, double z, double t) {
	double tmp;
	if ((z <= -9e-21) || !(z <= 5.5e+32)) {
		tmp = x * (1.0 - (y / z));
	} else {
		tmp = x * (y / t);
	}
	return tmp;
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: tmp
    if ((z <= (-9d-21)) .or. (.not. (z <= 5.5d+32))) then
        tmp = x * (1.0d0 - (y / z))
    else
        tmp = x * (y / t)
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double tmp;
	if ((z <= -9e-21) || !(z <= 5.5e+32)) {
		tmp = x * (1.0 - (y / z));
	} else {
		tmp = x * (y / t);
	}
	return tmp;
}
def code(x, y, z, t):
	tmp = 0
	if (z <= -9e-21) or not (z <= 5.5e+32):
		tmp = x * (1.0 - (y / z))
	else:
		tmp = x * (y / t)
	return tmp
function code(x, y, z, t)
	tmp = 0.0
	if ((z <= -9e-21) || !(z <= 5.5e+32))
		tmp = Float64(x * Float64(1.0 - Float64(y / z)));
	else
		tmp = Float64(x * Float64(y / t));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if ((z <= -9e-21) || ~((z <= 5.5e+32)))
		tmp = x * (1.0 - (y / z));
	else
		tmp = x * (y / t);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := If[Or[LessEqual[z, -9e-21], N[Not[LessEqual[z, 5.5e+32]], $MachinePrecision]], N[(x * N[(1.0 - N[(y / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(y / t), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -9 \cdot 10^{-21} \lor \neg \left(z \leq 5.5 \cdot 10^{+32}\right):\\
\;\;\;\;x \cdot \left(1 - \frac{y}{z}\right)\\

\mathbf{else}:\\
\;\;\;\;x \cdot \frac{y}{t}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -8.99999999999999936e-21 or 5.49999999999999984e32 < z

    1. Initial program 78.4%

      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
    2. Step-by-step derivation
      1. associate-*r/99.8%

        \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    3. Simplified99.8%

      \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    4. Step-by-step derivation
      1. div-sub99.8%

        \[\leadsto x \cdot \color{blue}{\left(\frac{y}{t - z} - \frac{z}{t - z}\right)} \]
    5. Applied egg-rr99.8%

      \[\leadsto x \cdot \color{blue}{\left(\frac{y}{t - z} - \frac{z}{t - z}\right)} \]
    6. Taylor expanded in t around 0 74.3%

      \[\leadsto \color{blue}{x \cdot \left(1 + -1 \cdot \frac{y}{z}\right)} \]
    7. Step-by-step derivation
      1. mul-1-neg74.3%

        \[\leadsto x \cdot \left(1 + \color{blue}{\left(-\frac{y}{z}\right)}\right) \]
      2. unsub-neg74.3%

        \[\leadsto x \cdot \color{blue}{\left(1 - \frac{y}{z}\right)} \]
    8. Simplified74.3%

      \[\leadsto \color{blue}{x \cdot \left(1 - \frac{y}{z}\right)} \]

    if -8.99999999999999936e-21 < z < 5.49999999999999984e32

    1. Initial program 93.8%

      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
    2. Step-by-step derivation
      1. associate-*r/94.6%

        \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    3. Simplified94.6%

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

      \[\leadsto x \cdot \color{blue}{\frac{y}{t}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification71.5%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -9 \cdot 10^{-21} \lor \neg \left(z \leq 5.5 \cdot 10^{+32}\right):\\ \;\;\;\;x \cdot \left(1 - \frac{y}{z}\right)\\ \mathbf{else}:\\ \;\;\;\;x \cdot \frac{y}{t}\\ \end{array} \]

Alternative 7: 69.1% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -1.8 \cdot 10^{-10}:\\ \;\;\;\;x \cdot \frac{z}{z - t}\\ \mathbf{elif}\;z \leq 5 \cdot 10^{+33}:\\ \;\;\;\;x \cdot \frac{y}{t}\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(1 - \frac{y}{z}\right)\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (if (<= z -1.8e-10)
   (* x (/ z (- z t)))
   (if (<= z 5e+33) (* x (/ y t)) (* x (- 1.0 (/ y z))))))
double code(double x, double y, double z, double t) {
	double tmp;
	if (z <= -1.8e-10) {
		tmp = x * (z / (z - t));
	} else if (z <= 5e+33) {
		tmp = x * (y / t);
	} else {
		tmp = x * (1.0 - (y / z));
	}
	return tmp;
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: tmp
    if (z <= (-1.8d-10)) then
        tmp = x * (z / (z - t))
    else if (z <= 5d+33) then
        tmp = x * (y / t)
    else
        tmp = x * (1.0d0 - (y / z))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double tmp;
	if (z <= -1.8e-10) {
		tmp = x * (z / (z - t));
	} else if (z <= 5e+33) {
		tmp = x * (y / t);
	} else {
		tmp = x * (1.0 - (y / z));
	}
	return tmp;
}
def code(x, y, z, t):
	tmp = 0
	if z <= -1.8e-10:
		tmp = x * (z / (z - t))
	elif z <= 5e+33:
		tmp = x * (y / t)
	else:
		tmp = x * (1.0 - (y / z))
	return tmp
function code(x, y, z, t)
	tmp = 0.0
	if (z <= -1.8e-10)
		tmp = Float64(x * Float64(z / Float64(z - t)));
	elseif (z <= 5e+33)
		tmp = Float64(x * Float64(y / t));
	else
		tmp = Float64(x * Float64(1.0 - Float64(y / z)));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if (z <= -1.8e-10)
		tmp = x * (z / (z - t));
	elseif (z <= 5e+33)
		tmp = x * (y / t);
	else
		tmp = x * (1.0 - (y / z));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := If[LessEqual[z, -1.8e-10], N[(x * N[(z / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 5e+33], N[(x * N[(y / t), $MachinePrecision]), $MachinePrecision], N[(x * N[(1.0 - N[(y / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.8 \cdot 10^{-10}:\\
\;\;\;\;x \cdot \frac{z}{z - t}\\

\mathbf{elif}\;z \leq 5 \cdot 10^{+33}:\\
\;\;\;\;x \cdot \frac{y}{t}\\

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


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

    1. Initial program 77.5%

      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
    2. Step-by-step derivation
      1. associate-*r/99.8%

        \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    3. Simplified99.8%

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

      \[\leadsto x \cdot \color{blue}{\left(-1 \cdot \frac{z}{t - z}\right)} \]
    5. Step-by-step derivation
      1. neg-mul-180.7%

        \[\leadsto x \cdot \color{blue}{\left(-\frac{z}{t - z}\right)} \]
      2. distribute-neg-frac80.7%

        \[\leadsto x \cdot \color{blue}{\frac{-z}{t - z}} \]
    6. Simplified80.7%

      \[\leadsto x \cdot \color{blue}{\frac{-z}{t - z}} \]
    7. Step-by-step derivation
      1. frac-2neg80.7%

        \[\leadsto x \cdot \color{blue}{\frac{-\left(-z\right)}{-\left(t - z\right)}} \]
      2. div-inv80.7%

        \[\leadsto x \cdot \color{blue}{\left(\left(-\left(-z\right)\right) \cdot \frac{1}{-\left(t - z\right)}\right)} \]
      3. remove-double-neg80.7%

        \[\leadsto x \cdot \left(\color{blue}{z} \cdot \frac{1}{-\left(t - z\right)}\right) \]
      4. sub-neg80.7%

        \[\leadsto x \cdot \left(z \cdot \frac{1}{-\color{blue}{\left(t + \left(-z\right)\right)}}\right) \]
      5. distribute-neg-in80.7%

        \[\leadsto x \cdot \left(z \cdot \frac{1}{\color{blue}{\left(-t\right) + \left(-\left(-z\right)\right)}}\right) \]
      6. remove-double-neg80.7%

        \[\leadsto x \cdot \left(z \cdot \frac{1}{\left(-t\right) + \color{blue}{z}}\right) \]
    8. Applied egg-rr80.7%

      \[\leadsto x \cdot \color{blue}{\left(z \cdot \frac{1}{\left(-t\right) + z}\right)} \]
    9. Step-by-step derivation
      1. associate-*r/80.7%

        \[\leadsto x \cdot \color{blue}{\frac{z \cdot 1}{\left(-t\right) + z}} \]
      2. *-rgt-identity80.7%

        \[\leadsto x \cdot \frac{\color{blue}{z}}{\left(-t\right) + z} \]
      3. +-commutative80.7%

        \[\leadsto x \cdot \frac{z}{\color{blue}{z + \left(-t\right)}} \]
      4. unsub-neg80.7%

        \[\leadsto x \cdot \frac{z}{\color{blue}{z - t}} \]
    10. Simplified80.7%

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

    if -1.8e-10 < z < 4.99999999999999973e33

    1. Initial program 94.0%

      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
    2. Step-by-step derivation
      1. associate-*r/94.8%

        \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    3. Simplified94.8%

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

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

    if 4.99999999999999973e33 < z

    1. Initial program 78.0%

      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
    2. Step-by-step derivation
      1. associate-*r/99.9%

        \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    3. Simplified99.9%

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

        \[\leadsto x \cdot \color{blue}{\left(\frac{y}{t - z} - \frac{z}{t - z}\right)} \]
    5. Applied egg-rr99.9%

      \[\leadsto x \cdot \color{blue}{\left(\frac{y}{t - z} - \frac{z}{t - z}\right)} \]
    6. Taylor expanded in t around 0 79.8%

      \[\leadsto \color{blue}{x \cdot \left(1 + -1 \cdot \frac{y}{z}\right)} \]
    7. Step-by-step derivation
      1. mul-1-neg79.8%

        \[\leadsto x \cdot \left(1 + \color{blue}{\left(-\frac{y}{z}\right)}\right) \]
      2. unsub-neg79.8%

        \[\leadsto x \cdot \color{blue}{\left(1 - \frac{y}{z}\right)} \]
    8. Simplified79.8%

      \[\leadsto \color{blue}{x \cdot \left(1 - \frac{y}{z}\right)} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification74.1%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.8 \cdot 10^{-10}:\\ \;\;\;\;x \cdot \frac{z}{z - t}\\ \mathbf{elif}\;z \leq 5 \cdot 10^{+33}:\\ \;\;\;\;x \cdot \frac{y}{t}\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(1 - \frac{y}{z}\right)\\ \end{array} \]

Alternative 8: 72.2% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -5.7 \cdot 10^{+79}:\\ \;\;\;\;x \cdot \frac{z}{z - t}\\ \mathbf{elif}\;z \leq 2.05 \cdot 10^{+77}:\\ \;\;\;\;x \cdot \frac{y - z}{t}\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(1 - \frac{y}{z}\right)\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (if (<= z -5.7e+79)
   (* x (/ z (- z t)))
   (if (<= z 2.05e+77) (* x (/ (- y z) t)) (* x (- 1.0 (/ y z))))))
double code(double x, double y, double z, double t) {
	double tmp;
	if (z <= -5.7e+79) {
		tmp = x * (z / (z - t));
	} else if (z <= 2.05e+77) {
		tmp = x * ((y - z) / t);
	} else {
		tmp = x * (1.0 - (y / z));
	}
	return tmp;
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: tmp
    if (z <= (-5.7d+79)) then
        tmp = x * (z / (z - t))
    else if (z <= 2.05d+77) then
        tmp = x * ((y - z) / t)
    else
        tmp = x * (1.0d0 - (y / z))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double tmp;
	if (z <= -5.7e+79) {
		tmp = x * (z / (z - t));
	} else if (z <= 2.05e+77) {
		tmp = x * ((y - z) / t);
	} else {
		tmp = x * (1.0 - (y / z));
	}
	return tmp;
}
def code(x, y, z, t):
	tmp = 0
	if z <= -5.7e+79:
		tmp = x * (z / (z - t))
	elif z <= 2.05e+77:
		tmp = x * ((y - z) / t)
	else:
		tmp = x * (1.0 - (y / z))
	return tmp
function code(x, y, z, t)
	tmp = 0.0
	if (z <= -5.7e+79)
		tmp = Float64(x * Float64(z / Float64(z - t)));
	elseif (z <= 2.05e+77)
		tmp = Float64(x * Float64(Float64(y - z) / t));
	else
		tmp = Float64(x * Float64(1.0 - Float64(y / z)));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if (z <= -5.7e+79)
		tmp = x * (z / (z - t));
	elseif (z <= 2.05e+77)
		tmp = x * ((y - z) / t);
	else
		tmp = x * (1.0 - (y / z));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := If[LessEqual[z, -5.7e+79], N[(x * N[(z / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2.05e+77], N[(x * N[(N[(y - z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision], N[(x * N[(1.0 - N[(y / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -5.7 \cdot 10^{+79}:\\
\;\;\;\;x \cdot \frac{z}{z - t}\\

\mathbf{elif}\;z \leq 2.05 \cdot 10^{+77}:\\
\;\;\;\;x \cdot \frac{y - z}{t}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -5.6999999999999997e79

    1. Initial program 72.7%

      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
    2. Step-by-step derivation
      1. associate-*r/99.9%

        \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    3. Simplified99.9%

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

      \[\leadsto x \cdot \color{blue}{\left(-1 \cdot \frac{z}{t - z}\right)} \]
    5. Step-by-step derivation
      1. neg-mul-191.6%

        \[\leadsto x \cdot \color{blue}{\left(-\frac{z}{t - z}\right)} \]
      2. distribute-neg-frac91.6%

        \[\leadsto x \cdot \color{blue}{\frac{-z}{t - z}} \]
    6. Simplified91.6%

      \[\leadsto x \cdot \color{blue}{\frac{-z}{t - z}} \]
    7. Step-by-step derivation
      1. frac-2neg91.6%

        \[\leadsto x \cdot \color{blue}{\frac{-\left(-z\right)}{-\left(t - z\right)}} \]
      2. div-inv91.5%

        \[\leadsto x \cdot \color{blue}{\left(\left(-\left(-z\right)\right) \cdot \frac{1}{-\left(t - z\right)}\right)} \]
      3. remove-double-neg91.5%

        \[\leadsto x \cdot \left(\color{blue}{z} \cdot \frac{1}{-\left(t - z\right)}\right) \]
      4. sub-neg91.5%

        \[\leadsto x \cdot \left(z \cdot \frac{1}{-\color{blue}{\left(t + \left(-z\right)\right)}}\right) \]
      5. distribute-neg-in91.5%

        \[\leadsto x \cdot \left(z \cdot \frac{1}{\color{blue}{\left(-t\right) + \left(-\left(-z\right)\right)}}\right) \]
      6. remove-double-neg91.5%

        \[\leadsto x \cdot \left(z \cdot \frac{1}{\left(-t\right) + \color{blue}{z}}\right) \]
    8. Applied egg-rr91.5%

      \[\leadsto x \cdot \color{blue}{\left(z \cdot \frac{1}{\left(-t\right) + z}\right)} \]
    9. Step-by-step derivation
      1. associate-*r/91.6%

        \[\leadsto x \cdot \color{blue}{\frac{z \cdot 1}{\left(-t\right) + z}} \]
      2. *-rgt-identity91.6%

        \[\leadsto x \cdot \frac{\color{blue}{z}}{\left(-t\right) + z} \]
      3. +-commutative91.6%

        \[\leadsto x \cdot \frac{z}{\color{blue}{z + \left(-t\right)}} \]
      4. unsub-neg91.6%

        \[\leadsto x \cdot \frac{z}{\color{blue}{z - t}} \]
    10. Simplified91.6%

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

    if -5.6999999999999997e79 < z < 2.05e77

    1. Initial program 93.3%

      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
    2. Step-by-step derivation
      1. associate-*r/95.7%

        \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    3. Simplified95.7%

      \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    4. Taylor expanded in t around inf 77.1%

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

    if 2.05e77 < z

    1. Initial program 75.2%

      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
    2. Step-by-step derivation
      1. associate-*r/99.9%

        \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    3. Simplified99.9%

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

        \[\leadsto x \cdot \color{blue}{\left(\frac{y}{t - z} - \frac{z}{t - z}\right)} \]
    5. Applied egg-rr99.9%

      \[\leadsto x \cdot \color{blue}{\left(\frac{y}{t - z} - \frac{z}{t - z}\right)} \]
    6. Taylor expanded in t around 0 83.7%

      \[\leadsto \color{blue}{x \cdot \left(1 + -1 \cdot \frac{y}{z}\right)} \]
    7. Step-by-step derivation
      1. mul-1-neg83.7%

        \[\leadsto x \cdot \left(1 + \color{blue}{\left(-\frac{y}{z}\right)}\right) \]
      2. unsub-neg83.7%

        \[\leadsto x \cdot \color{blue}{\left(1 - \frac{y}{z}\right)} \]
    8. Simplified83.7%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -5.7 \cdot 10^{+79}:\\ \;\;\;\;x \cdot \frac{z}{z - t}\\ \mathbf{elif}\;z \leq 2.05 \cdot 10^{+77}:\\ \;\;\;\;x \cdot \frac{y - z}{t}\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(1 - \frac{y}{z}\right)\\ \end{array} \]

Alternative 9: 60.8% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -1.45 \cdot 10^{+49}:\\ \;\;\;\;x\\ \mathbf{elif}\;z \leq 4.5 \cdot 10^{+74}:\\ \;\;\;\;x \cdot \frac{y}{t}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (if (<= z -1.45e+49) x (if (<= z 4.5e+74) (* x (/ y t)) x)))
double code(double x, double y, double z, double t) {
	double tmp;
	if (z <= -1.45e+49) {
		tmp = x;
	} else if (z <= 4.5e+74) {
		tmp = x * (y / t);
	} else {
		tmp = x;
	}
	return tmp;
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8) :: tmp
    if (z <= (-1.45d+49)) then
        tmp = x
    else if (z <= 4.5d+74) then
        tmp = x * (y / t)
    else
        tmp = x
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double tmp;
	if (z <= -1.45e+49) {
		tmp = x;
	} else if (z <= 4.5e+74) {
		tmp = x * (y / t);
	} else {
		tmp = x;
	}
	return tmp;
}
def code(x, y, z, t):
	tmp = 0
	if z <= -1.45e+49:
		tmp = x
	elif z <= 4.5e+74:
		tmp = x * (y / t)
	else:
		tmp = x
	return tmp
function code(x, y, z, t)
	tmp = 0.0
	if (z <= -1.45e+49)
		tmp = x;
	elseif (z <= 4.5e+74)
		tmp = Float64(x * Float64(y / t));
	else
		tmp = x;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	tmp = 0.0;
	if (z <= -1.45e+49)
		tmp = x;
	elseif (z <= 4.5e+74)
		tmp = x * (y / t);
	else
		tmp = x;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := If[LessEqual[z, -1.45e+49], x, If[LessEqual[z, 4.5e+74], N[(x * N[(y / t), $MachinePrecision]), $MachinePrecision], x]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.45 \cdot 10^{+49}:\\
\;\;\;\;x\\

\mathbf{elif}\;z \leq 4.5 \cdot 10^{+74}:\\
\;\;\;\;x \cdot \frac{y}{t}\\

\mathbf{else}:\\
\;\;\;\;x\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -1.45e49 or 4.5e74 < z

    1. Initial program 75.4%

      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
    2. Step-by-step derivation
      1. associate-*r/99.9%

        \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    3. Simplified99.9%

      \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    4. Taylor expanded in z around inf 71.4%

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

    if -1.45e49 < z < 4.5e74

    1. Initial program 93.0%

      \[\frac{x \cdot \left(y - z\right)}{t - z} \]
    2. Step-by-step derivation
      1. associate-*r/95.5%

        \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
    3. Simplified95.5%

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

      \[\leadsto x \cdot \color{blue}{\frac{y}{t}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification66.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.45 \cdot 10^{+49}:\\ \;\;\;\;x\\ \mathbf{elif}\;z \leq 4.5 \cdot 10^{+74}:\\ \;\;\;\;x \cdot \frac{y}{t}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]

Alternative 10: 34.9% accurate, 9.0× speedup?

\[\begin{array}{l} \\ x \end{array} \]
(FPCore (x y z t) :precision binary64 x)
double code(double x, double y, double z, double t) {
	return x;
}
real(8) function code(x, y, z, t)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    code = x
end function
public static double code(double x, double y, double z, double t) {
	return x;
}
def code(x, y, z, t):
	return x
function code(x, y, z, t)
	return x
end
function tmp = code(x, y, z, t)
	tmp = x;
end
code[x_, y_, z_, t_] := x
\begin{array}{l}

\\
x
\end{array}
Derivation
  1. Initial program 85.9%

    \[\frac{x \cdot \left(y - z\right)}{t - z} \]
  2. Step-by-step derivation
    1. associate-*r/97.3%

      \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
  3. Simplified97.3%

    \[\leadsto \color{blue}{x \cdot \frac{y - z}{t - z}} \]
  4. Taylor expanded in z around inf 35.0%

    \[\leadsto \color{blue}{x} \]
  5. Final simplification35.0%

    \[\leadsto x \]

Developer target: 97.0% accurate, 1.0× 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));
}
real(8) function code(x, y, z, t)
    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 2023320 
(FPCore (x y z t)
  :name "Graphics.Rendering.Chart.Plot.AreaSpots:renderAreaSpots4D from Chart-1.5.3"
  :precision binary64

  :herbie-target
  (/ x (/ (- t z) (- y z)))

  (/ (* x (- y z)) (- t z)))