Factorization of syms class objects
古いコメントを表示
I create Syms class matrices with elements taking a similar structure to this,
a11*(a1*a4*a7 + a2*a5*a9) + a3*a7*a11
I wish to factor each cell in such a way that there is no reptition of variables. In cases such as the above using 'factor' or 'simplify' only removes the common factor 'a11' from the term yielding,
a11*(a3*a7 + a1*a4*a7 + a2*a5*a9).
However, i am looking for 'a7' to also be factored out; thus yielding,
a11*( a7*(a3 + a1*a4) + a2*a5*a9).
I am interested to hear if anyone has an approach for dealing with such a problem.
Regards
Ross
Note: The methods applied to reach the original matrix would never return solutions which could not be factored in such a way that every variable occurs only once in the term.
2 件のコメント
Sean de Wolski
2011 年 12 月 16 日
Just a note: Naming a variable a11 is very hard to understand since it looks like all, a very useful builtin function.
ross montgomery
2011 年 12 月 16 日
採用された回答
その他の回答 (0 件)
カテゴリ
ヘルプ センター および File Exchange で Common Operations についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!