I am working on the eclipse (kepler) on C++11 and am required to use pow on a complex number (std::complex
), but I get the following
error: template std::complex<_Tp> std::polar(const _Tp&, const _Tp&)
int Group::getActivity() const{
complex<int> c(this->getNum1(), this->getNum2());
c = pow(c, 3); //<--problem here
return abs(c);
}
the code itself doesn't have an error in this function but I get an overall error about it (this is the only use of complex in the entire code and I'm required to use it)
Just to be clear, I'm using std::complex
and there is an include line at the beginning of the cpp file.