Average Error: 1.4 → 0.5
Time: 4.4s
Precision: 64
\[\left|\frac{x + 4}{y} - \frac{x}{y} \cdot z\right|\]
\[\left|\frac{x + 4}{y} - \left(1 \cdot \left|\frac{\sqrt[3]{x}}{\sqrt[3]{y}}\right|\right) \cdot \left(\left(\left|\frac{\sqrt[3]{x}}{\sqrt[3]{y}}\right| \cdot z\right) \cdot \frac{\sqrt[3]{x}}{\sqrt[3]{y}}\right)\right|\]
\left|\frac{x + 4}{y} - \frac{x}{y} \cdot z\right|
\left|\frac{x + 4}{y} - \left(1 \cdot \left|\frac{\sqrt[3]{x}}{\sqrt[3]{y}}\right|\right) \cdot \left(\left(\left|\frac{\sqrt[3]{x}}{\sqrt[3]{y}}\right| \cdot z\right) \cdot \frac{\sqrt[3]{x}}{\sqrt[3]{y}}\right)\right|
double code(double x, double y, double z) {
	return fabs((((x + 4.0) / y) - ((x / y) * z)));
}
double code(double x, double y, double z) {
	return fabs((((x + 4.0) / y) - ((1.0 * fabs((cbrt(x) / cbrt(y)))) * ((fabs((cbrt(x) / cbrt(y))) * z) * (cbrt(x) / cbrt(y))))));
}

Error

Bits error versus x

Bits error versus y

Bits error versus z

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 1.4

    \[\left|\frac{x + 4}{y} - \frac{x}{y} \cdot z\right|\]
  2. Using strategy rm
  3. Applied add-cube-cbrt1.7

    \[\leadsto \left|\frac{x + 4}{y} - \frac{x}{\color{blue}{\left(\sqrt[3]{y} \cdot \sqrt[3]{y}\right) \cdot \sqrt[3]{y}}} \cdot z\right|\]
  4. Applied add-cube-cbrt1.8

    \[\leadsto \left|\frac{x + 4}{y} - \frac{\color{blue}{\left(\sqrt[3]{x} \cdot \sqrt[3]{x}\right) \cdot \sqrt[3]{x}}}{\left(\sqrt[3]{y} \cdot \sqrt[3]{y}\right) \cdot \sqrt[3]{y}} \cdot z\right|\]
  5. Applied times-frac1.8

    \[\leadsto \left|\frac{x + 4}{y} - \color{blue}{\left(\frac{\sqrt[3]{x} \cdot \sqrt[3]{x}}{\sqrt[3]{y} \cdot \sqrt[3]{y}} \cdot \frac{\sqrt[3]{x}}{\sqrt[3]{y}}\right)} \cdot z\right|\]
  6. Applied associate-*l*0.6

    \[\leadsto \left|\frac{x + 4}{y} - \color{blue}{\frac{\sqrt[3]{x} \cdot \sqrt[3]{x}}{\sqrt[3]{y} \cdot \sqrt[3]{y}} \cdot \left(\frac{\sqrt[3]{x}}{\sqrt[3]{y}} \cdot z\right)}\right|\]
  7. Using strategy rm
  8. Applied add-sqr-sqrt0.6

    \[\leadsto \left|\frac{x + 4}{y} - \color{blue}{\left(\sqrt{\frac{\sqrt[3]{x} \cdot \sqrt[3]{x}}{\sqrt[3]{y} \cdot \sqrt[3]{y}}} \cdot \sqrt{\frac{\sqrt[3]{x} \cdot \sqrt[3]{x}}{\sqrt[3]{y} \cdot \sqrt[3]{y}}}\right)} \cdot \left(\frac{\sqrt[3]{x}}{\sqrt[3]{y}} \cdot z\right)\right|\]
  9. Applied associate-*l*0.6

    \[\leadsto \left|\frac{x + 4}{y} - \color{blue}{\sqrt{\frac{\sqrt[3]{x} \cdot \sqrt[3]{x}}{\sqrt[3]{y} \cdot \sqrt[3]{y}}} \cdot \left(\sqrt{\frac{\sqrt[3]{x} \cdot \sqrt[3]{x}}{\sqrt[3]{y} \cdot \sqrt[3]{y}}} \cdot \left(\frac{\sqrt[3]{x}}{\sqrt[3]{y}} \cdot z\right)\right)}\right|\]
  10. Simplified0.6

    \[\leadsto \left|\frac{x + 4}{y} - \sqrt{\frac{\sqrt[3]{x} \cdot \sqrt[3]{x}}{\sqrt[3]{y} \cdot \sqrt[3]{y}}} \cdot \color{blue}{\left(\left(\left|\frac{\sqrt[3]{x}}{\sqrt[3]{y}}\right| \cdot z\right) \cdot \frac{\sqrt[3]{x}}{\sqrt[3]{y}}\right)}\right|\]
  11. Using strategy rm
  12. Applied *-un-lft-identity0.6

    \[\leadsto \left|\frac{x + 4}{y} - \sqrt{\color{blue}{1 \cdot \frac{\sqrt[3]{x} \cdot \sqrt[3]{x}}{\sqrt[3]{y} \cdot \sqrt[3]{y}}}} \cdot \left(\left(\left|\frac{\sqrt[3]{x}}{\sqrt[3]{y}}\right| \cdot z\right) \cdot \frac{\sqrt[3]{x}}{\sqrt[3]{y}}\right)\right|\]
  13. Applied sqrt-prod0.6

    \[\leadsto \left|\frac{x + 4}{y} - \color{blue}{\left(\sqrt{1} \cdot \sqrt{\frac{\sqrt[3]{x} \cdot \sqrt[3]{x}}{\sqrt[3]{y} \cdot \sqrt[3]{y}}}\right)} \cdot \left(\left(\left|\frac{\sqrt[3]{x}}{\sqrt[3]{y}}\right| \cdot z\right) \cdot \frac{\sqrt[3]{x}}{\sqrt[3]{y}}\right)\right|\]
  14. Simplified0.6

    \[\leadsto \left|\frac{x + 4}{y} - \left(\color{blue}{1} \cdot \sqrt{\frac{\sqrt[3]{x} \cdot \sqrt[3]{x}}{\sqrt[3]{y} \cdot \sqrt[3]{y}}}\right) \cdot \left(\left(\left|\frac{\sqrt[3]{x}}{\sqrt[3]{y}}\right| \cdot z\right) \cdot \frac{\sqrt[3]{x}}{\sqrt[3]{y}}\right)\right|\]
  15. Simplified0.5

    \[\leadsto \left|\frac{x + 4}{y} - \left(1 \cdot \color{blue}{\left|\frac{\sqrt[3]{x}}{\sqrt[3]{y}}\right|}\right) \cdot \left(\left(\left|\frac{\sqrt[3]{x}}{\sqrt[3]{y}}\right| \cdot z\right) \cdot \frac{\sqrt[3]{x}}{\sqrt[3]{y}}\right)\right|\]
  16. Final simplification0.5

    \[\leadsto \left|\frac{x + 4}{y} - \left(1 \cdot \left|\frac{\sqrt[3]{x}}{\sqrt[3]{y}}\right|\right) \cdot \left(\left(\left|\frac{\sqrt[3]{x}}{\sqrt[3]{y}}\right| \cdot z\right) \cdot \frac{\sqrt[3]{x}}{\sqrt[3]{y}}\right)\right|\]

Reproduce

herbie shell --seed 2020066 
(FPCore (x y z)
  :name "fabs fraction 1"
  :precision binary64
  (fabs (- (/ (+ x 4) y) (* (/ x y) z))))