Ask Your Question

Revision history [back]

How to reorder terms in a polynomial to follow a specific order.

Hi everyone,

I have code in Sagemath that will give me various polynomials. However, I need these polynomials to be ordered in a specific way. For example, my code will output a polynomial that looks like this:


but I need it to be outputted like this:


Is there any way to do this? Thanks, I appreciate the help.