{\left(x + 1\right)}^{\left(\frac{1}{n}\right)} - {x}^{\left(\frac{1}{n}\right)}\begin{array}{l}
\mathbf{if}\;\frac{1}{n} \le -210159165.5542463362216949462890625:\\
\;\;\;\;2 \cdot \left(\sqrt{\log \left(\sqrt[3]{e^{{\left(x + 1\right)}^{\left(\frac{1}{n}\right)} - {x}^{\left(\frac{1}{n}\right)}}}\right)} \cdot \sqrt{\log \left(\sqrt[3]{e^{{\left(x + 1\right)}^{\left(\frac{1}{n}\right)} - {x}^{\left(\frac{1}{n}\right)}}}\right)}\right) + \log \left(\sqrt[3]{e^{{\left(x + 1\right)}^{\left(\frac{1}{n}\right)} - {x}^{\left(\frac{1}{n}\right)}}}\right)\\
\mathbf{elif}\;\frac{1}{n} \le 6.331169527565450284131583336320555667476 \cdot 10^{-11}:\\
\;\;\;\;\mathsf{fma}\left(1, \frac{1}{x \cdot n}, -\mathsf{fma}\left(0.5, \frac{1}{{x}^{2} \cdot n}, 1 \cdot \frac{\log \left(\frac{1}{x}\right)}{x \cdot {n}^{2}}\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\sqrt[3]{{\left({\left(x + 1\right)}^{\left(\frac{1}{n}\right)} - {x}^{\left(\frac{1}{n}\right)}\right)}^{3}}\\
\end{array}double f(double x, double n) {
double r68166 = x;
double r68167 = 1.0;
double r68168 = r68166 + r68167;
double r68169 = n;
double r68170 = r68167 / r68169;
double r68171 = pow(r68168, r68170);
double r68172 = pow(r68166, r68170);
double r68173 = r68171 - r68172;
return r68173;
}
double f(double x, double n) {
double r68174 = 1.0;
double r68175 = n;
double r68176 = r68174 / r68175;
double r68177 = -210159165.55424634;
bool r68178 = r68176 <= r68177;
double r68179 = 2.0;
double r68180 = x;
double r68181 = r68180 + r68174;
double r68182 = pow(r68181, r68176);
double r68183 = pow(r68180, r68176);
double r68184 = r68182 - r68183;
double r68185 = exp(r68184);
double r68186 = cbrt(r68185);
double r68187 = log(r68186);
double r68188 = sqrt(r68187);
double r68189 = r68188 * r68188;
double r68190 = r68179 * r68189;
double r68191 = r68190 + r68187;
double r68192 = 6.33116952756545e-11;
bool r68193 = r68176 <= r68192;
double r68194 = 1.0;
double r68195 = r68180 * r68175;
double r68196 = r68194 / r68195;
double r68197 = 0.5;
double r68198 = pow(r68180, r68179);
double r68199 = r68198 * r68175;
double r68200 = r68194 / r68199;
double r68201 = r68194 / r68180;
double r68202 = log(r68201);
double r68203 = pow(r68175, r68179);
double r68204 = r68180 * r68203;
double r68205 = r68202 / r68204;
double r68206 = r68174 * r68205;
double r68207 = fma(r68197, r68200, r68206);
double r68208 = -r68207;
double r68209 = fma(r68174, r68196, r68208);
double r68210 = 3.0;
double r68211 = pow(r68184, r68210);
double r68212 = cbrt(r68211);
double r68213 = r68193 ? r68209 : r68212;
double r68214 = r68178 ? r68191 : r68213;
return r68214;
}



Bits error versus x



Bits error versus n
if (/ 1.0 n) < -210159165.55424634Initial program 0
rmApplied add-log-exp0
Applied add-log-exp0
Applied diff-log0
Simplified0
rmApplied add-cube-cbrt0
Applied log-prod0
Simplified0
rmApplied add-sqr-sqrt0
if -210159165.55424634 < (/ 1.0 n) < 6.33116952756545e-11Initial program 43.7
Taylor expanded around inf 32.6
Simplified32.6
if 6.33116952756545e-11 < (/ 1.0 n) Initial program 24.4
rmApplied add-cbrt-cube24.4
Simplified24.4
Final simplification22.6
herbie shell --seed 2019346 +o rules:numerics
(FPCore (x n)
:name "2nthrt (problem 3.4.6)"
:precision binary64
(- (pow (+ x 1) (/ 1 n)) (pow x (/ 1 n))))