18
Quantum Computing Michael Larson

Quantum Computing Michael Larson. The Quantum Computer Quantum computers, like all computers, are machines that perform calculations upon data. Quantum

Embed Size (px)

Citation preview

Page 1: Quantum Computing Michael Larson. The Quantum Computer Quantum computers, like all computers, are machines that perform calculations upon data. Quantum

Quantum Computing

Michael Larson

Page 2: Quantum Computing Michael Larson. The Quantum Computer Quantum computers, like all computers, are machines that perform calculations upon data. Quantum

The Quantum Computer

Quantum computers, like all computers, are machines that perform calculations upon data.

Quantum computers use the principles of superposition and entanglement from the field of quantum mechanics to aid in the performance of these calculations

Page 3: Quantum Computing Michael Larson. The Quantum Computer Quantum computers, like all computers, are machines that perform calculations upon data. Quantum

Superpositioning

Superpositioning is a fundamental principle of quantum mechanics

Combinations of valid quantum states are themselves valid quantum states

An unobserved particle that is capable of being measured in one of two states exists as a superposition of those states.0 1 01

Page 4: Quantum Computing Michael Larson. The Quantum Computer Quantum computers, like all computers, are machines that perform calculations upon data. Quantum

Measurement and Decoherence

Superpositioning only occurs while the system is not being measured

When a system is measured, it’s superposition collapses to a well defined state.

A superposition can be described as the sum of the probabilities that a measurement will find a system in a certain state.

Accidental “measurement” of the quantum state leads to unintended collapse of the superposition.

Page 5: Quantum Computing Michael Larson. The Quantum Computer Quantum computers, like all computers, are machines that perform calculations upon data. Quantum

Quantum Entanglement

Quantum entanglement occurs when a group of quantum particles cannot be described independently.

For quantum computers this means that modification of a quantum bit or register will project changes onto their entangled bits or registers

For example, assume “The sum of these two bits is always 1” is a known fact.

101 0

Page 6: Quantum Computing Michael Larson. The Quantum Computer Quantum computers, like all computers, are machines that perform calculations upon data. Quantum

The Quantum Bit

In a regular computer a bit exists in one of two states, either 0 or 1.

In a quantum computer a quantum bit, or qubit exists as a superposition of these two states

The creation and manipulation of these quantum bits is the objective of quantum computing

Page 7: Quantum Computing Michael Larson. The Quantum Computer Quantum computers, like all computers, are machines that perform calculations upon data. Quantum

Registers of Qubits

A register containing n qubits can be expressed mathematically as a superposition of 2n quantum states.

These states can be described with a 2n dimensional vector with complex coefficients representing the probability of the represented state.

The sum of squares of the magnitude of these coefficients must be equal to 1.

Superpositioning and subsequent collapse upon measurement means that quantum computing is nondeterministic. Many samples should be taken to build a probability distribution when calculating an answer

Page 8: Quantum Computing Michael Larson. The Quantum Computer Quantum computers, like all computers, are machines that perform calculations upon data. Quantum

Example 3-Qubit RegisterState Coefficient Probability

000 a |a|2

001 b |b|2

010 c |c|2

011 d |d|2

100 e |e|2

101 f |f|2

110 g |g|2

111 h |h|2

Sum of Probabilities

|a|2 + |b|2 + |c|2 +|d|2 + |e|2 + |f|2 +|g|2 + |h|2 = 1

Page 9: Quantum Computing Michael Larson. The Quantum Computer Quantum computers, like all computers, are machines that perform calculations upon data. Quantum

Shor’s Algorithm

The objective of Shor’s algorithm is find a factor of a large number N. Repeatedly finding factors and dividing will result in finding all factors of N.

The proposed quantum algorithm works much faster than the best classical algorithm for integer factorization

Difficulty and time complexity of large integer factorization is the basis of many security schemes.

Page 10: Quantum Computing Michael Larson. The Quantum Computer Quantum computers, like all computers, are machines that perform calculations upon data. Quantum

Classical View of Shor’s Algorithm

1. Pick a random number a<N and see if it shares a greatest common denominator with N.

2. If the GCD is greater than 1, that GCD is a factor and we are done

3. Use the quantum portion of Shor’s algorithm to find the period of f(x) = ax mod N

4. After finding the smallest period r such that f(x)= f(x+r), this period can be used to generate ar/2 +1 and ar/2 -1, both of which are likely to have a greatest common denominator with N.

5. If not go back to step 1.

Step 3 is the quantum portion of this algorithm

Page 11: Quantum Computing Michael Larson. The Quantum Computer Quantum computers, like all computers, are machines that perform calculations upon data. Quantum

Shor’s Period Finding Subroutine

Classically we need to calculate ax mod N for every x<N, then analyze the pattern produced to find the period r.

For very large N, this very computationally and memory intensive from a classical standpoint.

Writing the algorithm as a quantum algorithm that takes advantage of the principles of entanglement and superposition would allow for massive reduction in data and computational cost

Page 12: Quantum Computing Michael Larson. The Quantum Computer Quantum computers, like all computers, are machines that perform calculations upon data. Quantum

Shor’s Period Finding Subroutine(cont)

With sufficient qubits, we can initialize a register as a superposition of every 0<=x <= N.

The calculation ax mod N can be performed using quantum gates, projecting this distribution onto the second register.

Due to effects of constructive and destructive interference in quantum algorithms, certain values of x that seperated by distance r tend to interfere constructively, while others tend to interfere destructively.

This leads to one state in the 2nd register having a much higher probability of being measured than any other.

Page 13: Quantum Computing Michael Larson. The Quantum Computer Quantum computers, like all computers, are machines that perform calculations upon data. Quantum

Shor’s Period Finding Subroutine(cont)

Due to the principles of quantum entanglement, each time a result is measured in the second register, the first register collapses to a state congruent with that state.

If ax mod N is measured to be 1, the probability will be evenly distributed in the first register among x’s such that ax mod N = 1.

Given enough sampling, a set of states separated by r would be most commonly measured in register 1 after running the algorithm and collapsing register 2

Page 14: Quantum Computing Michael Larson. The Quantum Computer Quantum computers, like all computers, are machines that perform calculations upon data. Quantum

Shor’s Period Finding Algorithm Examplex ax ax mod N =

mx (cont) ax (cont) ax mod N

=m (cont)

0 1 1 8 256 1

1 2 2 9 512 2

2 4 4 10 1024 4

3 8 8 11 2048 8

4 16 1 12 4096 1

5 32 2 13 8192 2

6 64 4 14 16384 4

7 128 8 15 32768 8

Page 15: Quantum Computing Michael Larson. The Quantum Computer Quantum computers, like all computers, are machines that perform calculations upon data. Quantum

Shor’s Period Finding Algorithm Example

Suppose that measuring the second register most commonly collapses to m = 8. Entanglement with the x register then collapses the register like so (x states not shown have 0 probability)

x ax ax mod N = m

3 8 8

7 128 8

11 2048 8

15 32768 8

Page 16: Quantum Computing Michael Larson. The Quantum Computer Quantum computers, like all computers, are machines that perform calculations upon data. Quantum

Results

Repeated experiments and measuring of the X register will lead to a distribution of elements that are multiples of 4 apart from each other

Thus r = 4N = 15, a = 2ar/2 + 1 = 5, ar/2 - 1 = 3, both of which are supposed share a greatest

common denominator with N=15. In fact 3 and 5 are verifiably the only 2 factors of 15.

Page 17: Quantum Computing Michael Larson. The Quantum Computer Quantum computers, like all computers, are machines that perform calculations upon data. Quantum

Relevance to Parallelism

Shor’s algorithm shows that with enough quantum bits and the right algorithm a quantum computer can run massively parallel code by superpositioning various possible initial states and collapsing them with measurement.

Every quantum bit effectively doubles parallelism of quantum code because it doubles the number of superpositioned states.

Page 18: Quantum Computing Michael Larson. The Quantum Computer Quantum computers, like all computers, are machines that perform calculations upon data. Quantum

Questions?*

*answered only to the best of my understanding.