Average Error: 18.8 → 13.0
Time: 22.9s
Precision: 64
Internal Precision: 128
\[c0 \cdot \sqrt{\frac{A}{V \cdot \ell}}\]
\[\begin{array}{l} \mathbf{if}\;V \cdot \ell \le -5.044277330985663 \cdot 10^{-164}:\\ \;\;\;\;c0 \cdot \sqrt{A \cdot \frac{1}{V \cdot \ell}}\\ \mathbf{elif}\;V \cdot \ell \le 3.2948560408933 \cdot 10^{-315}:\\ \;\;\;\;\sqrt{\frac{\frac{A}{V}}{\ell}} \cdot c0\\ \mathbf{else}:\\ \;\;\;\;c0 \cdot \frac{\sqrt{A}}{\sqrt{V \cdot \ell}}\\ \end{array}\]

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. Split input into 3 regimes
  2. if (* V l) < -5.044277330985663e-164

    1. Initial program 14.3

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

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

    if -5.044277330985663e-164 < (* V l) < 3.2948560408933e-315

    1. Initial program 42.0

      \[c0 \cdot \sqrt{\frac{A}{V \cdot \ell}}\]
    2. Using strategy rm
    3. Applied associate-/r*28.5

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

    if 3.2948560408933e-315 < (* V l)

    1. Initial program 14.6

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

      \[\leadsto c0 \cdot \color{blue}{\frac{\sqrt{A}}{\sqrt{V \cdot \ell}}}\]
  3. Recombined 3 regimes into one program.
  4. Final simplification13.0

    \[\leadsto \begin{array}{l} \mathbf{if}\;V \cdot \ell \le -5.044277330985663 \cdot 10^{-164}:\\ \;\;\;\;c0 \cdot \sqrt{A \cdot \frac{1}{V \cdot \ell}}\\ \mathbf{elif}\;V \cdot \ell \le 3.2948560408933 \cdot 10^{-315}:\\ \;\;\;\;\sqrt{\frac{\frac{A}{V}}{\ell}} \cdot c0\\ \mathbf{else}:\\ \;\;\;\;c0 \cdot \frac{\sqrt{A}}{\sqrt{V \cdot \ell}}\\ \end{array}\]

Runtime

Time bar (total: 22.9s)Debug logProfile

herbie shell --seed 2018273 +o rules:numerics
(FPCore (c0 A V l)
  :name "Henrywood and Agarwal, Equation (3)"
  (* c0 (sqrt (/ A (* V l)))))