Optimisation.CirclePacking:place from circle-packing-0.1.0.4, H

Percentage Accurate: 100.0% → 100.0%
Time: 5.6s
Alternatives: 7
Speedup: 1.0×

Specification

?
\[\begin{array}{l} \\ \left(x + y\right) \cdot \left(1 - z\right) \end{array} \]
(FPCore (x y z) :precision binary64 (* (+ x y) (- 1.0 z)))
double code(double x, double y, double z) {
	return (x + y) * (1.0 - z);
}
real(8) function code(x, y, z)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    code = (x + y) * (1.0d0 - z)
end function
public static double code(double x, double y, double z) {
	return (x + y) * (1.0 - z);
}
def code(x, y, z):
	return (x + y) * (1.0 - z)
function code(x, y, z)
	return Float64(Float64(x + y) * Float64(1.0 - z))
end
function tmp = code(x, y, z)
	tmp = (x + y) * (1.0 - z);
end
code[x_, y_, z_] := N[(N[(x + y), $MachinePrecision] * N[(1.0 - z), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\left(x + y\right) \cdot \left(1 - z\right)
\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 7 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: 100.0% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \left(x + y\right) \cdot \left(1 - z\right) \end{array} \]
(FPCore (x y z) :precision binary64 (* (+ x y) (- 1.0 z)))
double code(double x, double y, double z) {
	return (x + y) * (1.0 - z);
}
real(8) function code(x, y, z)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    code = (x + y) * (1.0d0 - z)
end function
public static double code(double x, double y, double z) {
	return (x + y) * (1.0 - z);
}
def code(x, y, z):
	return (x + y) * (1.0 - z)
function code(x, y, z)
	return Float64(Float64(x + y) * Float64(1.0 - z))
end
function tmp = code(x, y, z)
	tmp = (x + y) * (1.0 - z);
end
code[x_, y_, z_] := N[(N[(x + y), $MachinePrecision] * N[(1.0 - z), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\left(x + y\right) \cdot \left(1 - z\right)
\end{array}

Alternative 1: 100.0% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \left(1 - z\right) \cdot \left(x + y\right) \end{array} \]
(FPCore (x y z) :precision binary64 (* (- 1.0 z) (+ x y)))
double code(double x, double y, double z) {
	return (1.0 - z) * (x + y);
}
real(8) function code(x, y, z)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    code = (1.0d0 - z) * (x + y)
end function
public static double code(double x, double y, double z) {
	return (1.0 - z) * (x + y);
}
def code(x, y, z):
	return (1.0 - z) * (x + y)
function code(x, y, z)
	return Float64(Float64(1.0 - z) * Float64(x + y))
end
function tmp = code(x, y, z)
	tmp = (1.0 - z) * (x + y);
end
code[x_, y_, z_] := N[(N[(1.0 - z), $MachinePrecision] * N[(x + y), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\left(1 - z\right) \cdot \left(x + y\right)
\end{array}
Derivation
  1. Initial program 100.0%

    \[\left(x + y\right) \cdot \left(1 - z\right) \]
  2. Add Preprocessing
  3. Final simplification100.0%

    \[\leadsto \left(1 - z\right) \cdot \left(x + y\right) \]
  4. Add Preprocessing

Alternative 2: 75.7% accurate, 0.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := x \cdot \left(-z\right)\\ t_1 := y \cdot \left(1 - z\right)\\ \mathbf{if}\;z \leq -2.15 \cdot 10^{-13}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq 3.5 \cdot 10^{-16}:\\ \;\;\;\;x + y\\ \mathbf{elif}\;z \leq 320000:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq 1250000:\\ \;\;\;\;t\_0\\ \mathbf{elif}\;z \leq 3.9 \cdot 10^{+40}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq 4.8 \cdot 10^{+45} \lor \neg \left(z \leq 8 \cdot 10^{+56}\right) \land \left(z \leq 8.2 \cdot 10^{+69} \lor \neg \left(z \leq 5 \cdot 10^{+83}\right) \land \left(z \leq 6.6 \cdot 10^{+97} \lor \neg \left(z \leq 4.1 \cdot 10^{+98}\right) \land \left(z \leq 1.1 \cdot 10^{+102} \lor \neg \left(z \leq 1.5 \cdot 10^{+118}\right) \land \left(z \leq 4.2 \cdot 10^{+123} \lor \neg \left(z \leq 1.7 \cdot 10^{+127}\right) \land \left(z \leq 1.4 \cdot 10^{+142} \lor \neg \left(z \leq 1.55 \cdot 10^{+150}\right) \land \left(z \leq 5.2 \cdot 10^{+151} \lor \neg \left(z \leq 2.1 \cdot 10^{+156}\right) \land \left(z \leq 6.6 \cdot 10^{+156} \lor \neg \left(z \leq 5.4 \cdot 10^{+169}\right) \land \left(z \leq 2.3 \cdot 10^{+182} \lor \neg \left(z \leq 2.3 \cdot 10^{+185}\right) \land \left(z \leq 2.7 \cdot 10^{+191} \lor \neg \left(z \leq 8.4 \cdot 10^{+210}\right) \land \left(z \leq 9.2 \cdot 10^{+230} \lor \neg \left(z \leq 7.2 \cdot 10^{+241}\right) \land \left(z \leq 8.2 \cdot 10^{+264} \lor \neg \left(z \leq 9.5 \cdot 10^{+269}\right) \land \left(z \leq 3.5 \cdot 10^{+270} \lor \neg \left(z \leq 7.4 \cdot 10^{+282}\right) \land \left(z \leq 2.9 \cdot 10^{+283} \lor \neg \left(z \leq 9 \cdot 10^{+288}\right) \land z \leq 7.2 \cdot 10^{+291}\right)\right)\right)\right)\right)\right)\right)\right)\right)\right)\right)\right)\right):\\ \;\;\;\;t\_0\\ \mathbf{else}:\\ \;\;\;\;z \cdot \left(-y\right)\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (let* ((t_0 (* x (- z))) (t_1 (* y (- 1.0 z))))
   (if (<= z -2.15e-13)
     t_1
     (if (<= z 3.5e-16)
       (+ x y)
       (if (<= z 320000.0)
         t_1
         (if (<= z 1250000.0)
           t_0
           (if (<= z 3.9e+40)
             t_1
             (if (or (<= z 4.8e+45)
                     (and (not (<= z 8e+56))
                          (or (<= z 8.2e+69)
                              (and (not (<= z 5e+83))
                                   (or (<= z 6.6e+97)
                                       (and (not (<= z 4.1e+98))
                                            (or (<= z 1.1e+102)
                                                (and (not (<= z 1.5e+118))
                                                     (or (<= z 4.2e+123)
                                                         (and (not
                                                               (<= z 1.7e+127))
                                                              (or (<=
                                                                   z
                                                                   1.4e+142)
                                                                  (and (not
                                                                        (<=
                                                                         z
                                                                         1.55e+150))
                                                                       (or (<=
                                                                            z
                                                                            5.2e+151)
                                                                           (and (not
                                                                                 (<=
                                                                                  z
                                                                                  2.1e+156))
                                                                                (or (<=
                                                                                     z
                                                                                     6.6e+156)
                                                                                    (and (not
                                                                                          (<=
                                                                                           z
                                                                                           5.4e+169))
                                                                                         (or (<=
                                                                                              z
                                                                                              2.3e+182)
                                                                                             (and (not
                                                                                                   (<=
                                                                                                    z
                                                                                                    2.3e+185))
                                                                                                  (or (<=
                                                                                                       z
                                                                                                       2.7e+191)
                                                                                                      (and (not
                                                                                                            (<=
                                                                                                             z
                                                                                                             8.4e+210))
                                                                                                           (or (<=
                                                                                                                z
                                                                                                                9.2e+230)
                                                                                                               (and (not
                                                                                                                     (<=
                                                                                                                      z
                                                                                                                      7.2e+241))
                                                                                                                    (or (<=
                                                                                                                         z
                                                                                                                         8.2e+264)
                                                                                                                        (and (not
                                                                                                                              (<=
                                                                                                                               z
                                                                                                                               9.5e+269))
                                                                                                                             (or (<=
                                                                                                                                  z
                                                                                                                                  3.5e+270)
                                                                                                                                 (and (not
                                                                                                                                       (<=
                                                                                                                                        z
                                                                                                                                        7.4e+282))
                                                                                                                                      (or (<=
                                                                                                                                           z
                                                                                                                                           2.9e+283)
                                                                                                                                          (and (not
                                                                                                                                                (<=
                                                                                                                                                 z
                                                                                                                                                 9e+288))
                                                                                                                                               (<=
                                                                                                                                                z
                                                                                                                                                7.2e+291)))))))))))))))))))))))))))))
               t_0
               (* z (- y))))))))))
double code(double x, double y, double z) {
	double t_0 = x * -z;
	double t_1 = y * (1.0 - z);
	double tmp;
	if (z <= -2.15e-13) {
		tmp = t_1;
	} else if (z <= 3.5e-16) {
		tmp = x + y;
	} else if (z <= 320000.0) {
		tmp = t_1;
	} else if (z <= 1250000.0) {
		tmp = t_0;
	} else if (z <= 3.9e+40) {
		tmp = t_1;
	} else if ((z <= 4.8e+45) || (!(z <= 8e+56) && ((z <= 8.2e+69) || (!(z <= 5e+83) && ((z <= 6.6e+97) || (!(z <= 4.1e+98) && ((z <= 1.1e+102) || (!(z <= 1.5e+118) && ((z <= 4.2e+123) || (!(z <= 1.7e+127) && ((z <= 1.4e+142) || (!(z <= 1.55e+150) && ((z <= 5.2e+151) || (!(z <= 2.1e+156) && ((z <= 6.6e+156) || (!(z <= 5.4e+169) && ((z <= 2.3e+182) || (!(z <= 2.3e+185) && ((z <= 2.7e+191) || (!(z <= 8.4e+210) && ((z <= 9.2e+230) || (!(z <= 7.2e+241) && ((z <= 8.2e+264) || (!(z <= 9.5e+269) && ((z <= 3.5e+270) || (!(z <= 7.4e+282) && ((z <= 2.9e+283) || (!(z <= 9e+288) && (z <= 7.2e+291))))))))))))))))))))))))))))) {
		tmp = t_0;
	} else {
		tmp = z * -y;
	}
	return tmp;
}
real(8) function code(x, y, z)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8) :: t_0
    real(8) :: t_1
    real(8) :: tmp
    t_0 = x * -z
    t_1 = y * (1.0d0 - z)
    if (z <= (-2.15d-13)) then
        tmp = t_1
    else if (z <= 3.5d-16) then
        tmp = x + y
    else if (z <= 320000.0d0) then
        tmp = t_1
    else if (z <= 1250000.0d0) then
        tmp = t_0
    else if (z <= 3.9d+40) then
        tmp = t_1
    else if ((z <= 4.8d+45) .or. (.not. (z <= 8d+56)) .and. (z <= 8.2d+69) .or. (.not. (z <= 5d+83)) .and. (z <= 6.6d+97) .or. (.not. (z <= 4.1d+98)) .and. (z <= 1.1d+102) .or. (.not. (z <= 1.5d+118)) .and. (z <= 4.2d+123) .or. (.not. (z <= 1.7d+127)) .and. (z <= 1.4d+142) .or. (.not. (z <= 1.55d+150)) .and. (z <= 5.2d+151) .or. (.not. (z <= 2.1d+156)) .and. (z <= 6.6d+156) .or. (.not. (z <= 5.4d+169)) .and. (z <= 2.3d+182) .or. (.not. (z <= 2.3d+185)) .and. (z <= 2.7d+191) .or. (.not. (z <= 8.4d+210)) .and. (z <= 9.2d+230) .or. (.not. (z <= 7.2d+241)) .and. (z <= 8.2d+264) .or. (.not. (z <= 9.5d+269)) .and. (z <= 3.5d+270) .or. (.not. (z <= 7.4d+282)) .and. (z <= 2.9d+283) .or. (.not. (z <= 9d+288)) .and. (z <= 7.2d+291)) then
        tmp = t_0
    else
        tmp = z * -y
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double t_0 = x * -z;
	double t_1 = y * (1.0 - z);
	double tmp;
	if (z <= -2.15e-13) {
		tmp = t_1;
	} else if (z <= 3.5e-16) {
		tmp = x + y;
	} else if (z <= 320000.0) {
		tmp = t_1;
	} else if (z <= 1250000.0) {
		tmp = t_0;
	} else if (z <= 3.9e+40) {
		tmp = t_1;
	} else if ((z <= 4.8e+45) || (!(z <= 8e+56) && ((z <= 8.2e+69) || (!(z <= 5e+83) && ((z <= 6.6e+97) || (!(z <= 4.1e+98) && ((z <= 1.1e+102) || (!(z <= 1.5e+118) && ((z <= 4.2e+123) || (!(z <= 1.7e+127) && ((z <= 1.4e+142) || (!(z <= 1.55e+150) && ((z <= 5.2e+151) || (!(z <= 2.1e+156) && ((z <= 6.6e+156) || (!(z <= 5.4e+169) && ((z <= 2.3e+182) || (!(z <= 2.3e+185) && ((z <= 2.7e+191) || (!(z <= 8.4e+210) && ((z <= 9.2e+230) || (!(z <= 7.2e+241) && ((z <= 8.2e+264) || (!(z <= 9.5e+269) && ((z <= 3.5e+270) || (!(z <= 7.4e+282) && ((z <= 2.9e+283) || (!(z <= 9e+288) && (z <= 7.2e+291))))))))))))))))))))))))))))) {
		tmp = t_0;
	} else {
		tmp = z * -y;
	}
	return tmp;
}
def code(x, y, z):
	t_0 = x * -z
	t_1 = y * (1.0 - z)
	tmp = 0
	if z <= -2.15e-13:
		tmp = t_1
	elif z <= 3.5e-16:
		tmp = x + y
	elif z <= 320000.0:
		tmp = t_1
	elif z <= 1250000.0:
		tmp = t_0
	elif z <= 3.9e+40:
		tmp = t_1
	elif (z <= 4.8e+45) or (not (z <= 8e+56) and ((z <= 8.2e+69) or (not (z <= 5e+83) and ((z <= 6.6e+97) or (not (z <= 4.1e+98) and ((z <= 1.1e+102) or (not (z <= 1.5e+118) and ((z <= 4.2e+123) or (not (z <= 1.7e+127) and ((z <= 1.4e+142) or (not (z <= 1.55e+150) and ((z <= 5.2e+151) or (not (z <= 2.1e+156) and ((z <= 6.6e+156) or (not (z <= 5.4e+169) and ((z <= 2.3e+182) or (not (z <= 2.3e+185) and ((z <= 2.7e+191) or (not (z <= 8.4e+210) and ((z <= 9.2e+230) or (not (z <= 7.2e+241) and ((z <= 8.2e+264) or (not (z <= 9.5e+269) and ((z <= 3.5e+270) or (not (z <= 7.4e+282) and ((z <= 2.9e+283) or (not (z <= 9e+288) and (z <= 7.2e+291)))))))))))))))))))))))))))):
		tmp = t_0
	else:
		tmp = z * -y
	return tmp
function code(x, y, z)
	t_0 = Float64(x * Float64(-z))
	t_1 = Float64(y * Float64(1.0 - z))
	tmp = 0.0
	if (z <= -2.15e-13)
		tmp = t_1;
	elseif (z <= 3.5e-16)
		tmp = Float64(x + y);
	elseif (z <= 320000.0)
		tmp = t_1;
	elseif (z <= 1250000.0)
		tmp = t_0;
	elseif (z <= 3.9e+40)
		tmp = t_1;
	elseif ((z <= 4.8e+45) || (!(z <= 8e+56) && ((z <= 8.2e+69) || (!(z <= 5e+83) && ((z <= 6.6e+97) || (!(z <= 4.1e+98) && ((z <= 1.1e+102) || (!(z <= 1.5e+118) && ((z <= 4.2e+123) || (!(z <= 1.7e+127) && ((z <= 1.4e+142) || (!(z <= 1.55e+150) && ((z <= 5.2e+151) || (!(z <= 2.1e+156) && ((z <= 6.6e+156) || (!(z <= 5.4e+169) && ((z <= 2.3e+182) || (!(z <= 2.3e+185) && ((z <= 2.7e+191) || (!(z <= 8.4e+210) && ((z <= 9.2e+230) || (!(z <= 7.2e+241) && ((z <= 8.2e+264) || (!(z <= 9.5e+269) && ((z <= 3.5e+270) || (!(z <= 7.4e+282) && ((z <= 2.9e+283) || (!(z <= 9e+288) && (z <= 7.2e+291)))))))))))))))))))))))))))))
		tmp = t_0;
	else
		tmp = Float64(z * Float64(-y));
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	t_0 = x * -z;
	t_1 = y * (1.0 - z);
	tmp = 0.0;
	if (z <= -2.15e-13)
		tmp = t_1;
	elseif (z <= 3.5e-16)
		tmp = x + y;
	elseif (z <= 320000.0)
		tmp = t_1;
	elseif (z <= 1250000.0)
		tmp = t_0;
	elseif (z <= 3.9e+40)
		tmp = t_1;
	elseif ((z <= 4.8e+45) || (~((z <= 8e+56)) && ((z <= 8.2e+69) || (~((z <= 5e+83)) && ((z <= 6.6e+97) || (~((z <= 4.1e+98)) && ((z <= 1.1e+102) || (~((z <= 1.5e+118)) && ((z <= 4.2e+123) || (~((z <= 1.7e+127)) && ((z <= 1.4e+142) || (~((z <= 1.55e+150)) && ((z <= 5.2e+151) || (~((z <= 2.1e+156)) && ((z <= 6.6e+156) || (~((z <= 5.4e+169)) && ((z <= 2.3e+182) || (~((z <= 2.3e+185)) && ((z <= 2.7e+191) || (~((z <= 8.4e+210)) && ((z <= 9.2e+230) || (~((z <= 7.2e+241)) && ((z <= 8.2e+264) || (~((z <= 9.5e+269)) && ((z <= 3.5e+270) || (~((z <= 7.4e+282)) && ((z <= 2.9e+283) || (~((z <= 9e+288)) && (z <= 7.2e+291)))))))))))))))))))))))))))))
		tmp = t_0;
	else
		tmp = z * -y;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := Block[{t$95$0 = N[(x * (-z)), $MachinePrecision]}, Block[{t$95$1 = N[(y * N[(1.0 - z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -2.15e-13], t$95$1, If[LessEqual[z, 3.5e-16], N[(x + y), $MachinePrecision], If[LessEqual[z, 320000.0], t$95$1, If[LessEqual[z, 1250000.0], t$95$0, If[LessEqual[z, 3.9e+40], t$95$1, If[Or[LessEqual[z, 4.8e+45], And[N[Not[LessEqual[z, 8e+56]], $MachinePrecision], Or[LessEqual[z, 8.2e+69], And[N[Not[LessEqual[z, 5e+83]], $MachinePrecision], Or[LessEqual[z, 6.6e+97], And[N[Not[LessEqual[z, 4.1e+98]], $MachinePrecision], Or[LessEqual[z, 1.1e+102], And[N[Not[LessEqual[z, 1.5e+118]], $MachinePrecision], Or[LessEqual[z, 4.2e+123], And[N[Not[LessEqual[z, 1.7e+127]], $MachinePrecision], Or[LessEqual[z, 1.4e+142], And[N[Not[LessEqual[z, 1.55e+150]], $MachinePrecision], Or[LessEqual[z, 5.2e+151], And[N[Not[LessEqual[z, 2.1e+156]], $MachinePrecision], Or[LessEqual[z, 6.6e+156], And[N[Not[LessEqual[z, 5.4e+169]], $MachinePrecision], Or[LessEqual[z, 2.3e+182], And[N[Not[LessEqual[z, 2.3e+185]], $MachinePrecision], Or[LessEqual[z, 2.7e+191], And[N[Not[LessEqual[z, 8.4e+210]], $MachinePrecision], Or[LessEqual[z, 9.2e+230], And[N[Not[LessEqual[z, 7.2e+241]], $MachinePrecision], Or[LessEqual[z, 8.2e+264], And[N[Not[LessEqual[z, 9.5e+269]], $MachinePrecision], Or[LessEqual[z, 3.5e+270], And[N[Not[LessEqual[z, 7.4e+282]], $MachinePrecision], Or[LessEqual[z, 2.9e+283], And[N[Not[LessEqual[z, 9e+288]], $MachinePrecision], LessEqual[z, 7.2e+291]]]]]]]]]]]]]]]]]]]]]]]]]]]]], t$95$0, N[(z * (-y)), $MachinePrecision]]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := x \cdot \left(-z\right)\\
t_1 := y \cdot \left(1 - z\right)\\
\mathbf{if}\;z \leq -2.15 \cdot 10^{-13}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;z \leq 3.5 \cdot 10^{-16}:\\
\;\;\;\;x + y\\

\mathbf{elif}\;z \leq 320000:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;z \leq 1250000:\\
\;\;\;\;t\_0\\

\mathbf{elif}\;z \leq 3.9 \cdot 10^{+40}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;z \leq 4.8 \cdot 10^{+45} \lor \neg \left(z \leq 8 \cdot 10^{+56}\right) \land \left(z \leq 8.2 \cdot 10^{+69} \lor \neg \left(z \leq 5 \cdot 10^{+83}\right) \land \left(z \leq 6.6 \cdot 10^{+97} \lor \neg \left(z \leq 4.1 \cdot 10^{+98}\right) \land \left(z \leq 1.1 \cdot 10^{+102} \lor \neg \left(z \leq 1.5 \cdot 10^{+118}\right) \land \left(z \leq 4.2 \cdot 10^{+123} \lor \neg \left(z \leq 1.7 \cdot 10^{+127}\right) \land \left(z \leq 1.4 \cdot 10^{+142} \lor \neg \left(z \leq 1.55 \cdot 10^{+150}\right) \land \left(z \leq 5.2 \cdot 10^{+151} \lor \neg \left(z \leq 2.1 \cdot 10^{+156}\right) \land \left(z \leq 6.6 \cdot 10^{+156} \lor \neg \left(z \leq 5.4 \cdot 10^{+169}\right) \land \left(z \leq 2.3 \cdot 10^{+182} \lor \neg \left(z \leq 2.3 \cdot 10^{+185}\right) \land \left(z \leq 2.7 \cdot 10^{+191} \lor \neg \left(z \leq 8.4 \cdot 10^{+210}\right) \land \left(z \leq 9.2 \cdot 10^{+230} \lor \neg \left(z \leq 7.2 \cdot 10^{+241}\right) \land \left(z \leq 8.2 \cdot 10^{+264} \lor \neg \left(z \leq 9.5 \cdot 10^{+269}\right) \land \left(z \leq 3.5 \cdot 10^{+270} \lor \neg \left(z \leq 7.4 \cdot 10^{+282}\right) \land \left(z \leq 2.9 \cdot 10^{+283} \lor \neg \left(z \leq 9 \cdot 10^{+288}\right) \land z \leq 7.2 \cdot 10^{+291}\right)\right)\right)\right)\right)\right)\right)\right)\right)\right)\right)\right)\right):\\
\;\;\;\;t\_0\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if z < -2.1499999999999999e-13 or 3.50000000000000017e-16 < z < 3.2e5 or 1.25e6 < z < 3.9000000000000001e40

    1. Initial program 100.0%

      \[\left(x + y\right) \cdot \left(1 - z\right) \]
    2. Add Preprocessing
    3. Taylor expanded in x around 0 45.5%

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

    if -2.1499999999999999e-13 < z < 3.50000000000000017e-16

    1. Initial program 100.0%

      \[\left(x + y\right) \cdot \left(1 - z\right) \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 100.0%

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

        \[\leadsto \color{blue}{y + x} \]
    5. Simplified100.0%

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

    if 3.2e5 < z < 1.25e6 or 3.9000000000000001e40 < z < 4.79999999999999979e45 or 8.00000000000000074e56 < z < 8.1999999999999998e69 or 5.00000000000000029e83 < z < 6.6000000000000003e97 or 4.1e98 < z < 1.10000000000000004e102 or 1.5e118 < z < 4.19999999999999988e123 or 1.69999999999999989e127 < z < 1.4e142 or 1.55000000000000007e150 < z < 5.20000000000000026e151 or 2.09999999999999981e156 < z < 6.5999999999999997e156 or 5.39999999999999981e169 < z < 2.3e182 or 2.3000000000000001e185 < z < 2.69999999999999996e191 or 8.3999999999999994e210 < z < 9.1999999999999993e230 or 7.19999999999999966e241 < z < 8.1999999999999999e264 or 9.50000000000000044e269 < z < 3.4999999999999999e270 or 7.4000000000000004e282 < z < 2.8999999999999999e283 or 9.00000000000000034e288 < z < 7.1999999999999995e291

    1. Initial program 100.0%

      \[\left(x + y\right) \cdot \left(1 - z\right) \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf 96.8%

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

        \[\leadsto \color{blue}{-z \cdot \left(x + y\right)} \]
      2. distribute-lft-neg-out96.8%

        \[\leadsto \color{blue}{\left(-z\right) \cdot \left(x + y\right)} \]
      3. *-commutative96.8%

        \[\leadsto \color{blue}{\left(x + y\right) \cdot \left(-z\right)} \]
      4. +-commutative96.8%

        \[\leadsto \color{blue}{\left(y + x\right)} \cdot \left(-z\right) \]
    5. Simplified96.8%

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

      \[\leadsto \color{blue}{-1 \cdot \left(x \cdot z\right)} \]
    7. Step-by-step derivation
      1. associate-*r*44.6%

        \[\leadsto \color{blue}{\left(-1 \cdot x\right) \cdot z} \]
      2. mul-1-neg44.6%

        \[\leadsto \color{blue}{\left(-x\right)} \cdot z \]
    8. Simplified44.6%

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

    if 4.79999999999999979e45 < z < 8.00000000000000074e56 or 8.1999999999999998e69 < z < 5.00000000000000029e83 or 6.6000000000000003e97 < z < 4.1e98 or 1.10000000000000004e102 < z < 1.5e118 or 4.19999999999999988e123 < z < 1.69999999999999989e127 or 1.4e142 < z < 1.55000000000000007e150 or 5.20000000000000026e151 < z < 2.09999999999999981e156 or 6.5999999999999997e156 < z < 5.39999999999999981e169 or 2.3e182 < z < 2.3000000000000001e185 or 2.69999999999999996e191 < z < 8.3999999999999994e210 or 9.1999999999999993e230 < z < 7.19999999999999966e241 or 8.1999999999999999e264 < z < 9.50000000000000044e269 or 3.4999999999999999e270 < z < 7.4000000000000004e282 or 2.8999999999999999e283 < z < 9.00000000000000034e288 or 7.1999999999999995e291 < z

    1. Initial program 100.0%

      \[\left(x + y\right) \cdot \left(1 - z\right) \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf 100.0%

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

        \[\leadsto \color{blue}{-z \cdot \left(x + y\right)} \]
      2. distribute-lft-neg-out100.0%

        \[\leadsto \color{blue}{\left(-z\right) \cdot \left(x + y\right)} \]
      3. *-commutative100.0%

        \[\leadsto \color{blue}{\left(x + y\right) \cdot \left(-z\right)} \]
      4. +-commutative100.0%

        \[\leadsto \color{blue}{\left(y + x\right)} \cdot \left(-z\right) \]
    5. Simplified100.0%

      \[\leadsto \color{blue}{\left(y + x\right) \cdot \left(-z\right)} \]
    6. Taylor expanded in y around inf 48.1%

      \[\leadsto \color{blue}{-1 \cdot \left(y \cdot z\right)} \]
    7. Step-by-step derivation
      1. associate-*r*48.1%

        \[\leadsto \color{blue}{\left(-1 \cdot y\right) \cdot z} \]
      2. mul-1-neg48.1%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -2.15 \cdot 10^{-13}:\\ \;\;\;\;y \cdot \left(1 - z\right)\\ \mathbf{elif}\;z \leq 3.5 \cdot 10^{-16}:\\ \;\;\;\;x + y\\ \mathbf{elif}\;z \leq 320000:\\ \;\;\;\;y \cdot \left(1 - z\right)\\ \mathbf{elif}\;z \leq 1250000:\\ \;\;\;\;x \cdot \left(-z\right)\\ \mathbf{elif}\;z \leq 3.9 \cdot 10^{+40}:\\ \;\;\;\;y \cdot \left(1 - z\right)\\ \mathbf{elif}\;z \leq 4.8 \cdot 10^{+45} \lor \neg \left(z \leq 8 \cdot 10^{+56}\right) \land \left(z \leq 8.2 \cdot 10^{+69} \lor \neg \left(z \leq 5 \cdot 10^{+83}\right) \land \left(z \leq 6.6 \cdot 10^{+97} \lor \neg \left(z \leq 4.1 \cdot 10^{+98}\right) \land \left(z \leq 1.1 \cdot 10^{+102} \lor \neg \left(z \leq 1.5 \cdot 10^{+118}\right) \land \left(z \leq 4.2 \cdot 10^{+123} \lor \neg \left(z \leq 1.7 \cdot 10^{+127}\right) \land \left(z \leq 1.4 \cdot 10^{+142} \lor \neg \left(z \leq 1.55 \cdot 10^{+150}\right) \land \left(z \leq 5.2 \cdot 10^{+151} \lor \neg \left(z \leq 2.1 \cdot 10^{+156}\right) \land \left(z \leq 6.6 \cdot 10^{+156} \lor \neg \left(z \leq 5.4 \cdot 10^{+169}\right) \land \left(z \leq 2.3 \cdot 10^{+182} \lor \neg \left(z \leq 2.3 \cdot 10^{+185}\right) \land \left(z \leq 2.7 \cdot 10^{+191} \lor \neg \left(z \leq 8.4 \cdot 10^{+210}\right) \land \left(z \leq 9.2 \cdot 10^{+230} \lor \neg \left(z \leq 7.2 \cdot 10^{+241}\right) \land \left(z \leq 8.2 \cdot 10^{+264} \lor \neg \left(z \leq 9.5 \cdot 10^{+269}\right) \land \left(z \leq 3.5 \cdot 10^{+270} \lor \neg \left(z \leq 7.4 \cdot 10^{+282}\right) \land \left(z \leq 2.9 \cdot 10^{+283} \lor \neg \left(z \leq 9 \cdot 10^{+288}\right) \land z \leq 7.2 \cdot 10^{+291}\right)\right)\right)\right)\right)\right)\right)\right)\right)\right)\right)\right)\right):\\ \;\;\;\;x \cdot \left(-z\right)\\ \mathbf{else}:\\ \;\;\;\;z \cdot \left(-y\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 3: 75.3% accurate, 0.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := z \cdot \left(-y\right)\\ t_1 := x \cdot \left(1 - z\right)\\ t_2 := y \cdot \left(1 - z\right)\\ t_3 := x \cdot \left(-z\right)\\ \mathbf{if}\;z \leq -2.15 \cdot 10^{-13}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;z \leq 3.5 \cdot 10^{-16}:\\ \;\;\;\;x + y\\ \mathbf{elif}\;z \leq 0.092:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;z \leq 1250000:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq 2.5 \cdot 10^{+33}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;z \leq 1.4 \cdot 10^{+42}:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;z \leq 1.45 \cdot 10^{+58}:\\ \;\;\;\;t\_0\\ \mathbf{elif}\;z \leq 7.5 \cdot 10^{+70}:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;z \leq 2.9 \cdot 10^{+83}:\\ \;\;\;\;t\_0\\ \mathbf{elif}\;z \leq 3.5 \cdot 10^{+97}:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;z \leq 4.8 \cdot 10^{+100}:\\ \;\;\;\;t\_0\\ \mathbf{elif}\;z \leq 1.55 \cdot 10^{+102}:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;z \leq 2 \cdot 10^{+118}:\\ \;\;\;\;t\_0\\ \mathbf{elif}\;z \leq 1.5 \cdot 10^{+124}:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;z \leq 1.45 \cdot 10^{+126}:\\ \;\;\;\;t\_0\\ \mathbf{elif}\;z \leq 4.4 \cdot 10^{+139}:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;z \leq 4.2 \cdot 10^{+150}:\\ \;\;\;\;t\_0\\ \mathbf{elif}\;z \leq 1.65 \cdot 10^{+154}:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;z \leq 2 \cdot 10^{+156}:\\ \;\;\;\;t\_0\\ \mathbf{elif}\;z \leq 4.5 \cdot 10^{+156}:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;z \leq 1.9 \cdot 10^{+174}:\\ \;\;\;\;t\_0\\ \mathbf{elif}\;z \leq 4.6 \cdot 10^{+180}:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;z \leq 2.3 \cdot 10^{+185}:\\ \;\;\;\;t\_0\\ \mathbf{elif}\;z \leq 2.5 \cdot 10^{+191}:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;z \leq 1.85 \cdot 10^{+211}:\\ \;\;\;\;t\_0\\ \mathbf{elif}\;z \leq 4.7 \cdot 10^{+231}:\\ \;\;\;\;t\_3\\ \mathbf{elif}\;z \leq 1.4 \cdot 10^{+241}:\\ \;\;\;\;t\_0\\ \mathbf{elif}\;z \leq 2.6 \cdot 10^{+266}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq 1.05 \cdot 10^{+270} \lor \neg \left(z \leq 2.8 \cdot 10^{+270}\right) \land \left(z \leq 1.6 \cdot 10^{+281} \lor \neg \left(z \leq 2.05 \cdot 10^{+283} \lor \neg \left(z \leq 2.65 \cdot 10^{+289}\right) \land z \leq 2.8 \cdot 10^{+295}\right)\right):\\ \;\;\;\;t\_0\\ \mathbf{else}:\\ \;\;\;\;t\_3\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (let* ((t_0 (* z (- y)))
        (t_1 (* x (- 1.0 z)))
        (t_2 (* y (- 1.0 z)))
        (t_3 (* x (- z))))
   (if (<= z -2.15e-13)
     t_2
     (if (<= z 3.5e-16)
       (+ x y)
       (if (<= z 0.092)
         t_2
         (if (<= z 1250000.0)
           t_1
           (if (<= z 2.5e+33)
             t_2
             (if (<= z 1.4e+42)
               t_3
               (if (<= z 1.45e+58)
                 t_0
                 (if (<= z 7.5e+70)
                   t_3
                   (if (<= z 2.9e+83)
                     t_0
                     (if (<= z 3.5e+97)
                       t_3
                       (if (<= z 4.8e+100)
                         t_0
                         (if (<= z 1.55e+102)
                           t_3
                           (if (<= z 2e+118)
                             t_0
                             (if (<= z 1.5e+124)
                               t_3
                               (if (<= z 1.45e+126)
                                 t_0
                                 (if (<= z 4.4e+139)
                                   t_3
                                   (if (<= z 4.2e+150)
                                     t_0
                                     (if (<= z 1.65e+154)
                                       t_3
                                       (if (<= z 2e+156)
                                         t_0
                                         (if (<= z 4.5e+156)
                                           t_3
                                           (if (<= z 1.9e+174)
                                             t_0
                                             (if (<= z 4.6e+180)
                                               t_3
                                               (if (<= z 2.3e+185)
                                                 t_0
                                                 (if (<= z 2.5e+191)
                                                   t_3
                                                   (if (<= z 1.85e+211)
                                                     t_0
                                                     (if (<= z 4.7e+231)
                                                       t_3
                                                       (if (<= z 1.4e+241)
                                                         t_0
                                                         (if (<= z 2.6e+266)
                                                           t_1
                                                           (if (or (<=
                                                                    z
                                                                    1.05e+270)
                                                                   (and (not
                                                                         (<=
                                                                          z
                                                                          2.8e+270))
                                                                        (or (<=
                                                                             z
                                                                             1.6e+281)
                                                                            (not
                                                                             (or (<=
                                                                                  z
                                                                                  2.05e+283)
                                                                                 (and (not
                                                                                       (<=
                                                                                        z
                                                                                        2.65e+289))
                                                                                      (<=
                                                                                       z
                                                                                       2.8e+295)))))))
                                                             t_0
                                                             t_3)))))))))))))))))))))))))))))))
double code(double x, double y, double z) {
	double t_0 = z * -y;
	double t_1 = x * (1.0 - z);
	double t_2 = y * (1.0 - z);
	double t_3 = x * -z;
	double tmp;
	if (z <= -2.15e-13) {
		tmp = t_2;
	} else if (z <= 3.5e-16) {
		tmp = x + y;
	} else if (z <= 0.092) {
		tmp = t_2;
	} else if (z <= 1250000.0) {
		tmp = t_1;
	} else if (z <= 2.5e+33) {
		tmp = t_2;
	} else if (z <= 1.4e+42) {
		tmp = t_3;
	} else if (z <= 1.45e+58) {
		tmp = t_0;
	} else if (z <= 7.5e+70) {
		tmp = t_3;
	} else if (z <= 2.9e+83) {
		tmp = t_0;
	} else if (z <= 3.5e+97) {
		tmp = t_3;
	} else if (z <= 4.8e+100) {
		tmp = t_0;
	} else if (z <= 1.55e+102) {
		tmp = t_3;
	} else if (z <= 2e+118) {
		tmp = t_0;
	} else if (z <= 1.5e+124) {
		tmp = t_3;
	} else if (z <= 1.45e+126) {
		tmp = t_0;
	} else if (z <= 4.4e+139) {
		tmp = t_3;
	} else if (z <= 4.2e+150) {
		tmp = t_0;
	} else if (z <= 1.65e+154) {
		tmp = t_3;
	} else if (z <= 2e+156) {
		tmp = t_0;
	} else if (z <= 4.5e+156) {
		tmp = t_3;
	} else if (z <= 1.9e+174) {
		tmp = t_0;
	} else if (z <= 4.6e+180) {
		tmp = t_3;
	} else if (z <= 2.3e+185) {
		tmp = t_0;
	} else if (z <= 2.5e+191) {
		tmp = t_3;
	} else if (z <= 1.85e+211) {
		tmp = t_0;
	} else if (z <= 4.7e+231) {
		tmp = t_3;
	} else if (z <= 1.4e+241) {
		tmp = t_0;
	} else if (z <= 2.6e+266) {
		tmp = t_1;
	} else if ((z <= 1.05e+270) || (!(z <= 2.8e+270) && ((z <= 1.6e+281) || !((z <= 2.05e+283) || (!(z <= 2.65e+289) && (z <= 2.8e+295)))))) {
		tmp = t_0;
	} else {
		tmp = t_3;
	}
	return tmp;
}
real(8) function code(x, y, z)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8) :: t_0
    real(8) :: t_1
    real(8) :: t_2
    real(8) :: t_3
    real(8) :: tmp
    t_0 = z * -y
    t_1 = x * (1.0d0 - z)
    t_2 = y * (1.0d0 - z)
    t_3 = x * -z
    if (z <= (-2.15d-13)) then
        tmp = t_2
    else if (z <= 3.5d-16) then
        tmp = x + y
    else if (z <= 0.092d0) then
        tmp = t_2
    else if (z <= 1250000.0d0) then
        tmp = t_1
    else if (z <= 2.5d+33) then
        tmp = t_2
    else if (z <= 1.4d+42) then
        tmp = t_3
    else if (z <= 1.45d+58) then
        tmp = t_0
    else if (z <= 7.5d+70) then
        tmp = t_3
    else if (z <= 2.9d+83) then
        tmp = t_0
    else if (z <= 3.5d+97) then
        tmp = t_3
    else if (z <= 4.8d+100) then
        tmp = t_0
    else if (z <= 1.55d+102) then
        tmp = t_3
    else if (z <= 2d+118) then
        tmp = t_0
    else if (z <= 1.5d+124) then
        tmp = t_3
    else if (z <= 1.45d+126) then
        tmp = t_0
    else if (z <= 4.4d+139) then
        tmp = t_3
    else if (z <= 4.2d+150) then
        tmp = t_0
    else if (z <= 1.65d+154) then
        tmp = t_3
    else if (z <= 2d+156) then
        tmp = t_0
    else if (z <= 4.5d+156) then
        tmp = t_3
    else if (z <= 1.9d+174) then
        tmp = t_0
    else if (z <= 4.6d+180) then
        tmp = t_3
    else if (z <= 2.3d+185) then
        tmp = t_0
    else if (z <= 2.5d+191) then
        tmp = t_3
    else if (z <= 1.85d+211) then
        tmp = t_0
    else if (z <= 4.7d+231) then
        tmp = t_3
    else if (z <= 1.4d+241) then
        tmp = t_0
    else if (z <= 2.6d+266) then
        tmp = t_1
    else if ((z <= 1.05d+270) .or. (.not. (z <= 2.8d+270)) .and. (z <= 1.6d+281) .or. (.not. (z <= 2.05d+283) .or. (.not. (z <= 2.65d+289)) .and. (z <= 2.8d+295))) then
        tmp = t_0
    else
        tmp = t_3
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double t_0 = z * -y;
	double t_1 = x * (1.0 - z);
	double t_2 = y * (1.0 - z);
	double t_3 = x * -z;
	double tmp;
	if (z <= -2.15e-13) {
		tmp = t_2;
	} else if (z <= 3.5e-16) {
		tmp = x + y;
	} else if (z <= 0.092) {
		tmp = t_2;
	} else if (z <= 1250000.0) {
		tmp = t_1;
	} else if (z <= 2.5e+33) {
		tmp = t_2;
	} else if (z <= 1.4e+42) {
		tmp = t_3;
	} else if (z <= 1.45e+58) {
		tmp = t_0;
	} else if (z <= 7.5e+70) {
		tmp = t_3;
	} else if (z <= 2.9e+83) {
		tmp = t_0;
	} else if (z <= 3.5e+97) {
		tmp = t_3;
	} else if (z <= 4.8e+100) {
		tmp = t_0;
	} else if (z <= 1.55e+102) {
		tmp = t_3;
	} else if (z <= 2e+118) {
		tmp = t_0;
	} else if (z <= 1.5e+124) {
		tmp = t_3;
	} else if (z <= 1.45e+126) {
		tmp = t_0;
	} else if (z <= 4.4e+139) {
		tmp = t_3;
	} else if (z <= 4.2e+150) {
		tmp = t_0;
	} else if (z <= 1.65e+154) {
		tmp = t_3;
	} else if (z <= 2e+156) {
		tmp = t_0;
	} else if (z <= 4.5e+156) {
		tmp = t_3;
	} else if (z <= 1.9e+174) {
		tmp = t_0;
	} else if (z <= 4.6e+180) {
		tmp = t_3;
	} else if (z <= 2.3e+185) {
		tmp = t_0;
	} else if (z <= 2.5e+191) {
		tmp = t_3;
	} else if (z <= 1.85e+211) {
		tmp = t_0;
	} else if (z <= 4.7e+231) {
		tmp = t_3;
	} else if (z <= 1.4e+241) {
		tmp = t_0;
	} else if (z <= 2.6e+266) {
		tmp = t_1;
	} else if ((z <= 1.05e+270) || (!(z <= 2.8e+270) && ((z <= 1.6e+281) || !((z <= 2.05e+283) || (!(z <= 2.65e+289) && (z <= 2.8e+295)))))) {
		tmp = t_0;
	} else {
		tmp = t_3;
	}
	return tmp;
}
def code(x, y, z):
	t_0 = z * -y
	t_1 = x * (1.0 - z)
	t_2 = y * (1.0 - z)
	t_3 = x * -z
	tmp = 0
	if z <= -2.15e-13:
		tmp = t_2
	elif z <= 3.5e-16:
		tmp = x + y
	elif z <= 0.092:
		tmp = t_2
	elif z <= 1250000.0:
		tmp = t_1
	elif z <= 2.5e+33:
		tmp = t_2
	elif z <= 1.4e+42:
		tmp = t_3
	elif z <= 1.45e+58:
		tmp = t_0
	elif z <= 7.5e+70:
		tmp = t_3
	elif z <= 2.9e+83:
		tmp = t_0
	elif z <= 3.5e+97:
		tmp = t_3
	elif z <= 4.8e+100:
		tmp = t_0
	elif z <= 1.55e+102:
		tmp = t_3
	elif z <= 2e+118:
		tmp = t_0
	elif z <= 1.5e+124:
		tmp = t_3
	elif z <= 1.45e+126:
		tmp = t_0
	elif z <= 4.4e+139:
		tmp = t_3
	elif z <= 4.2e+150:
		tmp = t_0
	elif z <= 1.65e+154:
		tmp = t_3
	elif z <= 2e+156:
		tmp = t_0
	elif z <= 4.5e+156:
		tmp = t_3
	elif z <= 1.9e+174:
		tmp = t_0
	elif z <= 4.6e+180:
		tmp = t_3
	elif z <= 2.3e+185:
		tmp = t_0
	elif z <= 2.5e+191:
		tmp = t_3
	elif z <= 1.85e+211:
		tmp = t_0
	elif z <= 4.7e+231:
		tmp = t_3
	elif z <= 1.4e+241:
		tmp = t_0
	elif z <= 2.6e+266:
		tmp = t_1
	elif (z <= 1.05e+270) or (not (z <= 2.8e+270) and ((z <= 1.6e+281) or not ((z <= 2.05e+283) or (not (z <= 2.65e+289) and (z <= 2.8e+295))))):
		tmp = t_0
	else:
		tmp = t_3
	return tmp
function code(x, y, z)
	t_0 = Float64(z * Float64(-y))
	t_1 = Float64(x * Float64(1.0 - z))
	t_2 = Float64(y * Float64(1.0 - z))
	t_3 = Float64(x * Float64(-z))
	tmp = 0.0
	if (z <= -2.15e-13)
		tmp = t_2;
	elseif (z <= 3.5e-16)
		tmp = Float64(x + y);
	elseif (z <= 0.092)
		tmp = t_2;
	elseif (z <= 1250000.0)
		tmp = t_1;
	elseif (z <= 2.5e+33)
		tmp = t_2;
	elseif (z <= 1.4e+42)
		tmp = t_3;
	elseif (z <= 1.45e+58)
		tmp = t_0;
	elseif (z <= 7.5e+70)
		tmp = t_3;
	elseif (z <= 2.9e+83)
		tmp = t_0;
	elseif (z <= 3.5e+97)
		tmp = t_3;
	elseif (z <= 4.8e+100)
		tmp = t_0;
	elseif (z <= 1.55e+102)
		tmp = t_3;
	elseif (z <= 2e+118)
		tmp = t_0;
	elseif (z <= 1.5e+124)
		tmp = t_3;
	elseif (z <= 1.45e+126)
		tmp = t_0;
	elseif (z <= 4.4e+139)
		tmp = t_3;
	elseif (z <= 4.2e+150)
		tmp = t_0;
	elseif (z <= 1.65e+154)
		tmp = t_3;
	elseif (z <= 2e+156)
		tmp = t_0;
	elseif (z <= 4.5e+156)
		tmp = t_3;
	elseif (z <= 1.9e+174)
		tmp = t_0;
	elseif (z <= 4.6e+180)
		tmp = t_3;
	elseif (z <= 2.3e+185)
		tmp = t_0;
	elseif (z <= 2.5e+191)
		tmp = t_3;
	elseif (z <= 1.85e+211)
		tmp = t_0;
	elseif (z <= 4.7e+231)
		tmp = t_3;
	elseif (z <= 1.4e+241)
		tmp = t_0;
	elseif (z <= 2.6e+266)
		tmp = t_1;
	elseif ((z <= 1.05e+270) || (!(z <= 2.8e+270) && ((z <= 1.6e+281) || !((z <= 2.05e+283) || (!(z <= 2.65e+289) && (z <= 2.8e+295))))))
		tmp = t_0;
	else
		tmp = t_3;
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	t_0 = z * -y;
	t_1 = x * (1.0 - z);
	t_2 = y * (1.0 - z);
	t_3 = x * -z;
	tmp = 0.0;
	if (z <= -2.15e-13)
		tmp = t_2;
	elseif (z <= 3.5e-16)
		tmp = x + y;
	elseif (z <= 0.092)
		tmp = t_2;
	elseif (z <= 1250000.0)
		tmp = t_1;
	elseif (z <= 2.5e+33)
		tmp = t_2;
	elseif (z <= 1.4e+42)
		tmp = t_3;
	elseif (z <= 1.45e+58)
		tmp = t_0;
	elseif (z <= 7.5e+70)
		tmp = t_3;
	elseif (z <= 2.9e+83)
		tmp = t_0;
	elseif (z <= 3.5e+97)
		tmp = t_3;
	elseif (z <= 4.8e+100)
		tmp = t_0;
	elseif (z <= 1.55e+102)
		tmp = t_3;
	elseif (z <= 2e+118)
		tmp = t_0;
	elseif (z <= 1.5e+124)
		tmp = t_3;
	elseif (z <= 1.45e+126)
		tmp = t_0;
	elseif (z <= 4.4e+139)
		tmp = t_3;
	elseif (z <= 4.2e+150)
		tmp = t_0;
	elseif (z <= 1.65e+154)
		tmp = t_3;
	elseif (z <= 2e+156)
		tmp = t_0;
	elseif (z <= 4.5e+156)
		tmp = t_3;
	elseif (z <= 1.9e+174)
		tmp = t_0;
	elseif (z <= 4.6e+180)
		tmp = t_3;
	elseif (z <= 2.3e+185)
		tmp = t_0;
	elseif (z <= 2.5e+191)
		tmp = t_3;
	elseif (z <= 1.85e+211)
		tmp = t_0;
	elseif (z <= 4.7e+231)
		tmp = t_3;
	elseif (z <= 1.4e+241)
		tmp = t_0;
	elseif (z <= 2.6e+266)
		tmp = t_1;
	elseif ((z <= 1.05e+270) || (~((z <= 2.8e+270)) && ((z <= 1.6e+281) || ~(((z <= 2.05e+283) || (~((z <= 2.65e+289)) && (z <= 2.8e+295)))))))
		tmp = t_0;
	else
		tmp = t_3;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := Block[{t$95$0 = N[(z * (-y)), $MachinePrecision]}, Block[{t$95$1 = N[(x * N[(1.0 - z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(y * N[(1.0 - z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(x * (-z)), $MachinePrecision]}, If[LessEqual[z, -2.15e-13], t$95$2, If[LessEqual[z, 3.5e-16], N[(x + y), $MachinePrecision], If[LessEqual[z, 0.092], t$95$2, If[LessEqual[z, 1250000.0], t$95$1, If[LessEqual[z, 2.5e+33], t$95$2, If[LessEqual[z, 1.4e+42], t$95$3, If[LessEqual[z, 1.45e+58], t$95$0, If[LessEqual[z, 7.5e+70], t$95$3, If[LessEqual[z, 2.9e+83], t$95$0, If[LessEqual[z, 3.5e+97], t$95$3, If[LessEqual[z, 4.8e+100], t$95$0, If[LessEqual[z, 1.55e+102], t$95$3, If[LessEqual[z, 2e+118], t$95$0, If[LessEqual[z, 1.5e+124], t$95$3, If[LessEqual[z, 1.45e+126], t$95$0, If[LessEqual[z, 4.4e+139], t$95$3, If[LessEqual[z, 4.2e+150], t$95$0, If[LessEqual[z, 1.65e+154], t$95$3, If[LessEqual[z, 2e+156], t$95$0, If[LessEqual[z, 4.5e+156], t$95$3, If[LessEqual[z, 1.9e+174], t$95$0, If[LessEqual[z, 4.6e+180], t$95$3, If[LessEqual[z, 2.3e+185], t$95$0, If[LessEqual[z, 2.5e+191], t$95$3, If[LessEqual[z, 1.85e+211], t$95$0, If[LessEqual[z, 4.7e+231], t$95$3, If[LessEqual[z, 1.4e+241], t$95$0, If[LessEqual[z, 2.6e+266], t$95$1, If[Or[LessEqual[z, 1.05e+270], And[N[Not[LessEqual[z, 2.8e+270]], $MachinePrecision], Or[LessEqual[z, 1.6e+281], N[Not[Or[LessEqual[z, 2.05e+283], And[N[Not[LessEqual[z, 2.65e+289]], $MachinePrecision], LessEqual[z, 2.8e+295]]]], $MachinePrecision]]]], t$95$0, t$95$3]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := z \cdot \left(-y\right)\\
t_1 := x \cdot \left(1 - z\right)\\
t_2 := y \cdot \left(1 - z\right)\\
t_3 := x \cdot \left(-z\right)\\
\mathbf{if}\;z \leq -2.15 \cdot 10^{-13}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;z \leq 3.5 \cdot 10^{-16}:\\
\;\;\;\;x + y\\

\mathbf{elif}\;z \leq 0.092:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;z \leq 1250000:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;z \leq 2.5 \cdot 10^{+33}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;z \leq 1.4 \cdot 10^{+42}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;z \leq 1.45 \cdot 10^{+58}:\\
\;\;\;\;t\_0\\

\mathbf{elif}\;z \leq 7.5 \cdot 10^{+70}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;z \leq 2.9 \cdot 10^{+83}:\\
\;\;\;\;t\_0\\

\mathbf{elif}\;z \leq 3.5 \cdot 10^{+97}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;z \leq 4.8 \cdot 10^{+100}:\\
\;\;\;\;t\_0\\

\mathbf{elif}\;z \leq 1.55 \cdot 10^{+102}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;z \leq 2 \cdot 10^{+118}:\\
\;\;\;\;t\_0\\

\mathbf{elif}\;z \leq 1.5 \cdot 10^{+124}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;z \leq 1.45 \cdot 10^{+126}:\\
\;\;\;\;t\_0\\

\mathbf{elif}\;z \leq 4.4 \cdot 10^{+139}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;z \leq 4.2 \cdot 10^{+150}:\\
\;\;\;\;t\_0\\

\mathbf{elif}\;z \leq 1.65 \cdot 10^{+154}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;z \leq 2 \cdot 10^{+156}:\\
\;\;\;\;t\_0\\

\mathbf{elif}\;z \leq 4.5 \cdot 10^{+156}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;z \leq 1.9 \cdot 10^{+174}:\\
\;\;\;\;t\_0\\

\mathbf{elif}\;z \leq 4.6 \cdot 10^{+180}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;z \leq 2.3 \cdot 10^{+185}:\\
\;\;\;\;t\_0\\

\mathbf{elif}\;z \leq 2.5 \cdot 10^{+191}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;z \leq 1.85 \cdot 10^{+211}:\\
\;\;\;\;t\_0\\

\mathbf{elif}\;z \leq 4.7 \cdot 10^{+231}:\\
\;\;\;\;t\_3\\

\mathbf{elif}\;z \leq 1.4 \cdot 10^{+241}:\\
\;\;\;\;t\_0\\

\mathbf{elif}\;z \leq 2.6 \cdot 10^{+266}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;z \leq 1.05 \cdot 10^{+270} \lor \neg \left(z \leq 2.8 \cdot 10^{+270}\right) \land \left(z \leq 1.6 \cdot 10^{+281} \lor \neg \left(z \leq 2.05 \cdot 10^{+283} \lor \neg \left(z \leq 2.65 \cdot 10^{+289}\right) \land z \leq 2.8 \cdot 10^{+295}\right)\right):\\
\;\;\;\;t\_0\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 5 regimes
  2. if z < -2.1499999999999999e-13 or 3.50000000000000017e-16 < z < 0.091999999999999998 or 1.25e6 < z < 2.49999999999999986e33

    1. Initial program 100.0%

      \[\left(x + y\right) \cdot \left(1 - z\right) \]
    2. Add Preprocessing
    3. Taylor expanded in x around 0 45.5%

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

    if -2.1499999999999999e-13 < z < 3.50000000000000017e-16

    1. Initial program 100.0%

      \[\left(x + y\right) \cdot \left(1 - z\right) \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 100.0%

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

        \[\leadsto \color{blue}{y + x} \]
    5. Simplified100.0%

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

    if 0.091999999999999998 < z < 1.25e6 or 1.40000000000000013e241 < z < 2.60000000000000014e266

    1. Initial program 100.0%

      \[\left(x + y\right) \cdot \left(1 - z\right) \]
    2. Add Preprocessing
    3. Taylor expanded in x around inf 72.5%

      \[\leadsto \color{blue}{x \cdot \left(1 - z\right)} \]
    4. Step-by-step derivation
      1. *-commutative72.5%

        \[\leadsto \color{blue}{\left(1 - z\right) \cdot x} \]
    5. Simplified72.5%

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

    if 2.49999999999999986e33 < z < 1.4e42 or 1.45000000000000001e58 < z < 7.50000000000000031e70 or 2.89999999999999999e83 < z < 3.5000000000000001e97 or 4.80000000000000023e100 < z < 1.54999999999999993e102 or 1.99999999999999993e118 < z < 1.5e124 or 1.44999999999999993e126 < z < 4.3999999999999999e139 or 4.19999999999999996e150 < z < 1.65e154 or 2e156 < z < 4.50000000000000031e156 or 1.9000000000000001e174 < z < 4.5999999999999998e180 or 2.3000000000000001e185 < z < 2.5000000000000001e191 or 1.85000000000000005e211 < z < 4.70000000000000006e231 or 1.05000000000000005e270 < z < 2.8000000000000001e270 or 1.6000000000000001e281 < z < 2.05000000000000002e283 or 2.65e289 < z < 2.8000000000000001e295

    1. Initial program 100.0%

      \[\left(x + y\right) \cdot \left(1 - z\right) \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf 100.0%

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

        \[\leadsto \color{blue}{-z \cdot \left(x + y\right)} \]
      2. distribute-lft-neg-out100.0%

        \[\leadsto \color{blue}{\left(-z\right) \cdot \left(x + y\right)} \]
      3. *-commutative100.0%

        \[\leadsto \color{blue}{\left(x + y\right) \cdot \left(-z\right)} \]
      4. +-commutative100.0%

        \[\leadsto \color{blue}{\left(y + x\right)} \cdot \left(-z\right) \]
    5. Simplified100.0%

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

      \[\leadsto \color{blue}{-1 \cdot \left(x \cdot z\right)} \]
    7. Step-by-step derivation
      1. associate-*r*40.1%

        \[\leadsto \color{blue}{\left(-1 \cdot x\right) \cdot z} \]
      2. mul-1-neg40.1%

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

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

    if 1.4e42 < z < 1.45000000000000001e58 or 7.50000000000000031e70 < z < 2.89999999999999999e83 or 3.5000000000000001e97 < z < 4.80000000000000023e100 or 1.54999999999999993e102 < z < 1.99999999999999993e118 or 1.5e124 < z < 1.44999999999999993e126 or 4.3999999999999999e139 < z < 4.19999999999999996e150 or 1.65e154 < z < 2e156 or 4.50000000000000031e156 < z < 1.9000000000000001e174 or 4.5999999999999998e180 < z < 2.3000000000000001e185 or 2.5000000000000001e191 < z < 1.85000000000000005e211 or 4.70000000000000006e231 < z < 1.40000000000000013e241 or 2.60000000000000014e266 < z < 1.05000000000000005e270 or 2.8000000000000001e270 < z < 1.6000000000000001e281 or 2.05000000000000002e283 < z < 2.65e289 or 2.8000000000000001e295 < z

    1. Initial program 100.0%

      \[\left(x + y\right) \cdot \left(1 - z\right) \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf 100.0%

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

        \[\leadsto \color{blue}{-z \cdot \left(x + y\right)} \]
      2. distribute-lft-neg-out100.0%

        \[\leadsto \color{blue}{\left(-z\right) \cdot \left(x + y\right)} \]
      3. *-commutative100.0%

        \[\leadsto \color{blue}{\left(x + y\right) \cdot \left(-z\right)} \]
      4. +-commutative100.0%

        \[\leadsto \color{blue}{\left(y + x\right)} \cdot \left(-z\right) \]
    5. Simplified100.0%

      \[\leadsto \color{blue}{\left(y + x\right) \cdot \left(-z\right)} \]
    6. Taylor expanded in y around inf 48.1%

      \[\leadsto \color{blue}{-1 \cdot \left(y \cdot z\right)} \]
    7. Step-by-step derivation
      1. associate-*r*48.1%

        \[\leadsto \color{blue}{\left(-1 \cdot y\right) \cdot z} \]
      2. mul-1-neg48.1%

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

      \[\leadsto \color{blue}{\left(-y\right) \cdot z} \]
  3. Recombined 5 regimes into one program.
  4. Final simplification69.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -2.15 \cdot 10^{-13}:\\ \;\;\;\;y \cdot \left(1 - z\right)\\ \mathbf{elif}\;z \leq 3.5 \cdot 10^{-16}:\\ \;\;\;\;x + y\\ \mathbf{elif}\;z \leq 0.092:\\ \;\;\;\;y \cdot \left(1 - z\right)\\ \mathbf{elif}\;z \leq 1250000:\\ \;\;\;\;x \cdot \left(1 - z\right)\\ \mathbf{elif}\;z \leq 2.5 \cdot 10^{+33}:\\ \;\;\;\;y \cdot \left(1 - z\right)\\ \mathbf{elif}\;z \leq 1.4 \cdot 10^{+42}:\\ \;\;\;\;x \cdot \left(-z\right)\\ \mathbf{elif}\;z \leq 1.45 \cdot 10^{+58}:\\ \;\;\;\;z \cdot \left(-y\right)\\ \mathbf{elif}\;z \leq 7.5 \cdot 10^{+70}:\\ \;\;\;\;x \cdot \left(-z\right)\\ \mathbf{elif}\;z \leq 2.9 \cdot 10^{+83}:\\ \;\;\;\;z \cdot \left(-y\right)\\ \mathbf{elif}\;z \leq 3.5 \cdot 10^{+97}:\\ \;\;\;\;x \cdot \left(-z\right)\\ \mathbf{elif}\;z \leq 4.8 \cdot 10^{+100}:\\ \;\;\;\;z \cdot \left(-y\right)\\ \mathbf{elif}\;z \leq 1.55 \cdot 10^{+102}:\\ \;\;\;\;x \cdot \left(-z\right)\\ \mathbf{elif}\;z \leq 2 \cdot 10^{+118}:\\ \;\;\;\;z \cdot \left(-y\right)\\ \mathbf{elif}\;z \leq 1.5 \cdot 10^{+124}:\\ \;\;\;\;x \cdot \left(-z\right)\\ \mathbf{elif}\;z \leq 1.45 \cdot 10^{+126}:\\ \;\;\;\;z \cdot \left(-y\right)\\ \mathbf{elif}\;z \leq 4.4 \cdot 10^{+139}:\\ \;\;\;\;x \cdot \left(-z\right)\\ \mathbf{elif}\;z \leq 4.2 \cdot 10^{+150}:\\ \;\;\;\;z \cdot \left(-y\right)\\ \mathbf{elif}\;z \leq 1.65 \cdot 10^{+154}:\\ \;\;\;\;x \cdot \left(-z\right)\\ \mathbf{elif}\;z \leq 2 \cdot 10^{+156}:\\ \;\;\;\;z \cdot \left(-y\right)\\ \mathbf{elif}\;z \leq 4.5 \cdot 10^{+156}:\\ \;\;\;\;x \cdot \left(-z\right)\\ \mathbf{elif}\;z \leq 1.9 \cdot 10^{+174}:\\ \;\;\;\;z \cdot \left(-y\right)\\ \mathbf{elif}\;z \leq 4.6 \cdot 10^{+180}:\\ \;\;\;\;x \cdot \left(-z\right)\\ \mathbf{elif}\;z \leq 2.3 \cdot 10^{+185}:\\ \;\;\;\;z \cdot \left(-y\right)\\ \mathbf{elif}\;z \leq 2.5 \cdot 10^{+191}:\\ \;\;\;\;x \cdot \left(-z\right)\\ \mathbf{elif}\;z \leq 1.85 \cdot 10^{+211}:\\ \;\;\;\;z \cdot \left(-y\right)\\ \mathbf{elif}\;z \leq 4.7 \cdot 10^{+231}:\\ \;\;\;\;x \cdot \left(-z\right)\\ \mathbf{elif}\;z \leq 1.4 \cdot 10^{+241}:\\ \;\;\;\;z \cdot \left(-y\right)\\ \mathbf{elif}\;z \leq 2.6 \cdot 10^{+266}:\\ \;\;\;\;x \cdot \left(1 - z\right)\\ \mathbf{elif}\;z \leq 1.05 \cdot 10^{+270} \lor \neg \left(z \leq 2.8 \cdot 10^{+270}\right) \land \left(z \leq 1.6 \cdot 10^{+281} \lor \neg \left(z \leq 2.05 \cdot 10^{+283} \lor \neg \left(z \leq 2.65 \cdot 10^{+289}\right) \land z \leq 2.8 \cdot 10^{+295}\right)\right):\\ \;\;\;\;z \cdot \left(-y\right)\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(-z\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 4: 74.7% accurate, 0.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := z \cdot \left(-y\right)\\ \mathbf{if}\;z \leq -34:\\ \;\;\;\;t\_0\\ \mathbf{elif}\;z \leq 1:\\ \;\;\;\;x + y\\ \mathbf{elif}\;z \leq 1850000 \lor \neg \left(z \leq 8 \cdot 10^{+36}\right) \land \left(z \leq 1.05 \cdot 10^{+43} \lor \neg \left(z \leq 3.4 \cdot 10^{+59}\right) \land \left(z \leq 1.2 \cdot 10^{+72} \lor \neg \left(z \leq 2.7 \cdot 10^{+85}\right) \land \left(z \leq 3.2 \cdot 10^{+97} \lor \neg \left(z \leq 4.2 \cdot 10^{+99}\right) \land \left(z \leq 6.8 \cdot 10^{+100} \lor \neg \left(z \leq 5.2 \cdot 10^{+117}\right) \land \left(z \leq 2.2 \cdot 10^{+125} \lor \neg \left(z \leq 8.8 \cdot 10^{+126}\right) \land \left(z \leq 4.5 \cdot 10^{+142} \lor \neg \left(z \leq 3.4 \cdot 10^{+150}\right) \land \left(z \leq 2.55 \cdot 10^{+151} \lor \neg \left(z \leq 2.1 \cdot 10^{+156}\right) \land \left(z \leq 5.7 \cdot 10^{+156} \lor \neg \left(z \leq 1.05 \cdot 10^{+173}\right) \land \left(z \leq 4 \cdot 10^{+182} \lor \neg \left(z \leq 9.2 \cdot 10^{+184}\right) \land \left(z \leq 2.4 \cdot 10^{+191} \lor \neg \left(z \leq 2.05 \cdot 10^{+211}\right) \land \left(z \leq 4.2 \cdot 10^{+232} \lor \neg \left(z \leq 1.6 \cdot 10^{+241}\right) \land \left(z \leq 2.25 \cdot 10^{+265} \lor \neg \left(z \leq 10^{+270}\right) \land \left(z \leq 1.7 \cdot 10^{+270} \lor \neg \left(z \leq 1.95 \cdot 10^{+276}\right) \land \left(z \leq 1.35 \cdot 10^{+283} \lor \neg \left(z \leq 2.8 \cdot 10^{+289}\right) \land z \leq 2.05 \cdot 10^{+295}\right)\right)\right)\right)\right)\right)\right)\right)\right)\right)\right)\right)\right)\right):\\ \;\;\;\;x \cdot \left(-z\right)\\ \mathbf{else}:\\ \;\;\;\;t\_0\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (let* ((t_0 (* z (- y))))
   (if (<= z -34.0)
     t_0
     (if (<= z 1.0)
       (+ x y)
       (if (or (<= z 1850000.0)
               (and (not (<= z 8e+36))
                    (or (<= z 1.05e+43)
                        (and (not (<= z 3.4e+59))
                             (or (<= z 1.2e+72)
                                 (and (not (<= z 2.7e+85))
                                      (or (<= z 3.2e+97)
                                          (and (not (<= z 4.2e+99))
                                               (or (<= z 6.8e+100)
                                                   (and (not (<= z 5.2e+117))
                                                        (or (<= z 2.2e+125)
                                                            (and (not
                                                                  (<=
                                                                   z
                                                                   8.8e+126))
                                                                 (or (<=
                                                                      z
                                                                      4.5e+142)
                                                                     (and (not
                                                                           (<=
                                                                            z
                                                                            3.4e+150))
                                                                          (or (<=
                                                                               z
                                                                               2.55e+151)
                                                                              (and (not
                                                                                    (<=
                                                                                     z
                                                                                     2.1e+156))
                                                                                   (or (<=
                                                                                        z
                                                                                        5.7e+156)
                                                                                       (and (not
                                                                                             (<=
                                                                                              z
                                                                                              1.05e+173))
                                                                                            (or (<=
                                                                                                 z
                                                                                                 4e+182)
                                                                                                (and (not
                                                                                                      (<=
                                                                                                       z
                                                                                                       9.2e+184))
                                                                                                     (or (<=
                                                                                                          z
                                                                                                          2.4e+191)
                                                                                                         (and (not
                                                                                                               (<=
                                                                                                                z
                                                                                                                2.05e+211))
                                                                                                              (or (<=
                                                                                                                   z
                                                                                                                   4.2e+232)
                                                                                                                  (and (not
                                                                                                                        (<=
                                                                                                                         z
                                                                                                                         1.6e+241))
                                                                                                                       (or (<=
                                                                                                                            z
                                                                                                                            2.25e+265)
                                                                                                                           (and (not
                                                                                                                                 (<=
                                                                                                                                  z
                                                                                                                                  1e+270))
                                                                                                                                (or (<=
                                                                                                                                     z
                                                                                                                                     1.7e+270)
                                                                                                                                    (and (not
                                                                                                                                          (<=
                                                                                                                                           z
                                                                                                                                           1.95e+276))
                                                                                                                                         (or (<=
                                                                                                                                              z
                                                                                                                                              1.35e+283)
                                                                                                                                             (and (not
                                                                                                                                                   (<=
                                                                                                                                                    z
                                                                                                                                                    2.8e+289))
                                                                                                                                                  (<=
                                                                                                                                                   z
                                                                                                                                                   2.05e+295)))))))))))))))))))))))))))))))
         (* x (- z))
         t_0)))))
double code(double x, double y, double z) {
	double t_0 = z * -y;
	double tmp;
	if (z <= -34.0) {
		tmp = t_0;
	} else if (z <= 1.0) {
		tmp = x + y;
	} else if ((z <= 1850000.0) || (!(z <= 8e+36) && ((z <= 1.05e+43) || (!(z <= 3.4e+59) && ((z <= 1.2e+72) || (!(z <= 2.7e+85) && ((z <= 3.2e+97) || (!(z <= 4.2e+99) && ((z <= 6.8e+100) || (!(z <= 5.2e+117) && ((z <= 2.2e+125) || (!(z <= 8.8e+126) && ((z <= 4.5e+142) || (!(z <= 3.4e+150) && ((z <= 2.55e+151) || (!(z <= 2.1e+156) && ((z <= 5.7e+156) || (!(z <= 1.05e+173) && ((z <= 4e+182) || (!(z <= 9.2e+184) && ((z <= 2.4e+191) || (!(z <= 2.05e+211) && ((z <= 4.2e+232) || (!(z <= 1.6e+241) && ((z <= 2.25e+265) || (!(z <= 1e+270) && ((z <= 1.7e+270) || (!(z <= 1.95e+276) && ((z <= 1.35e+283) || (!(z <= 2.8e+289) && (z <= 2.05e+295))))))))))))))))))))))))))))))) {
		tmp = x * -z;
	} else {
		tmp = t_0;
	}
	return tmp;
}
real(8) function code(x, y, z)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8) :: t_0
    real(8) :: tmp
    t_0 = z * -y
    if (z <= (-34.0d0)) then
        tmp = t_0
    else if (z <= 1.0d0) then
        tmp = x + y
    else if ((z <= 1850000.0d0) .or. (.not. (z <= 8d+36)) .and. (z <= 1.05d+43) .or. (.not. (z <= 3.4d+59)) .and. (z <= 1.2d+72) .or. (.not. (z <= 2.7d+85)) .and. (z <= 3.2d+97) .or. (.not. (z <= 4.2d+99)) .and. (z <= 6.8d+100) .or. (.not. (z <= 5.2d+117)) .and. (z <= 2.2d+125) .or. (.not. (z <= 8.8d+126)) .and. (z <= 4.5d+142) .or. (.not. (z <= 3.4d+150)) .and. (z <= 2.55d+151) .or. (.not. (z <= 2.1d+156)) .and. (z <= 5.7d+156) .or. (.not. (z <= 1.05d+173)) .and. (z <= 4d+182) .or. (.not. (z <= 9.2d+184)) .and. (z <= 2.4d+191) .or. (.not. (z <= 2.05d+211)) .and. (z <= 4.2d+232) .or. (.not. (z <= 1.6d+241)) .and. (z <= 2.25d+265) .or. (.not. (z <= 1d+270)) .and. (z <= 1.7d+270) .or. (.not. (z <= 1.95d+276)) .and. (z <= 1.35d+283) .or. (.not. (z <= 2.8d+289)) .and. (z <= 2.05d+295)) then
        tmp = x * -z
    else
        tmp = t_0
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double t_0 = z * -y;
	double tmp;
	if (z <= -34.0) {
		tmp = t_0;
	} else if (z <= 1.0) {
		tmp = x + y;
	} else if ((z <= 1850000.0) || (!(z <= 8e+36) && ((z <= 1.05e+43) || (!(z <= 3.4e+59) && ((z <= 1.2e+72) || (!(z <= 2.7e+85) && ((z <= 3.2e+97) || (!(z <= 4.2e+99) && ((z <= 6.8e+100) || (!(z <= 5.2e+117) && ((z <= 2.2e+125) || (!(z <= 8.8e+126) && ((z <= 4.5e+142) || (!(z <= 3.4e+150) && ((z <= 2.55e+151) || (!(z <= 2.1e+156) && ((z <= 5.7e+156) || (!(z <= 1.05e+173) && ((z <= 4e+182) || (!(z <= 9.2e+184) && ((z <= 2.4e+191) || (!(z <= 2.05e+211) && ((z <= 4.2e+232) || (!(z <= 1.6e+241) && ((z <= 2.25e+265) || (!(z <= 1e+270) && ((z <= 1.7e+270) || (!(z <= 1.95e+276) && ((z <= 1.35e+283) || (!(z <= 2.8e+289) && (z <= 2.05e+295))))))))))))))))))))))))))))))) {
		tmp = x * -z;
	} else {
		tmp = t_0;
	}
	return tmp;
}
def code(x, y, z):
	t_0 = z * -y
	tmp = 0
	if z <= -34.0:
		tmp = t_0
	elif z <= 1.0:
		tmp = x + y
	elif (z <= 1850000.0) or (not (z <= 8e+36) and ((z <= 1.05e+43) or (not (z <= 3.4e+59) and ((z <= 1.2e+72) or (not (z <= 2.7e+85) and ((z <= 3.2e+97) or (not (z <= 4.2e+99) and ((z <= 6.8e+100) or (not (z <= 5.2e+117) and ((z <= 2.2e+125) or (not (z <= 8.8e+126) and ((z <= 4.5e+142) or (not (z <= 3.4e+150) and ((z <= 2.55e+151) or (not (z <= 2.1e+156) and ((z <= 5.7e+156) or (not (z <= 1.05e+173) and ((z <= 4e+182) or (not (z <= 9.2e+184) and ((z <= 2.4e+191) or (not (z <= 2.05e+211) and ((z <= 4.2e+232) or (not (z <= 1.6e+241) and ((z <= 2.25e+265) or (not (z <= 1e+270) and ((z <= 1.7e+270) or (not (z <= 1.95e+276) and ((z <= 1.35e+283) or (not (z <= 2.8e+289) and (z <= 2.05e+295)))))))))))))))))))))))))))))):
		tmp = x * -z
	else:
		tmp = t_0
	return tmp
function code(x, y, z)
	t_0 = Float64(z * Float64(-y))
	tmp = 0.0
	if (z <= -34.0)
		tmp = t_0;
	elseif (z <= 1.0)
		tmp = Float64(x + y);
	elseif ((z <= 1850000.0) || (!(z <= 8e+36) && ((z <= 1.05e+43) || (!(z <= 3.4e+59) && ((z <= 1.2e+72) || (!(z <= 2.7e+85) && ((z <= 3.2e+97) || (!(z <= 4.2e+99) && ((z <= 6.8e+100) || (!(z <= 5.2e+117) && ((z <= 2.2e+125) || (!(z <= 8.8e+126) && ((z <= 4.5e+142) || (!(z <= 3.4e+150) && ((z <= 2.55e+151) || (!(z <= 2.1e+156) && ((z <= 5.7e+156) || (!(z <= 1.05e+173) && ((z <= 4e+182) || (!(z <= 9.2e+184) && ((z <= 2.4e+191) || (!(z <= 2.05e+211) && ((z <= 4.2e+232) || (!(z <= 1.6e+241) && ((z <= 2.25e+265) || (!(z <= 1e+270) && ((z <= 1.7e+270) || (!(z <= 1.95e+276) && ((z <= 1.35e+283) || (!(z <= 2.8e+289) && (z <= 2.05e+295)))))))))))))))))))))))))))))))
		tmp = Float64(x * Float64(-z));
	else
		tmp = t_0;
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	t_0 = z * -y;
	tmp = 0.0;
	if (z <= -34.0)
		tmp = t_0;
	elseif (z <= 1.0)
		tmp = x + y;
	elseif ((z <= 1850000.0) || (~((z <= 8e+36)) && ((z <= 1.05e+43) || (~((z <= 3.4e+59)) && ((z <= 1.2e+72) || (~((z <= 2.7e+85)) && ((z <= 3.2e+97) || (~((z <= 4.2e+99)) && ((z <= 6.8e+100) || (~((z <= 5.2e+117)) && ((z <= 2.2e+125) || (~((z <= 8.8e+126)) && ((z <= 4.5e+142) || (~((z <= 3.4e+150)) && ((z <= 2.55e+151) || (~((z <= 2.1e+156)) && ((z <= 5.7e+156) || (~((z <= 1.05e+173)) && ((z <= 4e+182) || (~((z <= 9.2e+184)) && ((z <= 2.4e+191) || (~((z <= 2.05e+211)) && ((z <= 4.2e+232) || (~((z <= 1.6e+241)) && ((z <= 2.25e+265) || (~((z <= 1e+270)) && ((z <= 1.7e+270) || (~((z <= 1.95e+276)) && ((z <= 1.35e+283) || (~((z <= 2.8e+289)) && (z <= 2.05e+295)))))))))))))))))))))))))))))))
		tmp = x * -z;
	else
		tmp = t_0;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := Block[{t$95$0 = N[(z * (-y)), $MachinePrecision]}, If[LessEqual[z, -34.0], t$95$0, If[LessEqual[z, 1.0], N[(x + y), $MachinePrecision], If[Or[LessEqual[z, 1850000.0], And[N[Not[LessEqual[z, 8e+36]], $MachinePrecision], Or[LessEqual[z, 1.05e+43], And[N[Not[LessEqual[z, 3.4e+59]], $MachinePrecision], Or[LessEqual[z, 1.2e+72], And[N[Not[LessEqual[z, 2.7e+85]], $MachinePrecision], Or[LessEqual[z, 3.2e+97], And[N[Not[LessEqual[z, 4.2e+99]], $MachinePrecision], Or[LessEqual[z, 6.8e+100], And[N[Not[LessEqual[z, 5.2e+117]], $MachinePrecision], Or[LessEqual[z, 2.2e+125], And[N[Not[LessEqual[z, 8.8e+126]], $MachinePrecision], Or[LessEqual[z, 4.5e+142], And[N[Not[LessEqual[z, 3.4e+150]], $MachinePrecision], Or[LessEqual[z, 2.55e+151], And[N[Not[LessEqual[z, 2.1e+156]], $MachinePrecision], Or[LessEqual[z, 5.7e+156], And[N[Not[LessEqual[z, 1.05e+173]], $MachinePrecision], Or[LessEqual[z, 4e+182], And[N[Not[LessEqual[z, 9.2e+184]], $MachinePrecision], Or[LessEqual[z, 2.4e+191], And[N[Not[LessEqual[z, 2.05e+211]], $MachinePrecision], Or[LessEqual[z, 4.2e+232], And[N[Not[LessEqual[z, 1.6e+241]], $MachinePrecision], Or[LessEqual[z, 2.25e+265], And[N[Not[LessEqual[z, 1e+270]], $MachinePrecision], Or[LessEqual[z, 1.7e+270], And[N[Not[LessEqual[z, 1.95e+276]], $MachinePrecision], Or[LessEqual[z, 1.35e+283], And[N[Not[LessEqual[z, 2.8e+289]], $MachinePrecision], LessEqual[z, 2.05e+295]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]], N[(x * (-z)), $MachinePrecision], t$95$0]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := z \cdot \left(-y\right)\\
\mathbf{if}\;z \leq -34:\\
\;\;\;\;t\_0\\

\mathbf{elif}\;z \leq 1:\\
\;\;\;\;x + y\\

\mathbf{elif}\;z \leq 1850000 \lor \neg \left(z \leq 8 \cdot 10^{+36}\right) \land \left(z \leq 1.05 \cdot 10^{+43} \lor \neg \left(z \leq 3.4 \cdot 10^{+59}\right) \land \left(z \leq 1.2 \cdot 10^{+72} \lor \neg \left(z \leq 2.7 \cdot 10^{+85}\right) \land \left(z \leq 3.2 \cdot 10^{+97} \lor \neg \left(z \leq 4.2 \cdot 10^{+99}\right) \land \left(z \leq 6.8 \cdot 10^{+100} \lor \neg \left(z \leq 5.2 \cdot 10^{+117}\right) \land \left(z \leq 2.2 \cdot 10^{+125} \lor \neg \left(z \leq 8.8 \cdot 10^{+126}\right) \land \left(z \leq 4.5 \cdot 10^{+142} \lor \neg \left(z \leq 3.4 \cdot 10^{+150}\right) \land \left(z \leq 2.55 \cdot 10^{+151} \lor \neg \left(z \leq 2.1 \cdot 10^{+156}\right) \land \left(z \leq 5.7 \cdot 10^{+156} \lor \neg \left(z \leq 1.05 \cdot 10^{+173}\right) \land \left(z \leq 4 \cdot 10^{+182} \lor \neg \left(z \leq 9.2 \cdot 10^{+184}\right) \land \left(z \leq 2.4 \cdot 10^{+191} \lor \neg \left(z \leq 2.05 \cdot 10^{+211}\right) \land \left(z \leq 4.2 \cdot 10^{+232} \lor \neg \left(z \leq 1.6 \cdot 10^{+241}\right) \land \left(z \leq 2.25 \cdot 10^{+265} \lor \neg \left(z \leq 10^{+270}\right) \land \left(z \leq 1.7 \cdot 10^{+270} \lor \neg \left(z \leq 1.95 \cdot 10^{+276}\right) \land \left(z \leq 1.35 \cdot 10^{+283} \lor \neg \left(z \leq 2.8 \cdot 10^{+289}\right) \land z \leq 2.05 \cdot 10^{+295}\right)\right)\right)\right)\right)\right)\right)\right)\right)\right)\right)\right)\right)\right):\\
\;\;\;\;x \cdot \left(-z\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -34 or 1.85e6 < z < 8.00000000000000034e36 or 1.05000000000000001e43 < z < 3.40000000000000006e59 or 1.20000000000000005e72 < z < 2.69999999999999983e85 or 3.20000000000000016e97 < z < 4.2000000000000002e99 or 6.79999999999999988e100 < z < 5.1999999999999999e117 or 2.19999999999999991e125 < z < 8.79999999999999994e126 or 4.4999999999999999e142 < z < 3.39999999999999983e150 or 2.54999999999999998e151 < z < 2.09999999999999981e156 or 5.69999999999999998e156 < z < 1.05e173 or 4.0000000000000003e182 < z < 9.1999999999999999e184 or 2.39999999999999986e191 < z < 2.0499999999999999e211 or 4.19999999999999982e232 < z < 1.60000000000000002e241 or 2.24999999999999993e265 < z < 1e270 or 1.70000000000000008e270 < z < 1.9500000000000001e276 or 1.34999999999999991e283 < z < 2.79999999999999991e289 or 2.04999999999999992e295 < z

    1. Initial program 100.0%

      \[\left(x + y\right) \cdot \left(1 - z\right) \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf 99.1%

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

        \[\leadsto \color{blue}{-z \cdot \left(x + y\right)} \]
      2. distribute-lft-neg-out99.1%

        \[\leadsto \color{blue}{\left(-z\right) \cdot \left(x + y\right)} \]
      3. *-commutative99.1%

        \[\leadsto \color{blue}{\left(x + y\right) \cdot \left(-z\right)} \]
      4. +-commutative99.1%

        \[\leadsto \color{blue}{\left(y + x\right)} \cdot \left(-z\right) \]
    5. Simplified99.1%

      \[\leadsto \color{blue}{\left(y + x\right) \cdot \left(-z\right)} \]
    6. Taylor expanded in y around inf 46.7%

      \[\leadsto \color{blue}{-1 \cdot \left(y \cdot z\right)} \]
    7. Step-by-step derivation
      1. associate-*r*46.7%

        \[\leadsto \color{blue}{\left(-1 \cdot y\right) \cdot z} \]
      2. mul-1-neg46.7%

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

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

    if -34 < z < 1

    1. Initial program 100.0%

      \[\left(x + y\right) \cdot \left(1 - z\right) \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 98.4%

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

        \[\leadsto \color{blue}{y + x} \]
    5. Simplified98.4%

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

    if 1 < z < 1.85e6 or 8.00000000000000034e36 < z < 1.05000000000000001e43 or 3.40000000000000006e59 < z < 1.20000000000000005e72 or 2.69999999999999983e85 < z < 3.20000000000000016e97 or 4.2000000000000002e99 < z < 6.79999999999999988e100 or 5.1999999999999999e117 < z < 2.19999999999999991e125 or 8.79999999999999994e126 < z < 4.4999999999999999e142 or 3.39999999999999983e150 < z < 2.54999999999999998e151 or 2.09999999999999981e156 < z < 5.69999999999999998e156 or 1.05e173 < z < 4.0000000000000003e182 or 9.1999999999999999e184 < z < 2.39999999999999986e191 or 2.0499999999999999e211 < z < 4.19999999999999982e232 or 1.60000000000000002e241 < z < 2.24999999999999993e265 or 1e270 < z < 1.70000000000000008e270 or 1.9500000000000001e276 < z < 1.34999999999999991e283 or 2.79999999999999991e289 < z < 2.04999999999999992e295

    1. Initial program 100.0%

      \[\left(x + y\right) \cdot \left(1 - z\right) \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf 96.8%

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

        \[\leadsto \color{blue}{-z \cdot \left(x + y\right)} \]
      2. distribute-lft-neg-out96.8%

        \[\leadsto \color{blue}{\left(-z\right) \cdot \left(x + y\right)} \]
      3. *-commutative96.8%

        \[\leadsto \color{blue}{\left(x + y\right) \cdot \left(-z\right)} \]
      4. +-commutative96.8%

        \[\leadsto \color{blue}{\left(y + x\right)} \cdot \left(-z\right) \]
    5. Simplified96.8%

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

      \[\leadsto \color{blue}{-1 \cdot \left(x \cdot z\right)} \]
    7. Step-by-step derivation
      1. associate-*r*44.6%

        \[\leadsto \color{blue}{\left(-1 \cdot x\right) \cdot z} \]
      2. mul-1-neg44.6%

        \[\leadsto \color{blue}{\left(-x\right)} \cdot z \]
    8. Simplified44.6%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -34:\\ \;\;\;\;z \cdot \left(-y\right)\\ \mathbf{elif}\;z \leq 1:\\ \;\;\;\;x + y\\ \mathbf{elif}\;z \leq 1850000 \lor \neg \left(z \leq 8 \cdot 10^{+36}\right) \land \left(z \leq 1.05 \cdot 10^{+43} \lor \neg \left(z \leq 3.4 \cdot 10^{+59}\right) \land \left(z \leq 1.2 \cdot 10^{+72} \lor \neg \left(z \leq 2.7 \cdot 10^{+85}\right) \land \left(z \leq 3.2 \cdot 10^{+97} \lor \neg \left(z \leq 4.2 \cdot 10^{+99}\right) \land \left(z \leq 6.8 \cdot 10^{+100} \lor \neg \left(z \leq 5.2 \cdot 10^{+117}\right) \land \left(z \leq 2.2 \cdot 10^{+125} \lor \neg \left(z \leq 8.8 \cdot 10^{+126}\right) \land \left(z \leq 4.5 \cdot 10^{+142} \lor \neg \left(z \leq 3.4 \cdot 10^{+150}\right) \land \left(z \leq 2.55 \cdot 10^{+151} \lor \neg \left(z \leq 2.1 \cdot 10^{+156}\right) \land \left(z \leq 5.7 \cdot 10^{+156} \lor \neg \left(z \leq 1.05 \cdot 10^{+173}\right) \land \left(z \leq 4 \cdot 10^{+182} \lor \neg \left(z \leq 9.2 \cdot 10^{+184}\right) \land \left(z \leq 2.4 \cdot 10^{+191} \lor \neg \left(z \leq 2.05 \cdot 10^{+211}\right) \land \left(z \leq 4.2 \cdot 10^{+232} \lor \neg \left(z \leq 1.6 \cdot 10^{+241}\right) \land \left(z \leq 2.25 \cdot 10^{+265} \lor \neg \left(z \leq 10^{+270}\right) \land \left(z \leq 1.7 \cdot 10^{+270} \lor \neg \left(z \leq 1.95 \cdot 10^{+276}\right) \land \left(z \leq 1.35 \cdot 10^{+283} \lor \neg \left(z \leq 2.8 \cdot 10^{+289}\right) \land z \leq 2.05 \cdot 10^{+295}\right)\right)\right)\right)\right)\right)\right)\right)\right)\right)\right)\right)\right)\right):\\ \;\;\;\;x \cdot \left(-z\right)\\ \mathbf{else}:\\ \;\;\;\;z \cdot \left(-y\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 5: 72.6% accurate, 0.1× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -1.14 \cdot 10^{+21} \lor \neg \left(z \leq 1\right) \land \left(z \leq 5.9 \cdot 10^{+79} \lor \neg \left(z \leq 6 \cdot 10^{+79}\right) \land \left(z \leq 6.3 \cdot 10^{+149} \lor \neg \left(z \leq 6.5 \cdot 10^{+149}\right) \land \left(z \leq 1.12 \cdot 10^{+157} \lor \neg \left(z \leq 3 \cdot 10^{+167}\right) \land \left(z \leq 1.25 \cdot 10^{+184} \lor \neg \left(z \leq 1.28 \cdot 10^{+184}\right) \land \left(z \leq 6.5 \cdot 10^{+240} \lor \neg \left(z \leq 6.8 \cdot 10^{+240}\right) \land \left(z \leq 3.5 \cdot 10^{+283} \lor \neg \left(z \leq 3.1 \cdot 10^{+288}\right) \land z \leq 8.2 \cdot 10^{+297}\right)\right)\right)\right)\right)\right):\\ \;\;\;\;x \cdot \left(-z\right)\\ \mathbf{else}:\\ \;\;\;\;x + y\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (if (or (<= z -1.14e+21)
         (and (not (<= z 1.0))
              (or (<= z 5.9e+79)
                  (and (not (<= z 6e+79))
                       (or (<= z 6.3e+149)
                           (and (not (<= z 6.5e+149))
                                (or (<= z 1.12e+157)
                                    (and (not (<= z 3e+167))
                                         (or (<= z 1.25e+184)
                                             (and (not (<= z 1.28e+184))
                                                  (or (<= z 6.5e+240)
                                                      (and (not
                                                            (<= z 6.8e+240))
                                                           (or (<= z 3.5e+283)
                                                               (and (not
                                                                     (<=
                                                                      z
                                                                      3.1e+288))
                                                                    (<=
                                                                     z
                                                                     8.2e+297)))))))))))))))
   (* x (- z))
   (+ x y)))
double code(double x, double y, double z) {
	double tmp;
	if ((z <= -1.14e+21) || (!(z <= 1.0) && ((z <= 5.9e+79) || (!(z <= 6e+79) && ((z <= 6.3e+149) || (!(z <= 6.5e+149) && ((z <= 1.12e+157) || (!(z <= 3e+167) && ((z <= 1.25e+184) || (!(z <= 1.28e+184) && ((z <= 6.5e+240) || (!(z <= 6.8e+240) && ((z <= 3.5e+283) || (!(z <= 3.1e+288) && (z <= 8.2e+297))))))))))))))) {
		tmp = x * -z;
	} else {
		tmp = x + y;
	}
	return tmp;
}
real(8) function code(x, y, z)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8) :: tmp
    if ((z <= (-1.14d+21)) .or. (.not. (z <= 1.0d0)) .and. (z <= 5.9d+79) .or. (.not. (z <= 6d+79)) .and. (z <= 6.3d+149) .or. (.not. (z <= 6.5d+149)) .and. (z <= 1.12d+157) .or. (.not. (z <= 3d+167)) .and. (z <= 1.25d+184) .or. (.not. (z <= 1.28d+184)) .and. (z <= 6.5d+240) .or. (.not. (z <= 6.8d+240)) .and. (z <= 3.5d+283) .or. (.not. (z <= 3.1d+288)) .and. (z <= 8.2d+297)) then
        tmp = x * -z
    else
        tmp = x + y
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double tmp;
	if ((z <= -1.14e+21) || (!(z <= 1.0) && ((z <= 5.9e+79) || (!(z <= 6e+79) && ((z <= 6.3e+149) || (!(z <= 6.5e+149) && ((z <= 1.12e+157) || (!(z <= 3e+167) && ((z <= 1.25e+184) || (!(z <= 1.28e+184) && ((z <= 6.5e+240) || (!(z <= 6.8e+240) && ((z <= 3.5e+283) || (!(z <= 3.1e+288) && (z <= 8.2e+297))))))))))))))) {
		tmp = x * -z;
	} else {
		tmp = x + y;
	}
	return tmp;
}
def code(x, y, z):
	tmp = 0
	if (z <= -1.14e+21) or (not (z <= 1.0) and ((z <= 5.9e+79) or (not (z <= 6e+79) and ((z <= 6.3e+149) or (not (z <= 6.5e+149) and ((z <= 1.12e+157) or (not (z <= 3e+167) and ((z <= 1.25e+184) or (not (z <= 1.28e+184) and ((z <= 6.5e+240) or (not (z <= 6.8e+240) and ((z <= 3.5e+283) or (not (z <= 3.1e+288) and (z <= 8.2e+297)))))))))))))):
		tmp = x * -z
	else:
		tmp = x + y
	return tmp
function code(x, y, z)
	tmp = 0.0
	if ((z <= -1.14e+21) || (!(z <= 1.0) && ((z <= 5.9e+79) || (!(z <= 6e+79) && ((z <= 6.3e+149) || (!(z <= 6.5e+149) && ((z <= 1.12e+157) || (!(z <= 3e+167) && ((z <= 1.25e+184) || (!(z <= 1.28e+184) && ((z <= 6.5e+240) || (!(z <= 6.8e+240) && ((z <= 3.5e+283) || (!(z <= 3.1e+288) && (z <= 8.2e+297)))))))))))))))
		tmp = Float64(x * Float64(-z));
	else
		tmp = Float64(x + y);
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	tmp = 0.0;
	if ((z <= -1.14e+21) || (~((z <= 1.0)) && ((z <= 5.9e+79) || (~((z <= 6e+79)) && ((z <= 6.3e+149) || (~((z <= 6.5e+149)) && ((z <= 1.12e+157) || (~((z <= 3e+167)) && ((z <= 1.25e+184) || (~((z <= 1.28e+184)) && ((z <= 6.5e+240) || (~((z <= 6.8e+240)) && ((z <= 3.5e+283) || (~((z <= 3.1e+288)) && (z <= 8.2e+297)))))))))))))))
		tmp = x * -z;
	else
		tmp = x + y;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := If[Or[LessEqual[z, -1.14e+21], And[N[Not[LessEqual[z, 1.0]], $MachinePrecision], Or[LessEqual[z, 5.9e+79], And[N[Not[LessEqual[z, 6e+79]], $MachinePrecision], Or[LessEqual[z, 6.3e+149], And[N[Not[LessEqual[z, 6.5e+149]], $MachinePrecision], Or[LessEqual[z, 1.12e+157], And[N[Not[LessEqual[z, 3e+167]], $MachinePrecision], Or[LessEqual[z, 1.25e+184], And[N[Not[LessEqual[z, 1.28e+184]], $MachinePrecision], Or[LessEqual[z, 6.5e+240], And[N[Not[LessEqual[z, 6.8e+240]], $MachinePrecision], Or[LessEqual[z, 3.5e+283], And[N[Not[LessEqual[z, 3.1e+288]], $MachinePrecision], LessEqual[z, 8.2e+297]]]]]]]]]]]]]]], N[(x * (-z)), $MachinePrecision], N[(x + y), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.14 \cdot 10^{+21} \lor \neg \left(z \leq 1\right) \land \left(z \leq 5.9 \cdot 10^{+79} \lor \neg \left(z \leq 6 \cdot 10^{+79}\right) \land \left(z \leq 6.3 \cdot 10^{+149} \lor \neg \left(z \leq 6.5 \cdot 10^{+149}\right) \land \left(z \leq 1.12 \cdot 10^{+157} \lor \neg \left(z \leq 3 \cdot 10^{+167}\right) \land \left(z \leq 1.25 \cdot 10^{+184} \lor \neg \left(z \leq 1.28 \cdot 10^{+184}\right) \land \left(z \leq 6.5 \cdot 10^{+240} \lor \neg \left(z \leq 6.8 \cdot 10^{+240}\right) \land \left(z \leq 3.5 \cdot 10^{+283} \lor \neg \left(z \leq 3.1 \cdot 10^{+288}\right) \land z \leq 8.2 \cdot 10^{+297}\right)\right)\right)\right)\right)\right):\\
\;\;\;\;x \cdot \left(-z\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -1.14e21 or 1 < z < 5.9e79 or 5.99999999999999948e79 < z < 6.3e149 or 6.50000000000000015e149 < z < 1.11999999999999995e157 or 3.00000000000000012e167 < z < 1.25e184 or 1.2800000000000001e184 < z < 6.50000000000000018e240 or 6.80000000000000017e240 < z < 3.49999999999999995e283 or 3.1e288 < z < 8.2000000000000003e297

    1. Initial program 100.0%

      \[\left(x + y\right) \cdot \left(1 - z\right) \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf 98.5%

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

        \[\leadsto \color{blue}{-z \cdot \left(x + y\right)} \]
      2. distribute-lft-neg-out98.5%

        \[\leadsto \color{blue}{\left(-z\right) \cdot \left(x + y\right)} \]
      3. *-commutative98.5%

        \[\leadsto \color{blue}{\left(x + y\right) \cdot \left(-z\right)} \]
      4. +-commutative98.5%

        \[\leadsto \color{blue}{\left(y + x\right)} \cdot \left(-z\right) \]
    5. Simplified98.5%

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

      \[\leadsto \color{blue}{-1 \cdot \left(x \cdot z\right)} \]
    7. Step-by-step derivation
      1. associate-*r*55.1%

        \[\leadsto \color{blue}{\left(-1 \cdot x\right) \cdot z} \]
      2. mul-1-neg55.1%

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

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

    if -1.14e21 < z < 1 or 5.9e79 < z < 5.99999999999999948e79 or 6.3e149 < z < 6.50000000000000015e149 or 1.11999999999999995e157 < z < 3.00000000000000012e167 or 1.25e184 < z < 1.2800000000000001e184 or 6.50000000000000018e240 < z < 6.80000000000000017e240 or 3.49999999999999995e283 < z < 3.1e288 or 8.2000000000000003e297 < z

    1. Initial program 100.0%

      \[\left(x + y\right) \cdot \left(1 - z\right) \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 89.6%

      \[\leadsto \color{blue}{x + y} \]
    4. Step-by-step derivation
      1. +-commutative89.6%

        \[\leadsto \color{blue}{y + x} \]
    5. Simplified89.6%

      \[\leadsto \color{blue}{y + x} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification72.6%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.14 \cdot 10^{+21} \lor \neg \left(z \leq 1\right) \land \left(z \leq 5.9 \cdot 10^{+79} \lor \neg \left(z \leq 6 \cdot 10^{+79}\right) \land \left(z \leq 6.3 \cdot 10^{+149} \lor \neg \left(z \leq 6.5 \cdot 10^{+149}\right) \land \left(z \leq 1.12 \cdot 10^{+157} \lor \neg \left(z \leq 3 \cdot 10^{+167}\right) \land \left(z \leq 1.25 \cdot 10^{+184} \lor \neg \left(z \leq 1.28 \cdot 10^{+184}\right) \land \left(z \leq 6.5 \cdot 10^{+240} \lor \neg \left(z \leq 6.8 \cdot 10^{+240}\right) \land \left(z \leq 3.5 \cdot 10^{+283} \lor \neg \left(z \leq 3.1 \cdot 10^{+288}\right) \land z \leq 8.2 \cdot 10^{+297}\right)\right)\right)\right)\right)\right):\\ \;\;\;\;x \cdot \left(-z\right)\\ \mathbf{else}:\\ \;\;\;\;x + y\\ \end{array} \]
  5. Add Preprocessing

Alternative 6: 97.5% accurate, 0.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := y \cdot \left(1 - z\right)\\ t_1 := z \cdot \left(\left(-y\right) - x\right)\\ \mathbf{if}\;z \leq -1:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq 3.5 \cdot 10^{-16}:\\ \;\;\;\;x + y\\ \mathbf{elif}\;z \leq 1.75 \cdot 10^{-7}:\\ \;\;\;\;t\_0\\ \mathbf{elif}\;z \leq 1900000:\\ \;\;\;\;x \cdot \left(1 - z\right)\\ \mathbf{elif}\;z \leq 2.4 \cdot 10^{+14}:\\ \;\;\;\;t\_0\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (let* ((t_0 (* y (- 1.0 z))) (t_1 (* z (- (- y) x))))
   (if (<= z -1.0)
     t_1
     (if (<= z 3.5e-16)
       (+ x y)
       (if (<= z 1.75e-7)
         t_0
         (if (<= z 1900000.0) (* x (- 1.0 z)) (if (<= z 2.4e+14) t_0 t_1)))))))
double code(double x, double y, double z) {
	double t_0 = y * (1.0 - z);
	double t_1 = z * (-y - x);
	double tmp;
	if (z <= -1.0) {
		tmp = t_1;
	} else if (z <= 3.5e-16) {
		tmp = x + y;
	} else if (z <= 1.75e-7) {
		tmp = t_0;
	} else if (z <= 1900000.0) {
		tmp = x * (1.0 - z);
	} else if (z <= 2.4e+14) {
		tmp = t_0;
	} else {
		tmp = t_1;
	}
	return tmp;
}
real(8) function code(x, y, z)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8) :: t_0
    real(8) :: t_1
    real(8) :: tmp
    t_0 = y * (1.0d0 - z)
    t_1 = z * (-y - x)
    if (z <= (-1.0d0)) then
        tmp = t_1
    else if (z <= 3.5d-16) then
        tmp = x + y
    else if (z <= 1.75d-7) then
        tmp = t_0
    else if (z <= 1900000.0d0) then
        tmp = x * (1.0d0 - z)
    else if (z <= 2.4d+14) then
        tmp = t_0
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double t_0 = y * (1.0 - z);
	double t_1 = z * (-y - x);
	double tmp;
	if (z <= -1.0) {
		tmp = t_1;
	} else if (z <= 3.5e-16) {
		tmp = x + y;
	} else if (z <= 1.75e-7) {
		tmp = t_0;
	} else if (z <= 1900000.0) {
		tmp = x * (1.0 - z);
	} else if (z <= 2.4e+14) {
		tmp = t_0;
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z):
	t_0 = y * (1.0 - z)
	t_1 = z * (-y - x)
	tmp = 0
	if z <= -1.0:
		tmp = t_1
	elif z <= 3.5e-16:
		tmp = x + y
	elif z <= 1.75e-7:
		tmp = t_0
	elif z <= 1900000.0:
		tmp = x * (1.0 - z)
	elif z <= 2.4e+14:
		tmp = t_0
	else:
		tmp = t_1
	return tmp
function code(x, y, z)
	t_0 = Float64(y * Float64(1.0 - z))
	t_1 = Float64(z * Float64(Float64(-y) - x))
	tmp = 0.0
	if (z <= -1.0)
		tmp = t_1;
	elseif (z <= 3.5e-16)
		tmp = Float64(x + y);
	elseif (z <= 1.75e-7)
		tmp = t_0;
	elseif (z <= 1900000.0)
		tmp = Float64(x * Float64(1.0 - z));
	elseif (z <= 2.4e+14)
		tmp = t_0;
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	t_0 = y * (1.0 - z);
	t_1 = z * (-y - x);
	tmp = 0.0;
	if (z <= -1.0)
		tmp = t_1;
	elseif (z <= 3.5e-16)
		tmp = x + y;
	elseif (z <= 1.75e-7)
		tmp = t_0;
	elseif (z <= 1900000.0)
		tmp = x * (1.0 - z);
	elseif (z <= 2.4e+14)
		tmp = t_0;
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := Block[{t$95$0 = N[(y * N[(1.0 - z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(z * N[((-y) - x), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1.0], t$95$1, If[LessEqual[z, 3.5e-16], N[(x + y), $MachinePrecision], If[LessEqual[z, 1.75e-7], t$95$0, If[LessEqual[z, 1900000.0], N[(x * N[(1.0 - z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2.4e+14], t$95$0, t$95$1]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := y \cdot \left(1 - z\right)\\
t_1 := z \cdot \left(\left(-y\right) - x\right)\\
\mathbf{if}\;z \leq -1:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;z \leq 3.5 \cdot 10^{-16}:\\
\;\;\;\;x + y\\

\mathbf{elif}\;z \leq 1.75 \cdot 10^{-7}:\\
\;\;\;\;t\_0\\

\mathbf{elif}\;z \leq 1900000:\\
\;\;\;\;x \cdot \left(1 - z\right)\\

\mathbf{elif}\;z \leq 2.4 \cdot 10^{+14}:\\
\;\;\;\;t\_0\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if z < -1 or 2.4e14 < z

    1. Initial program 100.0%

      \[\left(x + y\right) \cdot \left(1 - z\right) \]
    2. Add Preprocessing
    3. Taylor expanded in z around inf 99.9%

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

        \[\leadsto \color{blue}{-z \cdot \left(x + y\right)} \]
      2. distribute-lft-neg-out99.9%

        \[\leadsto \color{blue}{\left(-z\right) \cdot \left(x + y\right)} \]
      3. *-commutative99.9%

        \[\leadsto \color{blue}{\left(x + y\right) \cdot \left(-z\right)} \]
      4. +-commutative99.9%

        \[\leadsto \color{blue}{\left(y + x\right)} \cdot \left(-z\right) \]
    5. Simplified99.9%

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

    if -1 < z < 3.50000000000000017e-16

    1. Initial program 100.0%

      \[\left(x + y\right) \cdot \left(1 - z\right) \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 99.1%

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

        \[\leadsto \color{blue}{y + x} \]
    5. Simplified99.1%

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

    if 3.50000000000000017e-16 < z < 1.74999999999999992e-7 or 1.9e6 < z < 2.4e14

    1. Initial program 100.0%

      \[\left(x + y\right) \cdot \left(1 - z\right) \]
    2. Add Preprocessing
    3. Taylor expanded in x around 0 3.0%

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

    if 1.74999999999999992e-7 < z < 1.9e6

    1. Initial program 100.0%

      \[\left(x + y\right) \cdot \left(1 - z\right) \]
    2. Add Preprocessing
    3. Taylor expanded in x around inf 50.8%

      \[\leadsto \color{blue}{x \cdot \left(1 - z\right)} \]
    4. Step-by-step derivation
      1. *-commutative50.8%

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1:\\ \;\;\;\;z \cdot \left(\left(-y\right) - x\right)\\ \mathbf{elif}\;z \leq 3.5 \cdot 10^{-16}:\\ \;\;\;\;x + y\\ \mathbf{elif}\;z \leq 1.75 \cdot 10^{-7}:\\ \;\;\;\;y \cdot \left(1 - z\right)\\ \mathbf{elif}\;z \leq 1900000:\\ \;\;\;\;x \cdot \left(1 - z\right)\\ \mathbf{elif}\;z \leq 2.4 \cdot 10^{+14}:\\ \;\;\;\;y \cdot \left(1 - z\right)\\ \mathbf{else}:\\ \;\;\;\;z \cdot \left(\left(-y\right) - x\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 7: 50.6% accurate, 2.3× speedup?

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

\\
x + y
\end{array}
Derivation
  1. Initial program 100.0%

    \[\left(x + y\right) \cdot \left(1 - z\right) \]
  2. Add Preprocessing
  3. Taylor expanded in z around 0 47.2%

    \[\leadsto \color{blue}{x + y} \]
  4. Step-by-step derivation
    1. +-commutative47.2%

      \[\leadsto \color{blue}{y + x} \]
  5. Simplified47.2%

    \[\leadsto \color{blue}{y + x} \]
  6. Final simplification47.2%

    \[\leadsto x + y \]
  7. Add Preprocessing

Reproduce

?
herbie shell --seed 2024096 
(FPCore (x y z)
  :name "Optimisation.CirclePacking:place from circle-packing-0.1.0.4, H"
  :precision binary64
  (* (+ x y) (- 1.0 z)))