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
multivariate factorization over QQbar #25390
Comments
Commit: |
Branch: public/25390 |
comment:1
I added code to call Singular's Here's what's now possible:
But something like this still doesn't work (because the coefficients aren't in
It's something, which is better than nothing, so I think we should move it towards New commits:
|
Author: Brent Baccala |
comment:2
I agree that small improvements are good. We can always do followup tickets to add more functionality. I do have some comments: Can we use Doc tweaks: ALGORITHM:
- Uses Singular's `absfact` library.
+ Uses Singular's ``absfact`` library.
- TODO:
+ .. TODO::
- Implement absolute factorization over number fields
+ Implement absolute factorization over number fields. Also if you could split the long output line so that it is at most ~80 chars per line. Instead of I don't see the need for the internal functions In Python, usually |
Branch pushed to git repo; I updated commit sha1. New commits:
|
comment:5
Over the weekend I remembered a technique that I read years ago for factoring over a number field - factor the norm of the polynomial, which has rational coefficients and is a multiple of the original polynomial. So, this ticket is moving towards The algorithm is tricky enough that I'm planning to write up a short paper describing it, post it on arxiv, and link to it from the documentation. If anybody has a better suggestion for how to incorporate a three page paper explaining the algorithm of a Sage method, please let me know. I took most of I also intend to implement factorization over |
Branch pushed to git repo; I updated commit sha1. New commits:
|
Branch pushed to git repo; I updated commit sha1. New commits:
|
comment:8
Still haven't figured out how to access the Singular variable from I spent two weeks trying to figure out to make this code work without doing division in polynomial rings over Right now, the code is fairly straightforward, but does require polynomial division over |
Dependencies: #25351 |
comment:9
Attachment: qqbar.pdf.gz I didn't realize that my suggestion would have been so complicated. Thank you for looking into it. I have two small additional nitpicks, but otherwise this ticket is a positive review assuming #25351 (which I cannot review as that is much more involved mathematically, you should cc some people who work more in that area, such as jdemeyer). You do not need to create a list: norm_f = prod([numfield_f.map_coefficients(h) for h in numfield.embeddings(QQbar)]).change_ring(QQ)
norm_f = prod(numfield_f.map_coefficients(h) for h in numfield.embeddings(QQbar)).change_ring(QQ) - REFERENCE::
+ REFERENCES:
- Geddes, et. al, "Algorithms for Computer Algebra", Section 8.8
+ - Geddes, et. al, "Algorithms for Computer Algebra", Section 8.8 although I think it would be better to reference the book in the master ref file and use |
comment:10
If at all possible, you'll probably want to avoid computing norms by multiplying complex embeddings together. Especially when you have your polynomial over a number field, it's probably much better to avoid floats altogether. For instance, if your number field is given as K=QQ[t]/(h(t)) (with h(t) monic) and you have a polynomial f(x) in K[x], then you can represent your polynomial as F(x,t) in QQ[x,t], via the isomorphism K[x] ~ Q[x,t]/(h(t)). Then you have that Norm_(K[x]/Q[x]) (f) = Resultant(F,h,t) Code for computing resultants is usually quite optimized. You can experiment a bit to see which approach works best, but I'd expect the resultant to work quite well. |
comment:12
I made the changes suggested by tscrim and nbruin; thanks for your feedback. Using the resultant was more of a pain that I thought it should be. The difficulty lay mainly in needing to introduce a new variable, different from the others. If anybody can suggest a better way that what I came up with, please let me know. |
comment:13
Variable names might be haunting us here:
Unless you can guarantee the variable names of the number field and the polynomial ring aren't clashing, it seems you cannot go about the problem this way. While it would be reasonable to assume that a user wouldn't intentionally throw this kind of awful naming at you, it's quite conceivable that automatic code would end up doing something like this. Example:
So it would seem the names of your variables for the trivariate ring should be unrelated to the names that occur for the others. Assuming you have a polynomial g in a ring P over a number field k over QQ, I think you can do your conversion with something along the lines of
Doing your conversions like this has the advantage that you don't rely on names of generators at all. |
Branch pushed to git repo; I updated commit sha1. New commits:
|
comment:19
Attachment: qqbar.tex.gz |
Branch pushed to git repo; I updated commit sha1. New commits:
|
Branch pushed to git repo; I updated commit sha1. Last 10 new commits:
|
Branch pushed to git repo; I updated commit sha1. New commits:
|
This comment has been minimized.
This comment has been minimized.
Branch pushed to git repo; I updated commit sha1. New commits:
|
Branch pushed to git repo; I updated commit sha1. New commits:
|
Branch pushed to git repo; I updated commit sha1. New commits:
|
comment:28
Two minor things: The first is the |
Branch pushed to git repo; I updated commit sha1. New commits:
|
comment:30
Replying to @tscrim:
OK, done. I didn't remove the blank lines on the second for loop because it's so long, I feel the blank lines improve it readability. |
Reviewer: Travis Scrimshaw |
comment:31
Thanks. I disagree about the space because I have never really seen that elsewhere in Python code and it looks strange to be because of that. Yet, I don't think it is important enough to hold up the ticket. |
Changed branch from public/25390 to |
We can currently (#8544) factor univariate polynomials over QQbar:
We can factor over multivariate rings, if the polynomial is actually univariate:
But we can't do full "absolute factorization" (that's what it's called in the literature):
This ticket implements absolute factorization by calling Singular's
absfact.lib
, which works for rings over Q (or transcendental extensions thereof), and uses a technique described in the attached document to handle number fields.I flagged it
major
because polynomial factorization is a fundamental feature that blocks the implementation of other things, like primary decomposition of ideals.Depends on #25351
CC: @tom111
Component: algebra
Author: Brent Baccala
Branch/Commit:
91d467e
Reviewer: Travis Scrimshaw
Issue created by migration from https://trac.sagemath.org/ticket/25390
The text was updated successfully, but these errors were encountered: