\sqrt[3]{x + 1} - \sqrt[3]{x}
\begin{array}{l}
\mathbf{if}\;x \leq -55446274.87776053:\\
\;\;\;\;0.3333333333333333 \cdot \sqrt[3]{\frac{1}{x \cdot x}}\\
\mathbf{else}:\\
\;\;\;\;\begin{array}{l}
t_0 := \sqrt[3]{x + 1}\\
\mathbf{if}\;x \leq 5.1726045598553944 \cdot 10^{-5}:\\
\;\;\;\;\frac{{t_0}^{3} - {\left(\sqrt[3]{x}\right)}^{3}}{t_0 \cdot t_0 + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + t_0 \cdot \sqrt[3]{x}\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{1}{{x}^{0.6666666666666666} + t_0 \cdot \left(t_0 + \sqrt[3]{x}\right)}\\
\end{array}\\
\end{array}
(FPCore (x) :precision binary64 (- (cbrt (+ x 1.0)) (cbrt x)))
(FPCore (x)
:precision binary64
(if (<= x -55446274.87776053)
(* 0.3333333333333333 (cbrt (/ 1.0 (* x x))))
(let* ((t_0 (cbrt (+ x 1.0))))
(if (<= x 5.1726045598553944e-5)
(/
(- (pow t_0 3.0) (pow (cbrt x) 3.0))
(+ (* t_0 t_0) (+ (* (cbrt x) (cbrt x)) (* t_0 (cbrt x)))))
(/ 1.0 (+ (pow x 0.6666666666666666) (* t_0 (+ t_0 (cbrt x)))))))))double code(double x) {
return cbrt(x + 1.0) - cbrt(x);
}
double code(double x) {
double tmp;
if (x <= -55446274.87776053) {
tmp = 0.3333333333333333 * cbrt(1.0 / (x * x));
} else {
double t_0 = cbrt(x + 1.0);
double tmp_1;
if (x <= 5.1726045598553944e-5) {
tmp_1 = (pow(t_0, 3.0) - pow(cbrt(x), 3.0)) / ((t_0 * t_0) + ((cbrt(x) * cbrt(x)) + (t_0 * cbrt(x))));
} else {
tmp_1 = 1.0 / (pow(x, 0.6666666666666666) + (t_0 * (t_0 + cbrt(x))));
}
tmp = tmp_1;
}
return tmp;
}



Bits error versus x
Results
if x < -55446274.87776053Initial program 60.6
Taylor expanded around inf 34.3
Simplified32.3
if -55446274.87776053 < x < 5.1726045598553944e-5Initial program 0.2
rmApplied flip3--_binary640.2
if 5.1726045598553944e-5 < x Initial program 58.7
rmApplied flip3--_binary6458.6
Simplified1.0
Simplified4.4
Final simplification9.3
herbie shell --seed 2021210
(FPCore (x)
:name "2cbrt (problem 3.3.4)"
:precision binary64
(- (cbrt (+ x 1.0)) (cbrt x)))