CSE442T Introduction to Cryptography (Lecture 7)
Chapter 2: Computational Hardness
Letter choosing experiment
For 100 letter tiles,
(with one blank)
For any , .
By Cauchy-Schwarz: .
let , , so . So
So for an adversary , who random choose and output if matched.
So
Modular arithmetic
For ,
Ex: , .
Equivalent relations for any on
and
Division Theorem
For any , and , .
with modular arithmetic.
Theorem: If and, then .
Definition: , is the maximum number such that and .
Using normal factoring is slow… (Example: large , )
Euclidean algorithm
Recursively relying on fact that
def euclidean_algorithm(a,b):
if a<b: return euclidean_algorithm(b,a)
if b==0: return a
return euclidean_algorithm(b,a%b)Proof:
We’ll show and and
,
,
Runtime analysis:
Fact:
Proof:
Since , and , , and in worst case is , so
(linear in size of bits input)
Extended Euclidean algorithm
Our goal is to find such that
Given , we do euclidean algorithm to find , then reverse the steps to find such that
def extended_euclidean_algorithm(a,b):
if a%b==0: return (0,1)
x,y=extended_euclidean_algorithm(b,a%b)
return (y,x-y*(a//b))Example: ,
So
Last updated on