5 Days into learning Quantum Computing. #100DaysOfCode

If I had to describe Quantum Computing to the average person today it would be that it is the best innovation in technology that is not ready or useful for wide-scale practical applications… yet. I am not an expert in quantum studies let alone quantum computing, but I decided to take the next 100 Days of my busy tech development life to understand what’s the hype about and understand its potential. Is it a pipe dream? Is it the next biggest invention since the lightbulb? These questions riddled me, but as someone who is starting his path to learn in-depth about this technology, I honor to take it among myself to dedicate a thorough comprehension of this topic.

My Experience

I first heard about quantum computing from this video back in 2018. It sparked my interest that this new technology it had the capabilities to process faster than classical computers and solve a more complex task that would take today’s computers an absolutely insane amount of time to solve (in theory at least). At the time, I was a college student studying on the innovative technology of blockchain development. However, when I heard the argument Quantum computers have the capabilities to break modern day encryption, I was curious. Especially since blockchain’s whole premise is based on encryption.

Right after this video, I became motivated to seek information around this topic. I ultimately was referred to IBMQ Experience which made a library dedicated to providing the public with interactions on a quantum machine, called Qiskit. I took some EDX .courses from MIT explaining quantum mechanics to garner a general understanding of the topic. I came to the conclusion that for practical usage is quantum computing is still a long way away. I took my focus away from it, and focus on blockchain and decentralized systems.

Prologue

I actually had started a 100 Days Of Code chain focusing on the premise of blockchain development. Things were going well until I had events occur in my tech business, where I had to cater to, so a lot of my tech research and practice took back-burner. Ultimately, I am proud that within the 25 days I manage to build a decentralized stock exchange as shown below:

But completing this was only the capping off of a short journey. I didn’t build out the entire application, but the base of the smart contract and simple designing was good enough for me especially with the things going on in the business. Eventually, I came to the thought of taking on something more challenging. It wasn’t until I saw this video from one of my favorite YouTubers to put the quantum spark back into me:

If you don’t know about Jake Tran yet, I highly recommend him. Jake Tran essentially gives an informative introduction about things business-related in the form of video essays. I say his content is on par with the likes of LEMMNO, Kurzgesagt — In a Nutshell, CNBC , Bloomberg, and, Aperture.

The video got me wondering that quantum computing is indeed on the next advancement in computation. Things like blockchain, Ai, IoT, and material sciences, are all power key components in our world in their own right, but quantum computing significantly enhances the way information is processed, understood, delivered, and retrieved. There have been statements of even big tech companies such as Microsoft and Google taking their trials into the new technology, all but yet Rigetti, and IBMQ leading the way.

From all of this content occurring, it motivated me to take my dive back into quantum.

Day 1

I already had my IBMQ account setup and started to play with the colorful gates here and there, but I honestly didn’t know I was doing. I began to look into the qiskit tutorials to have a guided starting point for my journey. I started to revisit the core concepts of quantum computers and it goes as follows. Quantum Computers operate off qubits. These qubits are like classical binary bits we are used to when it comes to classical computers however classical bits (cBits for short) can be 0 or 1 at any particular moment. However, qBits can be 0, 1 or both at the same time (until it’s measured). So once I had a general idea down it made the concept a little more understandable. The first script I wrote was nothing exciting. Just put two Hadamard gates on q[0] (qubit 0). Although simple it was my first step into writing a circuit for an advanced new innovation in technology. I have no idea what these circuits are meant to do in theory, but was excited to keep going!

Day 2

I wanted to dive deeper after I started my first step into creating my first circuit. For most of the code, I am using qiskit python library as I am very familiar with python and the introduction into the new technology is exciting. I became curious as to when I was inputting data and running these circuits, I was wondering about the outputs and how they were read by both computer and by humans. This is when I learned that there are actually four different types of notations that comes from identifying these outputs:

1> BRA-KET

2> Matrixes

3> Bloch

4> Measurement

Day 3

I moved into one of the most useful properties of quantum computing and that’s teleportation! This isn’t like nightcrawler popping all over the place or getting beamed up on USS Enterprise like in Star Trek. What’s happening is this: instead of transporting the information state from q0 to q2 through an otherwise physical medium via electronic connectors, you can teleport the information contained in q0 onto q2 without breaking measurement. This action is capable due to the process known as Quantum Entanglement. This means that the two particles are interconnected across a gap in space where action done on one qubit affects the other one it’s entangled with. There are still studies that are needed to further understand how this process works, but with the associated circuit above you can start teleportation too!

P.S: Teleportation is my favorite superhero ability

Day 4

By this day I moved into learning more about understanding the aspects of the power of quantum computing in comparison to classical computing. This case shows my first “use case” of quantum computing. I had followed qiskit tutorial on YouTube to have the quantum computing guess my secret number (I know it’s in binary, things are a little limited). For a classical computer, it would take n (n = length of the secret number in characters) tries to guess the secret number. However, with quantum computing guess how many tries it’ll take?…

That’s right! Only one try. This operates by applying a Hadamard gate (h-gate) to each qubit for n characters. Second, apply another x-gate and h-gate to the last qubit. Third, I added a for loop to loop through the secret-numbers and apply a cx-gate on each one. Finally, we take the measurements of the results and apply them to the cBits so that we can read the results.

You can see in the next photo that on the left it displays the results, but on the right, it displays the tries it took to correctly guess the number which is one!

Day 5

This day I wanted to take a deeper dive into the gates and how each one works. Up to this point I just plugged in these gates into circuits to see how they operate. I won’t go into each one here since that will be too long for an article, so I’ll reserve it for another one soon! The process to jot down all of the gates really aids in expanding on my understanding of quantum computing and mechanics as a whole. I’ll be continuing to learn more and expand upon my understanding of quantum computing.

I’m excited to see what to make from this

I’m excited about the world of quantum computing and see what cool thing’s can be built from it! If you have any great recommendations for sources to understanding quantum computing, place them down below! I really want to help people know what’s the journey is like to understand quantum especially when it’s a complex topic.

Stay Up To Date With Me!

Twitter | 100DaysOfCode Feed

Instagram

tycooperaow

I am a Blockchain Developer, and Crypto Edcuator