?

Average Accuracy: 52.9% → 99.2%
Time: 7.9s
Precision: binary64
Cost: 33088

?

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

Error?

Try it out?

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation?

  1. Initial program 59.9%

    \[\sqrt[3]{x + 1} - \sqrt[3]{x} \]
  2. Applied egg-rr61.3%

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

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

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

    \[\leadsto \frac{1}{\mathsf{fma}\left(\sqrt[3]{x}, \sqrt[3]{1 + x} + \sqrt[3]{x}, \color{blue}{{\left(\sqrt[3]{1 + x}\right)}^{2}}\right)} \]
  6. Applied egg-rr79.1%

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

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

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

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

Alternatives

Alternative 1
Accuracy60.5%
Cost39236
\[\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(\sqrt[3]{x} + t_0\right)}\\ \mathbf{else}:\\ \;\;\;\;{\left({t_1}^{3}\right)}^{0.3333333333333333}\\ \end{array} \]
Alternative 2
Accuracy60.5%
Cost33092
\[\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(\sqrt[3]{x} + t_0\right)}\\ \mathbf{else}:\\ \;\;\;\;\left(1 + \left(t_0 + -1\right)\right) - \sqrt[3]{x}\\ \end{array} \]
Alternative 3
Accuracy86.5%
Cost32964
\[\begin{array}{l} t_0 := \sqrt[3]{x} \cdot \left(\sqrt[3]{x} + \sqrt[3]{1 + x}\right)\\ \mathbf{if}\;x \leq -1:\\ \;\;\;\;\frac{1}{t_0 + \sqrt[3]{x \cdot x}}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{t_0 + e^{0.6666666666666666 \cdot \mathsf{log1p}\left(x\right)}}\\ \end{array} \]
Alternative 4
Accuracy86.4%
Cost32900
\[\begin{array}{l} t_0 := \sqrt[3]{x} + \sqrt[3]{1 + x}\\ \mathbf{if}\;x \leq -1:\\ \;\;\;\;\frac{1}{\sqrt[3]{x} \cdot t_0 + \sqrt[3]{x \cdot x}}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{\mathsf{fma}\left(\sqrt[3]{x}, t_0, {\left(1 + x\right)}^{0.6666666666666666}\right)}\\ \end{array} \]
Alternative 5
Accuracy78.1%
Cost26828
\[\begin{array}{l} t_0 := \sqrt[3]{1 + x}\\ t_1 := \sqrt[3]{x} \cdot \left(\sqrt[3]{x} + t_0\right)\\ t_2 := \frac{1}{t_1 + \sqrt[3]{x \cdot x}}\\ \mathbf{if}\;x \leq -21000000:\\ \;\;\;\;t_2\\ \mathbf{elif}\;x \leq 26000000:\\ \;\;\;\;{\left({\left(t_0 - \sqrt[3]{x}\right)}^{3}\right)}^{0.3333333333333333}\\ \mathbf{elif}\;x \leq 1.35 \cdot 10^{+154}:\\ \;\;\;\;t_2\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{1 + t_1}\\ \end{array} \]
Alternative 6
Accuracy86.4%
Cost26628
\[\begin{array}{l} t_0 := \sqrt[3]{x} \cdot \left(\sqrt[3]{x} + \sqrt[3]{1 + x}\right)\\ \mathbf{if}\;x \leq -1:\\ \;\;\;\;\frac{1}{t_0 + \sqrt[3]{x \cdot x}}\\ \mathbf{else}:\\ \;\;\;\;\frac{1}{t_0 + {\left(1 + x\right)}^{0.6666666666666666}}\\ \end{array} \]
Alternative 7
Accuracy52.9%
Cost13376
\[\left(1 + \left(\sqrt[3]{1 + x} + -1\right)\right) - \sqrt[3]{x} \]
Alternative 8
Accuracy52.9%
Cost13120
\[\sqrt[3]{1 + x} - \sqrt[3]{x} \]
Alternative 9
Accuracy3.6%
Cost64
\[0 \]
Alternative 10
Accuracy49.6%
Cost64
\[1 \]

Error

Reproduce?

herbie shell --seed 2023157 -o generate:proofs
(FPCore (x)
  :name "2cbrt (problem 3.3.4)"
  :precision binary64
  (- (cbrt (+ x 1.0)) (cbrt x)))