Skip to content

Compute Solve traits from types as args #2101

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

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

lgoettgens
Copy link
Member

My motivation for this is to be able to set a concrete type in the @attr Any call in https://github.com/oscar-system/Oscar.jl/pull/4915/files#diff-88ef12a4e6f091b2cc3dd521d7c8be444dab854cb7aef78f6837778a274315ffR489 (something along the lines of @attr solve_context_type(base_ring_type(M))).

I also copied over the two fallbacks (for ::Any and for ::DataType) over from all of the similar functions like base_ring_type and then removed some obsolete methods.

@joschmitt does this change make sense to you?

Copy link

codecov bot commented May 28, 2025

Codecov Report

Attention: Patch coverage is 83.33333% with 4 lines in your changes missing coverage. Please review.

Project coverage is 88.36%. Comparing base (cd318ff) to head (4d0126d).

Files with missing lines Patch % Lines
src/Solve.jl 83.33% 4 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #2101      +/-   ##
==========================================
- Coverage   88.36%   88.36%   -0.01%     
==========================================
  Files         126      126              
  Lines       31656    31660       +4     
==========================================
+ Hits        27974    27975       +1     
- Misses       3682     3685       +3     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@joschmitt
Copy link
Collaborator

I think the idea was that the "best" matrix normal form does not only depend on the type. For example, a zzModRing might be a field in which case the flint RREF (or LU?) should be better than the Howell form. That being said, we never seemed to have followed through with this idea.

@thofma what do you think?

@thofma
Copy link
Member

thofma commented May 30, 2025

Yes, the idea was to combine it with something like is_known(F, :is_field) and to use RREF in this case (make it a runtime thing). We might have to untangle this somehow, but I don't know how yet. Having one type for all solve contexts (with some flag) won't work, since it needs to be extensible.

@lgoettgens
Copy link
Member Author

Yes, the idea was to combine it with something like is_known(F, :is_field) and to use RREF in this case (make it a runtime thing). We might have to untangle this somehow, but I don't know how yet. Having one type for all solve contexts (with some flag) won't work, since it needs to be extensible.

Hmm, I don't really see how to do that without making inference of all of solving impossible. But I am open to any ideas you might have on the matter

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.

3 participants