Introduction to Quantum Computing :: Part #2


Psst, Thirsty-Robot here. Download the HTML document for full power on the mathematical notation here, GitHub - Thirsty-Robot/Quantum-Computing-Guide. Enjoy :slight_smile:.

Introduction to Quantum Computing :: Part #2

Hello again, I’m back with another guide. Last chapter we discussed some basic principles of Quantum physics, I really encourage you to read the first chapter before diving into this one. This chapter will cover the bases of quantum computing, I recommend being familiar with unitary matrices, vectors, basic linear algebra and basic computer logic. Also, my guide will be hosted on GitHub, I will use Jupyter notebook to show some mathematical notation, so you can clone the repository and read from there, I think it’s more comfy.

So now, in this tutorial we are going to review:

2.1. Basic Math Concepts and Some Feedback Links

2.2. A Brief History of Quantum Computing

2.3. The Qubit

2.2. Getting the Record Straight

Basic Math Concepts

So, math. It’s maybe the most important part of quantum computing. We are gonna see absolute values and complex number. Remember this is gonna be a basic overview of this, just for you to remember some basic conceps we dont use in day-to-day life.

Complex numbers

In day-to-day life we use real numbers, numbers on a one-dimensional matter if you will, you can imagine them as numbers on a two directional line, where 0 is the center of this line, left are negative numbers and right are positive numbers. Like this:


When you are at the center of this imaginary number line (meaning your position is zero) and then you add five, you are gonna be at position 5. This is the basics of group theory. We can interpret this field as an additive field, in which we can add to our original position (which is zero), and we are going to move to another position in our number line, streeching it (see reference links for a visual interpretetion). But, this is only in a two-dimensional matter. Are there any numbers in a three-dimensional matter?

The answer is yes, they are called imaginary numbers. You can imagine this numbers as numbers in another dimension, we don’t only have 1 or -1. We have 1i 2i etc… This numbers are useful enough to show quantum states as we are gonna do.


In here our A or X axis are real numbers and the B or Y axis are imaginary numbers. So instead of representing this as a normal equation, we are going to add a i at the end of out b or i axis. Because imaginary numbers are represented by an i, so our equation is:



Basic Matrices

In computer science we use matrices for representing arrays, but in physics they are for representing vectors. Also, we are gonna see them alot of times, so try your best to read the feedback links. Here is a matrix example:


A Brief History of Quantum Computing

I gave you a brief history of quantum physics, now I’m gonna give lecture you about quantum computing history.


Richard Feynman developed quantum electrodynamics. Which is the way electrons interact with each other trough photons.


Feynman and others started to investigate on conventional information, and the computation of quantum states with binary data.


David Deutsch, described the ‘Univeral Quantum Computer’ on a theorical paper. In this paper he proved that a two-state system could be use to simulate a quantum system. The operations of this computer were called Quantum Gates.


Peter Shor proposed a method of using entangled qubits for finding the prime factor of integer. This is known as the Shor’s Algorithm. This algorithm whill surpass the efficency of any known computer when executed on a quantum computing.

Present day

Quantum Computing is a big field now at days. New quantum gates come around every now and then.

The Qubit

Finally we are actually gonna learn quantum computing. Okey, so what is a Qubit. Remember last post? When I talked about some crazy cat and the Copenhagen interpretation? Well, in normal computing, computers can have a bit. Meaning they can only be a zero and a one, our bit is going to be represented by alpha:


In a physical manner, a bit is represented by an electrical current. 0 is no current and 1 is current. This controls the motherboard of your computer with the help of chemical transistors.

Well, in quantum computing our bit can be a 0 and a 1 at the same time. Just like in the copenhagen interpretetion, quantum computing takes advantage of super position, so our bit is in both states at the same time. Now let’s visualize this as alpha and let’s introduce another qubit, beta:


Now, our qubit is 0 and a 1 at the same time. How do we represent the possibility of this? This can be represented in the following way:


So we have psi equal alpha plus beta. Remember that psi is the way to represent the wave function of a quantum system. All the posiblities on a quantum system. And does weird parentesis are called the bra-ket notation. This notation is used to represent a quantum state. Alpha and beta are complex numbers that obey:


At the begining, our ground qubit will always be zero. Why? normally quantum computers use a type of hardware qubit named a superconducting transmon qubit, which is made of superconducting materials like aluminum or nobium. For this to behave as our abstract notion of the qubit it needs to be cooled at super frosty temperatures. It takes some days to reach perfect equilibrium, and when is does our “ground qubit” will be zero.

Well, our qubit needs to be other things too, not only a 0. So how do we manage our qubit. There are certain ways of doing these. In normal computers you use logic gates, gates like AND, OR, NOT, XOR, NOR etc. In the quantum world we use quantum gates (we will see them with more detail on the next chapter). For now we are going to learn one. Typical gates are represented by a 2x2 unitary matrix.

We are going to talk about the bit-flip gate which is denoted by X.


It simply flips the bit. Meaning, zero to one and vice versa. This has a matrix representation of it:


This is it for now. On the next chapter there is gonna be hard math so I recommend getting familiar with linear algebra again.

Getting the Record Straight

Quantum computing has been in everyones mind. It has been in on news report, movies ans series. Since the idea of thinking in to things at the same time it’s difficult for everyone, quantum computing has been misunderstude and by this it was plagued by myths and speculations. I will try to get the record straight with this myths and facts.

1. Quantum computers can get all posibilities at once

This is a myth. There are several quantum algorithms out there, each one target different fields, but none of them check “all posibilities” at once. This myth comes from the RSA algorithm breaking. The Shor Algorithm doesnt go over all primes at the same time, this algorithm just finds a quantum way or trick for getting the prime.

2. D-Wave is the first quantum computer

Again, not at all. D-Wave is a quantum annealer. It’s great for optimizing solutions to problems by quickly searching over a space and finding a minimum (or “solution”) by running adiabatic quantum algorithms. However, quantum annealing will never be able to run Shor’s algorithm, which breaks common forms of modern cryptography, like RSA and ECC.


Thanks for reading and waiting for this little guide. If you have any question go ahead and talk to me, no problem. In the next chapter we will use a quantum computer in the cloud, trust me, it’s gonna be fun. This is it for now, have fun and never stop searching.

  • Thirsty-Robot

Feedback Links


Awesome!!! Super interesting!

Thank you for this!


Yes very awesome article. This morning I just found out that IBM is offering free computer time on their IBM Q site.


This topic was automatically closed after 30 days. New replies are no longer allowed.