function template
std::pow
<complex>
template<class T> complex<T> pow (const complex<T>& x, int y);
template<class T> complex<T> pow (const complex<T>& x, const complex<T>& y);
template<class T> complex<T> pow (const complex<T>& x, const T& y);
template<class T> complex<T> pow (const T& x, const complex<T>& y);
Return complex power
Returns the complex power of base
x raised to the
y-th power using the principal branch, whose cuts are along the negative real axis, as if computed by:
This overloads
cmath's pow function.
Parameters
- x
- Base value.
T is complex's template type (i.e., its value type).
- y
- Exponent value.
T is complex's template type (i.e., its value type).
Return value
The result of raising
x to the
y-th power.
Each library implementation defines how range and domain errors are signaled.
See also
- log
- Return natural logarithm of complex (function template)
- exp
- Return exponential of complex (function template)
- sqrt
- Return square root of complex (function template)
- pow (cmath)
- Raise to power (function
)