Comics | 10 minutes to read quantum bits, quantum calculations, and quantum algorithms.

Source: Internet
Author: User

Please be prepared to enter the burning brain mode!

A lot of life experiences in the macro world are appearances. For example, you might think that the world's operation is deterministic, predictable, and that an object cannot be in two conflicting states at the same time.

In the microscopic world, this representation is broken by a law called quantum mechanics.

Quantum mechanics states that the world's operation is uncertain, and we can only predict the probability of the occurrence of a variety of outcomes; An object can be in two conflicting states at the same time.

Quantum computing is the process of manipulating data directly using phenomena of quantum mechanics, such as quantum superposition states.

In this paper, we simply introduce quantum superposition states, quantum bits, quantum measurements, and a quantum algorithm to search for random databases.

Summer is here, the scorching sun is scorching. When you wear polarized sunglasses, in a way, you begin to touch quantum computing.

Why do you say that? Because the polarization of light is "simultaneously in two contradictory states", namely the quantum superposition state. In quantum computing, the polarization of photons can be used to achieve quantum bits.

First, light is an electromagnetic wave, and the particles that make up it are called photons. The vibrations of the electromagnetic waves, like the rope wobble, can be biased toward the place, forming a variety of polarization.

Second, polarized sunglasses like a sieve, only with the gap in the direction of the sieve, photons can "drill through." If the direction of the gap is perpendicular to the sieve, the photon is completely "stopped".

It is easy to understand the polarization of photons with the jitter of a rope.

What if the photon polarization direction is neither perpendicular nor parallel to the direction of the gap, but at a certain angle?

If you are behind a photon that is polarized in the direction of the past, and a polarizing mirror that filters only the photons, you will find a very strange phenomenon of quantum mechanics: about half polarized light crosses the polarizer, and the polarization direction becomes ↑.

At this point, we can try to explain this phenomenon by using the knowledge of vector synthesis learned in high school.

Since the polarization of photons has both direction and size, we can consider the polarization of each photon as a vector. Thus, they satisfy the addition of vectors.

Since the direction of the vibration equals ↑ the direction of the vibration plus → the direction of the vibration, we can say that the polarized photons can be seen at the same time in both ↑ and → direction of vibration.

If you don't understand what it's like to have two vibrations at the same time, think of the tympanic membrane in your ear, and it's a variety of vibrations at the same time that you can hear all kinds of sounds at the same time.

At this point, we can try to explain the strange quantum phenomenon. If a polarized photon is seen as a photon at the same time in both ↑ and → two vibrations, then we can say that when the photon passed ↑ a polarizer, wherein the half → vibration was obstructed, another half ↑ vibration passed.

However, this explanation is not entirely right.

If you emit a photon towards the polarizer, you will not receive a vibrational energy that weakens the half photons after the polarizer. Instead, there is a 50% chance of receiving a ↑ photon; 50% chance of receiving nothing.

As you may remember, this is what quantum mechanics often says about "God throwing dice."

If we take ↑ photons as bit 0,→ photons as bit 1, then a photon is in the superposition state of bits 0 and bits 1 photons.

If you want to use a polarizing mirror to measure whether it is bit 0 or bit 1, you will find that the measurement results have a probability of 50% is bit 0, and 50% of the probability is bit 1.

The strange "bits" that a photon carries is called a quantum bit.

The calculation of the computer is the manipulation of the classic bits. In the same vein, the so-called quantum computer is the manipulation of quantum bits within the permissible range of quantum mechanics.

I don't know if you found out. Since qubits can be in the state of bits 0 and 1 at the same time, the quantum gate manipulates it, actually manipulating the state of bits 0 and 1 at the same time.

So, a quantum computer that manipulates 1 qubits can manipulate 2 states at the same time. If a quantum computer can manipulate n qubits at the same time, it can actually manipulate 2N states at the same time, each of which is a n-bit classic bit.

This is the parallel computing power of quantum computer lore.

Finally, let's use the Grover algorithm of quantum computation to illustrate how it is computed in parallel.

Let's say we have n unsorted data. If you use the classic algorithm to find one of the data x, the condition is that it (and only it) satisfies P (x) =true, say x represents a person's work number, P (x) is to see if he is the current CEO. Then you can only start with the first data, one by one to see it is not the CEO's work number, until you blind cat hit dead rats.

In this algorithm, the computational complexity is O (N).

In the Grover algorithm, we can store n data at the same time in the log2n qubit, and then compute the value of n function p () simultaneously, that is, it is not the CEO's work number at the same time.

of the results of n calculations, there must be 1 results that are the CEO's work number, and none of the other results. But if you rush to "read" The results at this time, you will find that the probability of each result occurring is 1/n.

It's like you use ↑ a polarizer to measure photons, and the probability of getting ↑ and → is 1/2.

The idea of the Grover algorithm is to calculate the value of n p () at the same time, not to read it, but to increase the probability that the result of the data of the CEO number will occur slightly by quantum manipulation.

The mathematical calculation proves that after repeating the above process (Π√N)/4 times, the probability of the data you are looking for will reach the maximum and reach the final (1-2-n). This time if you read the data again, you will read the data you are looking for in a great probability.

Therefore, Grover's Quantum search acceleration algorithm can reduce the search complexity to O (√n), but the probability that you will not be able to read that data will never reach 100%, but slightly less than 100%.

From the present situation, quantum computing is only performed faster than classical computations in a few computational tasks, such as the large-scale factor (Shor algorithm), random database search (Grover algorithm), and this fast method can not break free from the constraints of quantum mechanics to achieve perfection.

Note: Why the Grover algorithm must operate and can only be repeated (π√n)/4 times?

Imagine an n-dimensional space in which each dimension represents a state stored by a log2n qubit. Since this space cannot be drawn on paper, we need to make some simplification, assuming that the two-dimensional space on the right represents that n-dimensional space. One of the dimensions | X> represents the status of the data you are searching for, and another dimension |s ' > represents the addition | X> all other N-1 data in addition to the corresponding state.

The initial state of the Grover algorithm represents one of the vector |s>.

The quantum operation of the Grover algorithm is to keep the vector |s> moving towards |, just like the hour hand on the dial. X> the direction of the past, each angle can only be θ, which. Θ=2arcsin (1/√n).

Notice that we have said that the smaller the angle of a quantum superposition state to which direction it is, the greater the probability that the result will be obtained in which direction it is measured. Not difficult to calculate, will vector |s> like this toggle π/2θ? (π√n)/4 times after it with | The x> has the smallest angle, and the probability of getting the correct result you are looking for is the greatest.

Note that in this analogy, we do not consider the phase between N states, but this does not affect the outcome of the discussion.

Transferred from: http://www.sohu.com/a/150417986_224832

Comics | 10 minutes to read quantum bits, quantum calculations, and quantum algorithms.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.