?

Average Error: 24.9 → 6.8
Time: 27.1s
Precision: binary64
Cost: 8004

?

\[x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \]
\[\begin{array}{l} t_1 := \frac{y - z}{a - z}\\ t_2 := x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z}\\ \mathbf{if}\;t_2 \leq -5 \cdot 10^{-294}:\\ \;\;\;\;\mathsf{fma}\left(t_1, t - x, x\right)\\ \mathbf{elif}\;t_2 \leq 0:\\ \;\;\;\;t + \left(t - x\right) \cdot \frac{a - y}{z}\\ \mathbf{else}:\\ \;\;\;\;x + \left(t - x\right) \cdot t_1\\ \end{array} \]
(FPCore (x y z t a) :precision binary64 (+ x (/ (* (- y z) (- t x)) (- a z))))
(FPCore (x y z t a)
 :precision binary64
 (let* ((t_1 (/ (- y z) (- a z))) (t_2 (+ x (/ (* (- y z) (- t x)) (- a z)))))
   (if (<= t_2 -5e-294)
     (fma t_1 (- t x) x)
     (if (<= t_2 0.0) (+ t (* (- t x) (/ (- a y) z))) (+ x (* (- t x) t_1))))))
double code(double x, double y, double z, double t, double a) {
	return x + (((y - z) * (t - x)) / (a - z));
}
double code(double x, double y, double z, double t, double a) {
	double t_1 = (y - z) / (a - z);
	double t_2 = x + (((y - z) * (t - x)) / (a - z));
	double tmp;
	if (t_2 <= -5e-294) {
		tmp = fma(t_1, (t - x), x);
	} else if (t_2 <= 0.0) {
		tmp = t + ((t - x) * ((a - y) / z));
	} else {
		tmp = x + ((t - x) * t_1);
	}
	return tmp;
}
function code(x, y, z, t, a)
	return Float64(x + Float64(Float64(Float64(y - z) * Float64(t - x)) / Float64(a - z)))
end
function code(x, y, z, t, a)
	t_1 = Float64(Float64(y - z) / Float64(a - z))
	t_2 = Float64(x + Float64(Float64(Float64(y - z) * Float64(t - x)) / Float64(a - z)))
	tmp = 0.0
	if (t_2 <= -5e-294)
		tmp = fma(t_1, Float64(t - x), x);
	elseif (t_2 <= 0.0)
		tmp = Float64(t + Float64(Float64(t - x) * Float64(Float64(a - y) / z)));
	else
		tmp = Float64(x + Float64(Float64(t - x) * t_1));
	end
	return tmp
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]
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(y - z), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x + N[(N[(N[(y - z), $MachinePrecision] * N[(t - x), $MachinePrecision]), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, -5e-294], N[(t$95$1 * N[(t - x), $MachinePrecision] + x), $MachinePrecision], If[LessEqual[t$95$2, 0.0], N[(t + N[(N[(t - x), $MachinePrecision] * N[(N[(a - y), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(t - x), $MachinePrecision] * t$95$1), $MachinePrecision]), $MachinePrecision]]]]]
x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z}
\begin{array}{l}
t_1 := \frac{y - z}{a - z}\\
t_2 := x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z}\\
\mathbf{if}\;t_2 \leq -5 \cdot 10^{-294}:\\
\;\;\;\;\mathsf{fma}\left(t_1, t - x, x\right)\\

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

\mathbf{else}:\\
\;\;\;\;x + \left(t - x\right) \cdot t_1\\


\end{array}

Error?

Target

Original24.9
Target11.9
Herbie6.8
\[\begin{array}{l} \mathbf{if}\;z < -1.2536131056095036 \cdot 10^{+188}:\\ \;\;\;\;t - \frac{y}{z} \cdot \left(t - x\right)\\ \mathbf{elif}\;z < 4.446702369113811 \cdot 10^{+64}:\\ \;\;\;\;x + \frac{y - z}{\frac{a - z}{t - x}}\\ \mathbf{else}:\\ \;\;\;\;t - \frac{y}{z} \cdot \left(t - x\right)\\ \end{array} \]

Derivation?

  1. Split input into 3 regimes
  2. if (+.f64 x (/.f64 (*.f64 (-.f64 y z) (-.f64 t x)) (-.f64 a z))) < -5.0000000000000003e-294

    1. Initial program 21.7

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

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

      [Start]21.7

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

      +-commutative [=>]21.7

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

      associate-*l/ [<=]7.4

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

      fma-def [=>]7.4

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

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

    1. Initial program 60.3

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

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

      [Start]60.3

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

      +-commutative [=>]60.3

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

      associate-*l/ [<=]60.2

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

      fma-def [=>]60.2

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

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

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

      [Start]1.2

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

      +-commutative [=>]1.2

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

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

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

      associate-*r* [<=]1.2

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

      mul-1-neg [=>]1.2

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

      distribute-neg-frac [<=]1.2

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

      unsub-neg [=>]1.2

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

      associate-*l/ [<=]1.5

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

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

    1. Initial program 21.5

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

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

      [Start]21.5

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

      associate-*l/ [<=]7.1

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \leq -5 \cdot 10^{-294}:\\ \;\;\;\;\mathsf{fma}\left(\frac{y - z}{a - z}, t - x, x\right)\\ \mathbf{elif}\;x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z} \leq 0:\\ \;\;\;\;t + \left(t - x\right) \cdot \frac{a - y}{z}\\ \mathbf{else}:\\ \;\;\;\;x + \left(t - x\right) \cdot \frac{y - z}{a - z}\\ \end{array} \]

Alternatives

Alternative 1
Error6.8
Cost2633
\[\begin{array}{l} t_1 := x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z}\\ \mathbf{if}\;t_1 \leq -5 \cdot 10^{-294} \lor \neg \left(t_1 \leq 0\right):\\ \;\;\;\;x + \left(t - x\right) \cdot \frac{y - z}{a - z}\\ \mathbf{else}:\\ \;\;\;\;t + \left(t - x\right) \cdot \frac{a - y}{z}\\ \end{array} \]
Alternative 2
Error31.0
Cost1632
\[\begin{array}{l} t_1 := \left(t - x\right) \cdot \frac{y}{a - z}\\ t_2 := x - x \cdot \frac{y}{a}\\ \mathbf{if}\;x \leq -1.02 \cdot 10^{+125}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;x \leq -9.2 \cdot 10^{+105}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;x \leq -3.9 \cdot 10^{-54}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;x \leq 3.25 \cdot 10^{-111}:\\ \;\;\;\;t \cdot \frac{y - z}{a - z}\\ \mathbf{elif}\;x \leq 1.26 \cdot 10^{+43}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;x \leq 2.7 \cdot 10^{+69}:\\ \;\;\;\;x - \frac{t}{\frac{a}{z}}\\ \mathbf{elif}\;x \leq 7.5 \cdot 10^{+135}:\\ \;\;\;\;t - x \cdot \frac{a}{z}\\ \mathbf{elif}\;x \leq 3.2 \cdot 10^{+260}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;x \cdot \left(\frac{z}{a - z} + 1\right)\\ \end{array} \]
Alternative 3
Error30.0
Cost1504
\[\begin{array}{l} t_1 := x - x \cdot \frac{y}{a}\\ t_2 := t \cdot \frac{y - z}{a - z}\\ \mathbf{if}\;x \leq -1.7 \cdot 10^{+126}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;x \leq -3.3 \cdot 10^{+112}:\\ \;\;\;\;y \cdot \frac{x}{z - a}\\ \mathbf{elif}\;x \leq -4 \cdot 10^{-55}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;x \leq 4.2 \cdot 10^{-91}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;x \leq 4.2 \cdot 10^{-6}:\\ \;\;\;\;x \cdot \frac{y}{z - a}\\ \mathbf{elif}\;x \leq 6 \cdot 10^{+29}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;x \leq 1.42 \cdot 10^{+75}:\\ \;\;\;\;x - \frac{t}{\frac{a}{z}}\\ \mathbf{elif}\;x \leq 1.1 \cdot 10^{+135}:\\ \;\;\;\;t - x \cdot \frac{a}{z}\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \]
Alternative 4
Error38.5
Cost1240
\[\begin{array}{l} t_1 := z \cdot \frac{t}{z - a}\\ \mathbf{if}\;a \leq -2.8 \cdot 10^{+125}:\\ \;\;\;\;x\\ \mathbf{elif}\;a \leq -1.3 \cdot 10^{+61}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;a \leq -1 \cdot 10^{+21}:\\ \;\;\;\;x\\ \mathbf{elif}\;a \leq 8.2 \cdot 10^{-307}:\\ \;\;\;\;x \cdot \frac{y}{z - a}\\ \mathbf{elif}\;a \leq 10^{-70}:\\ \;\;\;\;t\\ \mathbf{elif}\;a \leq 5.6 \cdot 10^{+128}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]
Alternative 5
Error37.4
Cost1240
\[\begin{array}{l} \mathbf{if}\;a \leq -4.1 \cdot 10^{+117}:\\ \;\;\;\;x\\ \mathbf{elif}\;a \leq -8.4 \cdot 10^{-51}:\\ \;\;\;\;\left(t - x\right) \cdot \frac{y}{a}\\ \mathbf{elif}\;a \leq -4 \cdot 10^{-189}:\\ \;\;\;\;t\\ \mathbf{elif}\;a \leq 1.25 \cdot 10^{-283}:\\ \;\;\;\;x \cdot \frac{y}{z - a}\\ \mathbf{elif}\;a \leq 2.4 \cdot 10^{-73}:\\ \;\;\;\;t\\ \mathbf{elif}\;a \leq 3.5 \cdot 10^{+128}:\\ \;\;\;\;z \cdot \frac{t}{z - a}\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]
Alternative 6
Error27.7
Cost1172
\[\begin{array}{l} t_1 := x - \frac{t}{\frac{a}{z}}\\ t_2 := t - \frac{a}{\frac{z}{x}}\\ \mathbf{if}\;z \leq -6 \cdot 10^{+62}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;z \leq -3.35 \cdot 10^{-18}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq 10^{-38}:\\ \;\;\;\;x + t \cdot \frac{y}{a}\\ \mathbf{elif}\;z \leq 5.5 \cdot 10^{+91}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq 2.8 \cdot 10^{+221}:\\ \;\;\;\;t_2\\ \mathbf{else}:\\ \;\;\;\;t \cdot \frac{-z}{a - z}\\ \end{array} \]
Alternative 7
Error27.7
Cost1172
\[\begin{array}{l} t_1 := x - \frac{t}{\frac{a}{z}}\\ \mathbf{if}\;z \leq -1.05 \cdot 10^{+62}:\\ \;\;\;\;t - x \cdot \frac{a}{z}\\ \mathbf{elif}\;z \leq -2.4 \cdot 10^{-18}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq 3.1 \cdot 10^{-34}:\\ \;\;\;\;x + t \cdot \frac{y}{a}\\ \mathbf{elif}\;z \leq 4.2 \cdot 10^{+91}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq 6.6 \cdot 10^{+221}:\\ \;\;\;\;t - \frac{a}{\frac{z}{x}}\\ \mathbf{else}:\\ \;\;\;\;t \cdot \frac{-z}{a - z}\\ \end{array} \]
Alternative 8
Error23.2
Cost1105
\[\begin{array}{l} \mathbf{if}\;z \leq -1.85 \cdot 10^{+59}:\\ \;\;\;\;t - \frac{a}{z} \cdot \left(x - t\right)\\ \mathbf{elif}\;z \leq -0.025:\\ \;\;\;\;x - \frac{t}{\frac{a}{z}}\\ \mathbf{elif}\;z \leq -5.9 \cdot 10^{-18} \lor \neg \left(z \leq 3.5 \cdot 10^{-23}\right):\\ \;\;\;\;t \cdot \frac{y - z}{a - z}\\ \mathbf{else}:\\ \;\;\;\;x + y \cdot \frac{t - x}{a}\\ \end{array} \]
Alternative 9
Error22.5
Cost1105
\[\begin{array}{l} \mathbf{if}\;z \leq -1.2 \cdot 10^{+63}:\\ \;\;\;\;t - \frac{a}{z} \cdot \left(x - t\right)\\ \mathbf{elif}\;z \leq -0.0032:\\ \;\;\;\;x - \frac{t}{\frac{a}{z}}\\ \mathbf{elif}\;z \leq -6.3 \cdot 10^{-18} \lor \neg \left(z \leq 1.6 \cdot 10^{-24}\right):\\ \;\;\;\;t \cdot \frac{y - z}{a - z}\\ \mathbf{else}:\\ \;\;\;\;x + \left(t - x\right) \cdot \frac{y}{a}\\ \end{array} \]
Alternative 10
Error20.6
Cost1104
\[\begin{array}{l} t_1 := t - \frac{y}{\frac{z}{t - x}}\\ \mathbf{if}\;z \leq -9.5 \cdot 10^{+93}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq -3.6 \cdot 10^{-6}:\\ \;\;\;\;x - \frac{t}{\frac{a}{z}}\\ \mathbf{elif}\;z \leq -7.2 \cdot 10^{-18}:\\ \;\;\;\;t \cdot \frac{y - z}{a - z}\\ \mathbf{elif}\;z \leq 240000:\\ \;\;\;\;x + \left(t - x\right) \cdot \frac{y}{a}\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \]
Alternative 11
Error16.6
Cost1100
\[\begin{array}{l} t_1 := t + \left(t - x\right) \cdot \frac{a - y}{z}\\ \mathbf{if}\;z \leq -8.8 \cdot 10^{+80}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq -3.05 \cdot 10^{-18}:\\ \;\;\;\;x - \frac{z}{\frac{a - z}{t}}\\ \mathbf{elif}\;z \leq 0.84:\\ \;\;\;\;x + \left(t - x\right) \cdot \frac{y}{a}\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \]
Alternative 12
Error16.6
Cost1100
\[\begin{array}{l} t_1 := t + \left(t - x\right) \cdot \frac{a - y}{z}\\ \mathbf{if}\;z \leq -1.15 \cdot 10^{+99}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq -4.5 \cdot 10^{-24}:\\ \;\;\;\;x - \frac{z}{\frac{a - z}{t - x}}\\ \mathbf{elif}\;z \leq 5.7 \cdot 10^{-6}:\\ \;\;\;\;x + \left(t - x\right) \cdot \frac{y}{a}\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \]
Alternative 13
Error28.5
Cost1040
\[\begin{array}{l} t_1 := t \cdot \frac{-z}{a - z}\\ \mathbf{if}\;z \leq -2.3 \cdot 10^{+124}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq -9 \cdot 10^{-9}:\\ \;\;\;\;x - \frac{t}{\frac{a}{z}}\\ \mathbf{elif}\;z \leq -6.9 \cdot 10^{-18}:\\ \;\;\;\;\frac{z \cdot t}{z - a}\\ \mathbf{elif}\;z \leq 1.55 \cdot 10^{-20}:\\ \;\;\;\;x + t \cdot \frac{y}{a}\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \]
Alternative 14
Error29.8
Cost976
\[\begin{array}{l} t_1 := x - \frac{t}{\frac{a}{z}}\\ \mathbf{if}\;z \leq -9.5 \cdot 10^{+130}:\\ \;\;\;\;t\\ \mathbf{elif}\;z \leq -3.7 \cdot 10^{-18}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq 1.5 \cdot 10^{-36}:\\ \;\;\;\;x + t \cdot \frac{y}{a}\\ \mathbf{elif}\;z \leq 1.15 \cdot 10^{+92}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;t\\ \end{array} \]
Alternative 15
Error20.0
Cost972
\[\begin{array}{l} t_1 := t - \frac{y}{\frac{z}{t - x}}\\ \mathbf{if}\;z \leq -1.9 \cdot 10^{+173}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;z \leq -2.65 \cdot 10^{-18}:\\ \;\;\;\;x - \frac{z}{\frac{a - z}{t}}\\ \mathbf{elif}\;z \leq 900:\\ \;\;\;\;x + \left(t - x\right) \cdot \frac{y}{a}\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \]
Alternative 16
Error38.1
Cost712
\[\begin{array}{l} \mathbf{if}\;a \leq -4.6 \cdot 10^{+18}:\\ \;\;\;\;x\\ \mathbf{elif}\;a \leq 3.1 \cdot 10^{-295}:\\ \;\;\;\;x \cdot \frac{y}{z - a}\\ \mathbf{elif}\;a \leq 2.2 \cdot 10^{+102}:\\ \;\;\;\;t\\ \mathbf{else}:\\ \;\;\;\;x\\ \end{array} \]
Alternative 17
Error30.3
Cost712
\[\begin{array}{l} \mathbf{if}\;z \leq -1.7 \cdot 10^{+125}:\\ \;\;\;\;t\\ \mathbf{elif}\;z \leq 5 \cdot 10^{-23}:\\ \;\;\;\;x + t \cdot \frac{y}{a}\\ \mathbf{else}:\\ \;\;\;\;z \cdot \frac{t}{z - a}\\ \end{array} \]
Alternative 18
Error36.1
Cost328
\[\begin{array}{l} \mathbf{if}\;z \leq -3.8 \cdot 10^{+124}:\\ \;\;\;\;t\\ \mathbf{elif}\;z \leq 1.05 \cdot 10^{+88}:\\ \;\;\;\;x\\ \mathbf{else}:\\ \;\;\;\;t\\ \end{array} \]
Alternative 19
Error45.8
Cost64
\[t \]

Error

Reproduce?

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

  :herbie-target
  (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))))