If I define f(n)=(n+2)^2+3, then Polynomial(f) returns x^2+4x+7 instead of n^2+4n+7, which is odd.
Is the variable of a polynomial necessarily "x"?
Also, it will be good if users can choose between ascending powers or descending powers of the variable concerned.
e.g. Polynomial((n+2)^2+3,"ascending") gives 7+4n+n^2.
As far as I know, currently, there is no easy way to sort a polynomial in ascending powers of x.
Thank you for your attention.