You are here
Home > The Explainers > What is a Quantum Computer? Are you gonna get one of these in your houses anytime soon?

# What is a Quantum Computer? Are you gonna get one of these in your houses anytime soon?

Let’s start with the classical computer, really. The fundamental units that drive a classical computer, like the one at your house are bits ( 1’s and 0’s). When such bits are arranged in a particular fashion, they mean something. When such meaning full strings are arranged in rows, they make a Programs. Program is a set of instructions which command the computer to do some task.

### So, how are we creating these so called “1’s and 0s”?

Modern day computers use transistors. You don’t have to know what a transistor is, just think of them as a switch which allows the current to flow in particular direction when the switch is turned on. When the current (flow of electrons), is passing through the transistor (switch), it is called on state representing the binary digit (bit) 1. When the current is not flowing it represents the binary digit 0.

### How do we observe the data (the strings of meaningful bits)?

We store them in boxes called registers. These boxes (registers) can store one bit at a time. If we need to store more than one bit, we use them in cascaded (Series) fashion. The computer you have at home is probably a 64 bit PC, which means it has 64 registers (boxes) in one line. That computer can read and write data 64 bits at a time.

In classical computers these registers can store either one or zero at a time. They can’t store both one and zero at a time in the same register.The real magic happens when you can store both the bits at a time, right? That is exactly what a quantum computer does.

I know it is confusing, let’s take a step back and discuss in detail how Quantum computers actually work.

### The math behind a Quantum Computer

In classical computers, we use transistors which allows the current to flow or not to flow. Current is nothing but flow of electrons. What we are doing is cutting the flow to represent a bit and allowing the current to flow to represent another bit. You see, electrons are microscopic and their properties and behavior are way weirder than wwould ever have imagined.

Electrons have something called spin. This word “spin” means exactly what it means in English – rotation. An electron can rotate in N different ways.

Place an electron in a room. Remember that an electron behaves just like a dipole magnet. Now turn on magnetic field. The electron will try to align itself with the direction of the magnetic field. That configuration is called “Spin Down” (Logical Bit 0). Due to disturbances in the field the electron spins in the opposite direction to align itself in the opposite direction of the field, this is called “Spin Up” ( Logical bit 1).

Until this point a Quantum computer acts like a classical computer, because the spinning of the electron corresponds to the bit. But from here on, there is barely any similarity between what we know and what we are going to see.

According to Quantum Physics, an electron can spin in different directions at the same time. That means it can spin up and spin down at the same time. What we observe is merely the probability of the electron spinning up and spinning down.

If we take a two bit system, it has four different configurations (00, 01, 10, 11). A classical computer can compute any of these configurations at a time. But you see, quantum computer can perform all these four configurations at time. The two Qubits (Bits in a quantum computers are called qubits), can have four different possible states. Therefore two qubits are enough to represent four states of classical two bit system. While the classical computation takes four operations to compute the result, the quantum computation can compute the result in one operation.

Even though the electron can have different spin states at a time, when we observe it, the electron should settle in any of the spin states. Let’s take an example, if the output of the AND gate in classical computation is like this:

0 and 0 = 0
0 and 1 = 0
1 and 0 = 0
1 and 1 = 1

A classical computer first computes line one and comes to line two and goes all the way to the bottom in series fashion. But a quantum computer on the contrary does all the four computations at the same time and the result can be any one of the above. That means sometimes the result will be AND(0,0) and some other time the result will be AND(1,1). We don’t know when we will get what result but we can estimate how many times a particular result comes when we run the same computation for some number of times. This is called probability. This opens up the conversation about the most important and basic phenomenon which in the first place caused this – Superposition.

If you have ever heard of Schrodinger’s Cat experiment, you will know what I am talking about. The very famous Cat experiment starts with placing a cat inside a closed box. Along with the cat, if we place an explosive, the cat may die or live, we don’t know what happened to the cat unless we open the lid and see. Theoretically, the cat is both alive and dead until you see. In a way, if the cat is dead, it is because of you ;D. This is called superposition theorem. An electron can exist in different quantum states at the same time until the time of observation. When we observe, it will settle down in one of the most probable states.

### [0.5*AND(0,0)]+[0.2*AND(0,1)]+[0.1*AND(1,0)]+[0.2*AND(1,1)]

What does the equation say, when the same computation is run 100 times, the result of AND(0,0) comes 50 times, the result of AND(0,1) comes 20 times, the result of AND(1,0) comes 10 times and finally the result of AND(1,1) comes 20 times. So, quantum computers don’t give a fixed result, rather they give combination of results at different probabilities.

If you are video streaming or listening music, this doesn’t actually effect the speed, because when the file is loaded, what the quantum computer does is, it will load the entire file but only show a part of it. When you do it again, it will show the different part of the file or the same (depends on the probability). In this case the quantum computer is randomizing the access to the data in the file but not improving the speed at which you access it. In a classical computer you will access the file serially, that means you will see it bit by bit, in quantum computers those bits will come at random, but to load the entire file both the systems would take more or less same time. This is in case of regular stuff.

If you go for complex calculations, let’s say prime factorial of 274,207,281 – 1, you might want to grab a quantum computer. The reason being, a classical computer would take days to calculate the same, but a quantum computer can do it in minutes. The places where you use optimization algorithms, Quantum computers are highly helpful. With their parallel processing power, they will process the entire data at once and give the required information with in minutes.

Big Data, Encryption cracking, Sorting the databases, these are the areas where you can truly see what quantum computers can do. In mundane tasks that we do regularly we don’t find any real impact.

You are probably not going to get these anytime soon for domestic use, like in your houses or offices. Companies like Google, NASA, USRA have invested a lot in preparing a 512 Qubit Quantum computer developed by D Wave. This computer is used for traffic predictions, weather predictions or other complex calculations which may seem impossible using a regular computer.

If you think you liked what we write please like the post or share the post in your favorite social media platform. If you think we could do better leave a reason in the comments section below. No matter what you say we always love you 🙂 !

Sritha Bandla
A Tech Nerd, Neurotic Reader, Coffee Lover, Electronics Engineer, Writer, Web Developer, Designer.
http://sritha.com