Hi all,
I stumbled upon the discussion on matrix assumptions and the bit of history behind this sympy module: http://scicomp.stackexchange.com/questions/74/symbolic-software-packages-for-matrix-expressions First off all, thank you Matt, this is incredibly cool stuff! Now, I'm trying to do some matrix algebra while encoding knowledge about the matrices involved. For instance, say my matrix U is unitary, i.e. U * U.T = I. I've looked around in the documentation and source code, but couldn't figure out, if the new assumption system can be used to simplify matrix expressions. I was trying to exploit this using sympy as follows: from sympy import Q, symbols, MatrixSymbol, ask, simplify from sympy.assumptions.assume import global_assumptions n = symbols('n', integer=True) U = MatrixSymbol('U', n, n) global_assumptions.add(Q.unitary(U)) UU = U * U.T print UU simpleUU = simplify(UU) print simpleUU I was hoping that the second print would output the Identity, but somehow this didn't work. Any suggestions, pointers, hints? Cheers, Chris -- You received this message because you are subscribed to the Google Groups "sympy" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/sympy. To view this discussion on the web visit https://groups.google.com/d/msgid/sympy/31aaea36-675d-40b0-8d77-aec8828f6c31%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
