Diagrams.Solve.Polynomial:cubForm from diagrams-solve-0.1, H

Percentage Accurate: 95.7% → 99.0%
Time: 13.2s
Alternatives: 18
Speedup: 1.4×

Specification

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

\\
\left(x - \frac{y}{z \cdot 3}\right) + \frac{t}{\left(z \cdot 3\right) \cdot y}
\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 18 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: 95.7% accurate, 1.0× speedup?

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

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

Alternative 1: 99.0% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := x - \frac{y}{z \cdot 3}\\ \mathbf{if}\;z \cdot 3 \leq -1 \cdot 10^{+31}:\\ \;\;\;\;t\_1 + \frac{t}{3 \cdot \left(z \cdot y\right)}\\ \mathbf{elif}\;z \cdot 3 \leq 10^{-124}:\\ \;\;\;\;x + \frac{\frac{t}{y} - y}{3} \cdot \frac{1}{z}\\ \mathbf{else}:\\ \;\;\;\;t\_1 + t \cdot \frac{\frac{0.3333333333333333}{z}}{y}\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (- x (/ y (* z 3.0)))))
   (if (<= (* z 3.0) -1e+31)
     (+ t_1 (/ t (* 3.0 (* z y))))
     (if (<= (* z 3.0) 1e-124)
       (+ x (* (/ (- (/ t y) y) 3.0) (/ 1.0 z)))
       (+ t_1 (* t (/ (/ 0.3333333333333333 z) y)))))))
double code(double x, double y, double z, double t) {
	double t_1 = x - (y / (z * 3.0));
	double tmp;
	if ((z * 3.0) <= -1e+31) {
		tmp = t_1 + (t / (3.0 * (z * y)));
	} else if ((z * 3.0) <= 1e-124) {
		tmp = x + ((((t / y) - y) / 3.0) * (1.0 / z));
	} else {
		tmp = t_1 + (t * ((0.3333333333333333 / z) / y));
	}
	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) :: t_1
    real(8) :: tmp
    t_1 = x - (y / (z * 3.0d0))
    if ((z * 3.0d0) <= (-1d+31)) then
        tmp = t_1 + (t / (3.0d0 * (z * y)))
    else if ((z * 3.0d0) <= 1d-124) then
        tmp = x + ((((t / y) - y) / 3.0d0) * (1.0d0 / z))
    else
        tmp = t_1 + (t * ((0.3333333333333333d0 / z) / y))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double t_1 = x - (y / (z * 3.0));
	double tmp;
	if ((z * 3.0) <= -1e+31) {
		tmp = t_1 + (t / (3.0 * (z * y)));
	} else if ((z * 3.0) <= 1e-124) {
		tmp = x + ((((t / y) - y) / 3.0) * (1.0 / z));
	} else {
		tmp = t_1 + (t * ((0.3333333333333333 / z) / y));
	}
	return tmp;
}
def code(x, y, z, t):
	t_1 = x - (y / (z * 3.0))
	tmp = 0
	if (z * 3.0) <= -1e+31:
		tmp = t_1 + (t / (3.0 * (z * y)))
	elif (z * 3.0) <= 1e-124:
		tmp = x + ((((t / y) - y) / 3.0) * (1.0 / z))
	else:
		tmp = t_1 + (t * ((0.3333333333333333 / z) / y))
	return tmp
function code(x, y, z, t)
	t_1 = Float64(x - Float64(y / Float64(z * 3.0)))
	tmp = 0.0
	if (Float64(z * 3.0) <= -1e+31)
		tmp = Float64(t_1 + Float64(t / Float64(3.0 * Float64(z * y))));
	elseif (Float64(z * 3.0) <= 1e-124)
		tmp = Float64(x + Float64(Float64(Float64(Float64(t / y) - y) / 3.0) * Float64(1.0 / z)));
	else
		tmp = Float64(t_1 + Float64(t * Float64(Float64(0.3333333333333333 / z) / y)));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	t_1 = x - (y / (z * 3.0));
	tmp = 0.0;
	if ((z * 3.0) <= -1e+31)
		tmp = t_1 + (t / (3.0 * (z * y)));
	elseif ((z * 3.0) <= 1e-124)
		tmp = x + ((((t / y) - y) / 3.0) * (1.0 / z));
	else
		tmp = t_1 + (t * ((0.3333333333333333 / z) / y));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(x - N[(y / N[(z * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(z * 3.0), $MachinePrecision], -1e+31], N[(t$95$1 + N[(t / N[(3.0 * N[(z * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(z * 3.0), $MachinePrecision], 1e-124], N[(x + N[(N[(N[(N[(t / y), $MachinePrecision] - y), $MachinePrecision] / 3.0), $MachinePrecision] * N[(1.0 / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t$95$1 + N[(t * N[(N[(0.3333333333333333 / z), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}

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

\mathbf{elif}\;z \cdot 3 \leq 10^{-124}:\\
\;\;\;\;x + \frac{\frac{t}{y} - y}{3} \cdot \frac{1}{z}\\

\mathbf{else}:\\
\;\;\;\;t\_1 + t \cdot \frac{\frac{0.3333333333333333}{z}}{y}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (*.f64 z #s(literal 3 binary64)) < -9.9999999999999996e30

    1. Initial program 99.8%

      \[\left(x - \frac{y}{z \cdot 3}\right) + \frac{t}{\left(z \cdot 3\right) \cdot y} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. associate-*l*N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(z, 3\right)\right)\right), \mathsf{/.f64}\left(t, \left(z \cdot \color{blue}{\left(3 \cdot y\right)}\right)\right)\right) \]
      2. *-commutativeN/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(z, 3\right)\right)\right), \mathsf{/.f64}\left(t, \left(z \cdot \left(y \cdot \color{blue}{3}\right)\right)\right)\right) \]
      3. associate-*r*N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(z, 3\right)\right)\right), \mathsf{/.f64}\left(t, \left(\left(z \cdot y\right) \cdot \color{blue}{3}\right)\right)\right) \]
      4. *-lowering-*.f64N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(z, 3\right)\right)\right), \mathsf{/.f64}\left(t, \mathsf{*.f64}\left(\left(z \cdot y\right), \color{blue}{3}\right)\right)\right) \]
      5. *-lowering-*.f6499.8%

        \[\leadsto \mathsf{+.f64}\left(\mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(z, 3\right)\right)\right), \mathsf{/.f64}\left(t, \mathsf{*.f64}\left(\mathsf{*.f64}\left(z, y\right), 3\right)\right)\right) \]
    4. Applied egg-rr99.8%

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

    if -9.9999999999999996e30 < (*.f64 z #s(literal 3 binary64)) < 9.99999999999999933e-125

    1. Initial program 90.5%

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

      \[\leadsto \color{blue}{\left(x + \frac{1}{3} \cdot \frac{t}{y \cdot z}\right) - \frac{1}{3} \cdot \frac{y}{z}} \]
    4. Step-by-step derivation
      1. associate--l+N/A

        \[\leadsto x + \color{blue}{\left(\frac{1}{3} \cdot \frac{t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right)} \]
      2. +-commutativeN/A

        \[\leadsto \left(\frac{1}{3} \cdot \frac{t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right) + \color{blue}{x} \]
      3. +-lowering-+.f64N/A

        \[\leadsto \mathsf{+.f64}\left(\left(\frac{1}{3} \cdot \frac{t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right), \color{blue}{x}\right) \]
      4. associate-*r/N/A

        \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3} \cdot t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
      5. *-commutativeN/A

        \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3} \cdot t}{z \cdot y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
      6. times-fracN/A

        \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3}}{z} \cdot \frac{t}{y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
      7. metadata-evalN/A

        \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3} \cdot 1}{z} \cdot \frac{t}{y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
      8. associate-*r/N/A

        \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
      9. associate-*r/N/A

        \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{\frac{1}{3} \cdot y}{z}\right), x\right) \]
      10. associate-*l/N/A

        \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{\frac{1}{3}}{z} \cdot y\right), x\right) \]
      11. metadata-evalN/A

        \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{\frac{1}{3} \cdot 1}{z} \cdot y\right), x\right) \]
      12. associate-*r/N/A

        \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot y\right), x\right) \]
      13. distribute-lft-out--N/A

        \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \left(\frac{t}{y} - y\right)\right), x\right) \]
      14. *-lowering-*.f64N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
      15. associate-*r/N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\left(\frac{\frac{1}{3} \cdot 1}{z}\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
      16. metadata-evalN/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\left(\frac{\frac{1}{3}}{z}\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
      17. /-lowering-/.f64N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, z\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
      18. --lowering--.f64N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, z\right), \mathsf{\_.f64}\left(\left(\frac{t}{y}\right), y\right)\right), x\right) \]
      19. /-lowering-/.f6499.7%

        \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, z\right), \mathsf{\_.f64}\left(\mathsf{/.f64}\left(t, y\right), y\right)\right), x\right) \]
    5. Simplified99.7%

      \[\leadsto \color{blue}{\frac{0.3333333333333333}{z} \cdot \left(\frac{t}{y} - y\right) + x} \]
    6. Step-by-step derivation
      1. *-commutativeN/A

        \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{t}{y} - y\right) \cdot \frac{\frac{1}{3}}{z}\right), x\right) \]
      2. metadata-evalN/A

        \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{t}{y} - y\right) \cdot \frac{\frac{1}{3}}{z}\right), x\right) \]
      3. associate-/r*N/A

        \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{t}{y} - y\right) \cdot \frac{1}{3 \cdot z}\right), x\right) \]
      4. *-commutativeN/A

        \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{t}{y} - y\right) \cdot \frac{1}{z \cdot 3}\right), x\right) \]
      5. associate-*r/N/A

        \[\leadsto \mathsf{+.f64}\left(\left(\frac{\left(\frac{t}{y} - y\right) \cdot 1}{z \cdot 3}\right), x\right) \]
      6. *-commutativeN/A

        \[\leadsto \mathsf{+.f64}\left(\left(\frac{\left(\frac{t}{y} - y\right) \cdot 1}{3 \cdot z}\right), x\right) \]
      7. times-fracN/A

        \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{t}{y} - y}{3} \cdot \frac{1}{z}\right), x\right) \]
      8. *-lowering-*.f64N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\left(\frac{\frac{t}{y} - y}{3}\right), \left(\frac{1}{z}\right)\right), x\right) \]
      9. /-lowering-/.f64N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\left(\frac{t}{y} - y\right), 3\right), \left(\frac{1}{z}\right)\right), x\right) \]
      10. --lowering--.f64N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{\_.f64}\left(\left(\frac{t}{y}\right), y\right), 3\right), \left(\frac{1}{z}\right)\right), x\right) \]
      11. /-lowering-/.f64N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{\_.f64}\left(\mathsf{/.f64}\left(t, y\right), y\right), 3\right), \left(\frac{1}{z}\right)\right), x\right) \]
      12. /-lowering-/.f6499.8%

        \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{\_.f64}\left(\mathsf{/.f64}\left(t, y\right), y\right), 3\right), \mathsf{/.f64}\left(1, z\right)\right), x\right) \]
    7. Applied egg-rr99.8%

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

    if 9.99999999999999933e-125 < (*.f64 z #s(literal 3 binary64))

    1. Initial program 99.7%

      \[\left(x - \frac{y}{z \cdot 3}\right) + \frac{t}{\left(z \cdot 3\right) \cdot y} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. clear-numN/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(z, 3\right)\right)\right), \left(\frac{1}{\color{blue}{\frac{\left(z \cdot 3\right) \cdot y}{t}}}\right)\right) \]
      2. associate-/r/N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(z, 3\right)\right)\right), \left(\frac{1}{\left(z \cdot 3\right) \cdot y} \cdot \color{blue}{t}\right)\right) \]
      3. *-lowering-*.f64N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(z, 3\right)\right)\right), \mathsf{*.f64}\left(\left(\frac{1}{\left(z \cdot 3\right) \cdot y}\right), \color{blue}{t}\right)\right) \]
      4. associate-/r*N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(z, 3\right)\right)\right), \mathsf{*.f64}\left(\left(\frac{\frac{1}{z \cdot 3}}{y}\right), t\right)\right) \]
      5. /-lowering-/.f64N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(z, 3\right)\right)\right), \mathsf{*.f64}\left(\mathsf{/.f64}\left(\left(\frac{1}{z \cdot 3}\right), y\right), t\right)\right) \]
      6. *-commutativeN/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(z, 3\right)\right)\right), \mathsf{*.f64}\left(\mathsf{/.f64}\left(\left(\frac{1}{3 \cdot z}\right), y\right), t\right)\right) \]
      7. associate-/r*N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(z, 3\right)\right)\right), \mathsf{*.f64}\left(\mathsf{/.f64}\left(\left(\frac{\frac{1}{3}}{z}\right), y\right), t\right)\right) \]
      8. /-lowering-/.f64N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(z, 3\right)\right)\right), \mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(\left(\frac{1}{3}\right), z\right), y\right), t\right)\right) \]
      9. metadata-eval99.8%

        \[\leadsto \mathsf{+.f64}\left(\mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(z, 3\right)\right)\right), \mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, z\right), y\right), t\right)\right) \]
    4. Applied egg-rr99.8%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \cdot 3 \leq -1 \cdot 10^{+31}:\\ \;\;\;\;\left(x - \frac{y}{z \cdot 3}\right) + \frac{t}{3 \cdot \left(z \cdot y\right)}\\ \mathbf{elif}\;z \cdot 3 \leq 10^{-124}:\\ \;\;\;\;x + \frac{\frac{t}{y} - y}{3} \cdot \frac{1}{z}\\ \mathbf{else}:\\ \;\;\;\;\left(x - \frac{y}{z \cdot 3}\right) + t \cdot \frac{\frac{0.3333333333333333}{z}}{y}\\ \end{array} \]
  5. Add Preprocessing

Alternative 2: 99.0% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := \left(x - \frac{y}{z \cdot 3}\right) + t \cdot \frac{\frac{0.3333333333333333}{z}}{y}\\ \mathbf{if}\;z \cdot 3 \leq -1 \cdot 10^{+31}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \cdot 3 \leq 10^{-124}:\\ \;\;\;\;x + \frac{\frac{t}{y} - y}{3} \cdot \frac{1}{z}\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (+ (- x (/ y (* z 3.0))) (* t (/ (/ 0.3333333333333333 z) y)))))
   (if (<= (* z 3.0) -1e+31)
     t_1
     (if (<= (* z 3.0) 1e-124)
       (+ x (* (/ (- (/ t y) y) 3.0) (/ 1.0 z)))
       t_1))))
double code(double x, double y, double z, double t) {
	double t_1 = (x - (y / (z * 3.0))) + (t * ((0.3333333333333333 / z) / y));
	double tmp;
	if ((z * 3.0) <= -1e+31) {
		tmp = t_1;
	} else if ((z * 3.0) <= 1e-124) {
		tmp = x + ((((t / y) - y) / 3.0) * (1.0 / z));
	} else {
		tmp = t_1;
	}
	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) :: t_1
    real(8) :: tmp
    t_1 = (x - (y / (z * 3.0d0))) + (t * ((0.3333333333333333d0 / z) / y))
    if ((z * 3.0d0) <= (-1d+31)) then
        tmp = t_1
    else if ((z * 3.0d0) <= 1d-124) then
        tmp = x + ((((t / y) - y) / 3.0d0) * (1.0d0 / z))
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double t_1 = (x - (y / (z * 3.0))) + (t * ((0.3333333333333333 / z) / y));
	double tmp;
	if ((z * 3.0) <= -1e+31) {
		tmp = t_1;
	} else if ((z * 3.0) <= 1e-124) {
		tmp = x + ((((t / y) - y) / 3.0) * (1.0 / z));
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t):
	t_1 = (x - (y / (z * 3.0))) + (t * ((0.3333333333333333 / z) / y))
	tmp = 0
	if (z * 3.0) <= -1e+31:
		tmp = t_1
	elif (z * 3.0) <= 1e-124:
		tmp = x + ((((t / y) - y) / 3.0) * (1.0 / z))
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t)
	t_1 = Float64(Float64(x - Float64(y / Float64(z * 3.0))) + Float64(t * Float64(Float64(0.3333333333333333 / z) / y)))
	tmp = 0.0
	if (Float64(z * 3.0) <= -1e+31)
		tmp = t_1;
	elseif (Float64(z * 3.0) <= 1e-124)
		tmp = Float64(x + Float64(Float64(Float64(Float64(t / y) - y) / 3.0) * Float64(1.0 / z)));
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	t_1 = (x - (y / (z * 3.0))) + (t * ((0.3333333333333333 / z) / y));
	tmp = 0.0;
	if ((z * 3.0) <= -1e+31)
		tmp = t_1;
	elseif ((z * 3.0) <= 1e-124)
		tmp = x + ((((t / y) - y) / 3.0) * (1.0 / z));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(x - N[(y / N[(z * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(t * N[(N[(0.3333333333333333 / z), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(z * 3.0), $MachinePrecision], -1e+31], t$95$1, If[LessEqual[N[(z * 3.0), $MachinePrecision], 1e-124], N[(x + N[(N[(N[(N[(t / y), $MachinePrecision] - y), $MachinePrecision] / 3.0), $MachinePrecision] * N[(1.0 / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := \left(x - \frac{y}{z \cdot 3}\right) + t \cdot \frac{\frac{0.3333333333333333}{z}}{y}\\
\mathbf{if}\;z \cdot 3 \leq -1 \cdot 10^{+31}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;z \cdot 3 \leq 10^{-124}:\\
\;\;\;\;x + \frac{\frac{t}{y} - y}{3} \cdot \frac{1}{z}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (*.f64 z #s(literal 3 binary64)) < -9.9999999999999996e30 or 9.99999999999999933e-125 < (*.f64 z #s(literal 3 binary64))

    1. Initial program 99.7%

      \[\left(x - \frac{y}{z \cdot 3}\right) + \frac{t}{\left(z \cdot 3\right) \cdot y} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. clear-numN/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(z, 3\right)\right)\right), \left(\frac{1}{\color{blue}{\frac{\left(z \cdot 3\right) \cdot y}{t}}}\right)\right) \]
      2. associate-/r/N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(z, 3\right)\right)\right), \left(\frac{1}{\left(z \cdot 3\right) \cdot y} \cdot \color{blue}{t}\right)\right) \]
      3. *-lowering-*.f64N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(z, 3\right)\right)\right), \mathsf{*.f64}\left(\left(\frac{1}{\left(z \cdot 3\right) \cdot y}\right), \color{blue}{t}\right)\right) \]
      4. associate-/r*N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(z, 3\right)\right)\right), \mathsf{*.f64}\left(\left(\frac{\frac{1}{z \cdot 3}}{y}\right), t\right)\right) \]
      5. /-lowering-/.f64N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(z, 3\right)\right)\right), \mathsf{*.f64}\left(\mathsf{/.f64}\left(\left(\frac{1}{z \cdot 3}\right), y\right), t\right)\right) \]
      6. *-commutativeN/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(z, 3\right)\right)\right), \mathsf{*.f64}\left(\mathsf{/.f64}\left(\left(\frac{1}{3 \cdot z}\right), y\right), t\right)\right) \]
      7. associate-/r*N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(z, 3\right)\right)\right), \mathsf{*.f64}\left(\mathsf{/.f64}\left(\left(\frac{\frac{1}{3}}{z}\right), y\right), t\right)\right) \]
      8. /-lowering-/.f64N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(z, 3\right)\right)\right), \mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(\left(\frac{1}{3}\right), z\right), y\right), t\right)\right) \]
      9. metadata-eval99.8%

        \[\leadsto \mathsf{+.f64}\left(\mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(y, \mathsf{*.f64}\left(z, 3\right)\right)\right), \mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, z\right), y\right), t\right)\right) \]
    4. Applied egg-rr99.8%

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

    if -9.9999999999999996e30 < (*.f64 z #s(literal 3 binary64)) < 9.99999999999999933e-125

    1. Initial program 90.5%

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

      \[\leadsto \color{blue}{\left(x + \frac{1}{3} \cdot \frac{t}{y \cdot z}\right) - \frac{1}{3} \cdot \frac{y}{z}} \]
    4. Step-by-step derivation
      1. associate--l+N/A

        \[\leadsto x + \color{blue}{\left(\frac{1}{3} \cdot \frac{t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right)} \]
      2. +-commutativeN/A

        \[\leadsto \left(\frac{1}{3} \cdot \frac{t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right) + \color{blue}{x} \]
      3. +-lowering-+.f64N/A

        \[\leadsto \mathsf{+.f64}\left(\left(\frac{1}{3} \cdot \frac{t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right), \color{blue}{x}\right) \]
      4. associate-*r/N/A

        \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3} \cdot t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
      5. *-commutativeN/A

        \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3} \cdot t}{z \cdot y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
      6. times-fracN/A

        \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3}}{z} \cdot \frac{t}{y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
      7. metadata-evalN/A

        \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3} \cdot 1}{z} \cdot \frac{t}{y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
      8. associate-*r/N/A

        \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
      9. associate-*r/N/A

        \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{\frac{1}{3} \cdot y}{z}\right), x\right) \]
      10. associate-*l/N/A

        \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{\frac{1}{3}}{z} \cdot y\right), x\right) \]
      11. metadata-evalN/A

        \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{\frac{1}{3} \cdot 1}{z} \cdot y\right), x\right) \]
      12. associate-*r/N/A

        \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot y\right), x\right) \]
      13. distribute-lft-out--N/A

        \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \left(\frac{t}{y} - y\right)\right), x\right) \]
      14. *-lowering-*.f64N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
      15. associate-*r/N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\left(\frac{\frac{1}{3} \cdot 1}{z}\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
      16. metadata-evalN/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\left(\frac{\frac{1}{3}}{z}\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
      17. /-lowering-/.f64N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, z\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
      18. --lowering--.f64N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, z\right), \mathsf{\_.f64}\left(\left(\frac{t}{y}\right), y\right)\right), x\right) \]
      19. /-lowering-/.f6499.7%

        \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, z\right), \mathsf{\_.f64}\left(\mathsf{/.f64}\left(t, y\right), y\right)\right), x\right) \]
    5. Simplified99.7%

      \[\leadsto \color{blue}{\frac{0.3333333333333333}{z} \cdot \left(\frac{t}{y} - y\right) + x} \]
    6. Step-by-step derivation
      1. *-commutativeN/A

        \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{t}{y} - y\right) \cdot \frac{\frac{1}{3}}{z}\right), x\right) \]
      2. metadata-evalN/A

        \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{t}{y} - y\right) \cdot \frac{\frac{1}{3}}{z}\right), x\right) \]
      3. associate-/r*N/A

        \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{t}{y} - y\right) \cdot \frac{1}{3 \cdot z}\right), x\right) \]
      4. *-commutativeN/A

        \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{t}{y} - y\right) \cdot \frac{1}{z \cdot 3}\right), x\right) \]
      5. associate-*r/N/A

        \[\leadsto \mathsf{+.f64}\left(\left(\frac{\left(\frac{t}{y} - y\right) \cdot 1}{z \cdot 3}\right), x\right) \]
      6. *-commutativeN/A

        \[\leadsto \mathsf{+.f64}\left(\left(\frac{\left(\frac{t}{y} - y\right) \cdot 1}{3 \cdot z}\right), x\right) \]
      7. times-fracN/A

        \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{t}{y} - y}{3} \cdot \frac{1}{z}\right), x\right) \]
      8. *-lowering-*.f64N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\left(\frac{\frac{t}{y} - y}{3}\right), \left(\frac{1}{z}\right)\right), x\right) \]
      9. /-lowering-/.f64N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\left(\frac{t}{y} - y\right), 3\right), \left(\frac{1}{z}\right)\right), x\right) \]
      10. --lowering--.f64N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{\_.f64}\left(\left(\frac{t}{y}\right), y\right), 3\right), \left(\frac{1}{z}\right)\right), x\right) \]
      11. /-lowering-/.f64N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{\_.f64}\left(\mathsf{/.f64}\left(t, y\right), y\right), 3\right), \left(\frac{1}{z}\right)\right), x\right) \]
      12. /-lowering-/.f6499.8%

        \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{\_.f64}\left(\mathsf{/.f64}\left(t, y\right), y\right), 3\right), \mathsf{/.f64}\left(1, z\right)\right), x\right) \]
    7. Applied egg-rr99.8%

      \[\leadsto \color{blue}{\frac{\frac{t}{y} - y}{3} \cdot \frac{1}{z}} + x \]
  3. Recombined 2 regimes into one program.
  4. Final simplification99.8%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \cdot 3 \leq -1 \cdot 10^{+31}:\\ \;\;\;\;\left(x - \frac{y}{z \cdot 3}\right) + t \cdot \frac{\frac{0.3333333333333333}{z}}{y}\\ \mathbf{elif}\;z \cdot 3 \leq 10^{-124}:\\ \;\;\;\;x + \frac{\frac{t}{y} - y}{3} \cdot \frac{1}{z}\\ \mathbf{else}:\\ \;\;\;\;\left(x - \frac{y}{z \cdot 3}\right) + t \cdot \frac{\frac{0.3333333333333333}{z}}{y}\\ \end{array} \]
  5. Add Preprocessing

Alternative 3: 88.7% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := x + \frac{y \cdot -0.3333333333333333}{z}\\ \mathbf{if}\;y \leq -2.5 \cdot 10^{-55}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \leq 2.4 \cdot 10^{+64}:\\ \;\;\;\;x + \frac{t}{\left(z \cdot 3\right) \cdot y}\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t)
 :precision binary64
 (let* ((t_1 (+ x (/ (* y -0.3333333333333333) z))))
   (if (<= y -2.5e-55)
     t_1
     (if (<= y 2.4e+64) (+ x (/ t (* (* z 3.0) y))) t_1))))
double code(double x, double y, double z, double t) {
	double t_1 = x + ((y * -0.3333333333333333) / z);
	double tmp;
	if (y <= -2.5e-55) {
		tmp = t_1;
	} else if (y <= 2.4e+64) {
		tmp = x + (t / ((z * 3.0) * y));
	} else {
		tmp = t_1;
	}
	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) :: t_1
    real(8) :: tmp
    t_1 = x + ((y * (-0.3333333333333333d0)) / z)
    if (y <= (-2.5d-55)) then
        tmp = t_1
    else if (y <= 2.4d+64) then
        tmp = x + (t / ((z * 3.0d0) * y))
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t) {
	double t_1 = x + ((y * -0.3333333333333333) / z);
	double tmp;
	if (y <= -2.5e-55) {
		tmp = t_1;
	} else if (y <= 2.4e+64) {
		tmp = x + (t / ((z * 3.0) * y));
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t):
	t_1 = x + ((y * -0.3333333333333333) / z)
	tmp = 0
	if y <= -2.5e-55:
		tmp = t_1
	elif y <= 2.4e+64:
		tmp = x + (t / ((z * 3.0) * y))
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t)
	t_1 = Float64(x + Float64(Float64(y * -0.3333333333333333) / z))
	tmp = 0.0
	if (y <= -2.5e-55)
		tmp = t_1;
	elseif (y <= 2.4e+64)
		tmp = Float64(x + Float64(t / Float64(Float64(z * 3.0) * y)));
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t)
	t_1 = x + ((y * -0.3333333333333333) / z);
	tmp = 0.0;
	if (y <= -2.5e-55)
		tmp = t_1;
	elseif (y <= 2.4e+64)
		tmp = x + (t / ((z * 3.0) * y));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_] := Block[{t$95$1 = N[(x + N[(N[(y * -0.3333333333333333), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -2.5e-55], t$95$1, If[LessEqual[y, 2.4e+64], N[(x + N[(t / N[(N[(z * 3.0), $MachinePrecision] * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := x + \frac{y \cdot -0.3333333333333333}{z}\\
\mathbf{if}\;y \leq -2.5 \cdot 10^{-55}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;y \leq 2.4 \cdot 10^{+64}:\\
\;\;\;\;x + \frac{t}{\left(z \cdot 3\right) \cdot y}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y < -2.5000000000000001e-55 or 2.39999999999999999e64 < y

    1. Initial program 99.1%

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

      \[\leadsto \color{blue}{\left(x + \frac{1}{3} \cdot \frac{t}{y \cdot z}\right) - \frac{1}{3} \cdot \frac{y}{z}} \]
    4. Step-by-step derivation
      1. associate--l+N/A

        \[\leadsto x + \color{blue}{\left(\frac{1}{3} \cdot \frac{t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right)} \]
      2. +-commutativeN/A

        \[\leadsto \left(\frac{1}{3} \cdot \frac{t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right) + \color{blue}{x} \]
      3. +-lowering-+.f64N/A

        \[\leadsto \mathsf{+.f64}\left(\left(\frac{1}{3} \cdot \frac{t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right), \color{blue}{x}\right) \]
      4. associate-*r/N/A

        \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3} \cdot t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
      5. *-commutativeN/A

        \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3} \cdot t}{z \cdot y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
      6. times-fracN/A

        \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3}}{z} \cdot \frac{t}{y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
      7. metadata-evalN/A

        \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3} \cdot 1}{z} \cdot \frac{t}{y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
      8. associate-*r/N/A

        \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
      9. associate-*r/N/A

        \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{\frac{1}{3} \cdot y}{z}\right), x\right) \]
      10. associate-*l/N/A

        \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{\frac{1}{3}}{z} \cdot y\right), x\right) \]
      11. metadata-evalN/A

        \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{\frac{1}{3} \cdot 1}{z} \cdot y\right), x\right) \]
      12. associate-*r/N/A

        \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot y\right), x\right) \]
      13. distribute-lft-out--N/A

        \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \left(\frac{t}{y} - y\right)\right), x\right) \]
      14. *-lowering-*.f64N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
      15. associate-*r/N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\left(\frac{\frac{1}{3} \cdot 1}{z}\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
      16. metadata-evalN/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\left(\frac{\frac{1}{3}}{z}\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
      17. /-lowering-/.f64N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, z\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
      18. --lowering--.f64N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, z\right), \mathsf{\_.f64}\left(\left(\frac{t}{y}\right), y\right)\right), x\right) \]
      19. /-lowering-/.f6499.6%

        \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, z\right), \mathsf{\_.f64}\left(\mathsf{/.f64}\left(t, y\right), y\right)\right), x\right) \]
    5. Simplified99.6%

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

      \[\leadsto \mathsf{+.f64}\left(\color{blue}{\left(\frac{-1}{3} \cdot \frac{y}{z}\right)}, x\right) \]
    7. Step-by-step derivation
      1. associate-*r/N/A

        \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{-1}{3} \cdot y}{z}\right), x\right) \]
      2. /-lowering-/.f64N/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{/.f64}\left(\left(\frac{-1}{3} \cdot y\right), z\right), x\right) \]
      3. *-commutativeN/A

        \[\leadsto \mathsf{+.f64}\left(\mathsf{/.f64}\left(\left(y \cdot \frac{-1}{3}\right), z\right), x\right) \]
      4. *-lowering-*.f6495.0%

        \[\leadsto \mathsf{+.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \frac{-1}{3}\right), z\right), x\right) \]
    8. Simplified95.0%

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

    if -2.5000000000000001e-55 < y < 2.39999999999999999e64

    1. Initial program 92.3%

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

      \[\leadsto \mathsf{+.f64}\left(\color{blue}{x}, \mathsf{/.f64}\left(t, \mathsf{*.f64}\left(\mathsf{*.f64}\left(z, 3\right), y\right)\right)\right) \]
    4. Step-by-step derivation
      1. Simplified90.2%

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

      \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -2.5 \cdot 10^{-55}:\\ \;\;\;\;x + \frac{y \cdot -0.3333333333333333}{z}\\ \mathbf{elif}\;y \leq 2.4 \cdot 10^{+64}:\\ \;\;\;\;x + \frac{t}{\left(z \cdot 3\right) \cdot y}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y \cdot -0.3333333333333333}{z}\\ \end{array} \]
    7. Add Preprocessing

    Alternative 4: 78.6% accurate, 0.8× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} t_1 := x + \frac{y \cdot -0.3333333333333333}{z}\\ \mathbf{if}\;z \leq -1.4 \cdot 10^{-69}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq 1.55 \cdot 10^{+153}:\\ \;\;\;\;\left(\frac{t}{y} - y\right) \cdot \frac{0.3333333333333333}{z}\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
    (FPCore (x y z t)
     :precision binary64
     (let* ((t_1 (+ x (/ (* y -0.3333333333333333) z))))
       (if (<= z -1.4e-69)
         t_1
         (if (<= z 1.55e+153) (* (- (/ t y) y) (/ 0.3333333333333333 z)) t_1))))
    double code(double x, double y, double z, double t) {
    	double t_1 = x + ((y * -0.3333333333333333) / z);
    	double tmp;
    	if (z <= -1.4e-69) {
    		tmp = t_1;
    	} else if (z <= 1.55e+153) {
    		tmp = ((t / y) - y) * (0.3333333333333333 / z);
    	} else {
    		tmp = t_1;
    	}
    	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) :: t_1
        real(8) :: tmp
        t_1 = x + ((y * (-0.3333333333333333d0)) / z)
        if (z <= (-1.4d-69)) then
            tmp = t_1
        else if (z <= 1.55d+153) then
            tmp = ((t / y) - y) * (0.3333333333333333d0 / z)
        else
            tmp = t_1
        end if
        code = tmp
    end function
    
    public static double code(double x, double y, double z, double t) {
    	double t_1 = x + ((y * -0.3333333333333333) / z);
    	double tmp;
    	if (z <= -1.4e-69) {
    		tmp = t_1;
    	} else if (z <= 1.55e+153) {
    		tmp = ((t / y) - y) * (0.3333333333333333 / z);
    	} else {
    		tmp = t_1;
    	}
    	return tmp;
    }
    
    def code(x, y, z, t):
    	t_1 = x + ((y * -0.3333333333333333) / z)
    	tmp = 0
    	if z <= -1.4e-69:
    		tmp = t_1
    	elif z <= 1.55e+153:
    		tmp = ((t / y) - y) * (0.3333333333333333 / z)
    	else:
    		tmp = t_1
    	return tmp
    
    function code(x, y, z, t)
    	t_1 = Float64(x + Float64(Float64(y * -0.3333333333333333) / z))
    	tmp = 0.0
    	if (z <= -1.4e-69)
    		tmp = t_1;
    	elseif (z <= 1.55e+153)
    		tmp = Float64(Float64(Float64(t / y) - y) * Float64(0.3333333333333333 / z));
    	else
    		tmp = t_1;
    	end
    	return tmp
    end
    
    function tmp_2 = code(x, y, z, t)
    	t_1 = x + ((y * -0.3333333333333333) / z);
    	tmp = 0.0;
    	if (z <= -1.4e-69)
    		tmp = t_1;
    	elseif (z <= 1.55e+153)
    		tmp = ((t / y) - y) * (0.3333333333333333 / z);
    	else
    		tmp = t_1;
    	end
    	tmp_2 = tmp;
    end
    
    code[x_, y_, z_, t_] := Block[{t$95$1 = N[(x + N[(N[(y * -0.3333333333333333), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1.4e-69], t$95$1, If[LessEqual[z, 1.55e+153], N[(N[(N[(t / y), $MachinePrecision] - y), $MachinePrecision] * N[(0.3333333333333333 / z), $MachinePrecision]), $MachinePrecision], t$95$1]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    t_1 := x + \frac{y \cdot -0.3333333333333333}{z}\\
    \mathbf{if}\;z \leq -1.4 \cdot 10^{-69}:\\
    \;\;\;\;t\_1\\
    
    \mathbf{elif}\;z \leq 1.55 \cdot 10^{+153}:\\
    \;\;\;\;\left(\frac{t}{y} - y\right) \cdot \frac{0.3333333333333333}{z}\\
    
    \mathbf{else}:\\
    \;\;\;\;t\_1\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 2 regimes
    2. if z < -1.3999999999999999e-69 or 1.55e153 < z

      1. Initial program 98.9%

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

        \[\leadsto \color{blue}{\left(x + \frac{1}{3} \cdot \frac{t}{y \cdot z}\right) - \frac{1}{3} \cdot \frac{y}{z}} \]
      4. Step-by-step derivation
        1. associate--l+N/A

          \[\leadsto x + \color{blue}{\left(\frac{1}{3} \cdot \frac{t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right)} \]
        2. +-commutativeN/A

          \[\leadsto \left(\frac{1}{3} \cdot \frac{t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right) + \color{blue}{x} \]
        3. +-lowering-+.f64N/A

          \[\leadsto \mathsf{+.f64}\left(\left(\frac{1}{3} \cdot \frac{t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right), \color{blue}{x}\right) \]
        4. associate-*r/N/A

          \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3} \cdot t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
        5. *-commutativeN/A

          \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3} \cdot t}{z \cdot y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
        6. times-fracN/A

          \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3}}{z} \cdot \frac{t}{y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
        7. metadata-evalN/A

          \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3} \cdot 1}{z} \cdot \frac{t}{y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
        8. associate-*r/N/A

          \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
        9. associate-*r/N/A

          \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{\frac{1}{3} \cdot y}{z}\right), x\right) \]
        10. associate-*l/N/A

          \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{\frac{1}{3}}{z} \cdot y\right), x\right) \]
        11. metadata-evalN/A

          \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{\frac{1}{3} \cdot 1}{z} \cdot y\right), x\right) \]
        12. associate-*r/N/A

          \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot y\right), x\right) \]
        13. distribute-lft-out--N/A

          \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \left(\frac{t}{y} - y\right)\right), x\right) \]
        14. *-lowering-*.f64N/A

          \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
        15. associate-*r/N/A

          \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\left(\frac{\frac{1}{3} \cdot 1}{z}\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
        16. metadata-evalN/A

          \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\left(\frac{\frac{1}{3}}{z}\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
        17. /-lowering-/.f64N/A

          \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, z\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
        18. --lowering--.f64N/A

          \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, z\right), \mathsf{\_.f64}\left(\left(\frac{t}{y}\right), y\right)\right), x\right) \]
        19. /-lowering-/.f6488.0%

          \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, z\right), \mathsf{\_.f64}\left(\mathsf{/.f64}\left(t, y\right), y\right)\right), x\right) \]
      5. Simplified88.0%

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

        \[\leadsto \mathsf{+.f64}\left(\color{blue}{\left(\frac{-1}{3} \cdot \frac{y}{z}\right)}, x\right) \]
      7. Step-by-step derivation
        1. associate-*r/N/A

          \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{-1}{3} \cdot y}{z}\right), x\right) \]
        2. /-lowering-/.f64N/A

          \[\leadsto \mathsf{+.f64}\left(\mathsf{/.f64}\left(\left(\frac{-1}{3} \cdot y\right), z\right), x\right) \]
        3. *-commutativeN/A

          \[\leadsto \mathsf{+.f64}\left(\mathsf{/.f64}\left(\left(y \cdot \frac{-1}{3}\right), z\right), x\right) \]
        4. *-lowering-*.f6478.6%

          \[\leadsto \mathsf{+.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \frac{-1}{3}\right), z\right), x\right) \]
      8. Simplified78.6%

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

      if -1.3999999999999999e-69 < z < 1.55e153

      1. Initial program 93.9%

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

        \[\leadsto \color{blue}{\frac{1}{3} \cdot \frac{t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}} \]
      4. Step-by-step derivation
        1. associate-*r/N/A

          \[\leadsto \frac{\frac{1}{3} \cdot t}{y \cdot z} - \color{blue}{\frac{1}{3}} \cdot \frac{y}{z} \]
        2. *-commutativeN/A

          \[\leadsto \frac{\frac{1}{3} \cdot t}{z \cdot y} - \frac{1}{3} \cdot \frac{y}{z} \]
        3. times-fracN/A

          \[\leadsto \frac{\frac{1}{3}}{z} \cdot \frac{t}{y} - \color{blue}{\frac{1}{3}} \cdot \frac{y}{z} \]
        4. metadata-evalN/A

          \[\leadsto \frac{\frac{1}{3} \cdot 1}{z} \cdot \frac{t}{y} - \frac{1}{3} \cdot \frac{y}{z} \]
        5. associate-*r/N/A

          \[\leadsto \left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{1}{3} \cdot \frac{y}{z} \]
        6. associate-*r/N/A

          \[\leadsto \left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{\frac{1}{3} \cdot y}{\color{blue}{z}} \]
        7. associate-*l/N/A

          \[\leadsto \left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{\frac{1}{3}}{z} \cdot \color{blue}{y} \]
        8. metadata-evalN/A

          \[\leadsto \left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{\frac{1}{3} \cdot 1}{z} \cdot y \]
        9. associate-*r/N/A

          \[\leadsto \left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot y \]
        10. distribute-lft-out--N/A

          \[\leadsto \left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \color{blue}{\left(\frac{t}{y} - y\right)} \]
        11. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right), \color{blue}{\left(\frac{t}{y} - y\right)}\right) \]
        12. associate-*r/N/A

          \[\leadsto \mathsf{*.f64}\left(\left(\frac{\frac{1}{3} \cdot 1}{z}\right), \left(\color{blue}{\frac{t}{y}} - y\right)\right) \]
        13. metadata-evalN/A

          \[\leadsto \mathsf{*.f64}\left(\left(\frac{\frac{1}{3}}{z}\right), \left(\frac{\color{blue}{t}}{y} - y\right)\right) \]
        14. /-lowering-/.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, z\right), \left(\color{blue}{\frac{t}{y}} - y\right)\right) \]
        15. --lowering--.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, z\right), \mathsf{\_.f64}\left(\left(\frac{t}{y}\right), \color{blue}{y}\right)\right) \]
        16. /-lowering-/.f6490.4%

          \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, z\right), \mathsf{\_.f64}\left(\mathsf{/.f64}\left(t, y\right), y\right)\right) \]
      5. Simplified90.4%

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

      \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.4 \cdot 10^{-69}:\\ \;\;\;\;x + \frac{y \cdot -0.3333333333333333}{z}\\ \mathbf{elif}\;z \leq 1.55 \cdot 10^{+153}:\\ \;\;\;\;\left(\frac{t}{y} - y\right) \cdot \frac{0.3333333333333333}{z}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y \cdot -0.3333333333333333}{z}\\ \end{array} \]
    5. Add Preprocessing

    Alternative 5: 76.7% accurate, 0.9× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} t_1 := x + \frac{y \cdot -0.3333333333333333}{z}\\ \mathbf{if}\;y \leq -1.85 \cdot 10^{-57}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \leq 2.95 \cdot 10^{+48}:\\ \;\;\;\;\frac{\frac{\frac{t}{z}}{3}}{y}\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
    (FPCore (x y z t)
     :precision binary64
     (let* ((t_1 (+ x (/ (* y -0.3333333333333333) z))))
       (if (<= y -1.85e-57) t_1 (if (<= y 2.95e+48) (/ (/ (/ t z) 3.0) y) t_1))))
    double code(double x, double y, double z, double t) {
    	double t_1 = x + ((y * -0.3333333333333333) / z);
    	double tmp;
    	if (y <= -1.85e-57) {
    		tmp = t_1;
    	} else if (y <= 2.95e+48) {
    		tmp = ((t / z) / 3.0) / y;
    	} else {
    		tmp = t_1;
    	}
    	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) :: t_1
        real(8) :: tmp
        t_1 = x + ((y * (-0.3333333333333333d0)) / z)
        if (y <= (-1.85d-57)) then
            tmp = t_1
        else if (y <= 2.95d+48) then
            tmp = ((t / z) / 3.0d0) / y
        else
            tmp = t_1
        end if
        code = tmp
    end function
    
    public static double code(double x, double y, double z, double t) {
    	double t_1 = x + ((y * -0.3333333333333333) / z);
    	double tmp;
    	if (y <= -1.85e-57) {
    		tmp = t_1;
    	} else if (y <= 2.95e+48) {
    		tmp = ((t / z) / 3.0) / y;
    	} else {
    		tmp = t_1;
    	}
    	return tmp;
    }
    
    def code(x, y, z, t):
    	t_1 = x + ((y * -0.3333333333333333) / z)
    	tmp = 0
    	if y <= -1.85e-57:
    		tmp = t_1
    	elif y <= 2.95e+48:
    		tmp = ((t / z) / 3.0) / y
    	else:
    		tmp = t_1
    	return tmp
    
    function code(x, y, z, t)
    	t_1 = Float64(x + Float64(Float64(y * -0.3333333333333333) / z))
    	tmp = 0.0
    	if (y <= -1.85e-57)
    		tmp = t_1;
    	elseif (y <= 2.95e+48)
    		tmp = Float64(Float64(Float64(t / z) / 3.0) / y);
    	else
    		tmp = t_1;
    	end
    	return tmp
    end
    
    function tmp_2 = code(x, y, z, t)
    	t_1 = x + ((y * -0.3333333333333333) / z);
    	tmp = 0.0;
    	if (y <= -1.85e-57)
    		tmp = t_1;
    	elseif (y <= 2.95e+48)
    		tmp = ((t / z) / 3.0) / y;
    	else
    		tmp = t_1;
    	end
    	tmp_2 = tmp;
    end
    
    code[x_, y_, z_, t_] := Block[{t$95$1 = N[(x + N[(N[(y * -0.3333333333333333), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -1.85e-57], t$95$1, If[LessEqual[y, 2.95e+48], N[(N[(N[(t / z), $MachinePrecision] / 3.0), $MachinePrecision] / y), $MachinePrecision], t$95$1]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    t_1 := x + \frac{y \cdot -0.3333333333333333}{z}\\
    \mathbf{if}\;y \leq -1.85 \cdot 10^{-57}:\\
    \;\;\;\;t\_1\\
    
    \mathbf{elif}\;y \leq 2.95 \cdot 10^{+48}:\\
    \;\;\;\;\frac{\frac{\frac{t}{z}}{3}}{y}\\
    
    \mathbf{else}:\\
    \;\;\;\;t\_1\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 2 regimes
    2. if y < -1.85e-57 or 2.95000000000000025e48 < y

      1. Initial program 99.1%

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

        \[\leadsto \color{blue}{\left(x + \frac{1}{3} \cdot \frac{t}{y \cdot z}\right) - \frac{1}{3} \cdot \frac{y}{z}} \]
      4. Step-by-step derivation
        1. associate--l+N/A

          \[\leadsto x + \color{blue}{\left(\frac{1}{3} \cdot \frac{t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right)} \]
        2. +-commutativeN/A

          \[\leadsto \left(\frac{1}{3} \cdot \frac{t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right) + \color{blue}{x} \]
        3. +-lowering-+.f64N/A

          \[\leadsto \mathsf{+.f64}\left(\left(\frac{1}{3} \cdot \frac{t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right), \color{blue}{x}\right) \]
        4. associate-*r/N/A

          \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3} \cdot t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
        5. *-commutativeN/A

          \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3} \cdot t}{z \cdot y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
        6. times-fracN/A

          \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3}}{z} \cdot \frac{t}{y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
        7. metadata-evalN/A

          \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3} \cdot 1}{z} \cdot \frac{t}{y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
        8. associate-*r/N/A

          \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
        9. associate-*r/N/A

          \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{\frac{1}{3} \cdot y}{z}\right), x\right) \]
        10. associate-*l/N/A

          \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{\frac{1}{3}}{z} \cdot y\right), x\right) \]
        11. metadata-evalN/A

          \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{\frac{1}{3} \cdot 1}{z} \cdot y\right), x\right) \]
        12. associate-*r/N/A

          \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot y\right), x\right) \]
        13. distribute-lft-out--N/A

          \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \left(\frac{t}{y} - y\right)\right), x\right) \]
        14. *-lowering-*.f64N/A

          \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
        15. associate-*r/N/A

          \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\left(\frac{\frac{1}{3} \cdot 1}{z}\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
        16. metadata-evalN/A

          \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\left(\frac{\frac{1}{3}}{z}\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
        17. /-lowering-/.f64N/A

          \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, z\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
        18. --lowering--.f64N/A

          \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, z\right), \mathsf{\_.f64}\left(\left(\frac{t}{y}\right), y\right)\right), x\right) \]
        19. /-lowering-/.f6499.6%

          \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, z\right), \mathsf{\_.f64}\left(\mathsf{/.f64}\left(t, y\right), y\right)\right), x\right) \]
      5. Simplified99.6%

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

        \[\leadsto \mathsf{+.f64}\left(\color{blue}{\left(\frac{-1}{3} \cdot \frac{y}{z}\right)}, x\right) \]
      7. Step-by-step derivation
        1. associate-*r/N/A

          \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{-1}{3} \cdot y}{z}\right), x\right) \]
        2. /-lowering-/.f64N/A

          \[\leadsto \mathsf{+.f64}\left(\mathsf{/.f64}\left(\left(\frac{-1}{3} \cdot y\right), z\right), x\right) \]
        3. *-commutativeN/A

          \[\leadsto \mathsf{+.f64}\left(\mathsf{/.f64}\left(\left(y \cdot \frac{-1}{3}\right), z\right), x\right) \]
        4. *-lowering-*.f6494.3%

          \[\leadsto \mathsf{+.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \frac{-1}{3}\right), z\right), x\right) \]
      8. Simplified94.3%

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

      if -1.85e-57 < y < 2.95000000000000025e48

      1. Initial program 92.2%

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

        \[\leadsto \color{blue}{\frac{1}{3} \cdot \frac{t}{y \cdot z}} \]
      4. Step-by-step derivation
        1. associate-/l/N/A

          \[\leadsto \frac{1}{3} \cdot \frac{\frac{t}{z}}{\color{blue}{y}} \]
        2. associate-*r/N/A

          \[\leadsto \frac{\frac{1}{3} \cdot \frac{t}{z}}{\color{blue}{y}} \]
        3. /-lowering-/.f64N/A

          \[\leadsto \mathsf{/.f64}\left(\left(\frac{1}{3} \cdot \frac{t}{z}\right), \color{blue}{y}\right) \]
        4. associate-*r/N/A

          \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{1}{3} \cdot t}{z}\right), y\right) \]
        5. /-lowering-/.f64N/A

          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\left(\frac{1}{3} \cdot t\right), z\right), y\right) \]
        6. *-lowering-*.f6464.3%

          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\frac{1}{3}, t\right), z\right), y\right) \]
      5. Simplified64.3%

        \[\leadsto \color{blue}{\frac{\frac{0.3333333333333333 \cdot t}{z}}{y}} \]
      6. Step-by-step derivation
        1. clear-numN/A

          \[\leadsto \mathsf{/.f64}\left(\left(\frac{1}{\frac{z}{\frac{1}{3} \cdot t}}\right), y\right) \]
        2. associate-/r*N/A

          \[\leadsto \mathsf{/.f64}\left(\left(\frac{1}{\frac{\frac{z}{\frac{1}{3}}}{t}}\right), y\right) \]
        3. div-invN/A

          \[\leadsto \mathsf{/.f64}\left(\left(\frac{1}{\frac{z \cdot \frac{1}{\frac{1}{3}}}{t}}\right), y\right) \]
        4. metadata-evalN/A

          \[\leadsto \mathsf{/.f64}\left(\left(\frac{1}{\frac{z \cdot 3}{t}}\right), y\right) \]
        5. clear-numN/A

          \[\leadsto \mathsf{/.f64}\left(\left(\frac{t}{z \cdot 3}\right), y\right) \]
        6. associate-/r*N/A

          \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{t}{z}}{3}\right), y\right) \]
        7. /-lowering-/.f64N/A

          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\left(\frac{t}{z}\right), 3\right), y\right) \]
        8. /-lowering-/.f6464.4%

          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{/.f64}\left(t, z\right), 3\right), y\right) \]
      7. Applied egg-rr64.4%

        \[\leadsto \frac{\color{blue}{\frac{\frac{t}{z}}{3}}}{y} \]
    3. Recombined 2 regimes into one program.
    4. Final simplification81.0%

      \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -1.85 \cdot 10^{-57}:\\ \;\;\;\;x + \frac{y \cdot -0.3333333333333333}{z}\\ \mathbf{elif}\;y \leq 2.95 \cdot 10^{+48}:\\ \;\;\;\;\frac{\frac{\frac{t}{z}}{3}}{y}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y \cdot -0.3333333333333333}{z}\\ \end{array} \]
    5. Add Preprocessing

    Alternative 6: 76.7% accurate, 0.9× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} t_1 := x + \frac{y \cdot -0.3333333333333333}{z}\\ \mathbf{if}\;y \leq -2.4 \cdot 10^{-57}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \leq 2.95 \cdot 10^{+48}:\\ \;\;\;\;\frac{t}{z} \cdot \frac{0.3333333333333333}{y}\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
    (FPCore (x y z t)
     :precision binary64
     (let* ((t_1 (+ x (/ (* y -0.3333333333333333) z))))
       (if (<= y -2.4e-57)
         t_1
         (if (<= y 2.95e+48) (* (/ t z) (/ 0.3333333333333333 y)) t_1))))
    double code(double x, double y, double z, double t) {
    	double t_1 = x + ((y * -0.3333333333333333) / z);
    	double tmp;
    	if (y <= -2.4e-57) {
    		tmp = t_1;
    	} else if (y <= 2.95e+48) {
    		tmp = (t / z) * (0.3333333333333333 / y);
    	} else {
    		tmp = t_1;
    	}
    	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) :: t_1
        real(8) :: tmp
        t_1 = x + ((y * (-0.3333333333333333d0)) / z)
        if (y <= (-2.4d-57)) then
            tmp = t_1
        else if (y <= 2.95d+48) then
            tmp = (t / z) * (0.3333333333333333d0 / y)
        else
            tmp = t_1
        end if
        code = tmp
    end function
    
    public static double code(double x, double y, double z, double t) {
    	double t_1 = x + ((y * -0.3333333333333333) / z);
    	double tmp;
    	if (y <= -2.4e-57) {
    		tmp = t_1;
    	} else if (y <= 2.95e+48) {
    		tmp = (t / z) * (0.3333333333333333 / y);
    	} else {
    		tmp = t_1;
    	}
    	return tmp;
    }
    
    def code(x, y, z, t):
    	t_1 = x + ((y * -0.3333333333333333) / z)
    	tmp = 0
    	if y <= -2.4e-57:
    		tmp = t_1
    	elif y <= 2.95e+48:
    		tmp = (t / z) * (0.3333333333333333 / y)
    	else:
    		tmp = t_1
    	return tmp
    
    function code(x, y, z, t)
    	t_1 = Float64(x + Float64(Float64(y * -0.3333333333333333) / z))
    	tmp = 0.0
    	if (y <= -2.4e-57)
    		tmp = t_1;
    	elseif (y <= 2.95e+48)
    		tmp = Float64(Float64(t / z) * Float64(0.3333333333333333 / y));
    	else
    		tmp = t_1;
    	end
    	return tmp
    end
    
    function tmp_2 = code(x, y, z, t)
    	t_1 = x + ((y * -0.3333333333333333) / z);
    	tmp = 0.0;
    	if (y <= -2.4e-57)
    		tmp = t_1;
    	elseif (y <= 2.95e+48)
    		tmp = (t / z) * (0.3333333333333333 / y);
    	else
    		tmp = t_1;
    	end
    	tmp_2 = tmp;
    end
    
    code[x_, y_, z_, t_] := Block[{t$95$1 = N[(x + N[(N[(y * -0.3333333333333333), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -2.4e-57], t$95$1, If[LessEqual[y, 2.95e+48], N[(N[(t / z), $MachinePrecision] * N[(0.3333333333333333 / y), $MachinePrecision]), $MachinePrecision], t$95$1]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    t_1 := x + \frac{y \cdot -0.3333333333333333}{z}\\
    \mathbf{if}\;y \leq -2.4 \cdot 10^{-57}:\\
    \;\;\;\;t\_1\\
    
    \mathbf{elif}\;y \leq 2.95 \cdot 10^{+48}:\\
    \;\;\;\;\frac{t}{z} \cdot \frac{0.3333333333333333}{y}\\
    
    \mathbf{else}:\\
    \;\;\;\;t\_1\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 2 regimes
    2. if y < -2.40000000000000006e-57 or 2.95000000000000025e48 < y

      1. Initial program 99.1%

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

        \[\leadsto \color{blue}{\left(x + \frac{1}{3} \cdot \frac{t}{y \cdot z}\right) - \frac{1}{3} \cdot \frac{y}{z}} \]
      4. Step-by-step derivation
        1. associate--l+N/A

          \[\leadsto x + \color{blue}{\left(\frac{1}{3} \cdot \frac{t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right)} \]
        2. +-commutativeN/A

          \[\leadsto \left(\frac{1}{3} \cdot \frac{t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right) + \color{blue}{x} \]
        3. +-lowering-+.f64N/A

          \[\leadsto \mathsf{+.f64}\left(\left(\frac{1}{3} \cdot \frac{t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right), \color{blue}{x}\right) \]
        4. associate-*r/N/A

          \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3} \cdot t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
        5. *-commutativeN/A

          \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3} \cdot t}{z \cdot y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
        6. times-fracN/A

          \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3}}{z} \cdot \frac{t}{y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
        7. metadata-evalN/A

          \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3} \cdot 1}{z} \cdot \frac{t}{y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
        8. associate-*r/N/A

          \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
        9. associate-*r/N/A

          \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{\frac{1}{3} \cdot y}{z}\right), x\right) \]
        10. associate-*l/N/A

          \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{\frac{1}{3}}{z} \cdot y\right), x\right) \]
        11. metadata-evalN/A

          \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{\frac{1}{3} \cdot 1}{z} \cdot y\right), x\right) \]
        12. associate-*r/N/A

          \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot y\right), x\right) \]
        13. distribute-lft-out--N/A

          \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \left(\frac{t}{y} - y\right)\right), x\right) \]
        14. *-lowering-*.f64N/A

          \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
        15. associate-*r/N/A

          \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\left(\frac{\frac{1}{3} \cdot 1}{z}\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
        16. metadata-evalN/A

          \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\left(\frac{\frac{1}{3}}{z}\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
        17. /-lowering-/.f64N/A

          \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, z\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
        18. --lowering--.f64N/A

          \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, z\right), \mathsf{\_.f64}\left(\left(\frac{t}{y}\right), y\right)\right), x\right) \]
        19. /-lowering-/.f6499.6%

          \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, z\right), \mathsf{\_.f64}\left(\mathsf{/.f64}\left(t, y\right), y\right)\right), x\right) \]
      5. Simplified99.6%

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

        \[\leadsto \mathsf{+.f64}\left(\color{blue}{\left(\frac{-1}{3} \cdot \frac{y}{z}\right)}, x\right) \]
      7. Step-by-step derivation
        1. associate-*r/N/A

          \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{-1}{3} \cdot y}{z}\right), x\right) \]
        2. /-lowering-/.f64N/A

          \[\leadsto \mathsf{+.f64}\left(\mathsf{/.f64}\left(\left(\frac{-1}{3} \cdot y\right), z\right), x\right) \]
        3. *-commutativeN/A

          \[\leadsto \mathsf{+.f64}\left(\mathsf{/.f64}\left(\left(y \cdot \frac{-1}{3}\right), z\right), x\right) \]
        4. *-lowering-*.f6494.3%

          \[\leadsto \mathsf{+.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \frac{-1}{3}\right), z\right), x\right) \]
      8. Simplified94.3%

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

      if -2.40000000000000006e-57 < y < 2.95000000000000025e48

      1. Initial program 92.2%

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

        \[\leadsto \color{blue}{\frac{1}{3} \cdot \frac{t}{y \cdot z}} \]
      4. Step-by-step derivation
        1. associate-/l/N/A

          \[\leadsto \frac{1}{3} \cdot \frac{\frac{t}{z}}{\color{blue}{y}} \]
        2. associate-*r/N/A

          \[\leadsto \frac{\frac{1}{3} \cdot \frac{t}{z}}{\color{blue}{y}} \]
        3. /-lowering-/.f64N/A

          \[\leadsto \mathsf{/.f64}\left(\left(\frac{1}{3} \cdot \frac{t}{z}\right), \color{blue}{y}\right) \]
        4. associate-*r/N/A

          \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{1}{3} \cdot t}{z}\right), y\right) \]
        5. /-lowering-/.f64N/A

          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\left(\frac{1}{3} \cdot t\right), z\right), y\right) \]
        6. *-lowering-*.f6464.3%

          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\frac{1}{3}, t\right), z\right), y\right) \]
      5. Simplified64.3%

        \[\leadsto \color{blue}{\frac{\frac{0.3333333333333333 \cdot t}{z}}{y}} \]
      6. Step-by-step derivation
        1. associate-/l/N/A

          \[\leadsto \frac{\frac{1}{3} \cdot t}{\color{blue}{y \cdot z}} \]
        2. *-commutativeN/A

          \[\leadsto \frac{t \cdot \frac{1}{3}}{\color{blue}{y} \cdot z} \]
        3. *-commutativeN/A

          \[\leadsto \frac{t \cdot \frac{1}{3}}{z \cdot \color{blue}{y}} \]
        4. times-fracN/A

          \[\leadsto \frac{t}{z} \cdot \color{blue}{\frac{\frac{1}{3}}{y}} \]
        5. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\left(\frac{t}{z}\right), \color{blue}{\left(\frac{\frac{1}{3}}{y}\right)}\right) \]
        6. /-lowering-/.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(t, z\right), \left(\frac{\color{blue}{\frac{1}{3}}}{y}\right)\right) \]
        7. /-lowering-/.f6464.4%

          \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(t, z\right), \mathsf{/.f64}\left(\frac{1}{3}, \color{blue}{y}\right)\right) \]
      7. Applied egg-rr64.4%

        \[\leadsto \color{blue}{\frac{t}{z} \cdot \frac{0.3333333333333333}{y}} \]
    3. Recombined 2 regimes into one program.
    4. Final simplification81.0%

      \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -2.4 \cdot 10^{-57}:\\ \;\;\;\;x + \frac{y \cdot -0.3333333333333333}{z}\\ \mathbf{elif}\;y \leq 2.95 \cdot 10^{+48}:\\ \;\;\;\;\frac{t}{z} \cdot \frac{0.3333333333333333}{y}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y \cdot -0.3333333333333333}{z}\\ \end{array} \]
    5. Add Preprocessing

    Alternative 7: 76.7% accurate, 0.9× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} t_1 := x + y \cdot \frac{-0.3333333333333333}{z}\\ \mathbf{if}\;y \leq -2.5 \cdot 10^{-58}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \leq 2.95 \cdot 10^{+48}:\\ \;\;\;\;\frac{t}{z} \cdot \frac{0.3333333333333333}{y}\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
    (FPCore (x y z t)
     :precision binary64
     (let* ((t_1 (+ x (* y (/ -0.3333333333333333 z)))))
       (if (<= y -2.5e-58)
         t_1
         (if (<= y 2.95e+48) (* (/ t z) (/ 0.3333333333333333 y)) t_1))))
    double code(double x, double y, double z, double t) {
    	double t_1 = x + (y * (-0.3333333333333333 / z));
    	double tmp;
    	if (y <= -2.5e-58) {
    		tmp = t_1;
    	} else if (y <= 2.95e+48) {
    		tmp = (t / z) * (0.3333333333333333 / y);
    	} else {
    		tmp = t_1;
    	}
    	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) :: t_1
        real(8) :: tmp
        t_1 = x + (y * ((-0.3333333333333333d0) / z))
        if (y <= (-2.5d-58)) then
            tmp = t_1
        else if (y <= 2.95d+48) then
            tmp = (t / z) * (0.3333333333333333d0 / y)
        else
            tmp = t_1
        end if
        code = tmp
    end function
    
    public static double code(double x, double y, double z, double t) {
    	double t_1 = x + (y * (-0.3333333333333333 / z));
    	double tmp;
    	if (y <= -2.5e-58) {
    		tmp = t_1;
    	} else if (y <= 2.95e+48) {
    		tmp = (t / z) * (0.3333333333333333 / y);
    	} else {
    		tmp = t_1;
    	}
    	return tmp;
    }
    
    def code(x, y, z, t):
    	t_1 = x + (y * (-0.3333333333333333 / z))
    	tmp = 0
    	if y <= -2.5e-58:
    		tmp = t_1
    	elif y <= 2.95e+48:
    		tmp = (t / z) * (0.3333333333333333 / y)
    	else:
    		tmp = t_1
    	return tmp
    
    function code(x, y, z, t)
    	t_1 = Float64(x + Float64(y * Float64(-0.3333333333333333 / z)))
    	tmp = 0.0
    	if (y <= -2.5e-58)
    		tmp = t_1;
    	elseif (y <= 2.95e+48)
    		tmp = Float64(Float64(t / z) * Float64(0.3333333333333333 / y));
    	else
    		tmp = t_1;
    	end
    	return tmp
    end
    
    function tmp_2 = code(x, y, z, t)
    	t_1 = x + (y * (-0.3333333333333333 / z));
    	tmp = 0.0;
    	if (y <= -2.5e-58)
    		tmp = t_1;
    	elseif (y <= 2.95e+48)
    		tmp = (t / z) * (0.3333333333333333 / y);
    	else
    		tmp = t_1;
    	end
    	tmp_2 = tmp;
    end
    
    code[x_, y_, z_, t_] := Block[{t$95$1 = N[(x + N[(y * N[(-0.3333333333333333 / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -2.5e-58], t$95$1, If[LessEqual[y, 2.95e+48], N[(N[(t / z), $MachinePrecision] * N[(0.3333333333333333 / y), $MachinePrecision]), $MachinePrecision], t$95$1]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    t_1 := x + y \cdot \frac{-0.3333333333333333}{z}\\
    \mathbf{if}\;y \leq -2.5 \cdot 10^{-58}:\\
    \;\;\;\;t\_1\\
    
    \mathbf{elif}\;y \leq 2.95 \cdot 10^{+48}:\\
    \;\;\;\;\frac{t}{z} \cdot \frac{0.3333333333333333}{y}\\
    
    \mathbf{else}:\\
    \;\;\;\;t\_1\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 2 regimes
    2. if y < -2.49999999999999989e-58 or 2.95000000000000025e48 < y

      1. Initial program 99.1%

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

        \[\leadsto \color{blue}{y \cdot \left(\frac{x}{y} - \frac{1}{3} \cdot \frac{1}{z}\right)} \]
      4. Step-by-step derivation
        1. sub-negN/A

          \[\leadsto y \cdot \left(\frac{x}{y} + \color{blue}{\left(\mathsf{neg}\left(\frac{1}{3} \cdot \frac{1}{z}\right)\right)}\right) \]
        2. +-commutativeN/A

          \[\leadsto y \cdot \left(\left(\mathsf{neg}\left(\frac{1}{3} \cdot \frac{1}{z}\right)\right) + \color{blue}{\frac{x}{y}}\right) \]
        3. distribute-rgt-inN/A

          \[\leadsto \left(\mathsf{neg}\left(\frac{1}{3} \cdot \frac{1}{z}\right)\right) \cdot y + \color{blue}{\frac{x}{y} \cdot y} \]
        4. associate-*r/N/A

          \[\leadsto \left(\mathsf{neg}\left(\frac{\frac{1}{3} \cdot 1}{z}\right)\right) \cdot y + \frac{x}{y} \cdot y \]
        5. metadata-evalN/A

          \[\leadsto \left(\mathsf{neg}\left(\frac{\frac{1}{3}}{z}\right)\right) \cdot y + \frac{x}{y} \cdot y \]
        6. distribute-neg-fracN/A

          \[\leadsto \frac{\mathsf{neg}\left(\frac{1}{3}\right)}{z} \cdot y + \frac{\color{blue}{x}}{y} \cdot y \]
        7. metadata-evalN/A

          \[\leadsto \frac{\frac{-1}{3}}{z} \cdot y + \frac{x}{y} \cdot y \]
        8. associate-*l/N/A

          \[\leadsto \frac{\frac{-1}{3} \cdot y}{z} + \color{blue}{\frac{x}{y}} \cdot y \]
        9. associate-*r/N/A

          \[\leadsto \frac{-1}{3} \cdot \frac{y}{z} + \color{blue}{\frac{x}{y}} \cdot y \]
        10. cancel-sign-subN/A

          \[\leadsto \frac{-1}{3} \cdot \frac{y}{z} - \color{blue}{\left(\mathsf{neg}\left(\frac{x}{y}\right)\right) \cdot y} \]
        11. mul-1-negN/A

          \[\leadsto \frac{-1}{3} \cdot \frac{y}{z} - \left(-1 \cdot \frac{x}{y}\right) \cdot y \]
        12. associate-*r/N/A

          \[\leadsto \frac{-1}{3} \cdot \frac{y}{z} - \frac{-1 \cdot x}{y} \cdot y \]
        13. associate-*l/N/A

          \[\leadsto \frac{-1}{3} \cdot \frac{y}{z} - \frac{\left(-1 \cdot x\right) \cdot y}{\color{blue}{y}} \]
        14. associate-/l*N/A

          \[\leadsto \frac{-1}{3} \cdot \frac{y}{z} - \left(-1 \cdot x\right) \cdot \color{blue}{\frac{y}{y}} \]
        15. mul-1-negN/A

          \[\leadsto \frac{-1}{3} \cdot \frac{y}{z} - \left(\mathsf{neg}\left(x\right)\right) \cdot \frac{\color{blue}{y}}{y} \]
        16. *-inversesN/A

          \[\leadsto \frac{-1}{3} \cdot \frac{y}{z} - \left(\mathsf{neg}\left(x\right)\right) \cdot 1 \]
        17. cancel-sign-subN/A

          \[\leadsto \frac{-1}{3} \cdot \frac{y}{z} + \color{blue}{x \cdot 1} \]
        18. *-rgt-identityN/A

          \[\leadsto \frac{-1}{3} \cdot \frac{y}{z} + x \]
        19. +-commutativeN/A

          \[\leadsto x + \color{blue}{\frac{-1}{3} \cdot \frac{y}{z}} \]
        20. +-lowering-+.f64N/A

          \[\leadsto \mathsf{+.f64}\left(x, \color{blue}{\left(\frac{-1}{3} \cdot \frac{y}{z}\right)}\right) \]
        21. associate-*r/N/A

          \[\leadsto \mathsf{+.f64}\left(x, \left(\frac{\frac{-1}{3} \cdot y}{\color{blue}{z}}\right)\right) \]
        22. *-commutativeN/A

          \[\leadsto \mathsf{+.f64}\left(x, \left(\frac{y \cdot \frac{-1}{3}}{z}\right)\right) \]
        23. associate-/l*N/A

          \[\leadsto \mathsf{+.f64}\left(x, \left(y \cdot \color{blue}{\frac{\frac{-1}{3}}{z}}\right)\right) \]
      5. Simplified94.3%

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

      if -2.49999999999999989e-58 < y < 2.95000000000000025e48

      1. Initial program 92.2%

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

        \[\leadsto \color{blue}{\frac{1}{3} \cdot \frac{t}{y \cdot z}} \]
      4. Step-by-step derivation
        1. associate-/l/N/A

          \[\leadsto \frac{1}{3} \cdot \frac{\frac{t}{z}}{\color{blue}{y}} \]
        2. associate-*r/N/A

          \[\leadsto \frac{\frac{1}{3} \cdot \frac{t}{z}}{\color{blue}{y}} \]
        3. /-lowering-/.f64N/A

          \[\leadsto \mathsf{/.f64}\left(\left(\frac{1}{3} \cdot \frac{t}{z}\right), \color{blue}{y}\right) \]
        4. associate-*r/N/A

          \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{1}{3} \cdot t}{z}\right), y\right) \]
        5. /-lowering-/.f64N/A

          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\left(\frac{1}{3} \cdot t\right), z\right), y\right) \]
        6. *-lowering-*.f6464.3%

          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\frac{1}{3}, t\right), z\right), y\right) \]
      5. Simplified64.3%

        \[\leadsto \color{blue}{\frac{\frac{0.3333333333333333 \cdot t}{z}}{y}} \]
      6. Step-by-step derivation
        1. associate-/l/N/A

          \[\leadsto \frac{\frac{1}{3} \cdot t}{\color{blue}{y \cdot z}} \]
        2. *-commutativeN/A

          \[\leadsto \frac{t \cdot \frac{1}{3}}{\color{blue}{y} \cdot z} \]
        3. *-commutativeN/A

          \[\leadsto \frac{t \cdot \frac{1}{3}}{z \cdot \color{blue}{y}} \]
        4. times-fracN/A

          \[\leadsto \frac{t}{z} \cdot \color{blue}{\frac{\frac{1}{3}}{y}} \]
        5. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\left(\frac{t}{z}\right), \color{blue}{\left(\frac{\frac{1}{3}}{y}\right)}\right) \]
        6. /-lowering-/.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(t, z\right), \left(\frac{\color{blue}{\frac{1}{3}}}{y}\right)\right) \]
        7. /-lowering-/.f6464.4%

          \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(t, z\right), \mathsf{/.f64}\left(\frac{1}{3}, \color{blue}{y}\right)\right) \]
      7. Applied egg-rr64.4%

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

    Alternative 8: 64.5% accurate, 0.9× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{\frac{y}{z}}{-3}\\ \mathbf{if}\;y \leq -0.0015:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \leq 3 \cdot 10^{+53}:\\ \;\;\;\;\frac{t}{z} \cdot \frac{0.3333333333333333}{y}\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
    (FPCore (x y z t)
     :precision binary64
     (let* ((t_1 (/ (/ y z) -3.0)))
       (if (<= y -0.0015)
         t_1
         (if (<= y 3e+53) (* (/ t z) (/ 0.3333333333333333 y)) t_1))))
    double code(double x, double y, double z, double t) {
    	double t_1 = (y / z) / -3.0;
    	double tmp;
    	if (y <= -0.0015) {
    		tmp = t_1;
    	} else if (y <= 3e+53) {
    		tmp = (t / z) * (0.3333333333333333 / y);
    	} else {
    		tmp = t_1;
    	}
    	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) :: t_1
        real(8) :: tmp
        t_1 = (y / z) / (-3.0d0)
        if (y <= (-0.0015d0)) then
            tmp = t_1
        else if (y <= 3d+53) then
            tmp = (t / z) * (0.3333333333333333d0 / y)
        else
            tmp = t_1
        end if
        code = tmp
    end function
    
    public static double code(double x, double y, double z, double t) {
    	double t_1 = (y / z) / -3.0;
    	double tmp;
    	if (y <= -0.0015) {
    		tmp = t_1;
    	} else if (y <= 3e+53) {
    		tmp = (t / z) * (0.3333333333333333 / y);
    	} else {
    		tmp = t_1;
    	}
    	return tmp;
    }
    
    def code(x, y, z, t):
    	t_1 = (y / z) / -3.0
    	tmp = 0
    	if y <= -0.0015:
    		tmp = t_1
    	elif y <= 3e+53:
    		tmp = (t / z) * (0.3333333333333333 / y)
    	else:
    		tmp = t_1
    	return tmp
    
    function code(x, y, z, t)
    	t_1 = Float64(Float64(y / z) / -3.0)
    	tmp = 0.0
    	if (y <= -0.0015)
    		tmp = t_1;
    	elseif (y <= 3e+53)
    		tmp = Float64(Float64(t / z) * Float64(0.3333333333333333 / y));
    	else
    		tmp = t_1;
    	end
    	return tmp
    end
    
    function tmp_2 = code(x, y, z, t)
    	t_1 = (y / z) / -3.0;
    	tmp = 0.0;
    	if (y <= -0.0015)
    		tmp = t_1;
    	elseif (y <= 3e+53)
    		tmp = (t / z) * (0.3333333333333333 / y);
    	else
    		tmp = t_1;
    	end
    	tmp_2 = tmp;
    end
    
    code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(y / z), $MachinePrecision] / -3.0), $MachinePrecision]}, If[LessEqual[y, -0.0015], t$95$1, If[LessEqual[y, 3e+53], N[(N[(t / z), $MachinePrecision] * N[(0.3333333333333333 / y), $MachinePrecision]), $MachinePrecision], t$95$1]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    t_1 := \frac{\frac{y}{z}}{-3}\\
    \mathbf{if}\;y \leq -0.0015:\\
    \;\;\;\;t\_1\\
    
    \mathbf{elif}\;y \leq 3 \cdot 10^{+53}:\\
    \;\;\;\;\frac{t}{z} \cdot \frac{0.3333333333333333}{y}\\
    
    \mathbf{else}:\\
    \;\;\;\;t\_1\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 2 regimes
    2. if y < -0.0015 or 2.99999999999999998e53 < y

      1. Initial program 99.8%

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

        \[\leadsto \color{blue}{\frac{-1}{3} \cdot \frac{y}{z}} \]
      4. Step-by-step derivation
        1. associate-*r/N/A

          \[\leadsto \frac{\frac{-1}{3} \cdot y}{\color{blue}{z}} \]
        2. *-commutativeN/A

          \[\leadsto \frac{y \cdot \frac{-1}{3}}{z} \]
        3. associate-/l*N/A

          \[\leadsto y \cdot \color{blue}{\frac{\frac{-1}{3}}{z}} \]
        4. metadata-evalN/A

          \[\leadsto y \cdot \frac{\mathsf{neg}\left(\frac{1}{3}\right)}{z} \]
        5. distribute-neg-fracN/A

          \[\leadsto y \cdot \left(\mathsf{neg}\left(\frac{\frac{1}{3}}{z}\right)\right) \]
        6. metadata-evalN/A

          \[\leadsto y \cdot \left(\mathsf{neg}\left(\frac{\frac{1}{3} \cdot 1}{z}\right)\right) \]
        7. associate-*r/N/A

          \[\leadsto y \cdot \left(\mathsf{neg}\left(\frac{1}{3} \cdot \frac{1}{z}\right)\right) \]
        8. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(y, \color{blue}{\left(\mathsf{neg}\left(\frac{1}{3} \cdot \frac{1}{z}\right)\right)}\right) \]
        9. associate-*r/N/A

          \[\leadsto \mathsf{*.f64}\left(y, \left(\mathsf{neg}\left(\frac{\frac{1}{3} \cdot 1}{z}\right)\right)\right) \]
        10. metadata-evalN/A

          \[\leadsto \mathsf{*.f64}\left(y, \left(\mathsf{neg}\left(\frac{\frac{1}{3}}{z}\right)\right)\right) \]
        11. distribute-neg-fracN/A

          \[\leadsto \mathsf{*.f64}\left(y, \left(\frac{\mathsf{neg}\left(\frac{1}{3}\right)}{\color{blue}{z}}\right)\right) \]
        12. metadata-evalN/A

          \[\leadsto \mathsf{*.f64}\left(y, \left(\frac{\frac{-1}{3}}{z}\right)\right) \]
        13. /-lowering-/.f6477.2%

          \[\leadsto \mathsf{*.f64}\left(y, \mathsf{/.f64}\left(\frac{-1}{3}, \color{blue}{z}\right)\right) \]
      5. Simplified77.2%

        \[\leadsto \color{blue}{y \cdot \frac{-0.3333333333333333}{z}} \]
      6. Step-by-step derivation
        1. associate-*r/N/A

          \[\leadsto \frac{y \cdot \frac{-1}{3}}{\color{blue}{z}} \]
        2. /-rgt-identityN/A

          \[\leadsto \frac{y \cdot \frac{-1}{3}}{\frac{z}{\color{blue}{1}}} \]
        3. div-invN/A

          \[\leadsto \frac{y \cdot \frac{-1}{3}}{z \cdot \color{blue}{\frac{1}{1}}} \]
        4. metadata-evalN/A

          \[\leadsto \frac{y \cdot \frac{-1}{3}}{z \cdot 1} \]
        5. times-fracN/A

          \[\leadsto \frac{y}{z} \cdot \color{blue}{\frac{\frac{-1}{3}}{1}} \]
        6. metadata-evalN/A

          \[\leadsto \frac{y}{z} \cdot \frac{-1}{3} \]
        7. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\left(\frac{y}{z}\right), \color{blue}{\frac{-1}{3}}\right) \]
        8. /-lowering-/.f6477.2%

          \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(y, z\right), \frac{-1}{3}\right) \]
      7. Applied egg-rr77.2%

        \[\leadsto \color{blue}{\frac{y}{z} \cdot -0.3333333333333333} \]
      8. Step-by-step derivation
        1. metadata-evalN/A

          \[\leadsto \frac{y}{z} \cdot \frac{1}{\color{blue}{-3}} \]
        2. metadata-evalN/A

          \[\leadsto \frac{y}{z} \cdot \frac{1}{\mathsf{neg}\left(3\right)} \]
        3. div-invN/A

          \[\leadsto \frac{\frac{y}{z}}{\color{blue}{\mathsf{neg}\left(3\right)}} \]
        4. /-lowering-/.f64N/A

          \[\leadsto \mathsf{/.f64}\left(\left(\frac{y}{z}\right), \color{blue}{\left(\mathsf{neg}\left(3\right)\right)}\right) \]
        5. /-lowering-/.f64N/A

          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, z\right), \left(\mathsf{neg}\left(\color{blue}{3}\right)\right)\right) \]
        6. metadata-eval77.3%

          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, z\right), -3\right) \]
      9. Applied egg-rr77.3%

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

      if -0.0015 < y < 2.99999999999999998e53

      1. Initial program 92.2%

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

        \[\leadsto \color{blue}{\frac{1}{3} \cdot \frac{t}{y \cdot z}} \]
      4. Step-by-step derivation
        1. associate-/l/N/A

          \[\leadsto \frac{1}{3} \cdot \frac{\frac{t}{z}}{\color{blue}{y}} \]
        2. associate-*r/N/A

          \[\leadsto \frac{\frac{1}{3} \cdot \frac{t}{z}}{\color{blue}{y}} \]
        3. /-lowering-/.f64N/A

          \[\leadsto \mathsf{/.f64}\left(\left(\frac{1}{3} \cdot \frac{t}{z}\right), \color{blue}{y}\right) \]
        4. associate-*r/N/A

          \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{1}{3} \cdot t}{z}\right), y\right) \]
        5. /-lowering-/.f64N/A

          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\left(\frac{1}{3} \cdot t\right), z\right), y\right) \]
        6. *-lowering-*.f6461.2%

          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\frac{1}{3}, t\right), z\right), y\right) \]
      5. Simplified61.2%

        \[\leadsto \color{blue}{\frac{\frac{0.3333333333333333 \cdot t}{z}}{y}} \]
      6. Step-by-step derivation
        1. associate-/l/N/A

          \[\leadsto \frac{\frac{1}{3} \cdot t}{\color{blue}{y \cdot z}} \]
        2. *-commutativeN/A

          \[\leadsto \frac{t \cdot \frac{1}{3}}{\color{blue}{y} \cdot z} \]
        3. *-commutativeN/A

          \[\leadsto \frac{t \cdot \frac{1}{3}}{z \cdot \color{blue}{y}} \]
        4. times-fracN/A

          \[\leadsto \frac{t}{z} \cdot \color{blue}{\frac{\frac{1}{3}}{y}} \]
        5. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\left(\frac{t}{z}\right), \color{blue}{\left(\frac{\frac{1}{3}}{y}\right)}\right) \]
        6. /-lowering-/.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(t, z\right), \left(\frac{\color{blue}{\frac{1}{3}}}{y}\right)\right) \]
        7. /-lowering-/.f6461.2%

          \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(t, z\right), \mathsf{/.f64}\left(\frac{1}{3}, \color{blue}{y}\right)\right) \]
      7. Applied egg-rr61.2%

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

    Alternative 9: 61.9% accurate, 0.9× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{\frac{y}{z}}{-3}\\ \mathbf{if}\;y \leq -0.0002:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \leq 2.3 \cdot 10^{+64}:\\ \;\;\;\;t \cdot \frac{0.3333333333333333}{z \cdot y}\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
    (FPCore (x y z t)
     :precision binary64
     (let* ((t_1 (/ (/ y z) -3.0)))
       (if (<= y -0.0002)
         t_1
         (if (<= y 2.3e+64) (* t (/ 0.3333333333333333 (* z y))) t_1))))
    double code(double x, double y, double z, double t) {
    	double t_1 = (y / z) / -3.0;
    	double tmp;
    	if (y <= -0.0002) {
    		tmp = t_1;
    	} else if (y <= 2.3e+64) {
    		tmp = t * (0.3333333333333333 / (z * y));
    	} else {
    		tmp = t_1;
    	}
    	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) :: t_1
        real(8) :: tmp
        t_1 = (y / z) / (-3.0d0)
        if (y <= (-0.0002d0)) then
            tmp = t_1
        else if (y <= 2.3d+64) then
            tmp = t * (0.3333333333333333d0 / (z * y))
        else
            tmp = t_1
        end if
        code = tmp
    end function
    
    public static double code(double x, double y, double z, double t) {
    	double t_1 = (y / z) / -3.0;
    	double tmp;
    	if (y <= -0.0002) {
    		tmp = t_1;
    	} else if (y <= 2.3e+64) {
    		tmp = t * (0.3333333333333333 / (z * y));
    	} else {
    		tmp = t_1;
    	}
    	return tmp;
    }
    
    def code(x, y, z, t):
    	t_1 = (y / z) / -3.0
    	tmp = 0
    	if y <= -0.0002:
    		tmp = t_1
    	elif y <= 2.3e+64:
    		tmp = t * (0.3333333333333333 / (z * y))
    	else:
    		tmp = t_1
    	return tmp
    
    function code(x, y, z, t)
    	t_1 = Float64(Float64(y / z) / -3.0)
    	tmp = 0.0
    	if (y <= -0.0002)
    		tmp = t_1;
    	elseif (y <= 2.3e+64)
    		tmp = Float64(t * Float64(0.3333333333333333 / Float64(z * y)));
    	else
    		tmp = t_1;
    	end
    	return tmp
    end
    
    function tmp_2 = code(x, y, z, t)
    	t_1 = (y / z) / -3.0;
    	tmp = 0.0;
    	if (y <= -0.0002)
    		tmp = t_1;
    	elseif (y <= 2.3e+64)
    		tmp = t * (0.3333333333333333 / (z * y));
    	else
    		tmp = t_1;
    	end
    	tmp_2 = tmp;
    end
    
    code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(y / z), $MachinePrecision] / -3.0), $MachinePrecision]}, If[LessEqual[y, -0.0002], t$95$1, If[LessEqual[y, 2.3e+64], N[(t * N[(0.3333333333333333 / N[(z * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    t_1 := \frac{\frac{y}{z}}{-3}\\
    \mathbf{if}\;y \leq -0.0002:\\
    \;\;\;\;t\_1\\
    
    \mathbf{elif}\;y \leq 2.3 \cdot 10^{+64}:\\
    \;\;\;\;t \cdot \frac{0.3333333333333333}{z \cdot y}\\
    
    \mathbf{else}:\\
    \;\;\;\;t\_1\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 2 regimes
    2. if y < -2.0000000000000001e-4 or 2.3e64 < y

      1. Initial program 99.8%

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

        \[\leadsto \color{blue}{\frac{-1}{3} \cdot \frac{y}{z}} \]
      4. Step-by-step derivation
        1. associate-*r/N/A

          \[\leadsto \frac{\frac{-1}{3} \cdot y}{\color{blue}{z}} \]
        2. *-commutativeN/A

          \[\leadsto \frac{y \cdot \frac{-1}{3}}{z} \]
        3. associate-/l*N/A

          \[\leadsto y \cdot \color{blue}{\frac{\frac{-1}{3}}{z}} \]
        4. metadata-evalN/A

          \[\leadsto y \cdot \frac{\mathsf{neg}\left(\frac{1}{3}\right)}{z} \]
        5. distribute-neg-fracN/A

          \[\leadsto y \cdot \left(\mathsf{neg}\left(\frac{\frac{1}{3}}{z}\right)\right) \]
        6. metadata-evalN/A

          \[\leadsto y \cdot \left(\mathsf{neg}\left(\frac{\frac{1}{3} \cdot 1}{z}\right)\right) \]
        7. associate-*r/N/A

          \[\leadsto y \cdot \left(\mathsf{neg}\left(\frac{1}{3} \cdot \frac{1}{z}\right)\right) \]
        8. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(y, \color{blue}{\left(\mathsf{neg}\left(\frac{1}{3} \cdot \frac{1}{z}\right)\right)}\right) \]
        9. associate-*r/N/A

          \[\leadsto \mathsf{*.f64}\left(y, \left(\mathsf{neg}\left(\frac{\frac{1}{3} \cdot 1}{z}\right)\right)\right) \]
        10. metadata-evalN/A

          \[\leadsto \mathsf{*.f64}\left(y, \left(\mathsf{neg}\left(\frac{\frac{1}{3}}{z}\right)\right)\right) \]
        11. distribute-neg-fracN/A

          \[\leadsto \mathsf{*.f64}\left(y, \left(\frac{\mathsf{neg}\left(\frac{1}{3}\right)}{\color{blue}{z}}\right)\right) \]
        12. metadata-evalN/A

          \[\leadsto \mathsf{*.f64}\left(y, \left(\frac{\frac{-1}{3}}{z}\right)\right) \]
        13. /-lowering-/.f6477.6%

          \[\leadsto \mathsf{*.f64}\left(y, \mathsf{/.f64}\left(\frac{-1}{3}, \color{blue}{z}\right)\right) \]
      5. Simplified77.6%

        \[\leadsto \color{blue}{y \cdot \frac{-0.3333333333333333}{z}} \]
      6. Step-by-step derivation
        1. associate-*r/N/A

          \[\leadsto \frac{y \cdot \frac{-1}{3}}{\color{blue}{z}} \]
        2. /-rgt-identityN/A

          \[\leadsto \frac{y \cdot \frac{-1}{3}}{\frac{z}{\color{blue}{1}}} \]
        3. div-invN/A

          \[\leadsto \frac{y \cdot \frac{-1}{3}}{z \cdot \color{blue}{\frac{1}{1}}} \]
        4. metadata-evalN/A

          \[\leadsto \frac{y \cdot \frac{-1}{3}}{z \cdot 1} \]
        5. times-fracN/A

          \[\leadsto \frac{y}{z} \cdot \color{blue}{\frac{\frac{-1}{3}}{1}} \]
        6. metadata-evalN/A

          \[\leadsto \frac{y}{z} \cdot \frac{-1}{3} \]
        7. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\left(\frac{y}{z}\right), \color{blue}{\frac{-1}{3}}\right) \]
        8. /-lowering-/.f6477.6%

          \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(y, z\right), \frac{-1}{3}\right) \]
      7. Applied egg-rr77.6%

        \[\leadsto \color{blue}{\frac{y}{z} \cdot -0.3333333333333333} \]
      8. Step-by-step derivation
        1. metadata-evalN/A

          \[\leadsto \frac{y}{z} \cdot \frac{1}{\color{blue}{-3}} \]
        2. metadata-evalN/A

          \[\leadsto \frac{y}{z} \cdot \frac{1}{\mathsf{neg}\left(3\right)} \]
        3. div-invN/A

          \[\leadsto \frac{\frac{y}{z}}{\color{blue}{\mathsf{neg}\left(3\right)}} \]
        4. /-lowering-/.f64N/A

          \[\leadsto \mathsf{/.f64}\left(\left(\frac{y}{z}\right), \color{blue}{\left(\mathsf{neg}\left(3\right)\right)}\right) \]
        5. /-lowering-/.f64N/A

          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, z\right), \left(\mathsf{neg}\left(\color{blue}{3}\right)\right)\right) \]
        6. metadata-eval77.8%

          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, z\right), -3\right) \]
      9. Applied egg-rr77.8%

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

      if -2.0000000000000001e-4 < y < 2.3e64

      1. Initial program 92.3%

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

        \[\leadsto \color{blue}{\frac{1}{3} \cdot \frac{t}{y \cdot z}} \]
      4. Step-by-step derivation
        1. associate-/l/N/A

          \[\leadsto \frac{1}{3} \cdot \frac{\frac{t}{z}}{\color{blue}{y}} \]
        2. associate-*r/N/A

          \[\leadsto \frac{\frac{1}{3} \cdot \frac{t}{z}}{\color{blue}{y}} \]
        3. /-lowering-/.f64N/A

          \[\leadsto \mathsf{/.f64}\left(\left(\frac{1}{3} \cdot \frac{t}{z}\right), \color{blue}{y}\right) \]
        4. associate-*r/N/A

          \[\leadsto \mathsf{/.f64}\left(\left(\frac{\frac{1}{3} \cdot t}{z}\right), y\right) \]
        5. /-lowering-/.f64N/A

          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\left(\frac{1}{3} \cdot t\right), z\right), y\right) \]
        6. *-lowering-*.f6460.3%

          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(\mathsf{*.f64}\left(\frac{1}{3}, t\right), z\right), y\right) \]
      5. Simplified60.3%

        \[\leadsto \color{blue}{\frac{\frac{0.3333333333333333 \cdot t}{z}}{y}} \]
      6. Step-by-step derivation
        1. associate-*l/N/A

          \[\leadsto \frac{\frac{\frac{1}{3}}{z} \cdot t}{y} \]
        2. associate-*l/N/A

          \[\leadsto \frac{\frac{\frac{1}{3}}{z}}{y} \cdot \color{blue}{t} \]
        3. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\left(\frac{\frac{\frac{1}{3}}{z}}{y}\right), \color{blue}{t}\right) \]
        4. associate-/l/N/A

          \[\leadsto \mathsf{*.f64}\left(\left(\frac{\frac{1}{3}}{y \cdot z}\right), t\right) \]
        5. /-lowering-/.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, \left(y \cdot z\right)\right), t\right) \]
        6. *-lowering-*.f6456.0%

          \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, \mathsf{*.f64}\left(y, z\right)\right), t\right) \]
      7. Applied egg-rr56.0%

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

      \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -0.0002:\\ \;\;\;\;\frac{\frac{y}{z}}{-3}\\ \mathbf{elif}\;y \leq 2.3 \cdot 10^{+64}:\\ \;\;\;\;t \cdot \frac{0.3333333333333333}{z \cdot y}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{y}{z}}{-3}\\ \end{array} \]
    5. Add Preprocessing

    Alternative 10: 47.7% accurate, 1.0× speedup?

    \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{\frac{y}{z}}{-3}\\ \mathbf{if}\;y \leq -7.8 \cdot 10^{+23}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \leq 1.9 \cdot 10^{+89}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
    (FPCore (x y z t)
     :precision binary64
     (let* ((t_1 (/ (/ y z) -3.0)))
       (if (<= y -7.8e+23) t_1 (if (<= y 1.9e+89) x t_1))))
    double code(double x, double y, double z, double t) {
    	double t_1 = (y / z) / -3.0;
    	double tmp;
    	if (y <= -7.8e+23) {
    		tmp = t_1;
    	} else if (y <= 1.9e+89) {
    		tmp = x;
    	} else {
    		tmp = t_1;
    	}
    	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) :: t_1
        real(8) :: tmp
        t_1 = (y / z) / (-3.0d0)
        if (y <= (-7.8d+23)) then
            tmp = t_1
        else if (y <= 1.9d+89) then
            tmp = x
        else
            tmp = t_1
        end if
        code = tmp
    end function
    
    public static double code(double x, double y, double z, double t) {
    	double t_1 = (y / z) / -3.0;
    	double tmp;
    	if (y <= -7.8e+23) {
    		tmp = t_1;
    	} else if (y <= 1.9e+89) {
    		tmp = x;
    	} else {
    		tmp = t_1;
    	}
    	return tmp;
    }
    
    def code(x, y, z, t):
    	t_1 = (y / z) / -3.0
    	tmp = 0
    	if y <= -7.8e+23:
    		tmp = t_1
    	elif y <= 1.9e+89:
    		tmp = x
    	else:
    		tmp = t_1
    	return tmp
    
    function code(x, y, z, t)
    	t_1 = Float64(Float64(y / z) / -3.0)
    	tmp = 0.0
    	if (y <= -7.8e+23)
    		tmp = t_1;
    	elseif (y <= 1.9e+89)
    		tmp = x;
    	else
    		tmp = t_1;
    	end
    	return tmp
    end
    
    function tmp_2 = code(x, y, z, t)
    	t_1 = (y / z) / -3.0;
    	tmp = 0.0;
    	if (y <= -7.8e+23)
    		tmp = t_1;
    	elseif (y <= 1.9e+89)
    		tmp = x;
    	else
    		tmp = t_1;
    	end
    	tmp_2 = tmp;
    end
    
    code[x_, y_, z_, t_] := Block[{t$95$1 = N[(N[(y / z), $MachinePrecision] / -3.0), $MachinePrecision]}, If[LessEqual[y, -7.8e+23], t$95$1, If[LessEqual[y, 1.9e+89], x, t$95$1]]]
    
    \begin{array}{l}
    
    \\
    \begin{array}{l}
    t_1 := \frac{\frac{y}{z}}{-3}\\
    \mathbf{if}\;y \leq -7.8 \cdot 10^{+23}:\\
    \;\;\;\;t\_1\\
    
    \mathbf{elif}\;y \leq 1.9 \cdot 10^{+89}:\\
    \;\;\;\;x\\
    
    \mathbf{else}:\\
    \;\;\;\;t\_1\\
    
    
    \end{array}
    \end{array}
    
    Derivation
    1. Split input into 2 regimes
    2. if y < -7.8000000000000001e23 or 1.90000000000000012e89 < y

      1. Initial program 99.8%

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

        \[\leadsto \color{blue}{\frac{-1}{3} \cdot \frac{y}{z}} \]
      4. Step-by-step derivation
        1. associate-*r/N/A

          \[\leadsto \frac{\frac{-1}{3} \cdot y}{\color{blue}{z}} \]
        2. *-commutativeN/A

          \[\leadsto \frac{y \cdot \frac{-1}{3}}{z} \]
        3. associate-/l*N/A

          \[\leadsto y \cdot \color{blue}{\frac{\frac{-1}{3}}{z}} \]
        4. metadata-evalN/A

          \[\leadsto y \cdot \frac{\mathsf{neg}\left(\frac{1}{3}\right)}{z} \]
        5. distribute-neg-fracN/A

          \[\leadsto y \cdot \left(\mathsf{neg}\left(\frac{\frac{1}{3}}{z}\right)\right) \]
        6. metadata-evalN/A

          \[\leadsto y \cdot \left(\mathsf{neg}\left(\frac{\frac{1}{3} \cdot 1}{z}\right)\right) \]
        7. associate-*r/N/A

          \[\leadsto y \cdot \left(\mathsf{neg}\left(\frac{1}{3} \cdot \frac{1}{z}\right)\right) \]
        8. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(y, \color{blue}{\left(\mathsf{neg}\left(\frac{1}{3} \cdot \frac{1}{z}\right)\right)}\right) \]
        9. associate-*r/N/A

          \[\leadsto \mathsf{*.f64}\left(y, \left(\mathsf{neg}\left(\frac{\frac{1}{3} \cdot 1}{z}\right)\right)\right) \]
        10. metadata-evalN/A

          \[\leadsto \mathsf{*.f64}\left(y, \left(\mathsf{neg}\left(\frac{\frac{1}{3}}{z}\right)\right)\right) \]
        11. distribute-neg-fracN/A

          \[\leadsto \mathsf{*.f64}\left(y, \left(\frac{\mathsf{neg}\left(\frac{1}{3}\right)}{\color{blue}{z}}\right)\right) \]
        12. metadata-evalN/A

          \[\leadsto \mathsf{*.f64}\left(y, \left(\frac{\frac{-1}{3}}{z}\right)\right) \]
        13. /-lowering-/.f6480.5%

          \[\leadsto \mathsf{*.f64}\left(y, \mathsf{/.f64}\left(\frac{-1}{3}, \color{blue}{z}\right)\right) \]
      5. Simplified80.5%

        \[\leadsto \color{blue}{y \cdot \frac{-0.3333333333333333}{z}} \]
      6. Step-by-step derivation
        1. associate-*r/N/A

          \[\leadsto \frac{y \cdot \frac{-1}{3}}{\color{blue}{z}} \]
        2. /-rgt-identityN/A

          \[\leadsto \frac{y \cdot \frac{-1}{3}}{\frac{z}{\color{blue}{1}}} \]
        3. div-invN/A

          \[\leadsto \frac{y \cdot \frac{-1}{3}}{z \cdot \color{blue}{\frac{1}{1}}} \]
        4. metadata-evalN/A

          \[\leadsto \frac{y \cdot \frac{-1}{3}}{z \cdot 1} \]
        5. times-fracN/A

          \[\leadsto \frac{y}{z} \cdot \color{blue}{\frac{\frac{-1}{3}}{1}} \]
        6. metadata-evalN/A

          \[\leadsto \frac{y}{z} \cdot \frac{-1}{3} \]
        7. *-lowering-*.f64N/A

          \[\leadsto \mathsf{*.f64}\left(\left(\frac{y}{z}\right), \color{blue}{\frac{-1}{3}}\right) \]
        8. /-lowering-/.f6480.5%

          \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(y, z\right), \frac{-1}{3}\right) \]
      7. Applied egg-rr80.5%

        \[\leadsto \color{blue}{\frac{y}{z} \cdot -0.3333333333333333} \]
      8. Step-by-step derivation
        1. metadata-evalN/A

          \[\leadsto \frac{y}{z} \cdot \frac{1}{\color{blue}{-3}} \]
        2. metadata-evalN/A

          \[\leadsto \frac{y}{z} \cdot \frac{1}{\mathsf{neg}\left(3\right)} \]
        3. div-invN/A

          \[\leadsto \frac{\frac{y}{z}}{\color{blue}{\mathsf{neg}\left(3\right)}} \]
        4. /-lowering-/.f64N/A

          \[\leadsto \mathsf{/.f64}\left(\left(\frac{y}{z}\right), \color{blue}{\left(\mathsf{neg}\left(3\right)\right)}\right) \]
        5. /-lowering-/.f64N/A

          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, z\right), \left(\mathsf{neg}\left(\color{blue}{3}\right)\right)\right) \]
        6. metadata-eval80.7%

          \[\leadsto \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, z\right), -3\right) \]
      9. Applied egg-rr80.7%

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

      if -7.8000000000000001e23 < y < 1.90000000000000012e89

      1. Initial program 92.9%

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

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

          \[\leadsto \color{blue}{x} \]
      5. Recombined 2 regimes into one program.
      6. Add Preprocessing

      Alternative 11: 47.8% accurate, 1.0× speedup?

      \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -2.4 \cdot 10^{+41}:\\ \;\;\;\;\frac{y \cdot -0.3333333333333333}{z}\\ \mathbf{elif}\;y \leq 5.8 \cdot 10^{+88}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;\frac{y}{\frac{z}{-0.3333333333333333}}\\ \end{array} \end{array} \]
      (FPCore (x y z t)
       :precision binary64
       (if (<= y -2.4e+41)
         (/ (* y -0.3333333333333333) z)
         (if (<= y 5.8e+88) x (/ y (/ z -0.3333333333333333)))))
      double code(double x, double y, double z, double t) {
      	double tmp;
      	if (y <= -2.4e+41) {
      		tmp = (y * -0.3333333333333333) / z;
      	} else if (y <= 5.8e+88) {
      		tmp = x;
      	} else {
      		tmp = y / (z / -0.3333333333333333);
      	}
      	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 (y <= (-2.4d+41)) then
              tmp = (y * (-0.3333333333333333d0)) / z
          else if (y <= 5.8d+88) then
              tmp = x
          else
              tmp = y / (z / (-0.3333333333333333d0))
          end if
          code = tmp
      end function
      
      public static double code(double x, double y, double z, double t) {
      	double tmp;
      	if (y <= -2.4e+41) {
      		tmp = (y * -0.3333333333333333) / z;
      	} else if (y <= 5.8e+88) {
      		tmp = x;
      	} else {
      		tmp = y / (z / -0.3333333333333333);
      	}
      	return tmp;
      }
      
      def code(x, y, z, t):
      	tmp = 0
      	if y <= -2.4e+41:
      		tmp = (y * -0.3333333333333333) / z
      	elif y <= 5.8e+88:
      		tmp = x
      	else:
      		tmp = y / (z / -0.3333333333333333)
      	return tmp
      
      function code(x, y, z, t)
      	tmp = 0.0
      	if (y <= -2.4e+41)
      		tmp = Float64(Float64(y * -0.3333333333333333) / z);
      	elseif (y <= 5.8e+88)
      		tmp = x;
      	else
      		tmp = Float64(y / Float64(z / -0.3333333333333333));
      	end
      	return tmp
      end
      
      function tmp_2 = code(x, y, z, t)
      	tmp = 0.0;
      	if (y <= -2.4e+41)
      		tmp = (y * -0.3333333333333333) / z;
      	elseif (y <= 5.8e+88)
      		tmp = x;
      	else
      		tmp = y / (z / -0.3333333333333333);
      	end
      	tmp_2 = tmp;
      end
      
      code[x_, y_, z_, t_] := If[LessEqual[y, -2.4e+41], N[(N[(y * -0.3333333333333333), $MachinePrecision] / z), $MachinePrecision], If[LessEqual[y, 5.8e+88], x, N[(y / N[(z / -0.3333333333333333), $MachinePrecision]), $MachinePrecision]]]
      
      \begin{array}{l}
      
      \\
      \begin{array}{l}
      \mathbf{if}\;y \leq -2.4 \cdot 10^{+41}:\\
      \;\;\;\;\frac{y \cdot -0.3333333333333333}{z}\\
      
      \mathbf{elif}\;y \leq 5.8 \cdot 10^{+88}:\\
      \;\;\;\;x\\
      
      \mathbf{else}:\\
      \;\;\;\;\frac{y}{\frac{z}{-0.3333333333333333}}\\
      
      
      \end{array}
      \end{array}
      
      Derivation
      1. Split input into 3 regimes
      2. if y < -2.4000000000000002e41

        1. Initial program 99.7%

          \[\left(x - \frac{y}{z \cdot 3}\right) + \frac{t}{\left(z \cdot 3\right) \cdot y} \]
        2. Add Preprocessing
        3. Step-by-step derivation
          1. *-commutativeN/A

            \[\leadsto \mathsf{+.f64}\left(\mathsf{\_.f64}\left(x, \left(\frac{y}{3 \cdot z}\right)\right), \mathsf{/.f64}\left(t, \mathsf{*.f64}\left(\mathsf{*.f64}\left(z, 3\right), y\right)\right)\right) \]
          2. associate-/r*N/A

            \[\leadsto \mathsf{+.f64}\left(\mathsf{\_.f64}\left(x, \left(\frac{\frac{y}{3}}{z}\right)\right), \mathsf{/.f64}\left(t, \mathsf{*.f64}\left(\mathsf{*.f64}\left(z, 3\right), y\right)\right)\right) \]
          3. /-lowering-/.f64N/A

            \[\leadsto \mathsf{+.f64}\left(\mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\left(\frac{y}{3}\right), z\right)\right), \mathsf{/.f64}\left(t, \mathsf{*.f64}\left(\mathsf{*.f64}\left(z, 3\right), y\right)\right)\right) \]
          4. /-lowering-/.f6499.9%

            \[\leadsto \mathsf{+.f64}\left(\mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{/.f64}\left(y, 3\right), z\right)\right), \mathsf{/.f64}\left(t, \mathsf{*.f64}\left(\mathsf{*.f64}\left(z, 3\right), y\right)\right)\right) \]
        4. Applied egg-rr99.9%

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

          \[\leadsto \color{blue}{\frac{-1}{3} \cdot \frac{y}{z}} \]
        6. Step-by-step derivation
          1. associate-*r/N/A

            \[\leadsto \frac{\frac{-1}{3} \cdot y}{\color{blue}{z}} \]
          2. /-lowering-/.f64N/A

            \[\leadsto \mathsf{/.f64}\left(\left(\frac{-1}{3} \cdot y\right), \color{blue}{z}\right) \]
          3. *-commutativeN/A

            \[\leadsto \mathsf{/.f64}\left(\left(y \cdot \frac{-1}{3}\right), z\right) \]
          4. *-lowering-*.f6479.4%

            \[\leadsto \mathsf{/.f64}\left(\mathsf{*.f64}\left(y, \frac{-1}{3}\right), z\right) \]
        7. Simplified79.4%

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

        if -2.4000000000000002e41 < y < 5.7999999999999999e88

        1. Initial program 93.1%

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

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

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

          if 5.7999999999999999e88 < y

          1. Initial program 99.8%

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

            \[\leadsto \color{blue}{\frac{-1}{3} \cdot \frac{y}{z}} \]
          4. Step-by-step derivation
            1. associate-*r/N/A

              \[\leadsto \frac{\frac{-1}{3} \cdot y}{\color{blue}{z}} \]
            2. *-commutativeN/A

              \[\leadsto \frac{y \cdot \frac{-1}{3}}{z} \]
            3. associate-/l*N/A

              \[\leadsto y \cdot \color{blue}{\frac{\frac{-1}{3}}{z}} \]
            4. metadata-evalN/A

              \[\leadsto y \cdot \frac{\mathsf{neg}\left(\frac{1}{3}\right)}{z} \]
            5. distribute-neg-fracN/A

              \[\leadsto y \cdot \left(\mathsf{neg}\left(\frac{\frac{1}{3}}{z}\right)\right) \]
            6. metadata-evalN/A

              \[\leadsto y \cdot \left(\mathsf{neg}\left(\frac{\frac{1}{3} \cdot 1}{z}\right)\right) \]
            7. associate-*r/N/A

              \[\leadsto y \cdot \left(\mathsf{neg}\left(\frac{1}{3} \cdot \frac{1}{z}\right)\right) \]
            8. *-lowering-*.f64N/A

              \[\leadsto \mathsf{*.f64}\left(y, \color{blue}{\left(\mathsf{neg}\left(\frac{1}{3} \cdot \frac{1}{z}\right)\right)}\right) \]
            9. associate-*r/N/A

              \[\leadsto \mathsf{*.f64}\left(y, \left(\mathsf{neg}\left(\frac{\frac{1}{3} \cdot 1}{z}\right)\right)\right) \]
            10. metadata-evalN/A

              \[\leadsto \mathsf{*.f64}\left(y, \left(\mathsf{neg}\left(\frac{\frac{1}{3}}{z}\right)\right)\right) \]
            11. distribute-neg-fracN/A

              \[\leadsto \mathsf{*.f64}\left(y, \left(\frac{\mathsf{neg}\left(\frac{1}{3}\right)}{\color{blue}{z}}\right)\right) \]
            12. metadata-evalN/A

              \[\leadsto \mathsf{*.f64}\left(y, \left(\frac{\frac{-1}{3}}{z}\right)\right) \]
            13. /-lowering-/.f6484.7%

              \[\leadsto \mathsf{*.f64}\left(y, \mathsf{/.f64}\left(\frac{-1}{3}, \color{blue}{z}\right)\right) \]
          5. Simplified84.7%

            \[\leadsto \color{blue}{y \cdot \frac{-0.3333333333333333}{z}} \]
          6. Step-by-step derivation
            1. clear-numN/A

              \[\leadsto y \cdot \frac{1}{\color{blue}{\frac{z}{\frac{-1}{3}}}} \]
            2. un-div-invN/A

              \[\leadsto \frac{y}{\color{blue}{\frac{z}{\frac{-1}{3}}}} \]
            3. /-lowering-/.f64N/A

              \[\leadsto \mathsf{/.f64}\left(y, \color{blue}{\left(\frac{z}{\frac{-1}{3}}\right)}\right) \]
            4. /-lowering-/.f6484.8%

              \[\leadsto \mathsf{/.f64}\left(y, \mathsf{/.f64}\left(z, \color{blue}{\frac{-1}{3}}\right)\right) \]
          7. Applied egg-rr84.8%

            \[\leadsto \color{blue}{\frac{y}{\frac{z}{-0.3333333333333333}}} \]
        5. Recombined 3 regimes into one program.
        6. Add Preprocessing

        Alternative 12: 47.8% accurate, 1.0× speedup?

        \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -2.5 \cdot 10^{+42}:\\ \;\;\;\;y \cdot \frac{-0.3333333333333333}{z}\\ \mathbf{elif}\;y \leq 2.3 \cdot 10^{+93}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;\frac{y}{\frac{z}{-0.3333333333333333}}\\ \end{array} \end{array} \]
        (FPCore (x y z t)
         :precision binary64
         (if (<= y -2.5e+42)
           (* y (/ -0.3333333333333333 z))
           (if (<= y 2.3e+93) x (/ y (/ z -0.3333333333333333)))))
        double code(double x, double y, double z, double t) {
        	double tmp;
        	if (y <= -2.5e+42) {
        		tmp = y * (-0.3333333333333333 / z);
        	} else if (y <= 2.3e+93) {
        		tmp = x;
        	} else {
        		tmp = y / (z / -0.3333333333333333);
        	}
        	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 (y <= (-2.5d+42)) then
                tmp = y * ((-0.3333333333333333d0) / z)
            else if (y <= 2.3d+93) then
                tmp = x
            else
                tmp = y / (z / (-0.3333333333333333d0))
            end if
            code = tmp
        end function
        
        public static double code(double x, double y, double z, double t) {
        	double tmp;
        	if (y <= -2.5e+42) {
        		tmp = y * (-0.3333333333333333 / z);
        	} else if (y <= 2.3e+93) {
        		tmp = x;
        	} else {
        		tmp = y / (z / -0.3333333333333333);
        	}
        	return tmp;
        }
        
        def code(x, y, z, t):
        	tmp = 0
        	if y <= -2.5e+42:
        		tmp = y * (-0.3333333333333333 / z)
        	elif y <= 2.3e+93:
        		tmp = x
        	else:
        		tmp = y / (z / -0.3333333333333333)
        	return tmp
        
        function code(x, y, z, t)
        	tmp = 0.0
        	if (y <= -2.5e+42)
        		tmp = Float64(y * Float64(-0.3333333333333333 / z));
        	elseif (y <= 2.3e+93)
        		tmp = x;
        	else
        		tmp = Float64(y / Float64(z / -0.3333333333333333));
        	end
        	return tmp
        end
        
        function tmp_2 = code(x, y, z, t)
        	tmp = 0.0;
        	if (y <= -2.5e+42)
        		tmp = y * (-0.3333333333333333 / z);
        	elseif (y <= 2.3e+93)
        		tmp = x;
        	else
        		tmp = y / (z / -0.3333333333333333);
        	end
        	tmp_2 = tmp;
        end
        
        code[x_, y_, z_, t_] := If[LessEqual[y, -2.5e+42], N[(y * N[(-0.3333333333333333 / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2.3e+93], x, N[(y / N[(z / -0.3333333333333333), $MachinePrecision]), $MachinePrecision]]]
        
        \begin{array}{l}
        
        \\
        \begin{array}{l}
        \mathbf{if}\;y \leq -2.5 \cdot 10^{+42}:\\
        \;\;\;\;y \cdot \frac{-0.3333333333333333}{z}\\
        
        \mathbf{elif}\;y \leq 2.3 \cdot 10^{+93}:\\
        \;\;\;\;x\\
        
        \mathbf{else}:\\
        \;\;\;\;\frac{y}{\frac{z}{-0.3333333333333333}}\\
        
        
        \end{array}
        \end{array}
        
        Derivation
        1. Split input into 3 regimes
        2. if y < -2.50000000000000003e42

          1. Initial program 99.7%

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

            \[\leadsto \color{blue}{\frac{-1}{3} \cdot \frac{y}{z}} \]
          4. Step-by-step derivation
            1. associate-*r/N/A

              \[\leadsto \frac{\frac{-1}{3} \cdot y}{\color{blue}{z}} \]
            2. *-commutativeN/A

              \[\leadsto \frac{y \cdot \frac{-1}{3}}{z} \]
            3. associate-/l*N/A

              \[\leadsto y \cdot \color{blue}{\frac{\frac{-1}{3}}{z}} \]
            4. metadata-evalN/A

              \[\leadsto y \cdot \frac{\mathsf{neg}\left(\frac{1}{3}\right)}{z} \]
            5. distribute-neg-fracN/A

              \[\leadsto y \cdot \left(\mathsf{neg}\left(\frac{\frac{1}{3}}{z}\right)\right) \]
            6. metadata-evalN/A

              \[\leadsto y \cdot \left(\mathsf{neg}\left(\frac{\frac{1}{3} \cdot 1}{z}\right)\right) \]
            7. associate-*r/N/A

              \[\leadsto y \cdot \left(\mathsf{neg}\left(\frac{1}{3} \cdot \frac{1}{z}\right)\right) \]
            8. *-lowering-*.f64N/A

              \[\leadsto \mathsf{*.f64}\left(y, \color{blue}{\left(\mathsf{neg}\left(\frac{1}{3} \cdot \frac{1}{z}\right)\right)}\right) \]
            9. associate-*r/N/A

              \[\leadsto \mathsf{*.f64}\left(y, \left(\mathsf{neg}\left(\frac{\frac{1}{3} \cdot 1}{z}\right)\right)\right) \]
            10. metadata-evalN/A

              \[\leadsto \mathsf{*.f64}\left(y, \left(\mathsf{neg}\left(\frac{\frac{1}{3}}{z}\right)\right)\right) \]
            11. distribute-neg-fracN/A

              \[\leadsto \mathsf{*.f64}\left(y, \left(\frac{\mathsf{neg}\left(\frac{1}{3}\right)}{\color{blue}{z}}\right)\right) \]
            12. metadata-evalN/A

              \[\leadsto \mathsf{*.f64}\left(y, \left(\frac{\frac{-1}{3}}{z}\right)\right) \]
            13. /-lowering-/.f6479.3%

              \[\leadsto \mathsf{*.f64}\left(y, \mathsf{/.f64}\left(\frac{-1}{3}, \color{blue}{z}\right)\right) \]
          5. Simplified79.3%

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

          if -2.50000000000000003e42 < y < 2.3000000000000002e93

          1. Initial program 93.1%

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

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

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

            if 2.3000000000000002e93 < y

            1. Initial program 99.8%

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

              \[\leadsto \color{blue}{\frac{-1}{3} \cdot \frac{y}{z}} \]
            4. Step-by-step derivation
              1. associate-*r/N/A

                \[\leadsto \frac{\frac{-1}{3} \cdot y}{\color{blue}{z}} \]
              2. *-commutativeN/A

                \[\leadsto \frac{y \cdot \frac{-1}{3}}{z} \]
              3. associate-/l*N/A

                \[\leadsto y \cdot \color{blue}{\frac{\frac{-1}{3}}{z}} \]
              4. metadata-evalN/A

                \[\leadsto y \cdot \frac{\mathsf{neg}\left(\frac{1}{3}\right)}{z} \]
              5. distribute-neg-fracN/A

                \[\leadsto y \cdot \left(\mathsf{neg}\left(\frac{\frac{1}{3}}{z}\right)\right) \]
              6. metadata-evalN/A

                \[\leadsto y \cdot \left(\mathsf{neg}\left(\frac{\frac{1}{3} \cdot 1}{z}\right)\right) \]
              7. associate-*r/N/A

                \[\leadsto y \cdot \left(\mathsf{neg}\left(\frac{1}{3} \cdot \frac{1}{z}\right)\right) \]
              8. *-lowering-*.f64N/A

                \[\leadsto \mathsf{*.f64}\left(y, \color{blue}{\left(\mathsf{neg}\left(\frac{1}{3} \cdot \frac{1}{z}\right)\right)}\right) \]
              9. associate-*r/N/A

                \[\leadsto \mathsf{*.f64}\left(y, \left(\mathsf{neg}\left(\frac{\frac{1}{3} \cdot 1}{z}\right)\right)\right) \]
              10. metadata-evalN/A

                \[\leadsto \mathsf{*.f64}\left(y, \left(\mathsf{neg}\left(\frac{\frac{1}{3}}{z}\right)\right)\right) \]
              11. distribute-neg-fracN/A

                \[\leadsto \mathsf{*.f64}\left(y, \left(\frac{\mathsf{neg}\left(\frac{1}{3}\right)}{\color{blue}{z}}\right)\right) \]
              12. metadata-evalN/A

                \[\leadsto \mathsf{*.f64}\left(y, \left(\frac{\frac{-1}{3}}{z}\right)\right) \]
              13. /-lowering-/.f6484.7%

                \[\leadsto \mathsf{*.f64}\left(y, \mathsf{/.f64}\left(\frac{-1}{3}, \color{blue}{z}\right)\right) \]
            5. Simplified84.7%

              \[\leadsto \color{blue}{y \cdot \frac{-0.3333333333333333}{z}} \]
            6. Step-by-step derivation
              1. clear-numN/A

                \[\leadsto y \cdot \frac{1}{\color{blue}{\frac{z}{\frac{-1}{3}}}} \]
              2. un-div-invN/A

                \[\leadsto \frac{y}{\color{blue}{\frac{z}{\frac{-1}{3}}}} \]
              3. /-lowering-/.f64N/A

                \[\leadsto \mathsf{/.f64}\left(y, \color{blue}{\left(\frac{z}{\frac{-1}{3}}\right)}\right) \]
              4. /-lowering-/.f6484.8%

                \[\leadsto \mathsf{/.f64}\left(y, \mathsf{/.f64}\left(z, \color{blue}{\frac{-1}{3}}\right)\right) \]
            7. Applied egg-rr84.8%

              \[\leadsto \color{blue}{\frac{y}{\frac{z}{-0.3333333333333333}}} \]
          5. Recombined 3 regimes into one program.
          6. Add Preprocessing

          Alternative 13: 47.7% accurate, 1.0× speedup?

          \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -1.3 \cdot 10^{+43}:\\ \;\;\;\;y \cdot \frac{-0.3333333333333333}{z}\\ \mathbf{elif}\;y \leq 6.6 \cdot 10^{+94}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;-0.3333333333333333 \cdot \frac{y}{z}\\ \end{array} \end{array} \]
          (FPCore (x y z t)
           :precision binary64
           (if (<= y -1.3e+43)
             (* y (/ -0.3333333333333333 z))
             (if (<= y 6.6e+94) x (* -0.3333333333333333 (/ y z)))))
          double code(double x, double y, double z, double t) {
          	double tmp;
          	if (y <= -1.3e+43) {
          		tmp = y * (-0.3333333333333333 / z);
          	} else if (y <= 6.6e+94) {
          		tmp = x;
          	} else {
          		tmp = -0.3333333333333333 * (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 (y <= (-1.3d+43)) then
                  tmp = y * ((-0.3333333333333333d0) / z)
              else if (y <= 6.6d+94) then
                  tmp = x
              else
                  tmp = (-0.3333333333333333d0) * (y / z)
              end if
              code = tmp
          end function
          
          public static double code(double x, double y, double z, double t) {
          	double tmp;
          	if (y <= -1.3e+43) {
          		tmp = y * (-0.3333333333333333 / z);
          	} else if (y <= 6.6e+94) {
          		tmp = x;
          	} else {
          		tmp = -0.3333333333333333 * (y / z);
          	}
          	return tmp;
          }
          
          def code(x, y, z, t):
          	tmp = 0
          	if y <= -1.3e+43:
          		tmp = y * (-0.3333333333333333 / z)
          	elif y <= 6.6e+94:
          		tmp = x
          	else:
          		tmp = -0.3333333333333333 * (y / z)
          	return tmp
          
          function code(x, y, z, t)
          	tmp = 0.0
          	if (y <= -1.3e+43)
          		tmp = Float64(y * Float64(-0.3333333333333333 / z));
          	elseif (y <= 6.6e+94)
          		tmp = x;
          	else
          		tmp = Float64(-0.3333333333333333 * Float64(y / z));
          	end
          	return tmp
          end
          
          function tmp_2 = code(x, y, z, t)
          	tmp = 0.0;
          	if (y <= -1.3e+43)
          		tmp = y * (-0.3333333333333333 / z);
          	elseif (y <= 6.6e+94)
          		tmp = x;
          	else
          		tmp = -0.3333333333333333 * (y / z);
          	end
          	tmp_2 = tmp;
          end
          
          code[x_, y_, z_, t_] := If[LessEqual[y, -1.3e+43], N[(y * N[(-0.3333333333333333 / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 6.6e+94], x, N[(-0.3333333333333333 * N[(y / z), $MachinePrecision]), $MachinePrecision]]]
          
          \begin{array}{l}
          
          \\
          \begin{array}{l}
          \mathbf{if}\;y \leq -1.3 \cdot 10^{+43}:\\
          \;\;\;\;y \cdot \frac{-0.3333333333333333}{z}\\
          
          \mathbf{elif}\;y \leq 6.6 \cdot 10^{+94}:\\
          \;\;\;\;x\\
          
          \mathbf{else}:\\
          \;\;\;\;-0.3333333333333333 \cdot \frac{y}{z}\\
          
          
          \end{array}
          \end{array}
          
          Derivation
          1. Split input into 3 regimes
          2. if y < -1.3000000000000001e43

            1. Initial program 99.7%

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

              \[\leadsto \color{blue}{\frac{-1}{3} \cdot \frac{y}{z}} \]
            4. Step-by-step derivation
              1. associate-*r/N/A

                \[\leadsto \frac{\frac{-1}{3} \cdot y}{\color{blue}{z}} \]
              2. *-commutativeN/A

                \[\leadsto \frac{y \cdot \frac{-1}{3}}{z} \]
              3. associate-/l*N/A

                \[\leadsto y \cdot \color{blue}{\frac{\frac{-1}{3}}{z}} \]
              4. metadata-evalN/A

                \[\leadsto y \cdot \frac{\mathsf{neg}\left(\frac{1}{3}\right)}{z} \]
              5. distribute-neg-fracN/A

                \[\leadsto y \cdot \left(\mathsf{neg}\left(\frac{\frac{1}{3}}{z}\right)\right) \]
              6. metadata-evalN/A

                \[\leadsto y \cdot \left(\mathsf{neg}\left(\frac{\frac{1}{3} \cdot 1}{z}\right)\right) \]
              7. associate-*r/N/A

                \[\leadsto y \cdot \left(\mathsf{neg}\left(\frac{1}{3} \cdot \frac{1}{z}\right)\right) \]
              8. *-lowering-*.f64N/A

                \[\leadsto \mathsf{*.f64}\left(y, \color{blue}{\left(\mathsf{neg}\left(\frac{1}{3} \cdot \frac{1}{z}\right)\right)}\right) \]
              9. associate-*r/N/A

                \[\leadsto \mathsf{*.f64}\left(y, \left(\mathsf{neg}\left(\frac{\frac{1}{3} \cdot 1}{z}\right)\right)\right) \]
              10. metadata-evalN/A

                \[\leadsto \mathsf{*.f64}\left(y, \left(\mathsf{neg}\left(\frac{\frac{1}{3}}{z}\right)\right)\right) \]
              11. distribute-neg-fracN/A

                \[\leadsto \mathsf{*.f64}\left(y, \left(\frac{\mathsf{neg}\left(\frac{1}{3}\right)}{\color{blue}{z}}\right)\right) \]
              12. metadata-evalN/A

                \[\leadsto \mathsf{*.f64}\left(y, \left(\frac{\frac{-1}{3}}{z}\right)\right) \]
              13. /-lowering-/.f6479.3%

                \[\leadsto \mathsf{*.f64}\left(y, \mathsf{/.f64}\left(\frac{-1}{3}, \color{blue}{z}\right)\right) \]
            5. Simplified79.3%

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

            if -1.3000000000000001e43 < y < 6.6e94

            1. Initial program 93.1%

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

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

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

              if 6.6e94 < y

              1. Initial program 99.8%

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

                \[\leadsto \color{blue}{\frac{-1}{3} \cdot \frac{y}{z}} \]
              4. Step-by-step derivation
                1. associate-*r/N/A

                  \[\leadsto \frac{\frac{-1}{3} \cdot y}{\color{blue}{z}} \]
                2. *-commutativeN/A

                  \[\leadsto \frac{y \cdot \frac{-1}{3}}{z} \]
                3. associate-/l*N/A

                  \[\leadsto y \cdot \color{blue}{\frac{\frac{-1}{3}}{z}} \]
                4. metadata-evalN/A

                  \[\leadsto y \cdot \frac{\mathsf{neg}\left(\frac{1}{3}\right)}{z} \]
                5. distribute-neg-fracN/A

                  \[\leadsto y \cdot \left(\mathsf{neg}\left(\frac{\frac{1}{3}}{z}\right)\right) \]
                6. metadata-evalN/A

                  \[\leadsto y \cdot \left(\mathsf{neg}\left(\frac{\frac{1}{3} \cdot 1}{z}\right)\right) \]
                7. associate-*r/N/A

                  \[\leadsto y \cdot \left(\mathsf{neg}\left(\frac{1}{3} \cdot \frac{1}{z}\right)\right) \]
                8. *-lowering-*.f64N/A

                  \[\leadsto \mathsf{*.f64}\left(y, \color{blue}{\left(\mathsf{neg}\left(\frac{1}{3} \cdot \frac{1}{z}\right)\right)}\right) \]
                9. associate-*r/N/A

                  \[\leadsto \mathsf{*.f64}\left(y, \left(\mathsf{neg}\left(\frac{\frac{1}{3} \cdot 1}{z}\right)\right)\right) \]
                10. metadata-evalN/A

                  \[\leadsto \mathsf{*.f64}\left(y, \left(\mathsf{neg}\left(\frac{\frac{1}{3}}{z}\right)\right)\right) \]
                11. distribute-neg-fracN/A

                  \[\leadsto \mathsf{*.f64}\left(y, \left(\frac{\mathsf{neg}\left(\frac{1}{3}\right)}{\color{blue}{z}}\right)\right) \]
                12. metadata-evalN/A

                  \[\leadsto \mathsf{*.f64}\left(y, \left(\frac{\frac{-1}{3}}{z}\right)\right) \]
                13. /-lowering-/.f6484.7%

                  \[\leadsto \mathsf{*.f64}\left(y, \mathsf{/.f64}\left(\frac{-1}{3}, \color{blue}{z}\right)\right) \]
              5. Simplified84.7%

                \[\leadsto \color{blue}{y \cdot \frac{-0.3333333333333333}{z}} \]
              6. Step-by-step derivation
                1. associate-*r/N/A

                  \[\leadsto \frac{y \cdot \frac{-1}{3}}{\color{blue}{z}} \]
                2. /-rgt-identityN/A

                  \[\leadsto \frac{y \cdot \frac{-1}{3}}{\frac{z}{\color{blue}{1}}} \]
                3. div-invN/A

                  \[\leadsto \frac{y \cdot \frac{-1}{3}}{z \cdot \color{blue}{\frac{1}{1}}} \]
                4. metadata-evalN/A

                  \[\leadsto \frac{y \cdot \frac{-1}{3}}{z \cdot 1} \]
                5. times-fracN/A

                  \[\leadsto \frac{y}{z} \cdot \color{blue}{\frac{\frac{-1}{3}}{1}} \]
                6. metadata-evalN/A

                  \[\leadsto \frac{y}{z} \cdot \frac{-1}{3} \]
                7. *-lowering-*.f64N/A

                  \[\leadsto \mathsf{*.f64}\left(\left(\frac{y}{z}\right), \color{blue}{\frac{-1}{3}}\right) \]
                8. /-lowering-/.f6484.8%

                  \[\leadsto \mathsf{*.f64}\left(\mathsf{/.f64}\left(y, z\right), \frac{-1}{3}\right) \]
              7. Applied egg-rr84.8%

                \[\leadsto \color{blue}{\frac{y}{z} \cdot -0.3333333333333333} \]
            5. Recombined 3 regimes into one program.
            6. Final simplification56.7%

              \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -1.3 \cdot 10^{+43}:\\ \;\;\;\;y \cdot \frac{-0.3333333333333333}{z}\\ \mathbf{elif}\;y \leq 6.6 \cdot 10^{+94}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;-0.3333333333333333 \cdot \frac{y}{z}\\ \end{array} \]
            7. Add Preprocessing

            Alternative 14: 48.3% accurate, 1.0× speedup?

            \[\begin{array}{l} \\ \begin{array}{l} t_1 := y \cdot \frac{-0.3333333333333333}{z}\\ \mathbf{if}\;y \leq -2.6 \cdot 10^{+40}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \leq 6.6 \cdot 10^{+40}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
            (FPCore (x y z t)
             :precision binary64
             (let* ((t_1 (* y (/ -0.3333333333333333 z))))
               (if (<= y -2.6e+40) t_1 (if (<= y 6.6e+40) x t_1))))
            double code(double x, double y, double z, double t) {
            	double t_1 = y * (-0.3333333333333333 / z);
            	double tmp;
            	if (y <= -2.6e+40) {
            		tmp = t_1;
            	} else if (y <= 6.6e+40) {
            		tmp = x;
            	} else {
            		tmp = t_1;
            	}
            	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) :: t_1
                real(8) :: tmp
                t_1 = y * ((-0.3333333333333333d0) / z)
                if (y <= (-2.6d+40)) then
                    tmp = t_1
                else if (y <= 6.6d+40) then
                    tmp = x
                else
                    tmp = t_1
                end if
                code = tmp
            end function
            
            public static double code(double x, double y, double z, double t) {
            	double t_1 = y * (-0.3333333333333333 / z);
            	double tmp;
            	if (y <= -2.6e+40) {
            		tmp = t_1;
            	} else if (y <= 6.6e+40) {
            		tmp = x;
            	} else {
            		tmp = t_1;
            	}
            	return tmp;
            }
            
            def code(x, y, z, t):
            	t_1 = y * (-0.3333333333333333 / z)
            	tmp = 0
            	if y <= -2.6e+40:
            		tmp = t_1
            	elif y <= 6.6e+40:
            		tmp = x
            	else:
            		tmp = t_1
            	return tmp
            
            function code(x, y, z, t)
            	t_1 = Float64(y * Float64(-0.3333333333333333 / z))
            	tmp = 0.0
            	if (y <= -2.6e+40)
            		tmp = t_1;
            	elseif (y <= 6.6e+40)
            		tmp = x;
            	else
            		tmp = t_1;
            	end
            	return tmp
            end
            
            function tmp_2 = code(x, y, z, t)
            	t_1 = y * (-0.3333333333333333 / z);
            	tmp = 0.0;
            	if (y <= -2.6e+40)
            		tmp = t_1;
            	elseif (y <= 6.6e+40)
            		tmp = x;
            	else
            		tmp = t_1;
            	end
            	tmp_2 = tmp;
            end
            
            code[x_, y_, z_, t_] := Block[{t$95$1 = N[(y * N[(-0.3333333333333333 / z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -2.6e+40], t$95$1, If[LessEqual[y, 6.6e+40], x, t$95$1]]]
            
            \begin{array}{l}
            
            \\
            \begin{array}{l}
            t_1 := y \cdot \frac{-0.3333333333333333}{z}\\
            \mathbf{if}\;y \leq -2.6 \cdot 10^{+40}:\\
            \;\;\;\;t\_1\\
            
            \mathbf{elif}\;y \leq 6.6 \cdot 10^{+40}:\\
            \;\;\;\;x\\
            
            \mathbf{else}:\\
            \;\;\;\;t\_1\\
            
            
            \end{array}
            \end{array}
            
            Derivation
            1. Split input into 2 regimes
            2. if y < -2.6000000000000001e40 or 6.5999999999999997e40 < y

              1. Initial program 99.7%

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

                \[\leadsto \color{blue}{\frac{-1}{3} \cdot \frac{y}{z}} \]
              4. Step-by-step derivation
                1. associate-*r/N/A

                  \[\leadsto \frac{\frac{-1}{3} \cdot y}{\color{blue}{z}} \]
                2. *-commutativeN/A

                  \[\leadsto \frac{y \cdot \frac{-1}{3}}{z} \]
                3. associate-/l*N/A

                  \[\leadsto y \cdot \color{blue}{\frac{\frac{-1}{3}}{z}} \]
                4. metadata-evalN/A

                  \[\leadsto y \cdot \frac{\mathsf{neg}\left(\frac{1}{3}\right)}{z} \]
                5. distribute-neg-fracN/A

                  \[\leadsto y \cdot \left(\mathsf{neg}\left(\frac{\frac{1}{3}}{z}\right)\right) \]
                6. metadata-evalN/A

                  \[\leadsto y \cdot \left(\mathsf{neg}\left(\frac{\frac{1}{3} \cdot 1}{z}\right)\right) \]
                7. associate-*r/N/A

                  \[\leadsto y \cdot \left(\mathsf{neg}\left(\frac{1}{3} \cdot \frac{1}{z}\right)\right) \]
                8. *-lowering-*.f64N/A

                  \[\leadsto \mathsf{*.f64}\left(y, \color{blue}{\left(\mathsf{neg}\left(\frac{1}{3} \cdot \frac{1}{z}\right)\right)}\right) \]
                9. associate-*r/N/A

                  \[\leadsto \mathsf{*.f64}\left(y, \left(\mathsf{neg}\left(\frac{\frac{1}{3} \cdot 1}{z}\right)\right)\right) \]
                10. metadata-evalN/A

                  \[\leadsto \mathsf{*.f64}\left(y, \left(\mathsf{neg}\left(\frac{\frac{1}{3}}{z}\right)\right)\right) \]
                11. distribute-neg-fracN/A

                  \[\leadsto \mathsf{*.f64}\left(y, \left(\frac{\mathsf{neg}\left(\frac{1}{3}\right)}{\color{blue}{z}}\right)\right) \]
                12. metadata-evalN/A

                  \[\leadsto \mathsf{*.f64}\left(y, \left(\frac{\frac{-1}{3}}{z}\right)\right) \]
                13. /-lowering-/.f6477.7%

                  \[\leadsto \mathsf{*.f64}\left(y, \mathsf{/.f64}\left(\frac{-1}{3}, \color{blue}{z}\right)\right) \]
              5. Simplified77.7%

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

              if -2.6000000000000001e40 < y < 6.5999999999999997e40

              1. Initial program 92.6%

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

                \[\leadsto \color{blue}{x} \]
              4. Step-by-step derivation
                1. Simplified37.0%

                  \[\leadsto \color{blue}{x} \]
              5. Recombined 2 regimes into one program.
              6. Add Preprocessing

              Alternative 15: 95.8% accurate, 1.2× speedup?

              \[\begin{array}{l} \\ x + \frac{\frac{t}{y} - y}{3} \cdot \frac{1}{z} \end{array} \]
              (FPCore (x y z t)
               :precision binary64
               (+ x (* (/ (- (/ t y) y) 3.0) (/ 1.0 z))))
              double code(double x, double y, double z, double t) {
              	return x + ((((t / y) - y) / 3.0) * (1.0 / 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 / y) - y) / 3.0d0) * (1.0d0 / z))
              end function
              
              public static double code(double x, double y, double z, double t) {
              	return x + ((((t / y) - y) / 3.0) * (1.0 / z));
              }
              
              def code(x, y, z, t):
              	return x + ((((t / y) - y) / 3.0) * (1.0 / z))
              
              function code(x, y, z, t)
              	return Float64(x + Float64(Float64(Float64(Float64(t / y) - y) / 3.0) * Float64(1.0 / z)))
              end
              
              function tmp = code(x, y, z, t)
              	tmp = x + ((((t / y) - y) / 3.0) * (1.0 / z));
              end
              
              code[x_, y_, z_, t_] := N[(x + N[(N[(N[(N[(t / y), $MachinePrecision] - y), $MachinePrecision] / 3.0), $MachinePrecision] * N[(1.0 / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
              
              \begin{array}{l}
              
              \\
              x + \frac{\frac{t}{y} - y}{3} \cdot \frac{1}{z}
              \end{array}
              
              Derivation
              1. Initial program 96.0%

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

                \[\leadsto \color{blue}{\left(x + \frac{1}{3} \cdot \frac{t}{y \cdot z}\right) - \frac{1}{3} \cdot \frac{y}{z}} \]
              4. Step-by-step derivation
                1. associate--l+N/A

                  \[\leadsto x + \color{blue}{\left(\frac{1}{3} \cdot \frac{t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right)} \]
                2. +-commutativeN/A

                  \[\leadsto \left(\frac{1}{3} \cdot \frac{t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right) + \color{blue}{x} \]
                3. +-lowering-+.f64N/A

                  \[\leadsto \mathsf{+.f64}\left(\left(\frac{1}{3} \cdot \frac{t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right), \color{blue}{x}\right) \]
                4. associate-*r/N/A

                  \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3} \cdot t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
                5. *-commutativeN/A

                  \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3} \cdot t}{z \cdot y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
                6. times-fracN/A

                  \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3}}{z} \cdot \frac{t}{y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
                7. metadata-evalN/A

                  \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3} \cdot 1}{z} \cdot \frac{t}{y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
                8. associate-*r/N/A

                  \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
                9. associate-*r/N/A

                  \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{\frac{1}{3} \cdot y}{z}\right), x\right) \]
                10. associate-*l/N/A

                  \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{\frac{1}{3}}{z} \cdot y\right), x\right) \]
                11. metadata-evalN/A

                  \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{\frac{1}{3} \cdot 1}{z} \cdot y\right), x\right) \]
                12. associate-*r/N/A

                  \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot y\right), x\right) \]
                13. distribute-lft-out--N/A

                  \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \left(\frac{t}{y} - y\right)\right), x\right) \]
                14. *-lowering-*.f64N/A

                  \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
                15. associate-*r/N/A

                  \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\left(\frac{\frac{1}{3} \cdot 1}{z}\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
                16. metadata-evalN/A

                  \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\left(\frac{\frac{1}{3}}{z}\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
                17. /-lowering-/.f64N/A

                  \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, z\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
                18. --lowering--.f64N/A

                  \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, z\right), \mathsf{\_.f64}\left(\left(\frac{t}{y}\right), y\right)\right), x\right) \]
                19. /-lowering-/.f6494.2%

                  \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, z\right), \mathsf{\_.f64}\left(\mathsf{/.f64}\left(t, y\right), y\right)\right), x\right) \]
              5. Simplified94.2%

                \[\leadsto \color{blue}{\frac{0.3333333333333333}{z} \cdot \left(\frac{t}{y} - y\right) + x} \]
              6. Step-by-step derivation
                1. *-commutativeN/A

                  \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{t}{y} - y\right) \cdot \frac{\frac{1}{3}}{z}\right), x\right) \]
                2. metadata-evalN/A

                  \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{t}{y} - y\right) \cdot \frac{\frac{1}{3}}{z}\right), x\right) \]
                3. associate-/r*N/A

                  \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{t}{y} - y\right) \cdot \frac{1}{3 \cdot z}\right), x\right) \]
                4. *-commutativeN/A

                  \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{t}{y} - y\right) \cdot \frac{1}{z \cdot 3}\right), x\right) \]
                5. associate-*r/N/A

                  \[\leadsto \mathsf{+.f64}\left(\left(\frac{\left(\frac{t}{y} - y\right) \cdot 1}{z \cdot 3}\right), x\right) \]
                6. *-commutativeN/A

                  \[\leadsto \mathsf{+.f64}\left(\left(\frac{\left(\frac{t}{y} - y\right) \cdot 1}{3 \cdot z}\right), x\right) \]
                7. times-fracN/A

                  \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{t}{y} - y}{3} \cdot \frac{1}{z}\right), x\right) \]
                8. *-lowering-*.f64N/A

                  \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\left(\frac{\frac{t}{y} - y}{3}\right), \left(\frac{1}{z}\right)\right), x\right) \]
                9. /-lowering-/.f64N/A

                  \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\left(\frac{t}{y} - y\right), 3\right), \left(\frac{1}{z}\right)\right), x\right) \]
                10. --lowering--.f64N/A

                  \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{\_.f64}\left(\left(\frac{t}{y}\right), y\right), 3\right), \left(\frac{1}{z}\right)\right), x\right) \]
                11. /-lowering-/.f64N/A

                  \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{\_.f64}\left(\mathsf{/.f64}\left(t, y\right), y\right), 3\right), \left(\frac{1}{z}\right)\right), x\right) \]
                12. /-lowering-/.f6494.3%

                  \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\mathsf{\_.f64}\left(\mathsf{/.f64}\left(t, y\right), y\right), 3\right), \mathsf{/.f64}\left(1, z\right)\right), x\right) \]
              7. Applied egg-rr94.3%

                \[\leadsto \color{blue}{\frac{\frac{t}{y} - y}{3} \cdot \frac{1}{z}} + x \]
              8. Final simplification94.3%

                \[\leadsto x + \frac{\frac{t}{y} - y}{3} \cdot \frac{1}{z} \]
              9. Add Preprocessing

              Alternative 16: 95.8% accurate, 1.4× speedup?

              \[\begin{array}{l} \\ x + \frac{\frac{t}{y} - y}{z \cdot 3} \end{array} \]
              (FPCore (x y z t) :precision binary64 (+ x (/ (- (/ t y) y) (* z 3.0))))
              double code(double x, double y, double z, double t) {
              	return x + (((t / y) - y) / (z * 3.0));
              }
              
              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 / y) - y) / (z * 3.0d0))
              end function
              
              public static double code(double x, double y, double z, double t) {
              	return x + (((t / y) - y) / (z * 3.0));
              }
              
              def code(x, y, z, t):
              	return x + (((t / y) - y) / (z * 3.0))
              
              function code(x, y, z, t)
              	return Float64(x + Float64(Float64(Float64(t / y) - y) / Float64(z * 3.0)))
              end
              
              function tmp = code(x, y, z, t)
              	tmp = x + (((t / y) - y) / (z * 3.0));
              end
              
              code[x_, y_, z_, t_] := N[(x + N[(N[(N[(t / y), $MachinePrecision] - y), $MachinePrecision] / N[(z * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
              
              \begin{array}{l}
              
              \\
              x + \frac{\frac{t}{y} - y}{z \cdot 3}
              \end{array}
              
              Derivation
              1. Initial program 96.0%

                \[\left(x - \frac{y}{z \cdot 3}\right) + \frac{t}{\left(z \cdot 3\right) \cdot y} \]
              2. Add Preprocessing
              3. Step-by-step derivation
                1. associate-+l-N/A

                  \[\leadsto x - \color{blue}{\left(\frac{y}{z \cdot 3} - \frac{t}{\left(z \cdot 3\right) \cdot y}\right)} \]
                2. --lowering--.f64N/A

                  \[\leadsto \mathsf{\_.f64}\left(x, \color{blue}{\left(\frac{y}{z \cdot 3} - \frac{t}{\left(z \cdot 3\right) \cdot y}\right)}\right) \]
                3. *-commutativeN/A

                  \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y}{z \cdot 3} - \frac{t}{y \cdot \color{blue}{\left(z \cdot 3\right)}}\right)\right) \]
                4. associate-/r*N/A

                  \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y}{z \cdot 3} - \frac{\frac{t}{y}}{\color{blue}{z \cdot 3}}\right)\right) \]
                5. sub-divN/A

                  \[\leadsto \mathsf{\_.f64}\left(x, \left(\frac{y - \frac{t}{y}}{\color{blue}{z \cdot 3}}\right)\right) \]
                6. /-lowering-/.f64N/A

                  \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\left(y - \frac{t}{y}\right), \color{blue}{\left(z \cdot 3\right)}\right)\right) \]
                7. --lowering--.f64N/A

                  \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{\_.f64}\left(y, \left(\frac{t}{y}\right)\right), \left(\color{blue}{z} \cdot 3\right)\right)\right) \]
                8. /-lowering-/.f64N/A

                  \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{\_.f64}\left(y, \mathsf{/.f64}\left(t, y\right)\right), \left(z \cdot 3\right)\right)\right) \]
                9. *-lowering-*.f6494.3%

                  \[\leadsto \mathsf{\_.f64}\left(x, \mathsf{/.f64}\left(\mathsf{\_.f64}\left(y, \mathsf{/.f64}\left(t, y\right)\right), \mathsf{*.f64}\left(z, \color{blue}{3}\right)\right)\right) \]
              4. Applied egg-rr94.3%

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

                \[\leadsto x + \frac{\frac{t}{y} - y}{z \cdot 3} \]
              6. Add Preprocessing

              Alternative 17: 95.8% accurate, 1.4× speedup?

              \[\begin{array}{l} \\ x + \left(\frac{t}{y} - y\right) \cdot \frac{0.3333333333333333}{z} \end{array} \]
              (FPCore (x y z t)
               :precision binary64
               (+ x (* (- (/ t y) y) (/ 0.3333333333333333 z))))
              double code(double x, double y, double z, double t) {
              	return x + (((t / y) - y) * (0.3333333333333333 / 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 / y) - y) * (0.3333333333333333d0 / z))
              end function
              
              public static double code(double x, double y, double z, double t) {
              	return x + (((t / y) - y) * (0.3333333333333333 / z));
              }
              
              def code(x, y, z, t):
              	return x + (((t / y) - y) * (0.3333333333333333 / z))
              
              function code(x, y, z, t)
              	return Float64(x + Float64(Float64(Float64(t / y) - y) * Float64(0.3333333333333333 / z)))
              end
              
              function tmp = code(x, y, z, t)
              	tmp = x + (((t / y) - y) * (0.3333333333333333 / z));
              end
              
              code[x_, y_, z_, t_] := N[(x + N[(N[(N[(t / y), $MachinePrecision] - y), $MachinePrecision] * N[(0.3333333333333333 / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
              
              \begin{array}{l}
              
              \\
              x + \left(\frac{t}{y} - y\right) \cdot \frac{0.3333333333333333}{z}
              \end{array}
              
              Derivation
              1. Initial program 96.0%

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

                \[\leadsto \color{blue}{\left(x + \frac{1}{3} \cdot \frac{t}{y \cdot z}\right) - \frac{1}{3} \cdot \frac{y}{z}} \]
              4. Step-by-step derivation
                1. associate--l+N/A

                  \[\leadsto x + \color{blue}{\left(\frac{1}{3} \cdot \frac{t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right)} \]
                2. +-commutativeN/A

                  \[\leadsto \left(\frac{1}{3} \cdot \frac{t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right) + \color{blue}{x} \]
                3. +-lowering-+.f64N/A

                  \[\leadsto \mathsf{+.f64}\left(\left(\frac{1}{3} \cdot \frac{t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right), \color{blue}{x}\right) \]
                4. associate-*r/N/A

                  \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3} \cdot t}{y \cdot z} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
                5. *-commutativeN/A

                  \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3} \cdot t}{z \cdot y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
                6. times-fracN/A

                  \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3}}{z} \cdot \frac{t}{y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
                7. metadata-evalN/A

                  \[\leadsto \mathsf{+.f64}\left(\left(\frac{\frac{1}{3} \cdot 1}{z} \cdot \frac{t}{y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
                8. associate-*r/N/A

                  \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{1}{3} \cdot \frac{y}{z}\right), x\right) \]
                9. associate-*r/N/A

                  \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{\frac{1}{3} \cdot y}{z}\right), x\right) \]
                10. associate-*l/N/A

                  \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{\frac{1}{3}}{z} \cdot y\right), x\right) \]
                11. metadata-evalN/A

                  \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \frac{\frac{1}{3} \cdot 1}{z} \cdot y\right), x\right) \]
                12. associate-*r/N/A

                  \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \frac{t}{y} - \left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot y\right), x\right) \]
                13. distribute-lft-out--N/A

                  \[\leadsto \mathsf{+.f64}\left(\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right) \cdot \left(\frac{t}{y} - y\right)\right), x\right) \]
                14. *-lowering-*.f64N/A

                  \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\left(\frac{1}{3} \cdot \frac{1}{z}\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
                15. associate-*r/N/A

                  \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\left(\frac{\frac{1}{3} \cdot 1}{z}\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
                16. metadata-evalN/A

                  \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\left(\frac{\frac{1}{3}}{z}\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
                17. /-lowering-/.f64N/A

                  \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, z\right), \left(\frac{t}{y} - y\right)\right), x\right) \]
                18. --lowering--.f64N/A

                  \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, z\right), \mathsf{\_.f64}\left(\left(\frac{t}{y}\right), y\right)\right), x\right) \]
                19. /-lowering-/.f6494.2%

                  \[\leadsto \mathsf{+.f64}\left(\mathsf{*.f64}\left(\mathsf{/.f64}\left(\frac{1}{3}, z\right), \mathsf{\_.f64}\left(\mathsf{/.f64}\left(t, y\right), y\right)\right), x\right) \]
              5. Simplified94.2%

                \[\leadsto \color{blue}{\frac{0.3333333333333333}{z} \cdot \left(\frac{t}{y} - y\right) + x} \]
              6. Final simplification94.2%

                \[\leadsto x + \left(\frac{t}{y} - y\right) \cdot \frac{0.3333333333333333}{z} \]
              7. Add Preprocessing

              Alternative 18: 30.0% accurate, 15.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 96.0%

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

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

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

                Developer Target 1: 96.5% accurate, 1.0× speedup?

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

                Reproduce

                ?
                herbie shell --seed 2024191 
                (FPCore (x y z t)
                  :name "Diagrams.Solve.Polynomial:cubForm  from diagrams-solve-0.1, H"
                  :precision binary64
                
                  :alt
                  (! :herbie-platform default (+ (- x (/ y (* z 3))) (/ (/ t (* z 3)) y)))
                
                  (+ (- x (/ y (* z 3.0))) (/ t (* (* z 3.0) y))))