Graphics.Rendering.Chart.Axis.Types:invLinMap from Chart-1.5.3

Percentage Accurate: 68.5% → 88.9%
Time: 17.4s
Alternatives: 20
Speedup: 0.6×

Specification

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

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

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

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

Alternative 1: 88.9% accurate, 0.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := t - \frac{t - x}{z} \cdot \left(y - a\right)\\ \mathbf{if}\;z \leq -8.2 \cdot 10^{+154}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq 1.15 \cdot 10^{+186}:\\ \;\;\;\;x + \left(t - x\right) \cdot \frac{y - z}{a - z}\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (- t (* (/ (- t x) z) (- y a)))))
   (if (<= z -8.2e+154)
     t_1
     (if (<= z 1.15e+186) (+ x (* (- t x) (/ (- y z) (- a z)))) t_1))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = t - (((t - x) / z) * (y - a));
	double tmp;
	if (z <= -8.2e+154) {
		tmp = t_1;
	} else if (z <= 1.15e+186) {
		tmp = x + ((t - x) * ((y - z) / (a - z)));
	} else {
		tmp = t_1;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8) :: t_1
    real(8) :: tmp
    t_1 = t - (((t - x) / z) * (y - a))
    if (z <= (-8.2d+154)) then
        tmp = t_1
    else if (z <= 1.15d+186) then
        tmp = x + ((t - x) * ((y - z) / (a - z)))
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double t_1 = t - (((t - x) / z) * (y - a));
	double tmp;
	if (z <= -8.2e+154) {
		tmp = t_1;
	} else if (z <= 1.15e+186) {
		tmp = x + ((t - x) * ((y - z) / (a - z)));
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = t - (((t - x) / z) * (y - a))
	tmp = 0
	if z <= -8.2e+154:
		tmp = t_1
	elif z <= 1.15e+186:
		tmp = x + ((t - x) * ((y - z) / (a - z)))
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(t - Float64(Float64(Float64(t - x) / z) * Float64(y - a)))
	tmp = 0.0
	if (z <= -8.2e+154)
		tmp = t_1;
	elseif (z <= 1.15e+186)
		tmp = Float64(x + Float64(Float64(t - x) * Float64(Float64(y - z) / Float64(a - z))));
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = t - (((t - x) / z) * (y - a));
	tmp = 0.0;
	if (z <= -8.2e+154)
		tmp = t_1;
	elseif (z <= 1.15e+186)
		tmp = x + ((t - x) * ((y - z) / (a - z)));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(t - N[(N[(N[(t - x), $MachinePrecision] / z), $MachinePrecision] * N[(y - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -8.2e+154], t$95$1, If[LessEqual[z, 1.15e+186], N[(x + N[(N[(t - x), $MachinePrecision] * N[(N[(y - z), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}

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

\mathbf{elif}\;z \leq 1.15 \cdot 10^{+186}:\\
\;\;\;\;x + \left(t - x\right) \cdot \frac{y - z}{a - z}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -8.2e154 or 1.15000000000000007e186 < z

    1. Initial program 23.6%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Applied egg-rr0

      \[\leadsto expr\]
    5. Taylor expanded in z around inf 0

      \[\leadsto expr\]
    6. Simplified0

      \[\leadsto expr\]

    if -8.2e154 < z < 1.15000000000000007e186

    1. Initial program 83.1%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
  3. Recombined 2 regimes into one program.
  4. Add Preprocessing

Alternative 2: 78.2% accurate, 0.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := x + \frac{\left(y - z\right) \cdot t}{a - z}\\ t_2 := t - \frac{t - x}{z} \cdot \left(y - a\right)\\ \mathbf{if}\;z \leq -5.1 \cdot 10^{+67}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;z \leq -5.5 \cdot 10^{+23}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq -19000000:\\ \;\;\;\;t + \frac{\left(t - x\right) \cdot \left(a - y\right)}{z}\\ \mathbf{elif}\;z \leq 2.3 \cdot 10^{-106}:\\ \;\;\;\;x + \frac{y \cdot \left(t - x\right)}{a - z}\\ \mathbf{elif}\;z \leq 2.6 \cdot 10^{+81}:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;t\_2\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (+ x (/ (* (- y z) t) (- a z))))
        (t_2 (- t (* (/ (- t x) z) (- y a)))))
   (if (<= z -5.1e+67)
     t_2
     (if (<= z -5.5e+23)
       t_1
       (if (<= z -19000000.0)
         (+ t (/ (* (- t x) (- a y)) z))
         (if (<= z 2.3e-106)
           (+ x (/ (* y (- t x)) (- a z)))
           (if (<= z 2.6e+81) t_1 t_2)))))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = x + (((y - z) * t) / (a - z));
	double t_2 = t - (((t - x) / z) * (y - a));
	double tmp;
	if (z <= -5.1e+67) {
		tmp = t_2;
	} else if (z <= -5.5e+23) {
		tmp = t_1;
	} else if (z <= -19000000.0) {
		tmp = t + (((t - x) * (a - y)) / z);
	} else if (z <= 2.3e-106) {
		tmp = x + ((y * (t - x)) / (a - z));
	} else if (z <= 2.6e+81) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8) :: t_1
    real(8) :: t_2
    real(8) :: tmp
    t_1 = x + (((y - z) * t) / (a - z))
    t_2 = t - (((t - x) / z) * (y - a))
    if (z <= (-5.1d+67)) then
        tmp = t_2
    else if (z <= (-5.5d+23)) then
        tmp = t_1
    else if (z <= (-19000000.0d0)) then
        tmp = t + (((t - x) * (a - y)) / z)
    else if (z <= 2.3d-106) then
        tmp = x + ((y * (t - x)) / (a - z))
    else if (z <= 2.6d+81) then
        tmp = t_1
    else
        tmp = t_2
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double t_1 = x + (((y - z) * t) / (a - z));
	double t_2 = t - (((t - x) / z) * (y - a));
	double tmp;
	if (z <= -5.1e+67) {
		tmp = t_2;
	} else if (z <= -5.5e+23) {
		tmp = t_1;
	} else if (z <= -19000000.0) {
		tmp = t + (((t - x) * (a - y)) / z);
	} else if (z <= 2.3e-106) {
		tmp = x + ((y * (t - x)) / (a - z));
	} else if (z <= 2.6e+81) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = x + (((y - z) * t) / (a - z))
	t_2 = t - (((t - x) / z) * (y - a))
	tmp = 0
	if z <= -5.1e+67:
		tmp = t_2
	elif z <= -5.5e+23:
		tmp = t_1
	elif z <= -19000000.0:
		tmp = t + (((t - x) * (a - y)) / z)
	elif z <= 2.3e-106:
		tmp = x + ((y * (t - x)) / (a - z))
	elif z <= 2.6e+81:
		tmp = t_1
	else:
		tmp = t_2
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(x + Float64(Float64(Float64(y - z) * t) / Float64(a - z)))
	t_2 = Float64(t - Float64(Float64(Float64(t - x) / z) * Float64(y - a)))
	tmp = 0.0
	if (z <= -5.1e+67)
		tmp = t_2;
	elseif (z <= -5.5e+23)
		tmp = t_1;
	elseif (z <= -19000000.0)
		tmp = Float64(t + Float64(Float64(Float64(t - x) * Float64(a - y)) / z));
	elseif (z <= 2.3e-106)
		tmp = Float64(x + Float64(Float64(y * Float64(t - x)) / Float64(a - z)));
	elseif (z <= 2.6e+81)
		tmp = t_1;
	else
		tmp = t_2;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = x + (((y - z) * t) / (a - z));
	t_2 = t - (((t - x) / z) * (y - a));
	tmp = 0.0;
	if (z <= -5.1e+67)
		tmp = t_2;
	elseif (z <= -5.5e+23)
		tmp = t_1;
	elseif (z <= -19000000.0)
		tmp = t + (((t - x) * (a - y)) / z);
	elseif (z <= 2.3e-106)
		tmp = x + ((y * (t - x)) / (a - z));
	elseif (z <= 2.6e+81)
		tmp = t_1;
	else
		tmp = t_2;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(N[(N[(y - z), $MachinePrecision] * t), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(t - N[(N[(N[(t - x), $MachinePrecision] / z), $MachinePrecision] * N[(y - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -5.1e+67], t$95$2, If[LessEqual[z, -5.5e+23], t$95$1, If[LessEqual[z, -19000000.0], N[(t + N[(N[(N[(t - x), $MachinePrecision] * N[(a - y), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2.3e-106], N[(x + N[(N[(y * N[(t - x), $MachinePrecision]), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2.6e+81], t$95$1, t$95$2]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := x + \frac{\left(y - z\right) \cdot t}{a - z}\\
t_2 := t - \frac{t - x}{z} \cdot \left(y - a\right)\\
\mathbf{if}\;z \leq -5.1 \cdot 10^{+67}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;z \leq -5.5 \cdot 10^{+23}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;z \leq -19000000:\\
\;\;\;\;t + \frac{\left(t - x\right) \cdot \left(a - y\right)}{z}\\

\mathbf{elif}\;z \leq 2.3 \cdot 10^{-106}:\\
\;\;\;\;x + \frac{y \cdot \left(t - x\right)}{a - z}\\

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if z < -5.1000000000000002e67 or 2.59999999999999992e81 < z

    1. Initial program 29.5%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Applied egg-rr0

      \[\leadsto expr\]
    5. Taylor expanded in z around inf 0

      \[\leadsto expr\]
    6. Simplified0

      \[\leadsto expr\]

    if -5.1000000000000002e67 < z < -5.50000000000000004e23 or 2.3000000000000001e-106 < z < 2.59999999999999992e81

    1. Initial program 91.2%

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

      \[\leadsto expr\]
    4. Simplified0

      \[\leadsto expr\]

    if -5.50000000000000004e23 < z < -1.9e7

    1. Initial program 68.4%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in z around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]

    if -1.9e7 < z < 2.3000000000000001e-106

    1. Initial program 92.3%

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

      \[\leadsto expr\]
    4. Simplified0

      \[\leadsto expr\]
  3. Recombined 4 regimes into one program.
  4. Add Preprocessing

Alternative 3: 71.9% accurate, 0.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := x + \left(t - x\right) \cdot \frac{y - z}{a}\\ \mathbf{if}\;a \leq -6.8 \cdot 10^{+106}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;a \leq -0.065:\\ \;\;\;\;x + \frac{\left(y - z\right) \cdot t}{a - z}\\ \mathbf{elif}\;a \leq -1.8 \cdot 10^{-153}:\\ \;\;\;\;\frac{t - x}{\frac{a - z}{y}}\\ \mathbf{elif}\;a \leq 0.076:\\ \;\;\;\;t + \frac{\left(t - x\right) \cdot \left(a - y\right)}{z}\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (+ x (* (- t x) (/ (- y z) a)))))
   (if (<= a -6.8e+106)
     t_1
     (if (<= a -0.065)
       (+ x (/ (* (- y z) t) (- a z)))
       (if (<= a -1.8e-153)
         (/ (- t x) (/ (- a z) y))
         (if (<= a 0.076) (+ t (/ (* (- t x) (- a y)) z)) t_1))))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = x + ((t - x) * ((y - z) / a));
	double tmp;
	if (a <= -6.8e+106) {
		tmp = t_1;
	} else if (a <= -0.065) {
		tmp = x + (((y - z) * t) / (a - z));
	} else if (a <= -1.8e-153) {
		tmp = (t - x) / ((a - z) / y);
	} else if (a <= 0.076) {
		tmp = t + (((t - x) * (a - y)) / z);
	} else {
		tmp = t_1;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8) :: t_1
    real(8) :: tmp
    t_1 = x + ((t - x) * ((y - z) / a))
    if (a <= (-6.8d+106)) then
        tmp = t_1
    else if (a <= (-0.065d0)) then
        tmp = x + (((y - z) * t) / (a - z))
    else if (a <= (-1.8d-153)) then
        tmp = (t - x) / ((a - z) / y)
    else if (a <= 0.076d0) then
        tmp = t + (((t - x) * (a - y)) / z)
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double t_1 = x + ((t - x) * ((y - z) / a));
	double tmp;
	if (a <= -6.8e+106) {
		tmp = t_1;
	} else if (a <= -0.065) {
		tmp = x + (((y - z) * t) / (a - z));
	} else if (a <= -1.8e-153) {
		tmp = (t - x) / ((a - z) / y);
	} else if (a <= 0.076) {
		tmp = t + (((t - x) * (a - y)) / z);
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = x + ((t - x) * ((y - z) / a))
	tmp = 0
	if a <= -6.8e+106:
		tmp = t_1
	elif a <= -0.065:
		tmp = x + (((y - z) * t) / (a - z))
	elif a <= -1.8e-153:
		tmp = (t - x) / ((a - z) / y)
	elif a <= 0.076:
		tmp = t + (((t - x) * (a - y)) / z)
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(x + Float64(Float64(t - x) * Float64(Float64(y - z) / a)))
	tmp = 0.0
	if (a <= -6.8e+106)
		tmp = t_1;
	elseif (a <= -0.065)
		tmp = Float64(x + Float64(Float64(Float64(y - z) * t) / Float64(a - z)));
	elseif (a <= -1.8e-153)
		tmp = Float64(Float64(t - x) / Float64(Float64(a - z) / y));
	elseif (a <= 0.076)
		tmp = Float64(t + Float64(Float64(Float64(t - x) * Float64(a - y)) / z));
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = x + ((t - x) * ((y - z) / a));
	tmp = 0.0;
	if (a <= -6.8e+106)
		tmp = t_1;
	elseif (a <= -0.065)
		tmp = x + (((y - z) * t) / (a - z));
	elseif (a <= -1.8e-153)
		tmp = (t - x) / ((a - z) / y);
	elseif (a <= 0.076)
		tmp = t + (((t - x) * (a - y)) / z);
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(N[(t - x), $MachinePrecision] * N[(N[(y - z), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -6.8e+106], t$95$1, If[LessEqual[a, -0.065], N[(x + N[(N[(N[(y - z), $MachinePrecision] * t), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, -1.8e-153], N[(N[(t - x), $MachinePrecision] / N[(N[(a - z), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 0.076], N[(t + N[(N[(N[(t - x), $MachinePrecision] * N[(a - y), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}

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

\mathbf{elif}\;a \leq -0.065:\\
\;\;\;\;x + \frac{\left(y - z\right) \cdot t}{a - z}\\

\mathbf{elif}\;a \leq -1.8 \cdot 10^{-153}:\\
\;\;\;\;\frac{t - x}{\frac{a - z}{y}}\\

\mathbf{elif}\;a \leq 0.076:\\
\;\;\;\;t + \frac{\left(t - x\right) \cdot \left(a - y\right)}{z}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if a < -6.79999999999999989e106 or 0.0759999999999999981 < a

    1. Initial program 67.6%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in a around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]

    if -6.79999999999999989e106 < a < -0.065000000000000002

    1. Initial program 82.8%

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

      \[\leadsto expr\]
    4. Simplified0

      \[\leadsto expr\]

    if -0.065000000000000002 < a < -1.7999999999999999e-153

    1. Initial program 72.1%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in y around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]
    6. Applied egg-rr0

      \[\leadsto expr\]

    if -1.7999999999999999e-153 < a < 0.0759999999999999981

    1. Initial program 62.7%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in z around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]
  3. Recombined 4 regimes into one program.
  4. Add Preprocessing

Alternative 4: 72.3% accurate, 0.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := t + \frac{\left(t - x\right) \cdot \left(a - y\right)}{z}\\ t_2 := x + \left(t - x\right) \cdot \frac{y - z}{a}\\ \mathbf{if}\;a \leq -3.4 \cdot 10^{+25}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;a \leq -5.1 \cdot 10^{-51}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;a \leq -1.9 \cdot 10^{-153}:\\ \;\;\;\;\frac{t - x}{\frac{a - z}{y}}\\ \mathbf{elif}\;a \leq 2.5:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;t\_2\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (+ t (/ (* (- t x) (- a y)) z)))
        (t_2 (+ x (* (- t x) (/ (- y z) a)))))
   (if (<= a -3.4e+25)
     t_2
     (if (<= a -5.1e-51)
       t_1
       (if (<= a -1.9e-153)
         (/ (- t x) (/ (- a z) y))
         (if (<= a 2.5) t_1 t_2))))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = t + (((t - x) * (a - y)) / z);
	double t_2 = x + ((t - x) * ((y - z) / a));
	double tmp;
	if (a <= -3.4e+25) {
		tmp = t_2;
	} else if (a <= -5.1e-51) {
		tmp = t_1;
	} else if (a <= -1.9e-153) {
		tmp = (t - x) / ((a - z) / y);
	} else if (a <= 2.5) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8) :: t_1
    real(8) :: t_2
    real(8) :: tmp
    t_1 = t + (((t - x) * (a - y)) / z)
    t_2 = x + ((t - x) * ((y - z) / a))
    if (a <= (-3.4d+25)) then
        tmp = t_2
    else if (a <= (-5.1d-51)) then
        tmp = t_1
    else if (a <= (-1.9d-153)) then
        tmp = (t - x) / ((a - z) / y)
    else if (a <= 2.5d0) then
        tmp = t_1
    else
        tmp = t_2
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double t_1 = t + (((t - x) * (a - y)) / z);
	double t_2 = x + ((t - x) * ((y - z) / a));
	double tmp;
	if (a <= -3.4e+25) {
		tmp = t_2;
	} else if (a <= -5.1e-51) {
		tmp = t_1;
	} else if (a <= -1.9e-153) {
		tmp = (t - x) / ((a - z) / y);
	} else if (a <= 2.5) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = t + (((t - x) * (a - y)) / z)
	t_2 = x + ((t - x) * ((y - z) / a))
	tmp = 0
	if a <= -3.4e+25:
		tmp = t_2
	elif a <= -5.1e-51:
		tmp = t_1
	elif a <= -1.9e-153:
		tmp = (t - x) / ((a - z) / y)
	elif a <= 2.5:
		tmp = t_1
	else:
		tmp = t_2
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(t + Float64(Float64(Float64(t - x) * Float64(a - y)) / z))
	t_2 = Float64(x + Float64(Float64(t - x) * Float64(Float64(y - z) / a)))
	tmp = 0.0
	if (a <= -3.4e+25)
		tmp = t_2;
	elseif (a <= -5.1e-51)
		tmp = t_1;
	elseif (a <= -1.9e-153)
		tmp = Float64(Float64(t - x) / Float64(Float64(a - z) / y));
	elseif (a <= 2.5)
		tmp = t_1;
	else
		tmp = t_2;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = t + (((t - x) * (a - y)) / z);
	t_2 = x + ((t - x) * ((y - z) / a));
	tmp = 0.0;
	if (a <= -3.4e+25)
		tmp = t_2;
	elseif (a <= -5.1e-51)
		tmp = t_1;
	elseif (a <= -1.9e-153)
		tmp = (t - x) / ((a - z) / y);
	elseif (a <= 2.5)
		tmp = t_1;
	else
		tmp = t_2;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(t + N[(N[(N[(t - x), $MachinePrecision] * N[(a - y), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x + N[(N[(t - x), $MachinePrecision] * N[(N[(y - z), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -3.4e+25], t$95$2, If[LessEqual[a, -5.1e-51], t$95$1, If[LessEqual[a, -1.9e-153], N[(N[(t - x), $MachinePrecision] / N[(N[(a - z), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 2.5], t$95$1, t$95$2]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := t + \frac{\left(t - x\right) \cdot \left(a - y\right)}{z}\\
t_2 := x + \left(t - x\right) \cdot \frac{y - z}{a}\\
\mathbf{if}\;a \leq -3.4 \cdot 10^{+25}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;a \leq -5.1 \cdot 10^{-51}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;a \leq -1.9 \cdot 10^{-153}:\\
\;\;\;\;\frac{t - x}{\frac{a - z}{y}}\\

\mathbf{elif}\;a \leq 2.5:\\
\;\;\;\;t\_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if a < -3.39999999999999984e25 or 2.5 < a

    1. Initial program 71.7%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in a around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]

    if -3.39999999999999984e25 < a < -5.0999999999999997e-51 or -1.90000000000000011e-153 < a < 2.5

    1. Initial program 60.3%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in z around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]

    if -5.0999999999999997e-51 < a < -1.90000000000000011e-153

    1. Initial program 90.4%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in y around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]
    6. Applied egg-rr0

      \[\leadsto expr\]
  3. Recombined 3 regimes into one program.
  4. Add Preprocessing

Alternative 5: 68.4% accurate, 0.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := t + \frac{\left(t - x\right) \cdot \left(a - y\right)}{z}\\ t_2 := x + t \cdot \frac{y - z}{a}\\ \mathbf{if}\;a \leq -3.1 \cdot 10^{+28}:\\ \;\;\;\;t\_2\\ \mathbf{elif}\;a \leq -3.9 \cdot 10^{-49}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;a \leq -1.85 \cdot 10^{-153}:\\ \;\;\;\;\frac{t - x}{\frac{a - z}{y}}\\ \mathbf{elif}\;a \leq 1550:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;t\_2\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (+ t (/ (* (- t x) (- a y)) z))) (t_2 (+ x (* t (/ (- y z) a)))))
   (if (<= a -3.1e+28)
     t_2
     (if (<= a -3.9e-49)
       t_1
       (if (<= a -1.85e-153)
         (/ (- t x) (/ (- a z) y))
         (if (<= a 1550.0) t_1 t_2))))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = t + (((t - x) * (a - y)) / z);
	double t_2 = x + (t * ((y - z) / a));
	double tmp;
	if (a <= -3.1e+28) {
		tmp = t_2;
	} else if (a <= -3.9e-49) {
		tmp = t_1;
	} else if (a <= -1.85e-153) {
		tmp = (t - x) / ((a - z) / y);
	} else if (a <= 1550.0) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8) :: t_1
    real(8) :: t_2
    real(8) :: tmp
    t_1 = t + (((t - x) * (a - y)) / z)
    t_2 = x + (t * ((y - z) / a))
    if (a <= (-3.1d+28)) then
        tmp = t_2
    else if (a <= (-3.9d-49)) then
        tmp = t_1
    else if (a <= (-1.85d-153)) then
        tmp = (t - x) / ((a - z) / y)
    else if (a <= 1550.0d0) then
        tmp = t_1
    else
        tmp = t_2
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double t_1 = t + (((t - x) * (a - y)) / z);
	double t_2 = x + (t * ((y - z) / a));
	double tmp;
	if (a <= -3.1e+28) {
		tmp = t_2;
	} else if (a <= -3.9e-49) {
		tmp = t_1;
	} else if (a <= -1.85e-153) {
		tmp = (t - x) / ((a - z) / y);
	} else if (a <= 1550.0) {
		tmp = t_1;
	} else {
		tmp = t_2;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = t + (((t - x) * (a - y)) / z)
	t_2 = x + (t * ((y - z) / a))
	tmp = 0
	if a <= -3.1e+28:
		tmp = t_2
	elif a <= -3.9e-49:
		tmp = t_1
	elif a <= -1.85e-153:
		tmp = (t - x) / ((a - z) / y)
	elif a <= 1550.0:
		tmp = t_1
	else:
		tmp = t_2
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(t + Float64(Float64(Float64(t - x) * Float64(a - y)) / z))
	t_2 = Float64(x + Float64(t * Float64(Float64(y - z) / a)))
	tmp = 0.0
	if (a <= -3.1e+28)
		tmp = t_2;
	elseif (a <= -3.9e-49)
		tmp = t_1;
	elseif (a <= -1.85e-153)
		tmp = Float64(Float64(t - x) / Float64(Float64(a - z) / y));
	elseif (a <= 1550.0)
		tmp = t_1;
	else
		tmp = t_2;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = t + (((t - x) * (a - y)) / z);
	t_2 = x + (t * ((y - z) / a));
	tmp = 0.0;
	if (a <= -3.1e+28)
		tmp = t_2;
	elseif (a <= -3.9e-49)
		tmp = t_1;
	elseif (a <= -1.85e-153)
		tmp = (t - x) / ((a - z) / y);
	elseif (a <= 1550.0)
		tmp = t_1;
	else
		tmp = t_2;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(t + N[(N[(N[(t - x), $MachinePrecision] * N[(a - y), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x + N[(t * N[(N[(y - z), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -3.1e+28], t$95$2, If[LessEqual[a, -3.9e-49], t$95$1, If[LessEqual[a, -1.85e-153], N[(N[(t - x), $MachinePrecision] / N[(N[(a - z), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 1550.0], t$95$1, t$95$2]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := t + \frac{\left(t - x\right) \cdot \left(a - y\right)}{z}\\
t_2 := x + t \cdot \frac{y - z}{a}\\
\mathbf{if}\;a \leq -3.1 \cdot 10^{+28}:\\
\;\;\;\;t\_2\\

\mathbf{elif}\;a \leq -3.9 \cdot 10^{-49}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;a \leq -1.85 \cdot 10^{-153}:\\
\;\;\;\;\frac{t - x}{\frac{a - z}{y}}\\

\mathbf{elif}\;a \leq 1550:\\
\;\;\;\;t\_1\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if a < -3.1000000000000001e28 or 1550 < a

    1. Initial program 71.7%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in a around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]
    6. Taylor expanded in t around inf 0

      \[\leadsto expr\]
    7. Simplified0

      \[\leadsto expr\]

    if -3.1000000000000001e28 < a < -3.90000000000000011e-49 or -1.8500000000000001e-153 < a < 1550

    1. Initial program 60.3%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in z around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]

    if -3.90000000000000011e-49 < a < -1.8500000000000001e-153

    1. Initial program 90.4%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in y around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]
    6. Applied egg-rr0

      \[\leadsto expr\]
  3. Recombined 3 regimes into one program.
  4. Add Preprocessing

Alternative 6: 66.7% accurate, 0.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := t \cdot \frac{y - z}{a - z}\\ \mathbf{if}\;z \leq -3.2 \cdot 10^{+24}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq -9 \cdot 10^{-90}:\\ \;\;\;\;\left(t - x\right) \cdot \frac{y}{a - z}\\ \mathbf{elif}\;z \leq 6.5 \cdot 10^{-109}:\\ \;\;\;\;\frac{t - x}{\frac{a}{y}} + x\\ \mathbf{elif}\;z \leq 3.6 \cdot 10^{+77}:\\ \;\;\;\;x + t \cdot \frac{y - z}{a}\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (* t (/ (- y z) (- a z)))))
   (if (<= z -3.2e+24)
     t_1
     (if (<= z -9e-90)
       (* (- t x) (/ y (- a z)))
       (if (<= z 6.5e-109)
         (+ (/ (- t x) (/ a y)) x)
         (if (<= z 3.6e+77) (+ x (* t (/ (- y z) a))) t_1))))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = t * ((y - z) / (a - z));
	double tmp;
	if (z <= -3.2e+24) {
		tmp = t_1;
	} else if (z <= -9e-90) {
		tmp = (t - x) * (y / (a - z));
	} else if (z <= 6.5e-109) {
		tmp = ((t - x) / (a / y)) + x;
	} else if (z <= 3.6e+77) {
		tmp = x + (t * ((y - z) / a));
	} else {
		tmp = t_1;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8) :: t_1
    real(8) :: tmp
    t_1 = t * ((y - z) / (a - z))
    if (z <= (-3.2d+24)) then
        tmp = t_1
    else if (z <= (-9d-90)) then
        tmp = (t - x) * (y / (a - z))
    else if (z <= 6.5d-109) then
        tmp = ((t - x) / (a / y)) + x
    else if (z <= 3.6d+77) then
        tmp = x + (t * ((y - z) / a))
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double t_1 = t * ((y - z) / (a - z));
	double tmp;
	if (z <= -3.2e+24) {
		tmp = t_1;
	} else if (z <= -9e-90) {
		tmp = (t - x) * (y / (a - z));
	} else if (z <= 6.5e-109) {
		tmp = ((t - x) / (a / y)) + x;
	} else if (z <= 3.6e+77) {
		tmp = x + (t * ((y - z) / a));
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = t * ((y - z) / (a - z))
	tmp = 0
	if z <= -3.2e+24:
		tmp = t_1
	elif z <= -9e-90:
		tmp = (t - x) * (y / (a - z))
	elif z <= 6.5e-109:
		tmp = ((t - x) / (a / y)) + x
	elif z <= 3.6e+77:
		tmp = x + (t * ((y - z) / a))
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(t * Float64(Float64(y - z) / Float64(a - z)))
	tmp = 0.0
	if (z <= -3.2e+24)
		tmp = t_1;
	elseif (z <= -9e-90)
		tmp = Float64(Float64(t - x) * Float64(y / Float64(a - z)));
	elseif (z <= 6.5e-109)
		tmp = Float64(Float64(Float64(t - x) / Float64(a / y)) + x);
	elseif (z <= 3.6e+77)
		tmp = Float64(x + Float64(t * Float64(Float64(y - z) / a)));
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = t * ((y - z) / (a - z));
	tmp = 0.0;
	if (z <= -3.2e+24)
		tmp = t_1;
	elseif (z <= -9e-90)
		tmp = (t - x) * (y / (a - z));
	elseif (z <= 6.5e-109)
		tmp = ((t - x) / (a / y)) + x;
	elseif (z <= 3.6e+77)
		tmp = x + (t * ((y - z) / a));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(t * N[(N[(y - z), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -3.2e+24], t$95$1, If[LessEqual[z, -9e-90], N[(N[(t - x), $MachinePrecision] * N[(y / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 6.5e-109], N[(N[(N[(t - x), $MachinePrecision] / N[(a / y), $MachinePrecision]), $MachinePrecision] + x), $MachinePrecision], If[LessEqual[z, 3.6e+77], N[(x + N[(t * N[(N[(y - z), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := t \cdot \frac{y - z}{a - z}\\
\mathbf{if}\;z \leq -3.2 \cdot 10^{+24}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;z \leq -9 \cdot 10^{-90}:\\
\;\;\;\;\left(t - x\right) \cdot \frac{y}{a - z}\\

\mathbf{elif}\;z \leq 6.5 \cdot 10^{-109}:\\
\;\;\;\;\frac{t - x}{\frac{a}{y}} + x\\

\mathbf{elif}\;z \leq 3.6 \cdot 10^{+77}:\\
\;\;\;\;x + t \cdot \frac{y - z}{a}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if z < -3.1999999999999997e24 or 3.5999999999999998e77 < z

    1. Initial program 37.7%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in x around 0 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]

    if -3.1999999999999997e24 < z < -9.00000000000000017e-90

    1. Initial program 82.7%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in y around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]

    if -9.00000000000000017e-90 < z < 6.49999999999999959e-109

    1. Initial program 94.0%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Applied egg-rr0

      \[\leadsto expr\]
    5. Taylor expanded in z around 0 0

      \[\leadsto expr\]
    6. Simplified0

      \[\leadsto expr\]

    if 6.49999999999999959e-109 < z < 3.5999999999999998e77

    1. Initial program 90.6%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in a around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]
    6. Taylor expanded in t around inf 0

      \[\leadsto expr\]
    7. Simplified0

      \[\leadsto expr\]
  3. Recombined 4 regimes into one program.
  4. Add Preprocessing

Alternative 7: 66.6% accurate, 0.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := t \cdot \frac{y - z}{a - z}\\ \mathbf{if}\;z \leq -8.6 \cdot 10^{+23}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq -9 \cdot 10^{-90}:\\ \;\;\;\;\left(t - x\right) \cdot \frac{y}{a - z}\\ \mathbf{elif}\;z \leq 2.5 \cdot 10^{-107}:\\ \;\;\;\;x + \left(t - x\right) \cdot \frac{y}{a}\\ \mathbf{elif}\;z \leq 1.45 \cdot 10^{+78}:\\ \;\;\;\;x + t \cdot \frac{y - z}{a}\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (* t (/ (- y z) (- a z)))))
   (if (<= z -8.6e+23)
     t_1
     (if (<= z -9e-90)
       (* (- t x) (/ y (- a z)))
       (if (<= z 2.5e-107)
         (+ x (* (- t x) (/ y a)))
         (if (<= z 1.45e+78) (+ x (* t (/ (- y z) a))) t_1))))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = t * ((y - z) / (a - z));
	double tmp;
	if (z <= -8.6e+23) {
		tmp = t_1;
	} else if (z <= -9e-90) {
		tmp = (t - x) * (y / (a - z));
	} else if (z <= 2.5e-107) {
		tmp = x + ((t - x) * (y / a));
	} else if (z <= 1.45e+78) {
		tmp = x + (t * ((y - z) / a));
	} else {
		tmp = t_1;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8) :: t_1
    real(8) :: tmp
    t_1 = t * ((y - z) / (a - z))
    if (z <= (-8.6d+23)) then
        tmp = t_1
    else if (z <= (-9d-90)) then
        tmp = (t - x) * (y / (a - z))
    else if (z <= 2.5d-107) then
        tmp = x + ((t - x) * (y / a))
    else if (z <= 1.45d+78) then
        tmp = x + (t * ((y - z) / a))
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double t_1 = t * ((y - z) / (a - z));
	double tmp;
	if (z <= -8.6e+23) {
		tmp = t_1;
	} else if (z <= -9e-90) {
		tmp = (t - x) * (y / (a - z));
	} else if (z <= 2.5e-107) {
		tmp = x + ((t - x) * (y / a));
	} else if (z <= 1.45e+78) {
		tmp = x + (t * ((y - z) / a));
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = t * ((y - z) / (a - z))
	tmp = 0
	if z <= -8.6e+23:
		tmp = t_1
	elif z <= -9e-90:
		tmp = (t - x) * (y / (a - z))
	elif z <= 2.5e-107:
		tmp = x + ((t - x) * (y / a))
	elif z <= 1.45e+78:
		tmp = x + (t * ((y - z) / a))
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(t * Float64(Float64(y - z) / Float64(a - z)))
	tmp = 0.0
	if (z <= -8.6e+23)
		tmp = t_1;
	elseif (z <= -9e-90)
		tmp = Float64(Float64(t - x) * Float64(y / Float64(a - z)));
	elseif (z <= 2.5e-107)
		tmp = Float64(x + Float64(Float64(t - x) * Float64(y / a)));
	elseif (z <= 1.45e+78)
		tmp = Float64(x + Float64(t * Float64(Float64(y - z) / a)));
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = t * ((y - z) / (a - z));
	tmp = 0.0;
	if (z <= -8.6e+23)
		tmp = t_1;
	elseif (z <= -9e-90)
		tmp = (t - x) * (y / (a - z));
	elseif (z <= 2.5e-107)
		tmp = x + ((t - x) * (y / a));
	elseif (z <= 1.45e+78)
		tmp = x + (t * ((y - z) / a));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(t * N[(N[(y - z), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -8.6e+23], t$95$1, If[LessEqual[z, -9e-90], N[(N[(t - x), $MachinePrecision] * N[(y / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 2.5e-107], N[(x + N[(N[(t - x), $MachinePrecision] * N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.45e+78], N[(x + N[(t * N[(N[(y - z), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := t \cdot \frac{y - z}{a - z}\\
\mathbf{if}\;z \leq -8.6 \cdot 10^{+23}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;z \leq -9 \cdot 10^{-90}:\\
\;\;\;\;\left(t - x\right) \cdot \frac{y}{a - z}\\

\mathbf{elif}\;z \leq 2.5 \cdot 10^{-107}:\\
\;\;\;\;x + \left(t - x\right) \cdot \frac{y}{a}\\

\mathbf{elif}\;z \leq 1.45 \cdot 10^{+78}:\\
\;\;\;\;x + t \cdot \frac{y - z}{a}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if z < -8.5999999999999997e23 or 1.45000000000000008e78 < z

    1. Initial program 37.7%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in x around 0 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]

    if -8.5999999999999997e23 < z < -9.00000000000000017e-90

    1. Initial program 82.7%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in y around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]

    if -9.00000000000000017e-90 < z < 2.49999999999999985e-107

    1. Initial program 94.0%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in z around 0 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]

    if 2.49999999999999985e-107 < z < 1.45000000000000008e78

    1. Initial program 90.6%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in a around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]
    6. Taylor expanded in t around inf 0

      \[\leadsto expr\]
    7. Simplified0

      \[\leadsto expr\]
  3. Recombined 4 regimes into one program.
  4. Add Preprocessing

Alternative 8: 57.2% accurate, 0.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := t \cdot \frac{y - z}{a - z}\\ \mathbf{if}\;a \leq -1.7 \cdot 10^{+171}:\\ \;\;\;\;x + t \cdot \frac{y}{a}\\ \mathbf{elif}\;a \leq -3 \cdot 10^{-33}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;a \leq -3.4 \cdot 10^{-272}:\\ \;\;\;\;\left(t - x\right) \cdot \frac{y}{a - z}\\ \mathbf{elif}\;a \leq 3.4 \cdot 10^{+202}:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(1 - \frac{y - z}{a}\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (* t (/ (- y z) (- a z)))))
   (if (<= a -1.7e+171)
     (+ x (* t (/ y a)))
     (if (<= a -3e-33)
       t_1
       (if (<= a -3.4e-272)
         (* (- t x) (/ y (- a z)))
         (if (<= a 3.4e+202) t_1 (* x (- 1.0 (/ (- y z) a)))))))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = t * ((y - z) / (a - z));
	double tmp;
	if (a <= -1.7e+171) {
		tmp = x + (t * (y / a));
	} else if (a <= -3e-33) {
		tmp = t_1;
	} else if (a <= -3.4e-272) {
		tmp = (t - x) * (y / (a - z));
	} else if (a <= 3.4e+202) {
		tmp = t_1;
	} else {
		tmp = x * (1.0 - ((y - z) / a));
	}
	return tmp;
}
real(8) function code(x, y, z, t, a)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8) :: t_1
    real(8) :: tmp
    t_1 = t * ((y - z) / (a - z))
    if (a <= (-1.7d+171)) then
        tmp = x + (t * (y / a))
    else if (a <= (-3d-33)) then
        tmp = t_1
    else if (a <= (-3.4d-272)) then
        tmp = (t - x) * (y / (a - z))
    else if (a <= 3.4d+202) then
        tmp = t_1
    else
        tmp = x * (1.0d0 - ((y - z) / a))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double t_1 = t * ((y - z) / (a - z));
	double tmp;
	if (a <= -1.7e+171) {
		tmp = x + (t * (y / a));
	} else if (a <= -3e-33) {
		tmp = t_1;
	} else if (a <= -3.4e-272) {
		tmp = (t - x) * (y / (a - z));
	} else if (a <= 3.4e+202) {
		tmp = t_1;
	} else {
		tmp = x * (1.0 - ((y - z) / a));
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = t * ((y - z) / (a - z))
	tmp = 0
	if a <= -1.7e+171:
		tmp = x + (t * (y / a))
	elif a <= -3e-33:
		tmp = t_1
	elif a <= -3.4e-272:
		tmp = (t - x) * (y / (a - z))
	elif a <= 3.4e+202:
		tmp = t_1
	else:
		tmp = x * (1.0 - ((y - z) / a))
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(t * Float64(Float64(y - z) / Float64(a - z)))
	tmp = 0.0
	if (a <= -1.7e+171)
		tmp = Float64(x + Float64(t * Float64(y / a)));
	elseif (a <= -3e-33)
		tmp = t_1;
	elseif (a <= -3.4e-272)
		tmp = Float64(Float64(t - x) * Float64(y / Float64(a - z)));
	elseif (a <= 3.4e+202)
		tmp = t_1;
	else
		tmp = Float64(x * Float64(1.0 - Float64(Float64(y - z) / a)));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = t * ((y - z) / (a - z));
	tmp = 0.0;
	if (a <= -1.7e+171)
		tmp = x + (t * (y / a));
	elseif (a <= -3e-33)
		tmp = t_1;
	elseif (a <= -3.4e-272)
		tmp = (t - x) * (y / (a - z));
	elseif (a <= 3.4e+202)
		tmp = t_1;
	else
		tmp = x * (1.0 - ((y - z) / a));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(t * N[(N[(y - z), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -1.7e+171], N[(x + N[(t * N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, -3e-33], t$95$1, If[LessEqual[a, -3.4e-272], N[(N[(t - x), $MachinePrecision] * N[(y / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 3.4e+202], t$95$1, N[(x * N[(1.0 - N[(N[(y - z), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := t \cdot \frac{y - z}{a - z}\\
\mathbf{if}\;a \leq -1.7 \cdot 10^{+171}:\\
\;\;\;\;x + t \cdot \frac{y}{a}\\

\mathbf{elif}\;a \leq -3 \cdot 10^{-33}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;a \leq -3.4 \cdot 10^{-272}:\\
\;\;\;\;\left(t - x\right) \cdot \frac{y}{a - z}\\

\mathbf{elif}\;a \leq 3.4 \cdot 10^{+202}:\\
\;\;\;\;t\_1\\

\mathbf{else}:\\
\;\;\;\;x \cdot \left(1 - \frac{y - z}{a}\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if a < -1.7000000000000001e171

    1. Initial program 64.4%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in a around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]
    6. Taylor expanded in t around inf 0

      \[\leadsto expr\]
    7. Simplified0

      \[\leadsto expr\]
    8. Taylor expanded in y around inf 0

      \[\leadsto expr\]
    9. Simplified0

      \[\leadsto expr\]

    if -1.7000000000000001e171 < a < -3.0000000000000002e-33 or -3.4000000000000003e-272 < a < 3.4e202

    1. Initial program 69.6%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in x around 0 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]

    if -3.0000000000000002e-33 < a < -3.4000000000000003e-272

    1. Initial program 70.1%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in y around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]

    if 3.4e202 < a

    1. Initial program 63.6%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in a around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]
    6. Taylor expanded in x around inf 0

      \[\leadsto expr\]
    7. Simplified0

      \[\leadsto expr\]
  3. Recombined 4 regimes into one program.
  4. Add Preprocessing

Alternative 9: 57.1% accurate, 0.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := t \cdot \frac{y - z}{a - z}\\ \mathbf{if}\;a \leq -1.45 \cdot 10^{+171}:\\ \;\;\;\;x + t \cdot \frac{y}{a}\\ \mathbf{elif}\;a \leq -2.2 \cdot 10^{-33}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;a \leq -3 \cdot 10^{-272}:\\ \;\;\;\;y \cdot \frac{t - x}{a - z}\\ \mathbf{elif}\;a \leq 1.16 \cdot 10^{+198}:\\ \;\;\;\;t\_1\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(1 - \frac{y - z}{a}\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (* t (/ (- y z) (- a z)))))
   (if (<= a -1.45e+171)
     (+ x (* t (/ y a)))
     (if (<= a -2.2e-33)
       t_1
       (if (<= a -3e-272)
         (* y (/ (- t x) (- a z)))
         (if (<= a 1.16e+198) t_1 (* x (- 1.0 (/ (- y z) a)))))))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = t * ((y - z) / (a - z));
	double tmp;
	if (a <= -1.45e+171) {
		tmp = x + (t * (y / a));
	} else if (a <= -2.2e-33) {
		tmp = t_1;
	} else if (a <= -3e-272) {
		tmp = y * ((t - x) / (a - z));
	} else if (a <= 1.16e+198) {
		tmp = t_1;
	} else {
		tmp = x * (1.0 - ((y - z) / a));
	}
	return tmp;
}
real(8) function code(x, y, z, t, a)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8) :: t_1
    real(8) :: tmp
    t_1 = t * ((y - z) / (a - z))
    if (a <= (-1.45d+171)) then
        tmp = x + (t * (y / a))
    else if (a <= (-2.2d-33)) then
        tmp = t_1
    else if (a <= (-3d-272)) then
        tmp = y * ((t - x) / (a - z))
    else if (a <= 1.16d+198) then
        tmp = t_1
    else
        tmp = x * (1.0d0 - ((y - z) / a))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double t_1 = t * ((y - z) / (a - z));
	double tmp;
	if (a <= -1.45e+171) {
		tmp = x + (t * (y / a));
	} else if (a <= -2.2e-33) {
		tmp = t_1;
	} else if (a <= -3e-272) {
		tmp = y * ((t - x) / (a - z));
	} else if (a <= 1.16e+198) {
		tmp = t_1;
	} else {
		tmp = x * (1.0 - ((y - z) / a));
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = t * ((y - z) / (a - z))
	tmp = 0
	if a <= -1.45e+171:
		tmp = x + (t * (y / a))
	elif a <= -2.2e-33:
		tmp = t_1
	elif a <= -3e-272:
		tmp = y * ((t - x) / (a - z))
	elif a <= 1.16e+198:
		tmp = t_1
	else:
		tmp = x * (1.0 - ((y - z) / a))
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(t * Float64(Float64(y - z) / Float64(a - z)))
	tmp = 0.0
	if (a <= -1.45e+171)
		tmp = Float64(x + Float64(t * Float64(y / a)));
	elseif (a <= -2.2e-33)
		tmp = t_1;
	elseif (a <= -3e-272)
		tmp = Float64(y * Float64(Float64(t - x) / Float64(a - z)));
	elseif (a <= 1.16e+198)
		tmp = t_1;
	else
		tmp = Float64(x * Float64(1.0 - Float64(Float64(y - z) / a)));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = t * ((y - z) / (a - z));
	tmp = 0.0;
	if (a <= -1.45e+171)
		tmp = x + (t * (y / a));
	elseif (a <= -2.2e-33)
		tmp = t_1;
	elseif (a <= -3e-272)
		tmp = y * ((t - x) / (a - z));
	elseif (a <= 1.16e+198)
		tmp = t_1;
	else
		tmp = x * (1.0 - ((y - z) / a));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(t * N[(N[(y - z), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -1.45e+171], N[(x + N[(t * N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, -2.2e-33], t$95$1, If[LessEqual[a, -3e-272], N[(y * N[(N[(t - x), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 1.16e+198], t$95$1, N[(x * N[(1.0 - N[(N[(y - z), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := t \cdot \frac{y - z}{a - z}\\
\mathbf{if}\;a \leq -1.45 \cdot 10^{+171}:\\
\;\;\;\;x + t \cdot \frac{y}{a}\\

\mathbf{elif}\;a \leq -2.2 \cdot 10^{-33}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;a \leq -3 \cdot 10^{-272}:\\
\;\;\;\;y \cdot \frac{t - x}{a - z}\\

\mathbf{elif}\;a \leq 1.16 \cdot 10^{+198}:\\
\;\;\;\;t\_1\\

\mathbf{else}:\\
\;\;\;\;x \cdot \left(1 - \frac{y - z}{a}\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if a < -1.44999999999999992e171

    1. Initial program 64.4%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in a around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]
    6. Taylor expanded in t around inf 0

      \[\leadsto expr\]
    7. Simplified0

      \[\leadsto expr\]
    8. Taylor expanded in y around inf 0

      \[\leadsto expr\]
    9. Simplified0

      \[\leadsto expr\]

    if -1.44999999999999992e171 < a < -2.20000000000000005e-33 or -3.0000000000000003e-272 < a < 1.16000000000000001e198

    1. Initial program 69.6%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in x around 0 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]

    if -2.20000000000000005e-33 < a < -3.0000000000000003e-272

    1. Initial program 70.1%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in y around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]
    6. Applied egg-rr0

      \[\leadsto expr\]

    if 1.16000000000000001e198 < a

    1. Initial program 63.6%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in a around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]
    6. Taylor expanded in x around inf 0

      \[\leadsto expr\]
    7. Simplified0

      \[\leadsto expr\]
  3. Recombined 4 regimes into one program.
  4. Add Preprocessing

Alternative 10: 62.3% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := t \cdot \frac{y - z}{a - z}\\ \mathbf{if}\;z \leq -4.1 \cdot 10^{+24}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z \leq -6.2 \cdot 10^{-90}:\\ \;\;\;\;\left(t - x\right) \cdot \frac{y}{a - z}\\ \mathbf{elif}\;z \leq 1.15 \cdot 10^{+77}:\\ \;\;\;\;x + t \cdot \frac{y - z}{a}\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (* t (/ (- y z) (- a z)))))
   (if (<= z -4.1e+24)
     t_1
     (if (<= z -6.2e-90)
       (* (- t x) (/ y (- a z)))
       (if (<= z 1.15e+77) (+ x (* t (/ (- y z) a))) t_1)))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = t * ((y - z) / (a - z));
	double tmp;
	if (z <= -4.1e+24) {
		tmp = t_1;
	} else if (z <= -6.2e-90) {
		tmp = (t - x) * (y / (a - z));
	} else if (z <= 1.15e+77) {
		tmp = x + (t * ((y - z) / a));
	} else {
		tmp = t_1;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8) :: t_1
    real(8) :: tmp
    t_1 = t * ((y - z) / (a - z))
    if (z <= (-4.1d+24)) then
        tmp = t_1
    else if (z <= (-6.2d-90)) then
        tmp = (t - x) * (y / (a - z))
    else if (z <= 1.15d+77) then
        tmp = x + (t * ((y - z) / a))
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double t_1 = t * ((y - z) / (a - z));
	double tmp;
	if (z <= -4.1e+24) {
		tmp = t_1;
	} else if (z <= -6.2e-90) {
		tmp = (t - x) * (y / (a - z));
	} else if (z <= 1.15e+77) {
		tmp = x + (t * ((y - z) / a));
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = t * ((y - z) / (a - z))
	tmp = 0
	if z <= -4.1e+24:
		tmp = t_1
	elif z <= -6.2e-90:
		tmp = (t - x) * (y / (a - z))
	elif z <= 1.15e+77:
		tmp = x + (t * ((y - z) / a))
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(t * Float64(Float64(y - z) / Float64(a - z)))
	tmp = 0.0
	if (z <= -4.1e+24)
		tmp = t_1;
	elseif (z <= -6.2e-90)
		tmp = Float64(Float64(t - x) * Float64(y / Float64(a - z)));
	elseif (z <= 1.15e+77)
		tmp = Float64(x + Float64(t * Float64(Float64(y - z) / a)));
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = t * ((y - z) / (a - z));
	tmp = 0.0;
	if (z <= -4.1e+24)
		tmp = t_1;
	elseif (z <= -6.2e-90)
		tmp = (t - x) * (y / (a - z));
	elseif (z <= 1.15e+77)
		tmp = x + (t * ((y - z) / a));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(t * N[(N[(y - z), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -4.1e+24], t$95$1, If[LessEqual[z, -6.2e-90], N[(N[(t - x), $MachinePrecision] * N[(y / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.15e+77], N[(x + N[(t * N[(N[(y - z), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := t \cdot \frac{y - z}{a - z}\\
\mathbf{if}\;z \leq -4.1 \cdot 10^{+24}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;z \leq -6.2 \cdot 10^{-90}:\\
\;\;\;\;\left(t - x\right) \cdot \frac{y}{a - z}\\

\mathbf{elif}\;z \leq 1.15 \cdot 10^{+77}:\\
\;\;\;\;x + t \cdot \frac{y - z}{a}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -4.1000000000000001e24 or 1.14999999999999997e77 < z

    1. Initial program 37.7%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in x around 0 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]

    if -4.1000000000000001e24 < z < -6.2000000000000003e-90

    1. Initial program 82.7%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in y around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]

    if -6.2000000000000003e-90 < z < 1.14999999999999997e77

    1. Initial program 92.8%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in a around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]
    6. Taylor expanded in t around inf 0

      \[\leadsto expr\]
    7. Simplified0

      \[\leadsto expr\]
  3. Recombined 3 regimes into one program.
  4. Add Preprocessing

Alternative 11: 58.8% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;a \leq -1.2 \cdot 10^{+172}:\\ \;\;\;\;x + t \cdot \frac{y}{a}\\ \mathbf{elif}\;a \leq 1.65 \cdot 10^{+198}:\\ \;\;\;\;t \cdot \frac{y - z}{a - z}\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(1 - \frac{y - z}{a}\right)\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (if (<= a -1.2e+172)
   (+ x (* t (/ y a)))
   (if (<= a 1.65e+198)
     (* t (/ (- y z) (- a z)))
     (* x (- 1.0 (/ (- y z) a))))))
double code(double x, double y, double z, double t, double a) {
	double tmp;
	if (a <= -1.2e+172) {
		tmp = x + (t * (y / a));
	} else if (a <= 1.65e+198) {
		tmp = t * ((y - z) / (a - z));
	} else {
		tmp = x * (1.0 - ((y - z) / a));
	}
	return tmp;
}
real(8) function code(x, y, z, t, a)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8) :: tmp
    if (a <= (-1.2d+172)) then
        tmp = x + (t * (y / a))
    else if (a <= 1.65d+198) then
        tmp = t * ((y - z) / (a - z))
    else
        tmp = x * (1.0d0 - ((y - z) / a))
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double tmp;
	if (a <= -1.2e+172) {
		tmp = x + (t * (y / a));
	} else if (a <= 1.65e+198) {
		tmp = t * ((y - z) / (a - z));
	} else {
		tmp = x * (1.0 - ((y - z) / a));
	}
	return tmp;
}
def code(x, y, z, t, a):
	tmp = 0
	if a <= -1.2e+172:
		tmp = x + (t * (y / a))
	elif a <= 1.65e+198:
		tmp = t * ((y - z) / (a - z))
	else:
		tmp = x * (1.0 - ((y - z) / a))
	return tmp
function code(x, y, z, t, a)
	tmp = 0.0
	if (a <= -1.2e+172)
		tmp = Float64(x + Float64(t * Float64(y / a)));
	elseif (a <= 1.65e+198)
		tmp = Float64(t * Float64(Float64(y - z) / Float64(a - z)));
	else
		tmp = Float64(x * Float64(1.0 - Float64(Float64(y - z) / a)));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	tmp = 0.0;
	if (a <= -1.2e+172)
		tmp = x + (t * (y / a));
	elseif (a <= 1.65e+198)
		tmp = t * ((y - z) / (a - z));
	else
		tmp = x * (1.0 - ((y - z) / a));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -1.2e+172], N[(x + N[(t * N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 1.65e+198], N[(t * N[(N[(y - z), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(1.0 - N[(N[(y - z), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;a \leq -1.2 \cdot 10^{+172}:\\
\;\;\;\;x + t \cdot \frac{y}{a}\\

\mathbf{elif}\;a \leq 1.65 \cdot 10^{+198}:\\
\;\;\;\;t \cdot \frac{y - z}{a - z}\\

\mathbf{else}:\\
\;\;\;\;x \cdot \left(1 - \frac{y - z}{a}\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if a < -1.2e172

    1. Initial program 64.4%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in a around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]
    6. Taylor expanded in t around inf 0

      \[\leadsto expr\]
    7. Simplified0

      \[\leadsto expr\]
    8. Taylor expanded in y around inf 0

      \[\leadsto expr\]
    9. Simplified0

      \[\leadsto expr\]

    if -1.2e172 < a < 1.64999999999999997e198

    1. Initial program 69.7%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in x around 0 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]

    if 1.64999999999999997e198 < a

    1. Initial program 63.6%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in a around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]
    6. Taylor expanded in x around inf 0

      \[\leadsto expr\]
    7. Simplified0

      \[\leadsto expr\]
  3. Recombined 3 regimes into one program.
  4. Add Preprocessing

Alternative 12: 60.3% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := x + t \cdot \frac{y}{a}\\ \mathbf{if}\;a \leq -2.6 \cdot 10^{+172}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;a \leq 1.3 \cdot 10^{+158}:\\ \;\;\;\;t \cdot \frac{y - z}{a - z}\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (+ x (* t (/ y a)))))
   (if (<= a -2.6e+172)
     t_1
     (if (<= a 1.3e+158) (* t (/ (- y z) (- a z))) t_1))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = x + (t * (y / a));
	double tmp;
	if (a <= -2.6e+172) {
		tmp = t_1;
	} else if (a <= 1.3e+158) {
		tmp = t * ((y - z) / (a - z));
	} else {
		tmp = t_1;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8) :: t_1
    real(8) :: tmp
    t_1 = x + (t * (y / a))
    if (a <= (-2.6d+172)) then
        tmp = t_1
    else if (a <= 1.3d+158) then
        tmp = t * ((y - z) / (a - z))
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double t_1 = x + (t * (y / a));
	double tmp;
	if (a <= -2.6e+172) {
		tmp = t_1;
	} else if (a <= 1.3e+158) {
		tmp = t * ((y - z) / (a - z));
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = x + (t * (y / a))
	tmp = 0
	if a <= -2.6e+172:
		tmp = t_1
	elif a <= 1.3e+158:
		tmp = t * ((y - z) / (a - z))
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(x + Float64(t * Float64(y / a)))
	tmp = 0.0
	if (a <= -2.6e+172)
		tmp = t_1;
	elseif (a <= 1.3e+158)
		tmp = Float64(t * Float64(Float64(y - z) / Float64(a - z)));
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = x + (t * (y / a));
	tmp = 0.0;
	if (a <= -2.6e+172)
		tmp = t_1;
	elseif (a <= 1.3e+158)
		tmp = t * ((y - z) / (a - z));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(t * N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -2.6e+172], t$95$1, If[LessEqual[a, 1.3e+158], N[(t * N[(N[(y - z), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := x + t \cdot \frac{y}{a}\\
\mathbf{if}\;a \leq -2.6 \cdot 10^{+172}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;a \leq 1.3 \cdot 10^{+158}:\\
\;\;\;\;t \cdot \frac{y - z}{a - z}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if a < -2.6e172 or 1.3e158 < a

    1. Initial program 62.2%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in a around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]
    6. Taylor expanded in t around inf 0

      \[\leadsto expr\]
    7. Simplified0

      \[\leadsto expr\]
    8. Taylor expanded in y around inf 0

      \[\leadsto expr\]
    9. Simplified0

      \[\leadsto expr\]

    if -2.6e172 < a < 1.3e158

    1. Initial program 70.8%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in x around 0 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]
  3. Recombined 2 regimes into one program.
  4. Add Preprocessing

Alternative 13: 40.4% accurate, 0.7× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -61000000:\\ \;\;\;\;t\\ \mathbf{elif}\;z \leq 6.5 \cdot 10^{-79}:\\ \;\;\;\;x\\ \mathbf{elif}\;z \leq 1.5 \cdot 10^{+188}:\\ \;\;\;\;t + x\\ \mathbf{else}:\\ \;\;\;\;t\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (if (<= z -61000000.0)
   t
   (if (<= z 6.5e-79) x (if (<= z 1.5e+188) (+ t x) t))))
double code(double x, double y, double z, double t, double a) {
	double tmp;
	if (z <= -61000000.0) {
		tmp = t;
	} else if (z <= 6.5e-79) {
		tmp = x;
	} else if (z <= 1.5e+188) {
		tmp = t + x;
	} else {
		tmp = t;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8) :: tmp
    if (z <= (-61000000.0d0)) then
        tmp = t
    else if (z <= 6.5d-79) then
        tmp = x
    else if (z <= 1.5d+188) then
        tmp = t + x
    else
        tmp = t
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double tmp;
	if (z <= -61000000.0) {
		tmp = t;
	} else if (z <= 6.5e-79) {
		tmp = x;
	} else if (z <= 1.5e+188) {
		tmp = t + x;
	} else {
		tmp = t;
	}
	return tmp;
}
def code(x, y, z, t, a):
	tmp = 0
	if z <= -61000000.0:
		tmp = t
	elif z <= 6.5e-79:
		tmp = x
	elif z <= 1.5e+188:
		tmp = t + x
	else:
		tmp = t
	return tmp
function code(x, y, z, t, a)
	tmp = 0.0
	if (z <= -61000000.0)
		tmp = t;
	elseif (z <= 6.5e-79)
		tmp = x;
	elseif (z <= 1.5e+188)
		tmp = Float64(t + x);
	else
		tmp = t;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	tmp = 0.0;
	if (z <= -61000000.0)
		tmp = t;
	elseif (z <= 6.5e-79)
		tmp = x;
	elseif (z <= 1.5e+188)
		tmp = t + x;
	else
		tmp = t;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -61000000.0], t, If[LessEqual[z, 6.5e-79], x, If[LessEqual[z, 1.5e+188], N[(t + x), $MachinePrecision], t]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -61000000:\\
\;\;\;\;t\\

\mathbf{elif}\;z \leq 6.5 \cdot 10^{-79}:\\
\;\;\;\;x\\

\mathbf{elif}\;z \leq 1.5 \cdot 10^{+188}:\\
\;\;\;\;t + x\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if z < -6.1e7 or 1.5e188 < z

    1. Initial program 38.2%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in z around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]

    if -6.1e7 < z < 6.5000000000000003e-79

    1. Initial program 92.8%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in a around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]

    if 6.5000000000000003e-79 < z < 1.5e188

    1. Initial program 72.0%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Applied egg-rr0

      \[\leadsto expr\]
    5. Taylor expanded in z around inf 0

      \[\leadsto expr\]
    6. Simplified0

      \[\leadsto expr\]
    7. Taylor expanded in t around inf 0

      \[\leadsto expr\]
    8. Simplified0

      \[\leadsto expr\]
  3. Recombined 3 regimes into one program.
  4. Add Preprocessing

Alternative 14: 54.1% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;z \leq -5.9 \cdot 10^{+91}:\\ \;\;\;\;t\\ \mathbf{elif}\;z \leq 4.5 \cdot 10^{+80}:\\ \;\;\;\;x + t \cdot \frac{y}{a}\\ \mathbf{else}:\\ \;\;\;\;t\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (if (<= z -5.9e+91) t (if (<= z 4.5e+80) (+ x (* t (/ y a))) t)))
double code(double x, double y, double z, double t, double a) {
	double tmp;
	if (z <= -5.9e+91) {
		tmp = t;
	} else if (z <= 4.5e+80) {
		tmp = x + (t * (y / a));
	} else {
		tmp = t;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8) :: tmp
    if (z <= (-5.9d+91)) then
        tmp = t
    else if (z <= 4.5d+80) then
        tmp = x + (t * (y / a))
    else
        tmp = t
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double tmp;
	if (z <= -5.9e+91) {
		tmp = t;
	} else if (z <= 4.5e+80) {
		tmp = x + (t * (y / a));
	} else {
		tmp = t;
	}
	return tmp;
}
def code(x, y, z, t, a):
	tmp = 0
	if z <= -5.9e+91:
		tmp = t
	elif z <= 4.5e+80:
		tmp = x + (t * (y / a))
	else:
		tmp = t
	return tmp
function code(x, y, z, t, a)
	tmp = 0.0
	if (z <= -5.9e+91)
		tmp = t;
	elseif (z <= 4.5e+80)
		tmp = Float64(x + Float64(t * Float64(y / a)));
	else
		tmp = t;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	tmp = 0.0;
	if (z <= -5.9e+91)
		tmp = t;
	elseif (z <= 4.5e+80)
		tmp = x + (t * (y / a));
	else
		tmp = t;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -5.9e+91], t, If[LessEqual[z, 4.5e+80], N[(x + N[(t * N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;z \leq -5.9 \cdot 10^{+91}:\\
\;\;\;\;t\\

\mathbf{elif}\;z \leq 4.5 \cdot 10^{+80}:\\
\;\;\;\;x + t \cdot \frac{y}{a}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if z < -5.9000000000000002e91 or 4.50000000000000007e80 < z

    1. Initial program 30.0%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in z around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]

    if -5.9000000000000002e91 < z < 4.50000000000000007e80

    1. Initial program 90.4%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in a around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]
    6. Taylor expanded in t around inf 0

      \[\leadsto expr\]
    7. Simplified0

      \[\leadsto expr\]
    8. Taylor expanded in y around inf 0

      \[\leadsto expr\]
    9. Simplified0

      \[\leadsto expr\]
  3. Recombined 2 regimes into one program.
  4. Add Preprocessing

Alternative 15: 43.8% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -5.3 \cdot 10^{+48}:\\ \;\;\;\;t \cdot \frac{y}{a - z}\\ \mathbf{elif}\;y \leq 3.1 \cdot 10^{+96}:\\ \;\;\;\;t + x\\ \mathbf{else}:\\ \;\;\;\;\left(t - x\right) \cdot \frac{y}{a}\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (if (<= y -5.3e+48)
   (* t (/ y (- a z)))
   (if (<= y 3.1e+96) (+ t x) (* (- t x) (/ y a)))))
double code(double x, double y, double z, double t, double a) {
	double tmp;
	if (y <= -5.3e+48) {
		tmp = t * (y / (a - z));
	} else if (y <= 3.1e+96) {
		tmp = t + x;
	} else {
		tmp = (t - x) * (y / a);
	}
	return tmp;
}
real(8) function code(x, y, z, t, a)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8) :: tmp
    if (y <= (-5.3d+48)) then
        tmp = t * (y / (a - z))
    else if (y <= 3.1d+96) then
        tmp = t + x
    else
        tmp = (t - x) * (y / a)
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double tmp;
	if (y <= -5.3e+48) {
		tmp = t * (y / (a - z));
	} else if (y <= 3.1e+96) {
		tmp = t + x;
	} else {
		tmp = (t - x) * (y / a);
	}
	return tmp;
}
def code(x, y, z, t, a):
	tmp = 0
	if y <= -5.3e+48:
		tmp = t * (y / (a - z))
	elif y <= 3.1e+96:
		tmp = t + x
	else:
		tmp = (t - x) * (y / a)
	return tmp
function code(x, y, z, t, a)
	tmp = 0.0
	if (y <= -5.3e+48)
		tmp = Float64(t * Float64(y / Float64(a - z)));
	elseif (y <= 3.1e+96)
		tmp = Float64(t + x);
	else
		tmp = Float64(Float64(t - x) * Float64(y / a));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	tmp = 0.0;
	if (y <= -5.3e+48)
		tmp = t * (y / (a - z));
	elseif (y <= 3.1e+96)
		tmp = t + x;
	else
		tmp = (t - x) * (y / a);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := If[LessEqual[y, -5.3e+48], N[(t * N[(y / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 3.1e+96], N[(t + x), $MachinePrecision], N[(N[(t - x), $MachinePrecision] * N[(y / a), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -5.3 \cdot 10^{+48}:\\
\;\;\;\;t \cdot \frac{y}{a - z}\\

\mathbf{elif}\;y \leq 3.1 \cdot 10^{+96}:\\
\;\;\;\;t + x\\

\mathbf{else}:\\
\;\;\;\;\left(t - x\right) \cdot \frac{y}{a}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -5.3e48

    1. Initial program 68.4%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in y around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]
    6. Taylor expanded in t around inf 0

      \[\leadsto expr\]
    7. Simplified0

      \[\leadsto expr\]

    if -5.3e48 < y < 3.0999999999999998e96

    1. Initial program 67.2%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Applied egg-rr0

      \[\leadsto expr\]
    5. Taylor expanded in z around inf 0

      \[\leadsto expr\]
    6. Simplified0

      \[\leadsto expr\]
    7. Taylor expanded in t around inf 0

      \[\leadsto expr\]
    8. Simplified0

      \[\leadsto expr\]

    if 3.0999999999999998e96 < y

    1. Initial program 72.7%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in y around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]
    6. Taylor expanded in a around inf 0

      \[\leadsto expr\]
    7. Simplified0

      \[\leadsto expr\]
  3. Recombined 3 regimes into one program.
  4. Add Preprocessing

Alternative 16: 43.8% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;y \leq -9 \cdot 10^{+48}:\\ \;\;\;\;t \cdot \frac{y}{a - z}\\ \mathbf{elif}\;y \leq 9.8 \cdot 10^{+33}:\\ \;\;\;\;t + x\\ \mathbf{else}:\\ \;\;\;\;y \cdot \frac{x - t}{z}\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (if (<= y -9e+48)
   (* t (/ y (- a z)))
   (if (<= y 9.8e+33) (+ t x) (* y (/ (- x t) z)))))
double code(double x, double y, double z, double t, double a) {
	double tmp;
	if (y <= -9e+48) {
		tmp = t * (y / (a - z));
	} else if (y <= 9.8e+33) {
		tmp = t + x;
	} else {
		tmp = y * ((x - t) / z);
	}
	return tmp;
}
real(8) function code(x, y, z, t, a)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8) :: tmp
    if (y <= (-9d+48)) then
        tmp = t * (y / (a - z))
    else if (y <= 9.8d+33) then
        tmp = t + x
    else
        tmp = y * ((x - t) / z)
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double tmp;
	if (y <= -9e+48) {
		tmp = t * (y / (a - z));
	} else if (y <= 9.8e+33) {
		tmp = t + x;
	} else {
		tmp = y * ((x - t) / z);
	}
	return tmp;
}
def code(x, y, z, t, a):
	tmp = 0
	if y <= -9e+48:
		tmp = t * (y / (a - z))
	elif y <= 9.8e+33:
		tmp = t + x
	else:
		tmp = y * ((x - t) / z)
	return tmp
function code(x, y, z, t, a)
	tmp = 0.0
	if (y <= -9e+48)
		tmp = Float64(t * Float64(y / Float64(a - z)));
	elseif (y <= 9.8e+33)
		tmp = Float64(t + x);
	else
		tmp = Float64(y * Float64(Float64(x - t) / z));
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	tmp = 0.0;
	if (y <= -9e+48)
		tmp = t * (y / (a - z));
	elseif (y <= 9.8e+33)
		tmp = t + x;
	else
		tmp = y * ((x - t) / z);
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := If[LessEqual[y, -9e+48], N[(t * N[(y / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 9.8e+33], N[(t + x), $MachinePrecision], N[(y * N[(N[(x - t), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;y \leq -9 \cdot 10^{+48}:\\
\;\;\;\;t \cdot \frac{y}{a - z}\\

\mathbf{elif}\;y \leq 9.8 \cdot 10^{+33}:\\
\;\;\;\;t + x\\

\mathbf{else}:\\
\;\;\;\;y \cdot \frac{x - t}{z}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if y < -8.99999999999999991e48

    1. Initial program 68.4%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in y around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]
    6. Taylor expanded in t around inf 0

      \[\leadsto expr\]
    7. Simplified0

      \[\leadsto expr\]

    if -8.99999999999999991e48 < y < 9.80000000000000027e33

    1. Initial program 66.9%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Applied egg-rr0

      \[\leadsto expr\]
    5. Taylor expanded in z around inf 0

      \[\leadsto expr\]
    6. Simplified0

      \[\leadsto expr\]
    7. Taylor expanded in t around inf 0

      \[\leadsto expr\]
    8. Simplified0

      \[\leadsto expr\]

    if 9.80000000000000027e33 < y

    1. Initial program 72.4%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in z around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]
    6. Taylor expanded in y around inf 0

      \[\leadsto expr\]
    7. Simplified0

      \[\leadsto expr\]
  3. Recombined 3 regimes into one program.
  4. Add Preprocessing

Alternative 17: 43.1% accurate, 0.8× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := t \cdot \frac{y}{a - z}\\ \mathbf{if}\;y \leq -8.2 \cdot 10^{+49}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \leq 3.7 \cdot 10^{+96}:\\ \;\;\;\;t + x\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (* t (/ y (- a z)))))
   (if (<= y -8.2e+49) t_1 (if (<= y 3.7e+96) (+ t x) t_1))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = t * (y / (a - z));
	double tmp;
	if (y <= -8.2e+49) {
		tmp = t_1;
	} else if (y <= 3.7e+96) {
		tmp = t + x;
	} else {
		tmp = t_1;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8) :: t_1
    real(8) :: tmp
    t_1 = t * (y / (a - z))
    if (y <= (-8.2d+49)) then
        tmp = t_1
    else if (y <= 3.7d+96) then
        tmp = t + x
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double t_1 = t * (y / (a - z));
	double tmp;
	if (y <= -8.2e+49) {
		tmp = t_1;
	} else if (y <= 3.7e+96) {
		tmp = t + x;
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = t * (y / (a - z))
	tmp = 0
	if y <= -8.2e+49:
		tmp = t_1
	elif y <= 3.7e+96:
		tmp = t + x
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(t * Float64(y / Float64(a - z)))
	tmp = 0.0
	if (y <= -8.2e+49)
		tmp = t_1;
	elseif (y <= 3.7e+96)
		tmp = Float64(t + x);
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = t * (y / (a - z));
	tmp = 0.0;
	if (y <= -8.2e+49)
		tmp = t_1;
	elseif (y <= 3.7e+96)
		tmp = t + x;
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(t * N[(y / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -8.2e+49], t$95$1, If[LessEqual[y, 3.7e+96], N[(t + x), $MachinePrecision], t$95$1]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := t \cdot \frac{y}{a - z}\\
\mathbf{if}\;y \leq -8.2 \cdot 10^{+49}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;y \leq 3.7 \cdot 10^{+96}:\\
\;\;\;\;t + x\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y < -8.2e49 or 3.69999999999999991e96 < y

    1. Initial program 70.3%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in y around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]
    6. Taylor expanded in t around inf 0

      \[\leadsto expr\]
    7. Simplified0

      \[\leadsto expr\]

    if -8.2e49 < y < 3.69999999999999991e96

    1. Initial program 67.2%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Applied egg-rr0

      \[\leadsto expr\]
    5. Taylor expanded in z around inf 0

      \[\leadsto expr\]
    6. Simplified0

      \[\leadsto expr\]
    7. Taylor expanded in t around inf 0

      \[\leadsto expr\]
    8. Simplified0

      \[\leadsto expr\]
  3. Recombined 2 regimes into one program.
  4. Add Preprocessing

Alternative 18: 39.0% accurate, 0.9× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := t \cdot \frac{y}{a}\\ \mathbf{if}\;y \leq -1.45 \cdot 10^{+71}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;y \leq 8.5 \cdot 10^{+91}:\\ \;\;\;\;t + x\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (* t (/ y a))))
   (if (<= y -1.45e+71) t_1 (if (<= y 8.5e+91) (+ t x) t_1))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = t * (y / a);
	double tmp;
	if (y <= -1.45e+71) {
		tmp = t_1;
	} else if (y <= 8.5e+91) {
		tmp = t + x;
	} else {
		tmp = t_1;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8) :: t_1
    real(8) :: tmp
    t_1 = t * (y / a)
    if (y <= (-1.45d+71)) then
        tmp = t_1
    else if (y <= 8.5d+91) then
        tmp = t + x
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double t_1 = t * (y / a);
	double tmp;
	if (y <= -1.45e+71) {
		tmp = t_1;
	} else if (y <= 8.5e+91) {
		tmp = t + x;
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = t * (y / a)
	tmp = 0
	if y <= -1.45e+71:
		tmp = t_1
	elif y <= 8.5e+91:
		tmp = t + x
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(t * Float64(y / a))
	tmp = 0.0
	if (y <= -1.45e+71)
		tmp = t_1;
	elseif (y <= 8.5e+91)
		tmp = Float64(t + x);
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = t * (y / a);
	tmp = 0.0;
	if (y <= -1.45e+71)
		tmp = t_1;
	elseif (y <= 8.5e+91)
		tmp = t + x;
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(t * N[(y / a), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -1.45e+71], t$95$1, If[LessEqual[y, 8.5e+91], N[(t + x), $MachinePrecision], t$95$1]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := t \cdot \frac{y}{a}\\
\mathbf{if}\;y \leq -1.45 \cdot 10^{+71}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;y \leq 8.5 \cdot 10^{+91}:\\
\;\;\;\;t + x\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if y < -1.45000000000000004e71 or 8.4999999999999995e91 < y

    1. Initial program 70.3%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in x around 0 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]
    6. Taylor expanded in z around 0 0

      \[\leadsto expr\]
    7. Simplified0

      \[\leadsto expr\]

    if -1.45000000000000004e71 < y < 8.4999999999999995e91

    1. Initial program 67.2%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Applied egg-rr0

      \[\leadsto expr\]
    5. Taylor expanded in z around inf 0

      \[\leadsto expr\]
    6. Simplified0

      \[\leadsto expr\]
    7. Taylor expanded in t around inf 0

      \[\leadsto expr\]
    8. Simplified0

      \[\leadsto expr\]
  3. Recombined 2 regimes into one program.
  4. Add Preprocessing

Alternative 19: 38.8% accurate, 1.2× speedup?

\[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;a \leq -5 \cdot 10^{+54}:\\ \;\;\;\;x\\ \mathbf{elif}\;a \leq 6.2:\\ \;\;\;\;t\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (if (<= a -5e+54) x (if (<= a 6.2) t x)))
double code(double x, double y, double z, double t, double a) {
	double tmp;
	if (a <= -5e+54) {
		tmp = x;
	} else if (a <= 6.2) {
		tmp = t;
	} else {
		tmp = x;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8) :: tmp
    if (a <= (-5d+54)) then
        tmp = x
    else if (a <= 6.2d0) then
        tmp = t
    else
        tmp = x
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double tmp;
	if (a <= -5e+54) {
		tmp = x;
	} else if (a <= 6.2) {
		tmp = t;
	} else {
		tmp = x;
	}
	return tmp;
}
def code(x, y, z, t, a):
	tmp = 0
	if a <= -5e+54:
		tmp = x
	elif a <= 6.2:
		tmp = t
	else:
		tmp = x
	return tmp
function code(x, y, z, t, a)
	tmp = 0.0
	if (a <= -5e+54)
		tmp = x;
	elseif (a <= 6.2)
		tmp = t;
	else
		tmp = x;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	tmp = 0.0;
	if (a <= -5e+54)
		tmp = x;
	elseif (a <= 6.2)
		tmp = t;
	else
		tmp = x;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -5e+54], x, If[LessEqual[a, 6.2], t, x]]
\begin{array}{l}

\\
\begin{array}{l}
\mathbf{if}\;a \leq -5 \cdot 10^{+54}:\\
\;\;\;\;x\\

\mathbf{elif}\;a \leq 6.2:\\
\;\;\;\;t\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if a < -5.00000000000000005e54 or 6.20000000000000018 < a

    1. Initial program 70.3%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in a around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]

    if -5.00000000000000005e54 < a < 6.20000000000000018

    1. Initial program 66.8%

      \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
    2. Simplified0

      \[\leadsto expr\]
    3. Add Preprocessing
    4. Taylor expanded in z around inf 0

      \[\leadsto expr\]
    5. Simplified0

      \[\leadsto expr\]
  3. Recombined 2 regimes into one program.
  4. Add Preprocessing

Alternative 20: 25.7% accurate, 13.0× speedup?

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

\\
t
\end{array}
Derivation
  1. Initial program 68.4%

    \[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
  2. Simplified0

    \[\leadsto expr\]
  3. Add Preprocessing
  4. Taylor expanded in z around inf 0

    \[\leadsto expr\]
  5. Simplified0

    \[\leadsto expr\]
  6. Add Preprocessing

Developer target: 84.3% accurate, 0.6× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := t - \frac{y}{z} \cdot \left(t - x\right)\\ \mathbf{if}\;z < -1.2536131056095036 \cdot 10^{+188}:\\ \;\;\;\;t\_1\\ \mathbf{elif}\;z < 4.446702369113811 \cdot 10^{+64}:\\ \;\;\;\;x + \frac{y - z}{\frac{a - z}{t - x}}\\ \mathbf{else}:\\ \;\;\;\;t\_1\\ \end{array} \end{array} \]
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (- t (* (/ y z) (- t x)))))
   (if (< z -1.2536131056095036e+188)
     t_1
     (if (< z 4.446702369113811e+64)
       (+ x (/ (- y z) (/ (- a z) (- t x))))
       t_1))))
double code(double x, double y, double z, double t, double a) {
	double t_1 = t - ((y / z) * (t - x));
	double tmp;
	if (z < -1.2536131056095036e+188) {
		tmp = t_1;
	} else if (z < 4.446702369113811e+64) {
		tmp = x + ((y - z) / ((a - z) / (t - x)));
	} else {
		tmp = t_1;
	}
	return tmp;
}
real(8) function code(x, y, z, t, a)
    real(8), intent (in) :: x
    real(8), intent (in) :: y
    real(8), intent (in) :: z
    real(8), intent (in) :: t
    real(8), intent (in) :: a
    real(8) :: t_1
    real(8) :: tmp
    t_1 = t - ((y / z) * (t - x))
    if (z < (-1.2536131056095036d+188)) then
        tmp = t_1
    else if (z < 4.446702369113811d+64) then
        tmp = x + ((y - z) / ((a - z) / (t - x)))
    else
        tmp = t_1
    end if
    code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
	double t_1 = t - ((y / z) * (t - x));
	double tmp;
	if (z < -1.2536131056095036e+188) {
		tmp = t_1;
	} else if (z < 4.446702369113811e+64) {
		tmp = x + ((y - z) / ((a - z) / (t - x)));
	} else {
		tmp = t_1;
	}
	return tmp;
}
def code(x, y, z, t, a):
	t_1 = t - ((y / z) * (t - x))
	tmp = 0
	if z < -1.2536131056095036e+188:
		tmp = t_1
	elif z < 4.446702369113811e+64:
		tmp = x + ((y - z) / ((a - z) / (t - x)))
	else:
		tmp = t_1
	return tmp
function code(x, y, z, t, a)
	t_1 = Float64(t - Float64(Float64(y / z) * Float64(t - x)))
	tmp = 0.0
	if (z < -1.2536131056095036e+188)
		tmp = t_1;
	elseif (z < 4.446702369113811e+64)
		tmp = Float64(x + Float64(Float64(y - z) / Float64(Float64(a - z) / Float64(t - x))));
	else
		tmp = t_1;
	end
	return tmp
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = t - ((y / z) * (t - x));
	tmp = 0.0;
	if (z < -1.2536131056095036e+188)
		tmp = t_1;
	elseif (z < 4.446702369113811e+64)
		tmp = x + ((y - z) / ((a - z) / (t - x)));
	else
		tmp = t_1;
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(t - N[(N[(y / z), $MachinePrecision] * N[(t - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[Less[z, -1.2536131056095036e+188], t$95$1, If[Less[z, 4.446702369113811e+64], N[(x + N[(N[(y - z), $MachinePrecision] / N[(N[(a - z), $MachinePrecision] / N[(t - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := t - \frac{y}{z} \cdot \left(t - x\right)\\
\mathbf{if}\;z < -1.2536131056095036 \cdot 10^{+188}:\\
\;\;\;\;t\_1\\

\mathbf{elif}\;z < 4.446702369113811 \cdot 10^{+64}:\\
\;\;\;\;x + \frac{y - z}{\frac{a - z}{t - x}}\\

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


\end{array}
\end{array}

Reproduce

?
herbie shell --seed 2024110 
(FPCore (x y z t a)
  :name "Graphics.Rendering.Chart.Axis.Types:invLinMap from Chart-1.5.3"
  :precision binary64

  :alt
  (if (< z -1.2536131056095036e+188) (- t (* (/ y z) (- t x))) (if (< z 4.446702369113811e+64) (+ x (/ (- y z) (/ (- a z) (- t x)))) (- t (* (/ y z) (- t x)))))

  (+ x (/ (* (- y z) (- t x)) (- a z))))