Input Error: 30.7b
Output Error: 9.1b
Time: 1.1m
Precision: 64b
Ground Truth: 128b
\[{\left(x + 1\right)}^{\left(\frac{1}{n}\right)} - {x}^{\left(\frac{1}{n}\right)}\]
\[\begin{cases} \frac{1}{n \cdot x} - \left(\frac{1}{2} \cdot \frac{1}{n \cdot {x}^2} - \frac{\log x}{{n}^2 \cdot x}\right) & \text{when } n \le -8.279812664685517 \cdot 10^{+25} \\ {\left(x + 1\right)}^{\left(\frac{1}{n}\right)} - {x}^{\left(\frac{1}{n}\right)} & \text{when } n \le 15558334820591744.0 \\ \frac{1}{n \cdot x} - \left(\frac{1}{2} \cdot \frac{1}{n \cdot {x}^2} - \frac{\log x}{{n}^2 \cdot x}\right) & \text{otherwise} \end{cases}\]

Error

Bits error versus x
Bits error versus n

Derivation

    if n < -8.279812664685517e+25 or 15558334820591744.0 < n

    1. Initial program 44.0b

      \[{\left(x + 1\right)}^{\left(\frac{1}{n}\right)} - {x}^{\left(\frac{1}{n}\right)}\]
    2. Applied taylor 10.2b

      \[\leadsto \frac{1}{n \cdot x} - \left(\frac{1}{2} \cdot \frac{1}{n \cdot {x}^2} + \frac{\log x}{{n}^2 \cdot x}\right)\]
    3. Taylor expanded around inf 10.2b

      \[\leadsto \color{blue}{\frac{1}{n \cdot x} - \left(\frac{1}{2} \cdot \frac{1}{n \cdot {x}^2} + \frac{\log x}{{n}^2 \cdot x}\right)}\]
    4. Applied taylor 10.2b

      \[\leadsto \frac{1}{n \cdot x} - \left(\frac{1}{2} \cdot \frac{1}{n \cdot {x}^2} - \frac{\log x}{{n}^2 \cdot x}\right)\]
    5. Taylor expanded around inf 10.2b

      \[\leadsto \frac{1}{n \cdot x} - \color{blue}{\left(\frac{1}{2} \cdot \frac{1}{n \cdot {x}^2} - \frac{\log x}{{n}^2 \cdot x}\right)}\]

    if -8.279812664685517e+25 < n < 15558334820591744.0

    1. Initial program 7.1b

      \[{\left(x + 1\right)}^{\left(\frac{1}{n}\right)} - {x}^{\left(\frac{1}{n}\right)}\]
  1. Removed slow pow expressions

Runtime

Total time: 1.1m Debug log

herbie --seed '#(4144684574 3344287632 4282537481 2661820295 3395742502 212124165)'
(FPCore (x n)
  :name "NMSE problem 3.4.6"
  (- (pow (+ x 1) (/ 1 n)) (pow x (/ 1 n))))