combine terms into a single term
combine(f, n, opt1, opt2, ...)
any expression, or set or list of expressions
name or a list or set of names
opt1, opt2, ...
(optional) names of options
The combine function applies transformations which combine terms in sums, products, and powers into a single term. This function is applied recursively to the components of lists, sets, and relations; that is, f and n may be lists (or sets) of expressions and names, respectively.
For many functions, the transformations applied by combine are the inverse of the transformations that are applied by expand. For example, consider the well-known identity
The combine function applies the identity from right to left, whereas the expand function does the reverse.
Subexpressions involving Int, Sum, and Limit are combined into one expression where possible using linearity; that is, c1⁢f⁡a,range+c2⁢f⁡b,range ==> f⁡c1⁢a+c2⁢b,range.
A specific set of transformations is obtained by specifying a second (optional) argument n (a name) which is one or a list of the following:
For additional information and examples about the transformations applied by each of these, see combine[n] where n is an argument (a name) from the above list.
The symbolic option can be included to specify that formal symbolic manipulation of expressions is allowed without regard to the analytical issue of branches for multi-valued functions. For example, the expression sqrt(x)*sqrt(y) simplifies to sqrt(x*y) under the symbolic option. Without this option, the simplified result must take into account the different possible values of the (complex) sign of x and y.
Note: When the symbolic option is specified, any branch of a multi-valued function can be chosen during the simplification process. The result of such an operation is in general not valid over the whole complex plane and can lead to incorrect results if you assume the expressions represent analytical functions.
The combine function maps over functions. Therefore combine(f(a)) is the same as map(combine,f(a)).
The use of the inert Limit function can lead to errors.
f1 ≔ 3⁢2+y⁢x2−1
Compare the following examples. The extra arguments restrict the combining transformations.
Download Help Document
What kind of issue would you like to report? (Optional)