Average Error: 29.1 → 0
Time: 1.9s
Precision: 64
Internal Precision: 384
\[\sqrt{{x}^{2}}\]
\[\left|x\right|\]

Error

Bits error versus x

Derivation

  1. Initial program 29.1

    \[\sqrt{{x}^{2}}\]
  2. Applied simplify0

    \[\leadsto \color{blue}{\left|x\right|}\]
  3. Removed slow pow expressions.

Runtime

Time bar (total: 1.9s)Debug log

herbie shell --seed '#(70252082 919214569 1471114608 411424673 2660871550 3674146617)' 
(FPCore (x)
  :name "sqrt(x^2)"
  (sqrt (pow x 2)))