Average Error: 29.8 → 29.8
Time: 9.9s
Precision: 64
Internal precision: 1408
\[\sqrt{x + 1} - \sqrt{x}\]
\[\sqrt{x + 1} - \sqrt{x}\]

Error

Bits error versus x

Target

Original29.8
Comparison0.2
Herbie29.8
\[ \frac{1}{\sqrt{x + 1} + \sqrt{x}} \]

Derivation

  1. Initial program 29.8

    \[\sqrt{x + 1} - \sqrt{x}\]
  2. Removed slow pow expressions

Runtime

Time bar (total: 9.9s) Debug log

Please include this information when filing a bug report:

herbie shell --seed '#(644180380 3784176976 401987740 22459203 1940947670 3323606534)'
(FPCore (x)
  :name "2sqrt (example 3.1)"

  :target
  (/ 1 (+ (sqrt (+ x 1)) (sqrt x)))

  (- (sqrt (+ x 1)) (sqrt x)))