Factoring matrix expressions, even trivial ones?



Hi Paul:

The problem is that with a very large/complicated matrix, I might not be able to easily notice what factors exist in every entry.

Stavros basically answered my question in the negative: there isn't a built-in way to do this, but by 'flattening' the matrix
into a list, he can compute the GCD of this list, and then divide it out.

At 09:19 AM 5/3/2013, Paul Bowyer wrote:
>On 05/03/2013 06:30 AM, Henry Baker wrote:
>>Is there any way for Maxima to factor 'a' back out of a*M, as below?
>>
>>Maxima 5.28.0-2 http://maxima.sourceforge.net
>>using Lisp GNU Common Lisp (GCL) GCL 2.6.8 (a.k.a. GCL)
>>Distributed under the GNU Public License. See the file COPYING.
>>Dedicated to the memory of William Schelter.
>>The function bug_report() provides bug reporting information.
>>(%i1) M:transpose([x,y]);
>>                                      [ x ]
>>(%o1)                                [   ]
>>                                      [ y ]
>>(%i2) a*M;
>>                                     [ a x ]
>>(%o2)                               [     ]
>>                                     [ a y ]
>>(%i3) %,factor;
>>                                     [ a x ]
>>(%o3)                               [     ]
>>                                     [ a y ]
>>(%i4) ????
>
>Does this do want you want? (My ignorance might be showing)
>
>M:transpose([x,y]);
>M2:a*M;
>M:M2/a;
>
>Paul Bowyer