Lecture 8: Applications of Quantum Fourier transform

Size: px
Start display at page:

Download "Lecture 8: Applications of Quantum Fourier transform"

Transcription

1 Department of Physical Sciences, University of Helsinki quantumgas/ p. 1/25 Quantum information and computing Lecture 8: Applications of Quantum Fourier transform Jani-Petri Martikainen jamartik Department of Physical Sciences University of Helsinki

2 Department of Physical Sciences, University of Helsinki quantumgas/ p. 2/25 Quantum algorithms and their relations Quantum search Fourier transform Hidden subgroup problem Quantum counting Discrete log Order finding Factoring Statistics: mean, median, min Speedup for some NP problems Search for crypto keys Break cryptosystems (RSA)

3 Department of Physical Sciences, University of Helsinki quantumgas/ p. 3/25 Application:order finding We won t give the number theoretical proofs for some statements. See the text book appendix for details if you are interested. For positive integers x and N, x < N, with no common factors (co-prime), the order of x modulo N is the least positive integer, such that x r = 1(modN). Order finding problem is to determine the order for some specified x and N This problem is believed to be hard for a classical computer For example, order of x = 5 modulo 21 is 6...(x 6 /21 gives the same remainder as 1/21)

4 Department of Physical Sciences, University of Helsinki quantumgas/ p. 4/25 Application:order finding The quantum algorithm for order finding is just the phase estimation algorithm applied to the unitary operator U y = xy(modn) (1) with y {0, 1} L. When N y 2 L 1, we use the convention that xy(modn) is just y again. That is, U acts non-trivially only when 0 y N 1. states defined by (0 s r 1) u s = 1 r 1 r k=0 [ ] 2πisk exp x k modn (2) r

5 Department of Physical Sciences, University of Helsinki quantumgas/ p. 5/25 Application:order finding are eigenstates of U since U u s = 1 r 1 [ ] 2πisk exp x k+1 modn r r k=0 [ ] 2πis = exp u s (3) r Using phase estimation we obtain, with high accuracy, the eigenvalues exp(2πis/r), from which we can obtain the order r with a little bit more work. For us to be able to use phase estimation we must be able to 1. Implement efficiently controlled-u 2n operation for any integer j 2. Prepare an eigenstate u s efficiently

6 Department of Physical Sciences, University of Helsinki quantumgas/ p. 6/25 Application:order finding The first requirement is satisfied by using a procedure known as modular exponentiation (READ FROM THE BOOK/NOTES) The second condition is trickier: preparing u s requires that we know r, so this is out of the question. We can circumvent the problem by using the clever observation that 1 r 1 u s = 1 (4) r s=0 In phase estimation if we use t = 2L [log(2 + 1/2ǫ)] qubits in the first register and we prepare the second register in the state 1 (that is easy)...

7 Department of Physical Sciences, University of Helsinki quantumgas/ p. 7/25 Application:order finding it follows that for each s in the range 0...r 1, we will obtain an estimate of the phase φ s/r accurate to 2L + 1 bits, with probability at least (1 ǫ)/r. SEE THE SCHEMATIC DIAGRAM FOR ORDER FINDING. The reduction of order-finding to phase estimation is completed by explaining how we obtain the desired answer r, from the result of the phase estimation φ s/r. We only know 2L + 1 bits, but we also know a priori that it is a rational number...if we could compute nearest such fraction to φ we might obtain r

8 Department of Physical Sciences, University of Helsinki quantumgas/ p. 8/25 Order finding:continued fraction This task can be accomplished efficiently using the continued fraction algorithm. SEE NOTES OR READ FROM THE BOOK Theorem: suppose that s/r is a rational number such that s/r φ 1/2r 2. Then s/r is a convergent of the continued fraction for φ and thus can be computed in O(L 3 ) operations.

9 Department of Physical Sciences, University of Helsinki quantumgas/ p. 9/25 Order finding:continued fraction Since φ approximates s/r with accuracy 2L + 1 bits, it follows that s/r φ 2 2L 1 1/2r 2, since r N 2 L. Thus the theorem applies. Therefore, given φ the continued fraction algorithm efficiently produces numbers s and r with no common factor, such that s /r = s/r. The number r is our candidate for the order. Candidate can be efficiently checked by computing x r modn and seeing if the result is 1. If so, then r is the order of x modulo N! Algorithm takes O(L 3 ) gates...main cost comes from modular exponentiation. see the summary in the book or notes...

10 Department of Physical Sciences, University of Helsinki quantumgas/ p. 10/25 Factoring Factoring problem: Given a positive integer N, what prime numbers have to be multiplied together to get N? This problem turns out to be equivalent to the order finding problem. Fast algorithm for order finding can be turned into a fast algorithm for factoring. 1. Show that we can compute a factor of N if we can find a non-trivial solution x ±1(modN) to the equation x 2 = 1(modN) 2. Show that a randomly chosen co-prime to N is quite likely to have an order r which is even, and such that y r/2 ±1(modN) and thus x = y r/2 (modn) is a non-trivial solution to x 2 = 1(modN).

11 Department of Physical Sciences, University of Helsinki quantumgas/ p. 11/25 Factoring Steps a embodied in the following number theoretical theorems Theorem: Suppose N is an L bit composite number, and x is a non-trivial solution to the equation x 2 = 1(modN) in the range 1 x N, that is neither x = 1(modN) nor x = N 1 = 1(modN). Then at least one of gcd(x 1,N) and gcd(x + 1,N) is a non-trivial factor of N Suppose N = p α 1 1 pα m m is the prime factorization of an odd composite positive integer. Let x be an integer chosen uniformly at random, subject to the requirements that 1 x N 1 and x is co-prime to N. Let r be the order of x modulo N. Then p(r is even and x r/2 1(modN)) 1 1/2 m

12 Department of Physical Sciences, University of Helsinki quantumgas/ p. 12/25 Factoring:algorithm These theorems can be combined to give an algorithm which returns a non-trivial factor of a composite N with high probability. 1. If N is even, return 2 2. Determine whether N = a b for integers a 1 and b 2, and if so return the factor a (this can use a classical algorithm) 3. Randomly choose x in the range 1 to N 1. If gcd(x,n) > 1 then return the factor gcd(x,n) 4. Use the order finding to find the order r of x modulo N. 5. If r even and x r/2 1(modN) then compute gcd(x r/2 1,N) and gcd(x r/2 + 1,N) and test to see if one of these is a non-trivial factor, returning the factor if so. Otherwise algorithm fails.

13 Department of Physical Sciences, University of Helsinki quantumgas/ p. 13/25 Factoring:algorithm Steps 1 and 2 either return a factor, or else ensure that N is an odd integer with more than one prime factor. Step 3 either produces a factor or else a randomly chosen element x of {0, 1, 2,...N 1}. Step 4 computes the order and step 5 completes the algorithm since the earlier theorem guarantees that either gcd(x r/2 1,N) or gcd(x r/2 + 1,N) is a non-trivial factor.

14 Department of Physical Sciences, University of Helsinki quantumgas/ p. 14/25 Factoring: 15 Take N = 15. This is not even and also not a power of anything so we can jump to the step 3 of the algorithm. Choose x = 7 (random). Compute the order r of x modulo N: We start in the state 0 0 and create the state 1 2 t 2 t 1 k 0 = 1 2 t [ t 1 ] 0 k=0 by using t = 11 Hadamard transforms to the first register. This choice of t ensures an error probability of at most 1/4. Next, compute f(k) = x k mod N

15 Department of Physical Sciences, University of Helsinki quantumgas/ p. 15/25 Factoring: 15 We leave the result in the second register so we have a state 1 2 t = 2X t 1 k=0 1 2 t k x k modn [ ] (5) (the second register qubits start repeating themselves) We now apply inverse Fourier transform FT to the first register and measure it. Since no further operations are applied to the second register, we can apply the principle of implicit measurement and assume that the second register is measured. We obtain a random result from 1,7, 4, or 13.

16 Department of Physical Sciences, University of Helsinki quantumgas/ p. 16/25 Factoring: 15 Suppose we get 4 which implies that the input to the inverse FT would have been 4 [ ] (6) 2t After applying FT we obtain a state l α l l with the probability distribution..see FIGURE...shown for 2 t = 2048 The final measurement will give either 0, 512, 1024, or 1536 each with probability almost exactly 1/4 Suppose we get l = 1536 from the measurement

17 Factoring: 15 amplitudes 1 α k k F transform 1 α l l Department of Physical Sciences, University of Helsinki quantumgas/ p. 17/25

18 Department of Physical Sciences, University of Helsinki quantumgas/ p. 18/25 Factoring: 15 Computing the continued fraction expansion thus gives 1536/2048 = 1/(1 + (1/3)) so that 3/4 occurs as a convergent in the expansion. Therefore, r = 4 is the order of x = 7. By chance, r is even, and moreover, x r/2 mod N = 7 2 mod15 1mod15 so the algorithm works Computing the greatest common divisor gcd(x 2 1, 15) = 3 and gcd(x 2 + 1, 15) = 5 tells us that 15 = 3 5

19 Department of Physical Sciences, University of Helsinki quantumgas/ p. 19/25 Period finding Suppose f is a periodic function producing a single bit as output and such that f(x + r) = f(x), for some unknown 0 < r < 2 L, where x,r {0, 1, 2,...} Given a quantum black box U which performs U x y x y f(x) ( is addition modulo 2), how many black box queries and other operations are required to determine r? Here is a quantum algorithm which solves this problem using one query, and O(L 2 ) other operations...

20 Department of Physical Sciences, University of Helsinki quantumgas/ p. 20/25 Period finding Inputs: (1) A black box which performs U, (2) a state to store the function evaluation, initialized to 0, and (3) t = O(L + log(1/ǫ)) qubits initialized to 0 Outputs: The least integer r > 0 such that f(x + r) = f(x) 1. Initial state Create superposition: 1/ 2 t 2 t 1 x=0 x 0 3. Apply U: 1/ 2 t 1 2 t x f(x) x=0 1/ r 1 r2 t l=0 2 t 1 x=0 e 2πilx/r x ˆf(l) Note: f(x) = 1/ r P r 1 l=0 e2πilx/r ˆf(l) is an identity when x is an integer multiple of r! Approximation sign needed since 2 t might not be a multiple integer of r.

21 Department of Physical Sciences, University of Helsinki quantumgas/ p. 21/25...continues Period finding 1. Apply inverse FT to the first register: r 1 l=0 l/r ˆf(l) 2. Measure first register: l/r 3. Continued fraction algorithm: r

22 Department of Physical Sciences, University of Helsinki quantumgas/ p. 22/25 Discrete logarithm Period finding was simple, in that the domain and range of the periodic function where integers. What if the function is more complex? Consider f(x 1,x 2 ) = a sx 1+x 2 modn where all variables are integers, and r is the smallest positive integer for which a r modn = 1. This function is periodic since f(x 1 + l,x 2 ls) = f(x 1,x 2 ), but the period is a 2-tuple (l, ls) This function is useful in cryptography, since determining s allows one to solve the discrete logarithm problem: given a and b = a s, what is s Here quantum algorithm solving this problem using one query of a quantum black box U

23 Department of Physical Sciences, University of Helsinki quantumgas/ p. 23/25 Discrete logarithm Inputs: (1) A black box which performs U x 1 x 2 y = x 1 x 2 y f(x 1,x 2 ) for f(x 1,x 2 ) = b x 1 a x 2, (2) a state to store the function evaluation, initialized to 0, and (3) t = O(log r + log(1/ǫ)) qubits initialized to 0 Outputs: The least positive integer s such that a s = b 1. Initial state Create superposition: 1/2 t 2 t 1 x 1 =0 2 t 1 x 2 =0 x 1 x 2 0

24 Department of Physical Sciences, University of Helsinki quantumgas/ p. 24/25...continues 1. Apply U (Key step!): 2X 1/2 t Discrete logarithm t 1 1/(2 t r) = 1/2 t r 2 t 1 X x 1 =0 x 2 =0 r 1 X x 1 x 2 f(x 1, x 2 ) 2X t 1 2X t 1 l 2 =0 x 1 =0 x 2 =0 r 1 X l 2 = X t 1 x 1 =0 e 2πi(sl 2x 1 +l 2 x 2 )/r x 1 x 2 ˆf(sl 2, l 2 ) 3 2 e 2πi(sl 2x 1 )/r x X t 1 x 2 =0 2. Apply inverse FT to first two registers: 1/ r r 1 sl 2 /r l 2 /r ˆf(sl 2,l 2 ) l 2 =0 3. Measure first two registers: ( sl 2 /r, l 2 /r) 4. Apply generalized cont. frac. alg.: s 3 e 2πi(l 2x 2 )/r x 2 5 ˆf(sl 2, l 2 )

25 Department of Physical Sciences, University of Helsinki quantumgas/ p. 25/25 General applications of QFT Earlier examples, are all examples of a very general problem known as hidden subgroup problem This problem encompasses all known exponentially fast applications of QFT Problem: Let f be a function from a finitely generated group G to a finite set X such that f is constant on the cosets of a subgroup K, and distinct on each coset. Given a quantum black box for performing the unitary transformation U g h = g h f(g), for g G, h X and an appropriately chosen binary operation on X, find a generating set for K. See the text book for more details and references

Lecture 13: Factoring Integers

Lecture 13: Factoring Integers CS 880: Quantum Information Processing 0/4/0 Lecture 3: Factoring Integers Instructor: Dieter van Melkebeek Scribe: Mark Wellons In this lecture, we review order finding and use this to develop a method

More information

Breaking The Code. Ryan Lowe. Ryan Lowe is currently a Ball State senior with a double major in Computer Science and Mathematics and

Breaking The Code. Ryan Lowe. Ryan Lowe is currently a Ball State senior with a double major in Computer Science and Mathematics and Breaking The Code Ryan Lowe Ryan Lowe is currently a Ball State senior with a double major in Computer Science and Mathematics and a minor in Applied Physics. As a sophomore, he took an independent study

More information

Lecture 13 - Basic Number Theory.

Lecture 13 - Basic Number Theory. Lecture 13 - Basic Number Theory. Boaz Barak March 22, 2010 Divisibility and primes Unless mentioned otherwise throughout this lecture all numbers are non-negative integers. We say that A divides B, denoted

More information

Quantum Computing Lecture 7. Quantum Factoring. Anuj Dawar

Quantum Computing Lecture 7. Quantum Factoring. Anuj Dawar Quantum Computing Lecture 7 Quantum Factoring Anuj Dawar Quantum Factoring A polynomial time quantum algorithm for factoring numbers was published by Peter Shor in 1994. polynomial time here means that

More information

Factoring by Quantum Computers

Factoring by Quantum Computers Factoring by Quantum Computers Ragesh Jaiswal University of California, San Diego A Quantum computer is a device that uses uantum phenomenon to perform a computation. A classical system follows a single

More information

What Has Quantum Mechanics to Do With Factoring? Things I wish they had told me about Peter Shor s algorithm

What Has Quantum Mechanics to Do With Factoring? Things I wish they had told me about Peter Shor s algorithm What Has Quantum Mechanics to Do With Factoring? Things I wish they had told me about Peter Shor s algorithm 1 Question: What has quantum mechanics to do with factoring? Answer: Nothing! 2 Question: What

More information

QUANTUM COMPUTERS AND CRYPTOGRAPHY. Mark Zhandry Stanford University

QUANTUM COMPUTERS AND CRYPTOGRAPHY. Mark Zhandry Stanford University QUANTUM COMPUTERS AND CRYPTOGRAPHY Mark Zhandry Stanford University Classical Encryption pk m c = E(pk,m) sk m = D(sk,c) m??? Quantum Computing Attack pk m aka Post-quantum Crypto c = E(pk,m) sk m = D(sk,c)

More information

Factoring & Primality

Factoring & Primality Factoring & Primality Lecturer: Dimitris Papadopoulos In this lecture we will discuss the problem of integer factorization and primality testing, two problems that have been the focus of a great amount

More information

Cryptography and Network Security Chapter 8

Cryptography and Network Security Chapter 8 Cryptography and Network Security Chapter 8 Fifth Edition by William Stallings Lecture slides by Lawrie Brown (with edits by RHB) Chapter 8 Introduction to Number Theory The Devil said to Daniel Webster:

More information

Shor s algorithm and secret sharing

Shor s algorithm and secret sharing Shor s algorithm and secret sharing Libor Nentvich: QC 23 April 2007: Shor s algorithm and secret sharing 1/41 Goals: 1 To explain why the factoring is important. 2 To describe the oldest and most successful

More information

Quantum Algorithms in NMR Experiments. 25 th May 2012 Ling LIN & Michael Loretz

Quantum Algorithms in NMR Experiments. 25 th May 2012 Ling LIN & Michael Loretz Quantum Algorithms in NMR Experiments 25 th May 2012 Ling LIN & Michael Loretz Contents 1. Introduction 2. Shor s algorithm 3. NMR quantum computer Nuclear spin qubits in a molecule NMR principles 4. Implementing

More information

0.1 Phase Estimation Technique

0.1 Phase Estimation Technique Phase Estimation In this lecture we will describe Kitaev s phase estimation algorithm, and use it to obtain an alternate derivation of a quantum factoring algorithm We will also use this technique to design

More information

Discrete Mathematics, Chapter 4: Number Theory and Cryptography

Discrete Mathematics, Chapter 4: Number Theory and Cryptography Discrete Mathematics, Chapter 4: Number Theory and Cryptography Richard Mayr University of Edinburgh, UK Richard Mayr (University of Edinburgh, UK) Discrete Mathematics. Chapter 4 1 / 35 Outline 1 Divisibility

More information

Public Key Cryptography: RSA and Lots of Number Theory

Public Key Cryptography: RSA and Lots of Number Theory Public Key Cryptography: RSA and Lots of Number Theory Public vs. Private-Key Cryptography We have just discussed traditional symmetric cryptography: Uses a single key shared between sender and receiver

More information

U.C. Berkeley CS276: Cryptography Handout 0.1 Luca Trevisan January, 2009. Notes on Algebra

U.C. Berkeley CS276: Cryptography Handout 0.1 Luca Trevisan January, 2009. Notes on Algebra U.C. Berkeley CS276: Cryptography Handout 0.1 Luca Trevisan January, 2009 Notes on Algebra These notes contain as little theory as possible, and most results are stated without proof. Any introductory

More information

An Overview of Integer Factoring Algorithms. The Problem

An Overview of Integer Factoring Algorithms. The Problem An Overview of Integer Factoring Algorithms Manindra Agrawal IITK / NUS The Problem Given an integer n, find all its prime divisors as efficiently as possible. 1 A Difficult Problem No efficient algorithm

More information

CHAPTER 5. Number Theory. 1. Integers and Division. Discussion

CHAPTER 5. Number Theory. 1. Integers and Division. Discussion CHAPTER 5 Number Theory 1. Integers and Division 1.1. Divisibility. Definition 1.1.1. Given two integers a and b we say a divides b if there is an integer c such that b = ac. If a divides b, we write a

More information

Factoring Algorithms

Factoring Algorithms Factoring Algorithms The p 1 Method and Quadratic Sieve November 17, 2008 () Factoring Algorithms November 17, 2008 1 / 12 Fermat s factoring method Fermat made the observation that if n has two factors

More information

RSA and Primality Testing

RSA and Primality Testing and Primality Testing Joan Boyar, IMADA, University of Southern Denmark Studieretningsprojekter 2010 1 / 81 Correctness of cryptography cryptography Introduction to number theory Correctness of with 2

More information

Study of algorithms for factoring integers and computing discrete logarithms

Study of algorithms for factoring integers and computing discrete logarithms Study of algorithms for factoring integers and computing discrete logarithms First Indo-French Workshop on Cryptography and Related Topics (IFW 2007) June 11 13, 2007 Paris, France Dr. Abhijit Das Department

More information

Cryptography and Network Security Chapter 9

Cryptography and Network Security Chapter 9 Cryptography and Network Security Chapter 9 Fifth Edition by William Stallings Lecture slides by Lawrie Brown (with edits by RHB) Chapter 9 Public Key Cryptography and RSA Every Egyptian received two names,

More information

= 2 + 1 2 2 = 3 4, Now assume that P (k) is true for some fixed k 2. This means that

= 2 + 1 2 2 = 3 4, Now assume that P (k) is true for some fixed k 2. This means that Instructions. Answer each of the questions on your own paper, and be sure to show your work so that partial credit can be adequately assessed. Credit will not be given for answers (even correct ones) without

More information

Cryptography and Network Security Number Theory

Cryptography and Network Security Number Theory Cryptography and Network Security Number Theory Xiang-Yang Li Introduction to Number Theory Divisors b a if a=mb for an integer m b a and c b then c a b g and b h then b (mg+nh) for any int. m,n Prime

More information

Elements of Applied Cryptography Public key encryption

Elements of Applied Cryptography Public key encryption Network Security Elements of Applied Cryptography Public key encryption Public key cryptosystem RSA and the factorization problem RSA in practice Other asymmetric ciphers Asymmetric Encryption Scheme Let

More information

Faster deterministic integer factorisation

Faster deterministic integer factorisation David Harvey (joint work with Edgar Costa, NYU) University of New South Wales 25th October 2011 The obvious mathematical breakthrough would be the development of an easy way to factor large prime numbers

More information

Advanced Cryptography

Advanced Cryptography Family Name:... First Name:... Section:... Advanced Cryptography Final Exam July 18 th, 2006 Start at 9:15, End at 12:00 This document consists of 12 pages. Instructions Electronic devices are not allowed.

More information

Bits Superposition Quantum Parallelism

Bits Superposition Quantum Parallelism 7-Qubit Quantum Computer Typical Ion Oscillations in a Trap Bits Qubits vs Each qubit can represent both a or at the same time! This phenomenon is known as Superposition. It leads to Quantum Parallelism

More information

Primality - Factorization

Primality - Factorization Primality - Factorization Christophe Ritzenthaler November 9, 2009 1 Prime and factorization Definition 1.1. An integer p > 1 is called a prime number (nombre premier) if it has only 1 and p as divisors.

More information

8 Primes and Modular Arithmetic

8 Primes and Modular Arithmetic 8 Primes and Modular Arithmetic 8.1 Primes and Factors Over two millennia ago already, people all over the world were considering the properties of numbers. One of the simplest concepts is prime numbers.

More information

ALGEBRAIC APPROACH TO COMPOSITE INTEGER FACTORIZATION

ALGEBRAIC APPROACH TO COMPOSITE INTEGER FACTORIZATION ALGEBRAIC APPROACH TO COMPOSITE INTEGER FACTORIZATION Aldrin W. Wanambisi 1* School of Pure and Applied Science, Mount Kenya University, P.O box 553-50100, Kakamega, Kenya. Shem Aywa 2 Department of Mathematics,

More information

Principles of Public Key Cryptography. Applications of Public Key Cryptography. Security in Public Key Algorithms

Principles of Public Key Cryptography. Applications of Public Key Cryptography. Security in Public Key Algorithms Principles of Public Key Cryptography Chapter : Security Techniques Background Secret Key Cryptography Public Key Cryptography Hash Functions Authentication Chapter : Security on Network and Transport

More information

MATH 168: FINAL PROJECT Troels Eriksen. 1 Introduction

MATH 168: FINAL PROJECT Troels Eriksen. 1 Introduction MATH 168: FINAL PROJECT Troels Eriksen 1 Introduction In the later years cryptosystems using elliptic curves have shown up and are claimed to be just as secure as a system like RSA with much smaller key

More information

Modern Factoring Algorithms

Modern Factoring Algorithms Modern Factoring Algorithms Kostas Bimpikis and Ragesh Jaiswal University of California, San Diego... both Gauss and lesser mathematicians may be justified in rejoicing that there is one science [number

More information

The application of prime numbers to RSA encryption

The application of prime numbers to RSA encryption The application of prime numbers to RSA encryption Prime number definition: Let us begin with the definition of a prime number p The number p, which is a member of the set of natural numbers N, is considered

More information

I. Introduction. MPRI Cours 2-12-2. Lecture IV: Integer factorization. What is the factorization of a random number? II. Smoothness testing. F.

I. Introduction. MPRI Cours 2-12-2. Lecture IV: Integer factorization. What is the factorization of a random number? II. Smoothness testing. F. F. Morain École polytechnique MPRI cours 2-12-2 2013-2014 3/22 F. Morain École polytechnique MPRI cours 2-12-2 2013-2014 4/22 MPRI Cours 2-12-2 I. Introduction Input: an integer N; logox F. Morain logocnrs

More information

Public Key Cryptography and RSA. Review: Number Theory Basics

Public Key Cryptography and RSA. Review: Number Theory Basics Public Key Cryptography and RSA Murat Kantarcioglu Based on Prof. Ninghui Li s Slides Review: Number Theory Basics Definition An integer n > 1 is called a prime number if its positive divisors are 1 and

More information

The Mathematics of the RSA Public-Key Cryptosystem

The Mathematics of the RSA Public-Key Cryptosystem The Mathematics of the RSA Public-Key Cryptosystem Burt Kaliski RSA Laboratories ABOUT THE AUTHOR: Dr Burt Kaliski is a computer scientist whose involvement with the security industry has been through

More information

Groups in Cryptography

Groups in Cryptography Groups in Cryptography Çetin Kaya Koç http://cs.ucsb.edu/~koc/cs178 koc@cs.ucsb.edu Koç (http://cs.ucsb.edu/~koc) ucsb cs 178 intro to crypto winter 2013 1 / 13 Groups in Cryptography A set S and a binary

More information

Homework # 3 Solutions

Homework # 3 Solutions Homework # 3 Solutions February, 200 Solution (2.3.5). Noting that and ( + 3 x) x 8 = + 3 x) by Equation (2.3.) x 8 x 8 = + 3 8 by Equations (2.3.7) and (2.3.0) =3 x 8 6x2 + x 3 ) = 2 + 6x 2 + x 3 x 8

More information

CONTINUED FRACTIONS AND FACTORING. Niels Lauritzen

CONTINUED FRACTIONS AND FACTORING. Niels Lauritzen CONTINUED FRACTIONS AND FACTORING Niels Lauritzen ii NIELS LAURITZEN DEPARTMENT OF MATHEMATICAL SCIENCES UNIVERSITY OF AARHUS, DENMARK EMAIL: niels@imf.au.dk URL: http://home.imf.au.dk/niels/ Contents

More information

Library (versus Language) Based Parallelism in Factoring: Experiments in MPI. Dr. Michael Alexander Dr. Sonja Sewera.

Library (versus Language) Based Parallelism in Factoring: Experiments in MPI. Dr. Michael Alexander Dr. Sonja Sewera. Library (versus Language) Based Parallelism in Factoring: Experiments in MPI Dr. Michael Alexander Dr. Sonja Sewera Talk 2007-10-19 Slide 1 of 20 Primes Definitions Prime: A whole number n is a prime number

More information

CIS 5371 Cryptography. 8. Encryption --

CIS 5371 Cryptography. 8. Encryption -- CIS 5371 Cryptography p y 8. Encryption -- Asymmetric Techniques Textbook encryption algorithms In this chapter, security (confidentiality) is considered in the following sense: All-or-nothing secrecy.

More information

Arithmetic algorithms for cryptology 5 October 2015, Paris. Sieves. Razvan Barbulescu CNRS and IMJ-PRG. R. Barbulescu Sieves 0 / 28

Arithmetic algorithms for cryptology 5 October 2015, Paris. Sieves. Razvan Barbulescu CNRS and IMJ-PRG. R. Barbulescu Sieves 0 / 28 Arithmetic algorithms for cryptology 5 October 2015, Paris Sieves Razvan Barbulescu CNRS and IMJ-PRG R. Barbulescu Sieves 0 / 28 Starting point Notations q prime g a generator of (F q ) X a (secret) integer

More information

S hor s prime factoring algorithm1 reduces the factorization of a product N 5 pp9 of distinct odd primes p and

S hor s prime factoring algorithm1 reduces the factorization of a product N 5 pp9 of distinct odd primes p and OPEN SUBJECT AREAS: QUANTUM INFORMATION QUBITS Received 21 August 2013 Accepted 3 October 2013 Published 28 October 2013 Correspondence and requests for materials should be addressed to M.R.G. (mgeller@uga.

More information

I. GROUPS: BASIC DEFINITIONS AND EXAMPLES

I. GROUPS: BASIC DEFINITIONS AND EXAMPLES I GROUPS: BASIC DEFINITIONS AND EXAMPLES Definition 1: An operation on a set G is a function : G G G Definition 2: A group is a set G which is equipped with an operation and a special element e G, called

More information

Elementary factoring algorithms

Elementary factoring algorithms Math 5330 Spring 013 Elementary factoring algorithms The RSA cryptosystem is founded on the idea that, in general, factoring is hard. Where as with Fermat s Little Theorem and some related ideas, one can

More information

Some applications of LLL

Some applications of LLL Some applications of LLL a. Factorization of polynomials As the title Factoring polynomials with rational coefficients of the original paper in which the LLL algorithm was first published (Mathematische

More information

FACTORING LARGE NUMBERS, A GREAT WAY TO SPEND A BIRTHDAY

FACTORING LARGE NUMBERS, A GREAT WAY TO SPEND A BIRTHDAY FACTORING LARGE NUMBERS, A GREAT WAY TO SPEND A BIRTHDAY LINDSEY R. BOSKO I would like to acknowledge the assistance of Dr. Michael Singer. His guidance and feedback were instrumental in completing this

More information

Quantum Computers. And How Does Nature Compute? Kenneth W. Regan 1 University at Buffalo (SUNY) 21 May, 2015. Quantum Computers

Quantum Computers. And How Does Nature Compute? Kenneth W. Regan 1 University at Buffalo (SUNY) 21 May, 2015. Quantum Computers Quantum Computers And How Does Nature Compute? Kenneth W. Regan 1 University at Buffalo (SUNY) 21 May, 2015 1 Includes joint work with Amlan Chakrabarti, U. Calcutta If you were designing Nature, how would

More information

MATH 4330/5330, Fourier Analysis Section 11, The Discrete Fourier Transform

MATH 4330/5330, Fourier Analysis Section 11, The Discrete Fourier Transform MATH 433/533, Fourier Analysis Section 11, The Discrete Fourier Transform Now, instead of considering functions defined on a continuous domain, like the interval [, 1) or the whole real line R, we wish

More information

Lukasz Pater CMMS Administrator and Developer

Lukasz Pater CMMS Administrator and Developer Lukasz Pater CMMS Administrator and Developer EDMS 1373428 Agenda Introduction Why do we need asymmetric ciphers? One-way functions RSA Cipher Message Integrity Examples Secure Socket Layer Single Sign

More information

A Recent Improvements in Quantum Model and Counter Measures in Quantum Computing

A Recent Improvements in Quantum Model and Counter Measures in Quantum Computing A Recent Improvements in Quantum Model and Counter Measures in Quantum Computing J.Senthil Murugan 1, V.Parthasarathy 2, S.Sathya 3, M.Anand 4 Assistant Professor, VelTech HighTech Dr.Rangarajan Dr.Sakunthala

More information

Chapter 3. if 2 a i then location: = i. Page 40

Chapter 3. if 2 a i then location: = i. Page 40 Chapter 3 1. Describe an algorithm that takes a list of n integers a 1,a 2,,a n and finds the number of integers each greater than five in the list. Ans: procedure greaterthanfive(a 1,,a n : integers)

More information

A New Generic Digital Signature Algorithm

A New Generic Digital Signature Algorithm Groups Complex. Cryptol.? (????), 1 16 DOI 10.1515/GCC.????.??? de Gruyter???? A New Generic Digital Signature Algorithm Jennifer Seberry, Vinhbuu To and Dongvu Tonien Abstract. In this paper, we study

More information

Chapter. Number Theory and Cryptography. Contents

Chapter. Number Theory and Cryptography. Contents Chapter 10 Number Theory and Cryptography Contents 10.1 Fundamental Algorithms Involving Numbers..... 453 10.1.1 Some Facts from Elementary Number Theory.... 453 10.1.2 Euclid s GCD Algorithm................

More information

Quantum Algorithms Lecture Notes Summer School on Theory and Technology in Quantum Information, Communication, Computation and Cryptography

Quantum Algorithms Lecture Notes Summer School on Theory and Technology in Quantum Information, Communication, Computation and Cryptography Quantum Algorithms Lecture Notes Summer School on Theory and Technology in Quantum Information, Communication, Computation and Cryptography Julia Kempe CNRS & LRI, Université de Paris-Sud 9405 Orsay, France

More information

FACTORS AND MULTIPLES Answer Key

FACTORS AND MULTIPLES Answer Key I. Find prime factors by factor tree method FACTORS AND MULTIPLES Answer Key a. 768 2 384 2 192 2 96 2 48 2 24 2 12 2 6 2 3 768 = 2*2*2*2*2*2*2*2 *3 b. 1608 3 536 2 268 2 134 2 67 1608 = 3*2*2*2*67 c.

More information

Winter Camp 2011 Polynomials Alexander Remorov. Polynomials. Alexander Remorov alexanderrem@gmail.com

Winter Camp 2011 Polynomials Alexander Remorov. Polynomials. Alexander Remorov alexanderrem@gmail.com Polynomials Alexander Remorov alexanderrem@gmail.com Warm-up Problem 1: Let f(x) be a quadratic polynomial. Prove that there exist quadratic polynomials g(x) and h(x) such that f(x)f(x + 1) = g(h(x)).

More information

RSA Question 2. Bob thinks that p and q are primes but p isn t. Then, Bob thinks Φ Bob :=(p-1)(q-1) = φ(n). Is this true?

RSA Question 2. Bob thinks that p and q are primes but p isn t. Then, Bob thinks Φ Bob :=(p-1)(q-1) = φ(n). Is this true? RSA Question 2 Bob thinks that p and q are primes but p isn t. Then, Bob thinks Φ Bob :=(p-1)(q-1) = φ(n). Is this true? Bob chooses a random e (1 < e < Φ Bob ) such that gcd(e,φ Bob )=1. Then, d = e -1

More information

CS 103X: Discrete Structures Homework Assignment 3 Solutions

CS 103X: Discrete Structures Homework Assignment 3 Solutions CS 103X: Discrete Structures Homework Assignment 3 s Exercise 1 (20 points). On well-ordering and induction: (a) Prove the induction principle from the well-ordering principle. (b) Prove the well-ordering

More information

Notes on Factoring. MA 206 Kurt Bryan

Notes on Factoring. MA 206 Kurt Bryan The General Approach Notes on Factoring MA 26 Kurt Bryan Suppose I hand you n, a 2 digit integer and tell you that n is composite, with smallest prime factor around 5 digits. Finding a nontrivial factor

More information

Grade 7/8 Math Circles Fall 2012 Factors and Primes

Grade 7/8 Math Circles Fall 2012 Factors and Primes 1 University of Waterloo Faculty of Mathematics Centre for Education in Mathematics and Computing Grade 7/8 Math Circles Fall 2012 Factors and Primes Factors Definition: A factor of a number is a whole

More information

Quotient Rings and Field Extensions

Quotient Rings and Field Extensions Chapter 5 Quotient Rings and Field Extensions In this chapter we describe a method for producing field extension of a given field. If F is a field, then a field extension is a field K that contains F.

More information

Cryptography and Network Security Department of Computer Science and Engineering Indian Institute of Technology Kharagpur

Cryptography and Network Security Department of Computer Science and Engineering Indian Institute of Technology Kharagpur Cryptography and Network Security Department of Computer Science and Engineering Indian Institute of Technology Kharagpur Module No. # 01 Lecture No. # 05 Classic Cryptosystems (Refer Slide Time: 00:42)

More information

Introduction to Finite Fields (cont.)

Introduction to Finite Fields (cont.) Chapter 6 Introduction to Finite Fields (cont.) 6.1 Recall Theorem. Z m is a field m is a prime number. Theorem (Subfield Isomorphic to Z p ). Every finite field has the order of a power of a prime number

More information

RSA Attacks. By Abdulaziz Alrasheed and Fatima

RSA Attacks. By Abdulaziz Alrasheed and Fatima RSA Attacks By Abdulaziz Alrasheed and Fatima 1 Introduction Invented by Ron Rivest, Adi Shamir, and Len Adleman [1], the RSA cryptosystem was first revealed in the August 1977 issue of Scientific American.

More information

CONTINUED FRACTIONS AND PELL S EQUATION. Contents 1. Continued Fractions 1 2. Solution to Pell s Equation 9 References 12

CONTINUED FRACTIONS AND PELL S EQUATION. Contents 1. Continued Fractions 1 2. Solution to Pell s Equation 9 References 12 CONTINUED FRACTIONS AND PELL S EQUATION SEUNG HYUN YANG Abstract. In this REU paper, I will use some important characteristics of continued fractions to give the complete set of solutions to Pell s equation.

More information

Stupid Divisibility Tricks

Stupid Divisibility Tricks Stupid Divisibility Tricks 101 Ways to Stupefy Your Friends Appeared in Math Horizons November, 2006 Marc Renault Shippensburg University Mathematics Department 1871 Old Main Road Shippensburg, PA 17013

More information

Integer Factorization using the Quadratic Sieve

Integer Factorization using the Quadratic Sieve Integer Factorization using the Quadratic Sieve Chad Seibert* Division of Science and Mathematics University of Minnesota, Morris Morris, MN 56567 seib0060@morris.umn.edu March 16, 2011 Abstract We give

More information

arxiv:quant-ph/9508027v2 25 Jan 1996

arxiv:quant-ph/9508027v2 25 Jan 1996 Polynomial-Time Algorithms for Prime Factorization and Discrete Logarithms on a Quantum Computer arxiv:quant-ph/9508027v2 25 Jan 1996 Peter W. Shor Abstract A digital computer is generally believed to

More information

How To Know If A Message Is From A Person Or A Machine

How To Know If A Message Is From A Person Or A Machine The RSA Algorithm Evgeny Milanov 3 June 2009 In 1978, Ron Rivest, Adi Shamir, and Leonard Adleman introduced a cryptographic algorithm, which was essentially to replace the less secure National Bureau

More information

1 Formulating The Low Degree Testing Problem

1 Formulating The Low Degree Testing Problem 6.895 PCP and Hardness of Approximation MIT, Fall 2010 Lecture 5: Linearity Testing Lecturer: Dana Moshkovitz Scribe: Gregory Minton and Dana Moshkovitz In the last lecture, we proved a weak PCP Theorem,

More information

Cryptography and Network Security

Cryptography and Network Security Cryptography and Network Security Fifth Edition by William Stallings Chapter 9 Public Key Cryptography and RSA Private-Key Cryptography traditional private/secret/single key cryptography uses one key shared

More information

THE NUMBER OF REPRESENTATIONS OF n OF THE FORM n = x 2 2 y, x > 0, y 0

THE NUMBER OF REPRESENTATIONS OF n OF THE FORM n = x 2 2 y, x > 0, y 0 THE NUMBER OF REPRESENTATIONS OF n OF THE FORM n = x 2 2 y, x > 0, y 0 RICHARD J. MATHAR Abstract. We count solutions to the Ramanujan-Nagell equation 2 y +n = x 2 for fixed positive n. The computational

More information

CIS 6930 Emerging Topics in Network Security. Topic 2. Network Security Primitives

CIS 6930 Emerging Topics in Network Security. Topic 2. Network Security Primitives CIS 6930 Emerging Topics in Network Security Topic 2. Network Security Primitives 1 Outline Absolute basics Encryption/Decryption; Digital signatures; D-H key exchange; Hash functions; Application of hash

More information

Factoring Algorithms Based on NMR Quantum

Factoring Algorithms Based on NMR Quantum 1295 2002 69-74 69 Factoring Algorithms Based on NMR Quantum Computers (Noboru Kunihiro) (Shigeru Yamashita) NTT NTT Abstract No polynomial time algorithms have been proposed for the factoring and discrete

More information

SUBGROUPS OF CYCLIC GROUPS. 1. Introduction In a group G, we denote the (cyclic) group of powers of some g G by

SUBGROUPS OF CYCLIC GROUPS. 1. Introduction In a group G, we denote the (cyclic) group of powers of some g G by SUBGROUPS OF CYCLIC GROUPS KEITH CONRAD 1. Introduction In a group G, we denote the (cyclic) group of powers of some g G by g = {g k : k Z}. If G = g, then G itself is cyclic, with g as a generator. Examples

More information

Computing exponents modulo a number: Repeated squaring

Computing exponents modulo a number: Repeated squaring Computing exponents modulo a number: Repeated squaring How do you compute (1415) 13 mod 2537 = 2182 using just a calculator? Or how do you check that 2 340 mod 341 = 1? You can do this using the method

More information

The van Hoeij Algorithm for Factoring Polynomials

The van Hoeij Algorithm for Factoring Polynomials The van Hoeij Algorithm for Factoring Polynomials Jürgen Klüners Abstract In this survey we report about a new algorithm for factoring polynomials due to Mark van Hoeij. The main idea is that the combinatorial

More information

minimal polyonomial Example

minimal polyonomial Example Minimal Polynomials Definition Let α be an element in GF(p e ). We call the monic polynomial of smallest degree which has coefficients in GF(p) and α as a root, the minimal polyonomial of α. Example: We

More information

Basic Algorithms In Computer Algebra

Basic Algorithms In Computer Algebra Basic Algorithms In Computer Algebra Kaiserslautern SS 2011 Prof. Dr. Wolfram Decker 2. Mai 2011 References Cohen, H.: A Course in Computational Algebraic Number Theory. Springer, 1993. Cox, D.; Little,

More information

CSCE 465 Computer & Network Security

CSCE 465 Computer & Network Security CSCE 465 Computer & Network Security Instructor: Dr. Guofei Gu http://courses.cse.tamu.edu/guofei/csce465/ Public Key Cryptogrophy 1 Roadmap Introduction RSA Diffie-Hellman Key Exchange Public key and

More information

Is n a Prime Number? Manindra Agrawal. March 27, 2006, Delft. IIT Kanpur

Is n a Prime Number? Manindra Agrawal. March 27, 2006, Delft. IIT Kanpur Is n a Prime Number? Manindra Agrawal IIT Kanpur March 27, 2006, Delft Manindra Agrawal (IIT Kanpur) Is n a Prime Number? March 27, 2006, Delft 1 / 47 Overview 1 The Problem 2 Two Simple, and Slow, Methods

More information

Table of Contents. Bibliografische Informationen http://d-nb.info/996514864. digitalisiert durch

Table of Contents. Bibliografische Informationen http://d-nb.info/996514864. digitalisiert durch 1 Introduction to Cryptography and Data Security 1 1.1 Overview of Cryptology (and This Book) 2 1.2 Symmetric Cryptography 4 1.2.1 Basics 4 1.2.2 Simple Symmetric Encryption: The Substitution Cipher...

More information

Factoring Algorithms

Factoring Algorithms Institutionen för Informationsteknologi Lunds Tekniska Högskola Department of Information Technology Lund University Cryptology - Project 1 Factoring Algorithms The purpose of this project is to understand

More information

Influences in low-degree polynomials

Influences in low-degree polynomials Influences in low-degree polynomials Artūrs Bačkurs December 12, 2012 1 Introduction In 3] it is conjectured that every bounded real polynomial has a highly influential variable The conjecture is known

More information

3. Computational Complexity.

3. Computational Complexity. 3. Computational Complexity. (A) Introduction. As we will see, most cryptographic systems derive their supposed security from the presumed inability of any adversary to crack certain (number theoretic)

More information

Lecture 2: Universality

Lecture 2: Universality CS 710: Complexity Theory 1/21/2010 Lecture 2: Universality Instructor: Dieter van Melkebeek Scribe: Tyson Williams In this lecture, we introduce the notion of a universal machine, develop efficient universal

More information

Lecture Note 5 PUBLIC-KEY CRYPTOGRAPHY. Sourav Mukhopadhyay

Lecture Note 5 PUBLIC-KEY CRYPTOGRAPHY. Sourav Mukhopadhyay Lecture Note 5 PUBLIC-KEY CRYPTOGRAPHY Sourav Mukhopadhyay Cryptography and Network Security - MA61027 Modern/Public-key cryptography started in 1976 with the publication of the following paper. W. Diffie

More information

Using quantum computing to realize the Fourier Transform in computer vision applications

Using quantum computing to realize the Fourier Transform in computer vision applications Using quantum computing to realize the Fourier Transorm in computer vision applications Renato O. Violin and José H. Saito Computing Department Federal University o São Carlos {renato_violin, saito }@dc.uscar.br

More information

Algorithms with numbers

Algorithms with numbers Chapter 1 Algorithms with numbers One of the main themes of this chapter is the dramatic contrast between two ancient problems that at first seem very similar: Factoring: Given a number N, express it as

More information

Number Theory. Proof. Suppose otherwise. Then there would be a finite number n of primes, which we may

Number Theory. Proof. Suppose otherwise. Then there would be a finite number n of primes, which we may Number Theory Divisibility and Primes Definition. If a and b are integers and there is some integer c such that a = b c, then we say that b divides a or is a factor or divisor of a and write b a. Definition

More information

Software Implementation of Gong-Harn Public-key Cryptosystem and Analysis

Software Implementation of Gong-Harn Public-key Cryptosystem and Analysis Software Implementation of Gong-Harn Public-key Cryptosystem and Analysis by Susana Sin A thesis presented to the University of Waterloo in fulfilment of the thesis requirement for the degree of Master

More information

Factoring integers, Producing primes and the RSA cryptosystem Harish-Chandra Research Institute

Factoring integers, Producing primes and the RSA cryptosystem Harish-Chandra Research Institute RSA cryptosystem HRI, Allahabad, February, 2005 0 Factoring integers, Producing primes and the RSA cryptosystem Harish-Chandra Research Institute Allahabad (UP), INDIA February, 2005 RSA cryptosystem HRI,

More information

COMP 250 Fall 2012 lecture 2 binary representations Sept. 11, 2012

COMP 250 Fall 2012 lecture 2 binary representations Sept. 11, 2012 Binary numbers The reason humans represent numbers using decimal (the ten digits from 0,1,... 9) is that we have ten fingers. There is no other reason than that. There is nothing special otherwise about

More information

Elementary Number Theory and Methods of Proof. CSE 215, Foundations of Computer Science Stony Brook University http://www.cs.stonybrook.

Elementary Number Theory and Methods of Proof. CSE 215, Foundations of Computer Science Stony Brook University http://www.cs.stonybrook. Elementary Number Theory and Methods of Proof CSE 215, Foundations of Computer Science Stony Brook University http://www.cs.stonybrook.edu/~cse215 1 Number theory Properties: 2 Properties of integers (whole

More information

Factoring pq 2 with Quadratic Forms: Nice Cryptanalyses

Factoring pq 2 with Quadratic Forms: Nice Cryptanalyses Factoring pq 2 with Quadratic Forms: Nice Cryptanalyses Phong Nguyễn http://www.di.ens.fr/~pnguyen & ASIACRYPT 2009 Joint work with G. Castagnos, A. Joux and F. Laguillaumie Summary Factoring A New Factoring

More information

Recent Breakthrough in Primality Testing

Recent Breakthrough in Primality Testing Nonlinear Analysis: Modelling and Control, 2004, Vol. 9, No. 2, 171 184 Recent Breakthrough in Primality Testing R. Šleževičienė, J. Steuding, S. Turskienė Department of Computer Science, Faculty of Physics

More information

Quantum Computers vs. Computers Security. @veorq http://aumasson.jp

Quantum Computers vs. Computers Security. @veorq http://aumasson.jp Quantum Computers vs. Computers Security @veorq http://aumasson.jp Schrodinger equation Entanglement Bell states EPR pairs Wave functions Uncertainty principle Tensor products Unitary matrices Hilbert

More information

Applications of Fermat s Little Theorem and Congruences

Applications of Fermat s Little Theorem and Congruences Applications of Fermat s Little Theorem and Congruences Definition: Let m be a positive integer. Then integers a and b are congruent modulo m, denoted by a b mod m, if m (a b). Example: 3 1 mod 2, 6 4

More information