Skip to content
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

basis improvements for Artinian tower rings #3519

Open
wants to merge 17 commits into
base: development
Choose a base branch
from

Conversation

mahrud
Copy link
Member

@mahrud mahrud commented Oct 15, 2024

Summary of changes:

  • added helper routine inducedBasisMap
  • added helper routine inducedTruncationMap
  • added tests for a tricky example
  • added basis of a matrix of finite length modules
    • this is a much needed feature, to get the change of basis matrix induced by multiplication by a function in an Artinian ring, for instance.
  • added basis for ring map of Artinian rings
    • this time the change of basis matrix induced by a ring map of Artinian rings, which is often very useful.
  • added tests and docs for basis Matrix
  • changed [basis, Variable] to accept a sequence
  • fixed a bug in basis of tower rings
    • this is a somewhat breaking change because the default behavior of basis in a tower ring is changing, but it's needed to fix a bug.

The rest are fixes corresponding to the breaking change above:

  • changed a line in documentation of basis
  • added tests and docs for basis RingMap
  • fixed a basis computation in PushForward
  • fixed a basis computation in Schubert2
  • fixup a basis computation in DGAlgebras
  • fixed a basis computation in Book3264Examples
  • fixed a basis computation in GradedLieAlgebras
  • fixed a basis computation in PushForward

@mahrud
Copy link
Member Author

mahrud commented Oct 15, 2024

The failing build is an unrelated SumsOfSquares test.

@d-torrance
Copy link
Member

I think the SumsOfSquares test might actually be kind of related. If I remember when playing with this in the format PR recently, the matrix that gets sent to CSDP can vary depending on the ordering of some monomials in a set, which will depend on their hash codes. I'm not 100% sure how hash codes for monomials are generated, but if they're based at all on the symbols used for the polynomial ring, then they'll depend on how many times we've called nextHash.

So anytime we add some more things to Core, we'll risk changing these hash codes and changing the matrix that gets sent to CSDP. At one point, I had a possible fix that would preserve the order, but that ended up not going in the final version of that PR.

@mahrud
Copy link
Member Author

mahrud commented Oct 15, 2024

Wouldn't it consistently fail regardless of the build though? I'm not able to reproduce this locally.

@d-torrance
Copy link
Member

d-torrance commented Oct 15, 2024

Wouldn't it consistently fail regardless of the build though? I'm not able to reproduce this locally.

You'd think so, but I wasn't able to reproduce it locally either. I've only seen it on the Ubuntu 24.04 GitHub builds. And I'm running Ubuntu 24.04 locally using the exact same CSDP package that gets installed on the GitHub runners! It's very strange.

Edit: I just noticed that it actually failed on a macOS runner instead this time.

@mahrud mahrud marked this pull request as ready for review October 18, 2024 03:54
@mahrud
Copy link
Member Author

mahrud commented Oct 18, 2024

@mikestillman here is the only breaking change in this PR:

Before: basis of a tower ring gave the generators over the coefficient ring, but this meant that getting the basis of the whole tower ring was impossible.

i1 : R = QQ[x]/x^2;

i2 : basis R

o2 = | 1 x |

             1      2
o2 : Matrix R  <-- R

i3 : S = R[y]/y^2;

i4 : basis S

o4 = | 1 y |

             1      2
o4 : Matrix S  <-- S

i5 : T = QQ[x][y]/y^2;

i6 : basis T

o6 = | 1 y |

             1      2
o6 : Matrix T  <-- T

i7 : T = QQ[s][t]/t^2;

i8 : basis T

o8 = | 1 t |

             1      2
o8 : Matrix T  <-- T

After: basis of a tower ring uses all generators in the flat monoid, and you can use the Variables option to limit it to only variables of the most recent ring, for instance:

i1 : R = QQ[x]/x^2;

i2 : basis R

o2 = | 1 x |

             1      2
o2 : Matrix R  <-- R

i3 : S = R[y]/y^2;

i4 : basis S

o4 = | 1 y xy x |

             1      4
o4 : Matrix S  <-- S

i5 : basis(S, Variables => S_*)

o5 = | 1 y |

             1      2
o5 : Matrix S  <-- S

i7 : T = QQ[s][t]/t^2;

i8 : basis T
stdio:8:5:(3): error: module given is not finite over the base

i9 : basis(T, Variables => {t})

o9 = | 1 t |

             1      2
o9 : Matrix T  <-- T

@mahrud mahrud changed the title basis improvements basis improvements for tower rings and Artinian rings Oct 18, 2024
@mahrud mahrud changed the title basis improvements for tower rings and Artinian rings basis improvements for Artinian tower rings Oct 18, 2024
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