No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.
So i have to write a c++ program for the Graeffe's square root method I have am stuck here when i have this formula transform into c++ code, the formula is on the link The code works particulary, the (elem[j-1]*elem[j+i]) doesn't work, it's beeing ignored and i don't know why... … |
|
The part for(int i=1; i<n; i++) { x[i]=sqrt(y[i]*i); cout<<"x"<<i<<": "<<x[i]<<endl; } isn't working wll, for some elements the result is non, i thought that i because the numbers are complex, but not with include complex i get the same resut.. can anyone help me #include<iostream> #include<math.h> #include <complex> using namespace … |