Average Error: 0.0 → 0.0
Time: 1.1s
Precision: binary64
\[x \cdot y - x\]
\[x \cdot \left(\sqrt[3]{-1} \cdot \left(1 - y\right)\right)\]
x \cdot y - x
x \cdot \left(\sqrt[3]{-1} \cdot \left(1 - y\right)\right)
(FPCore (x y) :precision binary64 (- (* x y) x))
(FPCore (x y) :precision binary64 (* x (* (cbrt -1.0) (- 1.0 y))))
double code(double x, double y) {
	return (x * y) - x;
}
double code(double x, double y) {
	return x * (cbrt(-1.0) * (1.0 - y));
}

Error

Bits error versus x

Bits error versus y

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0.0

    \[x \cdot y - x\]
  2. Using strategy rm
  3. Applied add-cbrt-cube_binary6439.8

    \[\leadsto \color{blue}{\sqrt[3]{\left(\left(x \cdot y - x\right) \cdot \left(x \cdot y - x\right)\right) \cdot \left(x \cdot y - x\right)}}\]
  4. Simplified39.8

    \[\leadsto \sqrt[3]{\color{blue}{{\left(x \cdot \left(y - 1\right)\right)}^{3}}}\]
  5. Taylor expanded around -inf 0.0

    \[\leadsto \color{blue}{-1 \cdot \left(x \cdot \left(\sqrt[3]{-1} \cdot \left(y - 1\right)\right)\right)}\]
  6. Final simplification0.0

    \[\leadsto x \cdot \left(\sqrt[3]{-1} \cdot \left(1 - y\right)\right)\]

Alternatives

Reproduce

herbie shell --seed 2021118 
(FPCore (x y)
  :name "Data.Histogram.Bin.LogBinD:$cbinSizeN from histogram-fill-0.8.4.1"
  :precision binary64
  (- (* x y) x))