Collect

Collects the terms of an expression with respect to one of the variables.

collect(Expression, Identifier)

Given an expression and an identifier x in the expression, collects the term of the expression in powers of x.

collect(Expression, List)

Given an expression and a list with identifiers in the expression, collects the term of the expression in powers of the variables of the list.