Step-by-Step HHL Algorithm Walkthrough to Enhance the Understanding of Critical Quantum Computing Concepts

Hector Jose Morrell Jr,Anika Zaman,Hiu Yung Wong
DOI: https://doi.org/10.1109/ACCESS.2023.3297658
2023-03-25
Abstract:After learning basic quantum computing concepts, it is desirable to reinforce the learning using an important and relatively complex algorithm through which the students can observe and appreciate how the qubits evolve and interact with each other. Harrow-Hassidim-Lloyd (HHL) quantum algorithm, which can solve Linear System Problems with exponential speed-up over the classical method and is the basic of many important quantum computing algorithms, is used to serve this purpose. The HHL algorithm is explained analytically followed by a 4-qubit numerical example in bra-ket notation. Matlab code corresponding to the numerical example is available for students to gain a deeper understanding of the HHL algorithm from a pure matrix point of view. A quantum circuit programmed using qiskit is also provided which can be used for real hardware execution in IBM quantum computers. After going through the material, students are expected to have a better appreciation of the concepts such as basis transformation, bra-ket and matrix representations, superposition, entanglement, controlled operations, measurement, Quantum Fourier Transformation, Quantum Phase Estimation, and quantum programming. To help readers review these basic concepts, brief explanations augmented by the HHL numerical examples in the main text are provided in the Appendix.
Quantum Physics,Physics Education
What problem does this paper attempt to address?
The problem that this paper attempts to solve is how to enhance students' understanding of the core concepts of quantum computing through an important and relatively complex algorithm - the HHL quantum algorithm. Specifically, the HHL quantum algorithm can accelerate the solution of linear system problems (LSP) at an exponential rate, which is more efficient than classical methods. The paper details the analysis process of the HHL algorithm and provides a specific numerical example using 4 qubits to help students observe and understand how qubits evolve and interact. In addition, the corresponding Matlab code and Python code written with qiskit are also provided for actual hardware execution on IBM quantum computers, thereby deepening the understanding of the HHL algorithm from the perspective of pure matrices and actual operations. ### Main contributions of the paper 1. **Detailed analysis of the HHL algorithm**: The paper provides a step - by - step analysis of the HHL algorithm to ensure self - contained content and easy understanding. 2. **Specific numerical example**: A numerical example using 4 qubits shows the specific implementation process of the algorithm. 3. **Matlab code**: The Matlab code that completely corresponds to the numerical example is provided to help students track the evolution of the wave function from the matrix perspective. 4. **qiskit code**: The qiskit code that can be run on IBM quantum simulators and real hardware is provided. 5. **Comprehensive background knowledge**: In the appendix, basic quantum computing concepts such as basis transformation, bra - ket notation, matrix representation, superposition state, entangled state, encoding, controlled operation, measurement, quantum Fourier transform and quantum programming are briefly explained to help readers better understand the application of these concepts in the HHL algorithm. ### Specific problems solved - **Enhanced understanding**: By means of a specific complex algorithm, help students understand the core concepts of quantum computing more in - depth. - **Practical operation**: Provide actual code examples so that students can run and verify the algorithm on quantum computers. - **Combination of theory and practice**: Combine theoretical analysis and practical operation to improve students' comprehensive understanding ability of quantum computing. ### Target audience - **Beginners**: Students with a basic understanding of quantum computing and hoping to further improve their understanding through complex algorithms. - **Advanced learners**: Students who have studied the HHL algorithm but need specific numerical examples to strengthen their understanding. - **Educators**: Teachers who hope to introduce the HHL algorithm and its applications in teaching. Through these contributions, the paper aims to provide a comprehensive and practical resource for quantum computing education, helping students and educators better master this cutting - edge technology.