Plots of functions containing rational exponents such as is the source of much commotion. In this short report, I will highlight how Mathematica defines these roots and why it makes sense mathematically. Next, I will show how to resolve the issue using the
We know that every number (real or complex) has distinct roots. Therefore, has three roots, only one of which is real. As a matter of fact, more generally, if , then has roots, only one of which is real. Let’s consider the simplest case. Every positive real number has 2 square roots. It turns out both of these roots are real, one is positive and one is negative. For example has two square roots, and . We identify as the principal square root. Why? In algebra texts, the the principal square root is defined to be the positive root. However, this is very misleading and is the root of the problem we are addressing in this report. The principal square root is defined to be the complex root with the smallest argument. therefore, the arguments of its roots are and . We identify as the principal square root because it has the smallest argument; not because it is positive!
Generalizing this argument, let , then and therefore the arguments of its roots are for . The smallest of these is of course the root corresponding to in which case we have which means that is real (and positive).
Now suppose that , then and therefore, the arguments of its roots are for . As before, the root with the smallest argument corresponds to , namely . Finally, since for we know that . In other words, the principal root of every negative real number is complex, even when is odd!
Going back to Mathematica, is defined as the principal cube root of . Per our discussion above, if then and therefore wouldn’t (and shouldn’t) appear in the real plot.
Notwithstanding the mathematics of roots, Mathematica has a built-in function called
Surd. This function gives the real roots of real numbers (if they exist) even if these real roots are not the principal roots. For example
Surd[-1,3] gives the real cube root of . While
(-1)^(1/3) is left unevaluated (see figure 1).
Note that and therefore the principal cube root is . We can get a numerical result by entering
(-1.)^(1/3) as in figure 2 to confirm our analysis.