Teaching Quantum Neural Network (QNN) Concepts Through Artificial Neural Networks (ANNs): A Python Example Using the Iris Dataset
Ernane José Xavier Costa, José Lucas De Melo Costa
Abstract Quantum neural networks (QNNs) are emerging as a promising paradigm at the intersection of quantum computing and artificial intelligence. However, their conceptual abstraction and physical implementation remain challenging in educational contexts. In this work, we present a didactic framework to teach the fundamentals of QNNs by leveraging classical artificial neural networks (ANNs), Python simulation with Qiskit, and analysis of training dynamics using the Iris dataset. The paper begins with a theoretical comparison between classical and quantum neurons, followed by the design of a full QNN training algorithm implemented in Python. Through simulated results and pedagogical discussion, we show how learners can explore key aspects of quantum learning—including superposition, variational circuits, probabilistic measurement, and optimization—without access to quantum hardware. The use of graphical outputs and code-structure correspondence enhances student engagement and promotes algorithmic thinking. This approach supports quantum science education by offering a reproducible, interactive, and conceptually aligned method for introducing QNNs in undergraduate and graduate classrooms.
•Sep 22, 2025•0 citations