Manipulation of matrix symbols


I have several times found myself wanting a package that can perform symbolic manipulations on matrix level. Many of the symbolic packages out there support creating matrices of symbols and using these in expressions (SymPy for example), the result of which becomes hard to parse as they are printed on the level of individual matrix entries. As an example, I would like to be able to do stuff like

A = SymMatrix(3,3)
v = SymVector(3)
A*v # stored/printed as Av
(2A)*(2v) # stored/printed as 4Av
v*A # error, dimensions don't match
[A A] # printed as [A A] 

R = SymMatrix(SO(3))
simplify(R'R) == I 

Is such functionality available in any of the julia symbolic libraries? If not, is any of these libraries exposing an abstract symbol type that I could extend and endow with size properties etc. to build up such functionality?

1 Like