-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
invmod(n::BitInteger): efficient native modular inverses #52180
Conversation
I'm not sure this is |
It's a modular inverse where the modulus is implied by the type. In an alternate history I could see having I'm certainly ok with having an |
my point is that I don't think |
899c393
to
63c15e5
Compare
Mod by the the modulus implied by type of the argument. It seems reasonable to have an abbreviation for |
fair enough. |
fbe8426
to
bb1307d
Compare
bb1307d
to
3004076
Compare
Implement algorithm described in https://arxiv.org/pdf/2204.04342.pdf
3004076
to
40ce565
Compare
Failures look unrelated, this is a simple PR, and there's a decent spread of successes, so I'm gonna merge. |
Implement algorithm described in https://arxiv.org/pdf/2204.04342.pdf. The algorithm is pleasingly simple and efficient and the generic Julia implementation is also really enjoyable.