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
Finite-dimensional algebras with basis: add __invert__ method #33250
Comments
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
comment:4
This is good to add. I think we should have a shortcut for scalars of the identity when Since from-category methods are low in the MRO, there shouldn't be any danger of overshadowing more specific implementations. How could this fail to find an inverse when one did exist? I imagine there has to be some condition on the ground ring. We probably should also force the coefficients into the base ring (which will fail when it has say 1/2 when over Z as it should). I would add a For pushing to trac, perhaps check that your public key on trac? Perhaps something got changed on your computer too? |
comment:5
Replying to @tscrim:
Thanks. Should we just check for the case when both
I hope so, but I'm worried that some categories themselves might be specific (e.g., what if we have some kind of, say, "division rings" category that has its own implementation of inverses?).
That would happen if the ground ring doesn't know enough linear algebra to support
Yeah, that sounds reasonable.
My key is on trac, but yes, something changed on my computer (recent reinstall), and something seems to have changed on the server as well (the change from git:// to https://). I'd be happy to discuss this over zoom. |
This comment has been minimized.
This comment has been minimized.
Commit: |
comment:7
Here is a trac pushed version of the branch. I made some additional changes, including what I mentioned in comment:4. I also took the opportunity to make sure all implementations of New commits:
|
Author: Darij Grinberg |
Reviewer: Travis Scrimshaw |
Branch pushed to git repo; I updated commit sha1. New commits:
|
This comment has been minimized.
This comment has been minimized.
comment:9
LGTM! If doctests pass, this should be merged. (To clarify, Travis has reviewed my part of this ticket and I have now reviewed his.) |
Changed branch from public/algebra/generic_invert-33250 to |
Let's try to invert an element of a
finite-dimensional algebra over a field:
At the moment, this is not implemented.
The branch attached provides a naive implementation.
It does overshadow the
__invert__
method onAlgebrasWithBasis
, which however is unable toinvert anything but a scalar multiple of the unity
(and that only in the case when the unity is a
basis element). In theory, this could be a problem,
but I don't expect it to be.
I hope it doesn't overshadow any more efficient
__invert__
methods on other classes of algebrasvia diamond inheritance. Anyone who knows the hierarchy?
CC: @tscrim @fchapoton @mkoeppe @jhpalmieri
Component: algebra
Keywords: algebras, algebras with bases, inverses
Author: Darij Grinberg
Branch/Commit:
836a681
Reviewer: Travis Scrimshaw
Issue created by migration from https://trac.sagemath.org/ticket/33250
The text was updated successfully, but these errors were encountered: