sagemath / sage

Main repository of SageMath
https://www.sagemath.org
Other
1.34k stars 452 forks source link

Clifford algebras and differential Weyl algebras #15300

Closed tscrim closed 9 years ago

tscrim commented 10 years ago

Initial implementations of Weyl and Clifford algebras.

Depends on #16037

CC: @darijgr @sagetrac-sage-combinat

Component: algebra

Keywords: days54

Author: Travis Scrimshaw

Branch/Commit: ff27bdc

Reviewer: Darij Grinberg, John Palmieri

Issue created by migration from https://trac.sagemath.org/ticket/15300

tscrim commented 10 years ago

Attachment: trac_15300-weyl_clifford_algebras-ts.patch.gz

mguaypaq commented 10 years ago

Branch: u/mguaypaq/weyl-clifford

6bbcde06-8197-41f1-b9a3-c998bb839000 commented 10 years ago

Changed branch from u/mguaypaq/weyl-clifford to u/bump/ticket/15300

darijgr commented 10 years ago

Description changed:

--- 
+++ 
@@ -1 +1,3 @@
 Initial implementations of Weyl and Clifford algebras.
+
+Test!
anneschilling commented 10 years ago

Changed branch from u/bump/ticket/15300 to u/aschilling/ticket/15300

anneschilling commented 10 years ago

New commits:

[changeset:e3ff430]Merge branch 'u/bump/ticket/15300' of git://trac.sagemath.org/sage into ticket/15300
[changeset:427f2fe]changed formatting of list
[changeset:0734921]changed spaces
[changeset:1c7458a]#15300: Implement Weyl and Clifford algebras.
anneschilling commented 10 years ago

Commit: e3ff430

darijgr commented 10 years ago

Changed branch from u/aschilling/ticket/15300 to u/darij/ticket/15300

darijgr commented 10 years ago

Description changed:

--- 
+++ 
@@ -1,3 +1 @@
 Initial implementations of Weyl and Clifford algebras.
-
-Test!
a9a57cdf-9183-46c4-a1f6-41c1b5271dce commented 10 years ago

Changed branch from u/darij/ticket/15300 to u/gmoose05/ticket/15300

darijgr commented 10 years ago

Changed commit from e3ff430 to 8138949

darijgr commented 10 years ago
comment:10

Attachment: trac_15300-todos-dg.patch.gz

The patch I've posted contains a couple corrections and comments. Sorry for being this slow; the cold isn't very beneficial for my concentration.

EDIT: The commit list below has nothing to do with my post; it seems that trac automatically appends it to whatever post is made first after the commits. Anyway, for everyone who is not at Davis: The git commits on this ticket are a sandbox for people merging git; the true work is being done in the hg patches. I'm very positive this one is going to be reviewed way before we move over to git.


New commits:

[changeset:8138949]Merge branch 'u/darij/ticket/15300' of trac.sagemath.org:sage into gregg-change
[changeset:9f8c4a1]merged with Anne
[changeset:529d73c]Merge branch 'u/bump/ticket/15300' of git://trac.sagemath.org/sage into ticket/15300
[changeset:9086aca]added spaces
[changeset:911906c]#15300: Implement Weyl and Clifford algebras.
[changeset:2033f23]trying out git (pyflakes corrections)
tscrim commented 10 years ago

Changed branch from u/gmoose05/ticket/15300 to public/algebras/weyl_clifford-15300

tscrim commented 10 years ago

New commits:

[c2f2fef](https://github.com/sagemath/sagetrac-mirror/commit/c2f2fef)Merge branch 'master' into public/algebras/weyl_clifford-15300
tscrim commented 10 years ago

Changed commit from 8138949 to c2f2fef

7ed8c4ca-6d56-4ae9-953a-41e42b4ed313 commented 10 years ago

Branch pushed to git repo; I updated commit sha1. New commits:

[802459a](https://github.com/sagemath/sagetrac-mirror/commit/802459a)trac #15300: some remarks
7ed8c4ca-6d56-4ae9-953a-41e42b4ed313 commented 10 years ago

Changed commit from c2f2fef to 802459a

tscrim commented 10 years ago

Changed keywords from none to days54

7ed8c4ca-6d56-4ae9-953a-41e42b4ed313 commented 10 years ago

Changed commit from 802459a to dce70bb

7ed8c4ca-6d56-4ae9-953a-41e42b4ed313 commented 10 years ago

Branch pushed to git repo; I updated commit sha1. New commits:

[dce70bb](https://github.com/sagemath/sagetrac-mirror/commit/dce70bb)Fixes to Clifford algebras and expanded to have a functor method lift_morphism()
[728019a](https://github.com/sagemath/sagetrac-mirror/commit/728019a)Merge branch 'master' into public/algebras/weyl_clifford-15300
7ed8c4ca-6d56-4ae9-953a-41e42b4ed313 commented 10 years ago

Changed commit from dce70bb to 6b69822

7ed8c4ca-6d56-4ae9-953a-41e42b4ed313 commented 10 years ago

Branch pushed to git repo; I updated commit sha1. New commits:

[6b69822](https://github.com/sagemath/sagetrac-mirror/commit/6b69822)More docstring tweaks to Clifford algebra.
[f759608](https://github.com/sagemath/sagetrac-mirror/commit/f759608)Added lift_isometry method.
darijgr commented 10 years ago
comment:16

Is there an established class for bilinear forms (not necessarily symmetric!) on free modules? I'd need one to get anywhere towards the Clifford-exterior iso.

The scalar function as it stands is rather useless, since on the exterior algebra it just returns the product of the constant coefficients of self and other. What should be made (I can do that) is the lift of a bilinear (not quadratic) form on V to the exterior algebra of V (using the Gram matrix). But that requires bilinear forms, too, so I'd love to hear whether they exist before doing any changes.

7ed8c4ca-6d56-4ae9-953a-41e42b4ed313 commented 10 years ago

Changed commit from 6b69822 to 760de0b

7ed8c4ca-6d56-4ae9-953a-41e42b4ed313 commented 10 years ago

Branch pushed to git repo; I updated commit sha1. New commits:

[760de0b](https://github.com/sagemath/sagetrac-mirror/commit/760de0b)some doc fixes
tscrim commented 10 years ago
comment:18

Replying to @darijgr:

Is there an established class for bilinear forms (not necessarily symmetric!) on free modules? I'd need one to get anywhere towards the Clifford-exterior iso.

I don't think so. I think this is usually worked (hacked) around using dedicated methods.

The scalar function as it stands is rather useless, since on the exterior algebra it just returns the product of the constant coefficients of self and other. What should be made (I can do that) is the lift of a bilinear (not quadratic) form on V to the exterior algebra of V (using the Gram matrix). But that requires bilinear forms, too, so I'd love to hear whether they exist before doing any changes.

I'd just have a function Element.scalar(other) (or some other name) which projects down self and other to the exterior algebra and does the computation there via some (predefined) scalar() method.

darijgr commented 10 years ago
comment:19

Do you think it makes sense to add a BilinearForm class in analogy to QuadraticForm, or should I just use matrices to represent bilinear forms?

nthiery commented 10 years ago
comment:20

It depends what feature about bilinear forms you need for now. If it's just about computing it on some elements, I would stick for now with implementing appropriate "scalar" methods. Granted, it's a bit rudimentary. In the long run we want to have proper multivariate morphisms, with support from the coercion model. See #8900 and http://trac.sagemath.org/wiki/CategoriesRoadMap.

Cheers, Nicolas

darijgr commented 10 years ago
comment:21

What I want is to change the WeylAlgebra class to depend upon a space with a bilinear form, not on a polynomial ring. So the bilinear form will be a parameter. Still OK if it is a matrix or should I rather have an extra class?

tscrim commented 10 years ago
comment:22

Replying to @darijgr:

What I want is to change the WeylAlgebra class to depend upon a space with a bilinear form, not on a polynomial ring. So the bilinear form will be a parameter. Still OK if it is a matrix or should I rather have an extra class?

I think a matrix would be best for now (although I would like to keep the polynomial ring version).

Thanks,

Travis

darijgr commented 10 years ago
comment:23

Will be a matrix then.

Yeah, I'm not going to deprecate your Weyl algebra; I might end up renaming it, though. Thing is, the Weyl algebra of an antisymmetric bilinear form is the most correct analogue of the Clifford algebra known to me (there might be better ones, though) -- far closer than the Weyl algebra of a polynomial ring (which is just the Weyl algebra of the usual antisymmetric form which is

0 1
-1 0

as a block matrix.

tscrim commented 10 years ago
comment:24

I'm okay with renaming the class, but I'd like to keep the global entry point the same. In other words, I'd like to create it via WeylAlgebra(QQ, 4), where the absence of the bilinear form says to use the polynomial representation, or perhaps with a keyword such as polynomial=True. Thanks.

7ed8c4ca-6d56-4ae9-953a-41e42b4ed313 commented 10 years ago

Changed commit from 760de0b to e9902b9

7ed8c4ca-6d56-4ae9-953a-41e42b4ed313 commented 10 years ago

Branch pushed to git repo; I updated commit sha1. New commits:

e9902b9Merge branch 'public/algebras/weyl_clifford-15300' of trac.sagemath.org:sage into public/algebras/weyl_clifford-15300
darijgr commented 10 years ago
comment:27

There is a stupid __repr__ bug I've no idea how to fix.

sage: A = CliffordAlgebra(QuadraticForm(QQ, 3, [1,0,-1,3,-4,5]))
sage: A.basis()
Finite family {(0, 1): e0*e1, (1, 2): ee2, (0,): e0, (1,): e1, (0, 1, 2): e0*ee2, (2,): e2, (): 1, (0, 2): e0*e2}

See the ee2? It's an e1*e2, which the __repr__ routine seems to simplify to ee2 because 1* can be omitted, right? One way to deal with it would be to not use the multiplication signs; what do you think about that?

(Also, the doctests of lift_isometry are wrong -- could you compute them by hand and re-insert them? Thank you.)

EDIT: Oh, I see, the bug is in repr_from_monomials of weyl_algebra.py, not in some big free-module module.

7ed8c4ca-6d56-4ae9-953a-41e42b4ed313 commented 10 years ago

Changed commit from e9902b9 to ba596fa

7ed8c4ca-6d56-4ae9-953a-41e42b4ed313 commented 10 years ago

Branch pushed to git repo; I updated commit sha1. New commits:

c288a0cMerge branch 'public/algebras/weyl_clifford-15300' of trac.sagemath.org:sage into public/algebras/weyl_clifford-15300
015ce74Fix the repr.
ba596faFixed doctests in clifford_algebra.py.
7ed8c4ca-6d56-4ae9-953a-41e42b4ed313 commented 10 years ago

Branch pushed to git repo; I updated commit sha1. New commits:

adc2fb1rename currently existing Weyl algebra classes, so as to later introduce something more general
dad0bcereview of repr_from_monomials
7ed8c4ca-6d56-4ae9-953a-41e42b4ed313 commented 10 years ago

Changed commit from ba596fa to dad0bce

7ed8c4ca-6d56-4ae9-953a-41e42b4ed313 commented 10 years ago

Branch pushed to git repo; I updated commit sha1. New commits:

8749f21Added homology to exterior algebras.
6909a23Merge branch 'public/algebras/weyl_clifford-15300' of trac.sagemath.org:sage into public/algebras/weyl_clifford-15300
5109135Fixed doctests.
7ed8c4ca-6d56-4ae9-953a-41e42b4ed313 commented 10 years ago

Changed commit from dad0bce to 5109135

7ed8c4ca-6d56-4ae9-953a-41e42b4ed313 commented 10 years ago

Changed commit from 5109135 to 9bdf752

7ed8c4ca-6d56-4ae9-953a-41e42b4ed313 commented 10 years ago

Branch pushed to git repo; I updated commit sha1. New commits:

9bdf752various improvements to clifford_algebra.py
7ed8c4ca-6d56-4ae9-953a-41e42b4ed313 commented 10 years ago

Changed commit from 9bdf752 to 9f5bb97

7ed8c4ca-6d56-4ae9-953a-41e42b4ed313 commented 10 years ago

Branch pushed to git repo; I updated commit sha1. New commits:

9f5bb97fix merge
7ed8c4ca-6d56-4ae9-953a-41e42b4ed313 commented 10 years ago

Branch pushed to git repo; I updated commit sha1. New commits:

ab37f83tuple(S) for S a set doesn't always return the increasing list
7ed8c4ca-6d56-4ae9-953a-41e42b4ed313 commented 10 years ago

Changed commit from 9f5bb97 to ab37f83

7ed8c4ca-6d56-4ae9-953a-41e42b4ed313 commented 10 years ago

Changed commit from ab37f83 to a2354c6

7ed8c4ca-6d56-4ae9-953a-41e42b4ed313 commented 10 years ago

Branch pushed to git repo; I updated commit sha1. New commits:

a2354c6minor edits
7ed8c4ca-6d56-4ae9-953a-41e42b4ed313 commented 10 years ago

Branch pushed to git repo; I updated commit sha1. New commits:

8914cccfurther clifford edits