#include #include #include #include #include #include #include #include "BigIntegerLibrary.hh" using namespace std; string int2string(int n){ stringstream s; s << n; //el numero n passa a ser s return(s.str()); } int main(){ cout<<"Introduce until which k, n^k: "; int mmm; cin>>mmm; string mm = int2string(mmm); BigInteger m = stringToBigInteger(mm); cout<<"Introduce until what r, n^k(n+r)!: "; int nnn; cin>>nnn; string nn = int2string(nnn); BigInteger n = stringToBigInteger(nn); vector vres; vector > vpol1 (nnn+1); vres.push_back(-1); string unn; BigInteger un = stringToBigInteger(unn); un = 1; vector alpha; vector indep; string alphanumm; BigInteger alphanum = stringToBigInteger(alphanumm); string indepnumm; BigInteger indepnum = stringToBigInteger(indepnumm); string sumafactt; BigInteger sumafact = stringToBigInteger(sumafactt); sumafact = 0; alpha.push_back(1); alpha.push_back(0); indep.push_back(1); indep.push_back(-1); vpol1[1].push_back(1); vpol1[1].push_back(1); vector > bino (nnn); bino[0].push_back(1); bino[1].push_back(1); bino[1].push_back(1); for(unsigned long long int i=2; i > vpol2 (nnn+1); vpol2[1].push_back(1); vpol2[1].push_back(k); for(int w=2; w<=i; w++){ //LES ITERACIONS NECESSĀRIES PER CALCULAR UN POLINOMI DE TAL GRAU FINS i vpol2[w].push_back(1); //cout<<1<<" "; //si vols imprimir el polinomi for(int q=1; q