Average Error: 29.7 → 0.5
Time: 18.4s
Precision: 64
Internal Precision: 128
\[\sqrt[3]{x + 1} - \sqrt[3]{x}\]
\[\begin{array}{l} \mathbf{if}\;x \le -1.0112864276955098:\\ \;\;\;\;\left(\frac{1}{3} - \frac{\frac{1}{9}}{x}\right) \cdot \frac{\sqrt[3]{x}}{x} + \left(\sqrt[3]{x} - \sqrt[3]{-1} \cdot \sqrt[3]{-x}\right)\\ \mathbf{elif}\;x \le 58960.87609924843:\\ \;\;\;\;\log \left(e^{{\left(x + 1\right)}^{\frac{1}{3}} - \sqrt[3]{x}}\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\frac{1}{3} - \frac{\frac{1}{9}}{x}\right) \cdot \frac{\sqrt[3]{x}}{x} + \left(\sqrt[3]{x} - \sqrt[3]{-1} \cdot \sqrt[3]{-x}\right)\\ \end{array}\]

Error

Bits error versus x

Derivation

  1. Split input into 2 regimes
  2. if x < -1.0112864276955098 or 58960.87609924843 < x

    1. Initial program 59.8

      \[\sqrt[3]{x + 1} - \sqrt[3]{x}\]
    2. Using strategy rm
    3. Applied add-log-exp61.9

      \[\leadsto \sqrt[3]{x + 1} - \color{blue}{\log \left(e^{\sqrt[3]{x}}\right)}\]
    4. Applied add-log-exp61.4

      \[\leadsto \color{blue}{\log \left(e^{\sqrt[3]{x + 1}}\right)} - \log \left(e^{\sqrt[3]{x}}\right)\]
    5. Applied diff-log61.4

      \[\leadsto \color{blue}{\log \left(\frac{e^{\sqrt[3]{x + 1}}}{e^{\sqrt[3]{x}}}\right)}\]
    6. Simplified59.8

      \[\leadsto \log \color{blue}{\left(e^{\sqrt[3]{1 + x} - \sqrt[3]{x}}\right)}\]
    7. Using strategy rm
    8. Applied pow1/362.3

      \[\leadsto \log \left(e^{\color{blue}{{\left(1 + x\right)}^{\frac{1}{3}}} - \sqrt[3]{x}}\right)\]
    9. Taylor expanded around -inf 62.4

      \[\leadsto \color{blue}{\left(e^{\frac{1}{3} \cdot \left(\log -1 - \log \left(\frac{-1}{x}\right)\right)} + \frac{1}{3} \cdot \frac{e^{\frac{1}{3} \cdot \left(\log -1 - \log \left(\frac{-1}{x}\right)\right)}}{x}\right) - \left({\left(x \cdot -1\right)}^{\frac{1}{3}} \cdot \sqrt[3]{-1} + \frac{1}{9} \cdot \frac{e^{\frac{1}{3} \cdot \left(\log -1 - \log \left(\frac{-1}{x}\right)\right)}}{{x}^{2}}\right)}\]
    10. Simplified0.9

      \[\leadsto \color{blue}{\left(\frac{1}{3} - \frac{\frac{1}{9}}{x}\right) \cdot \frac{\sqrt[3]{x}}{x} + \left(\sqrt[3]{x} - \sqrt[3]{-1} \cdot \sqrt[3]{-x}\right)}\]

    if -1.0112864276955098 < x < 58960.87609924843

    1. Initial program 0.1

      \[\sqrt[3]{x + 1} - \sqrt[3]{x}\]
    2. Using strategy rm
    3. Applied add-log-exp0.1

      \[\leadsto \sqrt[3]{x + 1} - \color{blue}{\log \left(e^{\sqrt[3]{x}}\right)}\]
    4. Applied add-log-exp0.1

      \[\leadsto \color{blue}{\log \left(e^{\sqrt[3]{x + 1}}\right)} - \log \left(e^{\sqrt[3]{x}}\right)\]
    5. Applied diff-log0.1

      \[\leadsto \color{blue}{\log \left(\frac{e^{\sqrt[3]{x + 1}}}{e^{\sqrt[3]{x}}}\right)}\]
    6. Simplified0.1

      \[\leadsto \log \color{blue}{\left(e^{\sqrt[3]{1 + x} - \sqrt[3]{x}}\right)}\]
    7. Using strategy rm
    8. Applied pow1/30.1

      \[\leadsto \log \left(e^{\color{blue}{{\left(1 + x\right)}^{\frac{1}{3}}} - \sqrt[3]{x}}\right)\]
  3. Recombined 2 regimes into one program.
  4. Final simplification0.5

    \[\leadsto \begin{array}{l} \mathbf{if}\;x \le -1.0112864276955098:\\ \;\;\;\;\left(\frac{1}{3} - \frac{\frac{1}{9}}{x}\right) \cdot \frac{\sqrt[3]{x}}{x} + \left(\sqrt[3]{x} - \sqrt[3]{-1} \cdot \sqrt[3]{-x}\right)\\ \mathbf{elif}\;x \le 58960.87609924843:\\ \;\;\;\;\log \left(e^{{\left(x + 1\right)}^{\frac{1}{3}} - \sqrt[3]{x}}\right)\\ \mathbf{else}:\\ \;\;\;\;\left(\frac{1}{3} - \frac{\frac{1}{9}}{x}\right) \cdot \frac{\sqrt[3]{x}}{x} + \left(\sqrt[3]{x} - \sqrt[3]{-1} \cdot \sqrt[3]{-x}\right)\\ \end{array}\]

Reproduce

herbie shell --seed 2019051 
(FPCore (x)
  :name "2cbrt (problem 3.3.4)"
  (- (cbrt (+ x 1)) (cbrt x)))