Average Error: 18.8 → 14.7
Time: 12.4s
Precision: 64
Internal Precision: 576
\[c0 \cdot \sqrt{\frac{A}{V \cdot \ell}}\]
\[\begin{array}{l} \mathbf{if}\;c0 \cdot \sqrt{\frac{A}{V \cdot \ell}} = -\infty:\\ \;\;\;\;\frac{c0}{\sqrt{\frac{\ell}{A}} \cdot \sqrt{V}}\\ \mathbf{elif}\;c0 \cdot \sqrt{\frac{A}{V \cdot \ell}} \le -3.5741155635815926 \cdot 10^{-132}:\\ \;\;\;\;c0 \cdot \sqrt{\frac{A}{V \cdot \ell}}\\ \mathbf{elif}\;c0 \cdot \sqrt{\frac{A}{V \cdot \ell}} \le 0.0:\\ \;\;\;\;\frac{c0}{\sqrt{\frac{\ell}{\frac{A}{V}}}}\\ \mathbf{elif}\;c0 \cdot \sqrt{\frac{A}{V \cdot \ell}} \le 4.4289409362059765 \cdot 10^{+217}:\\ \;\;\;\;c0 \cdot \sqrt{\frac{A}{V \cdot \ell}}\\ \mathbf{else}:\\ \;\;\;\;\frac{c0}{\sqrt{V \cdot \frac{\ell}{A}}}\\ \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 4 regimes
  2. if (* c0 (sqrt (/ A (* V l)))) < -inf.0

    1. Initial program 61.0

      \[c0 \cdot \sqrt{\frac{A}{V \cdot \ell}}\]
    2. Initial simplification48.0

      \[\leadsto c0 \cdot \sqrt{\frac{\frac{A}{V}}{\ell}}\]
    3. Using strategy rm
    4. Applied clear-num48.0

      \[\leadsto c0 \cdot \sqrt{\color{blue}{\frac{1}{\frac{\ell}{\frac{A}{V}}}}}\]
    5. Using strategy rm
    6. Applied sqrt-div46.0

      \[\leadsto c0 \cdot \color{blue}{\frac{\sqrt{1}}{\sqrt{\frac{\ell}{\frac{A}{V}}}}}\]
    7. Applied associate-*r/46.0

      \[\leadsto \color{blue}{\frac{c0 \cdot \sqrt{1}}{\sqrt{\frac{\ell}{\frac{A}{V}}}}}\]
    8. Using strategy rm
    9. Applied associate-/l*46.0

      \[\leadsto \color{blue}{\frac{c0}{\frac{\sqrt{\frac{\ell}{\frac{A}{V}}}}{\sqrt{1}}}}\]
    10. Using strategy rm
    11. Applied associate-/r/45.8

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

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

    if -inf.0 < (* c0 (sqrt (/ A (* V l)))) < -3.5741155635815926e-132 or 0.0 < (* c0 (sqrt (/ A (* V l)))) < 4.4289409362059765e+217

    1. Initial program 0.7

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

    if -3.5741155635815926e-132 < (* c0 (sqrt (/ A (* V l)))) < 0.0

    1. Initial program 27.4

      \[c0 \cdot \sqrt{\frac{A}{V \cdot \ell}}\]
    2. Initial simplification21.9

      \[\leadsto c0 \cdot \sqrt{\frac{\frac{A}{V}}{\ell}}\]
    3. Using strategy rm
    4. Applied clear-num22.2

      \[\leadsto c0 \cdot \sqrt{\color{blue}{\frac{1}{\frac{\ell}{\frac{A}{V}}}}}\]
    5. Using strategy rm
    6. Applied sqrt-div22.2

      \[\leadsto c0 \cdot \color{blue}{\frac{\sqrt{1}}{\sqrt{\frac{\ell}{\frac{A}{V}}}}}\]
    7. Applied associate-*r/22.2

      \[\leadsto \color{blue}{\frac{c0 \cdot \sqrt{1}}{\sqrt{\frac{\ell}{\frac{A}{V}}}}}\]
    8. Using strategy rm
    9. Applied associate-/l*22.2

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

    if 4.4289409362059765e+217 < (* c0 (sqrt (/ A (* V l))))

    1. Initial program 42.1

      \[c0 \cdot \sqrt{\frac{A}{V \cdot \ell}}\]
    2. Initial simplification33.7

      \[\leadsto c0 \cdot \sqrt{\frac{\frac{A}{V}}{\ell}}\]
    3. Using strategy rm
    4. Applied clear-num33.7

      \[\leadsto c0 \cdot \sqrt{\color{blue}{\frac{1}{\frac{\ell}{\frac{A}{V}}}}}\]
    5. Using strategy rm
    6. Applied sqrt-div32.6

      \[\leadsto c0 \cdot \color{blue}{\frac{\sqrt{1}}{\sqrt{\frac{\ell}{\frac{A}{V}}}}}\]
    7. Applied associate-*r/32.6

      \[\leadsto \color{blue}{\frac{c0 \cdot \sqrt{1}}{\sqrt{\frac{\ell}{\frac{A}{V}}}}}\]
    8. Using strategy rm
    9. Applied associate-/l*32.6

      \[\leadsto \color{blue}{\frac{c0}{\frac{\sqrt{\frac{\ell}{\frac{A}{V}}}}{\sqrt{1}}}}\]
    10. Using strategy rm
    11. Applied *-un-lft-identity32.6

      \[\leadsto \frac{c0}{\color{blue}{1 \cdot \frac{\sqrt{\frac{\ell}{\frac{A}{V}}}}{\sqrt{1}}}}\]
    12. Applied associate-/r*32.6

      \[\leadsto \color{blue}{\frac{\frac{c0}{1}}{\frac{\sqrt{\frac{\ell}{\frac{A}{V}}}}{\sqrt{1}}}}\]
    13. Simplified32.9

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;c0 \cdot \sqrt{\frac{A}{V \cdot \ell}} = -\infty:\\ \;\;\;\;\frac{c0}{\sqrt{\frac{\ell}{A}} \cdot \sqrt{V}}\\ \mathbf{elif}\;c0 \cdot \sqrt{\frac{A}{V \cdot \ell}} \le -3.5741155635815926 \cdot 10^{-132}:\\ \;\;\;\;c0 \cdot \sqrt{\frac{A}{V \cdot \ell}}\\ \mathbf{elif}\;c0 \cdot \sqrt{\frac{A}{V \cdot \ell}} \le 0.0:\\ \;\;\;\;\frac{c0}{\sqrt{\frac{\ell}{\frac{A}{V}}}}\\ \mathbf{elif}\;c0 \cdot \sqrt{\frac{A}{V \cdot \ell}} \le 4.4289409362059765 \cdot 10^{+217}:\\ \;\;\;\;c0 \cdot \sqrt{\frac{A}{V \cdot \ell}}\\ \mathbf{else}:\\ \;\;\;\;\frac{c0}{\sqrt{V \cdot \frac{\ell}{A}}}\\ \end{array}\]

Runtime

Time bar (total: 12.4s)Debug logProfile

BaselineHerbieOracleSpan%
Regimes18.514.77.111.434%
herbie shell --seed 2018290 +o rules:numerics
(FPCore (c0 A V l)
  :name "Henrywood and Agarwal, Equation (3)"
  (* c0 (sqrt (/ A (* V l)))))