Numeric.SpecFunctions:$slogFactorial from math-functions-0.1.5.2, B

Percentage Accurate: 93.9% → 97.2%
Time: 25.6s
Alternatives: 20
Speedup: 1.0×

Specification

?
\[\begin{array}{l} \\ \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (+
  (+ (- (* (- x 0.5) (log x)) x) 0.91893853320467)
  (/
   (+
    (* (- (* (+ y 0.0007936500793651) z) 0.0027777777777778) z)
    0.083333333333333)
   x)))
double code(double x, double y, double z) {
	return ((((x - 0.5) * log(x)) - x) + 0.91893853320467) + ((((((y + 0.0007936500793651) * z) - 0.0027777777777778) * z) + 0.083333333333333) / x);
}
real(8) function code(x, y, z)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    code = ((((x - 0.5d0) * log(x)) - x) + 0.91893853320467d0) + ((((((y + 0.0007936500793651d0) * z) - 0.0027777777777778d0) * z) + 0.083333333333333d0) / x)
end function
public static double code(double x, double y, double z) {
	return ((((x - 0.5) * Math.log(x)) - x) + 0.91893853320467) + ((((((y + 0.0007936500793651) * z) - 0.0027777777777778) * z) + 0.083333333333333) / x);
}
def code(x, y, z):
	return ((((x - 0.5) * math.log(x)) - x) + 0.91893853320467) + ((((((y + 0.0007936500793651) * z) - 0.0027777777777778) * z) + 0.083333333333333) / x)
function code(x, y, z)
	return Float64(Float64(Float64(Float64(Float64(x - 0.5) * log(x)) - x) + 0.91893853320467) + Float64(Float64(Float64(Float64(Float64(Float64(y + 0.0007936500793651) * z) - 0.0027777777777778) * z) + 0.083333333333333) / x))
end
function tmp = code(x, y, z)
	tmp = ((((x - 0.5) * log(x)) - x) + 0.91893853320467) + ((((((y + 0.0007936500793651) * z) - 0.0027777777777778) * z) + 0.083333333333333) / x);
end
code[x_, y_, z_] := N[(N[(N[(N[(N[(x - 0.5), $MachinePrecision] * N[Log[x], $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision] + 0.91893853320467), $MachinePrecision] + N[(N[(N[(N[(N[(N[(y + 0.0007936500793651), $MachinePrecision] * z), $MachinePrecision] - 0.0027777777777778), $MachinePrecision] * z), $MachinePrecision] + 0.083333333333333), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}
\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 20 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: 93.9% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (+
  (+ (- (* (- x 0.5) (log x)) x) 0.91893853320467)
  (/
   (+
    (* (- (* (+ y 0.0007936500793651) z) 0.0027777777777778) z)
    0.083333333333333)
   x)))
double code(double x, double y, double z) {
	return ((((x - 0.5) * log(x)) - x) + 0.91893853320467) + ((((((y + 0.0007936500793651) * z) - 0.0027777777777778) * z) + 0.083333333333333) / x);
}
real(8) function code(x, y, z)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    code = ((((x - 0.5d0) * log(x)) - x) + 0.91893853320467d0) + ((((((y + 0.0007936500793651d0) * z) - 0.0027777777777778d0) * z) + 0.083333333333333d0) / x)
end function
public static double code(double x, double y, double z) {
	return ((((x - 0.5) * Math.log(x)) - x) + 0.91893853320467) + ((((((y + 0.0007936500793651) * z) - 0.0027777777777778) * z) + 0.083333333333333) / x);
}
def code(x, y, z):
	return ((((x - 0.5) * math.log(x)) - x) + 0.91893853320467) + ((((((y + 0.0007936500793651) * z) - 0.0027777777777778) * z) + 0.083333333333333) / x)
function code(x, y, z)
	return Float64(Float64(Float64(Float64(Float64(x - 0.5) * log(x)) - x) + 0.91893853320467) + Float64(Float64(Float64(Float64(Float64(Float64(y + 0.0007936500793651) * z) - 0.0027777777777778) * z) + 0.083333333333333) / x))
end
function tmp = code(x, y, z)
	tmp = ((((x - 0.5) * log(x)) - x) + 0.91893853320467) + ((((((y + 0.0007936500793651) * z) - 0.0027777777777778) * z) + 0.083333333333333) / x);
end
code[x_, y_, z_] := N[(N[(N[(N[(N[(x - 0.5), $MachinePrecision] * N[Log[x], $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision] + 0.91893853320467), $MachinePrecision] + N[(N[(N[(N[(N[(N[(y + 0.0007936500793651), $MachinePrecision] * z), $MachinePrecision] - 0.0027777777777778), $MachinePrecision] * z), $MachinePrecision] + 0.083333333333333), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}
\end{array}

Alternative 1: 97.2% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;x \leq 6.6 \cdot 10^{+149}:\\ \;\;\;\;\left(\mathsf{fma}\left(\log x, x + -0.5, 0.91893853320467\right) - x\right) + \frac{z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) + 0.083333333333333}{x}\\ \mathbf{else}:\\ \;\;\;\;\left(0.91893853320467 + \left(\log x \cdot \left(x - 0.5\right) - x\right)\right) + y \cdot \left(z \cdot \frac{z}{x}\right)\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (if (<= x 6.6e+149)
   (+
    (- (fma (log x) (+ x -0.5) 0.91893853320467) x)
    (/
     (+
      (* z (- (* (+ y 0.0007936500793651) z) 0.0027777777777778))
      0.083333333333333)
     x))
   (+ (+ 0.91893853320467 (- (* (log x) (- x 0.5)) x)) (* y (* z (/ z x))))))
double code(double x, double y, double z) {
	double tmp;
	if (x <= 6.6e+149) {
		tmp = (fma(log(x), (x + -0.5), 0.91893853320467) - x) + (((z * (((y + 0.0007936500793651) * z) - 0.0027777777777778)) + 0.083333333333333) / x);
	} else {
		tmp = (0.91893853320467 + ((log(x) * (x - 0.5)) - x)) + (y * (z * (z / x)));
	}
	return tmp;
}
function code(x, y, z)
	tmp = 0.0
	if (x <= 6.6e+149)
		tmp = Float64(Float64(fma(log(x), Float64(x + -0.5), 0.91893853320467) - x) + Float64(Float64(Float64(z * Float64(Float64(Float64(y + 0.0007936500793651) * z) - 0.0027777777777778)) + 0.083333333333333) / x));
	else
		tmp = Float64(Float64(0.91893853320467 + Float64(Float64(log(x) * Float64(x - 0.5)) - x)) + Float64(y * Float64(z * Float64(z / x))));
	end
	return tmp
end
code[x_, y_, z_] := If[LessEqual[x, 6.6e+149], N[(N[(N[(N[Log[x], $MachinePrecision] * N[(x + -0.5), $MachinePrecision] + 0.91893853320467), $MachinePrecision] - x), $MachinePrecision] + N[(N[(N[(z * N[(N[(N[(y + 0.0007936500793651), $MachinePrecision] * z), $MachinePrecision] - 0.0027777777777778), $MachinePrecision]), $MachinePrecision] + 0.083333333333333), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision], N[(N[(0.91893853320467 + N[(N[(N[Log[x], $MachinePrecision] * N[(x - 0.5), $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision]), $MachinePrecision] + N[(y * N[(z * N[(z / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;x \leq 6.6 \cdot 10^{+149}:\\
\;\;\;\;\left(\mathsf{fma}\left(\log x, x + -0.5, 0.91893853320467\right) - x\right) + \frac{z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) + 0.083333333333333}{x}\\

\mathbf{else}:\\
\;\;\;\;\left(0.91893853320467 + \left(\log x \cdot \left(x - 0.5\right) - x\right)\right) + y \cdot \left(z \cdot \frac{z}{x}\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if x < 6.6e149

    1. Initial program 98.3%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Taylor expanded in x around 0 98.3%

      \[\leadsto \color{blue}{\left(0.91893853320467 + \left(-0.5 \cdot \log x + x \cdot \left(\log x - 1\right)\right)\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    4. Step-by-step derivation
      1. sub-neg98.3%

        \[\leadsto \left(0.91893853320467 + \left(-0.5 \cdot \log x + x \cdot \color{blue}{\left(\log x + \left(-1\right)\right)}\right)\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      2. metadata-eval98.3%

        \[\leadsto \left(0.91893853320467 + \left(-0.5 \cdot \log x + x \cdot \left(\log x + \color{blue}{-1}\right)\right)\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      3. distribute-rgt-in98.3%

        \[\leadsto \left(0.91893853320467 + \left(-0.5 \cdot \log x + \color{blue}{\left(\log x \cdot x + -1 \cdot x\right)}\right)\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      4. *-commutative98.3%

        \[\leadsto \left(0.91893853320467 + \left(-0.5 \cdot \log x + \left(\color{blue}{x \cdot \log x} + -1 \cdot x\right)\right)\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      5. neg-mul-198.3%

        \[\leadsto \left(0.91893853320467 + \left(-0.5 \cdot \log x + \left(x \cdot \log x + \color{blue}{\left(-x\right)}\right)\right)\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      6. associate-+l+98.3%

        \[\leadsto \left(0.91893853320467 + \color{blue}{\left(\left(-0.5 \cdot \log x + x \cdot \log x\right) + \left(-x\right)\right)}\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      7. distribute-rgt-out98.3%

        \[\leadsto \left(0.91893853320467 + \left(\color{blue}{\log x \cdot \left(-0.5 + x\right)} + \left(-x\right)\right)\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      8. +-commutative98.3%

        \[\leadsto \left(0.91893853320467 + \left(\log x \cdot \color{blue}{\left(x + -0.5\right)} + \left(-x\right)\right)\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      9. associate-+r+98.3%

        \[\leadsto \color{blue}{\left(\left(0.91893853320467 + \log x \cdot \left(x + -0.5\right)\right) + \left(-x\right)\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      10. sub-neg98.3%

        \[\leadsto \color{blue}{\left(\left(0.91893853320467 + \log x \cdot \left(x + -0.5\right)\right) - x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      11. +-commutative98.3%

        \[\leadsto \left(\color{blue}{\left(\log x \cdot \left(x + -0.5\right) + 0.91893853320467\right)} - x\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      12. fma-define98.3%

        \[\leadsto \left(\color{blue}{\mathsf{fma}\left(\log x, x + -0.5, 0.91893853320467\right)} - x\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    5. Simplified98.3%

      \[\leadsto \color{blue}{\left(\mathsf{fma}\left(\log x, x + -0.5, 0.91893853320467\right) - x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]

    if 6.6e149 < x

    1. Initial program 87.7%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Taylor expanded in y around inf 84.1%

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{\frac{y \cdot {z}^{2}}{x}} \]
    4. Step-by-step derivation
      1. associate-/l*87.0%

        \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{y \cdot \frac{{z}^{2}}{x}} \]
    5. Simplified87.0%

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{y \cdot \frac{{z}^{2}}{x}} \]
    6. Step-by-step derivation
      1. unpow287.0%

        \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + y \cdot \frac{\color{blue}{z \cdot z}}{x} \]
      2. associate-/l*96.2%

        \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + y \cdot \color{blue}{\left(z \cdot \frac{z}{x}\right)} \]
    7. Applied egg-rr96.2%

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + y \cdot \color{blue}{\left(z \cdot \frac{z}{x}\right)} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification97.8%

    \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq 6.6 \cdot 10^{+149}:\\ \;\;\;\;\left(\mathsf{fma}\left(\log x, x + -0.5, 0.91893853320467\right) - x\right) + \frac{z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) + 0.083333333333333}{x}\\ \mathbf{else}:\\ \;\;\;\;\left(0.91893853320467 + \left(\log x \cdot \left(x - 0.5\right) - x\right)\right) + y \cdot \left(z \cdot \frac{z}{x}\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 2: 82.1% accurate, 0.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right)\\ \mathbf{if}\;t\_0 \leq -2 \cdot 10^{+40} \lor \neg \left(t\_0 \leq 2 \cdot 10^{+118}\right):\\ \;\;\;\;\frac{\left(y + 0.0007936500793651\right) \cdot {z}^{2}}{x} - x\\ \mathbf{else}:\\ \;\;\;\;\left(0.91893853320467 + \left(x \cdot \log x - x\right)\right) + \frac{1}{x \cdot 12.000000000000048}\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (let* ((t_0 (* z (- (* (+ y 0.0007936500793651) z) 0.0027777777777778))))
   (if (or (<= t_0 -2e+40) (not (<= t_0 2e+118)))
     (- (/ (* (+ y 0.0007936500793651) (pow z 2.0)) x) x)
     (+
      (+ 0.91893853320467 (- (* x (log x)) x))
      (/ 1.0 (* x 12.000000000000048))))))
double code(double x, double y, double z) {
	double t_0 = z * (((y + 0.0007936500793651) * z) - 0.0027777777777778);
	double tmp;
	if ((t_0 <= -2e+40) || !(t_0 <= 2e+118)) {
		tmp = (((y + 0.0007936500793651) * pow(z, 2.0)) / x) - x;
	} else {
		tmp = (0.91893853320467 + ((x * log(x)) - x)) + (1.0 / (x * 12.000000000000048));
	}
	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 + 0.0007936500793651d0) * z) - 0.0027777777777778d0)
    if ((t_0 <= (-2d+40)) .or. (.not. (t_0 <= 2d+118))) then
        tmp = (((y + 0.0007936500793651d0) * (z ** 2.0d0)) / x) - x
    else
        tmp = (0.91893853320467d0 + ((x * log(x)) - x)) + (1.0d0 / (x * 12.000000000000048d0))
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double t_0 = z * (((y + 0.0007936500793651) * z) - 0.0027777777777778);
	double tmp;
	if ((t_0 <= -2e+40) || !(t_0 <= 2e+118)) {
		tmp = (((y + 0.0007936500793651) * Math.pow(z, 2.0)) / x) - x;
	} else {
		tmp = (0.91893853320467 + ((x * Math.log(x)) - x)) + (1.0 / (x * 12.000000000000048));
	}
	return tmp;
}
def code(x, y, z):
	t_0 = z * (((y + 0.0007936500793651) * z) - 0.0027777777777778)
	tmp = 0
	if (t_0 <= -2e+40) or not (t_0 <= 2e+118):
		tmp = (((y + 0.0007936500793651) * math.pow(z, 2.0)) / x) - x
	else:
		tmp = (0.91893853320467 + ((x * math.log(x)) - x)) + (1.0 / (x * 12.000000000000048))
	return tmp
function code(x, y, z)
	t_0 = Float64(z * Float64(Float64(Float64(y + 0.0007936500793651) * z) - 0.0027777777777778))
	tmp = 0.0
	if ((t_0 <= -2e+40) || !(t_0 <= 2e+118))
		tmp = Float64(Float64(Float64(Float64(y + 0.0007936500793651) * (z ^ 2.0)) / x) - x);
	else
		tmp = Float64(Float64(0.91893853320467 + Float64(Float64(x * log(x)) - x)) + Float64(1.0 / Float64(x * 12.000000000000048)));
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	t_0 = z * (((y + 0.0007936500793651) * z) - 0.0027777777777778);
	tmp = 0.0;
	if ((t_0 <= -2e+40) || ~((t_0 <= 2e+118)))
		tmp = (((y + 0.0007936500793651) * (z ^ 2.0)) / x) - x;
	else
		tmp = (0.91893853320467 + ((x * log(x)) - x)) + (1.0 / (x * 12.000000000000048));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := Block[{t$95$0 = N[(z * N[(N[(N[(y + 0.0007936500793651), $MachinePrecision] * z), $MachinePrecision] - 0.0027777777777778), $MachinePrecision]), $MachinePrecision]}, If[Or[LessEqual[t$95$0, -2e+40], N[Not[LessEqual[t$95$0, 2e+118]], $MachinePrecision]], N[(N[(N[(N[(y + 0.0007936500793651), $MachinePrecision] * N[Power[z, 2.0], $MachinePrecision]), $MachinePrecision] / x), $MachinePrecision] - x), $MachinePrecision], N[(N[(0.91893853320467 + N[(N[(x * N[Log[x], $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision]), $MachinePrecision] + N[(1.0 / N[(x * 12.000000000000048), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right)\\
\mathbf{if}\;t\_0 \leq -2 \cdot 10^{+40} \lor \neg \left(t\_0 \leq 2 \cdot 10^{+118}\right):\\
\;\;\;\;\frac{\left(y + 0.0007936500793651\right) \cdot {z}^{2}}{x} - x\\

\mathbf{else}:\\
\;\;\;\;\left(0.91893853320467 + \left(x \cdot \log x - x\right)\right) + \frac{1}{x \cdot 12.000000000000048}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (*.f64 (-.f64 (*.f64 (+.f64 y 7936500793651/10000000000000000) z) 13888888888889/5000000000000000) z) < -2.00000000000000006e40 or 1.99999999999999993e118 < (*.f64 (-.f64 (*.f64 (+.f64 y 7936500793651/10000000000000000) z) 13888888888889/5000000000000000) z)

    1. Initial program 91.5%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. add-cube-cbrt91.4%

        \[\leadsto \left(\left(\color{blue}{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x} \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right) \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      2. pow391.4%

        \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      3. sub-neg91.4%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\left(x + \left(-0.5\right)\right)} \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      4. metadata-eval91.4%

        \[\leadsto \left(\left({\left(\sqrt[3]{\left(x + \color{blue}{-0.5}\right) \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      5. *-commutative91.4%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\log x \cdot \left(x + -0.5\right)}}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    4. Applied egg-rr91.4%

      \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\log x \cdot \left(x + -0.5\right)}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    5. Taylor expanded in x around inf 81.3%

      \[\leadsto \color{blue}{-1 \cdot x} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    6. Step-by-step derivation
      1. neg-mul-181.3%

        \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    7. Simplified81.3%

      \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    8. Taylor expanded in z around inf 81.3%

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

    if -2.00000000000000006e40 < (*.f64 (-.f64 (*.f64 (+.f64 y 7936500793651/10000000000000000) z) 13888888888889/5000000000000000) z) < 1.99999999999999993e118

    1. Initial program 99.5%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 93.4%

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{\frac{0.083333333333333}{x}} \]
    4. Step-by-step derivation
      1. clear-num93.4%

        \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{\frac{1}{\frac{x}{0.083333333333333}}} \]
      2. inv-pow93.4%

        \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{{\left(\frac{x}{0.083333333333333}\right)}^{-1}} \]
      3. div-inv93.4%

        \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + {\color{blue}{\left(x \cdot \frac{1}{0.083333333333333}\right)}}^{-1} \]
      4. metadata-eval93.4%

        \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + {\left(x \cdot \color{blue}{12.000000000000048}\right)}^{-1} \]
    5. Applied egg-rr93.4%

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{{\left(x \cdot 12.000000000000048\right)}^{-1}} \]
    6. Step-by-step derivation
      1. unpow-193.4%

        \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{\frac{1}{x \cdot 12.000000000000048}} \]
    7. Simplified93.4%

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{\frac{1}{x \cdot 12.000000000000048}} \]
    8. Taylor expanded in x around inf 90.9%

      \[\leadsto \left(\left(\color{blue}{-1 \cdot \left(x \cdot \log \left(\frac{1}{x}\right)\right)} - x\right) + 0.91893853320467\right) + \frac{1}{x \cdot 12.000000000000048} \]
    9. Step-by-step derivation
      1. mul-1-neg90.9%

        \[\leadsto \left(\left(\color{blue}{\left(-x \cdot \log \left(\frac{1}{x}\right)\right)} - x\right) + 0.91893853320467\right) + \frac{1}{x \cdot 12.000000000000048} \]
      2. distribute-rgt-neg-in90.9%

        \[\leadsto \left(\left(\color{blue}{x \cdot \left(-\log \left(\frac{1}{x}\right)\right)} - x\right) + 0.91893853320467\right) + \frac{1}{x \cdot 12.000000000000048} \]
      3. log-rec90.9%

        \[\leadsto \left(\left(x \cdot \left(-\color{blue}{\left(-\log x\right)}\right) - x\right) + 0.91893853320467\right) + \frac{1}{x \cdot 12.000000000000048} \]
      4. remove-double-neg90.9%

        \[\leadsto \left(\left(x \cdot \color{blue}{\log x} - x\right) + 0.91893853320467\right) + \frac{1}{x \cdot 12.000000000000048} \]
    10. Simplified90.9%

      \[\leadsto \left(\left(\color{blue}{x \cdot \log x} - x\right) + 0.91893853320467\right) + \frac{1}{x \cdot 12.000000000000048} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification86.4%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \leq -2 \cdot 10^{+40} \lor \neg \left(z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \leq 2 \cdot 10^{+118}\right):\\ \;\;\;\;\frac{\left(y + 0.0007936500793651\right) \cdot {z}^{2}}{x} - x\\ \mathbf{else}:\\ \;\;\;\;\left(0.91893853320467 + \left(x \cdot \log x - x\right)\right) + \frac{1}{x \cdot 12.000000000000048}\\ \end{array} \]
  5. Add Preprocessing

Alternative 3: 83.1% accurate, 0.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right)\\ \mathbf{if}\;t\_0 \leq -2 \cdot 10^{+40} \lor \neg \left(t\_0 \leq 2 \cdot 10^{+118}\right):\\ \;\;\;\;\frac{\left(y + 0.0007936500793651\right) \cdot {z}^{2}}{x} - x\\ \mathbf{else}:\\ \;\;\;\;\left(0.91893853320467 + \left(\log x \cdot \left(x - 0.5\right) - x\right)\right) + \frac{0.083333333333333}{x}\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (let* ((t_0 (* z (- (* (+ y 0.0007936500793651) z) 0.0027777777777778))))
   (if (or (<= t_0 -2e+40) (not (<= t_0 2e+118)))
     (- (/ (* (+ y 0.0007936500793651) (pow z 2.0)) x) x)
     (+
      (+ 0.91893853320467 (- (* (log x) (- x 0.5)) x))
      (/ 0.083333333333333 x)))))
double code(double x, double y, double z) {
	double t_0 = z * (((y + 0.0007936500793651) * z) - 0.0027777777777778);
	double tmp;
	if ((t_0 <= -2e+40) || !(t_0 <= 2e+118)) {
		tmp = (((y + 0.0007936500793651) * pow(z, 2.0)) / x) - x;
	} else {
		tmp = (0.91893853320467 + ((log(x) * (x - 0.5)) - x)) + (0.083333333333333 / x);
	}
	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 + 0.0007936500793651d0) * z) - 0.0027777777777778d0)
    if ((t_0 <= (-2d+40)) .or. (.not. (t_0 <= 2d+118))) then
        tmp = (((y + 0.0007936500793651d0) * (z ** 2.0d0)) / x) - x
    else
        tmp = (0.91893853320467d0 + ((log(x) * (x - 0.5d0)) - x)) + (0.083333333333333d0 / x)
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double t_0 = z * (((y + 0.0007936500793651) * z) - 0.0027777777777778);
	double tmp;
	if ((t_0 <= -2e+40) || !(t_0 <= 2e+118)) {
		tmp = (((y + 0.0007936500793651) * Math.pow(z, 2.0)) / x) - x;
	} else {
		tmp = (0.91893853320467 + ((Math.log(x) * (x - 0.5)) - x)) + (0.083333333333333 / x);
	}
	return tmp;
}
def code(x, y, z):
	t_0 = z * (((y + 0.0007936500793651) * z) - 0.0027777777777778)
	tmp = 0
	if (t_0 <= -2e+40) or not (t_0 <= 2e+118):
		tmp = (((y + 0.0007936500793651) * math.pow(z, 2.0)) / x) - x
	else:
		tmp = (0.91893853320467 + ((math.log(x) * (x - 0.5)) - x)) + (0.083333333333333 / x)
	return tmp
function code(x, y, z)
	t_0 = Float64(z * Float64(Float64(Float64(y + 0.0007936500793651) * z) - 0.0027777777777778))
	tmp = 0.0
	if ((t_0 <= -2e+40) || !(t_0 <= 2e+118))
		tmp = Float64(Float64(Float64(Float64(y + 0.0007936500793651) * (z ^ 2.0)) / x) - x);
	else
		tmp = Float64(Float64(0.91893853320467 + Float64(Float64(log(x) * Float64(x - 0.5)) - x)) + Float64(0.083333333333333 / x));
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	t_0 = z * (((y + 0.0007936500793651) * z) - 0.0027777777777778);
	tmp = 0.0;
	if ((t_0 <= -2e+40) || ~((t_0 <= 2e+118)))
		tmp = (((y + 0.0007936500793651) * (z ^ 2.0)) / x) - x;
	else
		tmp = (0.91893853320467 + ((log(x) * (x - 0.5)) - x)) + (0.083333333333333 / x);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := Block[{t$95$0 = N[(z * N[(N[(N[(y + 0.0007936500793651), $MachinePrecision] * z), $MachinePrecision] - 0.0027777777777778), $MachinePrecision]), $MachinePrecision]}, If[Or[LessEqual[t$95$0, -2e+40], N[Not[LessEqual[t$95$0, 2e+118]], $MachinePrecision]], N[(N[(N[(N[(y + 0.0007936500793651), $MachinePrecision] * N[Power[z, 2.0], $MachinePrecision]), $MachinePrecision] / x), $MachinePrecision] - x), $MachinePrecision], N[(N[(0.91893853320467 + N[(N[(N[Log[x], $MachinePrecision] * N[(x - 0.5), $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision]), $MachinePrecision] + N[(0.083333333333333 / x), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right)\\
\mathbf{if}\;t\_0 \leq -2 \cdot 10^{+40} \lor \neg \left(t\_0 \leq 2 \cdot 10^{+118}\right):\\
\;\;\;\;\frac{\left(y + 0.0007936500793651\right) \cdot {z}^{2}}{x} - x\\

\mathbf{else}:\\
\;\;\;\;\left(0.91893853320467 + \left(\log x \cdot \left(x - 0.5\right) - x\right)\right) + \frac{0.083333333333333}{x}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (*.f64 (-.f64 (*.f64 (+.f64 y 7936500793651/10000000000000000) z) 13888888888889/5000000000000000) z) < -2.00000000000000006e40 or 1.99999999999999993e118 < (*.f64 (-.f64 (*.f64 (+.f64 y 7936500793651/10000000000000000) z) 13888888888889/5000000000000000) z)

    1. Initial program 91.5%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. add-cube-cbrt91.4%

        \[\leadsto \left(\left(\color{blue}{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x} \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right) \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      2. pow391.4%

        \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      3. sub-neg91.4%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\left(x + \left(-0.5\right)\right)} \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      4. metadata-eval91.4%

        \[\leadsto \left(\left({\left(\sqrt[3]{\left(x + \color{blue}{-0.5}\right) \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      5. *-commutative91.4%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\log x \cdot \left(x + -0.5\right)}}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    4. Applied egg-rr91.4%

      \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\log x \cdot \left(x + -0.5\right)}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    5. Taylor expanded in x around inf 81.3%

      \[\leadsto \color{blue}{-1 \cdot x} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    6. Step-by-step derivation
      1. neg-mul-181.3%

        \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    7. Simplified81.3%

      \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    8. Taylor expanded in z around inf 81.3%

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

    if -2.00000000000000006e40 < (*.f64 (-.f64 (*.f64 (+.f64 y 7936500793651/10000000000000000) z) 13888888888889/5000000000000000) z) < 1.99999999999999993e118

    1. Initial program 99.5%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 93.4%

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{\frac{0.083333333333333}{x}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification87.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \leq -2 \cdot 10^{+40} \lor \neg \left(z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \leq 2 \cdot 10^{+118}\right):\\ \;\;\;\;\frac{\left(y + 0.0007936500793651\right) \cdot {z}^{2}}{x} - x\\ \mathbf{else}:\\ \;\;\;\;\left(0.91893853320467 + \left(\log x \cdot \left(x - 0.5\right) - x\right)\right) + \frac{0.083333333333333}{x}\\ \end{array} \]
  5. Add Preprocessing

Alternative 4: 82.1% accurate, 0.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right)\\ \mathbf{if}\;t\_0 \leq -2 \cdot 10^{+40} \lor \neg \left(t\_0 \leq 2 \cdot 10^{+118}\right):\\ \;\;\;\;\frac{\left(y + 0.0007936500793651\right) \cdot {z}^{2}}{x} - x\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(\log x + -1\right) + \frac{0.083333333333333}{x}\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (let* ((t_0 (* z (- (* (+ y 0.0007936500793651) z) 0.0027777777777778))))
   (if (or (<= t_0 -2e+40) (not (<= t_0 2e+118)))
     (- (/ (* (+ y 0.0007936500793651) (pow z 2.0)) x) x)
     (+ (* x (+ (log x) -1.0)) (/ 0.083333333333333 x)))))
double code(double x, double y, double z) {
	double t_0 = z * (((y + 0.0007936500793651) * z) - 0.0027777777777778);
	double tmp;
	if ((t_0 <= -2e+40) || !(t_0 <= 2e+118)) {
		tmp = (((y + 0.0007936500793651) * pow(z, 2.0)) / x) - x;
	} else {
		tmp = (x * (log(x) + -1.0)) + (0.083333333333333 / x);
	}
	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 + 0.0007936500793651d0) * z) - 0.0027777777777778d0)
    if ((t_0 <= (-2d+40)) .or. (.not. (t_0 <= 2d+118))) then
        tmp = (((y + 0.0007936500793651d0) * (z ** 2.0d0)) / x) - x
    else
        tmp = (x * (log(x) + (-1.0d0))) + (0.083333333333333d0 / x)
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double t_0 = z * (((y + 0.0007936500793651) * z) - 0.0027777777777778);
	double tmp;
	if ((t_0 <= -2e+40) || !(t_0 <= 2e+118)) {
		tmp = (((y + 0.0007936500793651) * Math.pow(z, 2.0)) / x) - x;
	} else {
		tmp = (x * (Math.log(x) + -1.0)) + (0.083333333333333 / x);
	}
	return tmp;
}
def code(x, y, z):
	t_0 = z * (((y + 0.0007936500793651) * z) - 0.0027777777777778)
	tmp = 0
	if (t_0 <= -2e+40) or not (t_0 <= 2e+118):
		tmp = (((y + 0.0007936500793651) * math.pow(z, 2.0)) / x) - x
	else:
		tmp = (x * (math.log(x) + -1.0)) + (0.083333333333333 / x)
	return tmp
function code(x, y, z)
	t_0 = Float64(z * Float64(Float64(Float64(y + 0.0007936500793651) * z) - 0.0027777777777778))
	tmp = 0.0
	if ((t_0 <= -2e+40) || !(t_0 <= 2e+118))
		tmp = Float64(Float64(Float64(Float64(y + 0.0007936500793651) * (z ^ 2.0)) / x) - x);
	else
		tmp = Float64(Float64(x * Float64(log(x) + -1.0)) + Float64(0.083333333333333 / x));
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	t_0 = z * (((y + 0.0007936500793651) * z) - 0.0027777777777778);
	tmp = 0.0;
	if ((t_0 <= -2e+40) || ~((t_0 <= 2e+118)))
		tmp = (((y + 0.0007936500793651) * (z ^ 2.0)) / x) - x;
	else
		tmp = (x * (log(x) + -1.0)) + (0.083333333333333 / x);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := Block[{t$95$0 = N[(z * N[(N[(N[(y + 0.0007936500793651), $MachinePrecision] * z), $MachinePrecision] - 0.0027777777777778), $MachinePrecision]), $MachinePrecision]}, If[Or[LessEqual[t$95$0, -2e+40], N[Not[LessEqual[t$95$0, 2e+118]], $MachinePrecision]], N[(N[(N[(N[(y + 0.0007936500793651), $MachinePrecision] * N[Power[z, 2.0], $MachinePrecision]), $MachinePrecision] / x), $MachinePrecision] - x), $MachinePrecision], N[(N[(x * N[(N[Log[x], $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision] + N[(0.083333333333333 / x), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right)\\
\mathbf{if}\;t\_0 \leq -2 \cdot 10^{+40} \lor \neg \left(t\_0 \leq 2 \cdot 10^{+118}\right):\\
\;\;\;\;\frac{\left(y + 0.0007936500793651\right) \cdot {z}^{2}}{x} - x\\

\mathbf{else}:\\
\;\;\;\;x \cdot \left(\log x + -1\right) + \frac{0.083333333333333}{x}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (*.f64 (-.f64 (*.f64 (+.f64 y 7936500793651/10000000000000000) z) 13888888888889/5000000000000000) z) < -2.00000000000000006e40 or 1.99999999999999993e118 < (*.f64 (-.f64 (*.f64 (+.f64 y 7936500793651/10000000000000000) z) 13888888888889/5000000000000000) z)

    1. Initial program 91.5%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. add-cube-cbrt91.4%

        \[\leadsto \left(\left(\color{blue}{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x} \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right) \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      2. pow391.4%

        \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      3. sub-neg91.4%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\left(x + \left(-0.5\right)\right)} \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      4. metadata-eval91.4%

        \[\leadsto \left(\left({\left(\sqrt[3]{\left(x + \color{blue}{-0.5}\right) \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      5. *-commutative91.4%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\log x \cdot \left(x + -0.5\right)}}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    4. Applied egg-rr91.4%

      \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\log x \cdot \left(x + -0.5\right)}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    5. Taylor expanded in x around inf 81.3%

      \[\leadsto \color{blue}{-1 \cdot x} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    6. Step-by-step derivation
      1. neg-mul-181.3%

        \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    7. Simplified81.3%

      \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    8. Taylor expanded in z around inf 81.3%

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

    if -2.00000000000000006e40 < (*.f64 (-.f64 (*.f64 (+.f64 y 7936500793651/10000000000000000) z) 13888888888889/5000000000000000) z) < 1.99999999999999993e118

    1. Initial program 99.5%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 93.4%

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{\frac{0.083333333333333}{x}} \]
    4. Taylor expanded in x around inf 90.9%

      \[\leadsto \color{blue}{x \cdot \left(-1 \cdot \log \left(\frac{1}{x}\right) - 1\right)} + \frac{0.083333333333333}{x} \]
    5. Step-by-step derivation
      1. sub-neg90.9%

        \[\leadsto x \cdot \color{blue}{\left(-1 \cdot \log \left(\frac{1}{x}\right) + \left(-1\right)\right)} + \frac{0.083333333333333}{x} \]
      2. mul-1-neg90.9%

        \[\leadsto x \cdot \left(\color{blue}{\left(-\log \left(\frac{1}{x}\right)\right)} + \left(-1\right)\right) + \frac{0.083333333333333}{x} \]
      3. log-rec90.9%

        \[\leadsto x \cdot \left(\left(-\color{blue}{\left(-\log x\right)}\right) + \left(-1\right)\right) + \frac{0.083333333333333}{x} \]
      4. remove-double-neg90.9%

        \[\leadsto x \cdot \left(\color{blue}{\log x} + \left(-1\right)\right) + \frac{0.083333333333333}{x} \]
      5. metadata-eval90.9%

        \[\leadsto x \cdot \left(\log x + \color{blue}{-1}\right) + \frac{0.083333333333333}{x} \]
    6. Simplified90.9%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \leq -2 \cdot 10^{+40} \lor \neg \left(z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \leq 2 \cdot 10^{+118}\right):\\ \;\;\;\;\frac{\left(y + 0.0007936500793651\right) \cdot {z}^{2}}{x} - x\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(\log x + -1\right) + \frac{0.083333333333333}{x}\\ \end{array} \]
  5. Add Preprocessing

Alternative 5: 82.0% accurate, 0.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right)\\ \mathbf{if}\;t\_0 \leq -2 \cdot 10^{+40}:\\ \;\;\;\;\frac{0.083333333333333 + z \cdot \left(y \cdot z - 0.0027777777777778\right)}{x} - x\\ \mathbf{elif}\;t\_0 \leq 2 \cdot 10^{+118}:\\ \;\;\;\;x \cdot \left(\log x + -1\right) + \frac{0.083333333333333}{x}\\ \mathbf{else}:\\ \;\;\;\;\frac{t\_0 + 0.083333333333333}{x} - x\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (let* ((t_0 (* z (- (* (+ y 0.0007936500793651) z) 0.0027777777777778))))
   (if (<= t_0 -2e+40)
     (- (/ (+ 0.083333333333333 (* z (- (* y z) 0.0027777777777778))) x) x)
     (if (<= t_0 2e+118)
       (+ (* x (+ (log x) -1.0)) (/ 0.083333333333333 x))
       (- (/ (+ t_0 0.083333333333333) x) x)))))
double code(double x, double y, double z) {
	double t_0 = z * (((y + 0.0007936500793651) * z) - 0.0027777777777778);
	double tmp;
	if (t_0 <= -2e+40) {
		tmp = ((0.083333333333333 + (z * ((y * z) - 0.0027777777777778))) / x) - x;
	} else if (t_0 <= 2e+118) {
		tmp = (x * (log(x) + -1.0)) + (0.083333333333333 / x);
	} else {
		tmp = ((t_0 + 0.083333333333333) / x) - x;
	}
	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 + 0.0007936500793651d0) * z) - 0.0027777777777778d0)
    if (t_0 <= (-2d+40)) then
        tmp = ((0.083333333333333d0 + (z * ((y * z) - 0.0027777777777778d0))) / x) - x
    else if (t_0 <= 2d+118) then
        tmp = (x * (log(x) + (-1.0d0))) + (0.083333333333333d0 / x)
    else
        tmp = ((t_0 + 0.083333333333333d0) / x) - x
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double t_0 = z * (((y + 0.0007936500793651) * z) - 0.0027777777777778);
	double tmp;
	if (t_0 <= -2e+40) {
		tmp = ((0.083333333333333 + (z * ((y * z) - 0.0027777777777778))) / x) - x;
	} else if (t_0 <= 2e+118) {
		tmp = (x * (Math.log(x) + -1.0)) + (0.083333333333333 / x);
	} else {
		tmp = ((t_0 + 0.083333333333333) / x) - x;
	}
	return tmp;
}
def code(x, y, z):
	t_0 = z * (((y + 0.0007936500793651) * z) - 0.0027777777777778)
	tmp = 0
	if t_0 <= -2e+40:
		tmp = ((0.083333333333333 + (z * ((y * z) - 0.0027777777777778))) / x) - x
	elif t_0 <= 2e+118:
		tmp = (x * (math.log(x) + -1.0)) + (0.083333333333333 / x)
	else:
		tmp = ((t_0 + 0.083333333333333) / x) - x
	return tmp
function code(x, y, z)
	t_0 = Float64(z * Float64(Float64(Float64(y + 0.0007936500793651) * z) - 0.0027777777777778))
	tmp = 0.0
	if (t_0 <= -2e+40)
		tmp = Float64(Float64(Float64(0.083333333333333 + Float64(z * Float64(Float64(y * z) - 0.0027777777777778))) / x) - x);
	elseif (t_0 <= 2e+118)
		tmp = Float64(Float64(x * Float64(log(x) + -1.0)) + Float64(0.083333333333333 / x));
	else
		tmp = Float64(Float64(Float64(t_0 + 0.083333333333333) / x) - x);
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	t_0 = z * (((y + 0.0007936500793651) * z) - 0.0027777777777778);
	tmp = 0.0;
	if (t_0 <= -2e+40)
		tmp = ((0.083333333333333 + (z * ((y * z) - 0.0027777777777778))) / x) - x;
	elseif (t_0 <= 2e+118)
		tmp = (x * (log(x) + -1.0)) + (0.083333333333333 / x);
	else
		tmp = ((t_0 + 0.083333333333333) / x) - x;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := Block[{t$95$0 = N[(z * N[(N[(N[(y + 0.0007936500793651), $MachinePrecision] * z), $MachinePrecision] - 0.0027777777777778), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$0, -2e+40], N[(N[(N[(0.083333333333333 + N[(z * N[(N[(y * z), $MachinePrecision] - 0.0027777777777778), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / x), $MachinePrecision] - x), $MachinePrecision], If[LessEqual[t$95$0, 2e+118], N[(N[(x * N[(N[Log[x], $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision] + N[(0.083333333333333 / x), $MachinePrecision]), $MachinePrecision], N[(N[(N[(t$95$0 + 0.083333333333333), $MachinePrecision] / x), $MachinePrecision] - x), $MachinePrecision]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right)\\
\mathbf{if}\;t\_0 \leq -2 \cdot 10^{+40}:\\
\;\;\;\;\frac{0.083333333333333 + z \cdot \left(y \cdot z - 0.0027777777777778\right)}{x} - x\\

\mathbf{elif}\;t\_0 \leq 2 \cdot 10^{+118}:\\
\;\;\;\;x \cdot \left(\log x + -1\right) + \frac{0.083333333333333}{x}\\

\mathbf{else}:\\
\;\;\;\;\frac{t\_0 + 0.083333333333333}{x} - x\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (*.f64 (-.f64 (*.f64 (+.f64 y 7936500793651/10000000000000000) z) 13888888888889/5000000000000000) z) < -2.00000000000000006e40

    1. Initial program 96.6%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. add-cube-cbrt96.3%

        \[\leadsto \left(\left(\color{blue}{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x} \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right) \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      2. pow396.3%

        \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      3. sub-neg96.3%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\left(x + \left(-0.5\right)\right)} \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      4. metadata-eval96.3%

        \[\leadsto \left(\left({\left(\sqrt[3]{\left(x + \color{blue}{-0.5}\right) \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      5. *-commutative96.3%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\log x \cdot \left(x + -0.5\right)}}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    4. Applied egg-rr96.3%

      \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\log x \cdot \left(x + -0.5\right)}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    5. Taylor expanded in x around inf 85.9%

      \[\leadsto \color{blue}{-1 \cdot x} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    6. Step-by-step derivation
      1. neg-mul-185.9%

        \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    7. Simplified85.9%

      \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    8. Taylor expanded in y around inf 85.9%

      \[\leadsto \left(-x\right) + \frac{\left(\color{blue}{y \cdot z} - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    9. Step-by-step derivation
      1. *-commutative85.9%

        \[\leadsto \left(-x\right) + \frac{\left(\color{blue}{z \cdot y} - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    10. Simplified85.9%

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

    if -2.00000000000000006e40 < (*.f64 (-.f64 (*.f64 (+.f64 y 7936500793651/10000000000000000) z) 13888888888889/5000000000000000) z) < 1.99999999999999993e118

    1. Initial program 99.5%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Taylor expanded in z around 0 93.4%

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{\frac{0.083333333333333}{x}} \]
    4. Taylor expanded in x around inf 90.9%

      \[\leadsto \color{blue}{x \cdot \left(-1 \cdot \log \left(\frac{1}{x}\right) - 1\right)} + \frac{0.083333333333333}{x} \]
    5. Step-by-step derivation
      1. sub-neg90.9%

        \[\leadsto x \cdot \color{blue}{\left(-1 \cdot \log \left(\frac{1}{x}\right) + \left(-1\right)\right)} + \frac{0.083333333333333}{x} \]
      2. mul-1-neg90.9%

        \[\leadsto x \cdot \left(\color{blue}{\left(-\log \left(\frac{1}{x}\right)\right)} + \left(-1\right)\right) + \frac{0.083333333333333}{x} \]
      3. log-rec90.9%

        \[\leadsto x \cdot \left(\left(-\color{blue}{\left(-\log x\right)}\right) + \left(-1\right)\right) + \frac{0.083333333333333}{x} \]
      4. remove-double-neg90.9%

        \[\leadsto x \cdot \left(\color{blue}{\log x} + \left(-1\right)\right) + \frac{0.083333333333333}{x} \]
      5. metadata-eval90.9%

        \[\leadsto x \cdot \left(\log x + \color{blue}{-1}\right) + \frac{0.083333333333333}{x} \]
    6. Simplified90.9%

      \[\leadsto \color{blue}{x \cdot \left(\log x + -1\right)} + \frac{0.083333333333333}{x} \]

    if 1.99999999999999993e118 < (*.f64 (-.f64 (*.f64 (+.f64 y 7936500793651/10000000000000000) z) 13888888888889/5000000000000000) z)

    1. Initial program 89.9%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. add-cube-cbrt89.9%

        \[\leadsto \left(\left(\color{blue}{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x} \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right) \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      2. pow389.9%

        \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      3. sub-neg89.9%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\left(x + \left(-0.5\right)\right)} \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      4. metadata-eval89.9%

        \[\leadsto \left(\left({\left(\sqrt[3]{\left(x + \color{blue}{-0.5}\right) \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      5. *-commutative89.9%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\log x \cdot \left(x + -0.5\right)}}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    4. Applied egg-rr89.9%

      \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\log x \cdot \left(x + -0.5\right)}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    5. Taylor expanded in x around inf 79.9%

      \[\leadsto \color{blue}{-1 \cdot x} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    6. Step-by-step derivation
      1. neg-mul-179.9%

        \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    7. Simplified79.9%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \leq -2 \cdot 10^{+40}:\\ \;\;\;\;\frac{0.083333333333333 + z \cdot \left(y \cdot z - 0.0027777777777778\right)}{x} - x\\ \mathbf{elif}\;z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \leq 2 \cdot 10^{+118}:\\ \;\;\;\;x \cdot \left(\log x + -1\right) + \frac{0.083333333333333}{x}\\ \mathbf{else}:\\ \;\;\;\;\frac{z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) + 0.083333333333333}{x} - x\\ \end{array} \]
  5. Add Preprocessing

Alternative 6: 92.1% accurate, 0.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := x \cdot \left(\log x + -1\right)\\ \mathbf{if}\;y + 0.0007936500793651 \leq -1000000000000 \lor \neg \left(y + 0.0007936500793651 \leq 0.00079366\right):\\ \;\;\;\;t\_0 + \frac{0.083333333333333 + z \cdot \left(y \cdot z - 0.0027777777777778\right)}{x}\\ \mathbf{else}:\\ \;\;\;\;t\_0 + \frac{0.083333333333333 + z \cdot \left(0.0007936500793651 \cdot z - 0.0027777777777778\right)}{x}\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (let* ((t_0 (* x (+ (log x) -1.0))))
   (if (or (<= (+ y 0.0007936500793651) -1000000000000.0)
           (not (<= (+ y 0.0007936500793651) 0.00079366)))
     (+ t_0 (/ (+ 0.083333333333333 (* z (- (* y z) 0.0027777777777778))) x))
     (+
      t_0
      (/
       (+
        0.083333333333333
        (* z (- (* 0.0007936500793651 z) 0.0027777777777778)))
       x)))))
double code(double x, double y, double z) {
	double t_0 = x * (log(x) + -1.0);
	double tmp;
	if (((y + 0.0007936500793651) <= -1000000000000.0) || !((y + 0.0007936500793651) <= 0.00079366)) {
		tmp = t_0 + ((0.083333333333333 + (z * ((y * z) - 0.0027777777777778))) / x);
	} else {
		tmp = t_0 + ((0.083333333333333 + (z * ((0.0007936500793651 * z) - 0.0027777777777778))) / x);
	}
	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 = x * (log(x) + (-1.0d0))
    if (((y + 0.0007936500793651d0) <= (-1000000000000.0d0)) .or. (.not. ((y + 0.0007936500793651d0) <= 0.00079366d0))) then
        tmp = t_0 + ((0.083333333333333d0 + (z * ((y * z) - 0.0027777777777778d0))) / x)
    else
        tmp = t_0 + ((0.083333333333333d0 + (z * ((0.0007936500793651d0 * z) - 0.0027777777777778d0))) / x)
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double t_0 = x * (Math.log(x) + -1.0);
	double tmp;
	if (((y + 0.0007936500793651) <= -1000000000000.0) || !((y + 0.0007936500793651) <= 0.00079366)) {
		tmp = t_0 + ((0.083333333333333 + (z * ((y * z) - 0.0027777777777778))) / x);
	} else {
		tmp = t_0 + ((0.083333333333333 + (z * ((0.0007936500793651 * z) - 0.0027777777777778))) / x);
	}
	return tmp;
}
def code(x, y, z):
	t_0 = x * (math.log(x) + -1.0)
	tmp = 0
	if ((y + 0.0007936500793651) <= -1000000000000.0) or not ((y + 0.0007936500793651) <= 0.00079366):
		tmp = t_0 + ((0.083333333333333 + (z * ((y * z) - 0.0027777777777778))) / x)
	else:
		tmp = t_0 + ((0.083333333333333 + (z * ((0.0007936500793651 * z) - 0.0027777777777778))) / x)
	return tmp
function code(x, y, z)
	t_0 = Float64(x * Float64(log(x) + -1.0))
	tmp = 0.0
	if ((Float64(y + 0.0007936500793651) <= -1000000000000.0) || !(Float64(y + 0.0007936500793651) <= 0.00079366))
		tmp = Float64(t_0 + Float64(Float64(0.083333333333333 + Float64(z * Float64(Float64(y * z) - 0.0027777777777778))) / x));
	else
		tmp = Float64(t_0 + Float64(Float64(0.083333333333333 + Float64(z * Float64(Float64(0.0007936500793651 * z) - 0.0027777777777778))) / x));
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	t_0 = x * (log(x) + -1.0);
	tmp = 0.0;
	if (((y + 0.0007936500793651) <= -1000000000000.0) || ~(((y + 0.0007936500793651) <= 0.00079366)))
		tmp = t_0 + ((0.083333333333333 + (z * ((y * z) - 0.0027777777777778))) / x);
	else
		tmp = t_0 + ((0.083333333333333 + (z * ((0.0007936500793651 * z) - 0.0027777777777778))) / x);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := Block[{t$95$0 = N[(x * N[(N[Log[x], $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision]}, If[Or[LessEqual[N[(y + 0.0007936500793651), $MachinePrecision], -1000000000000.0], N[Not[LessEqual[N[(y + 0.0007936500793651), $MachinePrecision], 0.00079366]], $MachinePrecision]], N[(t$95$0 + N[(N[(0.083333333333333 + N[(z * N[(N[(y * z), $MachinePrecision] - 0.0027777777777778), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision], N[(t$95$0 + N[(N[(0.083333333333333 + N[(z * N[(N[(0.0007936500793651 * z), $MachinePrecision] - 0.0027777777777778), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := x \cdot \left(\log x + -1\right)\\
\mathbf{if}\;y + 0.0007936500793651 \leq -1000000000000 \lor \neg \left(y + 0.0007936500793651 \leq 0.00079366\right):\\
\;\;\;\;t\_0 + \frac{0.083333333333333 + z \cdot \left(y \cdot z - 0.0027777777777778\right)}{x}\\

\mathbf{else}:\\
\;\;\;\;t\_0 + \frac{0.083333333333333 + z \cdot \left(0.0007936500793651 \cdot z - 0.0027777777777778\right)}{x}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (+.f64 y 7936500793651/10000000000000000) < -1e12 or 7.9365999999999996e-4 < (+.f64 y 7936500793651/10000000000000000)

    1. Initial program 95.9%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Taylor expanded in x around inf 94.7%

      \[\leadsto \color{blue}{x \cdot \left(-1 \cdot \log \left(\frac{1}{x}\right) - 1\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    4. Step-by-step derivation
      1. sub-neg49.0%

        \[\leadsto x \cdot \color{blue}{\left(-1 \cdot \log \left(\frac{1}{x}\right) + \left(-1\right)\right)} + \frac{0.083333333333333}{x} \]
      2. mul-1-neg49.0%

        \[\leadsto x \cdot \left(\color{blue}{\left(-\log \left(\frac{1}{x}\right)\right)} + \left(-1\right)\right) + \frac{0.083333333333333}{x} \]
      3. log-rec49.0%

        \[\leadsto x \cdot \left(\left(-\color{blue}{\left(-\log x\right)}\right) + \left(-1\right)\right) + \frac{0.083333333333333}{x} \]
      4. remove-double-neg49.0%

        \[\leadsto x \cdot \left(\color{blue}{\log x} + \left(-1\right)\right) + \frac{0.083333333333333}{x} \]
      5. metadata-eval49.0%

        \[\leadsto x \cdot \left(\log x + \color{blue}{-1}\right) + \frac{0.083333333333333}{x} \]
    5. Simplified94.7%

      \[\leadsto \color{blue}{x \cdot \left(\log x + -1\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    6. Taylor expanded in y around inf 94.7%

      \[\leadsto x \cdot \left(\log x + -1\right) + \frac{\left(\color{blue}{y \cdot z} - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    7. Step-by-step derivation
      1. *-commutative68.4%

        \[\leadsto \left(-x\right) + \frac{\left(\color{blue}{z \cdot y} - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    8. Simplified94.7%

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

    if -1e12 < (+.f64 y 7936500793651/10000000000000000) < 7.9365999999999996e-4

    1. Initial program 95.6%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Taylor expanded in x around inf 94.1%

      \[\leadsto \color{blue}{x \cdot \left(-1 \cdot \log \left(\frac{1}{x}\right) - 1\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    4. Step-by-step derivation
      1. sub-neg61.9%

        \[\leadsto x \cdot \color{blue}{\left(-1 \cdot \log \left(\frac{1}{x}\right) + \left(-1\right)\right)} + \frac{0.083333333333333}{x} \]
      2. mul-1-neg61.9%

        \[\leadsto x \cdot \left(\color{blue}{\left(-\log \left(\frac{1}{x}\right)\right)} + \left(-1\right)\right) + \frac{0.083333333333333}{x} \]
      3. log-rec61.9%

        \[\leadsto x \cdot \left(\left(-\color{blue}{\left(-\log x\right)}\right) + \left(-1\right)\right) + \frac{0.083333333333333}{x} \]
      4. remove-double-neg61.9%

        \[\leadsto x \cdot \left(\color{blue}{\log x} + \left(-1\right)\right) + \frac{0.083333333333333}{x} \]
      5. metadata-eval61.9%

        \[\leadsto x \cdot \left(\log x + \color{blue}{-1}\right) + \frac{0.083333333333333}{x} \]
    5. Simplified94.1%

      \[\leadsto \color{blue}{x \cdot \left(\log x + -1\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    6. Taylor expanded in y around 0 94.1%

      \[\leadsto x \cdot \left(\log x + -1\right) + \frac{\left(\color{blue}{0.0007936500793651 \cdot z} - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification94.4%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y + 0.0007936500793651 \leq -1000000000000 \lor \neg \left(y + 0.0007936500793651 \leq 0.00079366\right):\\ \;\;\;\;x \cdot \left(\log x + -1\right) + \frac{0.083333333333333 + z \cdot \left(y \cdot z - 0.0027777777777778\right)}{x}\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(\log x + -1\right) + \frac{0.083333333333333 + z \cdot \left(0.0007936500793651 \cdot z - 0.0027777777777778\right)}{x}\\ \end{array} \]
  5. Add Preprocessing

Alternative 7: 97.2% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := 0.91893853320467 + \left(\log x \cdot \left(x - 0.5\right) - x\right)\\ \mathbf{if}\;x \leq 10^{+150}:\\ \;\;\;\;\frac{z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) + 0.083333333333333}{x} + t\_0\\ \mathbf{else}:\\ \;\;\;\;t\_0 + y \cdot \left(z \cdot \frac{z}{x}\right)\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (let* ((t_0 (+ 0.91893853320467 (- (* (log x) (- x 0.5)) x))))
   (if (<= x 1e+150)
     (+
      (/
       (+
        (* z (- (* (+ y 0.0007936500793651) z) 0.0027777777777778))
        0.083333333333333)
       x)
      t_0)
     (+ t_0 (* y (* z (/ z x)))))))
double code(double x, double y, double z) {
	double t_0 = 0.91893853320467 + ((log(x) * (x - 0.5)) - x);
	double tmp;
	if (x <= 1e+150) {
		tmp = (((z * (((y + 0.0007936500793651) * z) - 0.0027777777777778)) + 0.083333333333333) / x) + t_0;
	} else {
		tmp = t_0 + (y * (z * (z / x)));
	}
	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 = 0.91893853320467d0 + ((log(x) * (x - 0.5d0)) - x)
    if (x <= 1d+150) then
        tmp = (((z * (((y + 0.0007936500793651d0) * z) - 0.0027777777777778d0)) + 0.083333333333333d0) / x) + t_0
    else
        tmp = t_0 + (y * (z * (z / x)))
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double t_0 = 0.91893853320467 + ((Math.log(x) * (x - 0.5)) - x);
	double tmp;
	if (x <= 1e+150) {
		tmp = (((z * (((y + 0.0007936500793651) * z) - 0.0027777777777778)) + 0.083333333333333) / x) + t_0;
	} else {
		tmp = t_0 + (y * (z * (z / x)));
	}
	return tmp;
}
def code(x, y, z):
	t_0 = 0.91893853320467 + ((math.log(x) * (x - 0.5)) - x)
	tmp = 0
	if x <= 1e+150:
		tmp = (((z * (((y + 0.0007936500793651) * z) - 0.0027777777777778)) + 0.083333333333333) / x) + t_0
	else:
		tmp = t_0 + (y * (z * (z / x)))
	return tmp
function code(x, y, z)
	t_0 = Float64(0.91893853320467 + Float64(Float64(log(x) * Float64(x - 0.5)) - x))
	tmp = 0.0
	if (x <= 1e+150)
		tmp = Float64(Float64(Float64(Float64(z * Float64(Float64(Float64(y + 0.0007936500793651) * z) - 0.0027777777777778)) + 0.083333333333333) / x) + t_0);
	else
		tmp = Float64(t_0 + Float64(y * Float64(z * Float64(z / x))));
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	t_0 = 0.91893853320467 + ((log(x) * (x - 0.5)) - x);
	tmp = 0.0;
	if (x <= 1e+150)
		tmp = (((z * (((y + 0.0007936500793651) * z) - 0.0027777777777778)) + 0.083333333333333) / x) + t_0;
	else
		tmp = t_0 + (y * (z * (z / x)));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := Block[{t$95$0 = N[(0.91893853320467 + N[(N[(N[Log[x], $MachinePrecision] * N[(x - 0.5), $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, 1e+150], N[(N[(N[(N[(z * N[(N[(N[(y + 0.0007936500793651), $MachinePrecision] * z), $MachinePrecision] - 0.0027777777777778), $MachinePrecision]), $MachinePrecision] + 0.083333333333333), $MachinePrecision] / x), $MachinePrecision] + t$95$0), $MachinePrecision], N[(t$95$0 + N[(y * N[(z * N[(z / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := 0.91893853320467 + \left(\log x \cdot \left(x - 0.5\right) - x\right)\\
\mathbf{if}\;x \leq 10^{+150}:\\
\;\;\;\;\frac{z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) + 0.083333333333333}{x} + t\_0\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if x < 9.99999999999999981e149

    1. Initial program 98.3%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing

    if 9.99999999999999981e149 < x

    1. Initial program 87.7%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Taylor expanded in y around inf 84.1%

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{\frac{y \cdot {z}^{2}}{x}} \]
    4. Step-by-step derivation
      1. associate-/l*87.0%

        \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{y \cdot \frac{{z}^{2}}{x}} \]
    5. Simplified87.0%

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{y \cdot \frac{{z}^{2}}{x}} \]
    6. Step-by-step derivation
      1. unpow287.0%

        \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + y \cdot \frac{\color{blue}{z \cdot z}}{x} \]
      2. associate-/l*96.2%

        \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + y \cdot \color{blue}{\left(z \cdot \frac{z}{x}\right)} \]
    7. Applied egg-rr96.2%

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + y \cdot \color{blue}{\left(z \cdot \frac{z}{x}\right)} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification97.8%

    \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq 10^{+150}:\\ \;\;\;\;\frac{z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) + 0.083333333333333}{x} + \left(0.91893853320467 + \left(\log x \cdot \left(x - 0.5\right) - x\right)\right)\\ \mathbf{else}:\\ \;\;\;\;\left(0.91893853320467 + \left(\log x \cdot \left(x - 0.5\right) - x\right)\right) + y \cdot \left(z \cdot \frac{z}{x}\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 8: 96.1% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;x \leq 1.2 \cdot 10^{+150}:\\ \;\;\;\;\frac{z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) + 0.083333333333333}{x} + x \cdot \left(\log x + -1\right)\\ \mathbf{else}:\\ \;\;\;\;\left(0.91893853320467 + \left(\log x \cdot \left(x - 0.5\right) - x\right)\right) + y \cdot \left(z \cdot \frac{z}{x}\right)\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (if (<= x 1.2e+150)
   (+
    (/
     (+
      (* z (- (* (+ y 0.0007936500793651) z) 0.0027777777777778))
      0.083333333333333)
     x)
    (* x (+ (log x) -1.0)))
   (+ (+ 0.91893853320467 (- (* (log x) (- x 0.5)) x)) (* y (* z (/ z x))))))
double code(double x, double y, double z) {
	double tmp;
	if (x <= 1.2e+150) {
		tmp = (((z * (((y + 0.0007936500793651) * z) - 0.0027777777777778)) + 0.083333333333333) / x) + (x * (log(x) + -1.0));
	} else {
		tmp = (0.91893853320467 + ((log(x) * (x - 0.5)) - x)) + (y * (z * (z / x)));
	}
	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 (x <= 1.2d+150) then
        tmp = (((z * (((y + 0.0007936500793651d0) * z) - 0.0027777777777778d0)) + 0.083333333333333d0) / x) + (x * (log(x) + (-1.0d0)))
    else
        tmp = (0.91893853320467d0 + ((log(x) * (x - 0.5d0)) - x)) + (y * (z * (z / x)))
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double tmp;
	if (x <= 1.2e+150) {
		tmp = (((z * (((y + 0.0007936500793651) * z) - 0.0027777777777778)) + 0.083333333333333) / x) + (x * (Math.log(x) + -1.0));
	} else {
		tmp = (0.91893853320467 + ((Math.log(x) * (x - 0.5)) - x)) + (y * (z * (z / x)));
	}
	return tmp;
}
def code(x, y, z):
	tmp = 0
	if x <= 1.2e+150:
		tmp = (((z * (((y + 0.0007936500793651) * z) - 0.0027777777777778)) + 0.083333333333333) / x) + (x * (math.log(x) + -1.0))
	else:
		tmp = (0.91893853320467 + ((math.log(x) * (x - 0.5)) - x)) + (y * (z * (z / x)))
	return tmp
function code(x, y, z)
	tmp = 0.0
	if (x <= 1.2e+150)
		tmp = Float64(Float64(Float64(Float64(z * Float64(Float64(Float64(y + 0.0007936500793651) * z) - 0.0027777777777778)) + 0.083333333333333) / x) + Float64(x * Float64(log(x) + -1.0)));
	else
		tmp = Float64(Float64(0.91893853320467 + Float64(Float64(log(x) * Float64(x - 0.5)) - x)) + Float64(y * Float64(z * Float64(z / x))));
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	tmp = 0.0;
	if (x <= 1.2e+150)
		tmp = (((z * (((y + 0.0007936500793651) * z) - 0.0027777777777778)) + 0.083333333333333) / x) + (x * (log(x) + -1.0));
	else
		tmp = (0.91893853320467 + ((log(x) * (x - 0.5)) - x)) + (y * (z * (z / x)));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := If[LessEqual[x, 1.2e+150], N[(N[(N[(N[(z * N[(N[(N[(y + 0.0007936500793651), $MachinePrecision] * z), $MachinePrecision] - 0.0027777777777778), $MachinePrecision]), $MachinePrecision] + 0.083333333333333), $MachinePrecision] / x), $MachinePrecision] + N[(x * N[(N[Log[x], $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(0.91893853320467 + N[(N[(N[Log[x], $MachinePrecision] * N[(x - 0.5), $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision]), $MachinePrecision] + N[(y * N[(z * N[(z / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;x \leq 1.2 \cdot 10^{+150}:\\
\;\;\;\;\frac{z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) + 0.083333333333333}{x} + x \cdot \left(\log x + -1\right)\\

\mathbf{else}:\\
\;\;\;\;\left(0.91893853320467 + \left(\log x \cdot \left(x - 0.5\right) - x\right)\right) + y \cdot \left(z \cdot \frac{z}{x}\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if x < 1.20000000000000001e150

    1. Initial program 98.3%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Taylor expanded in x around inf 96.5%

      \[\leadsto \color{blue}{x \cdot \left(-1 \cdot \log \left(\frac{1}{x}\right) - 1\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    4. Step-by-step derivation
      1. sub-neg47.1%

        \[\leadsto x \cdot \color{blue}{\left(-1 \cdot \log \left(\frac{1}{x}\right) + \left(-1\right)\right)} + \frac{0.083333333333333}{x} \]
      2. mul-1-neg47.1%

        \[\leadsto x \cdot \left(\color{blue}{\left(-\log \left(\frac{1}{x}\right)\right)} + \left(-1\right)\right) + \frac{0.083333333333333}{x} \]
      3. log-rec47.1%

        \[\leadsto x \cdot \left(\left(-\color{blue}{\left(-\log x\right)}\right) + \left(-1\right)\right) + \frac{0.083333333333333}{x} \]
      4. remove-double-neg47.1%

        \[\leadsto x \cdot \left(\color{blue}{\log x} + \left(-1\right)\right) + \frac{0.083333333333333}{x} \]
      5. metadata-eval47.1%

        \[\leadsto x \cdot \left(\log x + \color{blue}{-1}\right) + \frac{0.083333333333333}{x} \]
    5. Simplified96.5%

      \[\leadsto \color{blue}{x \cdot \left(\log x + -1\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]

    if 1.20000000000000001e150 < x

    1. Initial program 87.7%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Taylor expanded in y around inf 84.1%

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{\frac{y \cdot {z}^{2}}{x}} \]
    4. Step-by-step derivation
      1. associate-/l*87.0%

        \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{y \cdot \frac{{z}^{2}}{x}} \]
    5. Simplified87.0%

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{y \cdot \frac{{z}^{2}}{x}} \]
    6. Step-by-step derivation
      1. unpow287.0%

        \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + y \cdot \frac{\color{blue}{z \cdot z}}{x} \]
      2. associate-/l*96.2%

        \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + y \cdot \color{blue}{\left(z \cdot \frac{z}{x}\right)} \]
    7. Applied egg-rr96.2%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq 1.2 \cdot 10^{+150}:\\ \;\;\;\;\frac{z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) + 0.083333333333333}{x} + x \cdot \left(\log x + -1\right)\\ \mathbf{else}:\\ \;\;\;\;\left(0.91893853320467 + \left(\log x \cdot \left(x - 0.5\right) - x\right)\right) + y \cdot \left(z \cdot \frac{z}{x}\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 9: 96.1% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;x \leq 10^{+150}:\\ \;\;\;\;\frac{z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) + 0.083333333333333}{x} + \left(x \cdot \log x - x\right)\\ \mathbf{else}:\\ \;\;\;\;\left(0.91893853320467 + \left(\log x \cdot \left(x - 0.5\right) - x\right)\right) + y \cdot \left(z \cdot \frac{z}{x}\right)\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (if (<= x 1e+150)
   (+
    (/
     (+
      (* z (- (* (+ y 0.0007936500793651) z) 0.0027777777777778))
      0.083333333333333)
     x)
    (- (* x (log x)) x))
   (+ (+ 0.91893853320467 (- (* (log x) (- x 0.5)) x)) (* y (* z (/ z x))))))
double code(double x, double y, double z) {
	double tmp;
	if (x <= 1e+150) {
		tmp = (((z * (((y + 0.0007936500793651) * z) - 0.0027777777777778)) + 0.083333333333333) / x) + ((x * log(x)) - x);
	} else {
		tmp = (0.91893853320467 + ((log(x) * (x - 0.5)) - x)) + (y * (z * (z / x)));
	}
	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 (x <= 1d+150) then
        tmp = (((z * (((y + 0.0007936500793651d0) * z) - 0.0027777777777778d0)) + 0.083333333333333d0) / x) + ((x * log(x)) - x)
    else
        tmp = (0.91893853320467d0 + ((log(x) * (x - 0.5d0)) - x)) + (y * (z * (z / x)))
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double tmp;
	if (x <= 1e+150) {
		tmp = (((z * (((y + 0.0007936500793651) * z) - 0.0027777777777778)) + 0.083333333333333) / x) + ((x * Math.log(x)) - x);
	} else {
		tmp = (0.91893853320467 + ((Math.log(x) * (x - 0.5)) - x)) + (y * (z * (z / x)));
	}
	return tmp;
}
def code(x, y, z):
	tmp = 0
	if x <= 1e+150:
		tmp = (((z * (((y + 0.0007936500793651) * z) - 0.0027777777777778)) + 0.083333333333333) / x) + ((x * math.log(x)) - x)
	else:
		tmp = (0.91893853320467 + ((math.log(x) * (x - 0.5)) - x)) + (y * (z * (z / x)))
	return tmp
function code(x, y, z)
	tmp = 0.0
	if (x <= 1e+150)
		tmp = Float64(Float64(Float64(Float64(z * Float64(Float64(Float64(y + 0.0007936500793651) * z) - 0.0027777777777778)) + 0.083333333333333) / x) + Float64(Float64(x * log(x)) - x));
	else
		tmp = Float64(Float64(0.91893853320467 + Float64(Float64(log(x) * Float64(x - 0.5)) - x)) + Float64(y * Float64(z * Float64(z / x))));
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	tmp = 0.0;
	if (x <= 1e+150)
		tmp = (((z * (((y + 0.0007936500793651) * z) - 0.0027777777777778)) + 0.083333333333333) / x) + ((x * log(x)) - x);
	else
		tmp = (0.91893853320467 + ((log(x) * (x - 0.5)) - x)) + (y * (z * (z / x)));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := If[LessEqual[x, 1e+150], N[(N[(N[(N[(z * N[(N[(N[(y + 0.0007936500793651), $MachinePrecision] * z), $MachinePrecision] - 0.0027777777777778), $MachinePrecision]), $MachinePrecision] + 0.083333333333333), $MachinePrecision] / x), $MachinePrecision] + N[(N[(x * N[Log[x], $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision]), $MachinePrecision], N[(N[(0.91893853320467 + N[(N[(N[Log[x], $MachinePrecision] * N[(x - 0.5), $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision]), $MachinePrecision] + N[(y * N[(z * N[(z / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;x \leq 10^{+150}:\\
\;\;\;\;\frac{z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) + 0.083333333333333}{x} + \left(x \cdot \log x - x\right)\\

\mathbf{else}:\\
\;\;\;\;\left(0.91893853320467 + \left(\log x \cdot \left(x - 0.5\right) - x\right)\right) + y \cdot \left(z \cdot \frac{z}{x}\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if x < 9.99999999999999981e149

    1. Initial program 98.3%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Taylor expanded in x around 0 98.3%

      \[\leadsto \color{blue}{\left(0.91893853320467 + \left(-0.5 \cdot \log x + x \cdot \left(\log x - 1\right)\right)\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    4. Step-by-step derivation
      1. sub-neg98.3%

        \[\leadsto \left(0.91893853320467 + \left(-0.5 \cdot \log x + x \cdot \color{blue}{\left(\log x + \left(-1\right)\right)}\right)\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      2. metadata-eval98.3%

        \[\leadsto \left(0.91893853320467 + \left(-0.5 \cdot \log x + x \cdot \left(\log x + \color{blue}{-1}\right)\right)\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      3. distribute-rgt-in98.3%

        \[\leadsto \left(0.91893853320467 + \left(-0.5 \cdot \log x + \color{blue}{\left(\log x \cdot x + -1 \cdot x\right)}\right)\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      4. *-commutative98.3%

        \[\leadsto \left(0.91893853320467 + \left(-0.5 \cdot \log x + \left(\color{blue}{x \cdot \log x} + -1 \cdot x\right)\right)\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      5. neg-mul-198.3%

        \[\leadsto \left(0.91893853320467 + \left(-0.5 \cdot \log x + \left(x \cdot \log x + \color{blue}{\left(-x\right)}\right)\right)\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      6. associate-+l+98.3%

        \[\leadsto \left(0.91893853320467 + \color{blue}{\left(\left(-0.5 \cdot \log x + x \cdot \log x\right) + \left(-x\right)\right)}\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      7. distribute-rgt-out98.3%

        \[\leadsto \left(0.91893853320467 + \left(\color{blue}{\log x \cdot \left(-0.5 + x\right)} + \left(-x\right)\right)\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      8. +-commutative98.3%

        \[\leadsto \left(0.91893853320467 + \left(\log x \cdot \color{blue}{\left(x + -0.5\right)} + \left(-x\right)\right)\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      9. associate-+r+98.3%

        \[\leadsto \color{blue}{\left(\left(0.91893853320467 + \log x \cdot \left(x + -0.5\right)\right) + \left(-x\right)\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      10. sub-neg98.3%

        \[\leadsto \color{blue}{\left(\left(0.91893853320467 + \log x \cdot \left(x + -0.5\right)\right) - x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      11. +-commutative98.3%

        \[\leadsto \left(\color{blue}{\left(\log x \cdot \left(x + -0.5\right) + 0.91893853320467\right)} - x\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      12. fma-define98.3%

        \[\leadsto \left(\color{blue}{\mathsf{fma}\left(\log x, x + -0.5, 0.91893853320467\right)} - x\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    5. Simplified98.3%

      \[\leadsto \color{blue}{\left(\mathsf{fma}\left(\log x, x + -0.5, 0.91893853320467\right) - x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    6. Taylor expanded in x around inf 96.5%

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

        \[\leadsto \left(\color{blue}{\left(-x \cdot \log \left(\frac{1}{x}\right)\right)} - x\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      2. distribute-rgt-neg-in96.5%

        \[\leadsto \left(\color{blue}{x \cdot \left(-\log \left(\frac{1}{x}\right)\right)} - x\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      3. log-rec96.5%

        \[\leadsto \left(x \cdot \left(-\color{blue}{\left(-\log x\right)}\right) - x\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      4. remove-double-neg96.5%

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

      \[\leadsto \left(\color{blue}{x \cdot \log x} - x\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]

    if 9.99999999999999981e149 < x

    1. Initial program 87.7%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Taylor expanded in y around inf 84.1%

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{\frac{y \cdot {z}^{2}}{x}} \]
    4. Step-by-step derivation
      1. associate-/l*87.0%

        \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{y \cdot \frac{{z}^{2}}{x}} \]
    5. Simplified87.0%

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{y \cdot \frac{{z}^{2}}{x}} \]
    6. Step-by-step derivation
      1. unpow287.0%

        \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + y \cdot \frac{\color{blue}{z \cdot z}}{x} \]
      2. associate-/l*96.2%

        \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + y \cdot \color{blue}{\left(z \cdot \frac{z}{x}\right)} \]
    7. Applied egg-rr96.2%

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + y \cdot \color{blue}{\left(z \cdot \frac{z}{x}\right)} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification96.5%

    \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq 10^{+150}:\\ \;\;\;\;\frac{z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) + 0.083333333333333}{x} + \left(x \cdot \log x - x\right)\\ \mathbf{else}:\\ \;\;\;\;\left(0.91893853320467 + \left(\log x \cdot \left(x - 0.5\right) - x\right)\right) + y \cdot \left(z \cdot \frac{z}{x}\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 10: 88.8% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;x \leq 106:\\ \;\;\;\;\frac{z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) + 0.083333333333333}{x} + \left(0.91893853320467 - x\right)\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(\log x + -1\right) + \frac{0.083333333333333 + z \cdot \left(0.0007936500793651 \cdot z - 0.0027777777777778\right)}{x}\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (if (<= x 106.0)
   (+
    (/
     (+
      (* z (- (* (+ y 0.0007936500793651) z) 0.0027777777777778))
      0.083333333333333)
     x)
    (- 0.91893853320467 x))
   (+
    (* x (+ (log x) -1.0))
    (/
     (+
      0.083333333333333
      (* z (- (* 0.0007936500793651 z) 0.0027777777777778)))
     x))))
double code(double x, double y, double z) {
	double tmp;
	if (x <= 106.0) {
		tmp = (((z * (((y + 0.0007936500793651) * z) - 0.0027777777777778)) + 0.083333333333333) / x) + (0.91893853320467 - x);
	} else {
		tmp = (x * (log(x) + -1.0)) + ((0.083333333333333 + (z * ((0.0007936500793651 * z) - 0.0027777777777778))) / x);
	}
	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 (x <= 106.0d0) then
        tmp = (((z * (((y + 0.0007936500793651d0) * z) - 0.0027777777777778d0)) + 0.083333333333333d0) / x) + (0.91893853320467d0 - x)
    else
        tmp = (x * (log(x) + (-1.0d0))) + ((0.083333333333333d0 + (z * ((0.0007936500793651d0 * z) - 0.0027777777777778d0))) / x)
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double tmp;
	if (x <= 106.0) {
		tmp = (((z * (((y + 0.0007936500793651) * z) - 0.0027777777777778)) + 0.083333333333333) / x) + (0.91893853320467 - x);
	} else {
		tmp = (x * (Math.log(x) + -1.0)) + ((0.083333333333333 + (z * ((0.0007936500793651 * z) - 0.0027777777777778))) / x);
	}
	return tmp;
}
def code(x, y, z):
	tmp = 0
	if x <= 106.0:
		tmp = (((z * (((y + 0.0007936500793651) * z) - 0.0027777777777778)) + 0.083333333333333) / x) + (0.91893853320467 - x)
	else:
		tmp = (x * (math.log(x) + -1.0)) + ((0.083333333333333 + (z * ((0.0007936500793651 * z) - 0.0027777777777778))) / x)
	return tmp
function code(x, y, z)
	tmp = 0.0
	if (x <= 106.0)
		tmp = Float64(Float64(Float64(Float64(z * Float64(Float64(Float64(y + 0.0007936500793651) * z) - 0.0027777777777778)) + 0.083333333333333) / x) + Float64(0.91893853320467 - x));
	else
		tmp = Float64(Float64(x * Float64(log(x) + -1.0)) + Float64(Float64(0.083333333333333 + Float64(z * Float64(Float64(0.0007936500793651 * z) - 0.0027777777777778))) / x));
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	tmp = 0.0;
	if (x <= 106.0)
		tmp = (((z * (((y + 0.0007936500793651) * z) - 0.0027777777777778)) + 0.083333333333333) / x) + (0.91893853320467 - x);
	else
		tmp = (x * (log(x) + -1.0)) + ((0.083333333333333 + (z * ((0.0007936500793651 * z) - 0.0027777777777778))) / x);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := If[LessEqual[x, 106.0], N[(N[(N[(N[(z * N[(N[(N[(y + 0.0007936500793651), $MachinePrecision] * z), $MachinePrecision] - 0.0027777777777778), $MachinePrecision]), $MachinePrecision] + 0.083333333333333), $MachinePrecision] / x), $MachinePrecision] + N[(0.91893853320467 - x), $MachinePrecision]), $MachinePrecision], N[(N[(x * N[(N[Log[x], $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision] + N[(N[(0.083333333333333 + N[(z * N[(N[(0.0007936500793651 * z), $MachinePrecision] - 0.0027777777777778), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;x \leq 106:\\
\;\;\;\;\frac{z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) + 0.083333333333333}{x} + \left(0.91893853320467 - x\right)\\

\mathbf{else}:\\
\;\;\;\;x \cdot \left(\log x + -1\right) + \frac{0.083333333333333 + z \cdot \left(0.0007936500793651 \cdot z - 0.0027777777777778\right)}{x}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if x < 106

    1. Initial program 99.7%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. add-cube-cbrt99.7%

        \[\leadsto \left(\left(\color{blue}{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x} \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right) \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      2. pow399.7%

        \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      3. sub-neg99.7%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\left(x + \left(-0.5\right)\right)} \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      4. metadata-eval99.7%

        \[\leadsto \left(\left({\left(\sqrt[3]{\left(x + \color{blue}{-0.5}\right) \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      5. *-commutative99.7%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\log x \cdot \left(x + -0.5\right)}}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    4. Applied egg-rr99.7%

      \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\log x \cdot \left(x + -0.5\right)}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    5. Taylor expanded in x around inf 98.0%

      \[\leadsto \color{blue}{\left(0.91893853320467 + -1 \cdot x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    6. Step-by-step derivation
      1. neg-mul-198.0%

        \[\leadsto \left(0.91893853320467 + \color{blue}{\left(-x\right)}\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      2. sub-neg98.0%

        \[\leadsto \color{blue}{\left(0.91893853320467 - x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    7. Simplified98.0%

      \[\leadsto \color{blue}{\left(0.91893853320467 - x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]

    if 106 < x

    1. Initial program 91.0%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Taylor expanded in x around inf 90.2%

      \[\leadsto \color{blue}{x \cdot \left(-1 \cdot \log \left(\frac{1}{x}\right) - 1\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    4. Step-by-step derivation
      1. sub-neg68.5%

        \[\leadsto x \cdot \color{blue}{\left(-1 \cdot \log \left(\frac{1}{x}\right) + \left(-1\right)\right)} + \frac{0.083333333333333}{x} \]
      2. mul-1-neg68.5%

        \[\leadsto x \cdot \left(\color{blue}{\left(-\log \left(\frac{1}{x}\right)\right)} + \left(-1\right)\right) + \frac{0.083333333333333}{x} \]
      3. log-rec68.5%

        \[\leadsto x \cdot \left(\left(-\color{blue}{\left(-\log x\right)}\right) + \left(-1\right)\right) + \frac{0.083333333333333}{x} \]
      4. remove-double-neg68.5%

        \[\leadsto x \cdot \left(\color{blue}{\log x} + \left(-1\right)\right) + \frac{0.083333333333333}{x} \]
      5. metadata-eval68.5%

        \[\leadsto x \cdot \left(\log x + \color{blue}{-1}\right) + \frac{0.083333333333333}{x} \]
    5. Simplified90.2%

      \[\leadsto \color{blue}{x \cdot \left(\log x + -1\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    6. Taylor expanded in y around 0 79.7%

      \[\leadsto x \cdot \left(\log x + -1\right) + \frac{\left(\color{blue}{0.0007936500793651 \cdot z} - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification89.6%

    \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq 106:\\ \;\;\;\;\frac{z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) + 0.083333333333333}{x} + \left(0.91893853320467 - x\right)\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(\log x + -1\right) + \frac{0.083333333333333 + z \cdot \left(0.0007936500793651 \cdot z - 0.0027777777777778\right)}{x}\\ \end{array} \]
  5. Add Preprocessing

Alternative 11: 94.2% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;x \leq 0.016:\\ \;\;\;\;\frac{z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) + 0.083333333333333}{x} + \left(0.91893853320467 - x\right)\\ \mathbf{else}:\\ \;\;\;\;\left(0.91893853320467 + \left(\log x \cdot \left(x - 0.5\right) - x\right)\right) + y \cdot \left(z \cdot \frac{z}{x}\right)\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (if (<= x 0.016)
   (+
    (/
     (+
      (* z (- (* (+ y 0.0007936500793651) z) 0.0027777777777778))
      0.083333333333333)
     x)
    (- 0.91893853320467 x))
   (+ (+ 0.91893853320467 (- (* (log x) (- x 0.5)) x)) (* y (* z (/ z x))))))
double code(double x, double y, double z) {
	double tmp;
	if (x <= 0.016) {
		tmp = (((z * (((y + 0.0007936500793651) * z) - 0.0027777777777778)) + 0.083333333333333) / x) + (0.91893853320467 - x);
	} else {
		tmp = (0.91893853320467 + ((log(x) * (x - 0.5)) - x)) + (y * (z * (z / x)));
	}
	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 (x <= 0.016d0) then
        tmp = (((z * (((y + 0.0007936500793651d0) * z) - 0.0027777777777778d0)) + 0.083333333333333d0) / x) + (0.91893853320467d0 - x)
    else
        tmp = (0.91893853320467d0 + ((log(x) * (x - 0.5d0)) - x)) + (y * (z * (z / x)))
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double tmp;
	if (x <= 0.016) {
		tmp = (((z * (((y + 0.0007936500793651) * z) - 0.0027777777777778)) + 0.083333333333333) / x) + (0.91893853320467 - x);
	} else {
		tmp = (0.91893853320467 + ((Math.log(x) * (x - 0.5)) - x)) + (y * (z * (z / x)));
	}
	return tmp;
}
def code(x, y, z):
	tmp = 0
	if x <= 0.016:
		tmp = (((z * (((y + 0.0007936500793651) * z) - 0.0027777777777778)) + 0.083333333333333) / x) + (0.91893853320467 - x)
	else:
		tmp = (0.91893853320467 + ((math.log(x) * (x - 0.5)) - x)) + (y * (z * (z / x)))
	return tmp
function code(x, y, z)
	tmp = 0.0
	if (x <= 0.016)
		tmp = Float64(Float64(Float64(Float64(z * Float64(Float64(Float64(y + 0.0007936500793651) * z) - 0.0027777777777778)) + 0.083333333333333) / x) + Float64(0.91893853320467 - x));
	else
		tmp = Float64(Float64(0.91893853320467 + Float64(Float64(log(x) * Float64(x - 0.5)) - x)) + Float64(y * Float64(z * Float64(z / x))));
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	tmp = 0.0;
	if (x <= 0.016)
		tmp = (((z * (((y + 0.0007936500793651) * z) - 0.0027777777777778)) + 0.083333333333333) / x) + (0.91893853320467 - x);
	else
		tmp = (0.91893853320467 + ((log(x) * (x - 0.5)) - x)) + (y * (z * (z / x)));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := If[LessEqual[x, 0.016], N[(N[(N[(N[(z * N[(N[(N[(y + 0.0007936500793651), $MachinePrecision] * z), $MachinePrecision] - 0.0027777777777778), $MachinePrecision]), $MachinePrecision] + 0.083333333333333), $MachinePrecision] / x), $MachinePrecision] + N[(0.91893853320467 - x), $MachinePrecision]), $MachinePrecision], N[(N[(0.91893853320467 + N[(N[(N[Log[x], $MachinePrecision] * N[(x - 0.5), $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision]), $MachinePrecision] + N[(y * N[(z * N[(z / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;x \leq 0.016:\\
\;\;\;\;\frac{z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) + 0.083333333333333}{x} + \left(0.91893853320467 - x\right)\\

\mathbf{else}:\\
\;\;\;\;\left(0.91893853320467 + \left(\log x \cdot \left(x - 0.5\right) - x\right)\right) + y \cdot \left(z \cdot \frac{z}{x}\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if x < 0.016

    1. Initial program 99.7%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. add-cube-cbrt99.7%

        \[\leadsto \left(\left(\color{blue}{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x} \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right) \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      2. pow399.7%

        \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      3. sub-neg99.7%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\left(x + \left(-0.5\right)\right)} \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      4. metadata-eval99.7%

        \[\leadsto \left(\left({\left(\sqrt[3]{\left(x + \color{blue}{-0.5}\right) \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      5. *-commutative99.7%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\log x \cdot \left(x + -0.5\right)}}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    4. Applied egg-rr99.7%

      \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\log x \cdot \left(x + -0.5\right)}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    5. Taylor expanded in x around inf 98.6%

      \[\leadsto \color{blue}{\left(0.91893853320467 + -1 \cdot x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    6. Step-by-step derivation
      1. neg-mul-198.6%

        \[\leadsto \left(0.91893853320467 + \color{blue}{\left(-x\right)}\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      2. sub-neg98.6%

        \[\leadsto \color{blue}{\left(0.91893853320467 - x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    7. Simplified98.6%

      \[\leadsto \color{blue}{\left(0.91893853320467 - x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]

    if 0.016 < x

    1. Initial program 91.2%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Taylor expanded in y around inf 80.6%

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{\frac{y \cdot {z}^{2}}{x}} \]
    4. Step-by-step derivation
      1. associate-/l*82.8%

        \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{y \cdot \frac{{z}^{2}}{x}} \]
    5. Simplified82.8%

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{y \cdot \frac{{z}^{2}}{x}} \]
    6. Step-by-step derivation
      1. unpow282.8%

        \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + y \cdot \frac{\color{blue}{z \cdot z}}{x} \]
      2. associate-/l*87.7%

        \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + y \cdot \color{blue}{\left(z \cdot \frac{z}{x}\right)} \]
    7. Applied egg-rr87.7%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq 0.016:\\ \;\;\;\;\frac{z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) + 0.083333333333333}{x} + \left(0.91893853320467 - x\right)\\ \mathbf{else}:\\ \;\;\;\;\left(0.91893853320467 + \left(\log x \cdot \left(x - 0.5\right) - x\right)\right) + y \cdot \left(z \cdot \frac{z}{x}\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 12: 48.2% accurate, 5.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -380000000000 \lor \neg \left(z \leq 8 \cdot 10^{+14}\right):\\ \;\;\;\;\frac{0.083333333333333 + z \cdot \left(0.0007936500793651 \cdot z - 0.0027777777777778\right)}{x} - x\\ \mathbf{else}:\\ \;\;\;\;x + \frac{0.083333333333333}{x}\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (if (or (<= z -380000000000.0) (not (<= z 8e+14)))
   (-
    (/
     (+
      0.083333333333333
      (* z (- (* 0.0007936500793651 z) 0.0027777777777778)))
     x)
    x)
   (+ x (/ 0.083333333333333 x))))
double code(double x, double y, double z) {
	double tmp;
	if ((z <= -380000000000.0) || !(z <= 8e+14)) {
		tmp = ((0.083333333333333 + (z * ((0.0007936500793651 * z) - 0.0027777777777778))) / x) - x;
	} else {
		tmp = x + (0.083333333333333 / x);
	}
	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 <= (-380000000000.0d0)) .or. (.not. (z <= 8d+14))) then
        tmp = ((0.083333333333333d0 + (z * ((0.0007936500793651d0 * z) - 0.0027777777777778d0))) / x) - x
    else
        tmp = x + (0.083333333333333d0 / x)
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double tmp;
	if ((z <= -380000000000.0) || !(z <= 8e+14)) {
		tmp = ((0.083333333333333 + (z * ((0.0007936500793651 * z) - 0.0027777777777778))) / x) - x;
	} else {
		tmp = x + (0.083333333333333 / x);
	}
	return tmp;
}
def code(x, y, z):
	tmp = 0
	if (z <= -380000000000.0) or not (z <= 8e+14):
		tmp = ((0.083333333333333 + (z * ((0.0007936500793651 * z) - 0.0027777777777778))) / x) - x
	else:
		tmp = x + (0.083333333333333 / x)
	return tmp
function code(x, y, z)
	tmp = 0.0
	if ((z <= -380000000000.0) || !(z <= 8e+14))
		tmp = Float64(Float64(Float64(0.083333333333333 + Float64(z * Float64(Float64(0.0007936500793651 * z) - 0.0027777777777778))) / x) - x);
	else
		tmp = Float64(x + Float64(0.083333333333333 / x));
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	tmp = 0.0;
	if ((z <= -380000000000.0) || ~((z <= 8e+14)))
		tmp = ((0.083333333333333 + (z * ((0.0007936500793651 * z) - 0.0027777777777778))) / x) - x;
	else
		tmp = x + (0.083333333333333 / x);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := If[Or[LessEqual[z, -380000000000.0], N[Not[LessEqual[z, 8e+14]], $MachinePrecision]], N[(N[(N[(0.083333333333333 + N[(z * N[(N[(0.0007936500793651 * z), $MachinePrecision] - 0.0027777777777778), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / x), $MachinePrecision] - x), $MachinePrecision], N[(x + N[(0.083333333333333 / x), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -380000000000 \lor \neg \left(z \leq 8 \cdot 10^{+14}\right):\\
\;\;\;\;\frac{0.083333333333333 + z \cdot \left(0.0007936500793651 \cdot z - 0.0027777777777778\right)}{x} - x\\

\mathbf{else}:\\
\;\;\;\;x + \frac{0.083333333333333}{x}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -3.8e11 or 8e14 < z

    1. Initial program 91.2%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. add-cube-cbrt91.2%

        \[\leadsto \left(\left(\color{blue}{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x} \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right) \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      2. pow391.2%

        \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      3. sub-neg91.2%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\left(x + \left(-0.5\right)\right)} \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      4. metadata-eval91.2%

        \[\leadsto \left(\left({\left(\sqrt[3]{\left(x + \color{blue}{-0.5}\right) \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      5. *-commutative91.2%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\log x \cdot \left(x + -0.5\right)}}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    4. Applied egg-rr91.2%

      \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\log x \cdot \left(x + -0.5\right)}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    5. Taylor expanded in x around inf 79.2%

      \[\leadsto \color{blue}{-1 \cdot x} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    6. Step-by-step derivation
      1. neg-mul-179.2%

        \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    7. Simplified79.2%

      \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    8. Taylor expanded in y around 0 58.2%

      \[\leadsto \left(-x\right) + \frac{\left(\color{blue}{0.0007936500793651 \cdot z} - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]

    if -3.8e11 < z < 8e14

    1. Initial program 99.5%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. add-cube-cbrt98.9%

        \[\leadsto \left(\left(\color{blue}{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x} \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right) \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      2. pow398.9%

        \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      3. sub-neg98.9%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\left(x + \left(-0.5\right)\right)} \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      4. metadata-eval98.9%

        \[\leadsto \left(\left({\left(\sqrt[3]{\left(x + \color{blue}{-0.5}\right) \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      5. *-commutative98.9%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\log x \cdot \left(x + -0.5\right)}}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    4. Applied egg-rr98.9%

      \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\log x \cdot \left(x + -0.5\right)}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    5. Taylor expanded in x around inf 52.7%

      \[\leadsto \color{blue}{-1 \cdot x} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    6. Step-by-step derivation
      1. neg-mul-152.7%

        \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    7. Simplified52.7%

      \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    8. Taylor expanded in z around 0 43.1%

      \[\leadsto \left(-x\right) + \frac{\color{blue}{0.083333333333333}}{x} \]
    9. Step-by-step derivation
      1. *-un-lft-identity43.1%

        \[\leadsto \color{blue}{1 \cdot \left(\left(-x\right) + \frac{0.083333333333333}{x}\right)} \]
      2. *-un-lft-identity43.1%

        \[\leadsto \color{blue}{1 \cdot \left(1 \cdot \left(\left(-x\right) + \frac{0.083333333333333}{x}\right)\right)} \]
      3. *-un-lft-identity43.1%

        \[\leadsto 1 \cdot \color{blue}{\left(\left(-x\right) + \frac{0.083333333333333}{x}\right)} \]
      4. add-sqr-sqrt0.0%

        \[\leadsto 1 \cdot \left(\color{blue}{\sqrt{-x} \cdot \sqrt{-x}} + \frac{0.083333333333333}{x}\right) \]
      5. sqrt-unprod48.1%

        \[\leadsto 1 \cdot \left(\color{blue}{\sqrt{\left(-x\right) \cdot \left(-x\right)}} + \frac{0.083333333333333}{x}\right) \]
      6. sqr-neg48.1%

        \[\leadsto 1 \cdot \left(\sqrt{\color{blue}{x \cdot x}} + \frac{0.083333333333333}{x}\right) \]
      7. sqrt-unprod49.2%

        \[\leadsto 1 \cdot \left(\color{blue}{\sqrt{x} \cdot \sqrt{x}} + \frac{0.083333333333333}{x}\right) \]
      8. add-sqr-sqrt49.2%

        \[\leadsto 1 \cdot \left(\color{blue}{x} + \frac{0.083333333333333}{x}\right) \]
    10. Applied egg-rr49.2%

      \[\leadsto \color{blue}{1 \cdot \left(x + \frac{0.083333333333333}{x}\right)} \]
    11. Step-by-step derivation
      1. *-lft-identity49.2%

        \[\leadsto \color{blue}{x + \frac{0.083333333333333}{x}} \]
    12. Simplified49.2%

      \[\leadsto \color{blue}{x + \frac{0.083333333333333}{x}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification53.3%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -380000000000 \lor \neg \left(z \leq 8 \cdot 10^{+14}\right):\\ \;\;\;\;\frac{0.083333333333333 + z \cdot \left(0.0007936500793651 \cdot z - 0.0027777777777778\right)}{x} - x\\ \mathbf{else}:\\ \;\;\;\;x + \frac{0.083333333333333}{x}\\ \end{array} \]
  5. Add Preprocessing

Alternative 13: 61.2% accurate, 5.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -0.0008 \lor \neg \left(y \leq 2 \cdot 10^{-27}\right):\\ \;\;\;\;\frac{0.083333333333333 + z \cdot \left(y \cdot z - 0.0027777777777778\right)}{x} - x\\ \mathbf{else}:\\ \;\;\;\;\frac{0.083333333333333 + z \cdot \left(0.0007936500793651 \cdot z - 0.0027777777777778\right)}{x} - x\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (if (or (<= y -0.0008) (not (<= y 2e-27)))
   (- (/ (+ 0.083333333333333 (* z (- (* y z) 0.0027777777777778))) x) x)
   (-
    (/
     (+
      0.083333333333333
      (* z (- (* 0.0007936500793651 z) 0.0027777777777778)))
     x)
    x)))
double code(double x, double y, double z) {
	double tmp;
	if ((y <= -0.0008) || !(y <= 2e-27)) {
		tmp = ((0.083333333333333 + (z * ((y * z) - 0.0027777777777778))) / x) - x;
	} else {
		tmp = ((0.083333333333333 + (z * ((0.0007936500793651 * z) - 0.0027777777777778))) / x) - x;
	}
	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 ((y <= (-0.0008d0)) .or. (.not. (y <= 2d-27))) then
        tmp = ((0.083333333333333d0 + (z * ((y * z) - 0.0027777777777778d0))) / x) - x
    else
        tmp = ((0.083333333333333d0 + (z * ((0.0007936500793651d0 * z) - 0.0027777777777778d0))) / x) - x
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double tmp;
	if ((y <= -0.0008) || !(y <= 2e-27)) {
		tmp = ((0.083333333333333 + (z * ((y * z) - 0.0027777777777778))) / x) - x;
	} else {
		tmp = ((0.083333333333333 + (z * ((0.0007936500793651 * z) - 0.0027777777777778))) / x) - x;
	}
	return tmp;
}
def code(x, y, z):
	tmp = 0
	if (y <= -0.0008) or not (y <= 2e-27):
		tmp = ((0.083333333333333 + (z * ((y * z) - 0.0027777777777778))) / x) - x
	else:
		tmp = ((0.083333333333333 + (z * ((0.0007936500793651 * z) - 0.0027777777777778))) / x) - x
	return tmp
function code(x, y, z)
	tmp = 0.0
	if ((y <= -0.0008) || !(y <= 2e-27))
		tmp = Float64(Float64(Float64(0.083333333333333 + Float64(z * Float64(Float64(y * z) - 0.0027777777777778))) / x) - x);
	else
		tmp = Float64(Float64(Float64(0.083333333333333 + Float64(z * Float64(Float64(0.0007936500793651 * z) - 0.0027777777777778))) / x) - x);
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	tmp = 0.0;
	if ((y <= -0.0008) || ~((y <= 2e-27)))
		tmp = ((0.083333333333333 + (z * ((y * z) - 0.0027777777777778))) / x) - x;
	else
		tmp = ((0.083333333333333 + (z * ((0.0007936500793651 * z) - 0.0027777777777778))) / x) - x;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := If[Or[LessEqual[y, -0.0008], N[Not[LessEqual[y, 2e-27]], $MachinePrecision]], N[(N[(N[(0.083333333333333 + N[(z * N[(N[(y * z), $MachinePrecision] - 0.0027777777777778), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / x), $MachinePrecision] - x), $MachinePrecision], N[(N[(N[(0.083333333333333 + N[(z * N[(N[(0.0007936500793651 * z), $MachinePrecision] - 0.0027777777777778), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / x), $MachinePrecision] - x), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -0.0008 \lor \neg \left(y \leq 2 \cdot 10^{-27}\right):\\
\;\;\;\;\frac{0.083333333333333 + z \cdot \left(y \cdot z - 0.0027777777777778\right)}{x} - x\\

\mathbf{else}:\\
\;\;\;\;\frac{0.083333333333333 + z \cdot \left(0.0007936500793651 \cdot z - 0.0027777777777778\right)}{x} - x\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y < -8.00000000000000038e-4 or 2.0000000000000001e-27 < y

    1. Initial program 95.9%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. add-cube-cbrt95.6%

        \[\leadsto \left(\left(\color{blue}{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x} \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right) \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      2. pow395.6%

        \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      3. sub-neg95.6%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\left(x + \left(-0.5\right)\right)} \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      4. metadata-eval95.6%

        \[\leadsto \left(\left({\left(\sqrt[3]{\left(x + \color{blue}{-0.5}\right) \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      5. *-commutative95.6%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\log x \cdot \left(x + -0.5\right)}}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    4. Applied egg-rr95.6%

      \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\log x \cdot \left(x + -0.5\right)}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    5. Taylor expanded in x around inf 69.0%

      \[\leadsto \color{blue}{-1 \cdot x} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    6. Step-by-step derivation
      1. neg-mul-169.0%

        \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    7. Simplified69.0%

      \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    8. Taylor expanded in y around inf 69.0%

      \[\leadsto \left(-x\right) + \frac{\left(\color{blue}{y \cdot z} - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    9. Step-by-step derivation
      1. *-commutative69.0%

        \[\leadsto \left(-x\right) + \frac{\left(\color{blue}{z \cdot y} - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    10. Simplified69.0%

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

    if -8.00000000000000038e-4 < y < 2.0000000000000001e-27

    1. Initial program 95.5%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. add-cube-cbrt95.2%

        \[\leadsto \left(\left(\color{blue}{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x} \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right) \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      2. pow395.1%

        \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      3. sub-neg95.1%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\left(x + \left(-0.5\right)\right)} \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      4. metadata-eval95.1%

        \[\leadsto \left(\left({\left(\sqrt[3]{\left(x + \color{blue}{-0.5}\right) \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      5. *-commutative95.1%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\log x \cdot \left(x + -0.5\right)}}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    4. Applied egg-rr95.1%

      \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\log x \cdot \left(x + -0.5\right)}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    5. Taylor expanded in x around inf 61.1%

      \[\leadsto \color{blue}{-1 \cdot x} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    6. Step-by-step derivation
      1. neg-mul-161.1%

        \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    7. Simplified61.1%

      \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    8. Taylor expanded in y around 0 61.1%

      \[\leadsto \left(-x\right) + \frac{\left(\color{blue}{0.0007936500793651 \cdot z} - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification64.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;y \leq -0.0008 \lor \neg \left(y \leq 2 \cdot 10^{-27}\right):\\ \;\;\;\;\frac{0.083333333333333 + z \cdot \left(y \cdot z - 0.0027777777777778\right)}{x} - x\\ \mathbf{else}:\\ \;\;\;\;\frac{0.083333333333333 + z \cdot \left(0.0007936500793651 \cdot z - 0.0027777777777778\right)}{x} - x\\ \end{array} \]
  5. Add Preprocessing

Alternative 14: 33.0% accurate, 6.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;x \leq 3.8 \cdot 10^{-17}:\\ \;\;\;\;\left(\frac{z}{x} \cdot -0.0027777777777778 + 0.083333333333333 \cdot \frac{1}{x}\right) - x\\ \mathbf{else}:\\ \;\;\;\;x + \frac{0.083333333333333}{x}\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (if (<= x 3.8e-17)
   (- (+ (* (/ z x) -0.0027777777777778) (* 0.083333333333333 (/ 1.0 x))) x)
   (+ x (/ 0.083333333333333 x))))
double code(double x, double y, double z) {
	double tmp;
	if (x <= 3.8e-17) {
		tmp = (((z / x) * -0.0027777777777778) + (0.083333333333333 * (1.0 / x))) - x;
	} else {
		tmp = x + (0.083333333333333 / x);
	}
	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 (x <= 3.8d-17) then
        tmp = (((z / x) * (-0.0027777777777778d0)) + (0.083333333333333d0 * (1.0d0 / x))) - x
    else
        tmp = x + (0.083333333333333d0 / x)
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double tmp;
	if (x <= 3.8e-17) {
		tmp = (((z / x) * -0.0027777777777778) + (0.083333333333333 * (1.0 / x))) - x;
	} else {
		tmp = x + (0.083333333333333 / x);
	}
	return tmp;
}
def code(x, y, z):
	tmp = 0
	if x <= 3.8e-17:
		tmp = (((z / x) * -0.0027777777777778) + (0.083333333333333 * (1.0 / x))) - x
	else:
		tmp = x + (0.083333333333333 / x)
	return tmp
function code(x, y, z)
	tmp = 0.0
	if (x <= 3.8e-17)
		tmp = Float64(Float64(Float64(Float64(z / x) * -0.0027777777777778) + Float64(0.083333333333333 * Float64(1.0 / x))) - x);
	else
		tmp = Float64(x + Float64(0.083333333333333 / x));
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	tmp = 0.0;
	if (x <= 3.8e-17)
		tmp = (((z / x) * -0.0027777777777778) + (0.083333333333333 * (1.0 / x))) - x;
	else
		tmp = x + (0.083333333333333 / x);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := If[LessEqual[x, 3.8e-17], N[(N[(N[(N[(z / x), $MachinePrecision] * -0.0027777777777778), $MachinePrecision] + N[(0.083333333333333 * N[(1.0 / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision], N[(x + N[(0.083333333333333 / x), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;x \leq 3.8 \cdot 10^{-17}:\\
\;\;\;\;\left(\frac{z}{x} \cdot -0.0027777777777778 + 0.083333333333333 \cdot \frac{1}{x}\right) - x\\

\mathbf{else}:\\
\;\;\;\;x + \frac{0.083333333333333}{x}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if x < 3.8000000000000001e-17

    1. Initial program 99.7%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. add-cube-cbrt99.7%

        \[\leadsto \left(\left(\color{blue}{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x} \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right) \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      2. pow399.7%

        \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      3. sub-neg99.7%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\left(x + \left(-0.5\right)\right)} \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      4. metadata-eval99.7%

        \[\leadsto \left(\left({\left(\sqrt[3]{\left(x + \color{blue}{-0.5}\right) \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      5. *-commutative99.7%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\log x \cdot \left(x + -0.5\right)}}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    4. Applied egg-rr99.7%

      \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\log x \cdot \left(x + -0.5\right)}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    5. Taylor expanded in x around inf 99.7%

      \[\leadsto \color{blue}{-1 \cdot x} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    6. Step-by-step derivation
      1. neg-mul-199.7%

        \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    7. Simplified99.7%

      \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    8. Taylor expanded in z around 0 58.6%

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

    if 3.8000000000000001e-17 < x

    1. Initial program 91.6%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. add-cube-cbrt90.9%

        \[\leadsto \left(\left(\color{blue}{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x} \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right) \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      2. pow390.9%

        \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      3. sub-neg90.9%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\left(x + \left(-0.5\right)\right)} \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      4. metadata-eval90.9%

        \[\leadsto \left(\left({\left(\sqrt[3]{\left(x + \color{blue}{-0.5}\right) \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      5. *-commutative90.9%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\log x \cdot \left(x + -0.5\right)}}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    4. Applied egg-rr90.9%

      \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\log x \cdot \left(x + -0.5\right)}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    5. Taylor expanded in x around inf 29.5%

      \[\leadsto \color{blue}{-1 \cdot x} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    6. Step-by-step derivation
      1. neg-mul-129.5%

        \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    7. Simplified29.5%

      \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    8. Taylor expanded in z around 0 2.4%

      \[\leadsto \left(-x\right) + \frac{\color{blue}{0.083333333333333}}{x} \]
    9. Step-by-step derivation
      1. *-un-lft-identity2.4%

        \[\leadsto \color{blue}{1 \cdot \left(\left(-x\right) + \frac{0.083333333333333}{x}\right)} \]
      2. *-un-lft-identity2.4%

        \[\leadsto \color{blue}{1 \cdot \left(1 \cdot \left(\left(-x\right) + \frac{0.083333333333333}{x}\right)\right)} \]
      3. *-un-lft-identity2.4%

        \[\leadsto 1 \cdot \color{blue}{\left(\left(-x\right) + \frac{0.083333333333333}{x}\right)} \]
      4. add-sqr-sqrt0.0%

        \[\leadsto 1 \cdot \left(\color{blue}{\sqrt{-x} \cdot \sqrt{-x}} + \frac{0.083333333333333}{x}\right) \]
      5. sqrt-unprod13.3%

        \[\leadsto 1 \cdot \left(\color{blue}{\sqrt{\left(-x\right) \cdot \left(-x\right)}} + \frac{0.083333333333333}{x}\right) \]
      6. sqr-neg13.3%

        \[\leadsto 1 \cdot \left(\sqrt{\color{blue}{x \cdot x}} + \frac{0.083333333333333}{x}\right) \]
      7. sqrt-unprod11.6%

        \[\leadsto 1 \cdot \left(\color{blue}{\sqrt{x} \cdot \sqrt{x}} + \frac{0.083333333333333}{x}\right) \]
      8. add-sqr-sqrt11.6%

        \[\leadsto 1 \cdot \left(\color{blue}{x} + \frac{0.083333333333333}{x}\right) \]
    10. Applied egg-rr11.6%

      \[\leadsto \color{blue}{1 \cdot \left(x + \frac{0.083333333333333}{x}\right)} \]
    11. Step-by-step derivation
      1. *-lft-identity11.6%

        \[\leadsto \color{blue}{x + \frac{0.083333333333333}{x}} \]
    12. Simplified11.6%

      \[\leadsto \color{blue}{x + \frac{0.083333333333333}{x}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification35.3%

    \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq 3.8 \cdot 10^{-17}:\\ \;\;\;\;\left(\frac{z}{x} \cdot -0.0027777777777778 + 0.083333333333333 \cdot \frac{1}{x}\right) - x\\ \mathbf{else}:\\ \;\;\;\;x + \frac{0.083333333333333}{x}\\ \end{array} \]
  5. Add Preprocessing

Alternative 15: 61.5% accurate, 7.2× speedup?

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

\\
\frac{z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) + 0.083333333333333}{x} + \left(0.91893853320467 - x\right)
\end{array}
Derivation
  1. Initial program 95.7%

    \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  2. Add Preprocessing
  3. Step-by-step derivation
    1. add-cube-cbrt95.4%

      \[\leadsto \left(\left(\color{blue}{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x} \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right) \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. pow395.4%

      \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    3. sub-neg95.4%

      \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\left(x + \left(-0.5\right)\right)} \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    4. metadata-eval95.4%

      \[\leadsto \left(\left({\left(\sqrt[3]{\left(x + \color{blue}{-0.5}\right) \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    5. *-commutative95.4%

      \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\log x \cdot \left(x + -0.5\right)}}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  4. Applied egg-rr95.4%

    \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\log x \cdot \left(x + -0.5\right)}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  5. Taylor expanded in x around inf 64.9%

    \[\leadsto \color{blue}{\left(0.91893853320467 + -1 \cdot x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  6. Step-by-step derivation
    1. neg-mul-164.9%

      \[\leadsto \left(0.91893853320467 + \color{blue}{\left(-x\right)}\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. sub-neg64.9%

      \[\leadsto \color{blue}{\left(0.91893853320467 - x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  7. Simplified64.9%

    \[\leadsto \color{blue}{\left(0.91893853320467 - x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  8. Final simplification64.9%

    \[\leadsto \frac{z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) + 0.083333333333333}{x} + \left(0.91893853320467 - x\right) \]
  9. Add Preprocessing

Alternative 16: 61.5% accurate, 8.2× speedup?

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

\\
\frac{z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) + 0.083333333333333}{x} - x
\end{array}
Derivation
  1. Initial program 95.7%

    \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  2. Add Preprocessing
  3. Step-by-step derivation
    1. add-cube-cbrt95.4%

      \[\leadsto \left(\left(\color{blue}{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x} \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right) \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. pow395.4%

      \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    3. sub-neg95.4%

      \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\left(x + \left(-0.5\right)\right)} \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    4. metadata-eval95.4%

      \[\leadsto \left(\left({\left(\sqrt[3]{\left(x + \color{blue}{-0.5}\right) \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    5. *-commutative95.4%

      \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\log x \cdot \left(x + -0.5\right)}}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  4. Applied egg-rr95.4%

    \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\log x \cdot \left(x + -0.5\right)}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  5. Taylor expanded in x around inf 64.9%

    \[\leadsto \color{blue}{-1 \cdot x} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  6. Step-by-step derivation
    1. neg-mul-164.9%

      \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  7. Simplified64.9%

    \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  8. Final simplification64.9%

    \[\leadsto \frac{z \cdot \left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) + 0.083333333333333}{x} - x \]
  9. Add Preprocessing

Alternative 17: 30.6% accurate, 8.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -8 \cdot 10^{+137}:\\ \;\;\;\;\frac{0.083333333333333 + z \cdot -0.0027777777777778}{x} - x\\ \mathbf{else}:\\ \;\;\;\;x + \frac{0.083333333333333}{x}\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (if (<= z -8e+137)
   (- (/ (+ 0.083333333333333 (* z -0.0027777777777778)) x) x)
   (+ x (/ 0.083333333333333 x))))
double code(double x, double y, double z) {
	double tmp;
	if (z <= -8e+137) {
		tmp = ((0.083333333333333 + (z * -0.0027777777777778)) / x) - x;
	} else {
		tmp = x + (0.083333333333333 / x);
	}
	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 <= (-8d+137)) then
        tmp = ((0.083333333333333d0 + (z * (-0.0027777777777778d0))) / x) - x
    else
        tmp = x + (0.083333333333333d0 / x)
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double tmp;
	if (z <= -8e+137) {
		tmp = ((0.083333333333333 + (z * -0.0027777777777778)) / x) - x;
	} else {
		tmp = x + (0.083333333333333 / x);
	}
	return tmp;
}
def code(x, y, z):
	tmp = 0
	if z <= -8e+137:
		tmp = ((0.083333333333333 + (z * -0.0027777777777778)) / x) - x
	else:
		tmp = x + (0.083333333333333 / x)
	return tmp
function code(x, y, z)
	tmp = 0.0
	if (z <= -8e+137)
		tmp = Float64(Float64(Float64(0.083333333333333 + Float64(z * -0.0027777777777778)) / x) - x);
	else
		tmp = Float64(x + Float64(0.083333333333333 / x));
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	tmp = 0.0;
	if (z <= -8e+137)
		tmp = ((0.083333333333333 + (z * -0.0027777777777778)) / x) - x;
	else
		tmp = x + (0.083333333333333 / x);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := If[LessEqual[z, -8e+137], N[(N[(N[(0.083333333333333 + N[(z * -0.0027777777777778), $MachinePrecision]), $MachinePrecision] / x), $MachinePrecision] - x), $MachinePrecision], N[(x + N[(0.083333333333333 / x), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -8 \cdot 10^{+137}:\\
\;\;\;\;\frac{0.083333333333333 + z \cdot -0.0027777777777778}{x} - x\\

\mathbf{else}:\\
\;\;\;\;x + \frac{0.083333333333333}{x}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -8.0000000000000003e137

    1. Initial program 94.0%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. add-cube-cbrt94.0%

        \[\leadsto \left(\left(\color{blue}{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x} \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right) \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      2. pow394.0%

        \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      3. sub-neg94.0%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\left(x + \left(-0.5\right)\right)} \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      4. metadata-eval94.0%

        \[\leadsto \left(\left({\left(\sqrt[3]{\left(x + \color{blue}{-0.5}\right) \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      5. *-commutative94.0%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\log x \cdot \left(x + -0.5\right)}}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    4. Applied egg-rr94.0%

      \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\log x \cdot \left(x + -0.5\right)}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    5. Taylor expanded in x around inf 94.0%

      \[\leadsto \color{blue}{-1 \cdot x} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    6. Step-by-step derivation
      1. neg-mul-194.0%

        \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    7. Simplified94.0%

      \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    8. Taylor expanded in z around 0 51.3%

      \[\leadsto \left(-x\right) + \frac{\color{blue}{-0.0027777777777778 \cdot z} + 0.083333333333333}{x} \]
    9. Step-by-step derivation
      1. *-commutative51.3%

        \[\leadsto \left(-x\right) + \frac{\color{blue}{z \cdot -0.0027777777777778} + 0.083333333333333}{x} \]
    10. Simplified51.3%

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

    if -8.0000000000000003e137 < z

    1. Initial program 95.9%

      \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. add-cube-cbrt95.6%

        \[\leadsto \left(\left(\color{blue}{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x} \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right) \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      2. pow395.6%

        \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      3. sub-neg95.6%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\left(x + \left(-0.5\right)\right)} \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      4. metadata-eval95.6%

        \[\leadsto \left(\left({\left(\sqrt[3]{\left(x + \color{blue}{-0.5}\right) \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      5. *-commutative95.6%

        \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\log x \cdot \left(x + -0.5\right)}}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    4. Applied egg-rr95.6%

      \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\log x \cdot \left(x + -0.5\right)}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    5. Taylor expanded in x around inf 60.9%

      \[\leadsto \color{blue}{-1 \cdot x} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    6. Step-by-step derivation
      1. neg-mul-160.9%

        \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    7. Simplified60.9%

      \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    8. Taylor expanded in z around 0 27.5%

      \[\leadsto \left(-x\right) + \frac{\color{blue}{0.083333333333333}}{x} \]
    9. Step-by-step derivation
      1. *-un-lft-identity27.5%

        \[\leadsto \color{blue}{1 \cdot \left(\left(-x\right) + \frac{0.083333333333333}{x}\right)} \]
      2. *-un-lft-identity27.5%

        \[\leadsto \color{blue}{1 \cdot \left(1 \cdot \left(\left(-x\right) + \frac{0.083333333333333}{x}\right)\right)} \]
      3. *-un-lft-identity27.5%

        \[\leadsto 1 \cdot \color{blue}{\left(\left(-x\right) + \frac{0.083333333333333}{x}\right)} \]
      4. add-sqr-sqrt0.0%

        \[\leadsto 1 \cdot \left(\color{blue}{\sqrt{-x} \cdot \sqrt{-x}} + \frac{0.083333333333333}{x}\right) \]
      5. sqrt-unprod33.2%

        \[\leadsto 1 \cdot \left(\color{blue}{\sqrt{\left(-x\right) \cdot \left(-x\right)}} + \frac{0.083333333333333}{x}\right) \]
      6. sqr-neg33.2%

        \[\leadsto 1 \cdot \left(\sqrt{\color{blue}{x \cdot x}} + \frac{0.083333333333333}{x}\right) \]
      7. sqrt-unprod32.6%

        \[\leadsto 1 \cdot \left(\color{blue}{\sqrt{x} \cdot \sqrt{x}} + \frac{0.083333333333333}{x}\right) \]
      8. add-sqr-sqrt32.6%

        \[\leadsto 1 \cdot \left(\color{blue}{x} + \frac{0.083333333333333}{x}\right) \]
    10. Applied egg-rr32.6%

      \[\leadsto \color{blue}{1 \cdot \left(x + \frac{0.083333333333333}{x}\right)} \]
    11. Step-by-step derivation
      1. *-lft-identity32.6%

        \[\leadsto \color{blue}{x + \frac{0.083333333333333}{x}} \]
    12. Simplified32.6%

      \[\leadsto \color{blue}{x + \frac{0.083333333333333}{x}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification34.8%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -8 \cdot 10^{+137}:\\ \;\;\;\;\frac{0.083333333333333 + z \cdot -0.0027777777777778}{x} - x\\ \mathbf{else}:\\ \;\;\;\;x + \frac{0.083333333333333}{x}\\ \end{array} \]
  5. Add Preprocessing

Alternative 18: 27.5% accurate, 24.6× speedup?

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

\\
x + \frac{0.083333333333333}{x}
\end{array}
Derivation
  1. Initial program 95.7%

    \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  2. Add Preprocessing
  3. Step-by-step derivation
    1. add-cube-cbrt95.4%

      \[\leadsto \left(\left(\color{blue}{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x} \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right) \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. pow395.4%

      \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    3. sub-neg95.4%

      \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\left(x + \left(-0.5\right)\right)} \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    4. metadata-eval95.4%

      \[\leadsto \left(\left({\left(\sqrt[3]{\left(x + \color{blue}{-0.5}\right) \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    5. *-commutative95.4%

      \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\log x \cdot \left(x + -0.5\right)}}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  4. Applied egg-rr95.4%

    \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\log x \cdot \left(x + -0.5\right)}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  5. Taylor expanded in x around inf 64.9%

    \[\leadsto \color{blue}{-1 \cdot x} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  6. Step-by-step derivation
    1. neg-mul-164.9%

      \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  7. Simplified64.9%

    \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  8. Taylor expanded in z around 0 24.7%

    \[\leadsto \left(-x\right) + \frac{\color{blue}{0.083333333333333}}{x} \]
  9. Step-by-step derivation
    1. *-un-lft-identity24.7%

      \[\leadsto \color{blue}{1 \cdot \left(\left(-x\right) + \frac{0.083333333333333}{x}\right)} \]
    2. *-un-lft-identity24.7%

      \[\leadsto \color{blue}{1 \cdot \left(1 \cdot \left(\left(-x\right) + \frac{0.083333333333333}{x}\right)\right)} \]
    3. *-un-lft-identity24.7%

      \[\leadsto 1 \cdot \color{blue}{\left(\left(-x\right) + \frac{0.083333333333333}{x}\right)} \]
    4. add-sqr-sqrt0.0%

      \[\leadsto 1 \cdot \left(\color{blue}{\sqrt{-x} \cdot \sqrt{-x}} + \frac{0.083333333333333}{x}\right) \]
    5. sqrt-unprod30.1%

      \[\leadsto 1 \cdot \left(\color{blue}{\sqrt{\left(-x\right) \cdot \left(-x\right)}} + \frac{0.083333333333333}{x}\right) \]
    6. sqr-neg30.1%

      \[\leadsto 1 \cdot \left(\sqrt{\color{blue}{x \cdot x}} + \frac{0.083333333333333}{x}\right) \]
    7. sqrt-unprod29.3%

      \[\leadsto 1 \cdot \left(\color{blue}{\sqrt{x} \cdot \sqrt{x}} + \frac{0.083333333333333}{x}\right) \]
    8. add-sqr-sqrt29.3%

      \[\leadsto 1 \cdot \left(\color{blue}{x} + \frac{0.083333333333333}{x}\right) \]
  10. Applied egg-rr29.3%

    \[\leadsto \color{blue}{1 \cdot \left(x + \frac{0.083333333333333}{x}\right)} \]
  11. Step-by-step derivation
    1. *-lft-identity29.3%

      \[\leadsto \color{blue}{x + \frac{0.083333333333333}{x}} \]
  12. Simplified29.3%

    \[\leadsto \color{blue}{x + \frac{0.083333333333333}{x}} \]
  13. Final simplification29.3%

    \[\leadsto x + \frac{0.083333333333333}{x} \]
  14. Add Preprocessing

Alternative 19: 23.5% accurate, 41.0× speedup?

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

\\
\frac{0.083333333333333}{x}
\end{array}
Derivation
  1. Initial program 95.7%

    \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  2. Add Preprocessing
  3. Step-by-step derivation
    1. add-cube-cbrt95.4%

      \[\leadsto \left(\left(\color{blue}{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x} \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right) \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. pow395.4%

      \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    3. sub-neg95.4%

      \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\left(x + \left(-0.5\right)\right)} \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    4. metadata-eval95.4%

      \[\leadsto \left(\left({\left(\sqrt[3]{\left(x + \color{blue}{-0.5}\right) \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    5. *-commutative95.4%

      \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\log x \cdot \left(x + -0.5\right)}}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  4. Applied egg-rr95.4%

    \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\log x \cdot \left(x + -0.5\right)}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  5. Taylor expanded in x around inf 64.9%

    \[\leadsto \color{blue}{-1 \cdot x} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  6. Step-by-step derivation
    1. neg-mul-164.9%

      \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  7. Simplified64.9%

    \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  8. Taylor expanded in z around 0 24.7%

    \[\leadsto \left(-x\right) + \frac{\color{blue}{0.083333333333333}}{x} \]
  9. Taylor expanded in x around 0 25.6%

    \[\leadsto \color{blue}{\frac{0.083333333333333}{x}} \]
  10. Final simplification25.6%

    \[\leadsto \frac{0.083333333333333}{x} \]
  11. Add Preprocessing

Alternative 20: 1.3% accurate, 61.5× speedup?

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

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

    \[\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  2. Add Preprocessing
  3. Step-by-step derivation
    1. add-cube-cbrt95.4%

      \[\leadsto \left(\left(\color{blue}{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x} \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right) \cdot \sqrt[3]{\left(x - 0.5\right) \cdot \log x}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. pow395.4%

      \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\left(x - 0.5\right) \cdot \log x}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    3. sub-neg95.4%

      \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\left(x + \left(-0.5\right)\right)} \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    4. metadata-eval95.4%

      \[\leadsto \left(\left({\left(\sqrt[3]{\left(x + \color{blue}{-0.5}\right) \cdot \log x}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    5. *-commutative95.4%

      \[\leadsto \left(\left({\left(\sqrt[3]{\color{blue}{\log x \cdot \left(x + -0.5\right)}}\right)}^{3} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  4. Applied egg-rr95.4%

    \[\leadsto \left(\left(\color{blue}{{\left(\sqrt[3]{\log x \cdot \left(x + -0.5\right)}\right)}^{3}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  5. Taylor expanded in x around inf 64.9%

    \[\leadsto \color{blue}{-1 \cdot x} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  6. Step-by-step derivation
    1. neg-mul-164.9%

      \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  7. Simplified64.9%

    \[\leadsto \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
  8. Taylor expanded in z around 0 24.7%

    \[\leadsto \left(-x\right) + \frac{\color{blue}{0.083333333333333}}{x} \]
  9. Taylor expanded in x around inf 1.3%

    \[\leadsto \color{blue}{-1 \cdot x} \]
  10. Step-by-step derivation
    1. mul-1-neg1.3%

      \[\leadsto \color{blue}{-x} \]
  11. Simplified1.3%

    \[\leadsto \color{blue}{-x} \]
  12. Final simplification1.3%

    \[\leadsto -x \]
  13. Add Preprocessing

Developer target: 98.6% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \left(\left(\left(x - 0.5\right) \cdot \log x + \left(0.91893853320467 - x\right)\right) + \frac{0.083333333333333}{x}\right) + \frac{z}{x} \cdot \left(z \cdot \left(y + 0.0007936500793651\right) - 0.0027777777777778\right) \end{array} \]
(FPCore (x y z)
 :precision binary64
 (+
  (+ (+ (* (- x 0.5) (log x)) (- 0.91893853320467 x)) (/ 0.083333333333333 x))
  (* (/ z x) (- (* z (+ y 0.0007936500793651)) 0.0027777777777778))))
double code(double x, double y, double z) {
	return ((((x - 0.5) * log(x)) + (0.91893853320467 - x)) + (0.083333333333333 / x)) + ((z / x) * ((z * (y + 0.0007936500793651)) - 0.0027777777777778));
}
real(8) function code(x, y, z)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    code = ((((x - 0.5d0) * log(x)) + (0.91893853320467d0 - x)) + (0.083333333333333d0 / x)) + ((z / x) * ((z * (y + 0.0007936500793651d0)) - 0.0027777777777778d0))
end function
public static double code(double x, double y, double z) {
	return ((((x - 0.5) * Math.log(x)) + (0.91893853320467 - x)) + (0.083333333333333 / x)) + ((z / x) * ((z * (y + 0.0007936500793651)) - 0.0027777777777778));
}
def code(x, y, z):
	return ((((x - 0.5) * math.log(x)) + (0.91893853320467 - x)) + (0.083333333333333 / x)) + ((z / x) * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))
function code(x, y, z)
	return Float64(Float64(Float64(Float64(Float64(x - 0.5) * log(x)) + Float64(0.91893853320467 - x)) + Float64(0.083333333333333 / x)) + Float64(Float64(z / x) * Float64(Float64(z * Float64(y + 0.0007936500793651)) - 0.0027777777777778)))
end
function tmp = code(x, y, z)
	tmp = ((((x - 0.5) * log(x)) + (0.91893853320467 - x)) + (0.083333333333333 / x)) + ((z / x) * ((z * (y + 0.0007936500793651)) - 0.0027777777777778));
end
code[x_, y_, z_] := N[(N[(N[(N[(N[(x - 0.5), $MachinePrecision] * N[Log[x], $MachinePrecision]), $MachinePrecision] + N[(0.91893853320467 - x), $MachinePrecision]), $MachinePrecision] + N[(0.083333333333333 / x), $MachinePrecision]), $MachinePrecision] + N[(N[(z / x), $MachinePrecision] * N[(N[(z * N[(y + 0.0007936500793651), $MachinePrecision]), $MachinePrecision] - 0.0027777777777778), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\left(\left(\left(x - 0.5\right) \cdot \log x + \left(0.91893853320467 - x\right)\right) + \frac{0.083333333333333}{x}\right) + \frac{z}{x} \cdot \left(z \cdot \left(y + 0.0007936500793651\right) - 0.0027777777777778\right)
\end{array}

Reproduce

?
herbie shell --seed 2024067 
(FPCore (x y z)
  :name "Numeric.SpecFunctions:$slogFactorial from math-functions-0.1.5.2, B"
  :precision binary64

  :herbie-target
  (+ (+ (+ (* (- x 0.5) (log x)) (- 0.91893853320467 x)) (/ 0.083333333333333 x)) (* (/ z x) (- (* z (+ y 0.0007936500793651)) 0.0027777777777778)))

  (+ (+ (- (* (- x 0.5) (log x)) x) 0.91893853320467) (/ (+ (* (- (* (+ y 0.0007936500793651) z) 0.0027777777777778) z) 0.083333333333333) x)))