This question already has an answer here:
Here is an elementary third root calculation of -8 (or any negative real number) with and without parentheses, but Mathematica seems to be given different answers!
In:= -8^(1/3) // N Out= -2. In:= (-8)^(1/3) // N, Out= 1. + 1.73205 I, In:= (8)^(1/3) // N Out= 2. In:= 8^(1/3) // N Out= 2.
I noticed this weird behaviour when I was trying to compute Telles transformation points from some Gauss points. My set up required using nested parentheses, but it turned out after several tries I have to examine each component of my equation only to notice this strange behaviour with and without parentheses. Could this be a bug in V.220.127.116.11?
The question above was motivated by this basic computation
type1: k = (e (e^2 - 1) + Abs[e^2 - 1])^(1/3) + (e (e^2 - 1) - Abs[e^2 - 1])^(1/3) + e /. e -> -0.861136 a1 = e (e^2 - 1) /. e -> -0.861136; a2 = Abs[e^2 - 1] /. e -> -0.861136; type2: k = (a1 + a2)^(1/3) + (a1 - a2)^(1/3) - 0.861136 type3: k = CubeRoot[a1 + a2] + CubeRoot[a1 - a2] - 0.861136 0.0873074 + 0.28566 I (type1 output) 0.0873074 + 0.28566 I (type2 output) -0.407471(type3 output)
Typically one would write out equations in the
type2 formats especially if you have more complicated functions to deal with. I am not sure why
type2 are not giving the expected answer (