-
-
Notifications
You must be signed in to change notification settings - Fork 478
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
Fix change_ring
method of multi-variate polynomials
#37159
Conversation
change_ring
method of multi-variate polynomial rings
change_ring
method of multi-variate polynomial ringschange_ring
method of multi-variate polynomial
change_ring
method of multi-variate polynomialchange_ring
method of multi-variate polynomials
Since you are claiming that this fixes #36832, please could you add at least one doctest showing that the errors previously existing have been fixed by this? With that, and assuming that this change does not break anything else, I would be happy with merging it, though I confess that I have not looked into the details. |
Sure. Done. Moreover Before the patch: sage: F = GF(11)
sage: phi = Hom(F, F.extension(2)).an_element()
sage: R.<x,y> = F[]
sage: x.change_ring(phi)
sage: timeit('x.change_ring(phi)')
625 loops, best of 3: 148 μs per loop After the patch: sage: F = GF(11)
sage: phi = Hom(F, F.extension(2)).an_element()
sage: R.<x,y> = F[]
sage: x.change_ring(phi)
sage: timeit('x.change_ring(phi)')
625 loops, best of 3: 53 μs per loop Hence the new |
I don't understand. Wasn't #36832 about the following?
|
Yes. That (which didn't work before) is fixed by this PR. But as a bonus, the PR speeds up already working cases. |
It would be good to make that a doctest, don't you think? |
Above one? A doctest is already added by ccaa957. |
Notes:
|
ccaa957
to
3688c18
Compare
Done.
Sorry but I don't see the need.
As the failure in
Right, it seems redundant. Removed and combined with the one in |
Documentation preview for this PR (built with commit fb1b108; changes) is ready! 🎉 |
LGTM |
Thanks! |
Fixes #36832.
📝 Checklist
⌛ Dependencies