Skip to content

Add an infinite weyl algebra class #40263

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 13 commits into
base: develop
Choose a base branch
from

Conversation

jmcdonough98
Copy link
Contributor

This PR adds a class InfiniteDifferentialWeylAlgebra, the infinite analog of the currently existing DifferentialWeylAlgebra class. It is an algebra generated by two countable families of symbols x_i, dx_i subject to the relations [x_i, x_j] = [dx_i, dx_j] = 0 and [x_i, dx_j] = \delta_{i, j}

Part of #40241

cc: @tscrim

📝 Checklist

  • The title is concise and informative.
  • The description explains in detail what this PR is about.
  • I have linked a relevant issue or discussion.
  • I have created tests covering the changes.
  • I have updated the documentation and checked the documentation preview.

⌛ Dependencies

Copy link

github-actions bot commented Jun 16, 2025

Documentation preview for this PR (built with commit c018c5b; changes) is ready! 🎉
This preview will update shortly after each push to this PR.

from sage.algebras.weyl_algebra import DifferentialWeylAlgebra
from sage.algebras.weyl_algebra import DifferentialWeylAlgebra, InfiniteDifferentialWeylAlgebra
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should not import this into the global namespace, but instead update the hook for DifferentialWeylAlgebra to punt to the infinite case when the generators are infinite. This will mean renaming DifferentialWeylAlgebra__classcall__ to DifferentialWeylAlgebra__classcall_private__ and expanding its signature to take an addition n parameter. When n == oo, then it returns the infinitely generated case.

Comment on lines +1500 to +1511
@cached_method
def one(self):
"""
Return the multiplicative identity element `1` of ``self``

EXAMPLES::

sage: W.<x> = InfiniteDifferentialWeylAlgebra(QQ)
sage: x[1]*W.one() == x[1]
True
"""
return self.element_class(self, {(self._var_index.one(), self._diff_index.one()): self.base_ring().one()})
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
@cached_method
def one(self):
"""
Return the multiplicative identity element `1` of ``self``
EXAMPLES::
sage: W.<x> = InfiniteDifferentialWeylAlgebra(QQ)
sage: x[1]*W.one() == x[1]
True
"""
return self.element_class(self, {(self._var_index.one(), self._diff_index.one()): self.base_ring().one()})
@cached_method
def one_basis(self):
"""
Return the multiplicative identity element `1` of ``self``
EXAMPLES::
sage: W.<x> = InfiniteDifferentialWeylAlgebra(QQ)
sage: W.one_basis() == W.one().leading_support()
True
sage: x[1]*W.one() == x[1]
True
"""
return (self._var_index.one(), self._diff_index.one())

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants