subexpr
Rewrite symbolic expression in terms of common subexpressions
Description
[
                is equivalent to r,var]
= subexpr(expr,var)[r,var] = subexpr(expr,'var'), except that the
                symbolic variable var must already exist in the MATLAB® workspace.
This syntax overwrites the value of the variable var with the
                common subexpression found in expr. To avoid overwriting the
                value of var, use another variable name as the second output
                argument. For example, use [r,var1] = subexpr(expr,var).
Examples
Input Arguments
Output Arguments
Version History
Introduced before R2006a