Yep Aaron is right, this is a bug. On Fri, Nov 4, 2011 at 10:30 AM, Aaron Meurer <[email protected]> wrote: >> But, unforunately, when I tried "proj=TensorProduct(1,qb2*qb2.dual)" I got >> this error: >> AttributeError: 'int' object has no attribute 'is_commutative' >> >> I think 1 is an integer an does not behaved as an identity operator. Are >> there any identity operators in Sympy? >> vug > > This is a bug in the quantum module. It needs to have a SymPy > Integer, not a Python int. The quantum function should do this > conversion automatically, but it seems that this one doesn't. Try > using TensorProduct(Integer(1),qb2*qb2.dual) as a workaround. > > Aaron Meurer > > -- > You received this message because you are subscribed to the Google Groups > "sympy" group. > 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/sympy?hl=en. > >
-- Brian E. Granger Cal Poly State University, San Luis Obispo [email protected] and [email protected] -- You received this message because you are subscribed to the Google Groups "sympy" group. 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/sympy?hl=en.
