| Symbolic Math Toolbox | ![]() |
Syntax
Description
For each polynomial in the array S of polynomials, collect(S) collects terms containing the variable v (or x, if v is not specified). The result is an array containing the collected polynomials.
Examples
syms x y;R1 = collect((exp(x)+x)*(x+2))R2 =collect((x+y)*(x^2+y^2+1), y)R3 = collect([(x+1)*(y+1),x+y])
See Also
expand, factor, simple, simplify, syms
| ccode | colspace | ![]() |