ASKSAGE: Sage Q&A Forum - RSS feedhttps://ask.sagemath.org/questions/Q&A Forum for SageenCopyright Sage, 2010. Some rights reserved under creative commons license.Mon, 13 Jun 2016 23:43:15 +0200symbolic constant in clifford algebrahttps://ask.sagemath.org/question/33763/symbolic-constant-in-clifford-algebra/ Dear all,
First of all I'd like to state that I am far from a SageMath expert. Right now, I am working on Clifford algebra's and I would like to do some computations with SageMath Cloud. Unfortunately, I experience the problem that when I define a symbolic constant, Sage doesn't know how to multiply this with elements in the Clifford algebra. This is the code that I'm using.
START CODE
C = ComplexField();
sage: Q = QuadraticForm(C, 3, [0,0,1,1,0,0])
sage: Cl.<x,y,z> = CliffordAlgebra(Q)
var('e')
e*x
END CODE
I get an error for e*x: ''unsupported operand parent(s) for '*': 'Symbolic Ring' and 'The Clifford algebra of the Quadratic form in 3 variables over Complex Field with 53 bits of precision with coefficients:''
Does anyone maybe know how to work around this? Maybe I am defining the variable all wrong?
Thank you very much!
Kind regards,
David
Mon, 13 Jun 2016 15:01:50 +0200https://ask.sagemath.org/question/33763/symbolic-constant-in-clifford-algebra/Comment by tmonteil for <p>Dear all,</p>
<p>First of all I'd like to state that I am far from a SageMath expert. Right now, I am working on Clifford algebra's and I would like to do some computations with SageMath Cloud. Unfortunately, I experience the problem that when I define a symbolic constant, Sage doesn't know how to multiply this with elements in the Clifford algebra. This is the code that I'm using.</p>
<p>START CODE</p>
<p>C = ComplexField();</p>
<p>sage: Q = QuadraticForm(C, 3, [0,0,1,1,0,0])</p>
<p>sage: Cl.<x,y,z> = CliffordAlgebra(Q)</p>
<p>var('e')</p>
<p>e*x</p>
<p>END CODE</p>
<p>I get an error for e<em>x: ''unsupported operand parent(s) for '</em>': 'Symbolic Ring' and 'The Clifford algebra of the Quadratic form in 3 variables over Complex Field with 53 bits of precision with coefficients:''</p>
<p>Does anyone maybe know how to work around this? Maybe I am defining the variable all wrong?</p>
<p>Thank you very much!</p>
<p>Kind regards,</p>
<p>David</p>
https://ask.sagemath.org/question/33763/symbolic-constant-in-clifford-algebra/?comment=33766#post-id-33766Could you tell who is supposed to be `e` (mathematically) ?Mon, 13 Jun 2016 16:32:11 +0200https://ask.sagemath.org/question/33763/symbolic-constant-in-clifford-algebra/?comment=33766#post-id-33766Comment by davidvanovereem for <p>Dear all,</p>
<p>First of all I'd like to state that I am far from a SageMath expert. Right now, I am working on Clifford algebra's and I would like to do some computations with SageMath Cloud. Unfortunately, I experience the problem that when I define a symbolic constant, Sage doesn't know how to multiply this with elements in the Clifford algebra. This is the code that I'm using.</p>
<p>START CODE</p>
<p>C = ComplexField();</p>
<p>sage: Q = QuadraticForm(C, 3, [0,0,1,1,0,0])</p>
<p>sage: Cl.<x,y,z> = CliffordAlgebra(Q)</p>
<p>var('e')</p>
<p>e*x</p>
<p>END CODE</p>
<p>I get an error for e<em>x: ''unsupported operand parent(s) for '</em>': 'Symbolic Ring' and 'The Clifford algebra of the Quadratic form in 3 variables over Complex Field with 53 bits of precision with coefficients:''</p>
<p>Does anyone maybe know how to work around this? Maybe I am defining the variable all wrong?</p>
<p>Thank you very much!</p>
<p>Kind regards,</p>
<p>David</p>
https://ask.sagemath.org/question/33763/symbolic-constant-in-clifford-algebra/?comment=33769#post-id-33769thanks for your comment tmonteil! e is supposed to be just some constant in C.Mon, 13 Jun 2016 18:49:29 +0200https://ask.sagemath.org/question/33763/symbolic-constant-in-clifford-algebra/?comment=33769#post-id-33769Answer by tmonteil for <p>Dear all,</p>
<p>First of all I'd like to state that I am far from a SageMath expert. Right now, I am working on Clifford algebra's and I would like to do some computations with SageMath Cloud. Unfortunately, I experience the problem that when I define a symbolic constant, Sage doesn't know how to multiply this with elements in the Clifford algebra. This is the code that I'm using.</p>
<p>START CODE</p>
<p>C = ComplexField();</p>
<p>sage: Q = QuadraticForm(C, 3, [0,0,1,1,0,0])</p>
<p>sage: Cl.<x,y,z> = CliffordAlgebra(Q)</p>
<p>var('e')</p>
<p>e*x</p>
<p>END CODE</p>
<p>I get an error for e<em>x: ''unsupported operand parent(s) for '</em>': 'Symbolic Ring' and 'The Clifford algebra of the Quadratic form in 3 variables over Complex Field with 53 bits of precision with coefficients:''</p>
<p>Does anyone maybe know how to work around this? Maybe I am defining the variable all wrong?</p>
<p>Thank you very much!</p>
<p>Kind regards,</p>
<p>David</p>
https://ask.sagemath.org/question/33763/symbolic-constant-in-clifford-algebra/?answer=33771#post-id-33771It is not clear to me what do you plan to do with such product, so i fear there is no good answer to your question, perhaps could you try to be more precise on your goals.
That said, when dealing with algebraic objects, a classical trick is to use polynomial indeterminates instead of symbols. In your case, it could be something like:
sage: R.<e> = PolynomialRing(C)
sage: R
Univariate Polynomial Ring in e over Complex Field with 53 bits of precision
sage: e*x
x*e
Mon, 13 Jun 2016 23:43:15 +0200https://ask.sagemath.org/question/33763/symbolic-constant-in-clifford-algebra/?answer=33771#post-id-33771