-
-
Notifications
You must be signed in to change notification settings - Fork 601
Add skew Hadamard matrices up to order 1000 #35211
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
Add skew Hadamard matrices up to order 1000 #35211
Conversation
…m polynomial ring
can we get a test function, with And something similar for the skew case. |
I've added the function, but I didn't write the tests because they would take too long (around 10 min each). |
Documentation preview for this PR is ready! 🎉 |
It still needs a doctest that is run. I would extend the functionality slightly by adding an extra |
a function with prefixed by |
@dimpase That is completely wrong. That only applies to |
No, this is too restrictive. If true, this'd have effectively prevented Sage to have functions which are too long to run in doctests. And the function we are talking about is one of these. |
It is effectively a test itself, to be triggered by hand. There are other such functions, e.g. in graphs/ |
It is the rule, one I fully support. To me, this is suggesting that the function design is wrong. Again, see my suggestion about adding another parameter to set the upper bound. Or this should just become a doctest, with perhaps a smaller bound that is tested. Right now, this function is useless because it is not tested (so if something breaks, nobody will know) and not publicly shown (so nobody will even know to do this test). |
It is in the source, thus it is known. |
It is an important function, just too slow, for a good reason, to be tested in a doctest. That's all. |
Being in the source code (but not in the public documentation) does not make it discoverable. Who is going to even know about this, much less test it (which you are saying needs to be done by hand)? It is not even clear what that correct output should be. If it was just a doctest itself (marked with From another perspective, all of these constructions are actually tested at some place in the code. The point is to have a way for the user to iterate over the list of constructions to see which actually work in some range. Right now, it is basically just a doctest since the bounds are fixed, but it is put as a function. It seems like you want something more like In short, if it is important, then why isn't it public (and part of the standard doctests with some cutoff)? |
would it be OK to remove Also, make the name more descriptive, i.e. not |
Strictly speaking, that is not sufficient, but I can compromise on it. However, it still is speaking to me and saying that it should just be a doctest rather than a function. It feels like a magic number is being used. |
OK, @MatteoCati - how about indeed converting it into doctests, (tagged |
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.
Thank you. One last little thing (mostly formatting), but you are free to choose which option (some variation of it is also okay).
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.
Thank you.
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.
Great!
📚 Description
This PR adds constructions for all known skew Hadamard matrices of order up to 1000. The following changes have been made:
difference_family.py
have been changed so that now they also return the group to which the sets belong. This makes the functions consistent with the others contained in this file, and makes them more efficient.Note that only commits from c0eb0c1 are new, the older ones where created in #35059.
📝 Checklist
⌛ Dependencies
#35059: this PR adds (non skew) Hadamard matrices of order <= 1000