Numeric.SpecFunctions:logGamma from math-functions-0.1.5.2, B

Percentage Accurate: 69.3% → 99.7%
Time: 11.6s
Alternatives: 20
Speedup: 1.4×

Specification

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

\\
x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}
\end{array}

Sampling outcomes in binary64 precision:

Local Percentage Accuracy vs ?

The average percentage accuracy by input value. Horizontal axis shows value of an input variable; the variable is choosen in the title. Vertical axis is accuracy; higher is better. Red represent the original program, while blue represents Herbie's suggestion. These can be toggled with buttons below the plot. The line is an average while dots represent individual samples.

Accuracy vs Speed?

Herbie found 20 alternatives:

AlternativeAccuracySpeedup
The accuracy (vertical axis) and speed (horizontal axis) of each alternatives. Up and to the right is better. The red square shows the initial program, and each blue circle shows an alternative.The line shows the best available speed-accuracy tradeoffs.

Initial Program: 69.3% accurate, 1.0× speedup?

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

\\
x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}
\end{array}

Alternative 1: 99.7% accurate, 0.1× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;\frac{y \cdot \left(z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) + 0.279195317918525\right)}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304} \leq \infty:\\ \;\;\;\;x + y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\mathsf{fma}\left(z + 6.012459259764103, z, 3.350343815022304\right)}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{14.431876219268936}\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (if (<=
      (/
       (*
        y
        (+
         (* z (+ (* z 0.0692910599291889) 0.4917317610505968))
         0.279195317918525))
       (+ (* z (+ z 6.012459259764103)) 3.350343815022304))
      INFINITY)
   (+
    x
    (*
     y
     (/
      (fma (fma z 0.0692910599291889 0.4917317610505968) z 0.279195317918525)
      (fma (+ z 6.012459259764103) z 3.350343815022304))))
   (+ x (/ y 14.431876219268936))))
double code(double x, double y, double z) {
	double tmp;
	if (((y * ((z * ((z * 0.0692910599291889) + 0.4917317610505968)) + 0.279195317918525)) / ((z * (z + 6.012459259764103)) + 3.350343815022304)) <= ((double) INFINITY)) {
		tmp = x + (y * (fma(fma(z, 0.0692910599291889, 0.4917317610505968), z, 0.279195317918525) / fma((z + 6.012459259764103), z, 3.350343815022304)));
	} else {
		tmp = x + (y / 14.431876219268936);
	}
	return tmp;
}
function code(x, y, z)
	tmp = 0.0
	if (Float64(Float64(y * Float64(Float64(z * Float64(Float64(z * 0.0692910599291889) + 0.4917317610505968)) + 0.279195317918525)) / Float64(Float64(z * Float64(z + 6.012459259764103)) + 3.350343815022304)) <= Inf)
		tmp = Float64(x + Float64(y * Float64(fma(fma(z, 0.0692910599291889, 0.4917317610505968), z, 0.279195317918525) / fma(Float64(z + 6.012459259764103), z, 3.350343815022304))));
	else
		tmp = Float64(x + Float64(y / 14.431876219268936));
	end
	return tmp
end
code[x_, y_, z_] := If[LessEqual[N[(N[(y * N[(N[(z * N[(N[(z * 0.0692910599291889), $MachinePrecision] + 0.4917317610505968), $MachinePrecision]), $MachinePrecision] + 0.279195317918525), $MachinePrecision]), $MachinePrecision] / N[(N[(z * N[(z + 6.012459259764103), $MachinePrecision]), $MachinePrecision] + 3.350343815022304), $MachinePrecision]), $MachinePrecision], Infinity], N[(x + N[(y * N[(N[(N[(z * 0.0692910599291889 + 0.4917317610505968), $MachinePrecision] * z + 0.279195317918525), $MachinePrecision] / N[(N[(z + 6.012459259764103), $MachinePrecision] * z + 3.350343815022304), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(y / 14.431876219268936), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;\frac{y \cdot \left(z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) + 0.279195317918525\right)}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304} \leq \infty:\\
\;\;\;\;x + y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\mathsf{fma}\left(z + 6.012459259764103, z, 3.350343815022304\right)}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (/.f64 (*.f64 y (+.f64 (*.f64 (+.f64 (*.f64 z #s(literal 692910599291889/10000000000000000 binary64)) #s(literal 307332350656623/625000000000000 binary64)) z) #s(literal 11167812716741/40000000000000 binary64))) (+.f64 (*.f64 (+.f64 z #s(literal 6012459259764103/1000000000000000 binary64)) z) #s(literal 104698244219447/31250000000000 binary64))) < +inf.0

    1. Initial program 93.3%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. remove-double-neg93.3%

        \[\leadsto x + \color{blue}{\left(-\left(-\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      2. associate-/l*99.7%

        \[\leadsto x + \left(-\left(-\color{blue}{y \cdot \frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}}\right)\right) \]
      3. distribute-rgt-neg-in99.7%

        \[\leadsto x + \left(-\color{blue}{y \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)}\right) \]
      4. distribute-lft-neg-in99.7%

        \[\leadsto x + \color{blue}{\left(-y\right) \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)} \]
      5. distribute-lft-neg-in99.7%

        \[\leadsto x + \color{blue}{\left(-y \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      6. distribute-rgt-neg-in99.7%

        \[\leadsto x + \color{blue}{y \cdot \left(-\left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      7. remove-double-neg99.7%

        \[\leadsto x + y \cdot \color{blue}{\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} \]
      8. fma-define99.7%

        \[\leadsto x + y \cdot \frac{\color{blue}{\mathsf{fma}\left(z \cdot 0.0692910599291889 + 0.4917317610505968, z, 0.279195317918525\right)}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
      9. fma-define99.7%

        \[\leadsto x + y \cdot \frac{\mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
      10. fma-define99.7%

        \[\leadsto x + y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\color{blue}{\mathsf{fma}\left(z + 6.012459259764103, z, 3.350343815022304\right)}} \]
    3. Simplified99.7%

      \[\leadsto \color{blue}{x + y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\mathsf{fma}\left(z + 6.012459259764103, z, 3.350343815022304\right)}} \]
    4. Add Preprocessing

    if +inf.0 < (/.f64 (*.f64 y (+.f64 (*.f64 (+.f64 (*.f64 z #s(literal 692910599291889/10000000000000000 binary64)) #s(literal 307332350656623/625000000000000 binary64)) z) #s(literal 11167812716741/40000000000000 binary64))) (+.f64 (*.f64 (+.f64 z #s(literal 6012459259764103/1000000000000000 binary64)) z) #s(literal 104698244219447/31250000000000 binary64)))

    1. Initial program 0.0%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative0.0%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative0.0%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*0.0%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define0.0%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative0.0%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define0.0%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define0.0%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative0.0%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define0.0%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified0.0%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. fma-undefine0.0%

        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x} \]
      2. fma-undefine0.0%

        \[\leadsto \color{blue}{\left(z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) + 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      3. *-commutative0.0%

        \[\leadsto \left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z} + 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      4. fma-define0.0%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      5. fma-undefine0.0%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304}} + x \]
      6. *-commutative0.0%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{\left(z + 6.012459259764103\right) \cdot z} + 3.350343815022304} + x \]
      7. associate-*r/0.0%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      8. associate-*l/0.0%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \cdot y} + x \]
      9. *-commutative0.0%

        \[\leadsto \color{blue}{y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      10. clear-num0.0%

        \[\leadsto y \cdot \color{blue}{\frac{1}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      11. un-div-inv0.0%

        \[\leadsto \color{blue}{\frac{y}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      12. *-commutative0.0%

        \[\leadsto \frac{y}{\frac{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      13. fma-undefine0.0%

        \[\leadsto \frac{y}{\frac{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      14. fma-define0.0%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z + 0.279195317918525}}} + x \]
      15. *-commutative0.0%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)} + 0.279195317918525}} + x \]
      16. fma-undefine0.0%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}}} + x \]
    6. Applied egg-rr0.0%

      \[\leadsto \color{blue}{\frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}} + x} \]
    7. Taylor expanded in z around inf 99.9%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;\frac{y \cdot \left(z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) + 0.279195317918525\right)}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304} \leq \infty:\\ \;\;\;\;x + y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\mathsf{fma}\left(z + 6.012459259764103, z, 3.350343815022304\right)}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{14.431876219268936}\\ \end{array} \]
  5. Add Preprocessing

Alternative 2: 99.5% accurate, 0.1× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -6800:\\ \;\;\;\;x + \frac{y}{14.431876219268936 + \frac{\frac{101.23733352003822 + \frac{-655.3980091051341}{z}}{z} - 15.646356830292042}{z}}\\ \mathbf{elif}\;z \leq 2300:\\ \;\;\;\;x + \frac{y \cdot \left(z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) + 0.279195317918525\right)}{3.350343815022304 + \left(e^{\mathsf{log1p}\left(z \cdot \left(z + 6.012459259764103\right)\right)} + -1\right)}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{14.431876219268936}\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (if (<= z -6800.0)
   (+
    x
    (/
     y
     (+
      14.431876219268936
      (/
       (-
        (/ (+ 101.23733352003822 (/ -655.3980091051341 z)) z)
        15.646356830292042)
       z))))
   (if (<= z 2300.0)
     (+
      x
      (/
       (*
        y
        (+
         (* z (+ (* z 0.0692910599291889) 0.4917317610505968))
         0.279195317918525))
       (+
        3.350343815022304
        (+ (exp (log1p (* z (+ z 6.012459259764103)))) -1.0))))
     (+ x (/ y 14.431876219268936)))))
double code(double x, double y, double z) {
	double tmp;
	if (z <= -6800.0) {
		tmp = x + (y / (14.431876219268936 + ((((101.23733352003822 + (-655.3980091051341 / z)) / z) - 15.646356830292042) / z)));
	} else if (z <= 2300.0) {
		tmp = x + ((y * ((z * ((z * 0.0692910599291889) + 0.4917317610505968)) + 0.279195317918525)) / (3.350343815022304 + (exp(log1p((z * (z + 6.012459259764103)))) + -1.0)));
	} else {
		tmp = x + (y / 14.431876219268936);
	}
	return tmp;
}
public static double code(double x, double y, double z) {
	double tmp;
	if (z <= -6800.0) {
		tmp = x + (y / (14.431876219268936 + ((((101.23733352003822 + (-655.3980091051341 / z)) / z) - 15.646356830292042) / z)));
	} else if (z <= 2300.0) {
		tmp = x + ((y * ((z * ((z * 0.0692910599291889) + 0.4917317610505968)) + 0.279195317918525)) / (3.350343815022304 + (Math.exp(Math.log1p((z * (z + 6.012459259764103)))) + -1.0)));
	} else {
		tmp = x + (y / 14.431876219268936);
	}
	return tmp;
}
def code(x, y, z):
	tmp = 0
	if z <= -6800.0:
		tmp = x + (y / (14.431876219268936 + ((((101.23733352003822 + (-655.3980091051341 / z)) / z) - 15.646356830292042) / z)))
	elif z <= 2300.0:
		tmp = x + ((y * ((z * ((z * 0.0692910599291889) + 0.4917317610505968)) + 0.279195317918525)) / (3.350343815022304 + (math.exp(math.log1p((z * (z + 6.012459259764103)))) + -1.0)))
	else:
		tmp = x + (y / 14.431876219268936)
	return tmp
function code(x, y, z)
	tmp = 0.0
	if (z <= -6800.0)
		tmp = Float64(x + Float64(y / Float64(14.431876219268936 + Float64(Float64(Float64(Float64(101.23733352003822 + Float64(-655.3980091051341 / z)) / z) - 15.646356830292042) / z))));
	elseif (z <= 2300.0)
		tmp = Float64(x + Float64(Float64(y * Float64(Float64(z * Float64(Float64(z * 0.0692910599291889) + 0.4917317610505968)) + 0.279195317918525)) / Float64(3.350343815022304 + Float64(exp(log1p(Float64(z * Float64(z + 6.012459259764103)))) + -1.0))));
	else
		tmp = Float64(x + Float64(y / 14.431876219268936));
	end
	return tmp
end
code[x_, y_, z_] := If[LessEqual[z, -6800.0], N[(x + N[(y / N[(14.431876219268936 + N[(N[(N[(N[(101.23733352003822 + N[(-655.3980091051341 / z), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision] - 15.646356830292042), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2300.0], N[(x + N[(N[(y * N[(N[(z * N[(N[(z * 0.0692910599291889), $MachinePrecision] + 0.4917317610505968), $MachinePrecision]), $MachinePrecision] + 0.279195317918525), $MachinePrecision]), $MachinePrecision] / N[(3.350343815022304 + N[(N[Exp[N[Log[1 + N[(z * N[(z + 6.012459259764103), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision] + -1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(y / 14.431876219268936), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -6800:\\
\;\;\;\;x + \frac{y}{14.431876219268936 + \frac{\frac{101.23733352003822 + \frac{-655.3980091051341}{z}}{z} - 15.646356830292042}{z}}\\

\mathbf{elif}\;z \leq 2300:\\
\;\;\;\;x + \frac{y \cdot \left(z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) + 0.279195317918525\right)}{3.350343815022304 + \left(e^{\mathsf{log1p}\left(z \cdot \left(z + 6.012459259764103\right)\right)} + -1\right)}\\

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


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

    1. Initial program 42.7%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative42.7%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative42.7%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*50.7%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define50.7%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative50.7%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define50.7%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define50.7%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative50.7%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define50.7%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified50.7%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. fma-undefine50.7%

        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x} \]
      2. fma-undefine50.7%

        \[\leadsto \color{blue}{\left(z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) + 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      3. *-commutative50.7%

        \[\leadsto \left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z} + 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      4. fma-define50.7%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      5. fma-undefine50.7%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304}} + x \]
      6. *-commutative50.7%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{\left(z + 6.012459259764103\right) \cdot z} + 3.350343815022304} + x \]
      7. associate-*r/42.7%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      8. associate-*l/52.1%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \cdot y} + x \]
      9. *-commutative52.1%

        \[\leadsto \color{blue}{y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      10. clear-num52.1%

        \[\leadsto y \cdot \color{blue}{\frac{1}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      11. un-div-inv52.2%

        \[\leadsto \color{blue}{\frac{y}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      12. *-commutative52.2%

        \[\leadsto \frac{y}{\frac{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      13. fma-undefine52.2%

        \[\leadsto \frac{y}{\frac{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      14. fma-define52.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z + 0.279195317918525}}} + x \]
      15. *-commutative52.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)} + 0.279195317918525}} + x \]
      16. fma-undefine52.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}}} + x \]
    6. Applied egg-rr52.2%

      \[\leadsto \color{blue}{\frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}} + x} \]
    7. Taylor expanded in z around -inf 99.9%

      \[\leadsto \frac{y}{\color{blue}{14.431876219268936 + -1 \cdot \frac{15.646356830292042 + -1 \cdot \frac{101.23733352003822 - 655.3980091051341 \cdot \frac{1}{z}}{z}}{z}}} + x \]
    8. Step-by-step derivation
      1. mul-1-neg99.9%

        \[\leadsto \frac{y}{14.431876219268936 + \color{blue}{\left(-\frac{15.646356830292042 + -1 \cdot \frac{101.23733352003822 - 655.3980091051341 \cdot \frac{1}{z}}{z}}{z}\right)}} + x \]
      2. unsub-neg99.9%

        \[\leadsto \frac{y}{\color{blue}{14.431876219268936 - \frac{15.646356830292042 + -1 \cdot \frac{101.23733352003822 - 655.3980091051341 \cdot \frac{1}{z}}{z}}{z}}} + x \]
      3. mul-1-neg99.9%

        \[\leadsto \frac{y}{14.431876219268936 - \frac{15.646356830292042 + \color{blue}{\left(-\frac{101.23733352003822 - 655.3980091051341 \cdot \frac{1}{z}}{z}\right)}}{z}} + x \]
      4. unsub-neg99.9%

        \[\leadsto \frac{y}{14.431876219268936 - \frac{\color{blue}{15.646356830292042 - \frac{101.23733352003822 - 655.3980091051341 \cdot \frac{1}{z}}{z}}}{z}} + x \]
      5. sub-neg99.9%

        \[\leadsto \frac{y}{14.431876219268936 - \frac{15.646356830292042 - \frac{\color{blue}{101.23733352003822 + \left(-655.3980091051341 \cdot \frac{1}{z}\right)}}{z}}{z}} + x \]
      6. associate-*r/99.9%

        \[\leadsto \frac{y}{14.431876219268936 - \frac{15.646356830292042 - \frac{101.23733352003822 + \left(-\color{blue}{\frac{655.3980091051341 \cdot 1}{z}}\right)}{z}}{z}} + x \]
      7. metadata-eval99.9%

        \[\leadsto \frac{y}{14.431876219268936 - \frac{15.646356830292042 - \frac{101.23733352003822 + \left(-\frac{\color{blue}{655.3980091051341}}{z}\right)}{z}}{z}} + x \]
      8. distribute-neg-frac99.9%

        \[\leadsto \frac{y}{14.431876219268936 - \frac{15.646356830292042 - \frac{101.23733352003822 + \color{blue}{\frac{-655.3980091051341}{z}}}{z}}{z}} + x \]
      9. metadata-eval99.9%

        \[\leadsto \frac{y}{14.431876219268936 - \frac{15.646356830292042 - \frac{101.23733352003822 + \frac{\color{blue}{-655.3980091051341}}{z}}{z}}{z}} + x \]
    9. Simplified99.9%

      \[\leadsto \frac{y}{\color{blue}{14.431876219268936 - \frac{15.646356830292042 - \frac{101.23733352003822 + \frac{-655.3980091051341}{z}}{z}}{z}}} + x \]

    if -6800 < z < 2300

    1. Initial program 99.5%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. expm1-log1p-u99.5%

        \[\leadsto x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\color{blue}{\mathsf{expm1}\left(\mathsf{log1p}\left(\left(z + 6.012459259764103\right) \cdot z\right)\right)} + 3.350343815022304} \]
      2. expm1-undefine99.5%

        \[\leadsto x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\color{blue}{\left(e^{\mathsf{log1p}\left(\left(z + 6.012459259764103\right) \cdot z\right)} - 1\right)} + 3.350343815022304} \]
      3. *-commutative99.5%

        \[\leadsto x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(e^{\mathsf{log1p}\left(\color{blue}{z \cdot \left(z + 6.012459259764103\right)}\right)} - 1\right) + 3.350343815022304} \]
    4. Applied egg-rr99.5%

      \[\leadsto x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\color{blue}{\left(e^{\mathsf{log1p}\left(z \cdot \left(z + 6.012459259764103\right)\right)} - 1\right)} + 3.350343815022304} \]

    if 2300 < z

    1. Initial program 42.7%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative42.7%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative42.7%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*51.4%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified51.4%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. fma-undefine51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x} \]
      2. fma-undefine51.4%

        \[\leadsto \color{blue}{\left(z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) + 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      3. *-commutative51.4%

        \[\leadsto \left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z} + 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      4. fma-define51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      5. fma-undefine51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304}} + x \]
      6. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{\left(z + 6.012459259764103\right) \cdot z} + 3.350343815022304} + x \]
      7. associate-*r/42.7%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      8. associate-*l/52.8%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \cdot y} + x \]
      9. *-commutative52.8%

        \[\leadsto \color{blue}{y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      10. clear-num52.8%

        \[\leadsto y \cdot \color{blue}{\frac{1}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      11. un-div-inv52.8%

        \[\leadsto \color{blue}{\frac{y}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      12. *-commutative52.8%

        \[\leadsto \frac{y}{\frac{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      13. fma-undefine52.8%

        \[\leadsto \frac{y}{\frac{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      14. fma-define52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z + 0.279195317918525}}} + x \]
      15. *-commutative52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)} + 0.279195317918525}} + x \]
      16. fma-undefine52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}}} + x \]
    6. Applied egg-rr52.8%

      \[\leadsto \color{blue}{\frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}} + x} \]
    7. Taylor expanded in z around inf 99.9%

      \[\leadsto \frac{y}{\color{blue}{14.431876219268936}} + x \]
  3. Recombined 3 regimes into one program.
  4. Final simplification99.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -6800:\\ \;\;\;\;x + \frac{y}{14.431876219268936 + \frac{\frac{101.23733352003822 + \frac{-655.3980091051341}{z}}{z} - 15.646356830292042}{z}}\\ \mathbf{elif}\;z \leq 2300:\\ \;\;\;\;x + \frac{y \cdot \left(z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) + 0.279195317918525\right)}{3.350343815022304 + \left(e^{\mathsf{log1p}\left(z \cdot \left(z + 6.012459259764103\right)\right)} + -1\right)}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{14.431876219268936}\\ \end{array} \]
  5. Add Preprocessing

Alternative 3: 99.6% accurate, 0.1× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -32000:\\ \;\;\;\;x + \frac{y}{14.431876219268936 + \frac{\frac{101.23733352003822 + \frac{-655.3980091051341}{z}}{z} - 15.646356830292042}{z}}\\ \mathbf{elif}\;z \leq 2300:\\ \;\;\;\;x + \frac{y \cdot \left(0.279195317918525 + z \cdot \left(0.4917317610505968 + {\left(\sqrt[3]{z \cdot 0.0692910599291889}\right)}^{3}\right)\right)}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{14.431876219268936}\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (if (<= z -32000.0)
   (+
    x
    (/
     y
     (+
      14.431876219268936
      (/
       (-
        (/ (+ 101.23733352003822 (/ -655.3980091051341 z)) z)
        15.646356830292042)
       z))))
   (if (<= z 2300.0)
     (+
      x
      (/
       (*
        y
        (+
         0.279195317918525
         (*
          z
          (+ 0.4917317610505968 (pow (cbrt (* z 0.0692910599291889)) 3.0)))))
       (+ (* z (+ z 6.012459259764103)) 3.350343815022304)))
     (+ x (/ y 14.431876219268936)))))
double code(double x, double y, double z) {
	double tmp;
	if (z <= -32000.0) {
		tmp = x + (y / (14.431876219268936 + ((((101.23733352003822 + (-655.3980091051341 / z)) / z) - 15.646356830292042) / z)));
	} else if (z <= 2300.0) {
		tmp = x + ((y * (0.279195317918525 + (z * (0.4917317610505968 + pow(cbrt((z * 0.0692910599291889)), 3.0))))) / ((z * (z + 6.012459259764103)) + 3.350343815022304));
	} else {
		tmp = x + (y / 14.431876219268936);
	}
	return tmp;
}
public static double code(double x, double y, double z) {
	double tmp;
	if (z <= -32000.0) {
		tmp = x + (y / (14.431876219268936 + ((((101.23733352003822 + (-655.3980091051341 / z)) / z) - 15.646356830292042) / z)));
	} else if (z <= 2300.0) {
		tmp = x + ((y * (0.279195317918525 + (z * (0.4917317610505968 + Math.pow(Math.cbrt((z * 0.0692910599291889)), 3.0))))) / ((z * (z + 6.012459259764103)) + 3.350343815022304));
	} else {
		tmp = x + (y / 14.431876219268936);
	}
	return tmp;
}
function code(x, y, z)
	tmp = 0.0
	if (z <= -32000.0)
		tmp = Float64(x + Float64(y / Float64(14.431876219268936 + Float64(Float64(Float64(Float64(101.23733352003822 + Float64(-655.3980091051341 / z)) / z) - 15.646356830292042) / z))));
	elseif (z <= 2300.0)
		tmp = Float64(x + Float64(Float64(y * Float64(0.279195317918525 + Float64(z * Float64(0.4917317610505968 + (cbrt(Float64(z * 0.0692910599291889)) ^ 3.0))))) / Float64(Float64(z * Float64(z + 6.012459259764103)) + 3.350343815022304)));
	else
		tmp = Float64(x + Float64(y / 14.431876219268936));
	end
	return tmp
end
code[x_, y_, z_] := If[LessEqual[z, -32000.0], N[(x + N[(y / N[(14.431876219268936 + N[(N[(N[(N[(101.23733352003822 + N[(-655.3980091051341 / z), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision] - 15.646356830292042), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2300.0], N[(x + N[(N[(y * N[(0.279195317918525 + N[(z * N[(0.4917317610505968 + N[Power[N[Power[N[(z * 0.0692910599291889), $MachinePrecision], 1/3], $MachinePrecision], 3.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(N[(z * N[(z + 6.012459259764103), $MachinePrecision]), $MachinePrecision] + 3.350343815022304), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(y / 14.431876219268936), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -32000:\\
\;\;\;\;x + \frac{y}{14.431876219268936 + \frac{\frac{101.23733352003822 + \frac{-655.3980091051341}{z}}{z} - 15.646356830292042}{z}}\\

\mathbf{elif}\;z \leq 2300:\\
\;\;\;\;x + \frac{y \cdot \left(0.279195317918525 + z \cdot \left(0.4917317610505968 + {\left(\sqrt[3]{z \cdot 0.0692910599291889}\right)}^{3}\right)\right)}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304}\\

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


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

    1. Initial program 42.7%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative42.7%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative42.7%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*50.7%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define50.7%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative50.7%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define50.7%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define50.7%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative50.7%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define50.7%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified50.7%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. fma-undefine50.7%

        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x} \]
      2. fma-undefine50.7%

        \[\leadsto \color{blue}{\left(z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) + 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      3. *-commutative50.7%

        \[\leadsto \left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z} + 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      4. fma-define50.7%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      5. fma-undefine50.7%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304}} + x \]
      6. *-commutative50.7%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{\left(z + 6.012459259764103\right) \cdot z} + 3.350343815022304} + x \]
      7. associate-*r/42.7%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      8. associate-*l/52.1%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \cdot y} + x \]
      9. *-commutative52.1%

        \[\leadsto \color{blue}{y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      10. clear-num52.1%

        \[\leadsto y \cdot \color{blue}{\frac{1}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      11. un-div-inv52.2%

        \[\leadsto \color{blue}{\frac{y}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      12. *-commutative52.2%

        \[\leadsto \frac{y}{\frac{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      13. fma-undefine52.2%

        \[\leadsto \frac{y}{\frac{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      14. fma-define52.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z + 0.279195317918525}}} + x \]
      15. *-commutative52.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)} + 0.279195317918525}} + x \]
      16. fma-undefine52.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}}} + x \]
    6. Applied egg-rr52.2%

      \[\leadsto \color{blue}{\frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}} + x} \]
    7. Taylor expanded in z around -inf 99.9%

      \[\leadsto \frac{y}{\color{blue}{14.431876219268936 + -1 \cdot \frac{15.646356830292042 + -1 \cdot \frac{101.23733352003822 - 655.3980091051341 \cdot \frac{1}{z}}{z}}{z}}} + x \]
    8. Step-by-step derivation
      1. mul-1-neg99.9%

        \[\leadsto \frac{y}{14.431876219268936 + \color{blue}{\left(-\frac{15.646356830292042 + -1 \cdot \frac{101.23733352003822 - 655.3980091051341 \cdot \frac{1}{z}}{z}}{z}\right)}} + x \]
      2. unsub-neg99.9%

        \[\leadsto \frac{y}{\color{blue}{14.431876219268936 - \frac{15.646356830292042 + -1 \cdot \frac{101.23733352003822 - 655.3980091051341 \cdot \frac{1}{z}}{z}}{z}}} + x \]
      3. mul-1-neg99.9%

        \[\leadsto \frac{y}{14.431876219268936 - \frac{15.646356830292042 + \color{blue}{\left(-\frac{101.23733352003822 - 655.3980091051341 \cdot \frac{1}{z}}{z}\right)}}{z}} + x \]
      4. unsub-neg99.9%

        \[\leadsto \frac{y}{14.431876219268936 - \frac{\color{blue}{15.646356830292042 - \frac{101.23733352003822 - 655.3980091051341 \cdot \frac{1}{z}}{z}}}{z}} + x \]
      5. sub-neg99.9%

        \[\leadsto \frac{y}{14.431876219268936 - \frac{15.646356830292042 - \frac{\color{blue}{101.23733352003822 + \left(-655.3980091051341 \cdot \frac{1}{z}\right)}}{z}}{z}} + x \]
      6. associate-*r/99.9%

        \[\leadsto \frac{y}{14.431876219268936 - \frac{15.646356830292042 - \frac{101.23733352003822 + \left(-\color{blue}{\frac{655.3980091051341 \cdot 1}{z}}\right)}{z}}{z}} + x \]
      7. metadata-eval99.9%

        \[\leadsto \frac{y}{14.431876219268936 - \frac{15.646356830292042 - \frac{101.23733352003822 + \left(-\frac{\color{blue}{655.3980091051341}}{z}\right)}{z}}{z}} + x \]
      8. distribute-neg-frac99.9%

        \[\leadsto \frac{y}{14.431876219268936 - \frac{15.646356830292042 - \frac{101.23733352003822 + \color{blue}{\frac{-655.3980091051341}{z}}}{z}}{z}} + x \]
      9. metadata-eval99.9%

        \[\leadsto \frac{y}{14.431876219268936 - \frac{15.646356830292042 - \frac{101.23733352003822 + \frac{\color{blue}{-655.3980091051341}}{z}}{z}}{z}} + x \]
    9. Simplified99.9%

      \[\leadsto \frac{y}{\color{blue}{14.431876219268936 - \frac{15.646356830292042 - \frac{101.23733352003822 + \frac{-655.3980091051341}{z}}{z}}{z}}} + x \]

    if -32000 < z < 2300

    1. Initial program 99.5%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. add-cube-cbrt99.5%

        \[\leadsto x + \frac{y \cdot \left(\left(\color{blue}{\left(\sqrt[3]{z \cdot 0.0692910599291889} \cdot \sqrt[3]{z \cdot 0.0692910599291889}\right) \cdot \sqrt[3]{z \cdot 0.0692910599291889}} + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
      2. pow399.5%

        \[\leadsto x + \frac{y \cdot \left(\left(\color{blue}{{\left(\sqrt[3]{z \cdot 0.0692910599291889}\right)}^{3}} + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    4. Applied egg-rr99.5%

      \[\leadsto x + \frac{y \cdot \left(\left(\color{blue}{{\left(\sqrt[3]{z \cdot 0.0692910599291889}\right)}^{3}} + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]

    if 2300 < z

    1. Initial program 42.7%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative42.7%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative42.7%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*51.4%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified51.4%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. fma-undefine51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x} \]
      2. fma-undefine51.4%

        \[\leadsto \color{blue}{\left(z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) + 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      3. *-commutative51.4%

        \[\leadsto \left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z} + 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      4. fma-define51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      5. fma-undefine51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304}} + x \]
      6. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{\left(z + 6.012459259764103\right) \cdot z} + 3.350343815022304} + x \]
      7. associate-*r/42.7%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      8. associate-*l/52.8%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \cdot y} + x \]
      9. *-commutative52.8%

        \[\leadsto \color{blue}{y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      10. clear-num52.8%

        \[\leadsto y \cdot \color{blue}{\frac{1}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      11. un-div-inv52.8%

        \[\leadsto \color{blue}{\frac{y}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      12. *-commutative52.8%

        \[\leadsto \frac{y}{\frac{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      13. fma-undefine52.8%

        \[\leadsto \frac{y}{\frac{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      14. fma-define52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z + 0.279195317918525}}} + x \]
      15. *-commutative52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)} + 0.279195317918525}} + x \]
      16. fma-undefine52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}}} + x \]
    6. Applied egg-rr52.8%

      \[\leadsto \color{blue}{\frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}} + x} \]
    7. Taylor expanded in z around inf 99.9%

      \[\leadsto \frac{y}{\color{blue}{14.431876219268936}} + x \]
  3. Recombined 3 regimes into one program.
  4. Final simplification99.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -32000:\\ \;\;\;\;x + \frac{y}{14.431876219268936 + \frac{\frac{101.23733352003822 + \frac{-655.3980091051341}{z}}{z} - 15.646356830292042}{z}}\\ \mathbf{elif}\;z \leq 2300:\\ \;\;\;\;x + \frac{y \cdot \left(0.279195317918525 + z \cdot \left(0.4917317610505968 + {\left(\sqrt[3]{z \cdot 0.0692910599291889}\right)}^{3}\right)\right)}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{14.431876219268936}\\ \end{array} \]
  5. Add Preprocessing

Alternative 4: 77.0% accurate, 0.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -1.08 \cdot 10^{-38} \lor \neg \left(z \leq -4 \cdot 10^{-185}\right) \land \left(z \leq 5.6 \cdot 10^{-269} \lor \neg \left(z \leq 1.7 \cdot 10^{-171}\right) \land \left(z \leq 1.95 \cdot 10^{-101} \lor \neg \left(z \leq 1.85 \cdot 10^{-13}\right)\right)\right):\\ \;\;\;\;x + y \cdot 0.0692910599291889\\ \mathbf{else}:\\ \;\;\;\;y \cdot 0.08333333333333323\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (if (or (<= z -1.08e-38)
         (and (not (<= z -4e-185))
              (or (<= z 5.6e-269)
                  (and (not (<= z 1.7e-171))
                       (or (<= z 1.95e-101) (not (<= z 1.85e-13)))))))
   (+ x (* y 0.0692910599291889))
   (* y 0.08333333333333323)))
double code(double x, double y, double z) {
	double tmp;
	if ((z <= -1.08e-38) || (!(z <= -4e-185) && ((z <= 5.6e-269) || (!(z <= 1.7e-171) && ((z <= 1.95e-101) || !(z <= 1.85e-13)))))) {
		tmp = x + (y * 0.0692910599291889);
	} else {
		tmp = y * 0.08333333333333323;
	}
	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.08d-38)) .or. (.not. (z <= (-4d-185))) .and. (z <= 5.6d-269) .or. (.not. (z <= 1.7d-171)) .and. (z <= 1.95d-101) .or. (.not. (z <= 1.85d-13))) then
        tmp = x + (y * 0.0692910599291889d0)
    else
        tmp = y * 0.08333333333333323d0
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double tmp;
	if ((z <= -1.08e-38) || (!(z <= -4e-185) && ((z <= 5.6e-269) || (!(z <= 1.7e-171) && ((z <= 1.95e-101) || !(z <= 1.85e-13)))))) {
		tmp = x + (y * 0.0692910599291889);
	} else {
		tmp = y * 0.08333333333333323;
	}
	return tmp;
}
def code(x, y, z):
	tmp = 0
	if (z <= -1.08e-38) or (not (z <= -4e-185) and ((z <= 5.6e-269) or (not (z <= 1.7e-171) and ((z <= 1.95e-101) or not (z <= 1.85e-13))))):
		tmp = x + (y * 0.0692910599291889)
	else:
		tmp = y * 0.08333333333333323
	return tmp
function code(x, y, z)
	tmp = 0.0
	if ((z <= -1.08e-38) || (!(z <= -4e-185) && ((z <= 5.6e-269) || (!(z <= 1.7e-171) && ((z <= 1.95e-101) || !(z <= 1.85e-13))))))
		tmp = Float64(x + Float64(y * 0.0692910599291889));
	else
		tmp = Float64(y * 0.08333333333333323);
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	tmp = 0.0;
	if ((z <= -1.08e-38) || (~((z <= -4e-185)) && ((z <= 5.6e-269) || (~((z <= 1.7e-171)) && ((z <= 1.95e-101) || ~((z <= 1.85e-13)))))))
		tmp = x + (y * 0.0692910599291889);
	else
		tmp = y * 0.08333333333333323;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := If[Or[LessEqual[z, -1.08e-38], And[N[Not[LessEqual[z, -4e-185]], $MachinePrecision], Or[LessEqual[z, 5.6e-269], And[N[Not[LessEqual[z, 1.7e-171]], $MachinePrecision], Or[LessEqual[z, 1.95e-101], N[Not[LessEqual[z, 1.85e-13]], $MachinePrecision]]]]]], N[(x + N[(y * 0.0692910599291889), $MachinePrecision]), $MachinePrecision], N[(y * 0.08333333333333323), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.08 \cdot 10^{-38} \lor \neg \left(z \leq -4 \cdot 10^{-185}\right) \land \left(z \leq 5.6 \cdot 10^{-269} \lor \neg \left(z \leq 1.7 \cdot 10^{-171}\right) \land \left(z \leq 1.95 \cdot 10^{-101} \lor \neg \left(z \leq 1.85 \cdot 10^{-13}\right)\right)\right):\\
\;\;\;\;x + y \cdot 0.0692910599291889\\

\mathbf{else}:\\
\;\;\;\;y \cdot 0.08333333333333323\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -1.08e-38 or -4e-185 < z < 5.5999999999999999e-269 or 1.69999999999999993e-171 < z < 1.95000000000000008e-101 or 1.84999999999999994e-13 < z

    1. Initial program 61.4%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative61.4%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative61.4%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*67.0%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define67.0%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative67.0%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define67.0%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define67.0%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative67.0%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define67.0%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified67.0%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in z around inf 89.6%

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

        \[\leadsto \color{blue}{0.0692910599291889 \cdot y + x} \]
    7. Simplified89.6%

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

    if -1.08e-38 < z < -4e-185 or 5.5999999999999999e-269 < z < 1.69999999999999993e-171 or 1.95000000000000008e-101 < z < 1.84999999999999994e-13

    1. Initial program 99.3%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative99.3%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative99.3%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*99.3%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define99.3%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative99.3%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define99.3%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define99.3%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative99.3%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define99.3%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified99.3%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in z around 0 99.8%

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

        \[\leadsto \color{blue}{0.08333333333333323 \cdot y + x} \]
    7. Simplified99.8%

      \[\leadsto \color{blue}{0.08333333333333323 \cdot y + x} \]
    8. Taylor expanded in y around inf 77.5%

      \[\leadsto \color{blue}{0.08333333333333323 \cdot y} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification86.3%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -1.08 \cdot 10^{-38} \lor \neg \left(z \leq -4 \cdot 10^{-185}\right) \land \left(z \leq 5.6 \cdot 10^{-269} \lor \neg \left(z \leq 1.7 \cdot 10^{-171}\right) \land \left(z \leq 1.95 \cdot 10^{-101} \lor \neg \left(z \leq 1.85 \cdot 10^{-13}\right)\right)\right):\\ \;\;\;\;x + y \cdot 0.0692910599291889\\ \mathbf{else}:\\ \;\;\;\;y \cdot 0.08333333333333323\\ \end{array} \]
  5. Add Preprocessing

Alternative 5: 99.6% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -50000:\\ \;\;\;\;x + \frac{y}{14.431876219268936 + \frac{\frac{101.23733352003822 + \frac{-655.3980091051341}{z}}{z} - 15.646356830292042}{z}}\\ \mathbf{elif}\;z \leq 2300:\\ \;\;\;\;\frac{y \cdot \left(z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) + 0.279195317918525\right)}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304} + x\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{14.431876219268936}\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (if (<= z -50000.0)
   (+
    x
    (/
     y
     (+
      14.431876219268936
      (/
       (-
        (/ (+ 101.23733352003822 (/ -655.3980091051341 z)) z)
        15.646356830292042)
       z))))
   (if (<= z 2300.0)
     (+
      (/
       (*
        y
        (+
         (* z (+ (* z 0.0692910599291889) 0.4917317610505968))
         0.279195317918525))
       (+ (* z (+ z 6.012459259764103)) 3.350343815022304))
      x)
     (+ x (/ y 14.431876219268936)))))
double code(double x, double y, double z) {
	double tmp;
	if (z <= -50000.0) {
		tmp = x + (y / (14.431876219268936 + ((((101.23733352003822 + (-655.3980091051341 / z)) / z) - 15.646356830292042) / z)));
	} else if (z <= 2300.0) {
		tmp = ((y * ((z * ((z * 0.0692910599291889) + 0.4917317610505968)) + 0.279195317918525)) / ((z * (z + 6.012459259764103)) + 3.350343815022304)) + x;
	} else {
		tmp = x + (y / 14.431876219268936);
	}
	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 <= (-50000.0d0)) then
        tmp = x + (y / (14.431876219268936d0 + ((((101.23733352003822d0 + ((-655.3980091051341d0) / z)) / z) - 15.646356830292042d0) / z)))
    else if (z <= 2300.0d0) then
        tmp = ((y * ((z * ((z * 0.0692910599291889d0) + 0.4917317610505968d0)) + 0.279195317918525d0)) / ((z * (z + 6.012459259764103d0)) + 3.350343815022304d0)) + x
    else
        tmp = x + (y / 14.431876219268936d0)
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double tmp;
	if (z <= -50000.0) {
		tmp = x + (y / (14.431876219268936 + ((((101.23733352003822 + (-655.3980091051341 / z)) / z) - 15.646356830292042) / z)));
	} else if (z <= 2300.0) {
		tmp = ((y * ((z * ((z * 0.0692910599291889) + 0.4917317610505968)) + 0.279195317918525)) / ((z * (z + 6.012459259764103)) + 3.350343815022304)) + x;
	} else {
		tmp = x + (y / 14.431876219268936);
	}
	return tmp;
}
def code(x, y, z):
	tmp = 0
	if z <= -50000.0:
		tmp = x + (y / (14.431876219268936 + ((((101.23733352003822 + (-655.3980091051341 / z)) / z) - 15.646356830292042) / z)))
	elif z <= 2300.0:
		tmp = ((y * ((z * ((z * 0.0692910599291889) + 0.4917317610505968)) + 0.279195317918525)) / ((z * (z + 6.012459259764103)) + 3.350343815022304)) + x
	else:
		tmp = x + (y / 14.431876219268936)
	return tmp
function code(x, y, z)
	tmp = 0.0
	if (z <= -50000.0)
		tmp = Float64(x + Float64(y / Float64(14.431876219268936 + Float64(Float64(Float64(Float64(101.23733352003822 + Float64(-655.3980091051341 / z)) / z) - 15.646356830292042) / z))));
	elseif (z <= 2300.0)
		tmp = Float64(Float64(Float64(y * Float64(Float64(z * Float64(Float64(z * 0.0692910599291889) + 0.4917317610505968)) + 0.279195317918525)) / Float64(Float64(z * Float64(z + 6.012459259764103)) + 3.350343815022304)) + x);
	else
		tmp = Float64(x + Float64(y / 14.431876219268936));
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	tmp = 0.0;
	if (z <= -50000.0)
		tmp = x + (y / (14.431876219268936 + ((((101.23733352003822 + (-655.3980091051341 / z)) / z) - 15.646356830292042) / z)));
	elseif (z <= 2300.0)
		tmp = ((y * ((z * ((z * 0.0692910599291889) + 0.4917317610505968)) + 0.279195317918525)) / ((z * (z + 6.012459259764103)) + 3.350343815022304)) + x;
	else
		tmp = x + (y / 14.431876219268936);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := If[LessEqual[z, -50000.0], N[(x + N[(y / N[(14.431876219268936 + N[(N[(N[(N[(101.23733352003822 + N[(-655.3980091051341 / z), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision] - 15.646356830292042), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2300.0], N[(N[(N[(y * N[(N[(z * N[(N[(z * 0.0692910599291889), $MachinePrecision] + 0.4917317610505968), $MachinePrecision]), $MachinePrecision] + 0.279195317918525), $MachinePrecision]), $MachinePrecision] / N[(N[(z * N[(z + 6.012459259764103), $MachinePrecision]), $MachinePrecision] + 3.350343815022304), $MachinePrecision]), $MachinePrecision] + x), $MachinePrecision], N[(x + N[(y / 14.431876219268936), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -50000:\\
\;\;\;\;x + \frac{y}{14.431876219268936 + \frac{\frac{101.23733352003822 + \frac{-655.3980091051341}{z}}{z} - 15.646356830292042}{z}}\\

\mathbf{elif}\;z \leq 2300:\\
\;\;\;\;\frac{y \cdot \left(z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) + 0.279195317918525\right)}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304} + x\\

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


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

    1. Initial program 42.7%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative42.7%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative42.7%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*50.7%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define50.7%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative50.7%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define50.7%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define50.7%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative50.7%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define50.7%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified50.7%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. fma-undefine50.7%

        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x} \]
      2. fma-undefine50.7%

        \[\leadsto \color{blue}{\left(z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) + 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      3. *-commutative50.7%

        \[\leadsto \left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z} + 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      4. fma-define50.7%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      5. fma-undefine50.7%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304}} + x \]
      6. *-commutative50.7%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{\left(z + 6.012459259764103\right) \cdot z} + 3.350343815022304} + x \]
      7. associate-*r/42.7%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      8. associate-*l/52.1%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \cdot y} + x \]
      9. *-commutative52.1%

        \[\leadsto \color{blue}{y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      10. clear-num52.1%

        \[\leadsto y \cdot \color{blue}{\frac{1}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      11. un-div-inv52.2%

        \[\leadsto \color{blue}{\frac{y}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      12. *-commutative52.2%

        \[\leadsto \frac{y}{\frac{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      13. fma-undefine52.2%

        \[\leadsto \frac{y}{\frac{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      14. fma-define52.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z + 0.279195317918525}}} + x \]
      15. *-commutative52.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)} + 0.279195317918525}} + x \]
      16. fma-undefine52.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}}} + x \]
    6. Applied egg-rr52.2%

      \[\leadsto \color{blue}{\frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}} + x} \]
    7. Taylor expanded in z around -inf 99.9%

      \[\leadsto \frac{y}{\color{blue}{14.431876219268936 + -1 \cdot \frac{15.646356830292042 + -1 \cdot \frac{101.23733352003822 - 655.3980091051341 \cdot \frac{1}{z}}{z}}{z}}} + x \]
    8. Step-by-step derivation
      1. mul-1-neg99.9%

        \[\leadsto \frac{y}{14.431876219268936 + \color{blue}{\left(-\frac{15.646356830292042 + -1 \cdot \frac{101.23733352003822 - 655.3980091051341 \cdot \frac{1}{z}}{z}}{z}\right)}} + x \]
      2. unsub-neg99.9%

        \[\leadsto \frac{y}{\color{blue}{14.431876219268936 - \frac{15.646356830292042 + -1 \cdot \frac{101.23733352003822 - 655.3980091051341 \cdot \frac{1}{z}}{z}}{z}}} + x \]
      3. mul-1-neg99.9%

        \[\leadsto \frac{y}{14.431876219268936 - \frac{15.646356830292042 + \color{blue}{\left(-\frac{101.23733352003822 - 655.3980091051341 \cdot \frac{1}{z}}{z}\right)}}{z}} + x \]
      4. unsub-neg99.9%

        \[\leadsto \frac{y}{14.431876219268936 - \frac{\color{blue}{15.646356830292042 - \frac{101.23733352003822 - 655.3980091051341 \cdot \frac{1}{z}}{z}}}{z}} + x \]
      5. sub-neg99.9%

        \[\leadsto \frac{y}{14.431876219268936 - \frac{15.646356830292042 - \frac{\color{blue}{101.23733352003822 + \left(-655.3980091051341 \cdot \frac{1}{z}\right)}}{z}}{z}} + x \]
      6. associate-*r/99.9%

        \[\leadsto \frac{y}{14.431876219268936 - \frac{15.646356830292042 - \frac{101.23733352003822 + \left(-\color{blue}{\frac{655.3980091051341 \cdot 1}{z}}\right)}{z}}{z}} + x \]
      7. metadata-eval99.9%

        \[\leadsto \frac{y}{14.431876219268936 - \frac{15.646356830292042 - \frac{101.23733352003822 + \left(-\frac{\color{blue}{655.3980091051341}}{z}\right)}{z}}{z}} + x \]
      8. distribute-neg-frac99.9%

        \[\leadsto \frac{y}{14.431876219268936 - \frac{15.646356830292042 - \frac{101.23733352003822 + \color{blue}{\frac{-655.3980091051341}{z}}}{z}}{z}} + x \]
      9. metadata-eval99.9%

        \[\leadsto \frac{y}{14.431876219268936 - \frac{15.646356830292042 - \frac{101.23733352003822 + \frac{\color{blue}{-655.3980091051341}}{z}}{z}}{z}} + x \]
    9. Simplified99.9%

      \[\leadsto \frac{y}{\color{blue}{14.431876219268936 - \frac{15.646356830292042 - \frac{101.23733352003822 + \frac{-655.3980091051341}{z}}{z}}{z}}} + x \]

    if -5e4 < z < 2300

    1. Initial program 99.5%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Add Preprocessing

    if 2300 < z

    1. Initial program 42.7%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative42.7%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative42.7%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*51.4%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified51.4%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. fma-undefine51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x} \]
      2. fma-undefine51.4%

        \[\leadsto \color{blue}{\left(z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) + 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      3. *-commutative51.4%

        \[\leadsto \left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z} + 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      4. fma-define51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      5. fma-undefine51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304}} + x \]
      6. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{\left(z + 6.012459259764103\right) \cdot z} + 3.350343815022304} + x \]
      7. associate-*r/42.7%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      8. associate-*l/52.8%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \cdot y} + x \]
      9. *-commutative52.8%

        \[\leadsto \color{blue}{y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      10. clear-num52.8%

        \[\leadsto y \cdot \color{blue}{\frac{1}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      11. un-div-inv52.8%

        \[\leadsto \color{blue}{\frac{y}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      12. *-commutative52.8%

        \[\leadsto \frac{y}{\frac{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      13. fma-undefine52.8%

        \[\leadsto \frac{y}{\frac{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      14. fma-define52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z + 0.279195317918525}}} + x \]
      15. *-commutative52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)} + 0.279195317918525}} + x \]
      16. fma-undefine52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}}} + x \]
    6. Applied egg-rr52.8%

      \[\leadsto \color{blue}{\frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}} + x} \]
    7. Taylor expanded in z around inf 99.9%

      \[\leadsto \frac{y}{\color{blue}{14.431876219268936}} + x \]
  3. Recombined 3 regimes into one program.
  4. Final simplification99.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -50000:\\ \;\;\;\;x + \frac{y}{14.431876219268936 + \frac{\frac{101.23733352003822 + \frac{-655.3980091051341}{z}}{z} - 15.646356830292042}{z}}\\ \mathbf{elif}\;z \leq 2300:\\ \;\;\;\;\frac{y \cdot \left(z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) + 0.279195317918525\right)}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304} + x\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{14.431876219268936}\\ \end{array} \]
  5. Add Preprocessing

Alternative 6: 99.4% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -3100:\\ \;\;\;\;x + \frac{y}{14.431876219268936 + \frac{\frac{101.23733352003822 + \frac{-655.3980091051341}{z}}{z} - 15.646356830292042}{z}}\\ \mathbf{elif}\;z \leq 3:\\ \;\;\;\;x + \frac{y}{12.000000000000014 + z \cdot \left(0.39999999996247915 + z \cdot \left(z \cdot 0.07852944389170011 - 0.10095235035524991\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{14.431876219268936}\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (if (<= z -3100.0)
   (+
    x
    (/
     y
     (+
      14.431876219268936
      (/
       (-
        (/ (+ 101.23733352003822 (/ -655.3980091051341 z)) z)
        15.646356830292042)
       z))))
   (if (<= z 3.0)
     (+
      x
      (/
       y
       (+
        12.000000000000014
        (*
         z
         (+
          0.39999999996247915
          (* z (- (* z 0.07852944389170011) 0.10095235035524991)))))))
     (+ x (/ y 14.431876219268936)))))
double code(double x, double y, double z) {
	double tmp;
	if (z <= -3100.0) {
		tmp = x + (y / (14.431876219268936 + ((((101.23733352003822 + (-655.3980091051341 / z)) / z) - 15.646356830292042) / z)));
	} else if (z <= 3.0) {
		tmp = x + (y / (12.000000000000014 + (z * (0.39999999996247915 + (z * ((z * 0.07852944389170011) - 0.10095235035524991))))));
	} else {
		tmp = x + (y / 14.431876219268936);
	}
	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 <= (-3100.0d0)) then
        tmp = x + (y / (14.431876219268936d0 + ((((101.23733352003822d0 + ((-655.3980091051341d0) / z)) / z) - 15.646356830292042d0) / z)))
    else if (z <= 3.0d0) then
        tmp = x + (y / (12.000000000000014d0 + (z * (0.39999999996247915d0 + (z * ((z * 0.07852944389170011d0) - 0.10095235035524991d0))))))
    else
        tmp = x + (y / 14.431876219268936d0)
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double tmp;
	if (z <= -3100.0) {
		tmp = x + (y / (14.431876219268936 + ((((101.23733352003822 + (-655.3980091051341 / z)) / z) - 15.646356830292042) / z)));
	} else if (z <= 3.0) {
		tmp = x + (y / (12.000000000000014 + (z * (0.39999999996247915 + (z * ((z * 0.07852944389170011) - 0.10095235035524991))))));
	} else {
		tmp = x + (y / 14.431876219268936);
	}
	return tmp;
}
def code(x, y, z):
	tmp = 0
	if z <= -3100.0:
		tmp = x + (y / (14.431876219268936 + ((((101.23733352003822 + (-655.3980091051341 / z)) / z) - 15.646356830292042) / z)))
	elif z <= 3.0:
		tmp = x + (y / (12.000000000000014 + (z * (0.39999999996247915 + (z * ((z * 0.07852944389170011) - 0.10095235035524991))))))
	else:
		tmp = x + (y / 14.431876219268936)
	return tmp
function code(x, y, z)
	tmp = 0.0
	if (z <= -3100.0)
		tmp = Float64(x + Float64(y / Float64(14.431876219268936 + Float64(Float64(Float64(Float64(101.23733352003822 + Float64(-655.3980091051341 / z)) / z) - 15.646356830292042) / z))));
	elseif (z <= 3.0)
		tmp = Float64(x + Float64(y / Float64(12.000000000000014 + Float64(z * Float64(0.39999999996247915 + Float64(z * Float64(Float64(z * 0.07852944389170011) - 0.10095235035524991)))))));
	else
		tmp = Float64(x + Float64(y / 14.431876219268936));
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	tmp = 0.0;
	if (z <= -3100.0)
		tmp = x + (y / (14.431876219268936 + ((((101.23733352003822 + (-655.3980091051341 / z)) / z) - 15.646356830292042) / z)));
	elseif (z <= 3.0)
		tmp = x + (y / (12.000000000000014 + (z * (0.39999999996247915 + (z * ((z * 0.07852944389170011) - 0.10095235035524991))))));
	else
		tmp = x + (y / 14.431876219268936);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := If[LessEqual[z, -3100.0], N[(x + N[(y / N[(14.431876219268936 + N[(N[(N[(N[(101.23733352003822 + N[(-655.3980091051341 / z), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision] - 15.646356830292042), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 3.0], N[(x + N[(y / N[(12.000000000000014 + N[(z * N[(0.39999999996247915 + N[(z * N[(N[(z * 0.07852944389170011), $MachinePrecision] - 0.10095235035524991), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(y / 14.431876219268936), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -3100:\\
\;\;\;\;x + \frac{y}{14.431876219268936 + \frac{\frac{101.23733352003822 + \frac{-655.3980091051341}{z}}{z} - 15.646356830292042}{z}}\\

\mathbf{elif}\;z \leq 3:\\
\;\;\;\;x + \frac{y}{12.000000000000014 + z \cdot \left(0.39999999996247915 + z \cdot \left(z \cdot 0.07852944389170011 - 0.10095235035524991\right)\right)}\\

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


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

    1. Initial program 42.7%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative42.7%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative42.7%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*50.7%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define50.7%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative50.7%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define50.7%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define50.7%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative50.7%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define50.7%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified50.7%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. fma-undefine50.7%

        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x} \]
      2. fma-undefine50.7%

        \[\leadsto \color{blue}{\left(z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) + 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      3. *-commutative50.7%

        \[\leadsto \left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z} + 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      4. fma-define50.7%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      5. fma-undefine50.7%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304}} + x \]
      6. *-commutative50.7%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{\left(z + 6.012459259764103\right) \cdot z} + 3.350343815022304} + x \]
      7. associate-*r/42.7%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      8. associate-*l/52.1%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \cdot y} + x \]
      9. *-commutative52.1%

        \[\leadsto \color{blue}{y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      10. clear-num52.1%

        \[\leadsto y \cdot \color{blue}{\frac{1}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      11. un-div-inv52.2%

        \[\leadsto \color{blue}{\frac{y}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      12. *-commutative52.2%

        \[\leadsto \frac{y}{\frac{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      13. fma-undefine52.2%

        \[\leadsto \frac{y}{\frac{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      14. fma-define52.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z + 0.279195317918525}}} + x \]
      15. *-commutative52.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)} + 0.279195317918525}} + x \]
      16. fma-undefine52.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}}} + x \]
    6. Applied egg-rr52.2%

      \[\leadsto \color{blue}{\frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}} + x} \]
    7. Taylor expanded in z around -inf 99.9%

      \[\leadsto \frac{y}{\color{blue}{14.431876219268936 + -1 \cdot \frac{15.646356830292042 + -1 \cdot \frac{101.23733352003822 - 655.3980091051341 \cdot \frac{1}{z}}{z}}{z}}} + x \]
    8. Step-by-step derivation
      1. mul-1-neg99.9%

        \[\leadsto \frac{y}{14.431876219268936 + \color{blue}{\left(-\frac{15.646356830292042 + -1 \cdot \frac{101.23733352003822 - 655.3980091051341 \cdot \frac{1}{z}}{z}}{z}\right)}} + x \]
      2. unsub-neg99.9%

        \[\leadsto \frac{y}{\color{blue}{14.431876219268936 - \frac{15.646356830292042 + -1 \cdot \frac{101.23733352003822 - 655.3980091051341 \cdot \frac{1}{z}}{z}}{z}}} + x \]
      3. mul-1-neg99.9%

        \[\leadsto \frac{y}{14.431876219268936 - \frac{15.646356830292042 + \color{blue}{\left(-\frac{101.23733352003822 - 655.3980091051341 \cdot \frac{1}{z}}{z}\right)}}{z}} + x \]
      4. unsub-neg99.9%

        \[\leadsto \frac{y}{14.431876219268936 - \frac{\color{blue}{15.646356830292042 - \frac{101.23733352003822 - 655.3980091051341 \cdot \frac{1}{z}}{z}}}{z}} + x \]
      5. sub-neg99.9%

        \[\leadsto \frac{y}{14.431876219268936 - \frac{15.646356830292042 - \frac{\color{blue}{101.23733352003822 + \left(-655.3980091051341 \cdot \frac{1}{z}\right)}}{z}}{z}} + x \]
      6. associate-*r/99.9%

        \[\leadsto \frac{y}{14.431876219268936 - \frac{15.646356830292042 - \frac{101.23733352003822 + \left(-\color{blue}{\frac{655.3980091051341 \cdot 1}{z}}\right)}{z}}{z}} + x \]
      7. metadata-eval99.9%

        \[\leadsto \frac{y}{14.431876219268936 - \frac{15.646356830292042 - \frac{101.23733352003822 + \left(-\frac{\color{blue}{655.3980091051341}}{z}\right)}{z}}{z}} + x \]
      8. distribute-neg-frac99.9%

        \[\leadsto \frac{y}{14.431876219268936 - \frac{15.646356830292042 - \frac{101.23733352003822 + \color{blue}{\frac{-655.3980091051341}{z}}}{z}}{z}} + x \]
      9. metadata-eval99.9%

        \[\leadsto \frac{y}{14.431876219268936 - \frac{15.646356830292042 - \frac{101.23733352003822 + \frac{\color{blue}{-655.3980091051341}}{z}}{z}}{z}} + x \]
    9. Simplified99.9%

      \[\leadsto \frac{y}{\color{blue}{14.431876219268936 - \frac{15.646356830292042 - \frac{101.23733352003822 + \frac{-655.3980091051341}{z}}{z}}{z}}} + x \]

    if -3100 < z < 3

    1. Initial program 99.5%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative99.5%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative99.5%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*99.5%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define99.5%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative99.5%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define99.5%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified99.5%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. fma-undefine99.5%

        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x} \]
      2. fma-undefine99.5%

        \[\leadsto \color{blue}{\left(z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) + 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      3. *-commutative99.5%

        \[\leadsto \left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z} + 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      4. fma-define99.5%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      5. fma-undefine99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304}} + x \]
      6. *-commutative99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{\left(z + 6.012459259764103\right) \cdot z} + 3.350343815022304} + x \]
      7. associate-*r/99.5%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      8. associate-*l/99.9%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \cdot y} + x \]
      9. *-commutative99.9%

        \[\leadsto \color{blue}{y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      10. clear-num99.0%

        \[\leadsto y \cdot \color{blue}{\frac{1}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      11. un-div-inv99.2%

        \[\leadsto \color{blue}{\frac{y}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      12. *-commutative99.2%

        \[\leadsto \frac{y}{\frac{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      13. fma-undefine99.2%

        \[\leadsto \frac{y}{\frac{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      14. fma-define99.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z + 0.279195317918525}}} + x \]
      15. *-commutative99.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)} + 0.279195317918525}} + x \]
      16. fma-undefine99.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}}} + x \]
    6. Applied egg-rr99.2%

      \[\leadsto \color{blue}{\frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}} + x} \]
    7. Taylor expanded in z around 0 99.5%

      \[\leadsto \frac{y}{\color{blue}{12.000000000000014 + z \cdot \left(0.39999999996247915 + z \cdot \left(0.07852944389170011 \cdot z - 0.10095235035524991\right)\right)}} + x \]

    if 3 < z

    1. Initial program 42.7%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative42.7%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative42.7%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*51.4%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified51.4%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. fma-undefine51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x} \]
      2. fma-undefine51.4%

        \[\leadsto \color{blue}{\left(z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) + 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      3. *-commutative51.4%

        \[\leadsto \left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z} + 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      4. fma-define51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      5. fma-undefine51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304}} + x \]
      6. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{\left(z + 6.012459259764103\right) \cdot z} + 3.350343815022304} + x \]
      7. associate-*r/42.7%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      8. associate-*l/52.8%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \cdot y} + x \]
      9. *-commutative52.8%

        \[\leadsto \color{blue}{y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      10. clear-num52.8%

        \[\leadsto y \cdot \color{blue}{\frac{1}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      11. un-div-inv52.8%

        \[\leadsto \color{blue}{\frac{y}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      12. *-commutative52.8%

        \[\leadsto \frac{y}{\frac{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      13. fma-undefine52.8%

        \[\leadsto \frac{y}{\frac{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      14. fma-define52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z + 0.279195317918525}}} + x \]
      15. *-commutative52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)} + 0.279195317918525}} + x \]
      16. fma-undefine52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}}} + x \]
    6. Applied egg-rr52.8%

      \[\leadsto \color{blue}{\frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}} + x} \]
    7. Taylor expanded in z around inf 99.9%

      \[\leadsto \frac{y}{\color{blue}{14.431876219268936}} + x \]
  3. Recombined 3 regimes into one program.
  4. Final simplification99.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -3100:\\ \;\;\;\;x + \frac{y}{14.431876219268936 + \frac{\frac{101.23733352003822 + \frac{-655.3980091051341}{z}}{z} - 15.646356830292042}{z}}\\ \mathbf{elif}\;z \leq 3:\\ \;\;\;\;x + \frac{y}{12.000000000000014 + z \cdot \left(0.39999999996247915 + z \cdot \left(z \cdot 0.07852944389170011 - 0.10095235035524991\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{14.431876219268936}\\ \end{array} \]
  5. Add Preprocessing

Alternative 7: 99.3% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -3100:\\ \;\;\;\;x + y \cdot \left(0.0692910599291889 - \frac{\frac{0.4046220386999212}{z} + -0.07512208616047561}{z}\right)\\ \mathbf{elif}\;z \leq 3:\\ \;\;\;\;x + \frac{y}{12.000000000000014 + z \cdot \left(0.39999999996247915 + z \cdot \left(z \cdot 0.07852944389170011 - 0.10095235035524991\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{14.431876219268936}\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (if (<= z -3100.0)
   (+
    x
    (*
     y
     (-
      0.0692910599291889
      (/ (+ (/ 0.4046220386999212 z) -0.07512208616047561) z))))
   (if (<= z 3.0)
     (+
      x
      (/
       y
       (+
        12.000000000000014
        (*
         z
         (+
          0.39999999996247915
          (* z (- (* z 0.07852944389170011) 0.10095235035524991)))))))
     (+ x (/ y 14.431876219268936)))))
double code(double x, double y, double z) {
	double tmp;
	if (z <= -3100.0) {
		tmp = x + (y * (0.0692910599291889 - (((0.4046220386999212 / z) + -0.07512208616047561) / z)));
	} else if (z <= 3.0) {
		tmp = x + (y / (12.000000000000014 + (z * (0.39999999996247915 + (z * ((z * 0.07852944389170011) - 0.10095235035524991))))));
	} else {
		tmp = x + (y / 14.431876219268936);
	}
	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 <= (-3100.0d0)) then
        tmp = x + (y * (0.0692910599291889d0 - (((0.4046220386999212d0 / z) + (-0.07512208616047561d0)) / z)))
    else if (z <= 3.0d0) then
        tmp = x + (y / (12.000000000000014d0 + (z * (0.39999999996247915d0 + (z * ((z * 0.07852944389170011d0) - 0.10095235035524991d0))))))
    else
        tmp = x + (y / 14.431876219268936d0)
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double tmp;
	if (z <= -3100.0) {
		tmp = x + (y * (0.0692910599291889 - (((0.4046220386999212 / z) + -0.07512208616047561) / z)));
	} else if (z <= 3.0) {
		tmp = x + (y / (12.000000000000014 + (z * (0.39999999996247915 + (z * ((z * 0.07852944389170011) - 0.10095235035524991))))));
	} else {
		tmp = x + (y / 14.431876219268936);
	}
	return tmp;
}
def code(x, y, z):
	tmp = 0
	if z <= -3100.0:
		tmp = x + (y * (0.0692910599291889 - (((0.4046220386999212 / z) + -0.07512208616047561) / z)))
	elif z <= 3.0:
		tmp = x + (y / (12.000000000000014 + (z * (0.39999999996247915 + (z * ((z * 0.07852944389170011) - 0.10095235035524991))))))
	else:
		tmp = x + (y / 14.431876219268936)
	return tmp
function code(x, y, z)
	tmp = 0.0
	if (z <= -3100.0)
		tmp = Float64(x + Float64(y * Float64(0.0692910599291889 - Float64(Float64(Float64(0.4046220386999212 / z) + -0.07512208616047561) / z))));
	elseif (z <= 3.0)
		tmp = Float64(x + Float64(y / Float64(12.000000000000014 + Float64(z * Float64(0.39999999996247915 + Float64(z * Float64(Float64(z * 0.07852944389170011) - 0.10095235035524991)))))));
	else
		tmp = Float64(x + Float64(y / 14.431876219268936));
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	tmp = 0.0;
	if (z <= -3100.0)
		tmp = x + (y * (0.0692910599291889 - (((0.4046220386999212 / z) + -0.07512208616047561) / z)));
	elseif (z <= 3.0)
		tmp = x + (y / (12.000000000000014 + (z * (0.39999999996247915 + (z * ((z * 0.07852944389170011) - 0.10095235035524991))))));
	else
		tmp = x + (y / 14.431876219268936);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := If[LessEqual[z, -3100.0], N[(x + N[(y * N[(0.0692910599291889 - N[(N[(N[(0.4046220386999212 / z), $MachinePrecision] + -0.07512208616047561), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 3.0], N[(x + N[(y / N[(12.000000000000014 + N[(z * N[(0.39999999996247915 + N[(z * N[(N[(z * 0.07852944389170011), $MachinePrecision] - 0.10095235035524991), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(y / 14.431876219268936), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -3100:\\
\;\;\;\;x + y \cdot \left(0.0692910599291889 - \frac{\frac{0.4046220386999212}{z} + -0.07512208616047561}{z}\right)\\

\mathbf{elif}\;z \leq 3:\\
\;\;\;\;x + \frac{y}{12.000000000000014 + z \cdot \left(0.39999999996247915 + z \cdot \left(z \cdot 0.07852944389170011 - 0.10095235035524991\right)\right)}\\

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


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

    1. Initial program 42.7%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. remove-double-neg42.7%

        \[\leadsto x + \color{blue}{\left(-\left(-\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      2. associate-/l*52.2%

        \[\leadsto x + \left(-\left(-\color{blue}{y \cdot \frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}}\right)\right) \]
      3. distribute-rgt-neg-in52.2%

        \[\leadsto x + \left(-\color{blue}{y \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)}\right) \]
      4. distribute-lft-neg-in52.2%

        \[\leadsto x + \color{blue}{\left(-y\right) \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)} \]
      5. distribute-lft-neg-in52.2%

        \[\leadsto x + \color{blue}{\left(-y \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      6. distribute-rgt-neg-in52.2%

        \[\leadsto x + \color{blue}{y \cdot \left(-\left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      7. remove-double-neg52.2%

        \[\leadsto x + y \cdot \color{blue}{\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} \]
      8. fma-define52.2%

        \[\leadsto x + y \cdot \frac{\color{blue}{\mathsf{fma}\left(z \cdot 0.0692910599291889 + 0.4917317610505968, z, 0.279195317918525\right)}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
      9. fma-define52.1%

        \[\leadsto x + y \cdot \frac{\mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
      10. fma-define52.1%

        \[\leadsto x + y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\color{blue}{\mathsf{fma}\left(z + 6.012459259764103, z, 3.350343815022304\right)}} \]
    3. Simplified52.1%

      \[\leadsto \color{blue}{x + y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\mathsf{fma}\left(z + 6.012459259764103, z, 3.350343815022304\right)}} \]
    4. Add Preprocessing
    5. Taylor expanded in z around -inf 99.4%

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

        \[\leadsto x + y \cdot \left(0.0692910599291889 + \color{blue}{\left(-\frac{0.4046220386999212 \cdot \frac{1}{z} - 0.07512208616047561}{z}\right)}\right) \]
      2. unsub-neg99.4%

        \[\leadsto x + y \cdot \color{blue}{\left(0.0692910599291889 - \frac{0.4046220386999212 \cdot \frac{1}{z} - 0.07512208616047561}{z}\right)} \]
      3. sub-neg99.4%

        \[\leadsto x + y \cdot \left(0.0692910599291889 - \frac{\color{blue}{0.4046220386999212 \cdot \frac{1}{z} + \left(-0.07512208616047561\right)}}{z}\right) \]
      4. associate-*r/99.4%

        \[\leadsto x + y \cdot \left(0.0692910599291889 - \frac{\color{blue}{\frac{0.4046220386999212 \cdot 1}{z}} + \left(-0.07512208616047561\right)}{z}\right) \]
      5. metadata-eval99.4%

        \[\leadsto x + y \cdot \left(0.0692910599291889 - \frac{\frac{\color{blue}{0.4046220386999212}}{z} + \left(-0.07512208616047561\right)}{z}\right) \]
      6. metadata-eval99.4%

        \[\leadsto x + y \cdot \left(0.0692910599291889 - \frac{\frac{0.4046220386999212}{z} + \color{blue}{-0.07512208616047561}}{z}\right) \]
    7. Simplified99.4%

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

    if -3100 < z < 3

    1. Initial program 99.5%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative99.5%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative99.5%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*99.5%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define99.5%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative99.5%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define99.5%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified99.5%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. fma-undefine99.5%

        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x} \]
      2. fma-undefine99.5%

        \[\leadsto \color{blue}{\left(z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) + 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      3. *-commutative99.5%

        \[\leadsto \left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z} + 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      4. fma-define99.5%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      5. fma-undefine99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304}} + x \]
      6. *-commutative99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{\left(z + 6.012459259764103\right) \cdot z} + 3.350343815022304} + x \]
      7. associate-*r/99.5%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      8. associate-*l/99.9%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \cdot y} + x \]
      9. *-commutative99.9%

        \[\leadsto \color{blue}{y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      10. clear-num99.0%

        \[\leadsto y \cdot \color{blue}{\frac{1}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      11. un-div-inv99.2%

        \[\leadsto \color{blue}{\frac{y}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      12. *-commutative99.2%

        \[\leadsto \frac{y}{\frac{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      13. fma-undefine99.2%

        \[\leadsto \frac{y}{\frac{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      14. fma-define99.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z + 0.279195317918525}}} + x \]
      15. *-commutative99.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)} + 0.279195317918525}} + x \]
      16. fma-undefine99.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}}} + x \]
    6. Applied egg-rr99.2%

      \[\leadsto \color{blue}{\frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}} + x} \]
    7. Taylor expanded in z around 0 99.5%

      \[\leadsto \frac{y}{\color{blue}{12.000000000000014 + z \cdot \left(0.39999999996247915 + z \cdot \left(0.07852944389170011 \cdot z - 0.10095235035524991\right)\right)}} + x \]

    if 3 < z

    1. Initial program 42.7%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative42.7%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative42.7%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*51.4%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified51.4%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. fma-undefine51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x} \]
      2. fma-undefine51.4%

        \[\leadsto \color{blue}{\left(z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) + 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      3. *-commutative51.4%

        \[\leadsto \left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z} + 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      4. fma-define51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      5. fma-undefine51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304}} + x \]
      6. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{\left(z + 6.012459259764103\right) \cdot z} + 3.350343815022304} + x \]
      7. associate-*r/42.7%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      8. associate-*l/52.8%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \cdot y} + x \]
      9. *-commutative52.8%

        \[\leadsto \color{blue}{y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      10. clear-num52.8%

        \[\leadsto y \cdot \color{blue}{\frac{1}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      11. un-div-inv52.8%

        \[\leadsto \color{blue}{\frac{y}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      12. *-commutative52.8%

        \[\leadsto \frac{y}{\frac{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      13. fma-undefine52.8%

        \[\leadsto \frac{y}{\frac{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      14. fma-define52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z + 0.279195317918525}}} + x \]
      15. *-commutative52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)} + 0.279195317918525}} + x \]
      16. fma-undefine52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}}} + x \]
    6. Applied egg-rr52.8%

      \[\leadsto \color{blue}{\frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}} + x} \]
    7. Taylor expanded in z around inf 99.9%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -3100:\\ \;\;\;\;x + y \cdot \left(0.0692910599291889 - \frac{\frac{0.4046220386999212}{z} + -0.07512208616047561}{z}\right)\\ \mathbf{elif}\;z \leq 3:\\ \;\;\;\;x + \frac{y}{12.000000000000014 + z \cdot \left(0.39999999996247915 + z \cdot \left(z \cdot 0.07852944389170011 - 0.10095235035524991\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{14.431876219268936}\\ \end{array} \]
  5. Add Preprocessing

Alternative 8: 99.2% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -3100:\\ \;\;\;\;x + y \cdot \left(0.0692910599291889 - \frac{\frac{0.4046220386999212}{z} + -0.07512208616047561}{z}\right)\\ \mathbf{elif}\;z \leq 2.75:\\ \;\;\;\;x + y \cdot \left(0.08333333333333323 + z \cdot \left(z \cdot \left(0.0007936505811533442 + z \cdot -0.0005951669793454025\right) - 0.00277777777751721\right)\right)\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{14.431876219268936}\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (if (<= z -3100.0)
   (+
    x
    (*
     y
     (-
      0.0692910599291889
      (/ (+ (/ 0.4046220386999212 z) -0.07512208616047561) z))))
   (if (<= z 2.75)
     (+
      x
      (*
       y
       (+
        0.08333333333333323
        (*
         z
         (-
          (* z (+ 0.0007936505811533442 (* z -0.0005951669793454025)))
          0.00277777777751721)))))
     (+ x (/ y 14.431876219268936)))))
double code(double x, double y, double z) {
	double tmp;
	if (z <= -3100.0) {
		tmp = x + (y * (0.0692910599291889 - (((0.4046220386999212 / z) + -0.07512208616047561) / z)));
	} else if (z <= 2.75) {
		tmp = x + (y * (0.08333333333333323 + (z * ((z * (0.0007936505811533442 + (z * -0.0005951669793454025))) - 0.00277777777751721))));
	} else {
		tmp = x + (y / 14.431876219268936);
	}
	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 <= (-3100.0d0)) then
        tmp = x + (y * (0.0692910599291889d0 - (((0.4046220386999212d0 / z) + (-0.07512208616047561d0)) / z)))
    else if (z <= 2.75d0) then
        tmp = x + (y * (0.08333333333333323d0 + (z * ((z * (0.0007936505811533442d0 + (z * (-0.0005951669793454025d0)))) - 0.00277777777751721d0))))
    else
        tmp = x + (y / 14.431876219268936d0)
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double tmp;
	if (z <= -3100.0) {
		tmp = x + (y * (0.0692910599291889 - (((0.4046220386999212 / z) + -0.07512208616047561) / z)));
	} else if (z <= 2.75) {
		tmp = x + (y * (0.08333333333333323 + (z * ((z * (0.0007936505811533442 + (z * -0.0005951669793454025))) - 0.00277777777751721))));
	} else {
		tmp = x + (y / 14.431876219268936);
	}
	return tmp;
}
def code(x, y, z):
	tmp = 0
	if z <= -3100.0:
		tmp = x + (y * (0.0692910599291889 - (((0.4046220386999212 / z) + -0.07512208616047561) / z)))
	elif z <= 2.75:
		tmp = x + (y * (0.08333333333333323 + (z * ((z * (0.0007936505811533442 + (z * -0.0005951669793454025))) - 0.00277777777751721))))
	else:
		tmp = x + (y / 14.431876219268936)
	return tmp
function code(x, y, z)
	tmp = 0.0
	if (z <= -3100.0)
		tmp = Float64(x + Float64(y * Float64(0.0692910599291889 - Float64(Float64(Float64(0.4046220386999212 / z) + -0.07512208616047561) / z))));
	elseif (z <= 2.75)
		tmp = Float64(x + Float64(y * Float64(0.08333333333333323 + Float64(z * Float64(Float64(z * Float64(0.0007936505811533442 + Float64(z * -0.0005951669793454025))) - 0.00277777777751721)))));
	else
		tmp = Float64(x + Float64(y / 14.431876219268936));
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	tmp = 0.0;
	if (z <= -3100.0)
		tmp = x + (y * (0.0692910599291889 - (((0.4046220386999212 / z) + -0.07512208616047561) / z)));
	elseif (z <= 2.75)
		tmp = x + (y * (0.08333333333333323 + (z * ((z * (0.0007936505811533442 + (z * -0.0005951669793454025))) - 0.00277777777751721))));
	else
		tmp = x + (y / 14.431876219268936);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := If[LessEqual[z, -3100.0], N[(x + N[(y * N[(0.0692910599291889 - N[(N[(N[(0.4046220386999212 / z), $MachinePrecision] + -0.07512208616047561), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2.75], N[(x + N[(y * N[(0.08333333333333323 + N[(z * N[(N[(z * N[(0.0007936505811533442 + N[(z * -0.0005951669793454025), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - 0.00277777777751721), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(y / 14.431876219268936), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -3100:\\
\;\;\;\;x + y \cdot \left(0.0692910599291889 - \frac{\frac{0.4046220386999212}{z} + -0.07512208616047561}{z}\right)\\

\mathbf{elif}\;z \leq 2.75:\\
\;\;\;\;x + y \cdot \left(0.08333333333333323 + z \cdot \left(z \cdot \left(0.0007936505811533442 + z \cdot -0.0005951669793454025\right) - 0.00277777777751721\right)\right)\\

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


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

    1. Initial program 42.7%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. remove-double-neg42.7%

        \[\leadsto x + \color{blue}{\left(-\left(-\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      2. associate-/l*52.2%

        \[\leadsto x + \left(-\left(-\color{blue}{y \cdot \frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}}\right)\right) \]
      3. distribute-rgt-neg-in52.2%

        \[\leadsto x + \left(-\color{blue}{y \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)}\right) \]
      4. distribute-lft-neg-in52.2%

        \[\leadsto x + \color{blue}{\left(-y\right) \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)} \]
      5. distribute-lft-neg-in52.2%

        \[\leadsto x + \color{blue}{\left(-y \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      6. distribute-rgt-neg-in52.2%

        \[\leadsto x + \color{blue}{y \cdot \left(-\left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      7. remove-double-neg52.2%

        \[\leadsto x + y \cdot \color{blue}{\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} \]
      8. fma-define52.2%

        \[\leadsto x + y \cdot \frac{\color{blue}{\mathsf{fma}\left(z \cdot 0.0692910599291889 + 0.4917317610505968, z, 0.279195317918525\right)}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
      9. fma-define52.1%

        \[\leadsto x + y \cdot \frac{\mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
      10. fma-define52.1%

        \[\leadsto x + y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\color{blue}{\mathsf{fma}\left(z + 6.012459259764103, z, 3.350343815022304\right)}} \]
    3. Simplified52.1%

      \[\leadsto \color{blue}{x + y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\mathsf{fma}\left(z + 6.012459259764103, z, 3.350343815022304\right)}} \]
    4. Add Preprocessing
    5. Taylor expanded in z around -inf 99.4%

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

        \[\leadsto x + y \cdot \left(0.0692910599291889 + \color{blue}{\left(-\frac{0.4046220386999212 \cdot \frac{1}{z} - 0.07512208616047561}{z}\right)}\right) \]
      2. unsub-neg99.4%

        \[\leadsto x + y \cdot \color{blue}{\left(0.0692910599291889 - \frac{0.4046220386999212 \cdot \frac{1}{z} - 0.07512208616047561}{z}\right)} \]
      3. sub-neg99.4%

        \[\leadsto x + y \cdot \left(0.0692910599291889 - \frac{\color{blue}{0.4046220386999212 \cdot \frac{1}{z} + \left(-0.07512208616047561\right)}}{z}\right) \]
      4. associate-*r/99.4%

        \[\leadsto x + y \cdot \left(0.0692910599291889 - \frac{\color{blue}{\frac{0.4046220386999212 \cdot 1}{z}} + \left(-0.07512208616047561\right)}{z}\right) \]
      5. metadata-eval99.4%

        \[\leadsto x + y \cdot \left(0.0692910599291889 - \frac{\frac{\color{blue}{0.4046220386999212}}{z} + \left(-0.07512208616047561\right)}{z}\right) \]
      6. metadata-eval99.4%

        \[\leadsto x + y \cdot \left(0.0692910599291889 - \frac{\frac{0.4046220386999212}{z} + \color{blue}{-0.07512208616047561}}{z}\right) \]
    7. Simplified99.4%

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

    if -3100 < z < 2.75

    1. Initial program 99.5%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. remove-double-neg99.5%

        \[\leadsto x + \color{blue}{\left(-\left(-\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      2. associate-/l*99.9%

        \[\leadsto x + \left(-\left(-\color{blue}{y \cdot \frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}}\right)\right) \]
      3. distribute-rgt-neg-in99.9%

        \[\leadsto x + \left(-\color{blue}{y \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)}\right) \]
      4. distribute-lft-neg-in99.9%

        \[\leadsto x + \color{blue}{\left(-y\right) \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)} \]
      5. distribute-lft-neg-in99.9%

        \[\leadsto x + \color{blue}{\left(-y \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      6. distribute-rgt-neg-in99.9%

        \[\leadsto x + \color{blue}{y \cdot \left(-\left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      7. remove-double-neg99.9%

        \[\leadsto x + y \cdot \color{blue}{\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} \]
      8. fma-define99.9%

        \[\leadsto x + y \cdot \frac{\color{blue}{\mathsf{fma}\left(z \cdot 0.0692910599291889 + 0.4917317610505968, z, 0.279195317918525\right)}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
      9. fma-define99.9%

        \[\leadsto x + y \cdot \frac{\mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
      10. fma-define99.9%

        \[\leadsto x + y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\color{blue}{\mathsf{fma}\left(z + 6.012459259764103, z, 3.350343815022304\right)}} \]
    3. Simplified99.9%

      \[\leadsto \color{blue}{x + y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\mathsf{fma}\left(z + 6.012459259764103, z, 3.350343815022304\right)}} \]
    4. Add Preprocessing
    5. Taylor expanded in z around 0 99.4%

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

    if 2.75 < z

    1. Initial program 42.7%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative42.7%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative42.7%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*51.4%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified51.4%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. fma-undefine51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x} \]
      2. fma-undefine51.4%

        \[\leadsto \color{blue}{\left(z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) + 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      3. *-commutative51.4%

        \[\leadsto \left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z} + 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      4. fma-define51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      5. fma-undefine51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304}} + x \]
      6. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{\left(z + 6.012459259764103\right) \cdot z} + 3.350343815022304} + x \]
      7. associate-*r/42.7%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      8. associate-*l/52.8%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \cdot y} + x \]
      9. *-commutative52.8%

        \[\leadsto \color{blue}{y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      10. clear-num52.8%

        \[\leadsto y \cdot \color{blue}{\frac{1}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      11. un-div-inv52.8%

        \[\leadsto \color{blue}{\frac{y}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      12. *-commutative52.8%

        \[\leadsto \frac{y}{\frac{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      13. fma-undefine52.8%

        \[\leadsto \frac{y}{\frac{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      14. fma-define52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z + 0.279195317918525}}} + x \]
      15. *-commutative52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)} + 0.279195317918525}} + x \]
      16. fma-undefine52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}}} + x \]
    6. Applied egg-rr52.8%

      \[\leadsto \color{blue}{\frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}} + x} \]
    7. Taylor expanded in z around inf 99.9%

      \[\leadsto \frac{y}{\color{blue}{14.431876219268936}} + x \]
  3. Recombined 3 regimes into one program.
  4. Final simplification99.5%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -3100:\\ \;\;\;\;x + y \cdot \left(0.0692910599291889 - \frac{\frac{0.4046220386999212}{z} + -0.07512208616047561}{z}\right)\\ \mathbf{elif}\;z \leq 2.75:\\ \;\;\;\;x + y \cdot \left(0.08333333333333323 + z \cdot \left(z \cdot \left(0.0007936505811533442 + z \cdot -0.0005951669793454025\right) - 0.00277777777751721\right)\right)\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{14.431876219268936}\\ \end{array} \]
  5. Add Preprocessing

Alternative 9: 59.4% accurate, 0.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;x \leq -2.6 \cdot 10^{+35}:\\ \;\;\;\;x\\ \mathbf{elif}\;x \leq -6.8 \cdot 10^{-99}:\\ \;\;\;\;y \cdot 0.08333333333333323\\ \mathbf{elif}\;x \leq 6 \cdot 10^{-230}:\\ \;\;\;\;y \cdot 0.0692910599291889\\ \mathbf{elif}\;x \leq 5.2 \cdot 10^{-52}:\\ \;\;\;\;y \cdot 0.08333333333333323\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (if (<= x -2.6e+35)
   x
   (if (<= x -6.8e-99)
     (* y 0.08333333333333323)
     (if (<= x 6e-230)
       (* y 0.0692910599291889)
       (if (<= x 5.2e-52) (* y 0.08333333333333323) x)))))
double code(double x, double y, double z) {
	double tmp;
	if (x <= -2.6e+35) {
		tmp = x;
	} else if (x <= -6.8e-99) {
		tmp = y * 0.08333333333333323;
	} else if (x <= 6e-230) {
		tmp = y * 0.0692910599291889;
	} else if (x <= 5.2e-52) {
		tmp = y * 0.08333333333333323;
	} else {
		tmp = 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 <= (-2.6d+35)) then
        tmp = x
    else if (x <= (-6.8d-99)) then
        tmp = y * 0.08333333333333323d0
    else if (x <= 6d-230) then
        tmp = y * 0.0692910599291889d0
    else if (x <= 5.2d-52) then
        tmp = y * 0.08333333333333323d0
    else
        tmp = x
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double tmp;
	if (x <= -2.6e+35) {
		tmp = x;
	} else if (x <= -6.8e-99) {
		tmp = y * 0.08333333333333323;
	} else if (x <= 6e-230) {
		tmp = y * 0.0692910599291889;
	} else if (x <= 5.2e-52) {
		tmp = y * 0.08333333333333323;
	} else {
		tmp = x;
	}
	return tmp;
}
def code(x, y, z):
	tmp = 0
	if x <= -2.6e+35:
		tmp = x
	elif x <= -6.8e-99:
		tmp = y * 0.08333333333333323
	elif x <= 6e-230:
		tmp = y * 0.0692910599291889
	elif x <= 5.2e-52:
		tmp = y * 0.08333333333333323
	else:
		tmp = x
	return tmp
function code(x, y, z)
	tmp = 0.0
	if (x <= -2.6e+35)
		tmp = x;
	elseif (x <= -6.8e-99)
		tmp = Float64(y * 0.08333333333333323);
	elseif (x <= 6e-230)
		tmp = Float64(y * 0.0692910599291889);
	elseif (x <= 5.2e-52)
		tmp = Float64(y * 0.08333333333333323);
	else
		tmp = x;
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	tmp = 0.0;
	if (x <= -2.6e+35)
		tmp = x;
	elseif (x <= -6.8e-99)
		tmp = y * 0.08333333333333323;
	elseif (x <= 6e-230)
		tmp = y * 0.0692910599291889;
	elseif (x <= 5.2e-52)
		tmp = y * 0.08333333333333323;
	else
		tmp = x;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := If[LessEqual[x, -2.6e+35], x, If[LessEqual[x, -6.8e-99], N[(y * 0.08333333333333323), $MachinePrecision], If[LessEqual[x, 6e-230], N[(y * 0.0692910599291889), $MachinePrecision], If[LessEqual[x, 5.2e-52], N[(y * 0.08333333333333323), $MachinePrecision], x]]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;x \leq -2.6 \cdot 10^{+35}:\\
\;\;\;\;x\\

\mathbf{elif}\;x \leq -6.8 \cdot 10^{-99}:\\
\;\;\;\;y \cdot 0.08333333333333323\\

\mathbf{elif}\;x \leq 6 \cdot 10^{-230}:\\
\;\;\;\;y \cdot 0.0692910599291889\\

\mathbf{elif}\;x \leq 5.2 \cdot 10^{-52}:\\
\;\;\;\;y \cdot 0.08333333333333323\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if x < -2.60000000000000007e35 or 5.1999999999999997e-52 < x

    1. Initial program 72.2%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative72.2%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative72.2%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*77.3%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define77.3%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative77.3%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define77.3%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define77.3%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative77.3%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define77.3%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified77.3%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in y around 0 72.9%

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

    if -2.60000000000000007e35 < x < -6.80000000000000014e-99 or 6e-230 < x < 5.1999999999999997e-52

    1. Initial program 75.1%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative75.1%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative75.1%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*81.2%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define81.2%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative81.2%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define81.2%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define81.2%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative81.2%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define81.2%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified81.2%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in z around 0 77.2%

      \[\leadsto \color{blue}{x + 0.08333333333333323 \cdot y} \]
    6. Step-by-step derivation
      1. +-commutative77.2%

        \[\leadsto \color{blue}{0.08333333333333323 \cdot y + x} \]
    7. Simplified77.2%

      \[\leadsto \color{blue}{0.08333333333333323 \cdot y + x} \]
    8. Taylor expanded in y around inf 61.6%

      \[\leadsto \color{blue}{0.08333333333333323 \cdot y} \]

    if -6.80000000000000014e-99 < x < 6e-230

    1. Initial program 65.7%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative65.7%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative65.7%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*63.8%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define63.8%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative63.8%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define63.8%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define63.8%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative63.8%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define63.8%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified63.8%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in z around inf 74.5%

      \[\leadsto \color{blue}{x + 0.0692910599291889 \cdot y} \]
    6. Step-by-step derivation
      1. +-commutative74.5%

        \[\leadsto \color{blue}{0.0692910599291889 \cdot y + x} \]
    7. Simplified74.5%

      \[\leadsto \color{blue}{0.0692910599291889 \cdot y + x} \]
    8. Taylor expanded in y around inf 63.3%

      \[\leadsto \color{blue}{0.0692910599291889 \cdot y} \]
    9. Step-by-step derivation
      1. *-commutative63.3%

        \[\leadsto \color{blue}{y \cdot 0.0692910599291889} \]
    10. Simplified63.3%

      \[\leadsto \color{blue}{y \cdot 0.0692910599291889} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification67.6%

    \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq -2.6 \cdot 10^{+35}:\\ \;\;\;\;x\\ \mathbf{elif}\;x \leq -6.8 \cdot 10^{-99}:\\ \;\;\;\;y \cdot 0.08333333333333323\\ \mathbf{elif}\;x \leq 6 \cdot 10^{-230}:\\ \;\;\;\;y \cdot 0.0692910599291889\\ \mathbf{elif}\;x \leq 5.2 \cdot 10^{-52}:\\ \;\;\;\;y \cdot 0.08333333333333323\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]
  5. Add Preprocessing

Alternative 10: 99.2% accurate, 0.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -3100:\\ \;\;\;\;x + y \cdot \left(0.0692910599291889 - \frac{\frac{0.4046220386999212}{z} + -0.07512208616047561}{z}\right)\\ \mathbf{elif}\;z \leq 4.6:\\ \;\;\;\;x + \frac{y}{12.000000000000014 + z \cdot \left(0.39999999996247915 + z \cdot -0.10095235035524991\right)}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{14.431876219268936}\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (if (<= z -3100.0)
   (+
    x
    (*
     y
     (-
      0.0692910599291889
      (/ (+ (/ 0.4046220386999212 z) -0.07512208616047561) z))))
   (if (<= z 4.6)
     (+
      x
      (/
       y
       (+
        12.000000000000014
        (* z (+ 0.39999999996247915 (* z -0.10095235035524991))))))
     (+ x (/ y 14.431876219268936)))))
double code(double x, double y, double z) {
	double tmp;
	if (z <= -3100.0) {
		tmp = x + (y * (0.0692910599291889 - (((0.4046220386999212 / z) + -0.07512208616047561) / z)));
	} else if (z <= 4.6) {
		tmp = x + (y / (12.000000000000014 + (z * (0.39999999996247915 + (z * -0.10095235035524991)))));
	} else {
		tmp = x + (y / 14.431876219268936);
	}
	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 <= (-3100.0d0)) then
        tmp = x + (y * (0.0692910599291889d0 - (((0.4046220386999212d0 / z) + (-0.07512208616047561d0)) / z)))
    else if (z <= 4.6d0) then
        tmp = x + (y / (12.000000000000014d0 + (z * (0.39999999996247915d0 + (z * (-0.10095235035524991d0))))))
    else
        tmp = x + (y / 14.431876219268936d0)
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double tmp;
	if (z <= -3100.0) {
		tmp = x + (y * (0.0692910599291889 - (((0.4046220386999212 / z) + -0.07512208616047561) / z)));
	} else if (z <= 4.6) {
		tmp = x + (y / (12.000000000000014 + (z * (0.39999999996247915 + (z * -0.10095235035524991)))));
	} else {
		tmp = x + (y / 14.431876219268936);
	}
	return tmp;
}
def code(x, y, z):
	tmp = 0
	if z <= -3100.0:
		tmp = x + (y * (0.0692910599291889 - (((0.4046220386999212 / z) + -0.07512208616047561) / z)))
	elif z <= 4.6:
		tmp = x + (y / (12.000000000000014 + (z * (0.39999999996247915 + (z * -0.10095235035524991)))))
	else:
		tmp = x + (y / 14.431876219268936)
	return tmp
function code(x, y, z)
	tmp = 0.0
	if (z <= -3100.0)
		tmp = Float64(x + Float64(y * Float64(0.0692910599291889 - Float64(Float64(Float64(0.4046220386999212 / z) + -0.07512208616047561) / z))));
	elseif (z <= 4.6)
		tmp = Float64(x + Float64(y / Float64(12.000000000000014 + Float64(z * Float64(0.39999999996247915 + Float64(z * -0.10095235035524991))))));
	else
		tmp = Float64(x + Float64(y / 14.431876219268936));
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	tmp = 0.0;
	if (z <= -3100.0)
		tmp = x + (y * (0.0692910599291889 - (((0.4046220386999212 / z) + -0.07512208616047561) / z)));
	elseif (z <= 4.6)
		tmp = x + (y / (12.000000000000014 + (z * (0.39999999996247915 + (z * -0.10095235035524991)))));
	else
		tmp = x + (y / 14.431876219268936);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := If[LessEqual[z, -3100.0], N[(x + N[(y * N[(0.0692910599291889 - N[(N[(N[(0.4046220386999212 / z), $MachinePrecision] + -0.07512208616047561), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 4.6], N[(x + N[(y / N[(12.000000000000014 + N[(z * N[(0.39999999996247915 + N[(z * -0.10095235035524991), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(y / 14.431876219268936), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -3100:\\
\;\;\;\;x + y \cdot \left(0.0692910599291889 - \frac{\frac{0.4046220386999212}{z} + -0.07512208616047561}{z}\right)\\

\mathbf{elif}\;z \leq 4.6:\\
\;\;\;\;x + \frac{y}{12.000000000000014 + z \cdot \left(0.39999999996247915 + z \cdot -0.10095235035524991\right)}\\

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


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

    1. Initial program 42.7%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. remove-double-neg42.7%

        \[\leadsto x + \color{blue}{\left(-\left(-\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      2. associate-/l*52.2%

        \[\leadsto x + \left(-\left(-\color{blue}{y \cdot \frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}}\right)\right) \]
      3. distribute-rgt-neg-in52.2%

        \[\leadsto x + \left(-\color{blue}{y \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)}\right) \]
      4. distribute-lft-neg-in52.2%

        \[\leadsto x + \color{blue}{\left(-y\right) \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)} \]
      5. distribute-lft-neg-in52.2%

        \[\leadsto x + \color{blue}{\left(-y \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      6. distribute-rgt-neg-in52.2%

        \[\leadsto x + \color{blue}{y \cdot \left(-\left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      7. remove-double-neg52.2%

        \[\leadsto x + y \cdot \color{blue}{\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} \]
      8. fma-define52.2%

        \[\leadsto x + y \cdot \frac{\color{blue}{\mathsf{fma}\left(z \cdot 0.0692910599291889 + 0.4917317610505968, z, 0.279195317918525\right)}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
      9. fma-define52.1%

        \[\leadsto x + y \cdot \frac{\mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
      10. fma-define52.1%

        \[\leadsto x + y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\color{blue}{\mathsf{fma}\left(z + 6.012459259764103, z, 3.350343815022304\right)}} \]
    3. Simplified52.1%

      \[\leadsto \color{blue}{x + y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\mathsf{fma}\left(z + 6.012459259764103, z, 3.350343815022304\right)}} \]
    4. Add Preprocessing
    5. Taylor expanded in z around -inf 99.4%

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

        \[\leadsto x + y \cdot \left(0.0692910599291889 + \color{blue}{\left(-\frac{0.4046220386999212 \cdot \frac{1}{z} - 0.07512208616047561}{z}\right)}\right) \]
      2. unsub-neg99.4%

        \[\leadsto x + y \cdot \color{blue}{\left(0.0692910599291889 - \frac{0.4046220386999212 \cdot \frac{1}{z} - 0.07512208616047561}{z}\right)} \]
      3. sub-neg99.4%

        \[\leadsto x + y \cdot \left(0.0692910599291889 - \frac{\color{blue}{0.4046220386999212 \cdot \frac{1}{z} + \left(-0.07512208616047561\right)}}{z}\right) \]
      4. associate-*r/99.4%

        \[\leadsto x + y \cdot \left(0.0692910599291889 - \frac{\color{blue}{\frac{0.4046220386999212 \cdot 1}{z}} + \left(-0.07512208616047561\right)}{z}\right) \]
      5. metadata-eval99.4%

        \[\leadsto x + y \cdot \left(0.0692910599291889 - \frac{\frac{\color{blue}{0.4046220386999212}}{z} + \left(-0.07512208616047561\right)}{z}\right) \]
      6. metadata-eval99.4%

        \[\leadsto x + y \cdot \left(0.0692910599291889 - \frac{\frac{0.4046220386999212}{z} + \color{blue}{-0.07512208616047561}}{z}\right) \]
    7. Simplified99.4%

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

    if -3100 < z < 4.5999999999999996

    1. Initial program 99.5%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative99.5%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative99.5%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*99.5%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define99.5%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative99.5%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define99.5%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified99.5%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. fma-undefine99.5%

        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x} \]
      2. fma-undefine99.5%

        \[\leadsto \color{blue}{\left(z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) + 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      3. *-commutative99.5%

        \[\leadsto \left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z} + 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      4. fma-define99.5%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      5. fma-undefine99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304}} + x \]
      6. *-commutative99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{\left(z + 6.012459259764103\right) \cdot z} + 3.350343815022304} + x \]
      7. associate-*r/99.5%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      8. associate-*l/99.9%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \cdot y} + x \]
      9. *-commutative99.9%

        \[\leadsto \color{blue}{y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      10. clear-num99.0%

        \[\leadsto y \cdot \color{blue}{\frac{1}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      11. un-div-inv99.2%

        \[\leadsto \color{blue}{\frac{y}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      12. *-commutative99.2%

        \[\leadsto \frac{y}{\frac{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      13. fma-undefine99.2%

        \[\leadsto \frac{y}{\frac{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      14. fma-define99.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z + 0.279195317918525}}} + x \]
      15. *-commutative99.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)} + 0.279195317918525}} + x \]
      16. fma-undefine99.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}}} + x \]
    6. Applied egg-rr99.2%

      \[\leadsto \color{blue}{\frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}} + x} \]
    7. Taylor expanded in z around 0 99.4%

      \[\leadsto \frac{y}{\color{blue}{12.000000000000014 + z \cdot \left(0.39999999996247915 + -0.10095235035524991 \cdot z\right)}} + x \]
    8. Step-by-step derivation
      1. *-commutative99.4%

        \[\leadsto \frac{y}{12.000000000000014 + z \cdot \left(0.39999999996247915 + \color{blue}{z \cdot -0.10095235035524991}\right)} + x \]
    9. Simplified99.4%

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

    if 4.5999999999999996 < z

    1. Initial program 42.7%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative42.7%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative42.7%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*51.4%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified51.4%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. fma-undefine51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x} \]
      2. fma-undefine51.4%

        \[\leadsto \color{blue}{\left(z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) + 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      3. *-commutative51.4%

        \[\leadsto \left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z} + 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      4. fma-define51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      5. fma-undefine51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304}} + x \]
      6. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{\left(z + 6.012459259764103\right) \cdot z} + 3.350343815022304} + x \]
      7. associate-*r/42.7%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      8. associate-*l/52.8%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \cdot y} + x \]
      9. *-commutative52.8%

        \[\leadsto \color{blue}{y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      10. clear-num52.8%

        \[\leadsto y \cdot \color{blue}{\frac{1}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      11. un-div-inv52.8%

        \[\leadsto \color{blue}{\frac{y}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      12. *-commutative52.8%

        \[\leadsto \frac{y}{\frac{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      13. fma-undefine52.8%

        \[\leadsto \frac{y}{\frac{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      14. fma-define52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z + 0.279195317918525}}} + x \]
      15. *-commutative52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)} + 0.279195317918525}} + x \]
      16. fma-undefine52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}}} + x \]
    6. Applied egg-rr52.8%

      \[\leadsto \color{blue}{\frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}} + x} \]
    7. Taylor expanded in z around inf 99.9%

      \[\leadsto \frac{y}{\color{blue}{14.431876219268936}} + x \]
  3. Recombined 3 regimes into one program.
  4. Final simplification99.5%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -3100:\\ \;\;\;\;x + y \cdot \left(0.0692910599291889 - \frac{\frac{0.4046220386999212}{z} + -0.07512208616047561}{z}\right)\\ \mathbf{elif}\;z \leq 4.6:\\ \;\;\;\;x + \frac{y}{12.000000000000014 + z \cdot \left(0.39999999996247915 + z \cdot -0.10095235035524991\right)}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{14.431876219268936}\\ \end{array} \]
  5. Add Preprocessing

Alternative 11: 99.2% accurate, 0.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -3100:\\ \;\;\;\;x + y \cdot \left(0.0692910599291889 - \frac{\frac{0.4046220386999212}{z} + -0.07512208616047561}{z}\right)\\ \mathbf{elif}\;z \leq 4.5:\\ \;\;\;\;x + y \cdot \left(0.08333333333333323 + z \cdot \left(z \cdot 0.0007936505811533442 - 0.00277777777751721\right)\right)\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{14.431876219268936}\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (if (<= z -3100.0)
   (+
    x
    (*
     y
     (-
      0.0692910599291889
      (/ (+ (/ 0.4046220386999212 z) -0.07512208616047561) z))))
   (if (<= z 4.5)
     (+
      x
      (*
       y
       (+
        0.08333333333333323
        (* z (- (* z 0.0007936505811533442) 0.00277777777751721)))))
     (+ x (/ y 14.431876219268936)))))
double code(double x, double y, double z) {
	double tmp;
	if (z <= -3100.0) {
		tmp = x + (y * (0.0692910599291889 - (((0.4046220386999212 / z) + -0.07512208616047561) / z)));
	} else if (z <= 4.5) {
		tmp = x + (y * (0.08333333333333323 + (z * ((z * 0.0007936505811533442) - 0.00277777777751721))));
	} else {
		tmp = x + (y / 14.431876219268936);
	}
	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 <= (-3100.0d0)) then
        tmp = x + (y * (0.0692910599291889d0 - (((0.4046220386999212d0 / z) + (-0.07512208616047561d0)) / z)))
    else if (z <= 4.5d0) then
        tmp = x + (y * (0.08333333333333323d0 + (z * ((z * 0.0007936505811533442d0) - 0.00277777777751721d0))))
    else
        tmp = x + (y / 14.431876219268936d0)
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double tmp;
	if (z <= -3100.0) {
		tmp = x + (y * (0.0692910599291889 - (((0.4046220386999212 / z) + -0.07512208616047561) / z)));
	} else if (z <= 4.5) {
		tmp = x + (y * (0.08333333333333323 + (z * ((z * 0.0007936505811533442) - 0.00277777777751721))));
	} else {
		tmp = x + (y / 14.431876219268936);
	}
	return tmp;
}
def code(x, y, z):
	tmp = 0
	if z <= -3100.0:
		tmp = x + (y * (0.0692910599291889 - (((0.4046220386999212 / z) + -0.07512208616047561) / z)))
	elif z <= 4.5:
		tmp = x + (y * (0.08333333333333323 + (z * ((z * 0.0007936505811533442) - 0.00277777777751721))))
	else:
		tmp = x + (y / 14.431876219268936)
	return tmp
function code(x, y, z)
	tmp = 0.0
	if (z <= -3100.0)
		tmp = Float64(x + Float64(y * Float64(0.0692910599291889 - Float64(Float64(Float64(0.4046220386999212 / z) + -0.07512208616047561) / z))));
	elseif (z <= 4.5)
		tmp = Float64(x + Float64(y * Float64(0.08333333333333323 + Float64(z * Float64(Float64(z * 0.0007936505811533442) - 0.00277777777751721)))));
	else
		tmp = Float64(x + Float64(y / 14.431876219268936));
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	tmp = 0.0;
	if (z <= -3100.0)
		tmp = x + (y * (0.0692910599291889 - (((0.4046220386999212 / z) + -0.07512208616047561) / z)));
	elseif (z <= 4.5)
		tmp = x + (y * (0.08333333333333323 + (z * ((z * 0.0007936505811533442) - 0.00277777777751721))));
	else
		tmp = x + (y / 14.431876219268936);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := If[LessEqual[z, -3100.0], N[(x + N[(y * N[(0.0692910599291889 - N[(N[(N[(0.4046220386999212 / z), $MachinePrecision] + -0.07512208616047561), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 4.5], N[(x + N[(y * N[(0.08333333333333323 + N[(z * N[(N[(z * 0.0007936505811533442), $MachinePrecision] - 0.00277777777751721), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(y / 14.431876219268936), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -3100:\\
\;\;\;\;x + y \cdot \left(0.0692910599291889 - \frac{\frac{0.4046220386999212}{z} + -0.07512208616047561}{z}\right)\\

\mathbf{elif}\;z \leq 4.5:\\
\;\;\;\;x + y \cdot \left(0.08333333333333323 + z \cdot \left(z \cdot 0.0007936505811533442 - 0.00277777777751721\right)\right)\\

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


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

    1. Initial program 42.7%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. remove-double-neg42.7%

        \[\leadsto x + \color{blue}{\left(-\left(-\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      2. associate-/l*52.2%

        \[\leadsto x + \left(-\left(-\color{blue}{y \cdot \frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}}\right)\right) \]
      3. distribute-rgt-neg-in52.2%

        \[\leadsto x + \left(-\color{blue}{y \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)}\right) \]
      4. distribute-lft-neg-in52.2%

        \[\leadsto x + \color{blue}{\left(-y\right) \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)} \]
      5. distribute-lft-neg-in52.2%

        \[\leadsto x + \color{blue}{\left(-y \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      6. distribute-rgt-neg-in52.2%

        \[\leadsto x + \color{blue}{y \cdot \left(-\left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      7. remove-double-neg52.2%

        \[\leadsto x + y \cdot \color{blue}{\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} \]
      8. fma-define52.2%

        \[\leadsto x + y \cdot \frac{\color{blue}{\mathsf{fma}\left(z \cdot 0.0692910599291889 + 0.4917317610505968, z, 0.279195317918525\right)}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
      9. fma-define52.1%

        \[\leadsto x + y \cdot \frac{\mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
      10. fma-define52.1%

        \[\leadsto x + y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\color{blue}{\mathsf{fma}\left(z + 6.012459259764103, z, 3.350343815022304\right)}} \]
    3. Simplified52.1%

      \[\leadsto \color{blue}{x + y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\mathsf{fma}\left(z + 6.012459259764103, z, 3.350343815022304\right)}} \]
    4. Add Preprocessing
    5. Taylor expanded in z around -inf 99.4%

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

        \[\leadsto x + y \cdot \left(0.0692910599291889 + \color{blue}{\left(-\frac{0.4046220386999212 \cdot \frac{1}{z} - 0.07512208616047561}{z}\right)}\right) \]
      2. unsub-neg99.4%

        \[\leadsto x + y \cdot \color{blue}{\left(0.0692910599291889 - \frac{0.4046220386999212 \cdot \frac{1}{z} - 0.07512208616047561}{z}\right)} \]
      3. sub-neg99.4%

        \[\leadsto x + y \cdot \left(0.0692910599291889 - \frac{\color{blue}{0.4046220386999212 \cdot \frac{1}{z} + \left(-0.07512208616047561\right)}}{z}\right) \]
      4. associate-*r/99.4%

        \[\leadsto x + y \cdot \left(0.0692910599291889 - \frac{\color{blue}{\frac{0.4046220386999212 \cdot 1}{z}} + \left(-0.07512208616047561\right)}{z}\right) \]
      5. metadata-eval99.4%

        \[\leadsto x + y \cdot \left(0.0692910599291889 - \frac{\frac{\color{blue}{0.4046220386999212}}{z} + \left(-0.07512208616047561\right)}{z}\right) \]
      6. metadata-eval99.4%

        \[\leadsto x + y \cdot \left(0.0692910599291889 - \frac{\frac{0.4046220386999212}{z} + \color{blue}{-0.07512208616047561}}{z}\right) \]
    7. Simplified99.4%

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

    if -3100 < z < 4.5

    1. Initial program 99.5%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. remove-double-neg99.5%

        \[\leadsto x + \color{blue}{\left(-\left(-\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      2. associate-/l*99.9%

        \[\leadsto x + \left(-\left(-\color{blue}{y \cdot \frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}}\right)\right) \]
      3. distribute-rgt-neg-in99.9%

        \[\leadsto x + \left(-\color{blue}{y \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)}\right) \]
      4. distribute-lft-neg-in99.9%

        \[\leadsto x + \color{blue}{\left(-y\right) \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)} \]
      5. distribute-lft-neg-in99.9%

        \[\leadsto x + \color{blue}{\left(-y \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      6. distribute-rgt-neg-in99.9%

        \[\leadsto x + \color{blue}{y \cdot \left(-\left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      7. remove-double-neg99.9%

        \[\leadsto x + y \cdot \color{blue}{\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} \]
      8. fma-define99.9%

        \[\leadsto x + y \cdot \frac{\color{blue}{\mathsf{fma}\left(z \cdot 0.0692910599291889 + 0.4917317610505968, z, 0.279195317918525\right)}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
      9. fma-define99.9%

        \[\leadsto x + y \cdot \frac{\mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
      10. fma-define99.9%

        \[\leadsto x + y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\color{blue}{\mathsf{fma}\left(z + 6.012459259764103, z, 3.350343815022304\right)}} \]
    3. Simplified99.9%

      \[\leadsto \color{blue}{x + y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\mathsf{fma}\left(z + 6.012459259764103, z, 3.350343815022304\right)}} \]
    4. Add Preprocessing
    5. Taylor expanded in z around 0 99.3%

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

    if 4.5 < z

    1. Initial program 42.7%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative42.7%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative42.7%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*51.4%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified51.4%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. fma-undefine51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x} \]
      2. fma-undefine51.4%

        \[\leadsto \color{blue}{\left(z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) + 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      3. *-commutative51.4%

        \[\leadsto \left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z} + 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      4. fma-define51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      5. fma-undefine51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304}} + x \]
      6. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{\left(z + 6.012459259764103\right) \cdot z} + 3.350343815022304} + x \]
      7. associate-*r/42.7%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      8. associate-*l/52.8%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \cdot y} + x \]
      9. *-commutative52.8%

        \[\leadsto \color{blue}{y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      10. clear-num52.8%

        \[\leadsto y \cdot \color{blue}{\frac{1}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      11. un-div-inv52.8%

        \[\leadsto \color{blue}{\frac{y}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      12. *-commutative52.8%

        \[\leadsto \frac{y}{\frac{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      13. fma-undefine52.8%

        \[\leadsto \frac{y}{\frac{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      14. fma-define52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z + 0.279195317918525}}} + x \]
      15. *-commutative52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)} + 0.279195317918525}} + x \]
      16. fma-undefine52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}}} + x \]
    6. Applied egg-rr52.8%

      \[\leadsto \color{blue}{\frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}} + x} \]
    7. Taylor expanded in z around inf 99.9%

      \[\leadsto \frac{y}{\color{blue}{14.431876219268936}} + x \]
  3. Recombined 3 regimes into one program.
  4. Final simplification99.5%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -3100:\\ \;\;\;\;x + y \cdot \left(0.0692910599291889 - \frac{\frac{0.4046220386999212}{z} + -0.07512208616047561}{z}\right)\\ \mathbf{elif}\;z \leq 4.5:\\ \;\;\;\;x + y \cdot \left(0.08333333333333323 + z \cdot \left(z \cdot 0.0007936505811533442 - 0.00277777777751721\right)\right)\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{14.431876219268936}\\ \end{array} \]
  5. Add Preprocessing

Alternative 12: 99.2% accurate, 0.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -3100:\\ \;\;\;\;x + y \cdot \left(0.0692910599291889 + \frac{0.07512208616047561}{z}\right)\\ \mathbf{elif}\;z \leq 4.5:\\ \;\;\;\;x + y \cdot \left(0.08333333333333323 + z \cdot \left(z \cdot 0.0007936505811533442 - 0.00277777777751721\right)\right)\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{14.431876219268936}\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (if (<= z -3100.0)
   (+ x (* y (+ 0.0692910599291889 (/ 0.07512208616047561 z))))
   (if (<= z 4.5)
     (+
      x
      (*
       y
       (+
        0.08333333333333323
        (* z (- (* z 0.0007936505811533442) 0.00277777777751721)))))
     (+ x (/ y 14.431876219268936)))))
double code(double x, double y, double z) {
	double tmp;
	if (z <= -3100.0) {
		tmp = x + (y * (0.0692910599291889 + (0.07512208616047561 / z)));
	} else if (z <= 4.5) {
		tmp = x + (y * (0.08333333333333323 + (z * ((z * 0.0007936505811533442) - 0.00277777777751721))));
	} else {
		tmp = x + (y / 14.431876219268936);
	}
	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 <= (-3100.0d0)) then
        tmp = x + (y * (0.0692910599291889d0 + (0.07512208616047561d0 / z)))
    else if (z <= 4.5d0) then
        tmp = x + (y * (0.08333333333333323d0 + (z * ((z * 0.0007936505811533442d0) - 0.00277777777751721d0))))
    else
        tmp = x + (y / 14.431876219268936d0)
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double tmp;
	if (z <= -3100.0) {
		tmp = x + (y * (0.0692910599291889 + (0.07512208616047561 / z)));
	} else if (z <= 4.5) {
		tmp = x + (y * (0.08333333333333323 + (z * ((z * 0.0007936505811533442) - 0.00277777777751721))));
	} else {
		tmp = x + (y / 14.431876219268936);
	}
	return tmp;
}
def code(x, y, z):
	tmp = 0
	if z <= -3100.0:
		tmp = x + (y * (0.0692910599291889 + (0.07512208616047561 / z)))
	elif z <= 4.5:
		tmp = x + (y * (0.08333333333333323 + (z * ((z * 0.0007936505811533442) - 0.00277777777751721))))
	else:
		tmp = x + (y / 14.431876219268936)
	return tmp
function code(x, y, z)
	tmp = 0.0
	if (z <= -3100.0)
		tmp = Float64(x + Float64(y * Float64(0.0692910599291889 + Float64(0.07512208616047561 / z))));
	elseif (z <= 4.5)
		tmp = Float64(x + Float64(y * Float64(0.08333333333333323 + Float64(z * Float64(Float64(z * 0.0007936505811533442) - 0.00277777777751721)))));
	else
		tmp = Float64(x + Float64(y / 14.431876219268936));
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	tmp = 0.0;
	if (z <= -3100.0)
		tmp = x + (y * (0.0692910599291889 + (0.07512208616047561 / z)));
	elseif (z <= 4.5)
		tmp = x + (y * (0.08333333333333323 + (z * ((z * 0.0007936505811533442) - 0.00277777777751721))));
	else
		tmp = x + (y / 14.431876219268936);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := If[LessEqual[z, -3100.0], N[(x + N[(y * N[(0.0692910599291889 + N[(0.07512208616047561 / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 4.5], N[(x + N[(y * N[(0.08333333333333323 + N[(z * N[(N[(z * 0.0007936505811533442), $MachinePrecision] - 0.00277777777751721), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(y / 14.431876219268936), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -3100:\\
\;\;\;\;x + y \cdot \left(0.0692910599291889 + \frac{0.07512208616047561}{z}\right)\\

\mathbf{elif}\;z \leq 4.5:\\
\;\;\;\;x + y \cdot \left(0.08333333333333323 + z \cdot \left(z \cdot 0.0007936505811533442 - 0.00277777777751721\right)\right)\\

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


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

    1. Initial program 42.7%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. remove-double-neg42.7%

        \[\leadsto x + \color{blue}{\left(-\left(-\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      2. associate-/l*52.2%

        \[\leadsto x + \left(-\left(-\color{blue}{y \cdot \frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}}\right)\right) \]
      3. distribute-rgt-neg-in52.2%

        \[\leadsto x + \left(-\color{blue}{y \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)}\right) \]
      4. distribute-lft-neg-in52.2%

        \[\leadsto x + \color{blue}{\left(-y\right) \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)} \]
      5. distribute-lft-neg-in52.2%

        \[\leadsto x + \color{blue}{\left(-y \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      6. distribute-rgt-neg-in52.2%

        \[\leadsto x + \color{blue}{y \cdot \left(-\left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      7. remove-double-neg52.2%

        \[\leadsto x + y \cdot \color{blue}{\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} \]
      8. fma-define52.2%

        \[\leadsto x + y \cdot \frac{\color{blue}{\mathsf{fma}\left(z \cdot 0.0692910599291889 + 0.4917317610505968, z, 0.279195317918525\right)}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
      9. fma-define52.1%

        \[\leadsto x + y \cdot \frac{\mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
      10. fma-define52.1%

        \[\leadsto x + y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\color{blue}{\mathsf{fma}\left(z + 6.012459259764103, z, 3.350343815022304\right)}} \]
    3. Simplified52.1%

      \[\leadsto \color{blue}{x + y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\mathsf{fma}\left(z + 6.012459259764103, z, 3.350343815022304\right)}} \]
    4. Add Preprocessing
    5. Taylor expanded in z around inf 99.0%

      \[\leadsto x + y \cdot \color{blue}{\left(0.0692910599291889 + 0.07512208616047561 \cdot \frac{1}{z}\right)} \]
    6. Step-by-step derivation
      1. associate-*r/99.0%

        \[\leadsto x + y \cdot \left(0.0692910599291889 + \color{blue}{\frac{0.07512208616047561 \cdot 1}{z}}\right) \]
      2. metadata-eval99.0%

        \[\leadsto x + y \cdot \left(0.0692910599291889 + \frac{\color{blue}{0.07512208616047561}}{z}\right) \]
    7. Simplified99.0%

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

    if -3100 < z < 4.5

    1. Initial program 99.5%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. remove-double-neg99.5%

        \[\leadsto x + \color{blue}{\left(-\left(-\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      2. associate-/l*99.9%

        \[\leadsto x + \left(-\left(-\color{blue}{y \cdot \frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}}\right)\right) \]
      3. distribute-rgt-neg-in99.9%

        \[\leadsto x + \left(-\color{blue}{y \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)}\right) \]
      4. distribute-lft-neg-in99.9%

        \[\leadsto x + \color{blue}{\left(-y\right) \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)} \]
      5. distribute-lft-neg-in99.9%

        \[\leadsto x + \color{blue}{\left(-y \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      6. distribute-rgt-neg-in99.9%

        \[\leadsto x + \color{blue}{y \cdot \left(-\left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      7. remove-double-neg99.9%

        \[\leadsto x + y \cdot \color{blue}{\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} \]
      8. fma-define99.9%

        \[\leadsto x + y \cdot \frac{\color{blue}{\mathsf{fma}\left(z \cdot 0.0692910599291889 + 0.4917317610505968, z, 0.279195317918525\right)}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
      9. fma-define99.9%

        \[\leadsto x + y \cdot \frac{\mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
      10. fma-define99.9%

        \[\leadsto x + y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\color{blue}{\mathsf{fma}\left(z + 6.012459259764103, z, 3.350343815022304\right)}} \]
    3. Simplified99.9%

      \[\leadsto \color{blue}{x + y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\mathsf{fma}\left(z + 6.012459259764103, z, 3.350343815022304\right)}} \]
    4. Add Preprocessing
    5. Taylor expanded in z around 0 99.3%

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

    if 4.5 < z

    1. Initial program 42.7%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative42.7%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative42.7%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*51.4%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified51.4%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. fma-undefine51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x} \]
      2. fma-undefine51.4%

        \[\leadsto \color{blue}{\left(z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) + 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      3. *-commutative51.4%

        \[\leadsto \left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z} + 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      4. fma-define51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      5. fma-undefine51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304}} + x \]
      6. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{\left(z + 6.012459259764103\right) \cdot z} + 3.350343815022304} + x \]
      7. associate-*r/42.7%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      8. associate-*l/52.8%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \cdot y} + x \]
      9. *-commutative52.8%

        \[\leadsto \color{blue}{y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      10. clear-num52.8%

        \[\leadsto y \cdot \color{blue}{\frac{1}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      11. un-div-inv52.8%

        \[\leadsto \color{blue}{\frac{y}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      12. *-commutative52.8%

        \[\leadsto \frac{y}{\frac{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      13. fma-undefine52.8%

        \[\leadsto \frac{y}{\frac{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      14. fma-define52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z + 0.279195317918525}}} + x \]
      15. *-commutative52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)} + 0.279195317918525}} + x \]
      16. fma-undefine52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}}} + x \]
    6. Applied egg-rr52.8%

      \[\leadsto \color{blue}{\frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}} + x} \]
    7. Taylor expanded in z around inf 99.9%

      \[\leadsto \frac{y}{\color{blue}{14.431876219268936}} + x \]
  3. Recombined 3 regimes into one program.
  4. Final simplification99.4%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -3100:\\ \;\;\;\;x + y \cdot \left(0.0692910599291889 + \frac{0.07512208616047561}{z}\right)\\ \mathbf{elif}\;z \leq 4.5:\\ \;\;\;\;x + y \cdot \left(0.08333333333333323 + z \cdot \left(z \cdot 0.0007936505811533442 - 0.00277777777751721\right)\right)\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{14.431876219268936}\\ \end{array} \]
  5. Add Preprocessing

Alternative 13: 99.1% accurate, 1.1× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -3100:\\ \;\;\;\;x + y \cdot \left(0.0692910599291889 + \frac{0.07512208616047561}{z}\right)\\ \mathbf{elif}\;z \leq 6:\\ \;\;\;\;x + \frac{y}{12.000000000000014 + z \cdot 0.39999999996247915}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{14.431876219268936}\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (if (<= z -3100.0)
   (+ x (* y (+ 0.0692910599291889 (/ 0.07512208616047561 z))))
   (if (<= z 6.0)
     (+ x (/ y (+ 12.000000000000014 (* z 0.39999999996247915))))
     (+ x (/ y 14.431876219268936)))))
double code(double x, double y, double z) {
	double tmp;
	if (z <= -3100.0) {
		tmp = x + (y * (0.0692910599291889 + (0.07512208616047561 / z)));
	} else if (z <= 6.0) {
		tmp = x + (y / (12.000000000000014 + (z * 0.39999999996247915)));
	} else {
		tmp = x + (y / 14.431876219268936);
	}
	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 <= (-3100.0d0)) then
        tmp = x + (y * (0.0692910599291889d0 + (0.07512208616047561d0 / z)))
    else if (z <= 6.0d0) then
        tmp = x + (y / (12.000000000000014d0 + (z * 0.39999999996247915d0)))
    else
        tmp = x + (y / 14.431876219268936d0)
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double tmp;
	if (z <= -3100.0) {
		tmp = x + (y * (0.0692910599291889 + (0.07512208616047561 / z)));
	} else if (z <= 6.0) {
		tmp = x + (y / (12.000000000000014 + (z * 0.39999999996247915)));
	} else {
		tmp = x + (y / 14.431876219268936);
	}
	return tmp;
}
def code(x, y, z):
	tmp = 0
	if z <= -3100.0:
		tmp = x + (y * (0.0692910599291889 + (0.07512208616047561 / z)))
	elif z <= 6.0:
		tmp = x + (y / (12.000000000000014 + (z * 0.39999999996247915)))
	else:
		tmp = x + (y / 14.431876219268936)
	return tmp
function code(x, y, z)
	tmp = 0.0
	if (z <= -3100.0)
		tmp = Float64(x + Float64(y * Float64(0.0692910599291889 + Float64(0.07512208616047561 / z))));
	elseif (z <= 6.0)
		tmp = Float64(x + Float64(y / Float64(12.000000000000014 + Float64(z * 0.39999999996247915))));
	else
		tmp = Float64(x + Float64(y / 14.431876219268936));
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	tmp = 0.0;
	if (z <= -3100.0)
		tmp = x + (y * (0.0692910599291889 + (0.07512208616047561 / z)));
	elseif (z <= 6.0)
		tmp = x + (y / (12.000000000000014 + (z * 0.39999999996247915)));
	else
		tmp = x + (y / 14.431876219268936);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := If[LessEqual[z, -3100.0], N[(x + N[(y * N[(0.0692910599291889 + N[(0.07512208616047561 / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 6.0], N[(x + N[(y / N[(12.000000000000014 + N[(z * 0.39999999996247915), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(y / 14.431876219268936), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -3100:\\
\;\;\;\;x + y \cdot \left(0.0692910599291889 + \frac{0.07512208616047561}{z}\right)\\

\mathbf{elif}\;z \leq 6:\\
\;\;\;\;x + \frac{y}{12.000000000000014 + z \cdot 0.39999999996247915}\\

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


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

    1. Initial program 42.7%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. remove-double-neg42.7%

        \[\leadsto x + \color{blue}{\left(-\left(-\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      2. associate-/l*52.2%

        \[\leadsto x + \left(-\left(-\color{blue}{y \cdot \frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}}\right)\right) \]
      3. distribute-rgt-neg-in52.2%

        \[\leadsto x + \left(-\color{blue}{y \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)}\right) \]
      4. distribute-lft-neg-in52.2%

        \[\leadsto x + \color{blue}{\left(-y\right) \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)} \]
      5. distribute-lft-neg-in52.2%

        \[\leadsto x + \color{blue}{\left(-y \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      6. distribute-rgt-neg-in52.2%

        \[\leadsto x + \color{blue}{y \cdot \left(-\left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      7. remove-double-neg52.2%

        \[\leadsto x + y \cdot \color{blue}{\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} \]
      8. fma-define52.2%

        \[\leadsto x + y \cdot \frac{\color{blue}{\mathsf{fma}\left(z \cdot 0.0692910599291889 + 0.4917317610505968, z, 0.279195317918525\right)}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
      9. fma-define52.1%

        \[\leadsto x + y \cdot \frac{\mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
      10. fma-define52.1%

        \[\leadsto x + y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\color{blue}{\mathsf{fma}\left(z + 6.012459259764103, z, 3.350343815022304\right)}} \]
    3. Simplified52.1%

      \[\leadsto \color{blue}{x + y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\mathsf{fma}\left(z + 6.012459259764103, z, 3.350343815022304\right)}} \]
    4. Add Preprocessing
    5. Taylor expanded in z around inf 99.0%

      \[\leadsto x + y \cdot \color{blue}{\left(0.0692910599291889 + 0.07512208616047561 \cdot \frac{1}{z}\right)} \]
    6. Step-by-step derivation
      1. associate-*r/99.0%

        \[\leadsto x + y \cdot \left(0.0692910599291889 + \color{blue}{\frac{0.07512208616047561 \cdot 1}{z}}\right) \]
      2. metadata-eval99.0%

        \[\leadsto x + y \cdot \left(0.0692910599291889 + \frac{\color{blue}{0.07512208616047561}}{z}\right) \]
    7. Simplified99.0%

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

    if -3100 < z < 6

    1. Initial program 99.5%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative99.5%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative99.5%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*99.5%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define99.5%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative99.5%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define99.5%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified99.5%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. fma-undefine99.5%

        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x} \]
      2. fma-undefine99.5%

        \[\leadsto \color{blue}{\left(z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) + 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      3. *-commutative99.5%

        \[\leadsto \left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z} + 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      4. fma-define99.5%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      5. fma-undefine99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304}} + x \]
      6. *-commutative99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{\left(z + 6.012459259764103\right) \cdot z} + 3.350343815022304} + x \]
      7. associate-*r/99.5%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      8. associate-*l/99.9%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \cdot y} + x \]
      9. *-commutative99.9%

        \[\leadsto \color{blue}{y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      10. clear-num99.0%

        \[\leadsto y \cdot \color{blue}{\frac{1}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      11. un-div-inv99.2%

        \[\leadsto \color{blue}{\frac{y}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      12. *-commutative99.2%

        \[\leadsto \frac{y}{\frac{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      13. fma-undefine99.2%

        \[\leadsto \frac{y}{\frac{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      14. fma-define99.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z + 0.279195317918525}}} + x \]
      15. *-commutative99.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)} + 0.279195317918525}} + x \]
      16. fma-undefine99.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}}} + x \]
    6. Applied egg-rr99.2%

      \[\leadsto \color{blue}{\frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}} + x} \]
    7. Taylor expanded in z around 0 99.2%

      \[\leadsto \frac{y}{\color{blue}{12.000000000000014 + 0.39999999996247915 \cdot z}} + x \]
    8. Step-by-step derivation
      1. *-commutative99.2%

        \[\leadsto \frac{y}{12.000000000000014 + \color{blue}{z \cdot 0.39999999996247915}} + x \]
    9. Simplified99.2%

      \[\leadsto \frac{y}{\color{blue}{12.000000000000014 + z \cdot 0.39999999996247915}} + x \]

    if 6 < z

    1. Initial program 42.7%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative42.7%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative42.7%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*51.4%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified51.4%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. fma-undefine51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x} \]
      2. fma-undefine51.4%

        \[\leadsto \color{blue}{\left(z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) + 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      3. *-commutative51.4%

        \[\leadsto \left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z} + 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      4. fma-define51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      5. fma-undefine51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304}} + x \]
      6. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{\left(z + 6.012459259764103\right) \cdot z} + 3.350343815022304} + x \]
      7. associate-*r/42.7%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      8. associate-*l/52.8%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \cdot y} + x \]
      9. *-commutative52.8%

        \[\leadsto \color{blue}{y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      10. clear-num52.8%

        \[\leadsto y \cdot \color{blue}{\frac{1}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      11. un-div-inv52.8%

        \[\leadsto \color{blue}{\frac{y}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      12. *-commutative52.8%

        \[\leadsto \frac{y}{\frac{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      13. fma-undefine52.8%

        \[\leadsto \frac{y}{\frac{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      14. fma-define52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z + 0.279195317918525}}} + x \]
      15. *-commutative52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)} + 0.279195317918525}} + x \]
      16. fma-undefine52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}}} + x \]
    6. Applied egg-rr52.8%

      \[\leadsto \color{blue}{\frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}} + x} \]
    7. Taylor expanded in z around inf 99.9%

      \[\leadsto \frac{y}{\color{blue}{14.431876219268936}} + x \]
  3. Recombined 3 regimes into one program.
  4. Final simplification99.3%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -3100:\\ \;\;\;\;x + y \cdot \left(0.0692910599291889 + \frac{0.07512208616047561}{z}\right)\\ \mathbf{elif}\;z \leq 6:\\ \;\;\;\;x + \frac{y}{12.000000000000014 + z \cdot 0.39999999996247915}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{14.431876219268936}\\ \end{array} \]
  5. Add Preprocessing

Alternative 14: 99.1% accurate, 1.1× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -3100:\\ \;\;\;\;x + y \cdot \left(0.0692910599291889 + \frac{0.07512208616047561}{z}\right)\\ \mathbf{elif}\;z \leq 5:\\ \;\;\;\;x + y \cdot \left(0.08333333333333323 + z \cdot -0.00277777777751721\right)\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{14.431876219268936}\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (if (<= z -3100.0)
   (+ x (* y (+ 0.0692910599291889 (/ 0.07512208616047561 z))))
   (if (<= z 5.0)
     (+ x (* y (+ 0.08333333333333323 (* z -0.00277777777751721))))
     (+ x (/ y 14.431876219268936)))))
double code(double x, double y, double z) {
	double tmp;
	if (z <= -3100.0) {
		tmp = x + (y * (0.0692910599291889 + (0.07512208616047561 / z)));
	} else if (z <= 5.0) {
		tmp = x + (y * (0.08333333333333323 + (z * -0.00277777777751721)));
	} else {
		tmp = x + (y / 14.431876219268936);
	}
	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 <= (-3100.0d0)) then
        tmp = x + (y * (0.0692910599291889d0 + (0.07512208616047561d0 / z)))
    else if (z <= 5.0d0) then
        tmp = x + (y * (0.08333333333333323d0 + (z * (-0.00277777777751721d0))))
    else
        tmp = x + (y / 14.431876219268936d0)
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double tmp;
	if (z <= -3100.0) {
		tmp = x + (y * (0.0692910599291889 + (0.07512208616047561 / z)));
	} else if (z <= 5.0) {
		tmp = x + (y * (0.08333333333333323 + (z * -0.00277777777751721)));
	} else {
		tmp = x + (y / 14.431876219268936);
	}
	return tmp;
}
def code(x, y, z):
	tmp = 0
	if z <= -3100.0:
		tmp = x + (y * (0.0692910599291889 + (0.07512208616047561 / z)))
	elif z <= 5.0:
		tmp = x + (y * (0.08333333333333323 + (z * -0.00277777777751721)))
	else:
		tmp = x + (y / 14.431876219268936)
	return tmp
function code(x, y, z)
	tmp = 0.0
	if (z <= -3100.0)
		tmp = Float64(x + Float64(y * Float64(0.0692910599291889 + Float64(0.07512208616047561 / z))));
	elseif (z <= 5.0)
		tmp = Float64(x + Float64(y * Float64(0.08333333333333323 + Float64(z * -0.00277777777751721))));
	else
		tmp = Float64(x + Float64(y / 14.431876219268936));
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	tmp = 0.0;
	if (z <= -3100.0)
		tmp = x + (y * (0.0692910599291889 + (0.07512208616047561 / z)));
	elseif (z <= 5.0)
		tmp = x + (y * (0.08333333333333323 + (z * -0.00277777777751721)));
	else
		tmp = x + (y / 14.431876219268936);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := If[LessEqual[z, -3100.0], N[(x + N[(y * N[(0.0692910599291889 + N[(0.07512208616047561 / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 5.0], N[(x + N[(y * N[(0.08333333333333323 + N[(z * -0.00277777777751721), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(y / 14.431876219268936), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -3100:\\
\;\;\;\;x + y \cdot \left(0.0692910599291889 + \frac{0.07512208616047561}{z}\right)\\

\mathbf{elif}\;z \leq 5:\\
\;\;\;\;x + y \cdot \left(0.08333333333333323 + z \cdot -0.00277777777751721\right)\\

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


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

    1. Initial program 42.7%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. remove-double-neg42.7%

        \[\leadsto x + \color{blue}{\left(-\left(-\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      2. associate-/l*52.2%

        \[\leadsto x + \left(-\left(-\color{blue}{y \cdot \frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}}\right)\right) \]
      3. distribute-rgt-neg-in52.2%

        \[\leadsto x + \left(-\color{blue}{y \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)}\right) \]
      4. distribute-lft-neg-in52.2%

        \[\leadsto x + \color{blue}{\left(-y\right) \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)} \]
      5. distribute-lft-neg-in52.2%

        \[\leadsto x + \color{blue}{\left(-y \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      6. distribute-rgt-neg-in52.2%

        \[\leadsto x + \color{blue}{y \cdot \left(-\left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      7. remove-double-neg52.2%

        \[\leadsto x + y \cdot \color{blue}{\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} \]
      8. fma-define52.2%

        \[\leadsto x + y \cdot \frac{\color{blue}{\mathsf{fma}\left(z \cdot 0.0692910599291889 + 0.4917317610505968, z, 0.279195317918525\right)}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
      9. fma-define52.1%

        \[\leadsto x + y \cdot \frac{\mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
      10. fma-define52.1%

        \[\leadsto x + y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\color{blue}{\mathsf{fma}\left(z + 6.012459259764103, z, 3.350343815022304\right)}} \]
    3. Simplified52.1%

      \[\leadsto \color{blue}{x + y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\mathsf{fma}\left(z + 6.012459259764103, z, 3.350343815022304\right)}} \]
    4. Add Preprocessing
    5. Taylor expanded in z around inf 99.0%

      \[\leadsto x + y \cdot \color{blue}{\left(0.0692910599291889 + 0.07512208616047561 \cdot \frac{1}{z}\right)} \]
    6. Step-by-step derivation
      1. associate-*r/99.0%

        \[\leadsto x + y \cdot \left(0.0692910599291889 + \color{blue}{\frac{0.07512208616047561 \cdot 1}{z}}\right) \]
      2. metadata-eval99.0%

        \[\leadsto x + y \cdot \left(0.0692910599291889 + \frac{\color{blue}{0.07512208616047561}}{z}\right) \]
    7. Simplified99.0%

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

    if -3100 < z < 5

    1. Initial program 99.5%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. remove-double-neg99.5%

        \[\leadsto x + \color{blue}{\left(-\left(-\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      2. associate-/l*99.9%

        \[\leadsto x + \left(-\left(-\color{blue}{y \cdot \frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}}\right)\right) \]
      3. distribute-rgt-neg-in99.9%

        \[\leadsto x + \left(-\color{blue}{y \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)}\right) \]
      4. distribute-lft-neg-in99.9%

        \[\leadsto x + \color{blue}{\left(-y\right) \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)} \]
      5. distribute-lft-neg-in99.9%

        \[\leadsto x + \color{blue}{\left(-y \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      6. distribute-rgt-neg-in99.9%

        \[\leadsto x + \color{blue}{y \cdot \left(-\left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      7. remove-double-neg99.9%

        \[\leadsto x + y \cdot \color{blue}{\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} \]
      8. fma-define99.9%

        \[\leadsto x + y \cdot \frac{\color{blue}{\mathsf{fma}\left(z \cdot 0.0692910599291889 + 0.4917317610505968, z, 0.279195317918525\right)}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
      9. fma-define99.9%

        \[\leadsto x + y \cdot \frac{\mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
      10. fma-define99.9%

        \[\leadsto x + y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\color{blue}{\mathsf{fma}\left(z + 6.012459259764103, z, 3.350343815022304\right)}} \]
    3. Simplified99.9%

      \[\leadsto \color{blue}{x + y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\mathsf{fma}\left(z + 6.012459259764103, z, 3.350343815022304\right)}} \]
    4. Add Preprocessing
    5. Taylor expanded in z around 0 99.1%

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

    if 5 < z

    1. Initial program 42.7%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative42.7%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative42.7%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*51.4%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified51.4%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. fma-undefine51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x} \]
      2. fma-undefine51.4%

        \[\leadsto \color{blue}{\left(z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) + 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      3. *-commutative51.4%

        \[\leadsto \left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z} + 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      4. fma-define51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      5. fma-undefine51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304}} + x \]
      6. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{\left(z + 6.012459259764103\right) \cdot z} + 3.350343815022304} + x \]
      7. associate-*r/42.7%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      8. associate-*l/52.8%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \cdot y} + x \]
      9. *-commutative52.8%

        \[\leadsto \color{blue}{y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      10. clear-num52.8%

        \[\leadsto y \cdot \color{blue}{\frac{1}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      11. un-div-inv52.8%

        \[\leadsto \color{blue}{\frac{y}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      12. *-commutative52.8%

        \[\leadsto \frac{y}{\frac{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      13. fma-undefine52.8%

        \[\leadsto \frac{y}{\frac{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      14. fma-define52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z + 0.279195317918525}}} + x \]
      15. *-commutative52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)} + 0.279195317918525}} + x \]
      16. fma-undefine52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}}} + x \]
    6. Applied egg-rr52.8%

      \[\leadsto \color{blue}{\frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}} + x} \]
    7. Taylor expanded in z around inf 99.9%

      \[\leadsto \frac{y}{\color{blue}{14.431876219268936}} + x \]
  3. Recombined 3 regimes into one program.
  4. Final simplification99.3%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -3100:\\ \;\;\;\;x + y \cdot \left(0.0692910599291889 + \frac{0.07512208616047561}{z}\right)\\ \mathbf{elif}\;z \leq 5:\\ \;\;\;\;x + y \cdot \left(0.08333333333333323 + z \cdot -0.00277777777751721\right)\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{14.431876219268936}\\ \end{array} \]
  5. Add Preprocessing

Alternative 15: 98.9% accurate, 1.4× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -3100 \lor \neg \left(z \leq 5.8\right):\\
\;\;\;\;x + \frac{y}{14.431876219268936}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -3100 or 5.79999999999999982 < z

    1. Initial program 42.7%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative42.7%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative42.7%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*51.0%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define51.0%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative51.0%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define51.0%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define51.0%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative51.0%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define51.0%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified51.0%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. fma-undefine51.0%

        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x} \]
      2. fma-undefine51.0%

        \[\leadsto \color{blue}{\left(z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) + 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      3. *-commutative51.0%

        \[\leadsto \left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z} + 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      4. fma-define51.0%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      5. fma-undefine51.0%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304}} + x \]
      6. *-commutative51.0%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{\left(z + 6.012459259764103\right) \cdot z} + 3.350343815022304} + x \]
      7. associate-*r/42.7%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      8. associate-*l/52.5%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \cdot y} + x \]
      9. *-commutative52.5%

        \[\leadsto \color{blue}{y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      10. clear-num52.5%

        \[\leadsto y \cdot \color{blue}{\frac{1}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      11. un-div-inv52.5%

        \[\leadsto \color{blue}{\frac{y}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      12. *-commutative52.5%

        \[\leadsto \frac{y}{\frac{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      13. fma-undefine52.5%

        \[\leadsto \frac{y}{\frac{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      14. fma-define52.5%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z + 0.279195317918525}}} + x \]
      15. *-commutative52.5%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)} + 0.279195317918525}} + x \]
      16. fma-undefine52.5%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}}} + x \]
    6. Applied egg-rr52.5%

      \[\leadsto \color{blue}{\frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}} + x} \]
    7. Taylor expanded in z around inf 99.5%

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

    if -3100 < z < 5.79999999999999982

    1. Initial program 99.5%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative99.5%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative99.5%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*99.5%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define99.5%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative99.5%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define99.5%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified99.5%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. fma-undefine99.5%

        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x} \]
      2. fma-undefine99.5%

        \[\leadsto \color{blue}{\left(z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) + 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      3. *-commutative99.5%

        \[\leadsto \left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z} + 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      4. fma-define99.5%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      5. fma-undefine99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304}} + x \]
      6. *-commutative99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{\left(z + 6.012459259764103\right) \cdot z} + 3.350343815022304} + x \]
      7. associate-*r/99.5%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      8. associate-*l/99.9%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \cdot y} + x \]
      9. *-commutative99.9%

        \[\leadsto \color{blue}{y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      10. clear-num99.0%

        \[\leadsto y \cdot \color{blue}{\frac{1}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      11. un-div-inv99.2%

        \[\leadsto \color{blue}{\frac{y}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      12. *-commutative99.2%

        \[\leadsto \frac{y}{\frac{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      13. fma-undefine99.2%

        \[\leadsto \frac{y}{\frac{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      14. fma-define99.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z + 0.279195317918525}}} + x \]
      15. *-commutative99.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)} + 0.279195317918525}} + x \]
      16. fma-undefine99.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}}} + x \]
    6. Applied egg-rr99.2%

      \[\leadsto \color{blue}{\frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}} + x} \]
    7. Taylor expanded in z around 0 98.7%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -3100 \lor \neg \left(z \leq 5.8\right):\\ \;\;\;\;x + \frac{y}{14.431876219268936}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{12.000000000000014}\\ \end{array} \]
  5. Add Preprocessing

Alternative 16: 98.7% accurate, 1.4× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -3100 \lor \neg \left(z \leq 5.6\right):\\
\;\;\;\;x + y \cdot 0.0692910599291889\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -3100 or 5.5999999999999996 < z

    1. Initial program 42.7%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative42.7%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative42.7%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*51.0%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define51.0%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative51.0%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define51.0%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define51.0%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative51.0%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define51.0%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified51.0%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in z around inf 99.2%

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

        \[\leadsto \color{blue}{0.0692910599291889 \cdot y + x} \]
    7. Simplified99.2%

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

    if -3100 < z < 5.5999999999999996

    1. Initial program 99.5%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative99.5%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative99.5%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*99.5%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define99.5%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative99.5%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define99.5%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified99.5%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. fma-undefine99.5%

        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x} \]
      2. fma-undefine99.5%

        \[\leadsto \color{blue}{\left(z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) + 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      3. *-commutative99.5%

        \[\leadsto \left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z} + 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      4. fma-define99.5%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      5. fma-undefine99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304}} + x \]
      6. *-commutative99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{\left(z + 6.012459259764103\right) \cdot z} + 3.350343815022304} + x \]
      7. associate-*r/99.5%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      8. associate-*l/99.9%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \cdot y} + x \]
      9. *-commutative99.9%

        \[\leadsto \color{blue}{y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      10. clear-num99.0%

        \[\leadsto y \cdot \color{blue}{\frac{1}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      11. un-div-inv99.2%

        \[\leadsto \color{blue}{\frac{y}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      12. *-commutative99.2%

        \[\leadsto \frac{y}{\frac{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      13. fma-undefine99.2%

        \[\leadsto \frac{y}{\frac{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      14. fma-define99.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z + 0.279195317918525}}} + x \]
      15. *-commutative99.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)} + 0.279195317918525}} + x \]
      16. fma-undefine99.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}}} + x \]
    6. Applied egg-rr99.2%

      \[\leadsto \color{blue}{\frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}} + x} \]
    7. Taylor expanded in z around 0 98.7%

      \[\leadsto \frac{y}{\color{blue}{12.000000000000014}} + x \]
  3. Recombined 2 regimes into one program.
  4. Final simplification98.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -3100 \lor \neg \left(z \leq 5.6\right):\\ \;\;\;\;x + y \cdot 0.0692910599291889\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{12.000000000000014}\\ \end{array} \]
  5. Add Preprocessing

Alternative 17: 98.7% accurate, 1.4× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;z \leq -3100 \lor \neg \left(z \leq 5.4\right):\\
\;\;\;\;x + y \cdot 0.0692910599291889\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -3100 or 5.4000000000000004 < z

    1. Initial program 42.7%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative42.7%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative42.7%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*51.0%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define51.0%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative51.0%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define51.0%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define51.0%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative51.0%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define51.0%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified51.0%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in z around inf 99.2%

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

        \[\leadsto \color{blue}{0.0692910599291889 \cdot y + x} \]
    7. Simplified99.2%

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

    if -3100 < z < 5.4000000000000004

    1. Initial program 99.5%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative99.5%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative99.5%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*99.5%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define99.5%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative99.5%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define99.5%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified99.5%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in z around 0 98.6%

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

        \[\leadsto \color{blue}{0.08333333333333323 \cdot y + x} \]
    7. Simplified98.6%

      \[\leadsto \color{blue}{0.08333333333333323 \cdot y + x} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification98.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -3100 \lor \neg \left(z \leq 5.4\right):\\ \;\;\;\;x + y \cdot 0.0692910599291889\\ \mathbf{else}:\\ \;\;\;\;x + y \cdot 0.08333333333333323\\ \end{array} \]
  5. Add Preprocessing

Alternative 18: 98.9% accurate, 1.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -3100:\\ \;\;\;\;x + y \cdot \left(0.0692910599291889 + \frac{0.07512208616047561}{z}\right)\\ \mathbf{elif}\;z \leq 5.8:\\ \;\;\;\;x + \frac{y}{12.000000000000014}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{14.431876219268936}\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (if (<= z -3100.0)
   (+ x (* y (+ 0.0692910599291889 (/ 0.07512208616047561 z))))
   (if (<= z 5.8)
     (+ x (/ y 12.000000000000014))
     (+ x (/ y 14.431876219268936)))))
double code(double x, double y, double z) {
	double tmp;
	if (z <= -3100.0) {
		tmp = x + (y * (0.0692910599291889 + (0.07512208616047561 / z)));
	} else if (z <= 5.8) {
		tmp = x + (y / 12.000000000000014);
	} else {
		tmp = x + (y / 14.431876219268936);
	}
	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 <= (-3100.0d0)) then
        tmp = x + (y * (0.0692910599291889d0 + (0.07512208616047561d0 / z)))
    else if (z <= 5.8d0) then
        tmp = x + (y / 12.000000000000014d0)
    else
        tmp = x + (y / 14.431876219268936d0)
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double tmp;
	if (z <= -3100.0) {
		tmp = x + (y * (0.0692910599291889 + (0.07512208616047561 / z)));
	} else if (z <= 5.8) {
		tmp = x + (y / 12.000000000000014);
	} else {
		tmp = x + (y / 14.431876219268936);
	}
	return tmp;
}
def code(x, y, z):
	tmp = 0
	if z <= -3100.0:
		tmp = x + (y * (0.0692910599291889 + (0.07512208616047561 / z)))
	elif z <= 5.8:
		tmp = x + (y / 12.000000000000014)
	else:
		tmp = x + (y / 14.431876219268936)
	return tmp
function code(x, y, z)
	tmp = 0.0
	if (z <= -3100.0)
		tmp = Float64(x + Float64(y * Float64(0.0692910599291889 + Float64(0.07512208616047561 / z))));
	elseif (z <= 5.8)
		tmp = Float64(x + Float64(y / 12.000000000000014));
	else
		tmp = Float64(x + Float64(y / 14.431876219268936));
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	tmp = 0.0;
	if (z <= -3100.0)
		tmp = x + (y * (0.0692910599291889 + (0.07512208616047561 / z)));
	elseif (z <= 5.8)
		tmp = x + (y / 12.000000000000014);
	else
		tmp = x + (y / 14.431876219268936);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := If[LessEqual[z, -3100.0], N[(x + N[(y * N[(0.0692910599291889 + N[(0.07512208616047561 / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 5.8], N[(x + N[(y / 12.000000000000014), $MachinePrecision]), $MachinePrecision], N[(x + N[(y / 14.431876219268936), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -3100:\\
\;\;\;\;x + y \cdot \left(0.0692910599291889 + \frac{0.07512208616047561}{z}\right)\\

\mathbf{elif}\;z \leq 5.8:\\
\;\;\;\;x + \frac{y}{12.000000000000014}\\

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


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

    1. Initial program 42.7%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. remove-double-neg42.7%

        \[\leadsto x + \color{blue}{\left(-\left(-\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      2. associate-/l*52.2%

        \[\leadsto x + \left(-\left(-\color{blue}{y \cdot \frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}}\right)\right) \]
      3. distribute-rgt-neg-in52.2%

        \[\leadsto x + \left(-\color{blue}{y \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)}\right) \]
      4. distribute-lft-neg-in52.2%

        \[\leadsto x + \color{blue}{\left(-y\right) \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)} \]
      5. distribute-lft-neg-in52.2%

        \[\leadsto x + \color{blue}{\left(-y \cdot \left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      6. distribute-rgt-neg-in52.2%

        \[\leadsto x + \color{blue}{y \cdot \left(-\left(-\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\right)\right)} \]
      7. remove-double-neg52.2%

        \[\leadsto x + y \cdot \color{blue}{\frac{\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} \]
      8. fma-define52.2%

        \[\leadsto x + y \cdot \frac{\color{blue}{\mathsf{fma}\left(z \cdot 0.0692910599291889 + 0.4917317610505968, z, 0.279195317918525\right)}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
      9. fma-define52.1%

        \[\leadsto x + y \cdot \frac{\mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
      10. fma-define52.1%

        \[\leadsto x + y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\color{blue}{\mathsf{fma}\left(z + 6.012459259764103, z, 3.350343815022304\right)}} \]
    3. Simplified52.1%

      \[\leadsto \color{blue}{x + y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\mathsf{fma}\left(z + 6.012459259764103, z, 3.350343815022304\right)}} \]
    4. Add Preprocessing
    5. Taylor expanded in z around inf 99.0%

      \[\leadsto x + y \cdot \color{blue}{\left(0.0692910599291889 + 0.07512208616047561 \cdot \frac{1}{z}\right)} \]
    6. Step-by-step derivation
      1. associate-*r/99.0%

        \[\leadsto x + y \cdot \left(0.0692910599291889 + \color{blue}{\frac{0.07512208616047561 \cdot 1}{z}}\right) \]
      2. metadata-eval99.0%

        \[\leadsto x + y \cdot \left(0.0692910599291889 + \frac{\color{blue}{0.07512208616047561}}{z}\right) \]
    7. Simplified99.0%

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

    if -3100 < z < 5.79999999999999982

    1. Initial program 99.5%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative99.5%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative99.5%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*99.5%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define99.5%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative99.5%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define99.5%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified99.5%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. fma-undefine99.5%

        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x} \]
      2. fma-undefine99.5%

        \[\leadsto \color{blue}{\left(z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) + 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      3. *-commutative99.5%

        \[\leadsto \left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z} + 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      4. fma-define99.5%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      5. fma-undefine99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304}} + x \]
      6. *-commutative99.5%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{\left(z + 6.012459259764103\right) \cdot z} + 3.350343815022304} + x \]
      7. associate-*r/99.5%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      8. associate-*l/99.9%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \cdot y} + x \]
      9. *-commutative99.9%

        \[\leadsto \color{blue}{y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      10. clear-num99.0%

        \[\leadsto y \cdot \color{blue}{\frac{1}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      11. un-div-inv99.2%

        \[\leadsto \color{blue}{\frac{y}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      12. *-commutative99.2%

        \[\leadsto \frac{y}{\frac{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      13. fma-undefine99.2%

        \[\leadsto \frac{y}{\frac{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      14. fma-define99.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z + 0.279195317918525}}} + x \]
      15. *-commutative99.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)} + 0.279195317918525}} + x \]
      16. fma-undefine99.2%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}}} + x \]
    6. Applied egg-rr99.2%

      \[\leadsto \color{blue}{\frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}} + x} \]
    7. Taylor expanded in z around 0 98.7%

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

    if 5.79999999999999982 < z

    1. Initial program 42.7%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative42.7%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative42.7%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*51.4%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified51.4%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Step-by-step derivation
      1. fma-undefine51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x} \]
      2. fma-undefine51.4%

        \[\leadsto \color{blue}{\left(z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) + 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      3. *-commutative51.4%

        \[\leadsto \left(\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z} + 0.279195317918525\right) \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      4. fma-define51.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)} \cdot \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)} + x \]
      5. fma-undefine51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right) + 3.350343815022304}} + x \]
      6. *-commutative51.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot \frac{y}{\color{blue}{\left(z + 6.012459259764103\right) \cdot z} + 3.350343815022304} + x \]
      7. associate-*r/42.7%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right) \cdot y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      8. associate-*l/52.8%

        \[\leadsto \color{blue}{\frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \cdot y} + x \]
      9. *-commutative52.8%

        \[\leadsto \color{blue}{y \cdot \frac{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      10. clear-num52.8%

        \[\leadsto y \cdot \color{blue}{\frac{1}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      11. un-div-inv52.8%

        \[\leadsto \color{blue}{\frac{y}{\frac{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}}} + x \]
      12. *-commutative52.8%

        \[\leadsto \frac{y}{\frac{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      13. fma-undefine52.8%

        \[\leadsto \frac{y}{\frac{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}{\mathsf{fma}\left(\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), z, 0.279195317918525\right)}} + x \]
      14. fma-define52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right) \cdot z + 0.279195317918525}}} + x \]
      15. *-commutative52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{z \cdot \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)} + 0.279195317918525}} + x \]
      16. fma-undefine52.8%

        \[\leadsto \frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\color{blue}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}}} + x \]
    6. Applied egg-rr52.8%

      \[\leadsto \color{blue}{\frac{y}{\frac{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}{\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right)}} + x} \]
    7. Taylor expanded in z around inf 99.9%

      \[\leadsto \frac{y}{\color{blue}{14.431876219268936}} + x \]
  3. Recombined 3 regimes into one program.
  4. Final simplification99.1%

    \[\leadsto \begin{array}{l} \mathbf{if}\;z \leq -3100:\\ \;\;\;\;x + y \cdot \left(0.0692910599291889 + \frac{0.07512208616047561}{z}\right)\\ \mathbf{elif}\;z \leq 5.8:\\ \;\;\;\;x + \frac{y}{12.000000000000014}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y}{14.431876219268936}\\ \end{array} \]
  5. Add Preprocessing

Alternative 19: 60.0% accurate, 1.6× speedup?

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

\\
\begin{array}{l}
\mathbf{if}\;x \leq -2.35 \cdot 10^{+35}:\\
\;\;\;\;x\\

\mathbf{elif}\;x \leq 4.7 \cdot 10^{-51}:\\
\;\;\;\;y \cdot 0.08333333333333323\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if x < -2.35000000000000017e35 or 4.6999999999999997e-51 < x

    1. Initial program 72.2%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative72.2%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative72.2%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*77.3%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define77.3%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative77.3%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define77.3%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define77.3%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative77.3%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define77.3%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified77.3%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in y around 0 72.9%

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

    if -2.35000000000000017e35 < x < 4.6999999999999997e-51

    1. Initial program 71.4%

      \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
    2. Step-by-step derivation
      1. +-commutative71.4%

        \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
      2. *-commutative71.4%

        \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
      3. associate-/l*74.4%

        \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
      4. fma-define74.4%

        \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
      5. *-commutative74.4%

        \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      6. fma-define74.4%

        \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      7. fma-define74.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
      8. *-commutative74.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
      9. fma-define74.4%

        \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
    3. Simplified74.4%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
    4. Add Preprocessing
    5. Taylor expanded in z around 0 68.4%

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

        \[\leadsto \color{blue}{0.08333333333333323 \cdot y + x} \]
    7. Simplified68.4%

      \[\leadsto \color{blue}{0.08333333333333323 \cdot y + x} \]
    8. Taylor expanded in y around inf 55.0%

      \[\leadsto \color{blue}{0.08333333333333323 \cdot y} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification64.0%

    \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq -2.35 \cdot 10^{+35}:\\ \;\;\;\;x\\ \mathbf{elif}\;x \leq 4.7 \cdot 10^{-51}:\\ \;\;\;\;y \cdot 0.08333333333333323\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]
  5. Add Preprocessing

Alternative 20: 50.2% accurate, 21.0× speedup?

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

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

    \[x + \frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} \]
  2. Step-by-step derivation
    1. +-commutative71.8%

      \[\leadsto \color{blue}{\frac{y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x} \]
    2. *-commutative71.8%

      \[\leadsto \frac{\color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot y}}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304} + x \]
    3. associate-/l*75.8%

      \[\leadsto \color{blue}{\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right) \cdot \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}} + x \]
    4. fma-define75.8%

      \[\leadsto \color{blue}{\mathsf{fma}\left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right)} \]
    5. *-commutative75.8%

      \[\leadsto \mathsf{fma}\left(\color{blue}{z \cdot \left(z \cdot 0.0692910599291889 + 0.4917317610505968\right)} + 0.279195317918525, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
    6. fma-define75.8%

      \[\leadsto \mathsf{fma}\left(\color{blue}{\mathsf{fma}\left(z, z \cdot 0.0692910599291889 + 0.4917317610505968, 0.279195317918525\right)}, \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
    7. fma-define75.8%

      \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \color{blue}{\mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right)}, 0.279195317918525\right), \frac{y}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}, x\right) \]
    8. *-commutative75.8%

      \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{z \cdot \left(z + 6.012459259764103\right)} + 3.350343815022304}, x\right) \]
    9. fma-define75.8%

      \[\leadsto \mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\color{blue}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}}, x\right) \]
  3. Simplified75.8%

    \[\leadsto \color{blue}{\mathsf{fma}\left(\mathsf{fma}\left(z, \mathsf{fma}\left(z, 0.0692910599291889, 0.4917317610505968\right), 0.279195317918525\right), \frac{y}{\mathsf{fma}\left(z, z + 6.012459259764103, 3.350343815022304\right)}, x\right)} \]
  4. Add Preprocessing
  5. Taylor expanded in y around 0 44.8%

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

Developer target: 99.4% accurate, 0.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := \left(\frac{0.07512208616047561}{z} + 0.0692910599291889\right) \cdot y - \left(\frac{0.40462203869992125 \cdot y}{z \cdot z} - x\right)\\ \mathbf{if}\;z < -8120153.652456675:\\ \;\;\;\;t\_0\\ \mathbf{elif}\;z < 6.576118972787377 \cdot 10^{+20}:\\ \;\;\;\;x + \left(y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)\right) \cdot \frac{1}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\\ \mathbf{else}:\\ \;\;\;\;t\_0\\ \end{array} \end{array} \]
(FPCore (x y z)
 :precision binary64
 (let* ((t_0
         (-
          (* (+ (/ 0.07512208616047561 z) 0.0692910599291889) y)
          (- (/ (* 0.40462203869992125 y) (* z z)) x))))
   (if (< z -8120153.652456675)
     t_0
     (if (< z 6.576118972787377e+20)
       (+
        x
        (*
         (*
          y
          (+
           (* (+ (* z 0.0692910599291889) 0.4917317610505968) z)
           0.279195317918525))
         (/ 1.0 (+ (* (+ z 6.012459259764103) z) 3.350343815022304))))
       t_0))))
double code(double x, double y, double z) {
	double t_0 = (((0.07512208616047561 / z) + 0.0692910599291889) * y) - (((0.40462203869992125 * y) / (z * z)) - x);
	double tmp;
	if (z < -8120153.652456675) {
		tmp = t_0;
	} else if (z < 6.576118972787377e+20) {
		tmp = x + ((y * ((((z * 0.0692910599291889) + 0.4917317610505968) * z) + 0.279195317918525)) * (1.0 / (((z + 6.012459259764103) * z) + 3.350343815022304)));
	} 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.07512208616047561d0 / z) + 0.0692910599291889d0) * y) - (((0.40462203869992125d0 * y) / (z * z)) - x)
    if (z < (-8120153.652456675d0)) then
        tmp = t_0
    else if (z < 6.576118972787377d+20) then
        tmp = x + ((y * ((((z * 0.0692910599291889d0) + 0.4917317610505968d0) * z) + 0.279195317918525d0)) * (1.0d0 / (((z + 6.012459259764103d0) * z) + 3.350343815022304d0)))
    else
        tmp = t_0
    end if
    code = tmp
end function
public static double code(double x, double y, double z) {
	double t_0 = (((0.07512208616047561 / z) + 0.0692910599291889) * y) - (((0.40462203869992125 * y) / (z * z)) - x);
	double tmp;
	if (z < -8120153.652456675) {
		tmp = t_0;
	} else if (z < 6.576118972787377e+20) {
		tmp = x + ((y * ((((z * 0.0692910599291889) + 0.4917317610505968) * z) + 0.279195317918525)) * (1.0 / (((z + 6.012459259764103) * z) + 3.350343815022304)));
	} else {
		tmp = t_0;
	}
	return tmp;
}
def code(x, y, z):
	t_0 = (((0.07512208616047561 / z) + 0.0692910599291889) * y) - (((0.40462203869992125 * y) / (z * z)) - x)
	tmp = 0
	if z < -8120153.652456675:
		tmp = t_0
	elif z < 6.576118972787377e+20:
		tmp = x + ((y * ((((z * 0.0692910599291889) + 0.4917317610505968) * z) + 0.279195317918525)) * (1.0 / (((z + 6.012459259764103) * z) + 3.350343815022304)))
	else:
		tmp = t_0
	return tmp
function code(x, y, z)
	t_0 = Float64(Float64(Float64(Float64(0.07512208616047561 / z) + 0.0692910599291889) * y) - Float64(Float64(Float64(0.40462203869992125 * y) / Float64(z * z)) - x))
	tmp = 0.0
	if (z < -8120153.652456675)
		tmp = t_0;
	elseif (z < 6.576118972787377e+20)
		tmp = Float64(x + Float64(Float64(y * Float64(Float64(Float64(Float64(z * 0.0692910599291889) + 0.4917317610505968) * z) + 0.279195317918525)) * Float64(1.0 / Float64(Float64(Float64(z + 6.012459259764103) * z) + 3.350343815022304))));
	else
		tmp = t_0;
	end
	return tmp
end
function tmp_2 = code(x, y, z)
	t_0 = (((0.07512208616047561 / z) + 0.0692910599291889) * y) - (((0.40462203869992125 * y) / (z * z)) - x);
	tmp = 0.0;
	if (z < -8120153.652456675)
		tmp = t_0;
	elseif (z < 6.576118972787377e+20)
		tmp = x + ((y * ((((z * 0.0692910599291889) + 0.4917317610505968) * z) + 0.279195317918525)) * (1.0 / (((z + 6.012459259764103) * z) + 3.350343815022304)));
	else
		tmp = t_0;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_] := Block[{t$95$0 = N[(N[(N[(N[(0.07512208616047561 / z), $MachinePrecision] + 0.0692910599291889), $MachinePrecision] * y), $MachinePrecision] - N[(N[(N[(0.40462203869992125 * y), $MachinePrecision] / N[(z * z), $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision]), $MachinePrecision]}, If[Less[z, -8120153.652456675], t$95$0, If[Less[z, 6.576118972787377e+20], N[(x + N[(N[(y * N[(N[(N[(N[(z * 0.0692910599291889), $MachinePrecision] + 0.4917317610505968), $MachinePrecision] * z), $MachinePrecision] + 0.279195317918525), $MachinePrecision]), $MachinePrecision] * N[(1.0 / N[(N[(N[(z + 6.012459259764103), $MachinePrecision] * z), $MachinePrecision] + 3.350343815022304), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$0]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := \left(\frac{0.07512208616047561}{z} + 0.0692910599291889\right) \cdot y - \left(\frac{0.40462203869992125 \cdot y}{z \cdot z} - x\right)\\
\mathbf{if}\;z < -8120153.652456675:\\
\;\;\;\;t\_0\\

\mathbf{elif}\;z < 6.576118972787377 \cdot 10^{+20}:\\
\;\;\;\;x + \left(y \cdot \left(\left(z \cdot 0.0692910599291889 + 0.4917317610505968\right) \cdot z + 0.279195317918525\right)\right) \cdot \frac{1}{\left(z + 6.012459259764103\right) \cdot z + 3.350343815022304}\\

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


\end{array}
\end{array}

Reproduce

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

  :alt
  (if (< z -8120153.652456675) (- (* (+ (/ 0.07512208616047561 z) 0.0692910599291889) y) (- (/ (* 0.40462203869992125 y) (* z z)) x)) (if (< z 6.576118972787377e+20) (+ x (* (* y (+ (* (+ (* z 0.0692910599291889) 0.4917317610505968) z) 0.279195317918525)) (/ 1.0 (+ (* (+ z 6.012459259764103) z) 3.350343815022304)))) (- (* (+ (/ 0.07512208616047561 z) 0.0692910599291889) y) (- (/ (* 0.40462203869992125 y) (* z z)) x))))

  (+ x (/ (* y (+ (* (+ (* z 0.0692910599291889) 0.4917317610505968) z) 0.279195317918525)) (+ (* (+ z 6.012459259764103) z) 3.350343815022304))))