#hw9.txt, 23 Februray, ANDREW LOHR #Problem 1 ApplyUmbra := proc(P,x,U,m) local L,i,retexpr: L := PolynomialTools[CoefficientList](P,x): retexpr :=0: for i from 1 to nops(L) do retexpr := retexpr + L[i] * subs(m = i-1 , U): od: retexpr: end: #Problem 2 PnG:=proc(n,x,U,m) local eq,var,i,P,a: option remember: P:=x^n+add(a[i]*x^i,i=0..n-1): var:={seq(a[i],i=0..n-1)}: eq:={ seq( ApplyUmbra(P*x^i,x,U,m)=0, i=0..n-1)}: simplify(sort(subs(solve(eq,var),P))): end: #Problem 3 read `C6.txt`: GuessCoeff := proc(n,i,U,m) local j: GuessRF([seq(coeff(PnG(j,x,U,m),x,j-i),j=i..30+i)],n): end: #for U = 1/(m+1), i=0..7, we get #1 #-(1/2)*n #(n^3+n^2)/(8*n+4) #(n^4+3*n^3+2*n^2)/(-48*n-72) #(n^6+7*n^5+17*n^4+17*n^3+6*n^2)/(384*n^2+1536*n+1440) #(n^7+11*n^6+45*n^5+85*n^4+74*n^3+24*n^2)/(-3840*n^2-23040*n-33600) #(n^9+18*n^8+132*n^7+510*n^6+1119*n^5+1392*n^4+908*n^3+240*n^2)/(46080*n^3+483840*n^2+1647360*n+1814400) #(n^10+24*n^9+240*n^8+1302*n^7+4179*n^6+8106*n^5+9260*n^4+5688*n^3+1440*n^2)/(-645120*n^3-8709120*n^2-38545920*n-55883520) #for U = 1/(m+3), i=0..7, we get #1 #(n^2+2*n)/(-2*n-2) #(n^3+4*n^2+3*n)/(8*n+12) #(n^4+7*n^3+14*n^2+8*n)/(-48*n-120) #(n^6+13*n^5+63*n^4+143*n^3+152*n^2+60*n)/(384*n^2+2304*n+3360) #(n^7+18*n^6+127*n^5+450*n^4+844*n^3+792*n^2+288*n)/(-3840*n^2-30720*n-60480) #(n^9+27*n^8+306*n^7+1902*n^6+7089*n^5+16203*n^4+22124*n^3+16428*n^2+5040*n)/(46080*n^3+622080*n^2+2753280*n+3991680) #(n^10+34*n^9+494*n^8+4024*n^7+20237*n^6+65086*n^5+133636*n^4+168456*n^3+117792*n^2+34560*n)/(-645120*n^3-10644480*n^2-57899520*n-103783680) #for U = eval(m!), i=0..7, it took too long to run to completion #Problem 4 GuessOP := proc(n,r, U,m) local i: GuessRF([seq(GuessCoeff(n,i,U,m),i=1 .. 28)],r): end: