Period finding is a topic in Number Theory. Modulo functions are periodic.
https://young.physics.ucsc.edu/150/period.pdf
Gemini:
This document provides a fascinating explanation of how period finding can be used to factor integers, a concept crucial to quantum computing and cryptography. Let's break down the example with a = 19
and N = 91
.
Understanding the Function:
The function f(x) ≡ a^x (mod N)
is at the heart of this method. It essentially describes the pattern of remainders when a
is raised to increasing powers and divided by N
.
The Example with a = 19
:
Period: The document states that for
a = 19
andN = 91
, the period of the function isr = 12
. This means thatf(x) = f(x + 12)
for all values ofx
.Visualizing the Period: Figure 2 in the document illustrates this. You can see the function repeats itself every 12 steps.
The Importance of an Even Period: The method relies on the period
r
being even. In this example,r = 12
is even, which is a crucial condition for the factorization to work.Finding Factors: The document explains that since
r
is even, we can use the following:a^(r/2) + 1
is divisible by one of the factors ofN
.a^(r/2) - 1
is divisible by the other factor ofN
.
Calculating Factors:
- text
a^(r/2) + 1 = 19^(12/2) + 1 = 19^6 + 1 = 47045881 + 1 = 47045882
- text
a^(r/2) - 1 = 19^(12/2) - 1 = 19^6 - 1 = 47045881 - 1 = 47045880
Using Euclid's algorithm to find the greatest common divisor (GCD) of
N = 91
with these two values:GCD(91, 47045882) = 13
GCD(91, 47045880) = 7
We have successfully factored
N = 91
into its prime factors,13
and7
.
Key Points:
- The method relies on finding the period of a specific function.
- The period needs to be even for this method to work.
- The process involves calculating two values based on the period and then using Euclid's algorithm to find the factors.
Let me know if you have any other questions!
Perplexity:
Period finding; The document explains that since r is even, we can use the following: a^(r/2) + 1 is divisible by one of the factors of N. a^(r/2) - 1 is divisible by the other factor of N. ... Can you explain this to me
Background
First, let's establish some context:- We're dealing with a composite number N that we want to factorize.
- We've chosen a random number a that is coprime to N.
- We've found the period r, which is the smallest positive integer such that a^r ≡ 1 (mod N).
- We've discovered that r is even.
The Key Insight
The statement you're asking about is based on a fundamental theorem in number theory. Here's how it works:The Equation
If r is even, we can write:a^r - 1 ≡ 0 (mod N)We can factor this as:(a^(r/2) + 1)(a^(r/2) - 1) ≡ 0 (mod N)What This Means
This factorization tells us that the product (a^(r/2) + 1)(a^(r/2) - 1) is divisible by N.Why This Is Useful
Here's the key insight:- Since N divides this product, and N is composite, it's likely that one factor of N divides (a^(r/2) + 1) and the other factor divides (a^(r/2) - 1).
- This means that:
- gcd(a^(r/2) + 1, N) is likely to be a non-trivial factor of N
- gcd(a^(r/2) - 1, N) is likely to be the other non-trivial factor of N
An Example
Let's use a simple example to illustrate:- Suppose N = 15 (factors are 3 and 5)
- Choose a = 7
- We find that r = 4 (because 7^4 ≡ 1 (mod 15))
- a^(r/2) = 7^2 = 49 ≡ 4 (mod 15)
- a^(r/2) + 1 = 4 + 1 = 5
- a^(r/2) - 1 = 4 - 1 = 3
No comments:
Post a Comment