Iwan Lappo-Danilewski wrote:
> Why does a Matrix not possess the function full_simpify. I.e. why does
> P.full_simplify() not work?
>
It's probably because no one has written it yet. I think it'd be great
to have. We welcome any patches to do that.
You can do the same thing using the apply_map function, which applies a
function to each entry of a matrix.
sage: var('a,b,c,d')
(a, b, c, d)
sage: A=matrix([[sin(a+b), sin(c+d)],[cos(a+d),cos(b+d)]])
sage: A
[sin(b + a) sin(d + c)]
[cos(d + a) cos(d + b)]
sage: B=A.apply_map(lambda x: x.full_simplify())
sage: B
[cos(a)*sin(b) + sin(a)*cos(b) cos(c)*sin(d) + sin(c)*cos(d)]
[cos(a)*cos(d) - sin(a)*sin(d) cos(b)*cos(d) - sin(b)*sin(d)]
Jason
--~--~---------~--~----~------------~-------~--~----~
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/sage-support
URLs: http://www.sagemath.org
-~----------~----~----~----~------~----~------~--~---