Codementor Events

Quantum Computing ?/!

Published Dec 16, 2018
Quantum Computing ?/!

**Zeros and ones. **This is how we imagined computing till now. This is what classical computing is. But a whole new concept is now changing the way we think about computing.

In classical computers everything revolves around transistors, the most basic unit of storage. As we know, transistors are a basically a switch, being either on or off and hence representing a binary one or zero. Typical scale for transitors today is around 14 nanometers which is about 500 times less than a human Red blood cell. As this scale is decreasing we are approaching the limits at which classical computation can properly work. The reason being classical physics doesn’t work well in the quantum relm. A notable example of this is the quantum tunneling, in which electrons tunnels (passes) through a barrier that it classically cannot surmount.

But scientists are using these unusual properties to their advantage, by building quantum computers.

A classical computation is like a solo voice—one line of pure tones succeeding each other. A quantum computation is like a symphony—many lines of tones interfering with one another. ― Seth Lloyd, Programming the Universe: A Quantum Computer Scientist Takes on the Cosmos

As classical computers are driven by bits, Quantum computers are driven by qubits. These qubits have various properties, like superposition and entanglement.

**Superposition: **
Imagine a coin flip. We know that the result of a coin flip is binary, heads or tails. But we also know that a coin can stay in an undecided state. While its in air, its state is not defined yet, or we can also say that its in both the states. This principle of having both states at the same time, defines the most important property of quantum bits called superposition. Most of us have already heard about superposition in the classical Scrodengier’s Cat story, where a cat is both dead and alive. The moment you try to measure a qubit, it collapses to one of the definite states. If we have 4 classical bits we can have 2 ^4 = 16 possible combinations of values, out of which you use any one combination at a time. But 4 qubits however can be in all those 16 combinations at the same time.

**Entanglement: **
Two Qubits can be bind to one another in such a way that a change in one’s state makes the other one react instataneously. This means using a one entangled qubit, we can deduce properties of the other one.

Just like classical bits are manipulated using logic gates, Qubits are manipulated using quantum gates. Quantum gates taking as input the superposition and rotating probabilites give another superposition as output finally collapsing these superpositions to actual sequence of zeros and ones. This allows a complete set of calculations to be done at the same time.

1.png

Quantum computers require much less iterations as compared to classical computers, though you can’t do much with present day quantum computers. A traditional database searching which may require N iterations, with Quantum computers require just square-root N iterations. Interest in the field increased tremendously after Peter Shor’s very surprising discovery of efficient quantum algorithms for the problems of integer factorization and discrete logarithms in 1994. Since most of current classical cryptography assumes that these two problems are computationally hard, the ability to actually build and use a quantum computer would allow us to break most current classical cryptographic systems.

Almost every top company is researching on quantum computers. Google’s Bristlecone, a new quantum computing chip with 72 quantum bits, or qubits brings the race for quantum supremecy closer to its end, overtaking the previous record holder IBM with 50 qubit quantum computer. Quantum supremacy or "quantum advantage" is the potential ability of quantum computing devices to solve problems that classical computers practically cannot.

0.jpg

Now comes the important question, how can I get started with writing quantum algorithms. Microsoft answers this question with its quantum development kit. Microsoft’s quantum development kit comes with a quantum-focused domain specific language called Q#, a quantum simulation environment, and many open source libraries and beginner samples.

To run a typical quantum algorithm on a simulated environment requiring about 30 qubits, one needs a computer with a RAM of about 16 GB, and this number grows exponentially. As you go from 30 qubits to 40 qubits, this number increases from 16GB to about 16TB. To help with this microsoft offers a quantum simulator hosted on azure.

You can write your first quantum algorithm today. To get started just install microsoft quantum development kit on your system https://marketplace.visualstudio.com/items?itemName=quantum.quantum-devkit-vscode.

You can use it with visual studio community or with visual studio code. Now clone this repository https://github.com/microsoft/quantum, and try out the samples. To run these samples, you just need to have quantum-devkit and .NET SDK.

2.png

(above) Message Teleportation code running on my system. Transfering message between 2 qubits.

Some good reads for quantum computing.

Lecture Notes by Ronald de Wolf: here

Learning Q# and understanding microsoft quantum development kit: here

Quantum computing by Jozef Gruska: here

Discover and read more posts from Bhavin Jawade
get started
post commentsBe the first to share your opinion
Show more replies