?

Average Accuracy: 99.9% → 99.9%
Time: 9.9s
Precision: binary64
Cost: 576

?

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

Error?

Try it out?

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation?

  1. Initial program 99.9%

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

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

Alternatives

Alternative 1
Accuracy43.8%
Cost1377
\[\begin{array}{l} t_1 := y \cdot \frac{0.5}{t}\\ t_2 := \frac{-0.5}{\frac{t}{z}}\\ t_3 := z \cdot \frac{-0.5}{t}\\ \mathbf{if}\;x \leq -1.55 \cdot 10^{+61}:\\ \;\;\;\;x \cdot \frac{0.5}{t}\\ \mathbf{elif}\;x \leq -5.8 \cdot 10^{+16}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;x \leq -4.2 \cdot 10^{-27}:\\ \;\;\;\;\frac{0.5}{\frac{t}{x}}\\ \mathbf{elif}\;x \leq -1.08 \cdot 10^{-186}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;x \leq -1.5 \cdot 10^{-214}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;x \leq 2.4 \cdot 10^{-197}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;x \leq 7.5 \cdot 10^{-132} \lor \neg \left(x \leq 3.3 \cdot 10^{-78}\right):\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \]
Alternative 2
Accuracy44.0%
Cost1377
\[\begin{array}{l} t_1 := \frac{x}{\frac{t}{0.5}}\\ t_2 := \frac{-0.5}{\frac{t}{z}}\\ t_3 := y \cdot \frac{0.5}{t}\\ t_4 := z \cdot \frac{-0.5}{t}\\ \mathbf{if}\;x \leq -2.9 \cdot 10^{+59}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;x \leq -4.5 \cdot 10^{+16}:\\ \;\;\;\;t_4\\ \mathbf{elif}\;x \leq -4.8 \cdot 10^{-27}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;x \leq -1.5 \cdot 10^{-186}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;x \leq -9 \cdot 10^{-213}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;x \leq 2.05 \cdot 10^{-197}:\\ \;\;\;\;t_4\\ \mathbf{elif}\;x \leq 4.7 \cdot 10^{-129} \lor \neg \left(x \leq 8.8 \cdot 10^{-79}\right):\\ \;\;\;\;t_3\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \]
Alternative 3
Accuracy43.9%
Cost1377
\[\begin{array}{l} t_1 := \frac{x}{\frac{t}{0.5}}\\ t_2 := \frac{-0.5}{\frac{t}{z}}\\ t_3 := \frac{y}{\frac{t}{0.5}}\\ t_4 := z \cdot \frac{-0.5}{t}\\ \mathbf{if}\;x \leq -1.8 \cdot 10^{+63}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;x \leq -5.8 \cdot 10^{+16}:\\ \;\;\;\;t_4\\ \mathbf{elif}\;x \leq -5 \cdot 10^{-28}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;x \leq -4.4 \cdot 10^{-187}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;x \leq -5 \cdot 10^{-214}:\\ \;\;\;\;t_3\\ \mathbf{elif}\;x \leq 2.3 \cdot 10^{-197}:\\ \;\;\;\;t_4\\ \mathbf{elif}\;x \leq 2.3 \cdot 10^{-130} \lor \neg \left(x \leq 2.3 \cdot 10^{-78}\right):\\ \;\;\;\;t_3\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \]
Alternative 4
Accuracy44.4%
Cost1114
\[\begin{array}{l} \mathbf{if}\;x \leq -1.1 \cdot 10^{+61}:\\ \;\;\;\;x \cdot \frac{0.5}{t}\\ \mathbf{elif}\;x \leq -8.8 \cdot 10^{-187} \lor \neg \left(x \leq -6.2 \cdot 10^{-215}\right) \land \left(x \leq 1.75 \cdot 10^{-197} \lor \neg \left(x \leq 3 \cdot 10^{-118}\right) \land x \leq 3.5 \cdot 10^{-84}\right):\\ \;\;\;\;z \cdot \frac{-0.5}{t}\\ \mathbf{else}:\\ \;\;\;\;y \cdot \frac{0.5}{t}\\ \end{array} \]
Alternative 5
Accuracy44.5%
Cost1114
\[\begin{array}{l} \mathbf{if}\;x \leq -4 \cdot 10^{+65}:\\ \;\;\;\;\frac{x}{\frac{t}{0.5}}\\ \mathbf{elif}\;x \leq -5.4 \cdot 10^{-187} \lor \neg \left(x \leq -8.8 \cdot 10^{-214}\right) \land \left(x \leq 1.9 \cdot 10^{-197} \lor \neg \left(x \leq 3.2 \cdot 10^{-121}\right) \land x \leq 7.4 \cdot 10^{-84}\right):\\ \;\;\;\;\frac{z \cdot -0.5}{t}\\ \mathbf{else}:\\ \;\;\;\;\frac{y}{\frac{t}{0.5}}\\ \end{array} \]
Alternative 6
Accuracy44.2%
Cost1113
\[\begin{array}{l} t_1 := y \cdot \frac{0.5}{t}\\ t_2 := \frac{-0.5}{\frac{t}{z}}\\ \mathbf{if}\;x \leq -9 \cdot 10^{+58}:\\ \;\;\;\;x \cdot \frac{0.5}{t}\\ \mathbf{elif}\;x \leq -5.4 \cdot 10^{-187}:\\ \;\;\;\;t_2\\ \mathbf{elif}\;x \leq -3.45 \cdot 10^{-214}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;x \leq 2.3 \cdot 10^{-197}:\\ \;\;\;\;z \cdot \frac{-0.5}{t}\\ \mathbf{elif}\;x \leq 8.5 \cdot 10^{-124} \lor \neg \left(x \leq 1.06 \cdot 10^{-78}\right):\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;t_2\\ \end{array} \]
Alternative 7
Accuracy44.4%
Cost1113
\[\begin{array}{l} t_1 := \frac{z \cdot -0.5}{t}\\ \mathbf{if}\;x \leq -3.5 \cdot 10^{+63}:\\ \;\;\;\;\frac{x}{\frac{t}{0.5}}\\ \mathbf{elif}\;x \leq -5 \cdot 10^{-187}:\\ \;\;\;\;t_1\\ \mathbf{elif}\;x \leq -1.15 \cdot 10^{-214}:\\ \;\;\;\;\frac{-0.5}{\frac{-t}{y}}\\ \mathbf{elif}\;x \leq 1.7 \cdot 10^{-197} \lor \neg \left(x \leq 6.5 \cdot 10^{-125}\right) \land x \leq 3.5 \cdot 10^{-78}:\\ \;\;\;\;t_1\\ \mathbf{else}:\\ \;\;\;\;\frac{y}{\frac{t}{0.5}}\\ \end{array} \]
Alternative 8
Accuracy44.2%
Cost717
\[\begin{array}{l} \mathbf{if}\;y \leq 3.5 \cdot 10^{-90} \lor \neg \left(y \leq 5.1 \cdot 10^{-23}\right) \land y \leq 1.75:\\ \;\;\;\;x \cdot \frac{0.5}{t}\\ \mathbf{else}:\\ \;\;\;\;y \cdot \frac{0.5}{t}\\ \end{array} \]
Alternative 9
Accuracy73.7%
Cost580
\[\begin{array}{l} \mathbf{if}\;x \leq -2.8 \cdot 10^{+104}:\\ \;\;\;\;\frac{x}{\frac{t}{0.5}}\\ \mathbf{else}:\\ \;\;\;\;0.5 \cdot \frac{y - z}{t}\\ \end{array} \]
Alternative 10
Accuracy75.2%
Cost580
\[\begin{array}{l} \mathbf{if}\;y \leq 1.3 \cdot 10^{-89}:\\ \;\;\;\;\frac{-0.5}{t} \cdot \left(z - x\right)\\ \mathbf{else}:\\ \;\;\;\;0.5 \cdot \frac{y - z}{t}\\ \end{array} \]
Alternative 11
Accuracy75.1%
Cost580
\[\begin{array}{l} \mathbf{if}\;y \leq 1.15 \cdot 10^{-89}:\\ \;\;\;\;\frac{-0.5}{\frac{t}{z - x}}\\ \mathbf{else}:\\ \;\;\;\;0.5 \cdot \frac{y - z}{t}\\ \end{array} \]
Alternative 12
Accuracy75.4%
Cost580
\[\begin{array}{l} \mathbf{if}\;y \leq 9 \cdot 10^{-90}:\\ \;\;\;\;\frac{-0.5 \cdot \left(z - x\right)}{t}\\ \mathbf{else}:\\ \;\;\;\;0.5 \cdot \frac{y - z}{t}\\ \end{array} \]
Alternative 13
Accuracy99.6%
Cost576
\[\left(z - \left(x + y\right)\right) \cdot \frac{-0.5}{t} \]
Alternative 14
Accuracy36.3%
Cost320
\[x \cdot \frac{0.5}{t} \]

Error

Reproduce?

herbie shell --seed 2023133 
(FPCore (x y z t)
  :name "Optimisation.CirclePacking:place from circle-packing-0.1.0.4, B"
  :precision binary64
  (/ (- (+ x y) z) (* t 2.0)))