If you think of “regular” computers as machines that do mathematical operations over numbers, you can think of quantum computers as doing “quantum” mathematical operations.
You can ask a regular computer what’s 2+3 and it’ll tell you it’s 5. You can then use that result in your next computation and e.g. multiply it by by 5, then check if the result is an odd number.
A quantum computer can do all that, but it can also perform a type of operation where the result doesn’t need to be known right away. You can tell it that you’re interested in 2+3 but that you don’t need it right now – so the result can be kept in a superposition where it’s “some number between 2 and 10”. If you then multiply it by two, you can do it in a way that preserves the superposition, so it’s now “some number between 4 and 20”.
If at this point, however, you check if it’s odd or not, the quantum computer needs to actually collapse the superposition, i.e. “between 4 and 20” is no longer sufficient to get the answer you need and you need to know the real result. But doing this is no faster than doing it on a regular computer, so this type of work isn’t made better by using a quantum computer!
There are, however, some operations that can be made faster this way – for example, if you had a few dozen numbers you calculated using quantum operations and they are all in superpositions, you could use a type of operation unique to quantum computers where you ask “is any of these numbers odd”. This won’t tell you *which* number is odd – that would still require calculating all of them – but if you at least know none of them are, you’ll at least save some time not checking any. In contrast, a regular computer *must* calculate all of them before it can confidently tell you none of them are odd.
A way to think about quantum computers is that they can consider an entire puzzle at once.
As long as they have enough memory to fit the entire puzzle in one go.
If you can define your puzzle well, the quantum computer will consider all at once and then spit out all the solutions. Meanwhile binary computers have to do it step by step.
An often used example is postman problems, which ask ‘what is the shortest route to visit a lot of locations.’ On a binary computer these tend to be polynomial. Every extra location adds a ton of extra options to consider. But if you have enough qubits to fit the entire question into a quantum computer, then it solves it all in one go.
The difference in results can be dramatic. With current computing power, multiplied primes used for passwords take billions of years to solve. If someone builds a QC that can fit the primes puzzle in its memory, it solves it in a few minutes.
There are quite a few problems in the world that could be solved in this regard. For instance, around protein folding, which comes in to play in a lot of medicine.
But these machines are not ‘fast’ in the general sense as people think about normal computers. Single calculations are many orders of magnitudes slower. They won’t make for a magic computer future.
In the quantum world, there is a phenomenom called entanglement. Multiple particles can exist in every possible configuration at the same time, and the number of configurations grows exponentially with the number of particles. But when you look at them, you only see 1 random configuration. It’s as if nature has a giant spreadsheet off to the side somewhere that we never get to see.
That is the big idea behind quantum computing: Use nature itself as the computer.
The other phenomenon is interference. If you want to know the probability of seeing a set of particles in some configuration, you add up the probability of each possible path the particles took to get there. In quantum mechanics, probabilities can be negative. There might be paths with negative and positive probabilities and they cancel out, you never see the particles in that configuration. Or paths with positive probabilities that increase the likelihood of seeing that configuration.
This is why you get the “interference pattern” in the double-slit experiment.
What a quantum computer does is orchestrate an interference pattern that cancels out the probabilities of seeing wrong answers and amplifies the probability of seeing right answers.
So there are a set of mathematical problems or equations/formulas that are virtually and physically impossible to solve with modern day computers this is because of the speed it takes to calculate something.
With quantum computing you are supposed to have a jump in speed of processing those calculations such that they are possible to be calculated within your lifespan.
All computers are based on a type of mechanics. We currently have two type of mechanics to make computers with:
* **Classical mechanics** which we can use to create “boolean logic” computers; your every day computer. Although we normally make a computer with chips, this is still equivalent to a computer with moving parts.
* Data: The smallest variable is a “bit” which is true or false (1 or 0).
* Processing: With boolean logic building blocks you can combine it to a computer which can process data.
* **Quantum mechanics** which we can use to create “quantum logic” computers.
* Data: Represented by a **q**ubit which is, as long as you are not looking, not confined to being true or false. The “value” of a qubit can be seen as the position on a sphere (3d). But when you look, it collapses to the top of the sphere (true) or the bottom (false), whichever is closer (statistically).
* Processing: This is more complicated, but remember that we don’t look at the qubits before we are done…
* The quantum operators allow the qubit value to be “changed” (e.g. you rotate the position, move up or down). An operator can use more than one qubit input. A number of operators combined can be seen as an algorithm.
* It all seems “too simplistic” to be able to do something, but the funny thing is that with a few operators you can create algorithms which *converge* the qubits to the solution (i.e. “search”). You need to run these algorithms a few times to get a reliable answer (but that is pretty quick, so no problem).
* Practical limitations are the number of qubits and the connectivity between qubits (placing random operators between large amounts of qubits is still a challenge I believe). This makes it suitable for specific problems (smaller inputs, large problem space, small output).
Not really a ELI5 explanation, but the following is how I understand it.
In a classical computer, a 32-bit register can contain one of 2^32 different states at any given time. Each bit can be either 0 or 1, representing a single, specific state out of the possible 2^32 states.
In contrast, a quantum computer uses quantum bits, or q-bits, which can represent multiple states simultaneously due to the principle of superposition. The state of 32 q-bits is a complex linear combination of 2^32 different states. This means that a 32 q-bit register can hold all 2^32 states at once, with each state having a certain probability amplitude. The squares of these amplitudes’ magnitudes add up to one, ensuring proper normalization.
One unique property of quantum states is that they can undergo a global “phase shift,” where applying the same rotation to all the probability amplitudes doesn’t change the measurable state of the system.
Quantum “gates” manipulate the state of q-bits through operations that can entangle q-bits, create superpositions, and perform other transformations. These operations are fundamentally different from classical logic gates and can process an immense amount of information simultaneously. Simulating these quantum operations on a classical computer would require exponentially more resources, highlighting the efficiency and power of quantum computation.
Finally, at the end of a quantum computation, a measurement is performed. This collapses the superposition into one of the possible states, and the result is probabilistic, influenced by the probability amplitudes of the states (look up “Born’s rule”).
Imagine you have a group of animals: “dog, dog, dog, cat, dog”
You ask a regular computer “hey, does this group contain any cats?”
It has to go through the entire group.
“1 is not a cat, 2 is not a cat, 3 is not a cat, 4, is a cat!” And then it spits out: “Yes! The cat is at 4”
You ask the same thing to a quantum computer, it just looks at the entire group at once and goes “yep there’s a cat in there somewhere”.
I will not go in details with the math. The most important thing, I think, is noting that quantum computers do not solve problems exactly like classical computers but are very efficient at giving the solution to problems with some (hopefully high) probability.
The input depends on what quantum computer implementation you use, but it could be a series of ions suspended in an electromagnetic field, with the ions being either excited or not (think 1 or 0). Amazingly, lasers are so precise that individual ions can be hit with the light from the laser. The ions act as light bulbs which turn on or off if some neighbouring light bulbs are turned on or off. Think of the input as a starting configuration of light bulbs that are on or off. The computations are a pre-specified sequence of turning the light bulbs on and off which some math has shown with high probability should give a configuration of light bulbs which is interpreted as a solution. When you observe the resulting configuration, you can only hope that the wave functuon collapses to the correct configuration of light bulbs but that is not necessarily the case. However, the sequence of light pulses with the laser made it more and more probable that you would observe the right solution.
Latest Answers