ASKSAGE: Sage Q&A Forum - Latest question feedhttp://ask.sagemath.org/questions/Q&A Forum for SageenCopyright Sage, 2010. Some rights reserved under creative commons license.Fri, 11 Nov 2016 22:54:11 -0600Collect polynomial in a different variablehttp://ask.sagemath.org/question/35537/collect-polynomial-in-a-different-variable/ I want to collect my polynomial in a different variable. How am I to do that. For example I have :
D=(a1*u^3+a2*u^2+a3*u+a4)x^4+(a5*u^3+a6*u^2+a7*u+a8)x^3+(a9*u^3+a10*u^2+a11*u+a12)x^2+(a13*u^3+a14*u^2+a15*u+a16)x
Now I want my `D` to be in the form where `u` is the main variable, so I will have :
D=(a1*x^4+a5*x^3+a9*x^2+a13*x)u^3+(...)u^2+(...)u
Maple do it with `collect` code. I try to search for a similar code in Sage but no luck.ShaFri, 11 Nov 2016 22:54:11 -0600http://ask.sagemath.org/question/35537/