FUNCTION REFERENCE
nthroot
Real n-th root.
Real n-th root.
Syntax
y = nthroot(x, n)Real root of x for real n, with a final correction step for accuracy.
For finite n, negative x needs an odd integer n. For nonnegative x, n = 0
evaluates x.^Inf. Infinite n gives 1 for nonnegative x and -1 for negative x;
NaN in either input gives NaN.
Example
nthroot(-27, 3) % -3Differences from MATLAB: Real double and logical input only.
These are the engine’s help pages. Each page keeps its compatibility notes. File operations are unavailable in the browser.