Average Error: 20.0 → 2.3
Time: 11.2s
Precision: binary64
\[[V, l] = \mathsf{sort}([V, l]) \\]
\[c0 \cdot \sqrt{\frac{A}{V \cdot \ell}} \]
\[\begin{array}{l} t_0 := \frac{\frac{\sqrt[3]{A}}{\sqrt[3]{V}}}{\sqrt[3]{\ell}}\\ t_1 := \sqrt{\sqrt{t_0}}\\ c0 \cdot \left(t_1 \cdot \left(t_0 \cdot t_1\right)\right) \end{array} \]
c0 \cdot \sqrt{\frac{A}{V \cdot \ell}}
\begin{array}{l}
t_0 := \frac{\frac{\sqrt[3]{A}}{\sqrt[3]{V}}}{\sqrt[3]{\ell}}\\
t_1 := \sqrt{\sqrt{t_0}}\\
c0 \cdot \left(t_1 \cdot \left(t_0 \cdot t_1\right)\right)
\end{array}
(FPCore (c0 A V l) :precision binary64 (* c0 (sqrt (/ A (* V l)))))
(FPCore (c0 A V l)
 :precision binary64
 (let* ((t_0 (/ (/ (cbrt A) (cbrt V)) (cbrt l))) (t_1 (sqrt (sqrt t_0))))
   (* c0 (* t_1 (* t_0 t_1)))))
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) {
	double t_0 = (cbrt(A) / cbrt(V)) / cbrt(l);
	double t_1 = sqrt(sqrt(t_0));
	return c0 * (t_1 * (t_0 * t_1));
}

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 20.0

    \[c0 \cdot \sqrt{\frac{A}{V \cdot \ell}} \]
  2. Applied associate-/r*_binary6419.9

    \[\leadsto c0 \cdot \sqrt{\color{blue}{\frac{\frac{A}{V}}{\ell}}} \]
  3. Applied add-cube-cbrt_binary6420.2

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

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

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

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

    \[\leadsto c0 \cdot \sqrt{\color{blue}{\frac{\frac{\sqrt[3]{A} \cdot \sqrt[3]{A}}{\sqrt[3]{V} \cdot \sqrt[3]{V}}}{\sqrt[3]{\ell} \cdot \sqrt[3]{\ell}} \cdot \frac{\frac{\sqrt[3]{A}}{\sqrt[3]{V}}}{\sqrt[3]{\ell}}}} \]
  8. Applied sqrt-prod_binary647.7

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

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

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

    \[\leadsto c0 \cdot \color{blue}{\left(\left(\left|\frac{\frac{\sqrt[3]{A}}{\sqrt[3]{V}}}{\sqrt[3]{\ell}}\right| \cdot \sqrt{\sqrt{\frac{\frac{\sqrt[3]{A}}{\sqrt[3]{V}}}{\sqrt[3]{\ell}}}}\right) \cdot \sqrt{\sqrt{\frac{\frac{\sqrt[3]{A}}{\sqrt[3]{V}}}{\sqrt[3]{\ell}}}}\right)} \]
  12. Simplified2.3

    \[\leadsto c0 \cdot \left(\color{blue}{\left(\frac{\frac{\sqrt[3]{A}}{\sqrt[3]{V}}}{\sqrt[3]{\ell}} \cdot \sqrt{\sqrt{\frac{\frac{\sqrt[3]{A}}{\sqrt[3]{V}}}{\sqrt[3]{\ell}}}}\right)} \cdot \sqrt{\sqrt{\frac{\frac{\sqrt[3]{A}}{\sqrt[3]{V}}}{\sqrt[3]{\ell}}}}\right) \]
  13. Final simplification2.3

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

Reproduce

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