Average Error: 0.0 → 0.0
Time: 4.3s
Precision: binary64
\[x - y \cdot y\]
\[\frac{x + {y}^{2}}{\frac{x + y \cdot y}{x - {y}^{2}}}\]
x - y \cdot y
\frac{x + {y}^{2}}{\frac{x + y \cdot y}{x - {y}^{2}}}
(FPCore (x y) :precision binary64 (- x (* y y)))
(FPCore (x y)
 :precision binary64
 (/ (+ x (pow y 2.0)) (/ (+ x (* y y)) (- x (pow y 2.0)))))
double code(double x, double y) {
	return x - (y * y);
}
double code(double x, double y) {
	return (x + pow(y, 2.0)) / ((x + (y * y)) / (x - pow(y, 2.0)));
}

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 - y \cdot y\]
  2. Using strategy rm
  3. Applied flip--_binary64_346330.4

    \[\leadsto \color{blue}{\frac{x \cdot x - \left(y \cdot y\right) \cdot \left(y \cdot y\right)}{x + y \cdot y}}\]
  4. Simplified30.5

    \[\leadsto \frac{\color{blue}{x \cdot x - {y}^{4}}}{x + y \cdot y}\]
  5. Simplified30.5

    \[\leadsto \frac{x \cdot x - {y}^{4}}{\color{blue}{y \cdot y + x}}\]
  6. Using strategy rm
  7. Applied sqr-pow_binary64_346030.4

    \[\leadsto \frac{x \cdot x - \color{blue}{{y}^{\left(\frac{4}{2}\right)} \cdot {y}^{\left(\frac{4}{2}\right)}}}{y \cdot y + x}\]
  8. Applied difference-of-squares_binary64_345730.4

    \[\leadsto \frac{\color{blue}{\left(x + {y}^{\left(\frac{4}{2}\right)}\right) \cdot \left(x - {y}^{\left(\frac{4}{2}\right)}\right)}}{y \cdot y + x}\]
  9. Applied associate-/l*_binary64_34330.0

    \[\leadsto \color{blue}{\frac{x + {y}^{\left(\frac{4}{2}\right)}}{\frac{y \cdot y + x}{x - {y}^{\left(\frac{4}{2}\right)}}}}\]
  10. Final simplification0.0

    \[\leadsto \frac{x + {y}^{2}}{\frac{x + y \cdot y}{x - {y}^{2}}}\]

Reproduce

herbie shell --seed 2021027 
(FPCore (x y)
  :name "Graphics.Rasterific.Shading:$sradialGradientWithFocusShader from Rasterific-0.6.1"
  :precision binary64
  (- x (* y y)))