-
Notifications
You must be signed in to change notification settings - Fork 126
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 #4018 #4038
Fix #4018 #4038
Conversation
Maybe @ederc or @jankoboehm know more? |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #4038 +/- ##
==========================================
+ Coverage 84.58% 85.08% +0.49%
==========================================
Files 597 613 +16
Lines 82237 87693 +5456
==========================================
+ Hits 69559 74610 +5051
- Misses 12678 13083 +405
|
I realize now that my "fix" only works by coincidence, that is, because the ordering we want on the Singular side in this example happens to be the default (degrevlex). |
Tracing the bug here, I see a couple of things with idealGens, groebner_assure etc which I do not quite understand. I must discuss this with @ederc, @hannes14. return ideal(IdealGens(base,base.(gens(I)), o; |
I did another fix now. I am more confident of this, but someone who knows about these |
G = groebner_assure(I) | ||
cf = Singular.hilbert_series_data(G.S, W) | ||
S = singular_groebner_generators(I, false, true) | ||
cf = Singular.hilbert_series_data(S, W) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I assume that we want singular_groebner_generators
here and not just groebner_assure
. The doc string of groebner_assure
explains that one should not rely on the basis being defined on the Singular side.
I also assume that we need a global ordering here; otherwise one can change the true
to false
.
S = Singular.map_ideal(f, B.gens.S) | ||
if isdefined(B, :ord) && B.ord == monorder | ||
S.isGB = B.isGB | ||
end | ||
return S |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should fix the main problem in #4018: singular_generators
would not carry the information that the polynomials form a Gröbner basis with respect to monorder
over to the Singular side.
src/Rings/mpoly.jl
Outdated
if I.isGB | ||
if I.isGB && I.ord == monomial_ordering(I.gens.Ox, internal_ordering(I.gens.Sx)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This was wrong: the polynomial ring on the Singular side might have a monomial ordering different from I.ord
.
We discussed this during triage. The plan is to wait until after the OSCAr workshop in two weeks, during which hopefully the underlying issue can be resolved. If this for some reason doesn't happen, we can discuss again if we want to merge this for the time being until a "proper" fix can be implemented. |
I think that the fixes @joschmitt provides in this PR are the correct ones. There is, as @wdecker pointed out, another problem with |
For the above mentioned |
At last week's triage meeting, there was talk about an underlying issue and @fingolfin's summary above says that this pull request should wait, at least until the coding sprint next week. I don't want to restart the discussion; if somebody thinks this should be merged "as is", please do so. Otherwise I'm happy to talk about it next week. |
Since the "deeper" issue is fixed and @ederc thinks this PR is good to go, I'll merge it now. |
(Sorry for the duplicate, #4037 was the wrong branch.)
This fixes #4018 for me.
Apparently, one should not setkeep_ordering = true
in this case. Otherwise the ordering on the Singular side is set to what is nowadays calledinternal_ordering
, so lex in this case.I don't understand what the point of
keep_ordering
is. Does somebody know?