\cdbalgorithm{factor\_out}{}

Given a list of symbols, this algorithm tried to factor those symbols
out of terms. As an example,
\begin{screen}{1,2}
a b + a c e + a d:
@factor_out!(%){a};
a ( b + c e + d );
\end{screen}
In case you are familiar with FORM, {\tt factor\_out} is like its {\tt
bracket} statement. If you add more factors to factor out, it works as
in
\begin{screen}{1,2}
a b + a c e + a c + c e + c d + a d:
@factor_out!(%){a,c};
a (b + d) + c ( e + d ) + a c (e + 1);
\end{screen}
That is, separate terms will be generated for terms which differ by
powers of the factors to be factored out.

The algorithm of course also works with indexed objects, as in
\begin{screen}{1,2}
A_{m} B_{m} + C_{m} A_{m};
@factor_out!(%){A_{m}};
A_{m} (B_{m} + C_{m}) ;
\end{screen}
(this is still work in progress).

\cdbseealgo{factor_in}
