ASKSAGE: Sage Q&A Forum - Latest question feedhttp://ask.sagemath.org/questions/Q&A Forum for SageenCopyright Sage, 2010. Some rights reserved under creative commons license.Mon, 21 Jan 2013 20:37:05 -0600How to do symbolic computation with quaternionshttp://ask.sagemath.org/question/9730/how-to-do-symbolic-computation-with-quaternions/I need to do symbolic computations with quaternions. Ideally I'd like to enter something like
Q.<i,j,k> = QuaternionAlgebra(QQ,-1,-1)
a=var('a')
b=var('b')
c=var('c')
q = a*i+b*j+c*k
But it doesn't work : TypeError: unsupported operand parent(s) for '*': 'Symbolic Ring' and 'Quaternion Algebra (-1, -1) with base ring Rational Field'
Looks like SAGE doesn't know how to multiply a variable and a quaternion. Or should I specify the types of the variables ? How ?
Thanks for your help.
Gilles FalquetMon, 21 Jan 2013 20:37:05 -0600http://ask.sagemath.org/question/9730/