Average Error: 19.1 → 15.1
Time: 20.9s
Precision: 64
Internal precision: 128
\[c0 \cdot \sqrt{\frac{A}{V \cdot \ell}}\]
\[\begin{array}{l} \mathbf{if}\;V \le 1.0800478838409164 \cdot 10^{-294}:\\ \;\;\;\;\sqrt{\frac{\frac{A}{\ell}}{V}} \cdot c0\\ \mathbf{else}:\\ \;\;\;\;\frac{\sqrt{\frac{A}{\ell}}}{\sqrt{V}} \cdot c0\\ \end{array}\]

Error

Bits error versus c0

Bits error versus A

Bits error versus V

Bits error versus l

Derivation

  1. Split input into 2 regimes.
  2. if V < 1.0800478838409164e-294

    1. Initial program 19.3

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

      \[\leadsto c0 \cdot \color{blue}{{\left(\sqrt{\sqrt{\frac{A}{V \cdot \ell}}}\right)}^2}\]
    4. Applied taylor 19.5

      \[\leadsto c0 \cdot {\left(\sqrt{\sqrt{\frac{A}{\ell \cdot V}}}\right)}^2\]
    5. Taylor expanded around 0 19.5

      \[\leadsto c0 \cdot {\left(\sqrt{\sqrt{\color{blue}{\frac{A}{\ell \cdot V}}}}\right)}^2\]
    6. Applied simplify 19.1

      \[\leadsto \color{blue}{\sqrt{\frac{\frac{A}{\ell}}{V}} \cdot c0}\]

    if 1.0800478838409164e-294 < V

    1. Initial program 18.9

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

      \[\leadsto c0 \cdot \color{blue}{{\left(\sqrt{\sqrt{\frac{A}{V \cdot \ell}}}\right)}^2}\]
    4. Applied taylor 19.1

      \[\leadsto c0 \cdot {\left(\sqrt{\sqrt{\frac{A}{\ell \cdot V}}}\right)}^2\]
    5. Taylor expanded around 0 19.1

      \[\leadsto c0 \cdot {\left(\sqrt{\sqrt{\color{blue}{\frac{A}{\ell \cdot V}}}}\right)}^2\]
    6. Applied simplify 18.3

      \[\leadsto \color{blue}{\sqrt{\frac{\frac{A}{\ell}}{V}} \cdot c0}\]
    7. Using strategy rm
    8. Applied sqrt-div 10.9

      \[\leadsto \color{blue}{\frac{\sqrt{\frac{A}{\ell}}}{\sqrt{V}}} \cdot c0\]
  3. Recombined 2 regimes into one program.
  4. Removed slow pow expressions

Runtime

Time bar (total: 20.9s) Debug log

Please include this information when filing a bug report:

herbie --seed '#(2472078766 2254188213 3344067926 3806046757 1024838006 471693918)'
(FPCore (c0 A V l)
  :name "Henrywood and Agarwal, Equation (3)"
  (* c0 (sqrt (/ A (* V l)))))