Skip to content

Feat/shor classical implementation #12799

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 2 commits into
base: master
Choose a base branch
from

Conversation

khushipy
Copy link

@khushipy khushipy commented Jun 18, 2025

This PR adds a classical implementation of Shor’s Algorithm to the cryptography module. The algorithm factors a given composite number N by:

  • Checking for trivial factors using GCD
  • Finding the order of a random integer a modulo N
  • Using the order to derive factors of N
    Changes:
    Added shor_algorithm.py in cryptography directory
    Implemented modular exponentiation and order-finding methods
    Added tests in cryptography
    Issue Reference: Request to Implement Shor Algorithm #12318

@algorithms-keeper algorithms-keeper bot added the tests are failing Do not merge until tests pass label Jun 18, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
tests are failing Do not merge until tests pass
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant