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

Percentage Accurate: 94.0% → 99.6%
Time: 20.8s
Alternatives: 24
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 24 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: 94.0% 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: 99.6% accurate, 0.5× speedup?

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

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

\mathbf{else}:\\
\;\;\;\;0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \left(0.083333333333333 \cdot \frac{1}{x} + z \cdot \left(z \cdot \left(\frac{y}{x} + \frac{0.0007936500793651}{x}\right)\right)\right) - x\right)\\


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

    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

    if 8e8 < x

    1. Initial program 79.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. Step-by-step derivation
      1. +-commutative79.9%

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \frac{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), 0.083333333333333\right)}{x} - x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in z around 0 99.7%

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

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \left(\color{blue}{{z}^{2} \cdot \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)} + 0.083333333333333 \cdot \frac{1}{x}\right) - x\right) \]
    7. Step-by-step derivation
      1. distribute-rgt-in77.4%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \left(\color{blue}{\left(\left(0.0007936500793651 \cdot \frac{1}{x}\right) \cdot {z}^{2} + \frac{y}{x} \cdot {z}^{2}\right)} + 0.083333333333333 \cdot \frac{1}{x}\right) - x\right) \]
      2. associate-*r/77.4%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \left(\left(\color{blue}{\frac{0.0007936500793651 \cdot 1}{x}} \cdot {z}^{2} + \frac{y}{x} \cdot {z}^{2}\right) + 0.083333333333333 \cdot \frac{1}{x}\right) - x\right) \]
      3. metadata-eval77.4%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \left(\left(\frac{\color{blue}{0.0007936500793651}}{x} \cdot {z}^{2} + \frac{y}{x} \cdot {z}^{2}\right) + 0.083333333333333 \cdot \frac{1}{x}\right) - x\right) \]
      4. distribute-rgt-in91.4%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \left(\color{blue}{{z}^{2} \cdot \left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right)} + 0.083333333333333 \cdot \frac{1}{x}\right) - x\right) \]
      5. +-commutative91.4%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \left({z}^{2} \cdot \color{blue}{\left(\frac{y}{x} + \frac{0.0007936500793651}{x}\right)} + 0.083333333333333 \cdot \frac{1}{x}\right) - x\right) \]
      6. unpow291.4%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \left(\color{blue}{\left(z \cdot z\right)} \cdot \left(\frac{y}{x} + \frac{0.0007936500793651}{x}\right) + 0.083333333333333 \cdot \frac{1}{x}\right) - x\right) \]
      7. associate-*l*99.7%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \left(\color{blue}{z \cdot \left(z \cdot \left(\frac{y}{x} + \frac{0.0007936500793651}{x}\right)\right)} + 0.083333333333333 \cdot \frac{1}{x}\right) - x\right) \]
    8. Simplified99.7%

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \left(\color{blue}{z \cdot \left(z \cdot \left(\frac{y}{x} + \frac{0.0007936500793651}{x}\right)\right)} + 0.083333333333333 \cdot \frac{1}{x}\right) - x\right) \]
  3. Recombined 2 regimes into one program.
  4. Final simplification99.7%

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

Alternative 2: 99.4% accurate, 0.9× speedup?

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

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

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


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

    1. Initial program 99.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. flip--99.6%

        \[\leadsto \left(\left(\color{blue}{\frac{x \cdot x - 0.5 \cdot 0.5}{x + 0.5}} \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. metadata-eval99.6%

        \[\leadsto \left(\left(\frac{x \cdot x - \color{blue}{0.25}}{x + 0.5} \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} \]
      3. metadata-eval99.6%

        \[\leadsto \left(\left(\frac{x \cdot x - \color{blue}{-0.5 \cdot -0.5}}{x + 0.5} \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} \]
      4. associate-*l/99.7%

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

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

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

        \[\leadsto \left(\left(\frac{\left(x \cdot x + \color{blue}{-0.25}\right) \cdot \log x}{x + 0.5} - 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}{\frac{\left(x \cdot x + -0.25\right) \cdot \log x}{x + 0.5}} - x\right) + 0.91893853320467\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]

    if 5.8000000000000003e57 < x

    1. Initial program 76.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 z around 0 99.6%

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

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \left(\color{blue}{{z}^{2} \cdot \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)} + 0.083333333333333 \cdot \frac{1}{x}\right) \]
    5. Step-by-step derivation
      1. distribute-rgt-in76.3%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \left(\color{blue}{\left(\left(0.0007936500793651 \cdot \frac{1}{x}\right) \cdot {z}^{2} + \frac{y}{x} \cdot {z}^{2}\right)} + 0.083333333333333 \cdot \frac{1}{x}\right) - x\right) \]
      2. associate-*r/76.3%

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

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \left(\left(\frac{\color{blue}{0.0007936500793651}}{x} \cdot {z}^{2} + \frac{y}{x} \cdot {z}^{2}\right) + 0.083333333333333 \cdot \frac{1}{x}\right) - x\right) \]
      4. distribute-rgt-in90.0%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \left(\color{blue}{{z}^{2} \cdot \left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right)} + 0.083333333333333 \cdot \frac{1}{x}\right) - x\right) \]
      5. +-commutative90.0%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \left({z}^{2} \cdot \color{blue}{\left(\frac{y}{x} + \frac{0.0007936500793651}{x}\right)} + 0.083333333333333 \cdot \frac{1}{x}\right) - x\right) \]
      6. unpow290.0%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \left(\color{blue}{\left(z \cdot z\right)} \cdot \left(\frac{y}{x} + \frac{0.0007936500793651}{x}\right) + 0.083333333333333 \cdot \frac{1}{x}\right) - x\right) \]
      7. associate-*l*99.7%

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

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

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

Alternative 3: 84.2% accurate, 0.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := 0.91893853320467 + x \cdot \left(\log x + -1\right)\\ \mathbf{if}\;x \leq 1.55 \cdot 10^{+43}:\\ \;\;\;\;0.91893853320467 + \frac{0.083333333333333 + z \cdot \left(z \cdot \left(y + 0.0007936500793651\right) - 0.0027777777777778\right)}{x}\\ \mathbf{elif}\;x \leq 2.5 \cdot 10^{+100}:\\ \;\;\;\;x \cdot \left(-1 - \log \left(\frac{1}{x}\right)\right)\\ \mathbf{elif}\;x \leq 2.7 \cdot 10^{+120}:\\ \;\;\;\;0.91893853320467 + z \cdot \left(z \cdot \left(\frac{y}{x} + \frac{0.0007936500793651}{x}\right)\right)\\ \mathbf{elif}\;x \leq 1.85 \cdot 10^{+154}:\\ \;\;\;\;\frac{0.083333333333333 + x \cdot t\_0}{x}\\ \mathbf{else}:\\ \;\;\;\;t\_0\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (let* ((t_0 (+ 0.91893853320467 (* x (+ (log x) -1.0)))))
   (if (<= x 1.55e+43)
     (+
      0.91893853320467
      (/
       (+
        0.083333333333333
        (* z (- (* z (+ y 0.0007936500793651)) 0.0027777777777778)))
       x))
     (if (<= x 2.5e+100)
       (* x (- -1.0 (log (/ 1.0 x))))
       (if (<= x 2.7e+120)
         (+ 0.91893853320467 (* z (* z (+ (/ y x) (/ 0.0007936500793651 x)))))
         (if (<= x 1.85e+154) (/ (+ 0.083333333333333 (* x t_0)) x) t_0))))))
double code(double x, double y, double z) {
	double t_0 = 0.91893853320467 + (x * (log(x) + -1.0));
	double tmp;
	if (x <= 1.55e+43) {
		tmp = 0.91893853320467 + ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x);
	} else if (x <= 2.5e+100) {
		tmp = x * (-1.0 - log((1.0 / x)));
	} else if (x <= 2.7e+120) {
		tmp = 0.91893853320467 + (z * (z * ((y / x) + (0.0007936500793651 / x))));
	} else if (x <= 1.85e+154) {
		tmp = (0.083333333333333 + (x * t_0)) / x;
	} else {
		tmp = t_0;
	}
	return tmp;
}
real(8) function code(x, y, z)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8) :: t_0
    real(8) :: tmp
    t_0 = 0.91893853320467d0 + (x * (log(x) + (-1.0d0)))
    if (x <= 1.55d+43) then
        tmp = 0.91893853320467d0 + ((0.083333333333333d0 + (z * ((z * (y + 0.0007936500793651d0)) - 0.0027777777777778d0))) / x)
    else if (x <= 2.5d+100) then
        tmp = x * ((-1.0d0) - log((1.0d0 / x)))
    else if (x <= 2.7d+120) then
        tmp = 0.91893853320467d0 + (z * (z * ((y / x) + (0.0007936500793651d0 / x))))
    else if (x <= 1.85d+154) then
        tmp = (0.083333333333333d0 + (x * t_0)) / x
    else
        tmp = t_0
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double t_0 = 0.91893853320467 + (x * (Math.log(x) + -1.0));
	double tmp;
	if (x <= 1.55e+43) {
		tmp = 0.91893853320467 + ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x);
	} else if (x <= 2.5e+100) {
		tmp = x * (-1.0 - Math.log((1.0 / x)));
	} else if (x <= 2.7e+120) {
		tmp = 0.91893853320467 + (z * (z * ((y / x) + (0.0007936500793651 / x))));
	} else if (x <= 1.85e+154) {
		tmp = (0.083333333333333 + (x * t_0)) / x;
	} else {
		tmp = t_0;
	}
	return tmp;
}
def code(x, y, z):
	t_0 = 0.91893853320467 + (x * (math.log(x) + -1.0))
	tmp = 0
	if x <= 1.55e+43:
		tmp = 0.91893853320467 + ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x)
	elif x <= 2.5e+100:
		tmp = x * (-1.0 - math.log((1.0 / x)))
	elif x <= 2.7e+120:
		tmp = 0.91893853320467 + (z * (z * ((y / x) + (0.0007936500793651 / x))))
	elif x <= 1.85e+154:
		tmp = (0.083333333333333 + (x * t_0)) / x
	else:
		tmp = t_0
	return tmp
function code(x, y, z)
	t_0 = Float64(0.91893853320467 + Float64(x * Float64(log(x) + -1.0)))
	tmp = 0.0
	if (x <= 1.55e+43)
		tmp = Float64(0.91893853320467 + Float64(Float64(0.083333333333333 + Float64(z * Float64(Float64(z * Float64(y + 0.0007936500793651)) - 0.0027777777777778))) / x));
	elseif (x <= 2.5e+100)
		tmp = Float64(x * Float64(-1.0 - log(Float64(1.0 / x))));
	elseif (x <= 2.7e+120)
		tmp = Float64(0.91893853320467 + Float64(z * Float64(z * Float64(Float64(y / x) + Float64(0.0007936500793651 / x)))));
	elseif (x <= 1.85e+154)
		tmp = Float64(Float64(0.083333333333333 + Float64(x * t_0)) / x);
	else
		tmp = t_0;
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	t_0 = 0.91893853320467 + (x * (log(x) + -1.0));
	tmp = 0.0;
	if (x <= 1.55e+43)
		tmp = 0.91893853320467 + ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x);
	elseif (x <= 2.5e+100)
		tmp = x * (-1.0 - log((1.0 / x)));
	elseif (x <= 2.7e+120)
		tmp = 0.91893853320467 + (z * (z * ((y / x) + (0.0007936500793651 / x))));
	elseif (x <= 1.85e+154)
		tmp = (0.083333333333333 + (x * t_0)) / x;
	else
		tmp = t_0;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := Block[{t$95$0 = N[(0.91893853320467 + N[(x * N[(N[Log[x], $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, 1.55e+43], N[(0.91893853320467 + N[(N[(0.083333333333333 + N[(z * N[(N[(z * N[(y + 0.0007936500793651), $MachinePrecision]), $MachinePrecision] - 0.0027777777777778), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 2.5e+100], N[(x * N[(-1.0 - N[Log[N[(1.0 / x), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 2.7e+120], N[(0.91893853320467 + N[(z * N[(z * N[(N[(y / x), $MachinePrecision] + N[(0.0007936500793651 / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 1.85e+154], N[(N[(0.083333333333333 + N[(x * t$95$0), $MachinePrecision]), $MachinePrecision] / x), $MachinePrecision], t$95$0]]]]]
\begin{array}{l}

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

\mathbf{elif}\;x \leq 2.5 \cdot 10^{+100}:\\
\;\;\;\;x \cdot \left(-1 - \log \left(\frac{1}{x}\right)\right)\\

\mathbf{elif}\;x \leq 2.7 \cdot 10^{+120}:\\
\;\;\;\;0.91893853320467 + z \cdot \left(z \cdot \left(\frac{y}{x} + \frac{0.0007936500793651}{x}\right)\right)\\

\mathbf{elif}\;x \leq 1.85 \cdot 10^{+154}:\\
\;\;\;\;\frac{0.083333333333333 + x \cdot t\_0}{x}\\

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


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

    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. Step-by-step derivation
      1. +-commutative99.7%

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \frac{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), 0.083333333333333\right)}{x} - x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in x around 0 94.6%

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

    if 1.5500000000000001e43 < x < 2.4999999999999999e100

    1. Initial program 99.4%

      \[\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. Step-by-step derivation
      1. +-commutative99.4%

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \frac{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), 0.083333333333333\right)}{x} - x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in z around 0 71.4%

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

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

    if 2.4999999999999999e100 < x < 2.7e120

    1. Initial program 90.4%

      \[\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. Step-by-step derivation
      1. +-commutative90.4%

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

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto 0.91893853320467 + \color{blue}{{z}^{2} \cdot \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)} \]
    6. Step-by-step derivation
      1. *-commutative62.4%

        \[\leadsto 0.91893853320467 + \color{blue}{\left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right) \cdot {z}^{2}} \]
      2. associate-*r/62.4%

        \[\leadsto 0.91893853320467 + \left(\color{blue}{\frac{0.0007936500793651 \cdot 1}{x}} + \frac{y}{x}\right) \cdot {z}^{2} \]
      3. metadata-eval62.4%

        \[\leadsto 0.91893853320467 + \left(\frac{\color{blue}{0.0007936500793651}}{x} + \frac{y}{x}\right) \cdot {z}^{2} \]
      4. unpow262.4%

        \[\leadsto 0.91893853320467 + \left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot \color{blue}{\left(z \cdot z\right)} \]
    7. Simplified62.4%

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

        \[\leadsto \color{blue}{\left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot \left(z \cdot z\right) + 0.91893853320467} \]
      2. associate-*r*71.6%

        \[\leadsto \color{blue}{\left(\left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot z\right) \cdot z} + 0.91893853320467 \]
      3. div-inv71.6%

        \[\leadsto \left(\left(\color{blue}{0.0007936500793651 \cdot \frac{1}{x}} + \frac{y}{x}\right) \cdot z\right) \cdot z + 0.91893853320467 \]
      4. *-commutative71.6%

        \[\leadsto \color{blue}{\left(z \cdot \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)\right)} \cdot z + 0.91893853320467 \]
      5. div-inv71.6%

        \[\leadsto \left(z \cdot \left(\color{blue}{\frac{0.0007936500793651}{x}} + \frac{y}{x}\right)\right) \cdot z + 0.91893853320467 \]
      6. distribute-lft-in71.6%

        \[\leadsto \color{blue}{\left(z \cdot \frac{0.0007936500793651}{x} + z \cdot \frac{y}{x}\right)} \cdot z + 0.91893853320467 \]
    9. Applied egg-rr71.6%

      \[\leadsto \color{blue}{\left(z \cdot \frac{0.0007936500793651}{x} + z \cdot \frac{y}{x}\right) \cdot z + 0.91893853320467} \]
    10. Step-by-step derivation
      1. distribute-lft-out71.6%

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

        \[\leadsto \left(z \cdot \color{blue}{\left(\frac{y}{x} + \frac{0.0007936500793651}{x}\right)}\right) \cdot z + 0.91893853320467 \]
    11. Applied egg-rr71.6%

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

    if 2.7e120 < x < 1.84999999999999997e154

    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. Step-by-step derivation
      1. +-commutative94.0%

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \frac{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), 0.083333333333333\right)}{x} - x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in z around 0 56.9%

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

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

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

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

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

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

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

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

    if 1.84999999999999997e154 < x

    1. Initial program 67.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. Step-by-step derivation
      1. +-commutative67.9%

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

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto 0.91893853320467 + \color{blue}{x \cdot \left(-1 \cdot \log \left(\frac{1}{x}\right) - 1\right)} \]
    6. Step-by-step derivation
      1. sub-neg78.8%

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

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

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

        \[\leadsto 0.91893853320467 + x \cdot \left(\color{blue}{\log x} + \left(-1\right)\right) \]
      5. metadata-eval78.8%

        \[\leadsto 0.91893853320467 + x \cdot \left(\log x + \color{blue}{-1}\right) \]
    7. Simplified78.8%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq 1.55 \cdot 10^{+43}:\\ \;\;\;\;0.91893853320467 + \frac{0.083333333333333 + z \cdot \left(z \cdot \left(y + 0.0007936500793651\right) - 0.0027777777777778\right)}{x}\\ \mathbf{elif}\;x \leq 2.5 \cdot 10^{+100}:\\ \;\;\;\;x \cdot \left(-1 - \log \left(\frac{1}{x}\right)\right)\\ \mathbf{elif}\;x \leq 2.7 \cdot 10^{+120}:\\ \;\;\;\;0.91893853320467 + z \cdot \left(z \cdot \left(\frac{y}{x} + \frac{0.0007936500793651}{x}\right)\right)\\ \mathbf{elif}\;x \leq 1.85 \cdot 10^{+154}:\\ \;\;\;\;\frac{0.083333333333333 + x \cdot \left(0.91893853320467 + x \cdot \left(\log x + -1\right)\right)}{x}\\ \mathbf{else}:\\ \;\;\;\;0.91893853320467 + x \cdot \left(\log x + -1\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 4: 94.5% accurate, 0.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := \left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\\ \mathbf{if}\;x \leq 2.35 \cdot 10^{-5}:\\ \;\;\;\;0.91893853320467 + \frac{0.083333333333333 + z \cdot \left(z \cdot \left(y + 0.0007936500793651\right) - 0.0027777777777778\right)}{x}\\ \mathbf{elif}\;x \leq 1.2 \cdot 10^{+134}:\\ \;\;\;\;t\_0 + \frac{\left(z \cdot z\right) \cdot \left(y + 0.0007936500793651\right)}{x}\\ \mathbf{elif}\;x \leq 1.1 \cdot 10^{+215}:\\ \;\;\;\;t\_0 + \frac{y}{x} \cdot \left(z \cdot z\right)\\ \mathbf{else}:\\ \;\;\;\;0.91893853320467 + x \cdot \left(\frac{0.083333333333333}{x \cdot x} + \left(\log x + -1\right)\right)\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (let* ((t_0 (+ (- (* (- x 0.5) (log x)) x) 0.91893853320467)))
   (if (<= x 2.35e-5)
     (+
      0.91893853320467
      (/
       (+
        0.083333333333333
        (* z (- (* z (+ y 0.0007936500793651)) 0.0027777777777778)))
       x))
     (if (<= x 1.2e+134)
       (+ t_0 (/ (* (* z z) (+ y 0.0007936500793651)) x))
       (if (<= x 1.1e+215)
         (+ t_0 (* (/ y x) (* z z)))
         (+
          0.91893853320467
          (* x (+ (/ 0.083333333333333 (* x x)) (+ (log x) -1.0)))))))))
double code(double x, double y, double z) {
	double t_0 = (((x - 0.5) * log(x)) - x) + 0.91893853320467;
	double tmp;
	if (x <= 2.35e-5) {
		tmp = 0.91893853320467 + ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x);
	} else if (x <= 1.2e+134) {
		tmp = t_0 + (((z * z) * (y + 0.0007936500793651)) / x);
	} else if (x <= 1.1e+215) {
		tmp = t_0 + ((y / x) * (z * z));
	} else {
		tmp = 0.91893853320467 + (x * ((0.083333333333333 / (x * x)) + (log(x) + -1.0)));
	}
	return tmp;
}
real(8) function code(x, y, z)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8) :: t_0
    real(8) :: tmp
    t_0 = (((x - 0.5d0) * log(x)) - x) + 0.91893853320467d0
    if (x <= 2.35d-5) then
        tmp = 0.91893853320467d0 + ((0.083333333333333d0 + (z * ((z * (y + 0.0007936500793651d0)) - 0.0027777777777778d0))) / x)
    else if (x <= 1.2d+134) then
        tmp = t_0 + (((z * z) * (y + 0.0007936500793651d0)) / x)
    else if (x <= 1.1d+215) then
        tmp = t_0 + ((y / x) * (z * z))
    else
        tmp = 0.91893853320467d0 + (x * ((0.083333333333333d0 / (x * x)) + (log(x) + (-1.0d0))))
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double t_0 = (((x - 0.5) * Math.log(x)) - x) + 0.91893853320467;
	double tmp;
	if (x <= 2.35e-5) {
		tmp = 0.91893853320467 + ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x);
	} else if (x <= 1.2e+134) {
		tmp = t_0 + (((z * z) * (y + 0.0007936500793651)) / x);
	} else if (x <= 1.1e+215) {
		tmp = t_0 + ((y / x) * (z * z));
	} else {
		tmp = 0.91893853320467 + (x * ((0.083333333333333 / (x * x)) + (Math.log(x) + -1.0)));
	}
	return tmp;
}
def code(x, y, z):
	t_0 = (((x - 0.5) * math.log(x)) - x) + 0.91893853320467
	tmp = 0
	if x <= 2.35e-5:
		tmp = 0.91893853320467 + ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x)
	elif x <= 1.2e+134:
		tmp = t_0 + (((z * z) * (y + 0.0007936500793651)) / x)
	elif x <= 1.1e+215:
		tmp = t_0 + ((y / x) * (z * z))
	else:
		tmp = 0.91893853320467 + (x * ((0.083333333333333 / (x * x)) + (math.log(x) + -1.0)))
	return tmp
function code(x, y, z)
	t_0 = Float64(Float64(Float64(Float64(x - 0.5) * log(x)) - x) + 0.91893853320467)
	tmp = 0.0
	if (x <= 2.35e-5)
		tmp = Float64(0.91893853320467 + Float64(Float64(0.083333333333333 + Float64(z * Float64(Float64(z * Float64(y + 0.0007936500793651)) - 0.0027777777777778))) / x));
	elseif (x <= 1.2e+134)
		tmp = Float64(t_0 + Float64(Float64(Float64(z * z) * Float64(y + 0.0007936500793651)) / x));
	elseif (x <= 1.1e+215)
		tmp = Float64(t_0 + Float64(Float64(y / x) * Float64(z * z)));
	else
		tmp = Float64(0.91893853320467 + Float64(x * Float64(Float64(0.083333333333333 / Float64(x * x)) + Float64(log(x) + -1.0))));
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	t_0 = (((x - 0.5) * log(x)) - x) + 0.91893853320467;
	tmp = 0.0;
	if (x <= 2.35e-5)
		tmp = 0.91893853320467 + ((0.083333333333333 + (z * ((z * (y + 0.0007936500793651)) - 0.0027777777777778))) / x);
	elseif (x <= 1.2e+134)
		tmp = t_0 + (((z * z) * (y + 0.0007936500793651)) / x);
	elseif (x <= 1.1e+215)
		tmp = t_0 + ((y / x) * (z * z));
	else
		tmp = 0.91893853320467 + (x * ((0.083333333333333 / (x * x)) + (log(x) + -1.0)));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := Block[{t$95$0 = N[(N[(N[(N[(x - 0.5), $MachinePrecision] * N[Log[x], $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision] + 0.91893853320467), $MachinePrecision]}, If[LessEqual[x, 2.35e-5], N[(0.91893853320467 + N[(N[(0.083333333333333 + N[(z * N[(N[(z * N[(y + 0.0007936500793651), $MachinePrecision]), $MachinePrecision] - 0.0027777777777778), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 1.2e+134], N[(t$95$0 + N[(N[(N[(z * z), $MachinePrecision] * N[(y + 0.0007936500793651), $MachinePrecision]), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 1.1e+215], N[(t$95$0 + N[(N[(y / x), $MachinePrecision] * N[(z * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(0.91893853320467 + N[(x * N[(N[(0.083333333333333 / N[(x * x), $MachinePrecision]), $MachinePrecision] + N[(N[Log[x], $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}

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

\mathbf{elif}\;x \leq 1.2 \cdot 10^{+134}:\\
\;\;\;\;t\_0 + \frac{\left(z \cdot z\right) \cdot \left(y + 0.0007936500793651\right)}{x}\\

\mathbf{elif}\;x \leq 1.1 \cdot 10^{+215}:\\
\;\;\;\;t\_0 + \frac{y}{x} \cdot \left(z \cdot z\right)\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if x < 2.34999999999999986e-5

    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. Step-by-step derivation
      1. +-commutative99.7%

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \frac{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), 0.083333333333333\right)}{x} - x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in x around 0 99.1%

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

    if 2.34999999999999986e-5 < x < 1.20000000000000003e134

    1. Initial program 97.8%

      \[\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. flip-+52.7%

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

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

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

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{{z}^{2} \cdot \left(-1 \cdot \frac{-1 \cdot \frac{\left(7.716049382716173 \cdot 10^{-6} \cdot \frac{1}{x \cdot \left(0.0007936500793651 + y\right)} + 0.083333333333333 \cdot \frac{1}{x}\right) - 7.716049382716173 \cdot 10^{-6} \cdot \frac{1}{x \cdot \left(0.0007936500793651 + y\right)}}{z} + 0.0027777777777778 \cdot \frac{1}{x}}{z} + \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)\right)} \]
    6. Simplified74.9%

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{\left(z \cdot z\right) \cdot \left(\left(\frac{y}{x} + \frac{0.0007936500793651}{x}\right) - \frac{\frac{0.0027777777777778}{x} - \frac{\frac{7.716049382716173 \cdot 10^{-6}}{\left(0.0007936500793651 + y\right) \cdot x} + \left(\frac{0.083333333333333}{x} - \frac{7.716049382716173 \cdot 10^{-6}}{\left(0.0007936500793651 + y\right) \cdot x}\right)}{z}}{z}\right)} \]
    7. Taylor expanded in x around -inf 75.0%

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{-1 \cdot \frac{{z}^{2} \cdot \left(\left(-1 \cdot y + 0.0027777777777778 \cdot \frac{1}{z}\right) - \left(0.0007936500793651 + 0.083333333333333 \cdot \frac{1}{{z}^{2}}\right)\right)}{x}} \]
    8. Step-by-step derivation
      1. associate-*r/75.0%

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

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

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\color{blue}{{z}^{2} \cdot \left(0.0007936500793651 + y\right)}}{x} \]
    11. Step-by-step derivation
      1. *-commutative97.9%

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

        \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{\left(0.0007936500793651 + y\right) \cdot \color{blue}{\left(z \cdot z\right)}}{x} \]
    12. Simplified97.9%

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

    if 1.20000000000000003e134 < x < 1.1000000000000001e215

    1. Initial program 70.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. flip-+36.2%

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

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

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

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{{z}^{2} \cdot \left(-1 \cdot \frac{-1 \cdot \frac{\left(7.716049382716173 \cdot 10^{-6} \cdot \frac{1}{x \cdot \left(0.0007936500793651 + y\right)} + 0.083333333333333 \cdot \frac{1}{x}\right) - 7.716049382716173 \cdot 10^{-6} \cdot \frac{1}{x \cdot \left(0.0007936500793651 + y\right)}}{z} + 0.0027777777777778 \cdot \frac{1}{x}}{z} + \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)\right)} \]
    6. Simplified94.9%

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{\left(z \cdot z\right) \cdot \left(\left(\frac{y}{x} + \frac{0.0007936500793651}{x}\right) - \frac{\frac{0.0027777777777778}{x} - \frac{\frac{7.716049382716173 \cdot 10^{-6}}{\left(0.0007936500793651 + y\right) \cdot x} + \left(\frac{0.083333333333333}{x} - \frac{7.716049382716173 \cdot 10^{-6}}{\left(0.0007936500793651 + y\right) \cdot x}\right)}{z}}{z}\right)} \]
    7. Taylor expanded in y around inf 92.0%

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

    if 1.1000000000000001e215 < x

    1. Initial program 69.1%

      \[\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. Step-by-step derivation
      1. +-commutative69.1%

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \frac{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), 0.083333333333333\right)}{x} - x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in z around 0 86.2%

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

      \[\leadsto 0.91893853320467 + \left(\left(0.083333333333333 \cdot \frac{1}{x} + \color{blue}{-1 \cdot \left(x \cdot \log \left(\frac{1}{x}\right)\right)}\right) - x\right) \]
    7. Step-by-step derivation
      1. mul-1-neg86.2%

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

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

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

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

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

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

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

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

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

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

        \[\leadsto 0.91893853320467 + x \cdot \color{blue}{\left(0.083333333333333 \cdot \frac{1}{{x}^{2}} + \left(\log x - 1\right)\right)} \]
      6. sub-neg86.4%

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

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

        \[\leadsto 0.91893853320467 + x \cdot \left(0.083333333333333 \cdot \frac{1}{\color{blue}{x \cdot x}} + \left(\log x + -1\right)\right) \]
      9. associate-*r/86.4%

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

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

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

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

Alternative 5: 99.4% accurate, 0.9× speedup?

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

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

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


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

    1. Initial program 99.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

    if 5.8000000000000003e57 < x

    1. Initial program 76.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 z around 0 99.6%

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

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \left(\color{blue}{{z}^{2} \cdot \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)} + 0.083333333333333 \cdot \frac{1}{x}\right) \]
    5. Step-by-step derivation
      1. distribute-rgt-in76.3%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \left(\color{blue}{\left(\left(0.0007936500793651 \cdot \frac{1}{x}\right) \cdot {z}^{2} + \frac{y}{x} \cdot {z}^{2}\right)} + 0.083333333333333 \cdot \frac{1}{x}\right) - x\right) \]
      2. associate-*r/76.3%

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

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \left(\left(\frac{\color{blue}{0.0007936500793651}}{x} \cdot {z}^{2} + \frac{y}{x} \cdot {z}^{2}\right) + 0.083333333333333 \cdot \frac{1}{x}\right) - x\right) \]
      4. distribute-rgt-in90.0%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \left(\color{blue}{{z}^{2} \cdot \left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right)} + 0.083333333333333 \cdot \frac{1}{x}\right) - x\right) \]
      5. +-commutative90.0%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \left({z}^{2} \cdot \color{blue}{\left(\frac{y}{x} + \frac{0.0007936500793651}{x}\right)} + 0.083333333333333 \cdot \frac{1}{x}\right) - x\right) \]
      6. unpow290.0%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \left(\color{blue}{\left(z \cdot z\right)} \cdot \left(\frac{y}{x} + \frac{0.0007936500793651}{x}\right) + 0.083333333333333 \cdot \frac{1}{x}\right) - x\right) \]
      7. associate-*l*99.7%

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

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

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

Alternative 6: 95.3% accurate, 1.0× speedup?

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

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

\mathbf{elif}\;x \leq 7.5 \cdot 10^{+215}:\\
\;\;\;\;t\_0 + \frac{y}{x} \cdot \left(z \cdot z\right)\\

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


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

    1. Initial program 99.1%

      \[\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 1.70000000000000009e134 < x < 7.4999999999999994e215

    1. Initial program 70.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. flip-+36.2%

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

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

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

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{{z}^{2} \cdot \left(-1 \cdot \frac{-1 \cdot \frac{\left(7.716049382716173 \cdot 10^{-6} \cdot \frac{1}{x \cdot \left(0.0007936500793651 + y\right)} + 0.083333333333333 \cdot \frac{1}{x}\right) - 7.716049382716173 \cdot 10^{-6} \cdot \frac{1}{x \cdot \left(0.0007936500793651 + y\right)}}{z} + 0.0027777777777778 \cdot \frac{1}{x}}{z} + \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)\right)} \]
    6. Simplified94.9%

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{\left(z \cdot z\right) \cdot \left(\left(\frac{y}{x} + \frac{0.0007936500793651}{x}\right) - \frac{\frac{0.0027777777777778}{x} - \frac{\frac{7.716049382716173 \cdot 10^{-6}}{\left(0.0007936500793651 + y\right) \cdot x} + \left(\frac{0.083333333333333}{x} - \frac{7.716049382716173 \cdot 10^{-6}}{\left(0.0007936500793651 + y\right) \cdot x}\right)}{z}}{z}\right)} \]
    7. Taylor expanded in y around inf 92.0%

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

    if 7.4999999999999994e215 < x

    1. Initial program 69.1%

      \[\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. Step-by-step derivation
      1. +-commutative69.1%

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \frac{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), 0.083333333333333\right)}{x} - x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in z around 0 86.2%

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

      \[\leadsto 0.91893853320467 + \left(\left(0.083333333333333 \cdot \frac{1}{x} + \color{blue}{-1 \cdot \left(x \cdot \log \left(\frac{1}{x}\right)\right)}\right) - x\right) \]
    7. Step-by-step derivation
      1. mul-1-neg86.2%

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

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

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

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

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

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

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

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

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

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

        \[\leadsto 0.91893853320467 + x \cdot \color{blue}{\left(0.083333333333333 \cdot \frac{1}{{x}^{2}} + \left(\log x - 1\right)\right)} \]
      6. sub-neg86.4%

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

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

        \[\leadsto 0.91893853320467 + x \cdot \left(0.083333333333333 \cdot \frac{1}{\color{blue}{x \cdot x}} + \left(\log x + -1\right)\right) \]
      9. associate-*r/86.4%

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

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

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

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

Alternative 7: 94.2% accurate, 1.0× speedup?

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

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

\mathbf{elif}\;x \leq 2.8 \cdot 10^{+215}:\\
\;\;\;\;\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{y}{x} \cdot \left(z \cdot z\right)\\

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


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

    1. Initial program 99.1%

      \[\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 98.5%

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

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

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

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

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

      \[\leadsto \left(\left(\color{blue}{x \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} \]

    if 5.99999999999999993e134 < x < 2.8e215

    1. Initial program 70.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. flip-+36.2%

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

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

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

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{{z}^{2} \cdot \left(-1 \cdot \frac{-1 \cdot \frac{\left(7.716049382716173 \cdot 10^{-6} \cdot \frac{1}{x \cdot \left(0.0007936500793651 + y\right)} + 0.083333333333333 \cdot \frac{1}{x}\right) - 7.716049382716173 \cdot 10^{-6} \cdot \frac{1}{x \cdot \left(0.0007936500793651 + y\right)}}{z} + 0.0027777777777778 \cdot \frac{1}{x}}{z} + \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)\right)} \]
    6. Simplified94.9%

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{\left(z \cdot z\right) \cdot \left(\left(\frac{y}{x} + \frac{0.0007936500793651}{x}\right) - \frac{\frac{0.0027777777777778}{x} - \frac{\frac{7.716049382716173 \cdot 10^{-6}}{\left(0.0007936500793651 + y\right) \cdot x} + \left(\frac{0.083333333333333}{x} - \frac{7.716049382716173 \cdot 10^{-6}}{\left(0.0007936500793651 + y\right) \cdot x}\right)}{z}}{z}\right)} \]
    7. Taylor expanded in y around inf 92.0%

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

    if 2.8e215 < x

    1. Initial program 69.1%

      \[\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. Step-by-step derivation
      1. +-commutative69.1%

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \frac{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), 0.083333333333333\right)}{x} - x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in z around 0 86.2%

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

      \[\leadsto 0.91893853320467 + \left(\left(0.083333333333333 \cdot \frac{1}{x} + \color{blue}{-1 \cdot \left(x \cdot \log \left(\frac{1}{x}\right)\right)}\right) - x\right) \]
    7. Step-by-step derivation
      1. mul-1-neg86.2%

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

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

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

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

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

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

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

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

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

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

        \[\leadsto 0.91893853320467 + x \cdot \color{blue}{\left(0.083333333333333 \cdot \frac{1}{{x}^{2}} + \left(\log x - 1\right)\right)} \]
      6. sub-neg86.4%

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

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

        \[\leadsto 0.91893853320467 + x \cdot \left(0.083333333333333 \cdot \frac{1}{\color{blue}{x \cdot x}} + \left(\log x + -1\right)\right) \]
      9. associate-*r/86.4%

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

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

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

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

Alternative 8: 92.2% accurate, 1.0× speedup?

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

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

\mathbf{elif}\;x \leq 6.5 \cdot 10^{+214}:\\
\;\;\;\;\left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \frac{y}{x} \cdot \left(z \cdot z\right)\\

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


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

    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. Step-by-step derivation
      1. +-commutative99.7%

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \frac{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), 0.083333333333333\right)}{x} - x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in x around 0 99.2%

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

    if 0.0071999999999999998 < x < 6.5000000000000001e214

    1. Initial program 85.8%

      \[\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. flip-+45.5%

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

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

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

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{{z}^{2} \cdot \left(-1 \cdot \frac{-1 \cdot \frac{\left(7.716049382716173 \cdot 10^{-6} \cdot \frac{1}{x \cdot \left(0.0007936500793651 + y\right)} + 0.083333333333333 \cdot \frac{1}{x}\right) - 7.716049382716173 \cdot 10^{-6} \cdot \frac{1}{x \cdot \left(0.0007936500793651 + y\right)}}{z} + 0.0027777777777778 \cdot \frac{1}{x}}{z} + \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)\right)} \]
    6. Simplified83.2%

      \[\leadsto \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + 0.91893853320467\right) + \color{blue}{\left(z \cdot z\right) \cdot \left(\left(\frac{y}{x} + \frac{0.0007936500793651}{x}\right) - \frac{\frac{0.0027777777777778}{x} - \frac{\frac{7.716049382716173 \cdot 10^{-6}}{\left(0.0007936500793651 + y\right) \cdot x} + \left(\frac{0.083333333333333}{x} - \frac{7.716049382716173 \cdot 10^{-6}}{\left(0.0007936500793651 + y\right) \cdot x}\right)}{z}}{z}\right)} \]
    7. Taylor expanded in y around inf 85.5%

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

    if 6.5000000000000001e214 < x

    1. Initial program 69.1%

      \[\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. Step-by-step derivation
      1. +-commutative69.1%

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \frac{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), 0.083333333333333\right)}{x} - x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in z around 0 86.2%

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

      \[\leadsto 0.91893853320467 + \left(\left(0.083333333333333 \cdot \frac{1}{x} + \color{blue}{-1 \cdot \left(x \cdot \log \left(\frac{1}{x}\right)\right)}\right) - x\right) \]
    7. Step-by-step derivation
      1. mul-1-neg86.2%

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

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

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

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

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

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

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

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

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

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

        \[\leadsto 0.91893853320467 + x \cdot \color{blue}{\left(0.083333333333333 \cdot \frac{1}{{x}^{2}} + \left(\log x - 1\right)\right)} \]
      6. sub-neg86.4%

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

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

        \[\leadsto 0.91893853320467 + x \cdot \left(0.083333333333333 \cdot \frac{1}{\color{blue}{x \cdot x}} + \left(\log x + -1\right)\right) \]
      9. associate-*r/86.4%

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

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

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

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

Alternative 9: 85.3% accurate, 1.1× speedup?

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

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

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


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

    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. Step-by-step derivation
      1. +-commutative99.7%

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \frac{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), 0.083333333333333\right)}{x} - x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in x around 0 94.6%

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

    if 1.85e43 < x

    1. Initial program 77.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. Step-by-step derivation
      1. +-commutative77.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto 0.91893853320467 + x \cdot \left(\log x + \color{blue}{-1}\right) \]
    7. Simplified70.9%

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

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

Alternative 10: 47.5% accurate, 5.1× speedup?

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

\\
\begin{array}{l}
t_0 := 0.91893853320467 + y \cdot \left(z \cdot \frac{z}{x}\right)\\
\mathbf{if}\;z \leq -1.95 \cdot 10^{-31}:\\
\;\;\;\;t\_0\\

\mathbf{elif}\;z \leq 2.8 \cdot 10^{-117}:\\
\;\;\;\;\frac{0.083333333333333 + x \cdot 0.91893853320467}{x}\\

\mathbf{elif}\;z \leq 5.2 \cdot 10^{+20}:\\
\;\;\;\;t\_0\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -1.9500000000000001e-31 or 2.8e-117 < z < 5.2e20

    1. Initial program 88.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. Step-by-step derivation
      1. +-commutative88.0%

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto 0.91893853320467 + \color{blue}{\left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right) \cdot {z}^{2}} \]
      2. associate-*r/64.2%

        \[\leadsto 0.91893853320467 + \left(\color{blue}{\frac{0.0007936500793651 \cdot 1}{x}} + \frac{y}{x}\right) \cdot {z}^{2} \]
      3. metadata-eval64.2%

        \[\leadsto 0.91893853320467 + \left(\frac{\color{blue}{0.0007936500793651}}{x} + \frac{y}{x}\right) \cdot {z}^{2} \]
      4. unpow264.2%

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

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

        \[\leadsto \color{blue}{\left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot \left(z \cdot z\right) + 0.91893853320467} \]
      2. associate-*r*64.1%

        \[\leadsto \color{blue}{\left(\left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot z\right) \cdot z} + 0.91893853320467 \]
      3. div-inv64.1%

        \[\leadsto \left(\left(\color{blue}{0.0007936500793651 \cdot \frac{1}{x}} + \frac{y}{x}\right) \cdot z\right) \cdot z + 0.91893853320467 \]
      4. *-commutative64.1%

        \[\leadsto \color{blue}{\left(z \cdot \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)\right)} \cdot z + 0.91893853320467 \]
      5. div-inv64.1%

        \[\leadsto \left(z \cdot \left(\color{blue}{\frac{0.0007936500793651}{x}} + \frac{y}{x}\right)\right) \cdot z + 0.91893853320467 \]
      6. distribute-lft-in57.4%

        \[\leadsto \color{blue}{\left(z \cdot \frac{0.0007936500793651}{x} + z \cdot \frac{y}{x}\right)} \cdot z + 0.91893853320467 \]
    9. Applied egg-rr57.4%

      \[\leadsto \color{blue}{\left(z \cdot \frac{0.0007936500793651}{x} + z \cdot \frac{y}{x}\right) \cdot z + 0.91893853320467} \]
    10. Taylor expanded in y around inf 46.5%

      \[\leadsto \color{blue}{\frac{y \cdot {z}^{2}}{x}} + 0.91893853320467 \]
    11. Step-by-step derivation
      1. associate-/l*52.4%

        \[\leadsto \color{blue}{y \cdot \frac{{z}^{2}}{x}} + 0.91893853320467 \]
      2. unpow252.4%

        \[\leadsto y \cdot \frac{\color{blue}{z \cdot z}}{x} + 0.91893853320467 \]
      3. associate-/l*52.3%

        \[\leadsto y \cdot \color{blue}{\left(z \cdot \frac{z}{x}\right)} + 0.91893853320467 \]
    12. Simplified52.3%

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

    if -1.9500000000000001e-31 < z < 2.8e-117

    1. Initial program 99.4%

      \[\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. Step-by-step derivation
      1. +-commutative99.4%

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \frac{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), 0.083333333333333\right)}{x} - x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in z around 0 97.2%

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{\frac{0.083333333333333 + 0.91893853320467 \cdot x}{x}} \]

    if 5.2e20 < z

    1. Initial program 77.1%

      \[\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. Step-by-step derivation
      1. +-commutative77.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto 0.91893853320467 + \color{blue}{\left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right) \cdot {z}^{2}} \]
      2. associate-*r/68.0%

        \[\leadsto 0.91893853320467 + \left(\color{blue}{\frac{0.0007936500793651 \cdot 1}{x}} + \frac{y}{x}\right) \cdot {z}^{2} \]
      3. metadata-eval68.0%

        \[\leadsto 0.91893853320467 + \left(\frac{\color{blue}{0.0007936500793651}}{x} + \frac{y}{x}\right) \cdot {z}^{2} \]
      4. unpow268.0%

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

      \[\leadsto 0.91893853320467 + \color{blue}{\left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot \left(z \cdot z\right)} \]
    8. Step-by-step derivation
      1. +-commutative68.0%

        \[\leadsto \color{blue}{\left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot \left(z \cdot z\right) + 0.91893853320467} \]
      2. associate-*r*70.8%

        \[\leadsto \color{blue}{\left(\left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot z\right) \cdot z} + 0.91893853320467 \]
      3. div-inv70.8%

        \[\leadsto \left(\left(\color{blue}{0.0007936500793651 \cdot \frac{1}{x}} + \frac{y}{x}\right) \cdot z\right) \cdot z + 0.91893853320467 \]
      4. *-commutative70.8%

        \[\leadsto \color{blue}{\left(z \cdot \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)\right)} \cdot z + 0.91893853320467 \]
      5. div-inv70.8%

        \[\leadsto \left(z \cdot \left(\color{blue}{\frac{0.0007936500793651}{x}} + \frac{y}{x}\right)\right) \cdot z + 0.91893853320467 \]
      6. distribute-lft-in69.2%

        \[\leadsto \color{blue}{\left(z \cdot \frac{0.0007936500793651}{x} + z \cdot \frac{y}{x}\right)} \cdot z + 0.91893853320467 \]
    9. Applied egg-rr69.2%

      \[\leadsto \color{blue}{\left(z \cdot \frac{0.0007936500793651}{x} + z \cdot \frac{y}{x}\right) \cdot z + 0.91893853320467} \]
    10. Taylor expanded in y around 0 55.5%

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

        \[\leadsto \color{blue}{\frac{0.0007936500793651 \cdot z}{x}} \cdot z + 0.91893853320467 \]
      2. *-commutative55.5%

        \[\leadsto \frac{\color{blue}{z \cdot 0.0007936500793651}}{x} \cdot z + 0.91893853320467 \]
      3. associate-*r/55.5%

        \[\leadsto \color{blue}{\left(z \cdot \frac{0.0007936500793651}{x}\right)} \cdot z + 0.91893853320467 \]
    12. Simplified55.5%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.95 \cdot 10^{-31}:\\ \;\;\;\;0.91893853320467 + y \cdot \left(z \cdot \frac{z}{x}\right)\\ \mathbf{elif}\;z \leq 2.8 \cdot 10^{-117}:\\ \;\;\;\;\frac{0.083333333333333 + x \cdot 0.91893853320467}{x}\\ \mathbf{elif}\;z \leq 5.2 \cdot 10^{+20}:\\ \;\;\;\;0.91893853320467 + y \cdot \left(z \cdot \frac{z}{x}\right)\\ \mathbf{else}:\\ \;\;\;\;0.91893853320467 + z \cdot \left(z \cdot \frac{0.0007936500793651}{x}\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 11: 47.4% accurate, 5.1× speedup?

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

\\
\begin{array}{l}
t_0 := 0.91893853320467 + y \cdot \left(z \cdot \frac{z}{x}\right)\\
\mathbf{if}\;z \leq -4 \cdot 10^{-34}:\\
\;\;\;\;t\_0\\

\mathbf{elif}\;z \leq 2.8 \cdot 10^{-117}:\\
\;\;\;\;\frac{0.083333333333333 + x \cdot 0.91893853320467}{x}\\

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -3.99999999999999971e-34 or 2.8e-117 < z < 2.4e21

    1. Initial program 88.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. Step-by-step derivation
      1. +-commutative88.0%

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto 0.91893853320467 + \color{blue}{\left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right) \cdot {z}^{2}} \]
      2. associate-*r/64.2%

        \[\leadsto 0.91893853320467 + \left(\color{blue}{\frac{0.0007936500793651 \cdot 1}{x}} + \frac{y}{x}\right) \cdot {z}^{2} \]
      3. metadata-eval64.2%

        \[\leadsto 0.91893853320467 + \left(\frac{\color{blue}{0.0007936500793651}}{x} + \frac{y}{x}\right) \cdot {z}^{2} \]
      4. unpow264.2%

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

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

        \[\leadsto \color{blue}{\left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot \left(z \cdot z\right) + 0.91893853320467} \]
      2. associate-*r*64.1%

        \[\leadsto \color{blue}{\left(\left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot z\right) \cdot z} + 0.91893853320467 \]
      3. div-inv64.1%

        \[\leadsto \left(\left(\color{blue}{0.0007936500793651 \cdot \frac{1}{x}} + \frac{y}{x}\right) \cdot z\right) \cdot z + 0.91893853320467 \]
      4. *-commutative64.1%

        \[\leadsto \color{blue}{\left(z \cdot \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)\right)} \cdot z + 0.91893853320467 \]
      5. div-inv64.1%

        \[\leadsto \left(z \cdot \left(\color{blue}{\frac{0.0007936500793651}{x}} + \frac{y}{x}\right)\right) \cdot z + 0.91893853320467 \]
      6. distribute-lft-in57.4%

        \[\leadsto \color{blue}{\left(z \cdot \frac{0.0007936500793651}{x} + z \cdot \frac{y}{x}\right)} \cdot z + 0.91893853320467 \]
    9. Applied egg-rr57.4%

      \[\leadsto \color{blue}{\left(z \cdot \frac{0.0007936500793651}{x} + z \cdot \frac{y}{x}\right) \cdot z + 0.91893853320467} \]
    10. Taylor expanded in y around inf 46.5%

      \[\leadsto \color{blue}{\frac{y \cdot {z}^{2}}{x}} + 0.91893853320467 \]
    11. Step-by-step derivation
      1. associate-/l*52.4%

        \[\leadsto \color{blue}{y \cdot \frac{{z}^{2}}{x}} + 0.91893853320467 \]
      2. unpow252.4%

        \[\leadsto y \cdot \frac{\color{blue}{z \cdot z}}{x} + 0.91893853320467 \]
      3. associate-/l*52.3%

        \[\leadsto y \cdot \color{blue}{\left(z \cdot \frac{z}{x}\right)} + 0.91893853320467 \]
    12. Simplified52.3%

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

    if -3.99999999999999971e-34 < z < 2.8e-117

    1. Initial program 99.4%

      \[\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. Step-by-step derivation
      1. +-commutative99.4%

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \frac{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), 0.083333333333333\right)}{x} - x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in z around 0 97.2%

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{\frac{0.083333333333333 + 0.91893853320467 \cdot x}{x}} \]

    if 2.4e21 < z

    1. Initial program 77.1%

      \[\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. Step-by-step derivation
      1. +-commutative77.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto 0.91893853320467 + \color{blue}{\left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right) \cdot {z}^{2}} \]
      2. associate-*r/68.0%

        \[\leadsto 0.91893853320467 + \left(\color{blue}{\frac{0.0007936500793651 \cdot 1}{x}} + \frac{y}{x}\right) \cdot {z}^{2} \]
      3. metadata-eval68.0%

        \[\leadsto 0.91893853320467 + \left(\frac{\color{blue}{0.0007936500793651}}{x} + \frac{y}{x}\right) \cdot {z}^{2} \]
      4. unpow268.0%

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

      \[\leadsto 0.91893853320467 + \color{blue}{\left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot \left(z \cdot z\right)} \]
    8. Step-by-step derivation
      1. +-commutative68.0%

        \[\leadsto \color{blue}{\left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot \left(z \cdot z\right) + 0.91893853320467} \]
      2. associate-*r*70.8%

        \[\leadsto \color{blue}{\left(\left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot z\right) \cdot z} + 0.91893853320467 \]
      3. div-inv70.8%

        \[\leadsto \left(\left(\color{blue}{0.0007936500793651 \cdot \frac{1}{x}} + \frac{y}{x}\right) \cdot z\right) \cdot z + 0.91893853320467 \]
      4. *-commutative70.8%

        \[\leadsto \color{blue}{\left(z \cdot \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)\right)} \cdot z + 0.91893853320467 \]
      5. div-inv70.8%

        \[\leadsto \left(z \cdot \left(\color{blue}{\frac{0.0007936500793651}{x}} + \frac{y}{x}\right)\right) \cdot z + 0.91893853320467 \]
      6. distribute-lft-in69.2%

        \[\leadsto \color{blue}{\left(z \cdot \frac{0.0007936500793651}{x} + z \cdot \frac{y}{x}\right)} \cdot z + 0.91893853320467 \]
    9. Applied egg-rr69.2%

      \[\leadsto \color{blue}{\left(z \cdot \frac{0.0007936500793651}{x} + z \cdot \frac{y}{x}\right) \cdot z + 0.91893853320467} \]
    10. Taylor expanded in y around 0 55.5%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -4 \cdot 10^{-34}:\\ \;\;\;\;0.91893853320467 + y \cdot \left(z \cdot \frac{z}{x}\right)\\ \mathbf{elif}\;z \leq 2.8 \cdot 10^{-117}:\\ \;\;\;\;\frac{0.083333333333333 + x \cdot 0.91893853320467}{x}\\ \mathbf{elif}\;z \leq 2.4 \cdot 10^{+21}:\\ \;\;\;\;0.91893853320467 + y \cdot \left(z \cdot \frac{z}{x}\right)\\ \mathbf{else}:\\ \;\;\;\;0.91893853320467 + z \cdot \left(0.0007936500793651 \cdot \frac{z}{x}\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 12: 47.4% accurate, 5.1× speedup?

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

\\
\begin{array}{l}
t_0 := 0.91893853320467 + y \cdot \left(z \cdot \frac{z}{x}\right)\\
\mathbf{if}\;z \leq -1.8 \cdot 10^{-33}:\\
\;\;\;\;t\_0\\

\mathbf{elif}\;z \leq 2.8 \cdot 10^{-117}:\\
\;\;\;\;\frac{0.083333333333333 + x \cdot 0.91893853320467}{x}\\

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -1.80000000000000017e-33 or 2.8e-117 < z < 4.2e21

    1. Initial program 88.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. Step-by-step derivation
      1. +-commutative88.0%

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto 0.91893853320467 + \color{blue}{\left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right) \cdot {z}^{2}} \]
      2. associate-*r/64.2%

        \[\leadsto 0.91893853320467 + \left(\color{blue}{\frac{0.0007936500793651 \cdot 1}{x}} + \frac{y}{x}\right) \cdot {z}^{2} \]
      3. metadata-eval64.2%

        \[\leadsto 0.91893853320467 + \left(\frac{\color{blue}{0.0007936500793651}}{x} + \frac{y}{x}\right) \cdot {z}^{2} \]
      4. unpow264.2%

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

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

        \[\leadsto \color{blue}{\left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot \left(z \cdot z\right) + 0.91893853320467} \]
      2. associate-*r*64.1%

        \[\leadsto \color{blue}{\left(\left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot z\right) \cdot z} + 0.91893853320467 \]
      3. div-inv64.1%

        \[\leadsto \left(\left(\color{blue}{0.0007936500793651 \cdot \frac{1}{x}} + \frac{y}{x}\right) \cdot z\right) \cdot z + 0.91893853320467 \]
      4. *-commutative64.1%

        \[\leadsto \color{blue}{\left(z \cdot \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)\right)} \cdot z + 0.91893853320467 \]
      5. div-inv64.1%

        \[\leadsto \left(z \cdot \left(\color{blue}{\frac{0.0007936500793651}{x}} + \frac{y}{x}\right)\right) \cdot z + 0.91893853320467 \]
      6. distribute-lft-in57.4%

        \[\leadsto \color{blue}{\left(z \cdot \frac{0.0007936500793651}{x} + z \cdot \frac{y}{x}\right)} \cdot z + 0.91893853320467 \]
    9. Applied egg-rr57.4%

      \[\leadsto \color{blue}{\left(z \cdot \frac{0.0007936500793651}{x} + z \cdot \frac{y}{x}\right) \cdot z + 0.91893853320467} \]
    10. Taylor expanded in y around inf 46.5%

      \[\leadsto \color{blue}{\frac{y \cdot {z}^{2}}{x}} + 0.91893853320467 \]
    11. Step-by-step derivation
      1. associate-/l*52.4%

        \[\leadsto \color{blue}{y \cdot \frac{{z}^{2}}{x}} + 0.91893853320467 \]
      2. unpow252.4%

        \[\leadsto y \cdot \frac{\color{blue}{z \cdot z}}{x} + 0.91893853320467 \]
      3. associate-/l*52.3%

        \[\leadsto y \cdot \color{blue}{\left(z \cdot \frac{z}{x}\right)} + 0.91893853320467 \]
    12. Simplified52.3%

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

    if -1.80000000000000017e-33 < z < 2.8e-117

    1. Initial program 99.4%

      \[\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. Step-by-step derivation
      1. +-commutative99.4%

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \frac{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), 0.083333333333333\right)}{x} - x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in z around 0 97.2%

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{\frac{0.083333333333333 + 0.91893853320467 \cdot x}{x}} \]

    if 4.2e21 < z

    1. Initial program 77.1%

      \[\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. Step-by-step derivation
      1. +-commutative77.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto 0.91893853320467 + \color{blue}{\left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right) \cdot {z}^{2}} \]
      2. associate-*r/68.0%

        \[\leadsto 0.91893853320467 + \left(\color{blue}{\frac{0.0007936500793651 \cdot 1}{x}} + \frac{y}{x}\right) \cdot {z}^{2} \]
      3. metadata-eval68.0%

        \[\leadsto 0.91893853320467 + \left(\frac{\color{blue}{0.0007936500793651}}{x} + \frac{y}{x}\right) \cdot {z}^{2} \]
      4. unpow268.0%

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.8 \cdot 10^{-33}:\\ \;\;\;\;0.91893853320467 + y \cdot \left(z \cdot \frac{z}{x}\right)\\ \mathbf{elif}\;z \leq 2.8 \cdot 10^{-117}:\\ \;\;\;\;\frac{0.083333333333333 + x \cdot 0.91893853320467}{x}\\ \mathbf{elif}\;z \leq 4.2 \cdot 10^{+21}:\\ \;\;\;\;0.91893853320467 + y \cdot \left(z \cdot \frac{z}{x}\right)\\ \mathbf{else}:\\ \;\;\;\;0.91893853320467 + \frac{0.0007936500793651}{x} \cdot \left(z \cdot z\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 13: 46.0% accurate, 5.1× speedup?

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

\\
\begin{array}{l}
t_0 := 0.91893853320467 + \frac{y}{x} \cdot \left(z \cdot z\right)\\
\mathbf{if}\;z \leq -5.4 \cdot 10^{-33}:\\
\;\;\;\;t\_0\\

\mathbf{elif}\;z \leq 7.6 \cdot 10^{-119}:\\
\;\;\;\;\frac{0.083333333333333 + x \cdot 0.91893853320467}{x}\\

\mathbf{elif}\;z \leq 6.8 \cdot 10^{+19}:\\
\;\;\;\;t\_0\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -5.4000000000000002e-33 or 7.59999999999999949e-119 < z < 6.8e19

    1. Initial program 88.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. Step-by-step derivation
      1. +-commutative88.0%

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto 0.91893853320467 + \color{blue}{\left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right) \cdot {z}^{2}} \]
      2. associate-*r/64.2%

        \[\leadsto 0.91893853320467 + \left(\color{blue}{\frac{0.0007936500793651 \cdot 1}{x}} + \frac{y}{x}\right) \cdot {z}^{2} \]
      3. metadata-eval64.2%

        \[\leadsto 0.91893853320467 + \left(\frac{\color{blue}{0.0007936500793651}}{x} + \frac{y}{x}\right) \cdot {z}^{2} \]
      4. unpow264.2%

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

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

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

    if -5.4000000000000002e-33 < z < 7.59999999999999949e-119

    1. Initial program 99.4%

      \[\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. Step-by-step derivation
      1. +-commutative99.4%

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \frac{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), 0.083333333333333\right)}{x} - x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in z around 0 97.2%

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{\frac{0.083333333333333 + 0.91893853320467 \cdot x}{x}} \]

    if 6.8e19 < z

    1. Initial program 77.1%

      \[\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. Step-by-step derivation
      1. +-commutative77.1%

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto 0.91893853320467 + \color{blue}{\left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right) \cdot {z}^{2}} \]
      2. associate-*r/68.0%

        \[\leadsto 0.91893853320467 + \left(\color{blue}{\frac{0.0007936500793651 \cdot 1}{x}} + \frac{y}{x}\right) \cdot {z}^{2} \]
      3. metadata-eval68.0%

        \[\leadsto 0.91893853320467 + \left(\frac{\color{blue}{0.0007936500793651}}{x} + \frac{y}{x}\right) \cdot {z}^{2} \]
      4. unpow268.0%

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -5.4 \cdot 10^{-33}:\\ \;\;\;\;0.91893853320467 + \frac{y}{x} \cdot \left(z \cdot z\right)\\ \mathbf{elif}\;z \leq 7.6 \cdot 10^{-119}:\\ \;\;\;\;\frac{0.083333333333333 + x \cdot 0.91893853320467}{x}\\ \mathbf{elif}\;z \leq 6.8 \cdot 10^{+19}:\\ \;\;\;\;0.91893853320467 + \frac{y}{x} \cdot \left(z \cdot z\right)\\ \mathbf{else}:\\ \;\;\;\;0.91893853320467 + \frac{0.0007936500793651}{x} \cdot \left(z \cdot z\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 14: 60.3% accurate, 5.3× speedup?

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

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

\mathbf{elif}\;z \leq 2.5 \cdot 10^{-116}:\\
\;\;\;\;\frac{0.083333333333333 + x \cdot 0.91893853320467}{x}\\

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


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

    1. Initial program 85.1%

      \[\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. Step-by-step derivation
      1. +-commutative85.1%

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

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto 0.91893853320467 + \color{blue}{{z}^{2} \cdot \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)} \]
    6. Step-by-step derivation
      1. *-commutative68.7%

        \[\leadsto 0.91893853320467 + \color{blue}{\left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right) \cdot {z}^{2}} \]
      2. associate-*r/68.7%

        \[\leadsto 0.91893853320467 + \left(\color{blue}{\frac{0.0007936500793651 \cdot 1}{x}} + \frac{y}{x}\right) \cdot {z}^{2} \]
      3. metadata-eval68.7%

        \[\leadsto 0.91893853320467 + \left(\frac{\color{blue}{0.0007936500793651}}{x} + \frac{y}{x}\right) \cdot {z}^{2} \]
      4. unpow268.7%

        \[\leadsto 0.91893853320467 + \left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot \color{blue}{\left(z \cdot z\right)} \]
    7. Simplified68.7%

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

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

        \[\leadsto 0.91893853320467 + \left(\color{blue}{\frac{1}{x} \cdot 0.0007936500793651} + \frac{y}{x}\right) \cdot \left(z \cdot z\right) \]
    9. Applied egg-rr68.7%

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

    if -1.2000000000000001e-32 < z < 2.5000000000000001e-116

    1. Initial program 99.4%

      \[\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. Step-by-step derivation
      1. +-commutative99.4%

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \frac{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), 0.083333333333333\right)}{x} - x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in z around 0 97.2%

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{\frac{0.083333333333333 + 0.91893853320467 \cdot x}{x}} \]

    if 2.5000000000000001e-116 < z

    1. Initial program 82.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. Step-by-step derivation
      1. +-commutative82.6%

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto 0.91893853320467 + \color{blue}{\left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right) \cdot {z}^{2}} \]
      2. associate-*r/63.1%

        \[\leadsto 0.91893853320467 + \left(\color{blue}{\frac{0.0007936500793651 \cdot 1}{x}} + \frac{y}{x}\right) \cdot {z}^{2} \]
      3. metadata-eval63.1%

        \[\leadsto 0.91893853320467 + \left(\frac{\color{blue}{0.0007936500793651}}{x} + \frac{y}{x}\right) \cdot {z}^{2} \]
      4. unpow263.1%

        \[\leadsto 0.91893853320467 + \left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot \color{blue}{\left(z \cdot z\right)} \]
    7. Simplified63.1%

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

        \[\leadsto \color{blue}{\left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot \left(z \cdot z\right) + 0.91893853320467} \]
      2. associate-*r*65.3%

        \[\leadsto \color{blue}{\left(\left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot z\right) \cdot z} + 0.91893853320467 \]
      3. div-inv65.2%

        \[\leadsto \left(\left(\color{blue}{0.0007936500793651 \cdot \frac{1}{x}} + \frac{y}{x}\right) \cdot z\right) \cdot z + 0.91893853320467 \]
      4. *-commutative65.2%

        \[\leadsto \color{blue}{\left(z \cdot \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)\right)} \cdot z + 0.91893853320467 \]
      5. div-inv65.3%

        \[\leadsto \left(z \cdot \left(\color{blue}{\frac{0.0007936500793651}{x}} + \frac{y}{x}\right)\right) \cdot z + 0.91893853320467 \]
      6. distribute-lft-in64.0%

        \[\leadsto \color{blue}{\left(z \cdot \frac{0.0007936500793651}{x} + z \cdot \frac{y}{x}\right)} \cdot z + 0.91893853320467 \]
    9. Applied egg-rr64.0%

      \[\leadsto \color{blue}{\left(z \cdot \frac{0.0007936500793651}{x} + z \cdot \frac{y}{x}\right) \cdot z + 0.91893853320467} \]
    10. Step-by-step derivation
      1. distribute-lft-out65.3%

        \[\leadsto \color{blue}{\left(z \cdot \left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right)\right)} \cdot z + 0.91893853320467 \]
      2. +-commutative65.3%

        \[\leadsto \left(z \cdot \color{blue}{\left(\frac{y}{x} + \frac{0.0007936500793651}{x}\right)}\right) \cdot z + 0.91893853320467 \]
    11. Applied egg-rr65.3%

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

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

Alternative 15: 60.3% accurate, 5.3× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.4 \cdot 10^{-31}:\\
\;\;\;\;0.91893853320467 + \left(z \cdot z\right) \cdot \frac{y + 0.0007936500793651}{x}\\

\mathbf{elif}\;z \leq 2.8 \cdot 10^{-117}:\\
\;\;\;\;\frac{0.083333333333333 + x \cdot 0.91893853320467}{x}\\

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


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

    1. Initial program 85.1%

      \[\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. Step-by-step derivation
      1. +-commutative85.1%

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

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto 0.91893853320467 + \color{blue}{{z}^{2} \cdot \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)} \]
    6. Step-by-step derivation
      1. *-commutative68.7%

        \[\leadsto 0.91893853320467 + \color{blue}{\left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right) \cdot {z}^{2}} \]
      2. associate-*r/68.7%

        \[\leadsto 0.91893853320467 + \left(\color{blue}{\frac{0.0007936500793651 \cdot 1}{x}} + \frac{y}{x}\right) \cdot {z}^{2} \]
      3. metadata-eval68.7%

        \[\leadsto 0.91893853320467 + \left(\frac{\color{blue}{0.0007936500793651}}{x} + \frac{y}{x}\right) \cdot {z}^{2} \]
      4. unpow268.7%

        \[\leadsto 0.91893853320467 + \left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot \color{blue}{\left(z \cdot z\right)} \]
    7. Simplified68.7%

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

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

    if -2.4e-31 < z < 2.8e-117

    1. Initial program 99.4%

      \[\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. Step-by-step derivation
      1. +-commutative99.4%

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \frac{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), 0.083333333333333\right)}{x} - x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in z around 0 97.2%

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{\frac{0.083333333333333 + 0.91893853320467 \cdot x}{x}} \]

    if 2.8e-117 < z

    1. Initial program 82.8%

      \[\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. Step-by-step derivation
      1. +-commutative82.8%

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

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto 0.91893853320467 + \color{blue}{{z}^{2} \cdot \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)} \]
    6. Step-by-step derivation
      1. *-commutative62.4%

        \[\leadsto 0.91893853320467 + \color{blue}{\left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right) \cdot {z}^{2}} \]
      2. associate-*r/62.4%

        \[\leadsto 0.91893853320467 + \left(\color{blue}{\frac{0.0007936500793651 \cdot 1}{x}} + \frac{y}{x}\right) \cdot {z}^{2} \]
      3. metadata-eval62.4%

        \[\leadsto 0.91893853320467 + \left(\frac{\color{blue}{0.0007936500793651}}{x} + \frac{y}{x}\right) \cdot {z}^{2} \]
      4. unpow262.4%

        \[\leadsto 0.91893853320467 + \left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot \color{blue}{\left(z \cdot z\right)} \]
    7. Simplified62.4%

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

        \[\leadsto \color{blue}{\left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot \left(z \cdot z\right) + 0.91893853320467} \]
      2. associate-*r*64.6%

        \[\leadsto \color{blue}{\left(\left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot z\right) \cdot z} + 0.91893853320467 \]
      3. div-inv64.5%

        \[\leadsto \left(\left(\color{blue}{0.0007936500793651 \cdot \frac{1}{x}} + \frac{y}{x}\right) \cdot z\right) \cdot z + 0.91893853320467 \]
      4. *-commutative64.5%

        \[\leadsto \color{blue}{\left(z \cdot \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)\right)} \cdot z + 0.91893853320467 \]
      5. div-inv64.6%

        \[\leadsto \left(z \cdot \left(\color{blue}{\frac{0.0007936500793651}{x}} + \frac{y}{x}\right)\right) \cdot z + 0.91893853320467 \]
      6. distribute-lft-in63.3%

        \[\leadsto \color{blue}{\left(z \cdot \frac{0.0007936500793651}{x} + z \cdot \frac{y}{x}\right)} \cdot z + 0.91893853320467 \]
    9. Applied egg-rr63.3%

      \[\leadsto \color{blue}{\left(z \cdot \frac{0.0007936500793651}{x} + z \cdot \frac{y}{x}\right) \cdot z + 0.91893853320467} \]
    10. Step-by-step derivation
      1. distribute-lft-out64.6%

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

        \[\leadsto \left(z \cdot \color{blue}{\left(\frac{y}{x} + \frac{0.0007936500793651}{x}\right)}\right) \cdot z + 0.91893853320467 \]
    11. Applied egg-rr64.6%

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

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

Alternative 16: 59.4% accurate, 5.8× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -3.2 \cdot 10^{-31} \lor \neg \left(z \leq 2.8 \cdot 10^{-117}\right):\\
\;\;\;\;0.91893853320467 + \left(z \cdot z\right) \cdot \frac{y + 0.0007936500793651}{x}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -3.20000000000000018e-31 or 2.8e-117 < z

    1. Initial program 83.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. Step-by-step derivation
      1. +-commutative83.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto 0.91893853320467 + \color{blue}{\left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right) \cdot {z}^{2}} \]
      2. associate-*r/65.6%

        \[\leadsto 0.91893853320467 + \left(\color{blue}{\frac{0.0007936500793651 \cdot 1}{x}} + \frac{y}{x}\right) \cdot {z}^{2} \]
      3. metadata-eval65.6%

        \[\leadsto 0.91893853320467 + \left(\frac{\color{blue}{0.0007936500793651}}{x} + \frac{y}{x}\right) \cdot {z}^{2} \]
      4. unpow265.6%

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

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

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

    if -3.20000000000000018e-31 < z < 2.8e-117

    1. Initial program 99.4%

      \[\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. Step-by-step derivation
      1. +-commutative99.4%

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \frac{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), 0.083333333333333\right)}{x} - x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in z around 0 97.2%

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

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

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

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

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

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

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

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

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

Alternative 17: 60.4% accurate, 5.8× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -3.2 \cdot 10^{-33}:\\
\;\;\;\;0.91893853320467 + \left(z \cdot z\right) \cdot \frac{y + 0.0007936500793651}{x}\\

\mathbf{elif}\;z \leq 2.8 \cdot 10^{-117}:\\
\;\;\;\;\frac{0.083333333333333 + x \cdot 0.91893853320467}{x}\\

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


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

    1. Initial program 85.1%

      \[\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. Step-by-step derivation
      1. +-commutative85.1%

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

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto 0.91893853320467 + \color{blue}{{z}^{2} \cdot \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)} \]
    6. Step-by-step derivation
      1. *-commutative68.7%

        \[\leadsto 0.91893853320467 + \color{blue}{\left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right) \cdot {z}^{2}} \]
      2. associate-*r/68.7%

        \[\leadsto 0.91893853320467 + \left(\color{blue}{\frac{0.0007936500793651 \cdot 1}{x}} + \frac{y}{x}\right) \cdot {z}^{2} \]
      3. metadata-eval68.7%

        \[\leadsto 0.91893853320467 + \left(\frac{\color{blue}{0.0007936500793651}}{x} + \frac{y}{x}\right) \cdot {z}^{2} \]
      4. unpow268.7%

        \[\leadsto 0.91893853320467 + \left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot \color{blue}{\left(z \cdot z\right)} \]
    7. Simplified68.7%

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

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

    if -3.19999999999999977e-33 < z < 2.8e-117

    1. Initial program 99.4%

      \[\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. Step-by-step derivation
      1. +-commutative99.4%

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \frac{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), 0.083333333333333\right)}{x} - x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in z around 0 97.2%

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{\frac{0.083333333333333 + 0.91893853320467 \cdot x}{x}} \]

    if 2.8e-117 < z

    1. Initial program 82.8%

      \[\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. Step-by-step derivation
      1. +-commutative82.8%

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

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto 0.91893853320467 + \color{blue}{{z}^{2} \cdot \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)} \]
    6. Step-by-step derivation
      1. *-commutative62.4%

        \[\leadsto 0.91893853320467 + \color{blue}{\left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right) \cdot {z}^{2}} \]
      2. associate-*r/62.4%

        \[\leadsto 0.91893853320467 + \left(\color{blue}{\frac{0.0007936500793651 \cdot 1}{x}} + \frac{y}{x}\right) \cdot {z}^{2} \]
      3. metadata-eval62.4%

        \[\leadsto 0.91893853320467 + \left(\frac{\color{blue}{0.0007936500793651}}{x} + \frac{y}{x}\right) \cdot {z}^{2} \]
      4. unpow262.4%

        \[\leadsto 0.91893853320467 + \left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot \color{blue}{\left(z \cdot z\right)} \]
    7. Simplified62.4%

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

        \[\leadsto \color{blue}{\left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot \left(z \cdot z\right) + 0.91893853320467} \]
      2. associate-*r*64.6%

        \[\leadsto \color{blue}{\left(\left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot z\right) \cdot z} + 0.91893853320467 \]
      3. div-inv64.5%

        \[\leadsto \left(\left(\color{blue}{0.0007936500793651 \cdot \frac{1}{x}} + \frac{y}{x}\right) \cdot z\right) \cdot z + 0.91893853320467 \]
      4. *-commutative64.5%

        \[\leadsto \color{blue}{\left(z \cdot \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)\right)} \cdot z + 0.91893853320467 \]
      5. div-inv64.6%

        \[\leadsto \left(z \cdot \left(\color{blue}{\frac{0.0007936500793651}{x}} + \frac{y}{x}\right)\right) \cdot z + 0.91893853320467 \]
      6. distribute-lft-in63.3%

        \[\leadsto \color{blue}{\left(z \cdot \frac{0.0007936500793651}{x} + z \cdot \frac{y}{x}\right)} \cdot z + 0.91893853320467 \]
    9. Applied egg-rr63.3%

      \[\leadsto \color{blue}{\left(z \cdot \frac{0.0007936500793651}{x} + z \cdot \frac{y}{x}\right) \cdot z + 0.91893853320467} \]
    10. Taylor expanded in z around 0 64.5%

      \[\leadsto \color{blue}{\left(z \cdot \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)\right)} \cdot z + 0.91893853320467 \]
    11. Step-by-step derivation
      1. +-commutative64.5%

        \[\leadsto \left(z \cdot \color{blue}{\left(\frac{y}{x} + 0.0007936500793651 \cdot \frac{1}{x}\right)}\right) \cdot z + 0.91893853320467 \]
      2. distribute-rgt-in63.3%

        \[\leadsto \color{blue}{\left(\frac{y}{x} \cdot z + \left(0.0007936500793651 \cdot \frac{1}{x}\right) \cdot z\right)} \cdot z + 0.91893853320467 \]
      3. associate-*l/63.2%

        \[\leadsto \left(\color{blue}{\frac{y \cdot z}{x}} + \left(0.0007936500793651 \cdot \frac{1}{x}\right) \cdot z\right) \cdot z + 0.91893853320467 \]
      4. associate-/l*63.3%

        \[\leadsto \left(\color{blue}{y \cdot \frac{z}{x}} + \left(0.0007936500793651 \cdot \frac{1}{x}\right) \cdot z\right) \cdot z + 0.91893853320467 \]
      5. associate-*r/63.3%

        \[\leadsto \left(y \cdot \frac{z}{x} + \color{blue}{\frac{0.0007936500793651 \cdot 1}{x}} \cdot z\right) \cdot z + 0.91893853320467 \]
      6. metadata-eval63.3%

        \[\leadsto \left(y \cdot \frac{z}{x} + \frac{\color{blue}{0.0007936500793651}}{x} \cdot z\right) \cdot z + 0.91893853320467 \]
      7. associate-*l/63.3%

        \[\leadsto \left(y \cdot \frac{z}{x} + \color{blue}{\frac{0.0007936500793651 \cdot z}{x}}\right) \cdot z + 0.91893853320467 \]
      8. associate-*r/62.1%

        \[\leadsto \left(y \cdot \frac{z}{x} + \color{blue}{0.0007936500793651 \cdot \frac{z}{x}}\right) \cdot z + 0.91893853320467 \]
      9. distribute-rgt-out64.5%

        \[\leadsto \color{blue}{\left(\frac{z}{x} \cdot \left(y + 0.0007936500793651\right)\right)} \cdot z + 0.91893853320467 \]
    12. Simplified64.5%

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

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

Alternative 18: 66.5% accurate, 6.1× speedup?

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

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

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


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

    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. Step-by-step derivation
      1. +-commutative99.7%

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \frac{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), 0.083333333333333\right)}{x} - x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in x around 0 98.4%

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

    if 5.8e9 < x

    1. Initial program 79.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. Step-by-step derivation
      1. +-commutative79.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto 0.91893853320467 + \color{blue}{\left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right) \cdot {z}^{2}} \]
      2. associate-*r/33.2%

        \[\leadsto 0.91893853320467 + \left(\color{blue}{\frac{0.0007936500793651 \cdot 1}{x}} + \frac{y}{x}\right) \cdot {z}^{2} \]
      3. metadata-eval33.2%

        \[\leadsto 0.91893853320467 + \left(\frac{\color{blue}{0.0007936500793651}}{x} + \frac{y}{x}\right) \cdot {z}^{2} \]
      4. unpow233.2%

        \[\leadsto 0.91893853320467 + \left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot \color{blue}{\left(z \cdot z\right)} \]
    7. Simplified33.2%

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

        \[\leadsto \color{blue}{\left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot \left(z \cdot z\right) + 0.91893853320467} \]
      2. associate-*r*34.5%

        \[\leadsto \color{blue}{\left(\left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot z\right) \cdot z} + 0.91893853320467 \]
      3. div-inv34.5%

        \[\leadsto \left(\left(\color{blue}{0.0007936500793651 \cdot \frac{1}{x}} + \frac{y}{x}\right) \cdot z\right) \cdot z + 0.91893853320467 \]
      4. *-commutative34.5%

        \[\leadsto \color{blue}{\left(z \cdot \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)\right)} \cdot z + 0.91893853320467 \]
      5. div-inv34.5%

        \[\leadsto \left(z \cdot \left(\color{blue}{\frac{0.0007936500793651}{x}} + \frac{y}{x}\right)\right) \cdot z + 0.91893853320467 \]
      6. distribute-lft-in34.5%

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

      \[\leadsto \color{blue}{\left(z \cdot \frac{0.0007936500793651}{x} + z \cdot \frac{y}{x}\right) \cdot z + 0.91893853320467} \]
    10. Taylor expanded in z around 0 34.5%

      \[\leadsto \color{blue}{\left(z \cdot \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)\right)} \cdot z + 0.91893853320467 \]
    11. Step-by-step derivation
      1. +-commutative34.5%

        \[\leadsto \left(z \cdot \color{blue}{\left(\frac{y}{x} + 0.0007936500793651 \cdot \frac{1}{x}\right)}\right) \cdot z + 0.91893853320467 \]
      2. distribute-rgt-in34.5%

        \[\leadsto \color{blue}{\left(\frac{y}{x} \cdot z + \left(0.0007936500793651 \cdot \frac{1}{x}\right) \cdot z\right)} \cdot z + 0.91893853320467 \]
      3. associate-*l/31.3%

        \[\leadsto \left(\color{blue}{\frac{y \cdot z}{x}} + \left(0.0007936500793651 \cdot \frac{1}{x}\right) \cdot z\right) \cdot z + 0.91893853320467 \]
      4. associate-/l*34.5%

        \[\leadsto \left(\color{blue}{y \cdot \frac{z}{x}} + \left(0.0007936500793651 \cdot \frac{1}{x}\right) \cdot z\right) \cdot z + 0.91893853320467 \]
      5. associate-*r/34.5%

        \[\leadsto \left(y \cdot \frac{z}{x} + \color{blue}{\frac{0.0007936500793651 \cdot 1}{x}} \cdot z\right) \cdot z + 0.91893853320467 \]
      6. metadata-eval34.5%

        \[\leadsto \left(y \cdot \frac{z}{x} + \frac{\color{blue}{0.0007936500793651}}{x} \cdot z\right) \cdot z + 0.91893853320467 \]
      7. associate-*l/34.5%

        \[\leadsto \left(y \cdot \frac{z}{x} + \color{blue}{\frac{0.0007936500793651 \cdot z}{x}}\right) \cdot z + 0.91893853320467 \]
      8. associate-*r/34.5%

        \[\leadsto \left(y \cdot \frac{z}{x} + \color{blue}{0.0007936500793651 \cdot \frac{z}{x}}\right) \cdot z + 0.91893853320467 \]
      9. distribute-rgt-out34.5%

        \[\leadsto \color{blue}{\left(\frac{z}{x} \cdot \left(y + 0.0007936500793651\right)\right)} \cdot z + 0.91893853320467 \]
    12. Simplified34.5%

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

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

Alternative 19: 44.9% accurate, 6.5× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -0.72 \lor \neg \left(z \leq 2.8 \cdot 10^{-117}\right):\\
\;\;\;\;0.91893853320467 + 0.0007936500793651 \cdot \frac{z \cdot z}{x}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -0.71999999999999997 or 2.8e-117 < z

    1. Initial program 83.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. Step-by-step derivation
      1. +-commutative83.3%

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

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto 0.91893853320467 + \color{blue}{{z}^{2} \cdot \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)} \]
    6. Step-by-step derivation
      1. *-commutative66.4%

        \[\leadsto 0.91893853320467 + \color{blue}{\left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right) \cdot {z}^{2}} \]
      2. associate-*r/66.4%

        \[\leadsto 0.91893853320467 + \left(\color{blue}{\frac{0.0007936500793651 \cdot 1}{x}} + \frac{y}{x}\right) \cdot {z}^{2} \]
      3. metadata-eval66.4%

        \[\leadsto 0.91893853320467 + \left(\frac{\color{blue}{0.0007936500793651}}{x} + \frac{y}{x}\right) \cdot {z}^{2} \]
      4. unpow266.4%

        \[\leadsto 0.91893853320467 + \left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot \color{blue}{\left(z \cdot z\right)} \]
    7. Simplified66.4%

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

      \[\leadsto 0.91893853320467 + \color{blue}{0.0007936500793651 \cdot \frac{{z}^{2}}{x}} \]
    9. Step-by-step derivation
      1. unpow241.2%

        \[\leadsto 0.91893853320467 + 0.0007936500793651 \cdot \frac{\color{blue}{z \cdot z}}{x} \]
    10. Simplified41.2%

      \[\leadsto 0.91893853320467 + \color{blue}{0.0007936500793651 \cdot \frac{z \cdot z}{x}} \]

    if -0.71999999999999997 < z < 2.8e-117

    1. Initial program 99.4%

      \[\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. Step-by-step derivation
      1. +-commutative99.4%

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \frac{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), 0.083333333333333\right)}{x} - x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in z around 0 94.4%

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

      \[\leadsto 0.91893853320467 + \left(\left(0.083333333333333 \cdot \frac{1}{x} + \color{blue}{-1 \cdot \left(x \cdot \log \left(\frac{1}{x}\right)\right)}\right) - x\right) \]
    7. Step-by-step derivation
      1. mul-1-neg93.3%

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

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

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

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

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

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

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

Alternative 20: 44.9% accurate, 6.5× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -0.72:\\
\;\;\;\;0.91893853320467 + 0.0007936500793651 \cdot \frac{z \cdot z}{x}\\

\mathbf{elif}\;z \leq 2.8 \cdot 10^{-117}:\\
\;\;\;\;\frac{0.083333333333333 + x \cdot 0.91893853320467}{x}\\

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


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

    1. Initial program 83.8%

      \[\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. Step-by-step derivation
      1. +-commutative83.8%

        \[\leadsto \color{blue}{\left(0.91893853320467 + \left(\left(x - 0.5\right) \cdot \log x - x\right)\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      2. associate-+l+83.8%

        \[\leadsto \color{blue}{0.91893853320467 + \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)} \]
      3. associate-+l-83.8%

        \[\leadsto 0.91893853320467 + \color{blue}{\left(\left(x - 0.5\right) \cdot \log x - \left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)\right)} \]
      4. fma-neg83.8%

        \[\leadsto 0.91893853320467 + \color{blue}{\mathsf{fma}\left(x - 0.5, \log x, -\left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)\right)} \]
      5. sub-neg83.8%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(\color{blue}{x + \left(-0.5\right)}, \log x, -\left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)\right) \]
      6. metadata-eval83.8%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + \color{blue}{-0.5}, \log x, -\left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)\right) \]
      7. neg-sub083.8%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{0 - \left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)}\right) \]
      8. associate-+l-83.8%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{\left(0 - x\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}}\right) \]
      9. neg-sub083.8%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right) \]
      10. +-commutative83.8%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{\frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} + \left(-x\right)}\right) \]
      11. unsub-neg83.8%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{\frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} - x}\right) \]
    3. Simplified83.8%

      \[\leadsto \color{blue}{0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \frac{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), 0.083333333333333\right)}{x} - x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in z around inf 70.8%

      \[\leadsto 0.91893853320467 + \color{blue}{{z}^{2} \cdot \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)} \]
    6. Step-by-step derivation
      1. *-commutative70.8%

        \[\leadsto 0.91893853320467 + \color{blue}{\left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right) \cdot {z}^{2}} \]
      2. associate-*r/70.8%

        \[\leadsto 0.91893853320467 + \left(\color{blue}{\frac{0.0007936500793651 \cdot 1}{x}} + \frac{y}{x}\right) \cdot {z}^{2} \]
      3. metadata-eval70.8%

        \[\leadsto 0.91893853320467 + \left(\frac{\color{blue}{0.0007936500793651}}{x} + \frac{y}{x}\right) \cdot {z}^{2} \]
      4. unpow270.8%

        \[\leadsto 0.91893853320467 + \left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot \color{blue}{\left(z \cdot z\right)} \]
    7. Simplified70.8%

      \[\leadsto 0.91893853320467 + \color{blue}{\left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot \left(z \cdot z\right)} \]
    8. Taylor expanded in y around 0 40.4%

      \[\leadsto 0.91893853320467 + \color{blue}{0.0007936500793651 \cdot \frac{{z}^{2}}{x}} \]
    9. Step-by-step derivation
      1. unpow240.4%

        \[\leadsto 0.91893853320467 + 0.0007936500793651 \cdot \frac{\color{blue}{z \cdot z}}{x} \]
    10. Simplified40.4%

      \[\leadsto 0.91893853320467 + \color{blue}{0.0007936500793651 \cdot \frac{z \cdot z}{x}} \]

    if -0.71999999999999997 < z < 2.8e-117

    1. Initial program 99.4%

      \[\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. Step-by-step derivation
      1. +-commutative99.4%

        \[\leadsto \color{blue}{\left(0.91893853320467 + \left(\left(x - 0.5\right) \cdot \log x - x\right)\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      2. associate-+l+99.4%

        \[\leadsto \color{blue}{0.91893853320467 + \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)} \]
      3. associate-+l-99.4%

        \[\leadsto 0.91893853320467 + \color{blue}{\left(\left(x - 0.5\right) \cdot \log x - \left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)\right)} \]
      4. fma-neg99.5%

        \[\leadsto 0.91893853320467 + \color{blue}{\mathsf{fma}\left(x - 0.5, \log x, -\left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)\right)} \]
      5. sub-neg99.5%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(\color{blue}{x + \left(-0.5\right)}, \log x, -\left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)\right) \]
      6. metadata-eval99.5%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + \color{blue}{-0.5}, \log x, -\left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)\right) \]
      7. neg-sub099.5%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{0 - \left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)}\right) \]
      8. associate-+l-99.5%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{\left(0 - x\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}}\right) \]
      9. neg-sub099.5%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right) \]
      10. +-commutative99.5%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{\frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} + \left(-x\right)}\right) \]
      11. unsub-neg99.5%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{\frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} - x}\right) \]
    3. Simplified99.5%

      \[\leadsto \color{blue}{0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \frac{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), 0.083333333333333\right)}{x} - x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in z around 0 94.4%

      \[\leadsto 0.91893853320467 + \color{blue}{\left(\left(0.083333333333333 \cdot \frac{1}{x} + \log x \cdot \left(x - 0.5\right)\right) - x\right)} \]
    6. Taylor expanded in x around inf 93.3%

      \[\leadsto 0.91893853320467 + \left(\left(0.083333333333333 \cdot \frac{1}{x} + \color{blue}{-1 \cdot \left(x \cdot \log \left(\frac{1}{x}\right)\right)}\right) - x\right) \]
    7. Step-by-step derivation
      1. mul-1-neg93.3%

        \[\leadsto 0.91893853320467 + \left(\left(0.083333333333333 \cdot \frac{1}{x} + \color{blue}{\left(-x \cdot \log \left(\frac{1}{x}\right)\right)}\right) - x\right) \]
      2. distribute-rgt-neg-in93.3%

        \[\leadsto 0.91893853320467 + \left(\left(0.083333333333333 \cdot \frac{1}{x} + \color{blue}{x \cdot \left(-\log \left(\frac{1}{x}\right)\right)}\right) - x\right) \]
      3. log-rec93.3%

        \[\leadsto 0.91893853320467 + \left(\left(0.083333333333333 \cdot \frac{1}{x} + x \cdot \left(-\color{blue}{\left(-\log x\right)}\right)\right) - x\right) \]
      4. remove-double-neg93.3%

        \[\leadsto 0.91893853320467 + \left(\left(0.083333333333333 \cdot \frac{1}{x} + x \cdot \color{blue}{\log x}\right) - x\right) \]
    8. Simplified93.3%

      \[\leadsto 0.91893853320467 + \left(\left(0.083333333333333 \cdot \frac{1}{x} + \color{blue}{x \cdot \log x}\right) - x\right) \]
    9. Taylor expanded in x around 0 54.0%

      \[\leadsto \color{blue}{\frac{0.083333333333333 + 0.91893853320467 \cdot x}{x}} \]

    if 2.8e-117 < z

    1. Initial program 82.8%

      \[\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. Step-by-step derivation
      1. +-commutative82.8%

        \[\leadsto \color{blue}{\left(0.91893853320467 + \left(\left(x - 0.5\right) \cdot \log x - x\right)\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
      2. associate-+l+82.8%

        \[\leadsto \color{blue}{0.91893853320467 + \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)} \]
      3. associate-+l-82.8%

        \[\leadsto 0.91893853320467 + \color{blue}{\left(\left(x - 0.5\right) \cdot \log x - \left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)\right)} \]
      4. fma-neg82.7%

        \[\leadsto 0.91893853320467 + \color{blue}{\mathsf{fma}\left(x - 0.5, \log x, -\left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)\right)} \]
      5. sub-neg82.7%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(\color{blue}{x + \left(-0.5\right)}, \log x, -\left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)\right) \]
      6. metadata-eval82.7%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + \color{blue}{-0.5}, \log x, -\left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)\right) \]
      7. neg-sub082.7%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{0 - \left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)}\right) \]
      8. associate-+l-82.7%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{\left(0 - x\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}}\right) \]
      9. neg-sub082.7%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right) \]
      10. +-commutative82.7%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{\frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} + \left(-x\right)}\right) \]
      11. unsub-neg82.7%

        \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{\frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} - x}\right) \]
    3. Simplified82.7%

      \[\leadsto \color{blue}{0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \frac{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), 0.083333333333333\right)}{x} - x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in z around inf 62.4%

      \[\leadsto 0.91893853320467 + \color{blue}{{z}^{2} \cdot \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)} \]
    6. Step-by-step derivation
      1. *-commutative62.4%

        \[\leadsto 0.91893853320467 + \color{blue}{\left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right) \cdot {z}^{2}} \]
      2. associate-*r/62.4%

        \[\leadsto 0.91893853320467 + \left(\color{blue}{\frac{0.0007936500793651 \cdot 1}{x}} + \frac{y}{x}\right) \cdot {z}^{2} \]
      3. metadata-eval62.4%

        \[\leadsto 0.91893853320467 + \left(\frac{\color{blue}{0.0007936500793651}}{x} + \frac{y}{x}\right) \cdot {z}^{2} \]
      4. unpow262.4%

        \[\leadsto 0.91893853320467 + \left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot \color{blue}{\left(z \cdot z\right)} \]
    7. Simplified62.4%

      \[\leadsto 0.91893853320467 + \color{blue}{\left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot \left(z \cdot z\right)} \]
    8. Taylor expanded in y around 0 42.0%

      \[\leadsto 0.91893853320467 + \color{blue}{\frac{0.0007936500793651}{x}} \cdot \left(z \cdot z\right) \]
  3. Recombined 3 regimes into one program.
  4. Final simplification46.1%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -0.72:\\ \;\;\;\;0.91893853320467 + 0.0007936500793651 \cdot \frac{z \cdot z}{x}\\ \mathbf{elif}\;z \leq 2.8 \cdot 10^{-117}:\\ \;\;\;\;\frac{0.083333333333333 + x \cdot 0.91893853320467}{x}\\ \mathbf{else}:\\ \;\;\;\;0.91893853320467 + \frac{0.0007936500793651}{x} \cdot \left(z \cdot z\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 21: 24.4% accurate, 17.6× speedup?

\[\begin{array}{l} \\ \frac{0.083333333333333 + x \cdot 0.91893853320467}{x} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (/ (+ 0.083333333333333 (* x 0.91893853320467)) x))
double code(double x, double y, double z) {
	return (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 = (0.083333333333333d0 + (x * 0.91893853320467d0)) / x
end function
public static double code(double x, double y, double z) {
	return (0.083333333333333 + (x * 0.91893853320467)) / x;
}
def code(x, y, z):
	return (0.083333333333333 + (x * 0.91893853320467)) / x
function code(x, y, z)
	return Float64(Float64(0.083333333333333 + Float64(x * 0.91893853320467)) / x)
end
function tmp = code(x, y, z)
	tmp = (0.083333333333333 + (x * 0.91893853320467)) / x;
end
code[x_, y_, z_] := N[(N[(0.083333333333333 + N[(x * 0.91893853320467), $MachinePrecision]), $MachinePrecision] / x), $MachinePrecision]
\begin{array}{l}

\\
\frac{0.083333333333333 + x \cdot 0.91893853320467}{x}
\end{array}
Derivation
  1. Initial program 89.4%

    \[\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. Step-by-step derivation
    1. +-commutative89.4%

      \[\leadsto \color{blue}{\left(0.91893853320467 + \left(\left(x - 0.5\right) \cdot \log x - x\right)\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. associate-+l+89.4%

      \[\leadsto \color{blue}{0.91893853320467 + \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)} \]
    3. associate-+l-89.4%

      \[\leadsto 0.91893853320467 + \color{blue}{\left(\left(x - 0.5\right) \cdot \log x - \left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)\right)} \]
    4. fma-neg89.4%

      \[\leadsto 0.91893853320467 + \color{blue}{\mathsf{fma}\left(x - 0.5, \log x, -\left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)\right)} \]
    5. sub-neg89.4%

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(\color{blue}{x + \left(-0.5\right)}, \log x, -\left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)\right) \]
    6. metadata-eval89.4%

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + \color{blue}{-0.5}, \log x, -\left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)\right) \]
    7. neg-sub089.4%

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{0 - \left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)}\right) \]
    8. associate-+l-89.4%

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{\left(0 - x\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}}\right) \]
    9. neg-sub089.4%

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right) \]
    10. +-commutative89.4%

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{\frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} + \left(-x\right)}\right) \]
    11. unsub-neg89.4%

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{\frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} - x}\right) \]
  3. Simplified89.4%

    \[\leadsto \color{blue}{0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \frac{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), 0.083333333333333\right)}{x} - x\right)} \]
  4. Add Preprocessing
  5. Taylor expanded in z around 0 57.0%

    \[\leadsto 0.91893853320467 + \color{blue}{\left(\left(0.083333333333333 \cdot \frac{1}{x} + \log x \cdot \left(x - 0.5\right)\right) - x\right)} \]
  6. Taylor expanded in x around inf 56.6%

    \[\leadsto 0.91893853320467 + \left(\left(0.083333333333333 \cdot \frac{1}{x} + \color{blue}{-1 \cdot \left(x \cdot \log \left(\frac{1}{x}\right)\right)}\right) - x\right) \]
  7. Step-by-step derivation
    1. mul-1-neg56.6%

      \[\leadsto 0.91893853320467 + \left(\left(0.083333333333333 \cdot \frac{1}{x} + \color{blue}{\left(-x \cdot \log \left(\frac{1}{x}\right)\right)}\right) - x\right) \]
    2. distribute-rgt-neg-in56.6%

      \[\leadsto 0.91893853320467 + \left(\left(0.083333333333333 \cdot \frac{1}{x} + \color{blue}{x \cdot \left(-\log \left(\frac{1}{x}\right)\right)}\right) - x\right) \]
    3. log-rec56.6%

      \[\leadsto 0.91893853320467 + \left(\left(0.083333333333333 \cdot \frac{1}{x} + x \cdot \left(-\color{blue}{\left(-\log x\right)}\right)\right) - x\right) \]
    4. remove-double-neg56.6%

      \[\leadsto 0.91893853320467 + \left(\left(0.083333333333333 \cdot \frac{1}{x} + x \cdot \color{blue}{\log x}\right) - x\right) \]
  8. Simplified56.6%

    \[\leadsto 0.91893853320467 + \left(\left(0.083333333333333 \cdot \frac{1}{x} + \color{blue}{x \cdot \log x}\right) - x\right) \]
  9. Taylor expanded in x around 0 22.9%

    \[\leadsto \color{blue}{\frac{0.083333333333333 + 0.91893853320467 \cdot x}{x}} \]
  10. Final simplification22.9%

    \[\leadsto \frac{0.083333333333333 + x \cdot 0.91893853320467}{x} \]
  11. Add Preprocessing

Alternative 22: 24.4% accurate, 24.6× speedup?

\[\begin{array}{l} \\ 0.91893853320467 + \frac{0.083333333333333}{x} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (+ 0.91893853320467 (/ 0.083333333333333 x)))
double code(double x, double y, double z) {
	return 0.91893853320467 + (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.91893853320467d0 + (0.083333333333333d0 / x)
end function
public static double code(double x, double y, double z) {
	return 0.91893853320467 + (0.083333333333333 / x);
}
def code(x, y, z):
	return 0.91893853320467 + (0.083333333333333 / x)
function code(x, y, z)
	return Float64(0.91893853320467 + Float64(0.083333333333333 / x))
end
function tmp = code(x, y, z)
	tmp = 0.91893853320467 + (0.083333333333333 / x);
end
code[x_, y_, z_] := N[(0.91893853320467 + N[(0.083333333333333 / x), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
0.91893853320467 + \frac{0.083333333333333}{x}
\end{array}
Derivation
  1. Initial program 89.4%

    \[\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. Step-by-step derivation
    1. +-commutative89.4%

      \[\leadsto \color{blue}{\left(0.91893853320467 + \left(\left(x - 0.5\right) \cdot \log x - x\right)\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. associate-+l+89.4%

      \[\leadsto \color{blue}{0.91893853320467 + \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)} \]
    3. associate-+l-89.4%

      \[\leadsto 0.91893853320467 + \color{blue}{\left(\left(x - 0.5\right) \cdot \log x - \left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)\right)} \]
    4. fma-neg89.4%

      \[\leadsto 0.91893853320467 + \color{blue}{\mathsf{fma}\left(x - 0.5, \log x, -\left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)\right)} \]
    5. sub-neg89.4%

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(\color{blue}{x + \left(-0.5\right)}, \log x, -\left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)\right) \]
    6. metadata-eval89.4%

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + \color{blue}{-0.5}, \log x, -\left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)\right) \]
    7. neg-sub089.4%

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{0 - \left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)}\right) \]
    8. associate-+l-89.4%

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{\left(0 - x\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}}\right) \]
    9. neg-sub089.4%

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right) \]
    10. +-commutative89.4%

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{\frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} + \left(-x\right)}\right) \]
    11. unsub-neg89.4%

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{\frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} - x}\right) \]
  3. Simplified89.4%

    \[\leadsto \color{blue}{0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \frac{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), 0.083333333333333\right)}{x} - x\right)} \]
  4. Add Preprocessing
  5. Taylor expanded in z around 0 57.0%

    \[\leadsto 0.91893853320467 + \color{blue}{\left(\left(0.083333333333333 \cdot \frac{1}{x} + \log x \cdot \left(x - 0.5\right)\right) - x\right)} \]
  6. Taylor expanded in x around 0 22.9%

    \[\leadsto 0.91893853320467 + \color{blue}{\frac{0.083333333333333}{x}} \]
  7. Add Preprocessing

Alternative 23: 23.8% 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 89.4%

    \[\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. Step-by-step derivation
    1. +-commutative89.4%

      \[\leadsto \color{blue}{\left(0.91893853320467 + \left(\left(x - 0.5\right) \cdot \log x - x\right)\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. associate-+l+89.4%

      \[\leadsto \color{blue}{0.91893853320467 + \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)} \]
    3. associate-+l-89.4%

      \[\leadsto 0.91893853320467 + \color{blue}{\left(\left(x - 0.5\right) \cdot \log x - \left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)\right)} \]
    4. fma-neg89.4%

      \[\leadsto 0.91893853320467 + \color{blue}{\mathsf{fma}\left(x - 0.5, \log x, -\left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)\right)} \]
    5. sub-neg89.4%

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(\color{blue}{x + \left(-0.5\right)}, \log x, -\left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)\right) \]
    6. metadata-eval89.4%

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + \color{blue}{-0.5}, \log x, -\left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)\right) \]
    7. neg-sub089.4%

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{0 - \left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)}\right) \]
    8. associate-+l-89.4%

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{\left(0 - x\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}}\right) \]
    9. neg-sub089.4%

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right) \]
    10. +-commutative89.4%

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{\frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} + \left(-x\right)}\right) \]
    11. unsub-neg89.4%

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{\frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} - x}\right) \]
  3. Simplified89.4%

    \[\leadsto \color{blue}{0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \frac{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), 0.083333333333333\right)}{x} - x\right)} \]
  4. Add Preprocessing
  5. Taylor expanded in z around 0 57.0%

    \[\leadsto 0.91893853320467 + \color{blue}{\left(\left(0.083333333333333 \cdot \frac{1}{x} + \log x \cdot \left(x - 0.5\right)\right) - x\right)} \]
  6. Taylor expanded in x around 0 22.2%

    \[\leadsto \color{blue}{\frac{0.083333333333333}{x}} \]
  7. Add Preprocessing

Alternative 24: 4.1% accurate, 123.0× speedup?

\[\begin{array}{l} \\ 0.91893853320467 \end{array} \]
(FPCore (x y z) :precision binary64 0.91893853320467)
double code(double x, double y, double z) {
	return 0.91893853320467;
}
real(8) function code(x, y, z)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    code = 0.91893853320467d0
end function
public static double code(double x, double y, double z) {
	return 0.91893853320467;
}
def code(x, y, z):
	return 0.91893853320467
function code(x, y, z)
	return 0.91893853320467
end
function tmp = code(x, y, z)
	tmp = 0.91893853320467;
end
code[x_, y_, z_] := 0.91893853320467
\begin{array}{l}

\\
0.91893853320467
\end{array}
Derivation
  1. Initial program 89.4%

    \[\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. Step-by-step derivation
    1. +-commutative89.4%

      \[\leadsto \color{blue}{\left(0.91893853320467 + \left(\left(x - 0.5\right) \cdot \log x - x\right)\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} \]
    2. associate-+l+89.4%

      \[\leadsto \color{blue}{0.91893853320467 + \left(\left(\left(x - 0.5\right) \cdot \log x - x\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)} \]
    3. associate-+l-89.4%

      \[\leadsto 0.91893853320467 + \color{blue}{\left(\left(x - 0.5\right) \cdot \log x - \left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)\right)} \]
    4. fma-neg89.4%

      \[\leadsto 0.91893853320467 + \color{blue}{\mathsf{fma}\left(x - 0.5, \log x, -\left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)\right)} \]
    5. sub-neg89.4%

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(\color{blue}{x + \left(-0.5\right)}, \log x, -\left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)\right) \]
    6. metadata-eval89.4%

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + \color{blue}{-0.5}, \log x, -\left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)\right) \]
    7. neg-sub089.4%

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{0 - \left(x - \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right)}\right) \]
    8. associate-+l-89.4%

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{\left(0 - x\right) + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}}\right) \]
    9. neg-sub089.4%

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{\left(-x\right)} + \frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x}\right) \]
    10. +-commutative89.4%

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{\frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} + \left(-x\right)}\right) \]
    11. unsub-neg89.4%

      \[\leadsto 0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \color{blue}{\frac{\left(\left(y + 0.0007936500793651\right) \cdot z - 0.0027777777777778\right) \cdot z + 0.083333333333333}{x} - x}\right) \]
  3. Simplified89.4%

    \[\leadsto \color{blue}{0.91893853320467 + \mathsf{fma}\left(x + -0.5, \log x, \frac{\mathsf{fma}\left(z, \mathsf{fma}\left(y + 0.0007936500793651, z, -0.0027777777777778\right), 0.083333333333333\right)}{x} - x\right)} \]
  4. Add Preprocessing
  5. Taylor expanded in z around inf 45.0%

    \[\leadsto 0.91893853320467 + \color{blue}{{z}^{2} \cdot \left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right)} \]
  6. Step-by-step derivation
    1. *-commutative45.0%

      \[\leadsto 0.91893853320467 + \color{blue}{\left(0.0007936500793651 \cdot \frac{1}{x} + \frac{y}{x}\right) \cdot {z}^{2}} \]
    2. associate-*r/45.0%

      \[\leadsto 0.91893853320467 + \left(\color{blue}{\frac{0.0007936500793651 \cdot 1}{x}} + \frac{y}{x}\right) \cdot {z}^{2} \]
    3. metadata-eval45.0%

      \[\leadsto 0.91893853320467 + \left(\frac{\color{blue}{0.0007936500793651}}{x} + \frac{y}{x}\right) \cdot {z}^{2} \]
    4. unpow245.0%

      \[\leadsto 0.91893853320467 + \left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot \color{blue}{\left(z \cdot z\right)} \]
  7. Simplified45.0%

    \[\leadsto 0.91893853320467 + \color{blue}{\left(\frac{0.0007936500793651}{x} + \frac{y}{x}\right) \cdot \left(z \cdot z\right)} \]
  8. Taylor expanded in x around inf 3.9%

    \[\leadsto \color{blue}{0.91893853320467} \]
  9. Add Preprocessing

Developer target: 98.7% 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 2024097 
(FPCore (x y z)
  :name "Numeric.SpecFunctions:$slogFactorial from math-functions-0.1.5.2, B"
  :precision binary64

  :alt
  (+ (+ (+ (* (- 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)))