Math FPCore C Fortran Java Python Julia MATLAB Wolfram TeX \[x + \left(\left(y - x\right) \cdot 6\right) \cdot \left(\frac{2}{3} - z\right)
\]
↓
\[\left(y - x\right) \cdot \left(z \cdot -6\right) + \left(x + \left(y - x\right) \cdot 4\right)
\]
(FPCore (x y z)
:precision binary64
(+ x (* (* (- y x) 6.0) (- (/ 2.0 3.0) z)))) ↓
(FPCore (x y z)
:precision binary64
(+ (* (- y x) (* z -6.0)) (+ x (* (- y x) 4.0)))) double code(double x, double y, double z) {
return x + (((y - x) * 6.0) * ((2.0 / 3.0) - z));
}
↓
double code(double x, double y, double z) {
return ((y - x) * (z * -6.0)) + (x + ((y - x) * 4.0));
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = x + (((y - x) * 6.0d0) * ((2.0d0 / 3.0d0) - z))
end function
↓
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = ((y - x) * (z * (-6.0d0))) + (x + ((y - x) * 4.0d0))
end function
public static double code(double x, double y, double z) {
return x + (((y - x) * 6.0) * ((2.0 / 3.0) - z));
}
↓
public static double code(double x, double y, double z) {
return ((y - x) * (z * -6.0)) + (x + ((y - x) * 4.0));
}
def code(x, y, z):
return x + (((y - x) * 6.0) * ((2.0 / 3.0) - z))
↓
def code(x, y, z):
return ((y - x) * (z * -6.0)) + (x + ((y - x) * 4.0))
function code(x, y, z)
return Float64(x + Float64(Float64(Float64(y - x) * 6.0) * Float64(Float64(2.0 / 3.0) - z)))
end
↓
function code(x, y, z)
return Float64(Float64(Float64(y - x) * Float64(z * -6.0)) + Float64(x + Float64(Float64(y - x) * 4.0)))
end
function tmp = code(x, y, z)
tmp = x + (((y - x) * 6.0) * ((2.0 / 3.0) - z));
end
↓
function tmp = code(x, y, z)
tmp = ((y - x) * (z * -6.0)) + (x + ((y - x) * 4.0));
end
code[x_, y_, z_] := N[(x + N[(N[(N[(y - x), $MachinePrecision] * 6.0), $MachinePrecision] * N[(N[(2.0 / 3.0), $MachinePrecision] - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
↓
code[x_, y_, z_] := N[(N[(N[(y - x), $MachinePrecision] * N[(z * -6.0), $MachinePrecision]), $MachinePrecision] + N[(x + N[(N[(y - x), $MachinePrecision] * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
x + \left(\left(y - x\right) \cdot 6\right) \cdot \left(\frac{2}{3} - z\right)
↓
\left(y - x\right) \cdot \left(z \cdot -6\right) + \left(x + \left(y - x\right) \cdot 4\right)
Alternatives Alternative 1 Error 21.4 Cost 1108
\[\begin{array}{l}
t_0 := -6 \cdot \left(\left(y - x\right) \cdot z\right)\\
\mathbf{if}\;z \leq -4800000:\\
\;\;\;\;t_0\\
\mathbf{elif}\;z \leq -2.35 \cdot 10^{-33}:\\
\;\;\;\;6 \cdot \left(y \cdot \left(0.6666666666666666 - z\right)\right)\\
\mathbf{elif}\;z \leq -8.5 \cdot 10^{-133}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 1.75 \cdot 10^{-158}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 0.5:\\
\;\;\;\;x \cdot -3\\
\mathbf{else}:\\
\;\;\;\;t_0\\
\end{array}
\]
Alternative 2 Error 32.8 Cost 980
\[\begin{array}{l}
t_0 := 6 \cdot \left(x \cdot z\right)\\
\mathbf{if}\;z \leq -7 \cdot 10^{+64}:\\
\;\;\;\;-6 \cdot \left(y \cdot z\right)\\
\mathbf{elif}\;z \leq -0.072:\\
\;\;\;\;t_0\\
\mathbf{elif}\;z \leq -2.15 \cdot 10^{-134}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 7 \cdot 10^{-158}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 1.3 \cdot 10^{-10}:\\
\;\;\;\;x \cdot -3\\
\mathbf{else}:\\
\;\;\;\;t_0\\
\end{array}
\]
Alternative 3 Error 32.8 Cost 980
\[\begin{array}{l}
\mathbf{if}\;z \leq -6.7 \cdot 10^{+64}:\\
\;\;\;\;-6 \cdot \left(y \cdot z\right)\\
\mathbf{elif}\;z \leq -0.072:\\
\;\;\;\;6 \cdot \left(x \cdot z\right)\\
\mathbf{elif}\;z \leq -1.25 \cdot 10^{-135}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 4.8 \cdot 10^{-156}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 1.3 \cdot 10^{-10}:\\
\;\;\;\;x \cdot -3\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(z \cdot 6\right)\\
\end{array}
\]
Alternative 4 Error 21.7 Cost 976
\[\begin{array}{l}
t_0 := -6 \cdot \left(\left(y - x\right) \cdot z\right)\\
\mathbf{if}\;z \leq -2.2 \cdot 10^{-17}:\\
\;\;\;\;t_0\\
\mathbf{elif}\;z \leq -2.6 \cdot 10^{-132}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 1.22 \cdot 10^{-157}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 0.5:\\
\;\;\;\;x \cdot -3\\
\mathbf{else}:\\
\;\;\;\;t_0\\
\end{array}
\]
Alternative 5 Error 33.1 Cost 848
\[\begin{array}{l}
t_0 := -6 \cdot \left(y \cdot z\right)\\
\mathbf{if}\;z \leq -2.2 \cdot 10^{-17}:\\
\;\;\;\;t_0\\
\mathbf{elif}\;z \leq -3.6 \cdot 10^{-133}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 2.25 \cdot 10^{-156}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 0.65:\\
\;\;\;\;x \cdot -3\\
\mathbf{else}:\\
\;\;\;\;t_0\\
\end{array}
\]
Alternative 6 Error 33.7 Cost 721
\[\begin{array}{l}
\mathbf{if}\;x \leq -1.4 \cdot 10^{+94}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;x \leq -2.15 \cdot 10^{+69} \lor \neg \left(x \leq -5 \cdot 10^{-30}\right) \land x \leq 2.5 \cdot 10^{-5}:\\
\;\;\;\;y \cdot 4\\
\mathbf{else}:\\
\;\;\;\;x \cdot -3\\
\end{array}
\]
Alternative 7 Error 17.0 Cost 713
\[\begin{array}{l}
\mathbf{if}\;x \leq -4.9 \cdot 10^{-26} \lor \neg \left(x \leq 0.8\right):\\
\;\;\;\;x \cdot \left(-3 + z \cdot 6\right)\\
\mathbf{else}:\\
\;\;\;\;6 \cdot \left(y \cdot \left(0.6666666666666666 - z\right)\right)\\
\end{array}
\]
Alternative 8 Error 1.8 Cost 712
\[\begin{array}{l}
\mathbf{if}\;z \leq -0.6:\\
\;\;\;\;\left(y - x\right) \cdot \left(z \cdot -6\right)\\
\mathbf{elif}\;z \leq 0.6:\\
\;\;\;\;x + \left(y - x\right) \cdot 4\\
\mathbf{else}:\\
\;\;\;\;z \cdot \left(\left(y - x\right) \cdot -6\right)\\
\end{array}
\]
Alternative 9 Error 0.4 Cost 704
\[x + \left(0.6666666666666666 - z\right) \cdot \left(\left(y - x\right) \cdot 6\right)
\]
Alternative 10 Error 0.3 Cost 704
\[x + \frac{0.6666666666666666 - z}{\frac{0.16666666666666666}{y - x}}
\]
Alternative 11 Error 43.1 Cost 192
\[y \cdot 4
\]