Learn Quantum Programming #1

2 minute read

In case you didn’t notice, this is a part of a journal series describing my experiences learning Quantum Programming. If you have no idea what quantum computation is, start playing Hello Quantum, a mobile puzzle game.

Getting off with the standard tasks: I completed reading Chapter 1 of the book by Nielsen and Chuang, check out the solution manual that I am compiling. I have also completed a week’s syllabus of Quantum Information Science 1, Part 1 course by MIT. I was reminded by a question in r/MikeAndIke, that as you keep adding gates in the circuit, you should always right-multiply the corresponding matrices to the qubit vector. This sounds trivial, but prone to be ignored.

Now, to the more interesting stuff:

In a podcast, John Preskill1 covers topics mentioned in section 1.1 of the book and provides motivation to pursue Quantum Information. The most interesting part for me is when he talks about his current research on how Quantum entanglement could be the fundamental reason for the existing Space-time geometry (The video below starts at this point). Kudus to Chaitya for sharing this with me!

Read more about some other mentioned topics like, Microsoft’s topological approach to building quantum computers and how Intel can scale the production adapting superconducting technology.

There are 2 quantum computers you can program on now: IBM Q and Rigetti’s Forest. Gate model hardware vendors (IBM and Regetti) have built their own low-level languages: Quil and QASM which have higher level python SDK’s: Pyquil and Qiskit respectively. Though there are other independent frameworks like Project Q and Microsoft’s Q#, it is better to stick to the ones which can be run on real quantum computers and not just simulators. OpenFermion stands out as an interesting project to simulate quantum chemistry, but IBM launched a competition, QISKit ACQUA, a library of algorithms for chemistry simulations, AI and optimizations.

Rigetti’s Forest provides free access of up to 26 simulated qubits on sign up and access to a real 19Q processor on request. On the other hand, IBM Q provides access to a real 5-qubit processor on signup! As a beginner, I chose IBM Q to work on for now.

The QISKit tutorial is the best place to start learning to code once you understand all the fundamentals (Chapter 1 of the book should do). But if you want a glimpse of how the code looks with a good narration read this article where Dr James Wootton designs a quantum Battleship game (If you jumped hearing “quantum game”, check out this, this and this one too). If you are already familiar with QISKit, check out what’s new and exciting in their latest version 0.5.

1: Popular for the bet he won against Stephen Hawking and Kip Thorn, where we went against General relativity for Quantum Mechanics.