Average Error: 1.3 → 0.3
Time: 16.0s
Precision: binary64
\[\frac{1}{3} \cdot \cos^{-1} \left(\frac{3 \cdot \frac{x}{y \cdot 27}}{z \cdot 2} \cdot \sqrt{t}\right)\]
\[\frac{1}{\sqrt[3]{3} \cdot \sqrt[3]{3}} \cdot \frac{\cos^{-1} \left(\sqrt{t} \cdot \left(\frac{x}{y \cdot z} \cdot 0.05555555555555555\right)\right)}{\sqrt[3]{3}}\]
\frac{1}{3} \cdot \cos^{-1} \left(\frac{3 \cdot \frac{x}{y \cdot 27}}{z \cdot 2} \cdot \sqrt{t}\right)
\frac{1}{\sqrt[3]{3} \cdot \sqrt[3]{3}} \cdot \frac{\cos^{-1} \left(\sqrt{t} \cdot \left(\frac{x}{y \cdot z} \cdot 0.05555555555555555\right)\right)}{\sqrt[3]{3}}
(FPCore (x y z t)
 :precision binary64
 (* (/ 1.0 3.0) (acos (* (/ (* 3.0 (/ x (* y 27.0))) (* z 2.0)) (sqrt t)))))
(FPCore (x y z t)
 :precision binary64
 (*
  (/ 1.0 (* (cbrt 3.0) (cbrt 3.0)))
  (/ (acos (* (sqrt t) (* (/ x (* y z)) 0.05555555555555555))) (cbrt 3.0))))
double code(double x, double y, double z, double t) {
	return (1.0 / 3.0) * acos(((3.0 * (x / (y * 27.0))) / (z * 2.0)) * sqrt(t));
}
double code(double x, double y, double z, double t) {
	return (1.0 / (cbrt(3.0) * cbrt(3.0))) * (acos(sqrt(t) * ((x / (y * z)) * 0.05555555555555555)) / cbrt(3.0));
}

Error

Bits error versus x

Bits error versus y

Bits error versus z

Bits error versus t

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Target

Original1.3
Target1.2
Herbie0.3
\[\frac{\cos^{-1} \left(\frac{\frac{x}{27}}{y \cdot z} \cdot \frac{\sqrt{t}}{\frac{2}{3}}\right)}{3}\]

Derivation

  1. Initial program 1.3

    \[\frac{1}{3} \cdot \cos^{-1} \left(\frac{3 \cdot \frac{x}{y \cdot 27}}{z \cdot 2} \cdot \sqrt{t}\right)\]
  2. Using strategy rm
  3. Applied associate-*l/_binary64_187761.3

    \[\leadsto \frac{1}{3} \cdot \cos^{-1} \color{blue}{\left(\frac{\left(3 \cdot \frac{x}{y \cdot 27}\right) \cdot \sqrt{t}}{z \cdot 2}\right)}\]
  4. Simplified1.3

    \[\leadsto \frac{1}{3} \cdot \cos^{-1} \left(\frac{\color{blue}{\left(0.1111111111111111 \cdot \frac{x}{y}\right) \cdot \sqrt{t}}}{z \cdot 2}\right)\]
  5. Using strategy rm
  6. Applied add-cube-cbrt_binary64_188681.3

    \[\leadsto \frac{1}{\color{blue}{\left(\sqrt[3]{3} \cdot \sqrt[3]{3}\right) \cdot \sqrt[3]{3}}} \cdot \cos^{-1} \left(\frac{\left(0.1111111111111111 \cdot \frac{x}{y}\right) \cdot \sqrt{t}}{z \cdot 2}\right)\]
  7. Applied add-sqr-sqrt_binary64_188551.3

    \[\leadsto \frac{\color{blue}{\sqrt{1} \cdot \sqrt{1}}}{\left(\sqrt[3]{3} \cdot \sqrt[3]{3}\right) \cdot \sqrt[3]{3}} \cdot \cos^{-1} \left(\frac{\left(0.1111111111111111 \cdot \frac{x}{y}\right) \cdot \sqrt{t}}{z \cdot 2}\right)\]
  8. Applied times-frac_binary64_188390.4

    \[\leadsto \color{blue}{\left(\frac{\sqrt{1}}{\sqrt[3]{3} \cdot \sqrt[3]{3}} \cdot \frac{\sqrt{1}}{\sqrt[3]{3}}\right)} \cdot \cos^{-1} \left(\frac{\left(0.1111111111111111 \cdot \frac{x}{y}\right) \cdot \sqrt{t}}{z \cdot 2}\right)\]
  9. Applied associate-*l*_binary64_187740.3

    \[\leadsto \color{blue}{\frac{\sqrt{1}}{\sqrt[3]{3} \cdot \sqrt[3]{3}} \cdot \left(\frac{\sqrt{1}}{\sqrt[3]{3}} \cdot \cos^{-1} \left(\frac{\left(0.1111111111111111 \cdot \frac{x}{y}\right) \cdot \sqrt{t}}{z \cdot 2}\right)\right)}\]
  10. Simplified0.3

    \[\leadsto \frac{\sqrt{1}}{\sqrt[3]{3} \cdot \sqrt[3]{3}} \cdot \color{blue}{\frac{\cos^{-1} \left(\sqrt{t} \cdot \left(\frac{x}{y \cdot z} \cdot 0.05555555555555555\right)\right)}{\sqrt[3]{3}}}\]
  11. Final simplification0.3

    \[\leadsto \frac{1}{\sqrt[3]{3} \cdot \sqrt[3]{3}} \cdot \frac{\cos^{-1} \left(\sqrt{t} \cdot \left(\frac{x}{y \cdot z} \cdot 0.05555555555555555\right)\right)}{\sqrt[3]{3}}\]

Reproduce

herbie shell --seed 2021007 
(FPCore (x y z t)
  :name "Diagrams.Solve.Polynomial:cubForm  from diagrams-solve-0.1, D"
  :precision binary64

  :herbie-target
  (/ (acos (* (/ (/ x 27.0) (* y z)) (/ (sqrt t) (/ 2.0 3.0)))) 3.0)

  (* (/ 1.0 3.0) (acos (* (/ (* 3.0 (/ x (* y 27.0))) (* z 2.0)) (sqrt t)))))