Quantum Computing: A Beginner’s Notes


About the Beginner

I am a pretty normal guy. I drink my coffee in the morning, check my email and wonder what the future will bring. When I was much younger, I thought I wanted to be a nuclear physicist. I believed the only real solution to our energy problem was harnessing the power of the sun—that we would absolutely need to switch from fossil fuels and fission to fusion. I went to college and very quickly discovered that I wasn’t quite made of the engineering stuff. Engineering demanded precision, answers were right or wrong, and although you needed a good command of its rules, it did not seem to demand much deep thinking. So I switched out of engineering and ended up with a Master of Fine Arts in Poetry—and poetry, I felt, was just my cup of tea.

But I never left the engineering world far behind. To help pay for college, I fixed computers and eventually taught myself to write code. Coding I believed was just a different form of poetry. It had its own internal sets of rules, and when executed properly, it could delight just as well as any well-written poem. Shortly after, the Internet appeared—and I knew the world was about to change. As a programmer, I could see the way the Internet was spiraling out from the dark corners of research labs and academia into every facet of daily life. It was like standing on the edge of a great mountain and watching the shadow of a massive cloud spreading out to encompass the valley below.

The Valley Below

That same sense came to me the other day when I stumbled across the IBM Q website (https://www.research.ibm.com/ibm-q/). IBM and a handful of other companies have been trying to build a quantum computer for years. And, like fusion technology, the promise of a true, general purpose quantum computer is staggering. Because a quantum computer can, in theory at least, process many, many variables simultaneously, it has the potential to solve vastly complex problems almost instantaneously. Protein folding could be solved in seconds—leading to new drugs and molecular discoveries. Weather prediction would reach new heights of accuracy. And our current crop of cryptographic protections could be breached—posing challenges for the Internet as we know it. That much I knew. We are at the beginning of the age of the quantum—its vast cloud is just starting to fan out across the valley below.

What struck me with IBM’s quantum computing was that they had put it all online. I could set up an account, login, and begin learning the fundamentals of quantum computing for free, from the comforts of my home. When first released, the folks at IBM had a 5 qubit machine plugged into the internet. A year later, beta access to their 16 qubit processor is now available. If quantum computing is susceptible to Moore’s law, watch out. In two years, we could witness the birth of a 64 qubit processor—capable of processing 264 variables instantaneously—making a quantum computer faster than a traditional computer for some types of operations.

Into The Valley of Quantum Computing

So I started my descent into the often complex, and dizzying world of quantum computers. IBM’s Quantum Experience does a beautiful job of holding your hand.  The Beginner’s Guide provides great background information on quantum mechanics and quantum computing, and it allows you to flip between the user guide and the Composer, where you get to “program” the score that’s to be played out either in the simulator or on the real hardware that lives in IBM’s lab. The Composer also makes a graphical representation of the underlying coding (QASM) and thus lowers the difficulty level tremendously as it not only helps you visualize the score, but it helps you learn QASM.

In simulation mode, you can create a score using any number of qubits. Running against the hardware, however you are limited to 5 (or, if beta, 16) qubits.  The Composer provides tabs to drag and drop gates, barriers and measurements onto the score or to flip from viewing properties of steps or the entire QASM code.


Figure 1: Composer showing QASM code
Figure 1: Composer showing QASM code


Figure 2: Superposition and Measurement
Figure 2: Superposition and Measurement

My first walk through with the quantum processor was a very simple exercise out of the Beginner’s Guide. This experiment starts with a simple, single qubit, and applies a Hadamard gate to place the qubit into a state of supposition, where the qubit can be both a zero and a one simultaneously. Then a measure step is applied—this step, because it is a measurement, will cause the state of supposition to decohere into a classical bit state, either a zero or a one.

Because of the inherent randomness of quantum processes, each run of an experiment can result in different answers. IBM’s Quantum Experience lets you specify the number of runs (called “shots”) for your experiment and upon completion, shows your results as a histogram (or a QSphere—coming soon).

Figure 3: The results over 100 shots
Figure 3: The results over 100 shots

This of course, is an extremely simple circuit, but there, I have done it; I have written my first quantum code!

Figure 4: Quantum Code
Figure 4: Quantum Code


While it isn’t going to win me any awards, I am proud of this. But there is more to try–the Beginner’s Guide has a number of different experiments available—from Bit-flip encoders, to Grover’s and Shor’s algorithms. Am I ready to understand a quantum score like this?  Well, maybe not just yet.  Some day though…

Figure 5: Quantum score
Figure 5: Quantum score


One More Cup of Coffee

Idling through my morning, coffee in hand, I can feel where this experience is heading. One day, teams of quantum programmers will work on arranging scores to predict the weather, or simulate nuclear fusion in tokamak reactors. They will, for some time, be like me—thousands of miles away from the actual machine—using a tool similar to the Composer, or perhaps just down in the QASM code itself.

Is the IBM Quantum Experience perfect? No.  It is very much a work in progress. For example, as of this writing, the results of an experiment show the placeholder for IBM’s QSphere (but no Quantum Sphere materializes there).  It is also very likely that the tools will change significantly over time and evolve as these ideas meet the reality of the researchers and enthusiasts who interact with them.

Is it cool?  Heck yeah.


Learn more about Quantum Computing

About the Author, Kevin Casey

Kevin Casey, father of two very quantum children, is the president and owner of a small computer consulting firm, NanoLogic, Inc.  He has served as Chief Analytics Officer for a multi-channel marketing firm, Chief Technical Officer of a payments company, and as the Chief Information Officer of an online loan application platform for credit unions.  At home, he’s often referred to as the Chief Bottle Washer.  When not solving riddles in any one of the three start-ups he’s currently involved in, he builds guitars and dreams of mountains in Naples, FL.  You can follow him on LinkedIn at https://www.linkedin.com/in/kevinecasey.

6 comments on"Quantum Computing: A beginner’s notes and overview of IBM’s Quantum Experience"

  1. Want to map the brain using supercomputer to link all the synapses and show how blood, fat and protein make the brain the most creative object in the universe. My project will be called Hx2.

Join The Discussion

Your email address will not be published. Required fields are marked *