check for fractional powers

Parameters

 expr - expression

Description

 • The definition of type radical is that expr is of type ^ and op(2, expr) (the exponent) is of type fraction.

Examples

 > $\mathrm{type}\left({2}^{\frac{1}{2}},\mathrm{radical}\right)$
 ${\mathrm{true}}$ (1)
 > $\mathrm{type}\left({y}^{\frac{2}{5}},\mathrm{radical}\right)$
 ${\mathrm{true}}$ (2)
 > $\mathrm{type}\left({y}^{3},\mathrm{radical}\right)$
 ${\mathrm{false}}$ (3)
 > $\mathrm{type}\left(\mathrm{sqrt}\left({x}^{2}+{y}^{2}\right),\mathrm{radical}\right)$
 ${\mathrm{true}}$ (4)