x^3+2*x^2-8*x+10=0
I can use:
r=roots([1 2 -8 10])
or:
solve('x^3+2*x^2-8*x+10')
However, the answers will be given in different form. The first one will give numerical values of the roots, like:
ans =
-4.3605
1.1803 + 0.9488i
1.1803 - 0.9488i
the latter one will give symbolic form answers:
ans =
-1/3*(215+3*2697^(1/2))^(1/3)-28/3/(215+3*2697^(1/2))^(1/3)-2/3
1/6*(215+3*2697^(1/2))^(1/3)+14/3/(215+3*2697^(1/2))^(1/3)-2/3+1/2*i*3^(1/2)*(-1/3*(215+3*2697^(1/2))^(1/3)+28/3/(215+3*2697^(1/2))^(1/3))
1/6*(215+3*2697^(1/2))^(1/3)+14/3/(215+3*2697^(1/2))^(1/3)-2/3-1/2*i*3^(1/2)*(-1/3*(215+3*2697^(1/2))^(1/3)+28/3/(215+3*2697^(1/2))^(1/3))
short and to the point, thanks
ReplyDelete