?

Average Error: 24.4 → 7.9
Time: 26.4s
Precision: binary64
Cost: 4432

?

\[x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t} \]
\[\begin{array}{l} t_1 := x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t}\\ \mathbf{if}\;t_1 \leq -\infty:\\ \;\;\;\;y + \left(z - a\right) \cdot \frac{x - y}{t}\\ \mathbf{elif}\;t_1 \leq -1 \cdot 10^{-199}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;t_1 \leq 0:\\ \;\;\;\;y + \frac{\left(y - x\right) \cdot \left(a - z\right)}{t}\\ \mathbf{elif}\;t_1 \leq 2.1 \cdot 10^{+254}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;x + \left(z - t\right) \cdot \frac{y - x}{a - t}\\ \end{array} \]
(FPCore (x y z t a) :precision binary64 (+ x (/ (* (- y x) (- z t)) (- a t))))
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (+ x (/ (* (- y x) (- z t)) (- a t)))))
   (if (<= t_1 (- INFINITY))
     (+ y (* (- z a) (/ (- x y) t)))
     (if (<= t_1 -1e-199)
       t_1
       (if (<= t_1 0.0)
         (+ y (/ (* (- y x) (- a z)) t))
         (if (<= t_1 2.1e+254) t_1 (+ x (* (- z t) (/ (- y x) (- a t))))))))))
double code(double x, double y, double z, double t, double a) {
	return x + (((y - x) * (z - t)) / (a - t));
}
double code(double x, double y, double z, double t, double a) {
	double t_1 = x + (((y - x) * (z - t)) / (a - t));
	double tmp;
	if (t_1 <= -((double) INFINITY)) {
		tmp = y + ((z - a) * ((x - y) / t));
	} else if (t_1 <= -1e-199) {
		tmp = t_1;
	} else if (t_1 <= 0.0) {
		tmp = y + (((y - x) * (a - z)) / t);
	} else if (t_1 <= 2.1e+254) {
		tmp = t_1;
	} else {
		tmp = x + ((z - t) * ((y - x) / (a - t)));
	}
	return tmp;
}
public static double code(double x, double y, double z, double t, double a) {
	return x + (((y - x) * (z - t)) / (a - t));
}
public static double code(double x, double y, double z, double t, double a) {
	double t_1 = x + (((y - x) * (z - t)) / (a - t));
	double tmp;
	if (t_1 <= -Double.POSITIVE_INFINITY) {
		tmp = y + ((z - a) * ((x - y) / t));
	} else if (t_1 <= -1e-199) {
		tmp = t_1;
	} else if (t_1 <= 0.0) {
		tmp = y + (((y - x) * (a - z)) / t);
	} else if (t_1 <= 2.1e+254) {
		tmp = t_1;
	} else {
		tmp = x + ((z - t) * ((y - x) / (a - t)));
	}
	return tmp;
}
def code(x, y, z, t, a):
	return x + (((y - x) * (z - t)) / (a - t))
def code(x, y, z, t, a):
	t_1 = x + (((y - x) * (z - t)) / (a - t))
	tmp = 0
	if t_1 <= -math.inf:
		tmp = y + ((z - a) * ((x - y) / t))
	elif t_1 <= -1e-199:
		tmp = t_1
	elif t_1 <= 0.0:
		tmp = y + (((y - x) * (a - z)) / t)
	elif t_1 <= 2.1e+254:
		tmp = t_1
	else:
		tmp = x + ((z - t) * ((y - x) / (a - t)))
	return tmp
function code(x, y, z, t, a)
	return Float64(x + Float64(Float64(Float64(y - x) * Float64(z - t)) / Float64(a - t)))
end
function code(x, y, z, t, a)
	t_1 = Float64(x + Float64(Float64(Float64(y - x) * Float64(z - t)) / Float64(a - t)))
	tmp = 0.0
	if (t_1 <= Float64(-Inf))
		tmp = Float64(y + Float64(Float64(z - a) * Float64(Float64(x - y) / t)));
	elseif (t_1 <= -1e-199)
		tmp = t_1;
	elseif (t_1 <= 0.0)
		tmp = Float64(y + Float64(Float64(Float64(y - x) * Float64(a - z)) / t));
	elseif (t_1 <= 2.1e+254)
		tmp = t_1;
	else
		tmp = Float64(x + Float64(Float64(z - t) * Float64(Float64(y - x) / Float64(a - t))));
	end
	return tmp
end
function tmp = code(x, y, z, t, a)
	tmp = x + (((y - x) * (z - t)) / (a - t));
end
function tmp_2 = code(x, y, z, t, a)
	t_1 = x + (((y - x) * (z - t)) / (a - t));
	tmp = 0.0;
	if (t_1 <= -Inf)
		tmp = y + ((z - a) * ((x - y) / t));
	elseif (t_1 <= -1e-199)
		tmp = t_1;
	elseif (t_1 <= 0.0)
		tmp = y + (((y - x) * (a - z)) / t);
	elseif (t_1 <= 2.1e+254)
		tmp = t_1;
	else
		tmp = x + ((z - t) * ((y - x) / (a - t)));
	end
	tmp_2 = tmp;
end
code[x_, y_, z_, t_, a_] := N[(x + N[(N[(N[(y - x), $MachinePrecision] * N[(z - t), $MachinePrecision]), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(N[(N[(y - x), $MachinePrecision] * N[(z - t), $MachinePrecision]), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, (-Infinity)], N[(y + N[(N[(z - a), $MachinePrecision] * N[(N[(x - y), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, -1e-199], t$95$1, If[LessEqual[t$95$1, 0.0], N[(y + N[(N[(N[(y - x), $MachinePrecision] * N[(a - z), $MachinePrecision]), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, 2.1e+254], t$95$1, N[(x + N[(N[(z - t), $MachinePrecision] * N[(N[(y - x), $MachinePrecision] / N[(a - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t}
\begin{array}{l}
t_1 := x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t}\\
\mathbf{if}\;t_1 \leq -\infty:\\
\;\;\;\;y + \left(z - a\right) \cdot \frac{x - y}{t}\\

\mathbf{elif}\;t_1 \leq -1 \cdot 10^{-199}:\\
\;\;\;\;t_1\\

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

\mathbf{elif}\;t_1 \leq 2.1 \cdot 10^{+254}:\\
\;\;\;\;t_1\\

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


\end{array}

Error?

Try it out?

Your Program's Arguments

Results

Enter valid numbers for all inputs

Target

Original24.4
Target9.0
Herbie7.9
\[\begin{array}{l} \mathbf{if}\;a < -1.6153062845442575 \cdot 10^{-142}:\\ \;\;\;\;x + \frac{y - x}{1} \cdot \frac{z - t}{a - t}\\ \mathbf{elif}\;a < 3.774403170083174 \cdot 10^{-182}:\\ \;\;\;\;y - \frac{z}{t} \cdot \left(y - x\right)\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y - x}{1} \cdot \frac{z - t}{a - t}\\ \end{array} \]

Derivation?

  1. Split input into 4 regimes
  2. if (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) < -inf.0

    1. Initial program 64.0

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

      \[\leadsto \color{blue}{\mathsf{fma}\left(\frac{z - t}{a - t}, y - x, x\right)} \]
      Proof

      [Start]64.0

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

      +-commutative [=>]64.0

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

      associate-*r/ [<=]16.9

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

      *-commutative [<=]16.9

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

      fma-def [=>]16.9

      \[ \color{blue}{\mathsf{fma}\left(\frac{z - t}{a - t}, y - x, x\right)} \]
    3. Taylor expanded in t around inf 40.4

      \[\leadsto \color{blue}{y + \frac{\left(-1 \cdot z - -1 \cdot a\right) \cdot \left(y - x\right)}{t}} \]
    4. Simplified20.7

      \[\leadsto \color{blue}{y - \frac{y - x}{t} \cdot \left(z - a\right)} \]
      Proof

      [Start]40.4

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

      distribute-lft-out-- [=>]40.4

      \[ y + \frac{\color{blue}{\left(-1 \cdot \left(z - a\right)\right)} \cdot \left(y - x\right)}{t} \]

      associate-*r* [<=]40.4

      \[ y + \frac{\color{blue}{-1 \cdot \left(\left(z - a\right) \cdot \left(y - x\right)\right)}}{t} \]

      *-commutative [<=]40.4

      \[ y + \frac{-1 \cdot \color{blue}{\left(\left(y - x\right) \cdot \left(z - a\right)\right)}}{t} \]

      associate-*r/ [<=]40.4

      \[ y + \color{blue}{-1 \cdot \frac{\left(y - x\right) \cdot \left(z - a\right)}{t}} \]

      mul-1-neg [=>]40.4

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

      unsub-neg [=>]40.4

      \[ \color{blue}{y - \frac{\left(y - x\right) \cdot \left(z - a\right)}{t}} \]

      associate-/l* [=>]21.7

      \[ y - \color{blue}{\frac{y - x}{\frac{t}{z - a}}} \]

      associate-/r/ [=>]20.7

      \[ y - \color{blue}{\frac{y - x}{t} \cdot \left(z - a\right)} \]

    if -inf.0 < (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) < -9.99999999999999982e-200 or 0.0 < (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) < 2.1e254

    1. Initial program 1.7

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

    if -9.99999999999999982e-200 < (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t))) < 0.0

    1. Initial program 51.2

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

      \[\leadsto \color{blue}{x + \frac{y - x}{\frac{a - t}{z - t}}} \]
      Proof

      [Start]51.2

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

      associate-/l* [=>]51.3

      \[ x + \color{blue}{\frac{y - x}{\frac{a - t}{z - t}}} \]
    3. Taylor expanded in t around inf 9.2

      \[\leadsto \color{blue}{\left(-1 \cdot \frac{z \cdot \left(y - x\right)}{t} + y\right) - -1 \cdot \frac{a \cdot \left(y - x\right)}{t}} \]
    4. Simplified9.2

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

      [Start]9.2

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

      +-commutative [=>]9.2

      \[ \color{blue}{\left(y + -1 \cdot \frac{z \cdot \left(y - x\right)}{t}\right)} - -1 \cdot \frac{a \cdot \left(y - x\right)}{t} \]

      associate--l+ [=>]9.2

      \[ \color{blue}{y + \left(-1 \cdot \frac{z \cdot \left(y - x\right)}{t} - -1 \cdot \frac{a \cdot \left(y - x\right)}{t}\right)} \]

      *-commutative [=>]9.2

      \[ y + \left(-1 \cdot \frac{\color{blue}{\left(y - x\right) \cdot z}}{t} - -1 \cdot \frac{a \cdot \left(y - x\right)}{t}\right) \]

      associate-*r/ [=>]9.2

      \[ y + \left(\color{blue}{\frac{-1 \cdot \left(\left(y - x\right) \cdot z\right)}{t}} - -1 \cdot \frac{a \cdot \left(y - x\right)}{t}\right) \]

      associate-*r/ [=>]9.2

      \[ y + \left(\frac{-1 \cdot \left(\left(y - x\right) \cdot z\right)}{t} - \color{blue}{\frac{-1 \cdot \left(a \cdot \left(y - x\right)\right)}{t}}\right) \]

      div-sub [<=]9.2

      \[ y + \color{blue}{\frac{-1 \cdot \left(\left(y - x\right) \cdot z\right) - -1 \cdot \left(a \cdot \left(y - x\right)\right)}{t}} \]

      distribute-lft-out-- [=>]9.2

      \[ y + \frac{\color{blue}{-1 \cdot \left(\left(y - x\right) \cdot z - a \cdot \left(y - x\right)\right)}}{t} \]

    if 2.1e254 < (+.f64 x (/.f64 (*.f64 (-.f64 y x) (-.f64 z t)) (-.f64 a t)))

    1. Initial program 54.2

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

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

      [Start]54.2

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

      associate-*l/ [<=]17.7

      \[ x + \color{blue}{\frac{y - x}{a - t} \cdot \left(z - t\right)} \]
  3. Recombined 4 regimes into one program.
  4. Final simplification7.9

    \[\leadsto \begin{array}{l} \mathbf{if}\;x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t} \leq -\infty:\\ \;\;\;\;y + \left(z - a\right) \cdot \frac{x - y}{t}\\ \mathbf{elif}\;x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t} \leq -1 \cdot 10^{-199}:\\ \;\;\;\;x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t}\\ \mathbf{elif}\;x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t} \leq 0:\\ \;\;\;\;y + \frac{\left(y - x\right) \cdot \left(a - z\right)}{t}\\ \mathbf{elif}\;x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t} \leq 2.1 \cdot 10^{+254}:\\ \;\;\;\;x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t}\\ \mathbf{else}:\\ \;\;\;\;x + \left(z - t\right) \cdot \frac{y - x}{a - t}\\ \end{array} \]

Alternatives

Alternative 1
Error7.5
Cost2633
\[\begin{array}{l} t_1 := x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a - t}\\ \mathbf{if}\;t_1 \leq -1 \cdot 10^{-199} \lor \neg \left(t_1 \leq 0\right):\\ \;\;\;\;x + \frac{y - x}{\frac{a - t}{z - t}}\\ \mathbf{else}:\\ \;\;\;\;y + \frac{\left(y - x\right) \cdot \left(a - z\right)}{t}\\ \end{array} \]
Alternative 2
Error22.6
Cost1633
\[\begin{array}{l} t_1 := x + \frac{\left(y - x\right) \cdot \left(z - t\right)}{a}\\ \mathbf{if}\;a \leq -7.8 \cdot 10^{+191}:\\ \;\;\;\;x - \frac{t}{\frac{a}{y - x}}\\ \mathbf{elif}\;a \leq -3.2 \cdot 10^{+62}:\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \mathbf{elif}\;a \leq -1 \cdot 10^{+33}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;a \leq -230000:\\ \;\;\;\;y - a \cdot \frac{x}{t}\\ \mathbf{elif}\;a \leq -9.4 \cdot 10^{-17}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;a \leq -9.5 \cdot 10^{-62}:\\ \;\;\;\;y + \frac{\left(y - x\right) \cdot \left(a - z\right)}{t}\\ \mathbf{elif}\;a \leq -2.6 \cdot 10^{-98} \lor \neg \left(a \leq 5.6 \cdot 10^{-40}\right):\\ \;\;\;\;x + \left(y - x\right) \cdot \frac{z}{a}\\ \mathbf{else}:\\ \;\;\;\;y + \frac{x - y}{\frac{t}{z}}\\ \end{array} \]
Alternative 3
Error20.6
Cost1365
\[\begin{array}{l} \mathbf{if}\;a \leq -8.6 \cdot 10^{+180}:\\ \;\;\;\;x + \frac{t}{a - t} \cdot \left(x - y\right)\\ \mathbf{elif}\;a \leq -2.35 \cdot 10^{-17}:\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \mathbf{elif}\;a \leq 46000 \lor \neg \left(a \leq 4.3 \cdot 10^{+38}\right) \land a \leq 3.05 \cdot 10^{+71}:\\ \;\;\;\;y + \left(z - a\right) \cdot \frac{x - y}{t}\\ \mathbf{else}:\\ \;\;\;\;x + \left(y - x\right) \cdot \frac{z}{a}\\ \end{array} \]
Alternative 4
Error19.9
Cost1365
\[\begin{array}{l} \mathbf{if}\;a \leq -8.6 \cdot 10^{+180}:\\ \;\;\;\;x + \frac{t}{a - t} \cdot \left(x - y\right)\\ \mathbf{elif}\;a \leq -2.7 \cdot 10^{-17}:\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \mathbf{elif}\;a \leq 13500:\\ \;\;\;\;y + \frac{x - y}{\frac{t}{z - a}}\\ \mathbf{elif}\;a \leq 1.66 \cdot 10^{+38} \lor \neg \left(a \leq 2.6 \cdot 10^{+71}\right):\\ \;\;\;\;x + \left(y - x\right) \cdot \frac{z}{a}\\ \mathbf{else}:\\ \;\;\;\;y + \left(z - a\right) \cdot \frac{x - y}{t}\\ \end{array} \]
Alternative 5
Error29.7
Cost1236
\[\begin{array}{l} t_1 := x \cdot \left(1 - \frac{z}{a}\right)\\ t_2 := y \cdot \frac{z - t}{a - t}\\ \mathbf{if}\;y \leq -5.4 \cdot 10^{+25}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;y \leq -5 \cdot 10^{-236}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;y \leq 2 \cdot 10^{-250}:\\ \;\;\;\;\frac{-z}{\frac{a - t}{x}}\\ \mathbf{elif}\;y \leq 9.2 \cdot 10^{-176}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;y \leq 1.75 \cdot 10^{-85}:\\ \;\;\;\;x \cdot \frac{-z}{a - t}\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \]
Alternative 6
Error29.5
Cost1236
\[\begin{array}{l} t_1 := x \cdot \left(1 - \frac{z}{a}\right)\\ t_2 := y \cdot \frac{z - t}{a - t}\\ t_3 := z \cdot \frac{y - x}{a - t}\\ \mathbf{if}\;y \leq -7.6 \cdot 10^{+25}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;y \leq -3.05 \cdot 10^{-211}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;y \leq 1.35 \cdot 10^{-247}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;y \leq 4.3 \cdot 10^{-132}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;y \leq 7.6 \cdot 10^{-21}:\\ \;\;\;\;t_3\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \]
Alternative 7
Error19.6
Cost1100
\[\begin{array}{l} \mathbf{if}\;t \leq -1.3 \cdot 10^{+50}:\\ \;\;\;\;y + \frac{x - y}{\frac{t}{z}}\\ \mathbf{elif}\;t \leq 6.8 \cdot 10^{-49}:\\ \;\;\;\;x + \left(y - x\right) \cdot \frac{z}{a}\\ \mathbf{elif}\;t \leq 1.25 \cdot 10^{+103}:\\ \;\;\;\;x + \frac{t}{a - t} \cdot \left(x - y\right)\\ \mathbf{else}:\\ \;\;\;\;y + z \cdot \frac{x - y}{t}\\ \end{array} \]
Alternative 8
Error9.6
Cost1097
\[\begin{array}{l} \mathbf{if}\;t \leq -4.15 \cdot 10^{+127} \lor \neg \left(t \leq 1.2 \cdot 10^{+107}\right):\\ \;\;\;\;y + \frac{x - y}{\frac{t}{z - a}}\\ \mathbf{else}:\\ \;\;\;\;x + \left(z - t\right) \cdot \frac{y - x}{a - t}\\ \end{array} \]
Alternative 9
Error20.7
Cost972
\[\begin{array}{l} t_1 := y + z \cdot \frac{x - y}{t}\\ \mathbf{if}\;t \leq -1.95 \cdot 10^{+50}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;t \leq 6.6 \cdot 10^{-100}:\\ \;\;\;\;x + \left(y - x\right) \cdot \frac{z}{a}\\ \mathbf{elif}\;t \leq 1.5 \cdot 10^{+164}:\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \]
Alternative 10
Error20.6
Cost972
\[\begin{array}{l} \mathbf{if}\;t \leq -6.4 \cdot 10^{+50}:\\ \;\;\;\;y + \frac{x - y}{\frac{t}{z}}\\ \mathbf{elif}\;t \leq 6 \cdot 10^{-100}:\\ \;\;\;\;x + \left(y - x\right) \cdot \frac{z}{a}\\ \mathbf{elif}\;t \leq 3.6 \cdot 10^{+163}:\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \mathbf{else}:\\ \;\;\;\;y + z \cdot \frac{x - y}{t}\\ \end{array} \]
Alternative 11
Error30.7
Cost908
\[\begin{array}{l} \mathbf{if}\;t \leq -3.4 \cdot 10^{+52}:\\ \;\;\;\;y - a \cdot \frac{x}{t}\\ \mathbf{elif}\;t \leq 4.2 \cdot 10^{-222}:\\ \;\;\;\;x \cdot \left(1 - \frac{z}{a}\right)\\ \mathbf{elif}\;t \leq 6.6 \cdot 10^{-100}:\\ \;\;\;\;x + \frac{y \cdot z}{a}\\ \mathbf{else}:\\ \;\;\;\;\frac{y}{\frac{a - t}{-t}}\\ \end{array} \]
Alternative 12
Error29.8
Cost844
\[\begin{array}{l} t_1 := y \cdot \left(1 - \frac{z}{t}\right)\\ \mathbf{if}\;t \leq -1.28 \cdot 10^{-8}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;t \leq 7.6 \cdot 10^{-225}:\\ \;\;\;\;x \cdot \left(1 - \frac{z}{a}\right)\\ \mathbf{elif}\;t \leq 60000:\\ \;\;\;\;x + \frac{y \cdot z}{a}\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \]
Alternative 13
Error29.3
Cost844
\[\begin{array}{l} t_1 := y - a \cdot \frac{x}{t}\\ \mathbf{if}\;t \leq -2.2 \cdot 10^{+52}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;t \leq 3.6 \cdot 10^{-217}:\\ \;\;\;\;x \cdot \left(1 - \frac{z}{a}\right)\\ \mathbf{elif}\;t \leq 0.155:\\ \;\;\;\;x + \frac{y \cdot z}{a}\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \]
Alternative 14
Error22.1
Cost841
\[\begin{array}{l} \mathbf{if}\;t \leq -2.8 \cdot 10^{+50} \lor \neg \left(t \leq 4.2 \cdot 10^{-100}\right):\\ \;\;\;\;y \cdot \frac{z - t}{a - t}\\ \mathbf{else}:\\ \;\;\;\;x + \left(y - x\right) \cdot \frac{z}{a}\\ \end{array} \]
Alternative 15
Error31.3
Cost713
\[\begin{array}{l} \mathbf{if}\;t \leq -2.2 \cdot 10^{-5} \lor \neg \left(t \leq 5 \cdot 10^{-101}\right):\\ \;\;\;\;y \cdot \left(1 - \frac{z}{t}\right)\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(1 - \frac{z}{a}\right)\\ \end{array} \]
Alternative 16
Error33.2
Cost712
\[\begin{array}{l} \mathbf{if}\;a \leq -1.16 \cdot 10^{+170}:\\ \;\;\;\;x\\ \mathbf{elif}\;a \leq 2.5 \cdot 10^{+70}:\\ \;\;\;\;y \cdot \left(1 - \frac{z}{t}\right)\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]
Alternative 17
Error36.5
Cost328
\[\begin{array}{l} \mathbf{if}\;t \leq -1.26 \cdot 10^{+50}:\\ \;\;\;\;y\\ \mathbf{elif}\;t \leq 6.6 \cdot 10^{-100}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;y\\ \end{array} \]
Alternative 18
Error45.6
Cost64
\[x \]

Error

Reproduce?

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

  :herbie-target
  (if (< a -1.6153062845442575e-142) (+ x (* (/ (- y x) 1.0) (/ (- z t) (- a t)))) (if (< a 3.774403170083174e-182) (- y (* (/ z t) (- y x))) (+ x (* (/ (- y x) 1.0) (/ (- z t) (- a t))))))

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