Average Error: 19.7 → 1.2
Time: 10.9s
Precision: binary64
\[[V, l]=\mathsf{sort}([V, l])\]
\[c0 \cdot \sqrt{\frac{A}{V \cdot \ell}}\]
\[\left(c0 \cdot \left|\frac{\frac{\sqrt[3]{A}}{\sqrt[3]{\ell}}}{\sqrt[3]{V}}\right|\right) \cdot \sqrt{\frac{\frac{\sqrt[3]{A}}{\sqrt[3]{\ell}}}{\sqrt[3]{V}}}\]
c0 \cdot \sqrt{\frac{A}{V \cdot \ell}}
\left(c0 \cdot \left|\frac{\frac{\sqrt[3]{A}}{\sqrt[3]{\ell}}}{\sqrt[3]{V}}\right|\right) \cdot \sqrt{\frac{\frac{\sqrt[3]{A}}{\sqrt[3]{\ell}}}{\sqrt[3]{V}}}
(FPCore (c0 A V l) :precision binary64 (* c0 (sqrt (/ A (* V l)))))
(FPCore (c0 A V l)
 :precision binary64
 (*
  (* c0 (fabs (/ (/ (cbrt A) (cbrt l)) (cbrt V))))
  (sqrt (/ (/ (cbrt A) (cbrt l)) (cbrt V)))))
double code(double c0, double A, double V, double l) {
	return c0 * sqrt(A / (V * l));
}
double code(double c0, double A, double V, double l) {
	return (c0 * fabs((cbrt(A) / cbrt(l)) / cbrt(V))) * sqrt((cbrt(A) / cbrt(l)) / cbrt(V));
}

Error

Bits error versus c0

Bits error versus A

Bits error versus V

Bits error versus l

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 19.7

    \[c0 \cdot \sqrt{\frac{A}{V \cdot \ell}}\]
  2. Using strategy rm
  3. Applied add-cube-cbrt_binary64_113620.0

    \[\leadsto c0 \cdot \sqrt{\frac{\color{blue}{\left(\sqrt[3]{A} \cdot \sqrt[3]{A}\right) \cdot \sqrt[3]{A}}}{V \cdot \ell}}\]
  4. Applied times-frac_binary64_110718.6

    \[\leadsto c0 \cdot \sqrt{\color{blue}{\frac{\sqrt[3]{A} \cdot \sqrt[3]{A}}{V} \cdot \frac{\sqrt[3]{A}}{\ell}}}\]
  5. Using strategy rm
  6. Applied associate-*l/_binary64_104420.0

    \[\leadsto c0 \cdot \sqrt{\color{blue}{\frac{\left(\sqrt[3]{A} \cdot \sqrt[3]{A}\right) \cdot \frac{\sqrt[3]{A}}{\ell}}{V}}}\]
  7. Simplified19.6

    \[\leadsto c0 \cdot \sqrt{\frac{\color{blue}{\frac{A}{\ell}}}{V}}\]
  8. Using strategy rm
  9. Applied add-cube-cbrt_binary64_113620.0

    \[\leadsto c0 \cdot \sqrt{\frac{\frac{A}{\ell}}{\color{blue}{\left(\sqrt[3]{V} \cdot \sqrt[3]{V}\right) \cdot \sqrt[3]{V}}}}\]
  10. Applied add-cube-cbrt_binary64_113620.1

    \[\leadsto c0 \cdot \sqrt{\frac{\frac{A}{\color{blue}{\left(\sqrt[3]{\ell} \cdot \sqrt[3]{\ell}\right) \cdot \sqrt[3]{\ell}}}}{\left(\sqrt[3]{V} \cdot \sqrt[3]{V}\right) \cdot \sqrt[3]{V}}}\]
  11. Applied add-cube-cbrt_binary64_113620.2

    \[\leadsto c0 \cdot \sqrt{\frac{\frac{\color{blue}{\left(\sqrt[3]{A} \cdot \sqrt[3]{A}\right) \cdot \sqrt[3]{A}}}{\left(\sqrt[3]{\ell} \cdot \sqrt[3]{\ell}\right) \cdot \sqrt[3]{\ell}}}{\left(\sqrt[3]{V} \cdot \sqrt[3]{V}\right) \cdot \sqrt[3]{V}}}\]
  12. Applied times-frac_binary64_110720.2

    \[\leadsto c0 \cdot \sqrt{\frac{\color{blue}{\frac{\sqrt[3]{A} \cdot \sqrt[3]{A}}{\sqrt[3]{\ell} \cdot \sqrt[3]{\ell}} \cdot \frac{\sqrt[3]{A}}{\sqrt[3]{\ell}}}}{\left(\sqrt[3]{V} \cdot \sqrt[3]{V}\right) \cdot \sqrt[3]{V}}}\]
  13. Applied times-frac_binary64_110715.9

    \[\leadsto c0 \cdot \sqrt{\color{blue}{\frac{\frac{\sqrt[3]{A} \cdot \sqrt[3]{A}}{\sqrt[3]{\ell} \cdot \sqrt[3]{\ell}}}{\sqrt[3]{V} \cdot \sqrt[3]{V}} \cdot \frac{\frac{\sqrt[3]{A}}{\sqrt[3]{\ell}}}{\sqrt[3]{V}}}}\]
  14. Applied sqrt-prod_binary64_11177.1

    \[\leadsto c0 \cdot \color{blue}{\left(\sqrt{\frac{\frac{\sqrt[3]{A} \cdot \sqrt[3]{A}}{\sqrt[3]{\ell} \cdot \sqrt[3]{\ell}}}{\sqrt[3]{V} \cdot \sqrt[3]{V}}} \cdot \sqrt{\frac{\frac{\sqrt[3]{A}}{\sqrt[3]{\ell}}}{\sqrt[3]{V}}}\right)}\]
  15. Applied associate-*r*_binary64_10417.1

    \[\leadsto \color{blue}{\left(c0 \cdot \sqrt{\frac{\frac{\sqrt[3]{A} \cdot \sqrt[3]{A}}{\sqrt[3]{\ell} \cdot \sqrt[3]{\ell}}}{\sqrt[3]{V} \cdot \sqrt[3]{V}}}\right) \cdot \sqrt{\frac{\frac{\sqrt[3]{A}}{\sqrt[3]{\ell}}}{\sqrt[3]{V}}}}\]
  16. Simplified1.2

    \[\leadsto \color{blue}{\left(c0 \cdot \left|\frac{\frac{\sqrt[3]{A}}{\sqrt[3]{\ell}}}{\sqrt[3]{V}}\right|\right)} \cdot \sqrt{\frac{\frac{\sqrt[3]{A}}{\sqrt[3]{\ell}}}{\sqrt[3]{V}}}\]
  17. Final simplification1.2

    \[\leadsto \left(c0 \cdot \left|\frac{\frac{\sqrt[3]{A}}{\sqrt[3]{\ell}}}{\sqrt[3]{V}}\right|\right) \cdot \sqrt{\frac{\frac{\sqrt[3]{A}}{\sqrt[3]{\ell}}}{\sqrt[3]{V}}}\]

Reproduce

herbie shell --seed 2021027 
(FPCore (c0 A V l)
  :name "Henrywood and Agarwal, Equation (3)"
  :precision binary64
  (* c0 (sqrt (/ A (* V l)))))