2cbrt (problem 3.3.4)

Percentage Accurate: 52.9% → 99.2%
Time: 16.6s
Alternatives: 14
Speedup: 1.0×

Specification

?
\[\begin{array}{l} \\ \sqrt[3]{x + 1} - \sqrt[3]{x} \end{array} \]
(FPCore (x) :precision binary64 (- (cbrt (+ x 1.0)) (cbrt x)))
double code(double x) {
	return cbrt((x + 1.0)) - cbrt(x);
}
public static double code(double x) {
	return Math.cbrt((x + 1.0)) - Math.cbrt(x);
}
function code(x)
	return Float64(cbrt(Float64(x + 1.0)) - cbrt(x))
end
code[x_] := N[(N[Power[N[(x + 1.0), $MachinePrecision], 1/3], $MachinePrecision] - N[Power[x, 1/3], $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\sqrt[3]{x + 1} - \sqrt[3]{x}
\end{array}

Sampling outcomes in binary64 precision:

Local Percentage Accuracy vs ?

The average percentage accuracy by input value. Horizontal axis shows value of an input variable; the variable is choosen in the title. Vertical axis is accuracy; higher is better. Red represent the original program, while blue represents Herbie's suggestion. These can be toggled with buttons below the plot. The line is an average while dots represent individual samples.

Accuracy vs Speed?

Herbie found 14 alternatives:

AlternativeAccuracySpeedup
The accuracy (vertical axis) and speed (horizontal axis) of each alternatives. Up and to the right is better. The red square shows the initial program, and each blue circle shows an alternative.The line shows the best available speed-accuracy tradeoffs.

Initial Program: 52.9% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \sqrt[3]{x + 1} - \sqrt[3]{x} \end{array} \]
(FPCore (x) :precision binary64 (- (cbrt (+ x 1.0)) (cbrt x)))
double code(double x) {
	return cbrt((x + 1.0)) - cbrt(x);
}
public static double code(double x) {
	return Math.cbrt((x + 1.0)) - Math.cbrt(x);
}
function code(x)
	return Float64(cbrt(Float64(x + 1.0)) - cbrt(x))
end
code[x_] := N[(N[Power[N[(x + 1.0), $MachinePrecision], 1/3], $MachinePrecision] - N[Power[x, 1/3], $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\sqrt[3]{x + 1} - \sqrt[3]{x}
\end{array}

Alternative 1: 99.2% accurate, 0.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := \sqrt[3]{1 + x}\\ \mathbf{if}\;t_0 - \sqrt[3]{x} \leq 0:\\ \;\;\;\;\frac{1}{{t_0}^{2} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x} + \sqrt[3]{x}\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{\sqrt[3]{x} \cdot \left(t_0 + \sqrt[3]{x}\right) + \sqrt[3]{{\left(1 + x\right)}^{2}}}\\ \end{array} \end{array} \]
(FPCore (x)
 :precision binary64
 (let* ((t_0 (cbrt (+ 1.0 x))))
   (if (<= (- t_0 (cbrt x)) 0.0)
     (/ 1.0 (+ (pow t_0 2.0) (* (cbrt x) (+ (cbrt x) (cbrt x)))))
     (/ 1.0 (+ (* (cbrt x) (+ t_0 (cbrt x))) (cbrt (pow (+ 1.0 x) 2.0)))))))
double code(double x) {
	double t_0 = cbrt((1.0 + x));
	double tmp;
	if ((t_0 - cbrt(x)) <= 0.0) {
		tmp = 1.0 / (pow(t_0, 2.0) + (cbrt(x) * (cbrt(x) + cbrt(x))));
	} else {
		tmp = 1.0 / ((cbrt(x) * (t_0 + cbrt(x))) + cbrt(pow((1.0 + x), 2.0)));
	}
	return tmp;
}
public static double code(double x) {
	double t_0 = Math.cbrt((1.0 + x));
	double tmp;
	if ((t_0 - Math.cbrt(x)) <= 0.0) {
		tmp = 1.0 / (Math.pow(t_0, 2.0) + (Math.cbrt(x) * (Math.cbrt(x) + Math.cbrt(x))));
	} else {
		tmp = 1.0 / ((Math.cbrt(x) * (t_0 + Math.cbrt(x))) + Math.cbrt(Math.pow((1.0 + x), 2.0)));
	}
	return tmp;
}
function code(x)
	t_0 = cbrt(Float64(1.0 + x))
	tmp = 0.0
	if (Float64(t_0 - cbrt(x)) <= 0.0)
		tmp = Float64(1.0 / Float64((t_0 ^ 2.0) + Float64(cbrt(x) * Float64(cbrt(x) + cbrt(x)))));
	else
		tmp = Float64(1.0 / Float64(Float64(cbrt(x) * Float64(t_0 + cbrt(x))) + cbrt((Float64(1.0 + x) ^ 2.0))));
	end
	return tmp
end
code[x_] := Block[{t$95$0 = N[Power[N[(1.0 + x), $MachinePrecision], 1/3], $MachinePrecision]}, If[LessEqual[N[(t$95$0 - N[Power[x, 1/3], $MachinePrecision]), $MachinePrecision], 0.0], N[(1.0 / N[(N[Power[t$95$0, 2.0], $MachinePrecision] + N[(N[Power[x, 1/3], $MachinePrecision] * N[(N[Power[x, 1/3], $MachinePrecision] + N[Power[x, 1/3], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(1.0 / N[(N[(N[Power[x, 1/3], $MachinePrecision] * N[(t$95$0 + N[Power[x, 1/3], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[Power[N[Power[N[(1.0 + x), $MachinePrecision], 2.0], $MachinePrecision], 1/3], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := \sqrt[3]{1 + x}\\
\mathbf{if}\;t_0 - \sqrt[3]{x} \leq 0:\\
\;\;\;\;\frac{1}{{t_0}^{2} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x} + \sqrt[3]{x}\right)}\\

\mathbf{else}:\\
\;\;\;\;\frac{1}{\sqrt[3]{x} \cdot \left(t_0 + \sqrt[3]{x}\right) + \sqrt[3]{{\left(1 + x\right)}^{2}}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (-.f64 (cbrt.f64 (+.f64 x 1)) (cbrt.f64 x)) < 0.0

    1. Initial program 4.2%

      \[\sqrt[3]{x + 1} - \sqrt[3]{x} \]
    2. Step-by-step derivation
      1. flip3--4.2%

        \[\leadsto \color{blue}{\frac{{\left(\sqrt[3]{x + 1}\right)}^{3} - {\left(\sqrt[3]{x}\right)}^{3}}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)}} \]
      2. div-inv4.2%

        \[\leadsto \color{blue}{\left({\left(\sqrt[3]{x + 1}\right)}^{3} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)}} \]
      3. rem-cube-cbrt3.8%

        \[\leadsto \left(\color{blue}{\left(x + 1\right)} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      4. +-commutative3.8%

        \[\leadsto \left(\color{blue}{\left(1 + x\right)} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      5. rem-cube-cbrt4.2%

        \[\leadsto \left(\left(1 + x\right) - \color{blue}{x}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      6. associate--l+98.4%

        \[\leadsto \color{blue}{\left(1 + \left(x - x\right)\right)} \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
    3. Applied egg-rr43.1%

      \[\leadsto \color{blue}{\left(1 + \left(x - x\right)\right) \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)}} \]
    4. Step-by-step derivation
      1. +-inverses43.1%

        \[\leadsto \left(1 + \color{blue}{0}\right) \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)} \]
      2. metadata-eval43.1%

        \[\leadsto \color{blue}{1} \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)} \]
      3. *-lft-identity43.1%

        \[\leadsto \color{blue}{\frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)}} \]
      4. +-commutative43.1%

        \[\leadsto \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{\color{blue}{1 + x}} + \sqrt[3]{x}\right)} \]
    5. Simplified43.1%

      \[\leadsto \color{blue}{\frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)}} \]
    6. Step-by-step derivation
      1. log1p-udef43.1%

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

        \[\leadsto \frac{1}{e^{\log \color{blue}{\left(x + 1\right)} \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
      3. exp-to-pow43.0%

        \[\leadsto \frac{1}{\color{blue}{{\left(x + 1\right)}^{0.6666666666666666}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
      4. metadata-eval43.0%

        \[\leadsto \frac{1}{{\left(x + 1\right)}^{\color{blue}{\left(2 \cdot 0.3333333333333333\right)}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
      5. pow-sqr43.0%

        \[\leadsto \frac{1}{\color{blue}{{\left(x + 1\right)}^{0.3333333333333333} \cdot {\left(x + 1\right)}^{0.3333333333333333}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
      6. pow1/343.7%

        \[\leadsto \frac{1}{\color{blue}{\sqrt[3]{x + 1}} \cdot {\left(x + 1\right)}^{0.3333333333333333} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
      7. pow1/398.4%

        \[\leadsto \frac{1}{\sqrt[3]{x + 1} \cdot \color{blue}{\sqrt[3]{x + 1}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
      8. pow298.4%

        \[\leadsto \frac{1}{\color{blue}{{\left(\sqrt[3]{x + 1}\right)}^{2}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
    7. Applied egg-rr98.4%

      \[\leadsto \frac{1}{\color{blue}{{\left(\sqrt[3]{x + 1}\right)}^{2}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
    8. Step-by-step derivation
      1. +-commutative98.4%

        \[\leadsto \frac{1}{{\left(\sqrt[3]{x + 1}\right)}^{2} + \sqrt[3]{x} \cdot \left(\sqrt[3]{\color{blue}{x + 1}} + \sqrt[3]{x}\right)} \]
      2. pow1/343.7%

        \[\leadsto \frac{1}{{\left(\sqrt[3]{x + 1}\right)}^{2} + \sqrt[3]{x} \cdot \left(\color{blue}{{\left(x + 1\right)}^{0.3333333333333333}} + \sqrt[3]{x}\right)} \]
      3. metadata-eval43.7%

        \[\leadsto \frac{1}{{\left(\sqrt[3]{x + 1}\right)}^{2} + \sqrt[3]{x} \cdot \left({\left(x + 1\right)}^{\color{blue}{\left(\frac{0.6666666666666666}{2}\right)}} + \sqrt[3]{x}\right)} \]
      4. sqrt-pow243.7%

        \[\leadsto \frac{1}{{\left(\sqrt[3]{x + 1}\right)}^{2} + \sqrt[3]{x} \cdot \left(\color{blue}{{\left(\sqrt{x + 1}\right)}^{0.6666666666666666}} + \sqrt[3]{x}\right)} \]
      5. add-cube-cbrt43.7%

        \[\leadsto \frac{1}{{\left(\sqrt[3]{x + 1}\right)}^{2} + \sqrt[3]{x} \cdot \left(\color{blue}{\left(\sqrt[3]{{\left(\sqrt{x + 1}\right)}^{0.6666666666666666}} \cdot \sqrt[3]{{\left(\sqrt{x + 1}\right)}^{0.6666666666666666}}\right) \cdot \sqrt[3]{{\left(\sqrt{x + 1}\right)}^{0.6666666666666666}}} + \sqrt[3]{x}\right)} \]
      6. pow343.7%

        \[\leadsto \frac{1}{{\left(\sqrt[3]{x + 1}\right)}^{2} + \sqrt[3]{x} \cdot \left(\color{blue}{{\left(\sqrt[3]{{\left(\sqrt{x + 1}\right)}^{0.6666666666666666}}\right)}^{3}} + \sqrt[3]{x}\right)} \]
      7. sqrt-pow243.7%

        \[\leadsto \frac{1}{{\left(\sqrt[3]{x + 1}\right)}^{2} + \sqrt[3]{x} \cdot \left({\left(\sqrt[3]{\color{blue}{{\left(x + 1\right)}^{\left(\frac{0.6666666666666666}{2}\right)}}}\right)}^{3} + \sqrt[3]{x}\right)} \]
      8. metadata-eval43.7%

        \[\leadsto \frac{1}{{\left(\sqrt[3]{x + 1}\right)}^{2} + \sqrt[3]{x} \cdot \left({\left(\sqrt[3]{{\left(x + 1\right)}^{\color{blue}{0.3333333333333333}}}\right)}^{3} + \sqrt[3]{x}\right)} \]
      9. pow1/398.2%

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

        \[\leadsto \frac{1}{{\left(\sqrt[3]{x + 1}\right)}^{2} + \sqrt[3]{x} \cdot \left({\left(\sqrt[3]{\sqrt[3]{\color{blue}{1 + x}}}\right)}^{3} + \sqrt[3]{x}\right)} \]
    9. Applied egg-rr98.2%

      \[\leadsto \frac{1}{{\left(\sqrt[3]{x + 1}\right)}^{2} + \sqrt[3]{x} \cdot \left(\color{blue}{{\left(\sqrt[3]{\sqrt[3]{1 + x}}\right)}^{3}} + \sqrt[3]{x}\right)} \]
    10. Taylor expanded in x around inf 43.7%

      \[\leadsto \frac{1}{{\left(\sqrt[3]{x + 1}\right)}^{2} + \sqrt[3]{x} \cdot \left(\color{blue}{{x}^{0.3333333333333333}} + \sqrt[3]{x}\right)} \]
    11. Step-by-step derivation
      1. unpow1/398.4%

        \[\leadsto \frac{1}{{\left(\sqrt[3]{x + 1}\right)}^{2} + \sqrt[3]{x} \cdot \left(\color{blue}{\sqrt[3]{x}} + \sqrt[3]{x}\right)} \]
    12. Simplified98.4%

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

    if 0.0 < (-.f64 (cbrt.f64 (+.f64 x 1)) (cbrt.f64 x))

    1. Initial program 97.4%

      \[\sqrt[3]{x + 1} - \sqrt[3]{x} \]
    2. Step-by-step derivation
      1. flip3--97.4%

        \[\leadsto \color{blue}{\frac{{\left(\sqrt[3]{x + 1}\right)}^{3} - {\left(\sqrt[3]{x}\right)}^{3}}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)}} \]
      2. div-inv97.4%

        \[\leadsto \color{blue}{\left({\left(\sqrt[3]{x + 1}\right)}^{3} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)}} \]
      3. rem-cube-cbrt97.9%

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

        \[\leadsto \left(\color{blue}{\left(1 + x\right)} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      5. rem-cube-cbrt99.8%

        \[\leadsto \left(\left(1 + x\right) - \color{blue}{x}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      6. associate--l+99.8%

        \[\leadsto \color{blue}{\left(1 + \left(x - x\right)\right)} \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
    3. Applied egg-rr96.4%

      \[\leadsto \color{blue}{\left(1 + \left(x - x\right)\right) \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)}} \]
    4. Step-by-step derivation
      1. +-inverses96.4%

        \[\leadsto \left(1 + \color{blue}{0}\right) \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)} \]
      2. metadata-eval96.4%

        \[\leadsto \color{blue}{1} \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)} \]
      3. *-lft-identity96.4%

        \[\leadsto \color{blue}{\frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)}} \]
      4. +-commutative96.4%

        \[\leadsto \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{\color{blue}{1 + x}} + \sqrt[3]{x}\right)} \]
    5. Simplified96.4%

      \[\leadsto \color{blue}{\frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)}} \]
    6. Step-by-step derivation
      1. log1p-udef96.4%

        \[\leadsto \frac{1}{e^{\color{blue}{\log \left(1 + x\right)} \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
      2. +-commutative96.4%

        \[\leadsto \frac{1}{e^{\log \color{blue}{\left(x + 1\right)} \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
      3. exp-to-pow96.5%

        \[\leadsto \frac{1}{\color{blue}{{\left(x + 1\right)}^{0.6666666666666666}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
      4. metadata-eval96.5%

        \[\leadsto \frac{1}{{\left(x + 1\right)}^{\color{blue}{\left(2 \cdot 0.3333333333333333\right)}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
      5. pow-sqr96.5%

        \[\leadsto \frac{1}{\color{blue}{{\left(x + 1\right)}^{0.3333333333333333} \cdot {\left(x + 1\right)}^{0.3333333333333333}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
      6. pow-prod-down99.8%

        \[\leadsto \frac{1}{\color{blue}{{\left(\left(x + 1\right) \cdot \left(x + 1\right)\right)}^{0.3333333333333333}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
      7. pow1/399.9%

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

        \[\leadsto \frac{1}{\sqrt[3]{\color{blue}{{\left(x + 1\right)}^{2}}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
    7. Applied egg-rr99.9%

      \[\leadsto \frac{1}{\color{blue}{\sqrt[3]{{\left(x + 1\right)}^{2}}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification99.1%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\sqrt[3]{1 + x} - \sqrt[3]{x} \leq 0:\\ \;\;\;\;\frac{1}{{\left(\sqrt[3]{1 + x}\right)}^{2} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x} + \sqrt[3]{x}\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{\sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right) + \sqrt[3]{{\left(1 + x\right)}^{2}}}\\ \end{array} \]

Alternative 2: 98.7% accurate, 0.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := \sqrt[3]{1 + x}\\ \mathbf{if}\;t_0 - \sqrt[3]{x} \leq 5 \cdot 10^{-6}:\\ \;\;\;\;\frac{1}{{t_0}^{2} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x} + \sqrt[3]{x}\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{\sqrt[3]{\mathsf{fma}\left(x, x, -1\right)}}{\sqrt[3]{x + -1}} - \sqrt[3]{x}\\ \end{array} \end{array} \]
(FPCore (x)
 :precision binary64
 (let* ((t_0 (cbrt (+ 1.0 x))))
   (if (<= (- t_0 (cbrt x)) 5e-6)
     (/ 1.0 (+ (pow t_0 2.0) (* (cbrt x) (+ (cbrt x) (cbrt x)))))
     (- (/ (cbrt (fma x x -1.0)) (cbrt (+ x -1.0))) (cbrt x)))))
double code(double x) {
	double t_0 = cbrt((1.0 + x));
	double tmp;
	if ((t_0 - cbrt(x)) <= 5e-6) {
		tmp = 1.0 / (pow(t_0, 2.0) + (cbrt(x) * (cbrt(x) + cbrt(x))));
	} else {
		tmp = (cbrt(fma(x, x, -1.0)) / cbrt((x + -1.0))) - cbrt(x);
	}
	return tmp;
}
function code(x)
	t_0 = cbrt(Float64(1.0 + x))
	tmp = 0.0
	if (Float64(t_0 - cbrt(x)) <= 5e-6)
		tmp = Float64(1.0 / Float64((t_0 ^ 2.0) + Float64(cbrt(x) * Float64(cbrt(x) + cbrt(x)))));
	else
		tmp = Float64(Float64(cbrt(fma(x, x, -1.0)) / cbrt(Float64(x + -1.0))) - cbrt(x));
	end
	return tmp
end
code[x_] := Block[{t$95$0 = N[Power[N[(1.0 + x), $MachinePrecision], 1/3], $MachinePrecision]}, If[LessEqual[N[(t$95$0 - N[Power[x, 1/3], $MachinePrecision]), $MachinePrecision], 5e-6], N[(1.0 / N[(N[Power[t$95$0, 2.0], $MachinePrecision] + N[(N[Power[x, 1/3], $MachinePrecision] * N[(N[Power[x, 1/3], $MachinePrecision] + N[Power[x, 1/3], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(N[Power[N[(x * x + -1.0), $MachinePrecision], 1/3], $MachinePrecision] / N[Power[N[(x + -1.0), $MachinePrecision], 1/3], $MachinePrecision]), $MachinePrecision] - N[Power[x, 1/3], $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := \sqrt[3]{1 + x}\\
\mathbf{if}\;t_0 - \sqrt[3]{x} \leq 5 \cdot 10^{-6}:\\
\;\;\;\;\frac{1}{{t_0}^{2} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x} + \sqrt[3]{x}\right)}\\

\mathbf{else}:\\
\;\;\;\;\frac{\sqrt[3]{\mathsf{fma}\left(x, x, -1\right)}}{\sqrt[3]{x + -1}} - \sqrt[3]{x}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (-.f64 (cbrt.f64 (+.f64 x 1)) (cbrt.f64 x)) < 5.00000000000000041e-6

    1. Initial program 5.3%

      \[\sqrt[3]{x + 1} - \sqrt[3]{x} \]
    2. Step-by-step derivation
      1. flip3--5.3%

        \[\leadsto \color{blue}{\frac{{\left(\sqrt[3]{x + 1}\right)}^{3} - {\left(\sqrt[3]{x}\right)}^{3}}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)}} \]
      2. div-inv5.3%

        \[\leadsto \color{blue}{\left({\left(\sqrt[3]{x + 1}\right)}^{3} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)}} \]
      3. rem-cube-cbrt5.4%

        \[\leadsto \left(\color{blue}{\left(x + 1\right)} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      4. +-commutative5.4%

        \[\leadsto \left(\color{blue}{\left(1 + x\right)} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      5. rem-cube-cbrt6.9%

        \[\leadsto \left(\left(1 + x\right) - \color{blue}{x}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      6. associate--l+98.4%

        \[\leadsto \color{blue}{\left(1 + \left(x - x\right)\right)} \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
    3. Applied egg-rr43.3%

      \[\leadsto \color{blue}{\left(1 + \left(x - x\right)\right) \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)}} \]
    4. Step-by-step derivation
      1. +-inverses43.3%

        \[\leadsto \left(1 + \color{blue}{0}\right) \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)} \]
      2. metadata-eval43.3%

        \[\leadsto \color{blue}{1} \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)} \]
      3. *-lft-identity43.3%

        \[\leadsto \color{blue}{\frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)}} \]
      4. +-commutative43.3%

        \[\leadsto \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{\color{blue}{1 + x}} + \sqrt[3]{x}\right)} \]
    5. Simplified43.3%

      \[\leadsto \color{blue}{\frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)}} \]
    6. Step-by-step derivation
      1. log1p-udef43.3%

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

        \[\leadsto \frac{1}{e^{\log \color{blue}{\left(x + 1\right)} \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
      3. exp-to-pow43.2%

        \[\leadsto \frac{1}{\color{blue}{{\left(x + 1\right)}^{0.6666666666666666}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
      4. metadata-eval43.2%

        \[\leadsto \frac{1}{{\left(x + 1\right)}^{\color{blue}{\left(2 \cdot 0.3333333333333333\right)}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
      5. pow-sqr43.2%

        \[\leadsto \frac{1}{\color{blue}{{\left(x + 1\right)}^{0.3333333333333333} \cdot {\left(x + 1\right)}^{0.3333333333333333}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
      6. pow1/343.9%

        \[\leadsto \frac{1}{\color{blue}{\sqrt[3]{x + 1}} \cdot {\left(x + 1\right)}^{0.3333333333333333} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
      7. pow1/398.4%

        \[\leadsto \frac{1}{\sqrt[3]{x + 1} \cdot \color{blue}{\sqrt[3]{x + 1}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
      8. pow298.4%

        \[\leadsto \frac{1}{\color{blue}{{\left(\sqrt[3]{x + 1}\right)}^{2}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
    7. Applied egg-rr98.4%

      \[\leadsto \frac{1}{\color{blue}{{\left(\sqrt[3]{x + 1}\right)}^{2}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
    8. Step-by-step derivation
      1. +-commutative98.4%

        \[\leadsto \frac{1}{{\left(\sqrt[3]{x + 1}\right)}^{2} + \sqrt[3]{x} \cdot \left(\sqrt[3]{\color{blue}{x + 1}} + \sqrt[3]{x}\right)} \]
      2. pow1/343.9%

        \[\leadsto \frac{1}{{\left(\sqrt[3]{x + 1}\right)}^{2} + \sqrt[3]{x} \cdot \left(\color{blue}{{\left(x + 1\right)}^{0.3333333333333333}} + \sqrt[3]{x}\right)} \]
      3. metadata-eval43.9%

        \[\leadsto \frac{1}{{\left(\sqrt[3]{x + 1}\right)}^{2} + \sqrt[3]{x} \cdot \left({\left(x + 1\right)}^{\color{blue}{\left(\frac{0.6666666666666666}{2}\right)}} + \sqrt[3]{x}\right)} \]
      4. sqrt-pow243.9%

        \[\leadsto \frac{1}{{\left(\sqrt[3]{x + 1}\right)}^{2} + \sqrt[3]{x} \cdot \left(\color{blue}{{\left(\sqrt{x + 1}\right)}^{0.6666666666666666}} + \sqrt[3]{x}\right)} \]
      5. add-cube-cbrt43.9%

        \[\leadsto \frac{1}{{\left(\sqrt[3]{x + 1}\right)}^{2} + \sqrt[3]{x} \cdot \left(\color{blue}{\left(\sqrt[3]{{\left(\sqrt{x + 1}\right)}^{0.6666666666666666}} \cdot \sqrt[3]{{\left(\sqrt{x + 1}\right)}^{0.6666666666666666}}\right) \cdot \sqrt[3]{{\left(\sqrt{x + 1}\right)}^{0.6666666666666666}}} + \sqrt[3]{x}\right)} \]
      6. pow343.9%

        \[\leadsto \frac{1}{{\left(\sqrt[3]{x + 1}\right)}^{2} + \sqrt[3]{x} \cdot \left(\color{blue}{{\left(\sqrt[3]{{\left(\sqrt{x + 1}\right)}^{0.6666666666666666}}\right)}^{3}} + \sqrt[3]{x}\right)} \]
      7. sqrt-pow243.9%

        \[\leadsto \frac{1}{{\left(\sqrt[3]{x + 1}\right)}^{2} + \sqrt[3]{x} \cdot \left({\left(\sqrt[3]{\color{blue}{{\left(x + 1\right)}^{\left(\frac{0.6666666666666666}{2}\right)}}}\right)}^{3} + \sqrt[3]{x}\right)} \]
      8. metadata-eval43.9%

        \[\leadsto \frac{1}{{\left(\sqrt[3]{x + 1}\right)}^{2} + \sqrt[3]{x} \cdot \left({\left(\sqrt[3]{{\left(x + 1\right)}^{\color{blue}{0.3333333333333333}}}\right)}^{3} + \sqrt[3]{x}\right)} \]
      9. pow1/398.2%

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

        \[\leadsto \frac{1}{{\left(\sqrt[3]{x + 1}\right)}^{2} + \sqrt[3]{x} \cdot \left({\left(\sqrt[3]{\sqrt[3]{\color{blue}{1 + x}}}\right)}^{3} + \sqrt[3]{x}\right)} \]
    9. Applied egg-rr98.2%

      \[\leadsto \frac{1}{{\left(\sqrt[3]{x + 1}\right)}^{2} + \sqrt[3]{x} \cdot \left(\color{blue}{{\left(\sqrt[3]{\sqrt[3]{1 + x}}\right)}^{3}} + \sqrt[3]{x}\right)} \]
    10. Taylor expanded in x around inf 43.6%

      \[\leadsto \frac{1}{{\left(\sqrt[3]{x + 1}\right)}^{2} + \sqrt[3]{x} \cdot \left(\color{blue}{{x}^{0.3333333333333333}} + \sqrt[3]{x}\right)} \]
    11. Step-by-step derivation
      1. unpow1/397.8%

        \[\leadsto \frac{1}{{\left(\sqrt[3]{x + 1}\right)}^{2} + \sqrt[3]{x} \cdot \left(\color{blue}{\sqrt[3]{x}} + \sqrt[3]{x}\right)} \]
    12. Simplified97.8%

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

    if 5.00000000000000041e-6 < (-.f64 (cbrt.f64 (+.f64 x 1)) (cbrt.f64 x))

    1. Initial program 99.3%

      \[\sqrt[3]{x + 1} - \sqrt[3]{x} \]
    2. Step-by-step derivation
      1. flip-+99.3%

        \[\leadsto \sqrt[3]{\color{blue}{\frac{x \cdot x - 1 \cdot 1}{x - 1}}} - \sqrt[3]{x} \]
      2. cbrt-div99.4%

        \[\leadsto \color{blue}{\frac{\sqrt[3]{x \cdot x - 1 \cdot 1}}{\sqrt[3]{x - 1}}} - \sqrt[3]{x} \]
      3. div-inv99.4%

        \[\leadsto \color{blue}{\sqrt[3]{x \cdot x - 1 \cdot 1} \cdot \frac{1}{\sqrt[3]{x - 1}}} - \sqrt[3]{x} \]
      4. metadata-eval99.4%

        \[\leadsto \sqrt[3]{x \cdot x - \color{blue}{1}} \cdot \frac{1}{\sqrt[3]{x - 1}} - \sqrt[3]{x} \]
      5. fma-neg99.4%

        \[\leadsto \sqrt[3]{\color{blue}{\mathsf{fma}\left(x, x, -1\right)}} \cdot \frac{1}{\sqrt[3]{x - 1}} - \sqrt[3]{x} \]
      6. metadata-eval99.4%

        \[\leadsto \sqrt[3]{\mathsf{fma}\left(x, x, \color{blue}{-1}\right)} \cdot \frac{1}{\sqrt[3]{x - 1}} - \sqrt[3]{x} \]
      7. sub-neg99.4%

        \[\leadsto \sqrt[3]{\mathsf{fma}\left(x, x, -1\right)} \cdot \frac{1}{\sqrt[3]{\color{blue}{x + \left(-1\right)}}} - \sqrt[3]{x} \]
      8. metadata-eval99.4%

        \[\leadsto \sqrt[3]{\mathsf{fma}\left(x, x, -1\right)} \cdot \frac{1}{\sqrt[3]{x + \color{blue}{-1}}} - \sqrt[3]{x} \]
    3. Applied egg-rr99.4%

      \[\leadsto \color{blue}{\sqrt[3]{\mathsf{fma}\left(x, x, -1\right)} \cdot \frac{1}{\sqrt[3]{x + -1}}} - \sqrt[3]{x} \]
    4. Step-by-step derivation
      1. associate-*r/99.4%

        \[\leadsto \color{blue}{\frac{\sqrt[3]{\mathsf{fma}\left(x, x, -1\right)} \cdot 1}{\sqrt[3]{x + -1}}} - \sqrt[3]{x} \]
      2. *-rgt-identity99.4%

        \[\leadsto \frac{\color{blue}{\sqrt[3]{\mathsf{fma}\left(x, x, -1\right)}}}{\sqrt[3]{x + -1}} - \sqrt[3]{x} \]
    5. Simplified99.4%

      \[\leadsto \color{blue}{\frac{\sqrt[3]{\mathsf{fma}\left(x, x, -1\right)}}{\sqrt[3]{x + -1}}} - \sqrt[3]{x} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification98.5%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\sqrt[3]{1 + x} - \sqrt[3]{x} \leq 5 \cdot 10^{-6}:\\ \;\;\;\;\frac{1}{{\left(\sqrt[3]{1 + x}\right)}^{2} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x} + \sqrt[3]{x}\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{\sqrt[3]{\mathsf{fma}\left(x, x, -1\right)}}{\sqrt[3]{x + -1}} - \sqrt[3]{x}\\ \end{array} \]

Alternative 3: 60.5% accurate, 0.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := \sqrt[3]{1 + x}\\ \mathbf{if}\;t_0 - \sqrt[3]{x} \leq 0:\\ \;\;\;\;\frac{1}{1 + \sqrt[3]{x} \cdot \left(t_0 + \sqrt[3]{x}\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt[3]{\sqrt[3]{{\left(1 + x\right)}^{3}}} - \sqrt[3]{x}\\ \end{array} \end{array} \]
(FPCore (x)
 :precision binary64
 (let* ((t_0 (cbrt (+ 1.0 x))))
   (if (<= (- t_0 (cbrt x)) 0.0)
     (/ 1.0 (+ 1.0 (* (cbrt x) (+ t_0 (cbrt x)))))
     (- (cbrt (cbrt (pow (+ 1.0 x) 3.0))) (cbrt x)))))
double code(double x) {
	double t_0 = cbrt((1.0 + x));
	double tmp;
	if ((t_0 - cbrt(x)) <= 0.0) {
		tmp = 1.0 / (1.0 + (cbrt(x) * (t_0 + cbrt(x))));
	} else {
		tmp = cbrt(cbrt(pow((1.0 + x), 3.0))) - cbrt(x);
	}
	return tmp;
}
public static double code(double x) {
	double t_0 = Math.cbrt((1.0 + x));
	double tmp;
	if ((t_0 - Math.cbrt(x)) <= 0.0) {
		tmp = 1.0 / (1.0 + (Math.cbrt(x) * (t_0 + Math.cbrt(x))));
	} else {
		tmp = Math.cbrt(Math.cbrt(Math.pow((1.0 + x), 3.0))) - Math.cbrt(x);
	}
	return tmp;
}
function code(x)
	t_0 = cbrt(Float64(1.0 + x))
	tmp = 0.0
	if (Float64(t_0 - cbrt(x)) <= 0.0)
		tmp = Float64(1.0 / Float64(1.0 + Float64(cbrt(x) * Float64(t_0 + cbrt(x)))));
	else
		tmp = Float64(cbrt(cbrt((Float64(1.0 + x) ^ 3.0))) - cbrt(x));
	end
	return tmp
end
code[x_] := Block[{t$95$0 = N[Power[N[(1.0 + x), $MachinePrecision], 1/3], $MachinePrecision]}, If[LessEqual[N[(t$95$0 - N[Power[x, 1/3], $MachinePrecision]), $MachinePrecision], 0.0], N[(1.0 / N[(1.0 + N[(N[Power[x, 1/3], $MachinePrecision] * N[(t$95$0 + N[Power[x, 1/3], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[Power[N[Power[N[Power[N[(1.0 + x), $MachinePrecision], 3.0], $MachinePrecision], 1/3], $MachinePrecision], 1/3], $MachinePrecision] - N[Power[x, 1/3], $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := \sqrt[3]{1 + x}\\
\mathbf{if}\;t_0 - \sqrt[3]{x} \leq 0:\\
\;\;\;\;\frac{1}{1 + \sqrt[3]{x} \cdot \left(t_0 + \sqrt[3]{x}\right)}\\

\mathbf{else}:\\
\;\;\;\;\sqrt[3]{\sqrt[3]{{\left(1 + x\right)}^{3}}} - \sqrt[3]{x}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (-.f64 (cbrt.f64 (+.f64 x 1)) (cbrt.f64 x)) < 0.0

    1. Initial program 4.2%

      \[\sqrt[3]{x + 1} - \sqrt[3]{x} \]
    2. Step-by-step derivation
      1. flip3--4.2%

        \[\leadsto \color{blue}{\frac{{\left(\sqrt[3]{x + 1}\right)}^{3} - {\left(\sqrt[3]{x}\right)}^{3}}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)}} \]
      2. div-inv4.2%

        \[\leadsto \color{blue}{\left({\left(\sqrt[3]{x + 1}\right)}^{3} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)}} \]
      3. rem-cube-cbrt3.8%

        \[\leadsto \left(\color{blue}{\left(x + 1\right)} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      4. +-commutative3.8%

        \[\leadsto \left(\color{blue}{\left(1 + x\right)} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      5. rem-cube-cbrt4.2%

        \[\leadsto \left(\left(1 + x\right) - \color{blue}{x}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      6. associate--l+98.4%

        \[\leadsto \color{blue}{\left(1 + \left(x - x\right)\right)} \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
    3. Applied egg-rr43.1%

      \[\leadsto \color{blue}{\left(1 + \left(x - x\right)\right) \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)}} \]
    4. Step-by-step derivation
      1. +-inverses43.1%

        \[\leadsto \left(1 + \color{blue}{0}\right) \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)} \]
      2. metadata-eval43.1%

        \[\leadsto \color{blue}{1} \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)} \]
      3. *-lft-identity43.1%

        \[\leadsto \color{blue}{\frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)}} \]
      4. +-commutative43.1%

        \[\leadsto \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{\color{blue}{1 + x}} + \sqrt[3]{x}\right)} \]
    5. Simplified43.1%

      \[\leadsto \color{blue}{\frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)}} \]
    6. Taylor expanded in x around 0 20.0%

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

    if 0.0 < (-.f64 (cbrt.f64 (+.f64 x 1)) (cbrt.f64 x))

    1. Initial program 97.4%

      \[\sqrt[3]{x + 1} - \sqrt[3]{x} \]
    2. Step-by-step derivation
      1. pow1/395.4%

        \[\leadsto \color{blue}{{\left(x + 1\right)}^{0.3333333333333333}} - \sqrt[3]{x} \]
      2. pow-to-exp95.2%

        \[\leadsto \color{blue}{e^{\log \left(x + 1\right) \cdot 0.3333333333333333}} - \sqrt[3]{x} \]
      3. +-commutative95.2%

        \[\leadsto e^{\log \color{blue}{\left(1 + x\right)} \cdot 0.3333333333333333} - \sqrt[3]{x} \]
      4. log1p-def95.2%

        \[\leadsto e^{\color{blue}{\mathsf{log1p}\left(x\right)} \cdot 0.3333333333333333} - \sqrt[3]{x} \]
    3. Applied egg-rr95.2%

      \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(x\right) \cdot 0.3333333333333333}} - \sqrt[3]{x} \]
    4. Step-by-step derivation
      1. exp-prod95.2%

        \[\leadsto \color{blue}{{\left(e^{\mathsf{log1p}\left(x\right)}\right)}^{0.3333333333333333}} - \sqrt[3]{x} \]
      2. unpow1/395.2%

        \[\leadsto \color{blue}{\sqrt[3]{e^{\mathsf{log1p}\left(x\right)}}} - \sqrt[3]{x} \]
    5. Simplified95.2%

      \[\leadsto \color{blue}{\sqrt[3]{e^{\mathsf{log1p}\left(x\right)}}} - \sqrt[3]{x} \]
    6. Step-by-step derivation
      1. log1p-udef95.1%

        \[\leadsto \sqrt[3]{e^{\color{blue}{\log \left(1 + x\right)}}} - \sqrt[3]{x} \]
      2. +-commutative95.1%

        \[\leadsto \sqrt[3]{e^{\log \color{blue}{\left(x + 1\right)}}} - \sqrt[3]{x} \]
      3. add-cbrt-cube95.1%

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

        \[\leadsto \sqrt[3]{\color{blue}{\sqrt[3]{\left(\left(x + 1\right) \cdot \left(x + 1\right)\right) \cdot \left(x + 1\right)}}} - \sqrt[3]{x} \]
      5. pow397.4%

        \[\leadsto \sqrt[3]{\sqrt[3]{\color{blue}{{\left(x + 1\right)}^{3}}}} - \sqrt[3]{x} \]
    7. Applied egg-rr97.4%

      \[\leadsto \sqrt[3]{\color{blue}{\sqrt[3]{{\left(x + 1\right)}^{3}}}} - \sqrt[3]{x} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification55.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\sqrt[3]{1 + x} - \sqrt[3]{x} \leq 0:\\ \;\;\;\;\frac{1}{1 + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt[3]{\sqrt[3]{{\left(1 + x\right)}^{3}}} - \sqrt[3]{x}\\ \end{array} \]

Alternative 4: 60.4% accurate, 0.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := \sqrt[3]{1 + x}\\ \mathbf{if}\;t_0 - \sqrt[3]{x} \leq 0:\\ \;\;\;\;\frac{1}{1 + \sqrt[3]{x} \cdot \left(t_0 + \sqrt[3]{x}\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt[3]{{t_0}^{3}} - \sqrt[3]{x}\\ \end{array} \end{array} \]
(FPCore (x)
 :precision binary64
 (let* ((t_0 (cbrt (+ 1.0 x))))
   (if (<= (- t_0 (cbrt x)) 0.0)
     (/ 1.0 (+ 1.0 (* (cbrt x) (+ t_0 (cbrt x)))))
     (- (cbrt (pow t_0 3.0)) (cbrt x)))))
double code(double x) {
	double t_0 = cbrt((1.0 + x));
	double tmp;
	if ((t_0 - cbrt(x)) <= 0.0) {
		tmp = 1.0 / (1.0 + (cbrt(x) * (t_0 + cbrt(x))));
	} else {
		tmp = cbrt(pow(t_0, 3.0)) - cbrt(x);
	}
	return tmp;
}
public static double code(double x) {
	double t_0 = Math.cbrt((1.0 + x));
	double tmp;
	if ((t_0 - Math.cbrt(x)) <= 0.0) {
		tmp = 1.0 / (1.0 + (Math.cbrt(x) * (t_0 + Math.cbrt(x))));
	} else {
		tmp = Math.cbrt(Math.pow(t_0, 3.0)) - Math.cbrt(x);
	}
	return tmp;
}
function code(x)
	t_0 = cbrt(Float64(1.0 + x))
	tmp = 0.0
	if (Float64(t_0 - cbrt(x)) <= 0.0)
		tmp = Float64(1.0 / Float64(1.0 + Float64(cbrt(x) * Float64(t_0 + cbrt(x)))));
	else
		tmp = Float64(cbrt((t_0 ^ 3.0)) - cbrt(x));
	end
	return tmp
end
code[x_] := Block[{t$95$0 = N[Power[N[(1.0 + x), $MachinePrecision], 1/3], $MachinePrecision]}, If[LessEqual[N[(t$95$0 - N[Power[x, 1/3], $MachinePrecision]), $MachinePrecision], 0.0], N[(1.0 / N[(1.0 + N[(N[Power[x, 1/3], $MachinePrecision] * N[(t$95$0 + N[Power[x, 1/3], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[Power[N[Power[t$95$0, 3.0], $MachinePrecision], 1/3], $MachinePrecision] - N[Power[x, 1/3], $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := \sqrt[3]{1 + x}\\
\mathbf{if}\;t_0 - \sqrt[3]{x} \leq 0:\\
\;\;\;\;\frac{1}{1 + \sqrt[3]{x} \cdot \left(t_0 + \sqrt[3]{x}\right)}\\

\mathbf{else}:\\
\;\;\;\;\sqrt[3]{{t_0}^{3}} - \sqrt[3]{x}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (-.f64 (cbrt.f64 (+.f64 x 1)) (cbrt.f64 x)) < 0.0

    1. Initial program 4.2%

      \[\sqrt[3]{x + 1} - \sqrt[3]{x} \]
    2. Step-by-step derivation
      1. flip3--4.2%

        \[\leadsto \color{blue}{\frac{{\left(\sqrt[3]{x + 1}\right)}^{3} - {\left(\sqrt[3]{x}\right)}^{3}}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)}} \]
      2. div-inv4.2%

        \[\leadsto \color{blue}{\left({\left(\sqrt[3]{x + 1}\right)}^{3} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)}} \]
      3. rem-cube-cbrt3.8%

        \[\leadsto \left(\color{blue}{\left(x + 1\right)} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      4. +-commutative3.8%

        \[\leadsto \left(\color{blue}{\left(1 + x\right)} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      5. rem-cube-cbrt4.2%

        \[\leadsto \left(\left(1 + x\right) - \color{blue}{x}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      6. associate--l+98.4%

        \[\leadsto \color{blue}{\left(1 + \left(x - x\right)\right)} \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
    3. Applied egg-rr43.1%

      \[\leadsto \color{blue}{\left(1 + \left(x - x\right)\right) \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)}} \]
    4. Step-by-step derivation
      1. +-inverses43.1%

        \[\leadsto \left(1 + \color{blue}{0}\right) \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)} \]
      2. metadata-eval43.1%

        \[\leadsto \color{blue}{1} \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)} \]
      3. *-lft-identity43.1%

        \[\leadsto \color{blue}{\frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)}} \]
      4. +-commutative43.1%

        \[\leadsto \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{\color{blue}{1 + x}} + \sqrt[3]{x}\right)} \]
    5. Simplified43.1%

      \[\leadsto \color{blue}{\frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)}} \]
    6. Taylor expanded in x around 0 20.0%

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

    if 0.0 < (-.f64 (cbrt.f64 (+.f64 x 1)) (cbrt.f64 x))

    1. Initial program 97.4%

      \[\sqrt[3]{x + 1} - \sqrt[3]{x} \]
    2. Step-by-step derivation
      1. pow1/395.4%

        \[\leadsto \color{blue}{{\left(x + 1\right)}^{0.3333333333333333}} - \sqrt[3]{x} \]
      2. pow-to-exp95.2%

        \[\leadsto \color{blue}{e^{\log \left(x + 1\right) \cdot 0.3333333333333333}} - \sqrt[3]{x} \]
      3. +-commutative95.2%

        \[\leadsto e^{\log \color{blue}{\left(1 + x\right)} \cdot 0.3333333333333333} - \sqrt[3]{x} \]
      4. log1p-def95.2%

        \[\leadsto e^{\color{blue}{\mathsf{log1p}\left(x\right)} \cdot 0.3333333333333333} - \sqrt[3]{x} \]
    3. Applied egg-rr95.2%

      \[\leadsto \color{blue}{e^{\mathsf{log1p}\left(x\right) \cdot 0.3333333333333333}} - \sqrt[3]{x} \]
    4. Step-by-step derivation
      1. exp-prod95.2%

        \[\leadsto \color{blue}{{\left(e^{\mathsf{log1p}\left(x\right)}\right)}^{0.3333333333333333}} - \sqrt[3]{x} \]
      2. unpow1/395.2%

        \[\leadsto \color{blue}{\sqrt[3]{e^{\mathsf{log1p}\left(x\right)}}} - \sqrt[3]{x} \]
    5. Simplified95.2%

      \[\leadsto \color{blue}{\sqrt[3]{e^{\mathsf{log1p}\left(x\right)}}} - \sqrt[3]{x} \]
    6. Step-by-step derivation
      1. log1p-udef95.1%

        \[\leadsto \sqrt[3]{e^{\color{blue}{\log \left(1 + x\right)}}} - \sqrt[3]{x} \]
      2. +-commutative95.1%

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

        \[\leadsto \sqrt[3]{\color{blue}{x + 1}} - \sqrt[3]{x} \]
      4. rem-cube-cbrt97.5%

        \[\leadsto \sqrt[3]{\color{blue}{{\left(\sqrt[3]{x + 1}\right)}^{3}}} - \sqrt[3]{x} \]
    7. Applied egg-rr97.5%

      \[\leadsto \sqrt[3]{\color{blue}{{\left(\sqrt[3]{x + 1}\right)}^{3}}} - \sqrt[3]{x} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification55.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\sqrt[3]{1 + x} - \sqrt[3]{x} \leq 0:\\ \;\;\;\;\frac{1}{1 + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt[3]{{\left(\sqrt[3]{1 + x}\right)}^{3}} - \sqrt[3]{x}\\ \end{array} \]

Alternative 5: 60.5% accurate, 0.3× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := \sqrt[3]{1 + x}\\ t_1 := t_0 - \sqrt[3]{x}\\ \mathbf{if}\;t_1 \leq 0:\\ \;\;\;\;\frac{1}{1 + \sqrt[3]{x} \cdot \left(t_0 + \sqrt[3]{x}\right)}\\ \mathbf{else}:\\ \;\;\;\;e^{\log t_1}\\ \end{array} \end{array} \]
(FPCore (x)
 :precision binary64
 (let* ((t_0 (cbrt (+ 1.0 x))) (t_1 (- t_0 (cbrt x))))
   (if (<= t_1 0.0)
     (/ 1.0 (+ 1.0 (* (cbrt x) (+ t_0 (cbrt x)))))
     (exp (log t_1)))))
double code(double x) {
	double t_0 = cbrt((1.0 + x));
	double t_1 = t_0 - cbrt(x);
	double tmp;
	if (t_1 <= 0.0) {
		tmp = 1.0 / (1.0 + (cbrt(x) * (t_0 + cbrt(x))));
	} else {
		tmp = exp(log(t_1));
	}
	return tmp;
}
public static double code(double x) {
	double t_0 = Math.cbrt((1.0 + x));
	double t_1 = t_0 - Math.cbrt(x);
	double tmp;
	if (t_1 <= 0.0) {
		tmp = 1.0 / (1.0 + (Math.cbrt(x) * (t_0 + Math.cbrt(x))));
	} else {
		tmp = Math.exp(Math.log(t_1));
	}
	return tmp;
}
function code(x)
	t_0 = cbrt(Float64(1.0 + x))
	t_1 = Float64(t_0 - cbrt(x))
	tmp = 0.0
	if (t_1 <= 0.0)
		tmp = Float64(1.0 / Float64(1.0 + Float64(cbrt(x) * Float64(t_0 + cbrt(x)))));
	else
		tmp = exp(log(t_1));
	end
	return tmp
end
code[x_] := Block[{t$95$0 = N[Power[N[(1.0 + x), $MachinePrecision], 1/3], $MachinePrecision]}, Block[{t$95$1 = N[(t$95$0 - N[Power[x, 1/3], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, 0.0], N[(1.0 / N[(1.0 + N[(N[Power[x, 1/3], $MachinePrecision] * N[(t$95$0 + N[Power[x, 1/3], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[Exp[N[Log[t$95$1], $MachinePrecision]], $MachinePrecision]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := \sqrt[3]{1 + x}\\
t_1 := t_0 - \sqrt[3]{x}\\
\mathbf{if}\;t_1 \leq 0:\\
\;\;\;\;\frac{1}{1 + \sqrt[3]{x} \cdot \left(t_0 + \sqrt[3]{x}\right)}\\

\mathbf{else}:\\
\;\;\;\;e^{\log t_1}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (-.f64 (cbrt.f64 (+.f64 x 1)) (cbrt.f64 x)) < 0.0

    1. Initial program 4.2%

      \[\sqrt[3]{x + 1} - \sqrt[3]{x} \]
    2. Step-by-step derivation
      1. flip3--4.2%

        \[\leadsto \color{blue}{\frac{{\left(\sqrt[3]{x + 1}\right)}^{3} - {\left(\sqrt[3]{x}\right)}^{3}}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)}} \]
      2. div-inv4.2%

        \[\leadsto \color{blue}{\left({\left(\sqrt[3]{x + 1}\right)}^{3} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)}} \]
      3. rem-cube-cbrt3.8%

        \[\leadsto \left(\color{blue}{\left(x + 1\right)} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      4. +-commutative3.8%

        \[\leadsto \left(\color{blue}{\left(1 + x\right)} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      5. rem-cube-cbrt4.2%

        \[\leadsto \left(\left(1 + x\right) - \color{blue}{x}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      6. associate--l+98.4%

        \[\leadsto \color{blue}{\left(1 + \left(x - x\right)\right)} \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
    3. Applied egg-rr43.1%

      \[\leadsto \color{blue}{\left(1 + \left(x - x\right)\right) \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)}} \]
    4. Step-by-step derivation
      1. +-inverses43.1%

        \[\leadsto \left(1 + \color{blue}{0}\right) \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)} \]
      2. metadata-eval43.1%

        \[\leadsto \color{blue}{1} \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)} \]
      3. *-lft-identity43.1%

        \[\leadsto \color{blue}{\frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)}} \]
      4. +-commutative43.1%

        \[\leadsto \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{\color{blue}{1 + x}} + \sqrt[3]{x}\right)} \]
    5. Simplified43.1%

      \[\leadsto \color{blue}{\frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)}} \]
    6. Taylor expanded in x around 0 20.0%

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

    if 0.0 < (-.f64 (cbrt.f64 (+.f64 x 1)) (cbrt.f64 x))

    1. Initial program 97.4%

      \[\sqrt[3]{x + 1} - \sqrt[3]{x} \]
    2. Step-by-step derivation
      1. add-exp-log97.4%

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

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

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

Alternative 6: 87.2% accurate, 0.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)\\ \mathbf{if}\;x \leq -1.35 \cdot 10^{+154}:\\ \;\;\;\;\frac{1}{1 + t_0}\\ \mathbf{elif}\;x \leq -1:\\ \;\;\;\;\frac{1}{t_0 + \sqrt[3]{{x}^{2}}}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{t_0 + {\left(1 + x\right)}^{0.6666666666666666}}\\ \end{array} \end{array} \]
(FPCore (x)
 :precision binary64
 (let* ((t_0 (* (cbrt x) (+ (cbrt (+ 1.0 x)) (cbrt x)))))
   (if (<= x -1.35e+154)
     (/ 1.0 (+ 1.0 t_0))
     (if (<= x -1.0)
       (/ 1.0 (+ t_0 (cbrt (pow x 2.0))))
       (/ 1.0 (+ t_0 (pow (+ 1.0 x) 0.6666666666666666)))))))
double code(double x) {
	double t_0 = cbrt(x) * (cbrt((1.0 + x)) + cbrt(x));
	double tmp;
	if (x <= -1.35e+154) {
		tmp = 1.0 / (1.0 + t_0);
	} else if (x <= -1.0) {
		tmp = 1.0 / (t_0 + cbrt(pow(x, 2.0)));
	} else {
		tmp = 1.0 / (t_0 + pow((1.0 + x), 0.6666666666666666));
	}
	return tmp;
}
public static double code(double x) {
	double t_0 = Math.cbrt(x) * (Math.cbrt((1.0 + x)) + Math.cbrt(x));
	double tmp;
	if (x <= -1.35e+154) {
		tmp = 1.0 / (1.0 + t_0);
	} else if (x <= -1.0) {
		tmp = 1.0 / (t_0 + Math.cbrt(Math.pow(x, 2.0)));
	} else {
		tmp = 1.0 / (t_0 + Math.pow((1.0 + x), 0.6666666666666666));
	}
	return tmp;
}
function code(x)
	t_0 = Float64(cbrt(x) * Float64(cbrt(Float64(1.0 + x)) + cbrt(x)))
	tmp = 0.0
	if (x <= -1.35e+154)
		tmp = Float64(1.0 / Float64(1.0 + t_0));
	elseif (x <= -1.0)
		tmp = Float64(1.0 / Float64(t_0 + cbrt((x ^ 2.0))));
	else
		tmp = Float64(1.0 / Float64(t_0 + (Float64(1.0 + x) ^ 0.6666666666666666)));
	end
	return tmp
end
code[x_] := Block[{t$95$0 = N[(N[Power[x, 1/3], $MachinePrecision] * N[(N[Power[N[(1.0 + x), $MachinePrecision], 1/3], $MachinePrecision] + N[Power[x, 1/3], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -1.35e+154], N[(1.0 / N[(1.0 + t$95$0), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, -1.0], N[(1.0 / N[(t$95$0 + N[Power[N[Power[x, 2.0], $MachinePrecision], 1/3], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(1.0 / N[(t$95$0 + N[Power[N[(1.0 + x), $MachinePrecision], 0.6666666666666666], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)\\
\mathbf{if}\;x \leq -1.35 \cdot 10^{+154}:\\
\;\;\;\;\frac{1}{1 + t_0}\\

\mathbf{elif}\;x \leq -1:\\
\;\;\;\;\frac{1}{t_0 + \sqrt[3]{{x}^{2}}}\\

\mathbf{else}:\\
\;\;\;\;\frac{1}{t_0 + {\left(1 + x\right)}^{0.6666666666666666}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if x < -1.35000000000000003e154

    1. Initial program 4.9%

      \[\sqrt[3]{x + 1} - \sqrt[3]{x} \]
    2. Step-by-step derivation
      1. flip3--4.9%

        \[\leadsto \color{blue}{\frac{{\left(\sqrt[3]{x + 1}\right)}^{3} - {\left(\sqrt[3]{x}\right)}^{3}}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)}} \]
      2. div-inv4.9%

        \[\leadsto \color{blue}{\left({\left(\sqrt[3]{x + 1}\right)}^{3} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)}} \]
      3. rem-cube-cbrt3.7%

        \[\leadsto \left(\color{blue}{\left(x + 1\right)} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      4. +-commutative3.7%

        \[\leadsto \left(\color{blue}{\left(1 + x\right)} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      5. rem-cube-cbrt4.9%

        \[\leadsto \left(\left(1 + x\right) - \color{blue}{x}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      6. associate--l+98.5%

        \[\leadsto \color{blue}{\left(1 + \left(x - x\right)\right)} \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
    3. Applied egg-rr0.0%

      \[\leadsto \color{blue}{\left(1 + \left(x - x\right)\right) \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)}} \]
    4. Step-by-step derivation
      1. +-inverses0.0%

        \[\leadsto \left(1 + \color{blue}{0}\right) \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)} \]
      2. metadata-eval0.0%

        \[\leadsto \color{blue}{1} \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)} \]
      3. *-lft-identity0.0%

        \[\leadsto \color{blue}{\frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)}} \]
      4. +-commutative0.0%

        \[\leadsto \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{\color{blue}{1 + x}} + \sqrt[3]{x}\right)} \]
    5. Simplified0.0%

      \[\leadsto \color{blue}{\frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)}} \]
    6. Taylor expanded in x around 0 20.0%

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

    if -1.35000000000000003e154 < x < -1

    1. Initial program 8.8%

      \[\sqrt[3]{x + 1} - \sqrt[3]{x} \]
    2. Step-by-step derivation
      1. flip3--8.8%

        \[\leadsto \color{blue}{\frac{{\left(\sqrt[3]{x + 1}\right)}^{3} - {\left(\sqrt[3]{x}\right)}^{3}}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)}} \]
      2. div-inv8.8%

        \[\leadsto \color{blue}{\left({\left(\sqrt[3]{x + 1}\right)}^{3} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)}} \]
      3. rem-cube-cbrt10.9%

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

        \[\leadsto \left(\color{blue}{\left(1 + x\right)} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      5. rem-cube-cbrt12.1%

        \[\leadsto \left(\left(1 + x\right) - \color{blue}{x}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      6. associate--l+98.3%

        \[\leadsto \color{blue}{\left(1 + \left(x - x\right)\right)} \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
    3. Applied egg-rr0.0%

      \[\leadsto \color{blue}{\left(1 + \left(x - x\right)\right) \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)}} \]
    4. Step-by-step derivation
      1. +-inverses0.0%

        \[\leadsto \left(1 + \color{blue}{0}\right) \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)} \]
      2. metadata-eval0.0%

        \[\leadsto \color{blue}{1} \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)} \]
      3. *-lft-identity0.0%

        \[\leadsto \color{blue}{\frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)}} \]
      4. +-commutative0.0%

        \[\leadsto \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{\color{blue}{1 + x}} + \sqrt[3]{x}\right)} \]
    5. Simplified0.0%

      \[\leadsto \color{blue}{\frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)}} \]
    6. Taylor expanded in x around inf 90.4%

      \[\leadsto \frac{1}{\color{blue}{{\left({x}^{2}\right)}^{0.3333333333333333}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
    7. Step-by-step derivation
      1. unpow1/395.0%

        \[\leadsto \frac{1}{\color{blue}{\sqrt[3]{{x}^{2}}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
    8. Simplified95.0%

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

    if -1 < x

    1. Initial program 64.7%

      \[\sqrt[3]{x + 1} - \sqrt[3]{x} \]
    2. Step-by-step derivation
      1. flip3--64.7%

        \[\leadsto \color{blue}{\frac{{\left(\sqrt[3]{x + 1}\right)}^{3} - {\left(\sqrt[3]{x}\right)}^{3}}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)}} \]
      2. div-inv64.7%

        \[\leadsto \color{blue}{\left({\left(\sqrt[3]{x + 1}\right)}^{3} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)}} \]
      3. rem-cube-cbrt64.4%

        \[\leadsto \left(\color{blue}{\left(x + 1\right)} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      4. +-commutative64.4%

        \[\leadsto \left(\color{blue}{\left(1 + x\right)} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      5. rem-cube-cbrt65.4%

        \[\leadsto \left(\left(1 + x\right) - \color{blue}{x}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      6. associate--l+99.3%

        \[\leadsto \color{blue}{\left(1 + \left(x - x\right)\right)} \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
    3. Applied egg-rr97.4%

      \[\leadsto \color{blue}{\left(1 + \left(x - x\right)\right) \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)}} \]
    4. Step-by-step derivation
      1. +-inverses97.4%

        \[\leadsto \left(1 + \color{blue}{0}\right) \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)} \]
      2. metadata-eval97.4%

        \[\leadsto \color{blue}{1} \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)} \]
      3. *-lft-identity97.4%

        \[\leadsto \color{blue}{\frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)}} \]
      4. +-commutative97.4%

        \[\leadsto \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{\color{blue}{1 + x}} + \sqrt[3]{x}\right)} \]
    5. Simplified97.4%

      \[\leadsto \color{blue}{\frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)}} \]
    6. Step-by-step derivation
      1. log1p-udef97.4%

        \[\leadsto \frac{1}{e^{\color{blue}{\log \left(1 + x\right)} \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
      2. +-commutative97.4%

        \[\leadsto \frac{1}{e^{\log \color{blue}{\left(x + 1\right)} \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
      3. exp-to-pow97.3%

        \[\leadsto \frac{1}{\color{blue}{{\left(x + 1\right)}^{0.6666666666666666}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
    7. Applied egg-rr97.3%

      \[\leadsto \frac{1}{\color{blue}{{\left(x + 1\right)}^{0.6666666666666666}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification86.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq -1.35 \cdot 10^{+154}:\\ \;\;\;\;\frac{1}{1 + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)}\\ \mathbf{elif}\;x \leq -1:\\ \;\;\;\;\frac{1}{\sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right) + \sqrt[3]{{x}^{2}}}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{\sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right) + {\left(1 + x\right)}^{0.6666666666666666}}\\ \end{array} \]

Alternative 7: 60.5% accurate, 0.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := \sqrt[3]{1 + x}\\ t_1 := t_0 - \sqrt[3]{x}\\ \mathbf{if}\;t_1 \leq 0:\\ \;\;\;\;\frac{1}{1 + \sqrt[3]{x} \cdot \left(t_0 + \sqrt[3]{x}\right)}\\ \mathbf{else}:\\ \;\;\;\;t_1\\ \end{array} \end{array} \]
(FPCore (x)
 :precision binary64
 (let* ((t_0 (cbrt (+ 1.0 x))) (t_1 (- t_0 (cbrt x))))
   (if (<= t_1 0.0) (/ 1.0 (+ 1.0 (* (cbrt x) (+ t_0 (cbrt x))))) t_1)))
double code(double x) {
	double t_0 = cbrt((1.0 + x));
	double t_1 = t_0 - cbrt(x);
	double tmp;
	if (t_1 <= 0.0) {
		tmp = 1.0 / (1.0 + (cbrt(x) * (t_0 + cbrt(x))));
	} else {
		tmp = t_1;
	}
	return tmp;
}
public static double code(double x) {
	double t_0 = Math.cbrt((1.0 + x));
	double t_1 = t_0 - Math.cbrt(x);
	double tmp;
	if (t_1 <= 0.0) {
		tmp = 1.0 / (1.0 + (Math.cbrt(x) * (t_0 + Math.cbrt(x))));
	} else {
		tmp = t_1;
	}
	return tmp;
}
function code(x)
	t_0 = cbrt(Float64(1.0 + x))
	t_1 = Float64(t_0 - cbrt(x))
	tmp = 0.0
	if (t_1 <= 0.0)
		tmp = Float64(1.0 / Float64(1.0 + Float64(cbrt(x) * Float64(t_0 + cbrt(x)))));
	else
		tmp = t_1;
	end
	return tmp
end
code[x_] := Block[{t$95$0 = N[Power[N[(1.0 + x), $MachinePrecision], 1/3], $MachinePrecision]}, Block[{t$95$1 = N[(t$95$0 - N[Power[x, 1/3], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, 0.0], N[(1.0 / N[(1.0 + N[(N[Power[x, 1/3], $MachinePrecision] * N[(t$95$0 + N[Power[x, 1/3], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := \sqrt[3]{1 + x}\\
t_1 := t_0 - \sqrt[3]{x}\\
\mathbf{if}\;t_1 \leq 0:\\
\;\;\;\;\frac{1}{1 + \sqrt[3]{x} \cdot \left(t_0 + \sqrt[3]{x}\right)}\\

\mathbf{else}:\\
\;\;\;\;t_1\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if (-.f64 (cbrt.f64 (+.f64 x 1)) (cbrt.f64 x)) < 0.0

    1. Initial program 4.2%

      \[\sqrt[3]{x + 1} - \sqrt[3]{x} \]
    2. Step-by-step derivation
      1. flip3--4.2%

        \[\leadsto \color{blue}{\frac{{\left(\sqrt[3]{x + 1}\right)}^{3} - {\left(\sqrt[3]{x}\right)}^{3}}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)}} \]
      2. div-inv4.2%

        \[\leadsto \color{blue}{\left({\left(\sqrt[3]{x + 1}\right)}^{3} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)}} \]
      3. rem-cube-cbrt3.8%

        \[\leadsto \left(\color{blue}{\left(x + 1\right)} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      4. +-commutative3.8%

        \[\leadsto \left(\color{blue}{\left(1 + x\right)} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      5. rem-cube-cbrt4.2%

        \[\leadsto \left(\left(1 + x\right) - \color{blue}{x}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      6. associate--l+98.4%

        \[\leadsto \color{blue}{\left(1 + \left(x - x\right)\right)} \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
    3. Applied egg-rr43.1%

      \[\leadsto \color{blue}{\left(1 + \left(x - x\right)\right) \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)}} \]
    4. Step-by-step derivation
      1. +-inverses43.1%

        \[\leadsto \left(1 + \color{blue}{0}\right) \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)} \]
      2. metadata-eval43.1%

        \[\leadsto \color{blue}{1} \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)} \]
      3. *-lft-identity43.1%

        \[\leadsto \color{blue}{\frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)}} \]
      4. +-commutative43.1%

        \[\leadsto \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{\color{blue}{1 + x}} + \sqrt[3]{x}\right)} \]
    5. Simplified43.1%

      \[\leadsto \color{blue}{\frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)}} \]
    6. Taylor expanded in x around 0 20.0%

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

    if 0.0 < (-.f64 (cbrt.f64 (+.f64 x 1)) (cbrt.f64 x))

    1. Initial program 97.4%

      \[\sqrt[3]{x + 1} - \sqrt[3]{x} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification55.7%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\sqrt[3]{1 + x} - \sqrt[3]{x} \leq 0:\\ \;\;\;\;\frac{1}{1 + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt[3]{1 + x} - \sqrt[3]{x}\\ \end{array} \]

Alternative 8: 99.1% accurate, 0.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := \sqrt[3]{1 + x}\\ \frac{1}{{t_0}^{2} + \sqrt[3]{x} \cdot \left(t_0 + \sqrt[3]{x}\right)} \end{array} \end{array} \]
(FPCore (x)
 :precision binary64
 (let* ((t_0 (cbrt (+ 1.0 x))))
   (/ 1.0 (+ (pow t_0 2.0) (* (cbrt x) (+ t_0 (cbrt x)))))))
double code(double x) {
	double t_0 = cbrt((1.0 + x));
	return 1.0 / (pow(t_0, 2.0) + (cbrt(x) * (t_0 + cbrt(x))));
}
public static double code(double x) {
	double t_0 = Math.cbrt((1.0 + x));
	return 1.0 / (Math.pow(t_0, 2.0) + (Math.cbrt(x) * (t_0 + Math.cbrt(x))));
}
function code(x)
	t_0 = cbrt(Float64(1.0 + x))
	return Float64(1.0 / Float64((t_0 ^ 2.0) + Float64(cbrt(x) * Float64(t_0 + cbrt(x)))))
end
code[x_] := Block[{t$95$0 = N[Power[N[(1.0 + x), $MachinePrecision], 1/3], $MachinePrecision]}, N[(1.0 / N[(N[Power[t$95$0, 2.0], $MachinePrecision] + N[(N[Power[x, 1/3], $MachinePrecision] * N[(t$95$0 + N[Power[x, 1/3], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := \sqrt[3]{1 + x}\\
\frac{1}{{t_0}^{2} + \sqrt[3]{x} \cdot \left(t_0 + \sqrt[3]{x}\right)}
\end{array}
\end{array}
Derivation
  1. Initial program 47.2%

    \[\sqrt[3]{x + 1} - \sqrt[3]{x} \]
  2. Step-by-step derivation
    1. flip3--47.2%

      \[\leadsto \color{blue}{\frac{{\left(\sqrt[3]{x + 1}\right)}^{3} - {\left(\sqrt[3]{x}\right)}^{3}}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)}} \]
    2. div-inv47.2%

      \[\leadsto \color{blue}{\left({\left(\sqrt[3]{x + 1}\right)}^{3} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)}} \]
    3. rem-cube-cbrt47.2%

      \[\leadsto \left(\color{blue}{\left(x + 1\right)} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
    4. +-commutative47.2%

      \[\leadsto \left(\color{blue}{\left(1 + x\right)} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
    5. rem-cube-cbrt48.3%

      \[\leadsto \left(\left(1 + x\right) - \color{blue}{x}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
    6. associate--l+99.0%

      \[\leadsto \color{blue}{\left(1 + \left(x - x\right)\right)} \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
  3. Applied egg-rr67.7%

    \[\leadsto \color{blue}{\left(1 + \left(x - x\right)\right) \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)}} \]
  4. Step-by-step derivation
    1. +-inverses67.7%

      \[\leadsto \left(1 + \color{blue}{0}\right) \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)} \]
    2. metadata-eval67.7%

      \[\leadsto \color{blue}{1} \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)} \]
    3. *-lft-identity67.7%

      \[\leadsto \color{blue}{\frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)}} \]
    4. +-commutative67.7%

      \[\leadsto \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{\color{blue}{1 + x}} + \sqrt[3]{x}\right)} \]
  5. Simplified67.7%

    \[\leadsto \color{blue}{\frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)}} \]
  6. Step-by-step derivation
    1. log1p-udef67.7%

      \[\leadsto \frac{1}{e^{\color{blue}{\log \left(1 + x\right)} \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
    2. +-commutative67.7%

      \[\leadsto \frac{1}{e^{\log \color{blue}{\left(x + 1\right)} \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
    3. exp-to-pow67.7%

      \[\leadsto \frac{1}{\color{blue}{{\left(x + 1\right)}^{0.6666666666666666}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
    4. metadata-eval67.7%

      \[\leadsto \frac{1}{{\left(x + 1\right)}^{\color{blue}{\left(2 \cdot 0.3333333333333333\right)}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
    5. pow-sqr67.7%

      \[\leadsto \frac{1}{\color{blue}{{\left(x + 1\right)}^{0.3333333333333333} \cdot {\left(x + 1\right)}^{0.3333333333333333}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
    6. pow1/368.0%

      \[\leadsto \frac{1}{\color{blue}{\sqrt[3]{x + 1}} \cdot {\left(x + 1\right)}^{0.3333333333333333} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
    7. pow1/399.0%

      \[\leadsto \frac{1}{\sqrt[3]{x + 1} \cdot \color{blue}{\sqrt[3]{x + 1}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
    8. pow299.0%

      \[\leadsto \frac{1}{\color{blue}{{\left(\sqrt[3]{x + 1}\right)}^{2}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
  7. Applied egg-rr99.0%

    \[\leadsto \frac{1}{\color{blue}{{\left(\sqrt[3]{x + 1}\right)}^{2}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
  8. Final simplification99.0%

    \[\leadsto \frac{1}{{\left(\sqrt[3]{1 + x}\right)}^{2} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]

Alternative 9: 77.8% accurate, 0.5× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_0 := \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)\\ \mathbf{if}\;x \leq -1:\\ \;\;\;\;\frac{1}{1 + t_0}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{t_0 + {\left(1 + x\right)}^{0.6666666666666666}}\\ \end{array} \end{array} \]
(FPCore (x)
 :precision binary64
 (let* ((t_0 (* (cbrt x) (+ (cbrt (+ 1.0 x)) (cbrt x)))))
   (if (<= x -1.0)
     (/ 1.0 (+ 1.0 t_0))
     (/ 1.0 (+ t_0 (pow (+ 1.0 x) 0.6666666666666666))))))
double code(double x) {
	double t_0 = cbrt(x) * (cbrt((1.0 + x)) + cbrt(x));
	double tmp;
	if (x <= -1.0) {
		tmp = 1.0 / (1.0 + t_0);
	} else {
		tmp = 1.0 / (t_0 + pow((1.0 + x), 0.6666666666666666));
	}
	return tmp;
}
public static double code(double x) {
	double t_0 = Math.cbrt(x) * (Math.cbrt((1.0 + x)) + Math.cbrt(x));
	double tmp;
	if (x <= -1.0) {
		tmp = 1.0 / (1.0 + t_0);
	} else {
		tmp = 1.0 / (t_0 + Math.pow((1.0 + x), 0.6666666666666666));
	}
	return tmp;
}
function code(x)
	t_0 = Float64(cbrt(x) * Float64(cbrt(Float64(1.0 + x)) + cbrt(x)))
	tmp = 0.0
	if (x <= -1.0)
		tmp = Float64(1.0 / Float64(1.0 + t_0));
	else
		tmp = Float64(1.0 / Float64(t_0 + (Float64(1.0 + x) ^ 0.6666666666666666)));
	end
	return tmp
end
code[x_] := Block[{t$95$0 = N[(N[Power[x, 1/3], $MachinePrecision] * N[(N[Power[N[(1.0 + x), $MachinePrecision], 1/3], $MachinePrecision] + N[Power[x, 1/3], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -1.0], N[(1.0 / N[(1.0 + t$95$0), $MachinePrecision]), $MachinePrecision], N[(1.0 / N[(t$95$0 + N[Power[N[(1.0 + x), $MachinePrecision], 0.6666666666666666], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}

\\
\begin{array}{l}
t_0 := \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)\\
\mathbf{if}\;x \leq -1:\\
\;\;\;\;\frac{1}{1 + t_0}\\

\mathbf{else}:\\
\;\;\;\;\frac{1}{t_0 + {\left(1 + x\right)}^{0.6666666666666666}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if x < -1

    1. Initial program 7.2%

      \[\sqrt[3]{x + 1} - \sqrt[3]{x} \]
    2. Step-by-step derivation
      1. flip3--7.2%

        \[\leadsto \color{blue}{\frac{{\left(\sqrt[3]{x + 1}\right)}^{3} - {\left(\sqrt[3]{x}\right)}^{3}}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)}} \]
      2. div-inv7.2%

        \[\leadsto \color{blue}{\left({\left(\sqrt[3]{x + 1}\right)}^{3} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)}} \]
      3. rem-cube-cbrt7.9%

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

        \[\leadsto \left(\color{blue}{\left(1 + x\right)} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      5. rem-cube-cbrt9.0%

        \[\leadsto \left(\left(1 + x\right) - \color{blue}{x}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      6. associate--l+98.4%

        \[\leadsto \color{blue}{\left(1 + \left(x - x\right)\right)} \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
    3. Applied egg-rr0.0%

      \[\leadsto \color{blue}{\left(1 + \left(x - x\right)\right) \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)}} \]
    4. Step-by-step derivation
      1. +-inverses0.0%

        \[\leadsto \left(1 + \color{blue}{0}\right) \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)} \]
      2. metadata-eval0.0%

        \[\leadsto \color{blue}{1} \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)} \]
      3. *-lft-identity0.0%

        \[\leadsto \color{blue}{\frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)}} \]
      4. +-commutative0.0%

        \[\leadsto \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{\color{blue}{1 + x}} + \sqrt[3]{x}\right)} \]
    5. Simplified0.0%

      \[\leadsto \color{blue}{\frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)}} \]
    6. Taylor expanded in x around 0 20.0%

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

    if -1 < x

    1. Initial program 64.7%

      \[\sqrt[3]{x + 1} - \sqrt[3]{x} \]
    2. Step-by-step derivation
      1. flip3--64.7%

        \[\leadsto \color{blue}{\frac{{\left(\sqrt[3]{x + 1}\right)}^{3} - {\left(\sqrt[3]{x}\right)}^{3}}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)}} \]
      2. div-inv64.7%

        \[\leadsto \color{blue}{\left({\left(\sqrt[3]{x + 1}\right)}^{3} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)}} \]
      3. rem-cube-cbrt64.4%

        \[\leadsto \left(\color{blue}{\left(x + 1\right)} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      4. +-commutative64.4%

        \[\leadsto \left(\color{blue}{\left(1 + x\right)} - {\left(\sqrt[3]{x}\right)}^{3}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      5. rem-cube-cbrt65.4%

        \[\leadsto \left(\left(1 + x\right) - \color{blue}{x}\right) \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
      6. associate--l+99.3%

        \[\leadsto \color{blue}{\left(1 + \left(x - x\right)\right)} \cdot \frac{1}{\sqrt[3]{x + 1} \cdot \sqrt[3]{x + 1} + \left(\sqrt[3]{x} \cdot \sqrt[3]{x} + \sqrt[3]{x + 1} \cdot \sqrt[3]{x}\right)} \]
    3. Applied egg-rr97.4%

      \[\leadsto \color{blue}{\left(1 + \left(x - x\right)\right) \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)}} \]
    4. Step-by-step derivation
      1. +-inverses97.4%

        \[\leadsto \left(1 + \color{blue}{0}\right) \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)} \]
      2. metadata-eval97.4%

        \[\leadsto \color{blue}{1} \cdot \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)} \]
      3. *-lft-identity97.4%

        \[\leadsto \color{blue}{\frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{x + 1} + \sqrt[3]{x}\right)}} \]
      4. +-commutative97.4%

        \[\leadsto \frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{\color{blue}{1 + x}} + \sqrt[3]{x}\right)} \]
    5. Simplified97.4%

      \[\leadsto \color{blue}{\frac{1}{e^{\mathsf{log1p}\left(x\right) \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)}} \]
    6. Step-by-step derivation
      1. log1p-udef97.4%

        \[\leadsto \frac{1}{e^{\color{blue}{\log \left(1 + x\right)} \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
      2. +-commutative97.4%

        \[\leadsto \frac{1}{e^{\log \color{blue}{\left(x + 1\right)} \cdot 0.6666666666666666} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
      3. exp-to-pow97.3%

        \[\leadsto \frac{1}{\color{blue}{{\left(x + 1\right)}^{0.6666666666666666}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
    7. Applied egg-rr97.3%

      \[\leadsto \frac{1}{\color{blue}{{\left(x + 1\right)}^{0.6666666666666666}} + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification73.8%

    \[\leadsto \begin{array}{l} \mathbf{if}\;x \leq -1:\\ \;\;\;\;\frac{1}{1 + \sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right)}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{\sqrt[3]{x} \cdot \left(\sqrt[3]{1 + x} + \sqrt[3]{x}\right) + {\left(1 + x\right)}^{0.6666666666666666}}\\ \end{array} \]

Alternative 10: 52.9% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \sqrt[3]{1 + x} - \sqrt[3]{x} \end{array} \]
(FPCore (x) :precision binary64 (- (cbrt (+ 1.0 x)) (cbrt x)))
double code(double x) {
	return cbrt((1.0 + x)) - cbrt(x);
}
public static double code(double x) {
	return Math.cbrt((1.0 + x)) - Math.cbrt(x);
}
function code(x)
	return Float64(cbrt(Float64(1.0 + x)) - cbrt(x))
end
code[x_] := N[(N[Power[N[(1.0 + x), $MachinePrecision], 1/3], $MachinePrecision] - N[Power[x, 1/3], $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
\sqrt[3]{1 + x} - \sqrt[3]{x}
\end{array}
Derivation
  1. Initial program 47.2%

    \[\sqrt[3]{x + 1} - \sqrt[3]{x} \]
  2. Final simplification47.2%

    \[\leadsto \sqrt[3]{1 + x} - \sqrt[3]{x} \]

Alternative 11: 50.3% accurate, 1.9× speedup?

\[\begin{array}{l} \\ 1 + \left(x \cdot 0.3333333333333333 - \sqrt[3]{x}\right) \end{array} \]
(FPCore (x) :precision binary64 (+ 1.0 (- (* x 0.3333333333333333) (cbrt x))))
double code(double x) {
	return 1.0 + ((x * 0.3333333333333333) - cbrt(x));
}
public static double code(double x) {
	return 1.0 + ((x * 0.3333333333333333) - Math.cbrt(x));
}
function code(x)
	return Float64(1.0 + Float64(Float64(x * 0.3333333333333333) - cbrt(x)))
end
code[x_] := N[(1.0 + N[(N[(x * 0.3333333333333333), $MachinePrecision] - N[Power[x, 1/3], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
1 + \left(x \cdot 0.3333333333333333 - \sqrt[3]{x}\right)
\end{array}
Derivation
  1. Initial program 47.2%

    \[\sqrt[3]{x + 1} - \sqrt[3]{x} \]
  2. Step-by-step derivation
    1. add-cube-cbrt47.0%

      \[\leadsto \sqrt[3]{x + 1} - \color{blue}{\left(\sqrt[3]{\sqrt[3]{x}} \cdot \sqrt[3]{\sqrt[3]{x}}\right) \cdot \sqrt[3]{\sqrt[3]{x}}} \]
    2. pow347.0%

      \[\leadsto \sqrt[3]{x + 1} - \color{blue}{{\left(\sqrt[3]{\sqrt[3]{x}}\right)}^{3}} \]
  3. Applied egg-rr47.0%

    \[\leadsto \sqrt[3]{x + 1} - \color{blue}{{\left(\sqrt[3]{\sqrt[3]{x}}\right)}^{3}} \]
  4. Taylor expanded in x around 0 20.5%

    \[\leadsto \color{blue}{\left(1 + 0.3333333333333333 \cdot x\right) - {\left({1}^{4}\right)}^{0.1111111111111111} \cdot {x}^{0.3333333333333333}} \]
  5. Step-by-step derivation
    1. associate--l+20.5%

      \[\leadsto \color{blue}{1 + \left(0.3333333333333333 \cdot x - {\left({1}^{4}\right)}^{0.1111111111111111} \cdot {x}^{0.3333333333333333}\right)} \]
    2. *-commutative20.5%

      \[\leadsto 1 + \left(\color{blue}{x \cdot 0.3333333333333333} - {\left({1}^{4}\right)}^{0.1111111111111111} \cdot {x}^{0.3333333333333333}\right) \]
    3. metadata-eval20.5%

      \[\leadsto 1 + \left(x \cdot 0.3333333333333333 - {\color{blue}{1}}^{0.1111111111111111} \cdot {x}^{0.3333333333333333}\right) \]
    4. pow-base-120.5%

      \[\leadsto 1 + \left(x \cdot 0.3333333333333333 - \color{blue}{1} \cdot {x}^{0.3333333333333333}\right) \]
    5. unpow1/344.6%

      \[\leadsto 1 + \left(x \cdot 0.3333333333333333 - 1 \cdot \color{blue}{\sqrt[3]{x}}\right) \]
    6. *-lft-identity44.6%

      \[\leadsto 1 + \left(x \cdot 0.3333333333333333 - \color{blue}{\sqrt[3]{x}}\right) \]
  6. Simplified44.6%

    \[\leadsto \color{blue}{1 + \left(x \cdot 0.3333333333333333 - \sqrt[3]{x}\right)} \]
  7. Final simplification44.6%

    \[\leadsto 1 + \left(x \cdot 0.3333333333333333 - \sqrt[3]{x}\right) \]

Alternative 12: 50.2% accurate, 2.0× speedup?

\[\begin{array}{l} \\ 1 - \sqrt[3]{x} \end{array} \]
(FPCore (x) :precision binary64 (- 1.0 (cbrt x)))
double code(double x) {
	return 1.0 - cbrt(x);
}
public static double code(double x) {
	return 1.0 - Math.cbrt(x);
}
function code(x)
	return Float64(1.0 - cbrt(x))
end
code[x_] := N[(1.0 - N[Power[x, 1/3], $MachinePrecision]), $MachinePrecision]
\begin{array}{l}

\\
1 - \sqrt[3]{x}
\end{array}
Derivation
  1. Initial program 47.2%

    \[\sqrt[3]{x + 1} - \sqrt[3]{x} \]
  2. Step-by-step derivation
    1. add-cube-cbrt47.0%

      \[\leadsto \sqrt[3]{x + 1} - \color{blue}{\left(\sqrt[3]{\sqrt[3]{x}} \cdot \sqrt[3]{\sqrt[3]{x}}\right) \cdot \sqrt[3]{\sqrt[3]{x}}} \]
    2. pow347.0%

      \[\leadsto \sqrt[3]{x + 1} - \color{blue}{{\left(\sqrt[3]{\sqrt[3]{x}}\right)}^{3}} \]
  3. Applied egg-rr47.0%

    \[\leadsto \sqrt[3]{x + 1} - \color{blue}{{\left(\sqrt[3]{\sqrt[3]{x}}\right)}^{3}} \]
  4. Taylor expanded in x around 0 19.6%

    \[\leadsto \color{blue}{1 - {\left({1}^{4}\right)}^{0.1111111111111111} \cdot {x}^{0.3333333333333333}} \]
  5. Step-by-step derivation
    1. metadata-eval19.6%

      \[\leadsto 1 - {\color{blue}{1}}^{0.1111111111111111} \cdot {x}^{0.3333333333333333} \]
    2. pow-base-119.6%

      \[\leadsto 1 - \color{blue}{1} \cdot {x}^{0.3333333333333333} \]
    3. unpow1/344.5%

      \[\leadsto 1 - 1 \cdot \color{blue}{\sqrt[3]{x}} \]
    4. *-lft-identity44.5%

      \[\leadsto 1 - \color{blue}{\sqrt[3]{x}} \]
  6. Simplified44.5%

    \[\leadsto \color{blue}{1 - \sqrt[3]{x}} \]
  7. Final simplification44.5%

    \[\leadsto 1 - \sqrt[3]{x} \]

Alternative 13: 3.6% accurate, 205.0× speedup?

\[\begin{array}{l} \\ 0 \end{array} \]
(FPCore (x) :precision binary64 0.0)
double code(double x) {
	return 0.0;
}
real(8) function code(x)
    real(8), intent (in) :: x
    code = 0.0d0
end function
public static double code(double x) {
	return 0.0;
}
def code(x):
	return 0.0
function code(x)
	return 0.0
end
function tmp = code(x)
	tmp = 0.0;
end
code[x_] := 0.0
\begin{array}{l}

\\
0
\end{array}
Derivation
  1. Initial program 47.2%

    \[\sqrt[3]{x + 1} - \sqrt[3]{x} \]
  2. Taylor expanded in x around inf 3.7%

    \[\leadsto \color{blue}{0} \]
  3. Final simplification3.7%

    \[\leadsto 0 \]

Alternative 14: 49.3% accurate, 205.0× speedup?

\[\begin{array}{l} \\ 1 \end{array} \]
(FPCore (x) :precision binary64 1.0)
double code(double x) {
	return 1.0;
}
real(8) function code(x)
    real(8), intent (in) :: x
    code = 1.0d0
end function
public static double code(double x) {
	return 1.0;
}
def code(x):
	return 1.0
function code(x)
	return 1.0
end
function tmp = code(x)
	tmp = 1.0;
end
code[x_] := 1.0
\begin{array}{l}

\\
1
\end{array}
Derivation
  1. Initial program 47.2%

    \[\sqrt[3]{x + 1} - \sqrt[3]{x} \]
  2. Taylor expanded in x around 0 44.0%

    \[\leadsto \color{blue}{1} \]
  3. Final simplification44.0%

    \[\leadsto 1 \]

Reproduce

?
herbie shell --seed 2023336 
(FPCore (x)
  :name "2cbrt (problem 3.3.4)"
  :precision binary64
  (- (cbrt (+ x 1.0)) (cbrt x)))