Flip a quantum coin, and you might split our universe into two. At least, that’s the premise behind the many-worlds interpretation of quantum measurement, which is the idea that every quantum measurement — otherwise interpreted as a wave function collapse — divides our universe into multiple universes, one for each possible outcome.
While this interpretation of our quantum world carries many objections, the concept behind it has proven useful for calculations. In fact, the many-worlds interpretation was the inspiration behind “Quantum Ghosts,” a project started by four students at Qiskit’s Tel Aviv hackathon with the goal of improving the StatevectorSimulator in Qiskit Aer.
Specifically, the team developed a method to simulate all possible outcomes of a measurement, essentially allowing a classical CPU to calculate and track parallel timelines.
This new feature allows the StatevectorSimulator in Qiskit Aer to more accurately simulate circuits with measurements. “Quantum Ghosts” will be implemented into Qiskit Aer in the near future.
We interviewed the four student hackers to learn more about Quantum Ghosts, including their thoughts while planning and developing the hack, as well as their hopeful evolution for it.
(answers edited for clarity)
Qiskit’s Tel Aviv Hackathon Winners
Keren Avnery: I’m 22 years old and from Israel. I majored in physics at the Hebrew University of Jerusalem and currently I study in the Weizmann institute of science for my M.Sc. in physics.
Matan Parnas: I’m 19 years old and just finished my first year at Bar Ilan University majoring in Physics, as a part of the academic reserves unit in the IDF. The Hackathon was my first experience with Qiskit and I learned it hands-on. It definitely was an incredible experience for me.
Gilad Pollack: I am a student at Tel-Aviv University, now finishing my B.Sc. in physics. I have a lot of experience with programming outside of my university studying, but this hackathon was my first experience with Qiskit.
Gal Viener: I’m a Computer Science and Mathematics student at the Open University of Israel for now. I’ve had zero experience with Qiskit or quantum computing before this hackathon. I’ve heard of qubits before but turns out they are nothing like what I imagined.
Why did your group want to improve this particular feature of Aer?
Pollack: As it stood, the StatevectorSimulator was less useful for quantum circuits with measurements. This is because when simulating measurement within a circuit, the StatevectorSimulator would collapse the states into a random outcome. This means that for consecutive runs of the same circuit you could get different results. In fact, each result only represented a subset of the possible outcomes.
How did your team approach simulating a state vector?
Pollack: Our goal was to simulate, for each measurement in the circuit, both (or all) of its possible outcomes, and in this way, the final output would be more useful.
Why would a simulator need to track multiple outcomes?
Avnery: One of the philosophical interpretations of quantum physics relates to the underlying uncertainty in measurements — we can’t know which of the possible results will turn up in a measurement.
Avnery, cont’d: This can be thought of as different timelines diverging from each measurement, wherein each timeline a specific value (eigenvalue) is measured, and the likelihood of each timeline is the likelihood to get this eigenvalue.
How does “Quantum Ghosts” handle these multiple outcomes?
Avnery: Instead of averaging out each measurement and working with the expectation value, or randomly selecting a specific eigenvalue, in our project we gave the option to lay out all the different possible results and their probability for each measurement, and to continue the experiment in all the different timelines simultaneously (figuratively, of course. The simulator actually runs on a classical CPU, so the timelines must be computed recursively, one by one).
Avnery, cont’d: This way, we can measure during an experiment without losing the valuable information stored in different timelines.
What was the most difficult part of building this project?
Parnas: For me, the most difficult part was to think of how I could visualize an experiment’s results in a way that is user-friendly and intuitive.
Viener: And for me, personally, the main difficulty was understanding the basic concepts of quantum computing, as I’m a Computer Science and Maths student and have yet to encounter such complex concepts as quantum physics, quantum algorithms and their utilizations.
Viener, cont’d: Furthermore, technically, when creating our project I was tasked with visualizing the calculations and measurements, and that was a pretty big technical hurdle, as I was trying to integrate code bits from different languages into the same project, all within a time window of around five hours.
What was your favorite aspect of the Qiskit hackathon?
Viener: As someone who’s academic background comes mainly from the fields of Mathematics and abstract CS, on the one hand, it was very interesting seeing how abstract algebraic methods are utilized in the description of quantum computing transformation and logical gates.
Viener, cont’d: And on the other hand, I got to chat, work, and learn from physicists, and learn about the absolutely fascinating world of quantum physics, and especially quantum computing. The fact we had a whole day of lectures from experts in the field helped greatly with exposing the concepts and sparking the imagination of us contestants.
How will you further contribute to “Quantum Ghosts”?
Viener: If I find the time, I’ll try to implement the cross-language visualization functionality in a proper manner.
Pollack: In the Hackathon, the project was implemented in Python, but the main Qiskit simulator is written in C++, so for one, it needs to be converted.
Parnas: I would like to make a 3D model of the wave-function collapsing and see how it changes in each experiment. I also want to polish the simulator itself for a smoother algorithm run.
How might others use Quantum Ghost?
Parnas: The analysis of any experiment could be made much easier by using the histograms of the probability coefficients, as well as a history tree of the collapsing wave functions.
Pollack: And when implemented into Qiskit, “Quantum Ghosts” could be used to better visualize and understand complicated circuits containing many measurements. In addition, since measurements and noise are so closely related, this could be used to help simulate noise better than before.
Pollack, Viener, Avnery and Parnas were the four members of the “Quantum Ghosts” team, which won the hackathon competition at Qiskit’s Tel Aviv Hackathon, held on 28–29 May 2019.
Look for the inclusion of Quantum Ghosts in a future update of Qiskit Aer!