- Team Name: Q-Plinkers
- Team Size: 3
- Team Members:
- Mrunal Arun Kumavat (gst-5xQeln6sCF0kYi6)
- Ritisha Katiyar (gst-BlDqzagDwOqhxW3)
- Viraj Daniel Dsouza (gst-XsbkDJWSAD37VOk)
This repository explores the Universal Statistical Simulator by implementing a Quantum Galton Board (QGB), a quantum analog of the classic Plinko game. The Galton board serves as a physical realization of a Monte Carlo simulation. Our work focuses on developing and optimizing quantum circuits that generate various statistical distributions.
Initially, we developed a general algorithm to construct a QGB circuit for an arbitrary number of layers, building on 1-, 2-, 3-, and 4-layer models. We successfully verified that the output of our noiseless circuit adheres to a Gaussian distribution, consistent with the classical Galton board's behavior. We then adapted this core functionality to produce other, non-Gaussian distributions, specifically the Exponential distribution and the Hadamard quantum walk. For all implementations, we provided good fits between the observed results and the theoretical forms of each distribution.
The next phase involved simulating these circuits on a noisy model of quantum hardware. Recognizing that gate errors and decoherence significantly impact circuit fidelity, we focused on quantifying these errors and developing optimized implementations. This involved creating custom transpiler pass managers to mitigate noise by optimizing qubit layout, routing, and more. Through a systematic search, we aimed to maximize the accuracy and the number of layers achievable before noise completely dominates the signal. This part of the project highlights the critical role of appropriate transpilation and noise mitigation in practical quantum computing.
Finally, we also conducted an analysis of the results by computing the statistical distance between our simulated distributions and the ideal target distributions. This allowed us to quantify the impact of noise and the effectiveness of our strategies, providing a comprehensive evaluation of our implementation's performance. The project demonstrates a full cycle of quantum algorithm development, from theoretical implementation to practical optimization on a noisy hardware model.
Click here to view the project description.
A well-structured 2-pager document summarizing the implementation of QGBs based on a review of the paper can be found here.
- We started with a QGB circuit with small number of layers to observe the pattern to help us generalize the circuit for arbitrary number of layers. Refer here for the implementation. We then developed a general-purpose algorithm capable of generating a QGB circuit for any number of layers. The algorithm was verified using a noiseless simulator, confirming that the output distribution for the measured samples is Gaussian, matching the expected behavior of a classical Galton board.
- Exponential Distribution: By using a row-dependent
Ryrotation gate in the 'peg' construction, we generated an exponentially decaying distribution. The rotation angle was carefully chosen to decrease the probability of a "right" movement with each subsequent layer. Additionally, we explored another possible implementation with more control possible over the exponential decay rate. - Hadamard Quantum Walk:
Refer here for the detailed implementation of outcomes 2 and 3.
- We utilized IBM qiskit's custom
PassManagerto optimize the circuits for a real hardware noise model. We benchmarked different transpiler settings and seeds to find the optimal configuration that minimizes the total accumulated error, allowing for a greater number of layers to give reliable results on the noisy simulator.
- Statistical Analysis: We computed the distances between the distributions obtained from the noisy simulations and the ideal distributions.
Refer here for the detailed implementation of outcomes 4 and 5.
A sneak peak into our noisy simulator based results:
The presentation slides can be found here.
Please fork the repository and clone the fork to your local device. Certain files use modules that contain helper functions.
Install all the necessary packages using the requirements.txt file.
You can use pip install -r requirements.txt to install all the packages needed.
Please create your ibm api-token from upgraded IBM Quantum® Platform. Then create your instance and copy its CRN code. Save the details using the code below to run the codes on real hardwares and/or noise simulators.
QiskitRuntimeService.save_account( channel="ibm_quantum_platform", token=your_api_key, instance=your_crn, name="any_name", overwrite=True, )
If you wish to contribute to this repository, please fork the repository, make your contributions in your fork, and submit a pull request
This project is licensed under the MIT License - see the LICENSE file for details.
- M. Carney and B. Varcoe, Universal Statistical Simulator. arXiv:2202.01735 [quant-ph], 2022. https://arxiv.org/abs/2202.01735
- A heartfelt gratitude to Womanium and Wiser Team for designing & organizing this program, and offering scholarships.
- Grateful to Brian McDermott and the NNL team for their guidance and support on this project.
- Thanks to the Discord community for active discussion and timely support.
- This project majorly uses Qiskit by IBM Quantum.


