# A Graph-Based Approach for Modelling Quantum Circuits
## 2 Related Work
[18] sets out some of the principles that should be preserved when designing modelling languages for quantum software by providing a set of extensions to UML to abstractly model arbitrary circuits. However, no details are provided on the modelling of quantum circuits, only their integration as part of a hybrid system. In [19], some ideas for deriving new languages for modelling quantum software are provided. In particular, they consider an approach in which metamodels are used for modelling quantum programs as extensions of UML. In [20], MDE4 QAI is proposed as an MOF-based metamodelling framework for integrating quantum computing and Artificial Intelligence. The paper [21] presents extensions, again as UML profiles, for use case, class, sequence, activity, and deployment diagrams, to enable the development of hybrid systems (i.e., systems that integrate quantum programs with classical software) through the use of up to 20 stereotypes. The quantum UML profile, and the examples of its use with different UML diagrams, provides a set of design guidelines for the development of classical-quantum information systems. They also describe a way to define the relationships between classical and quantum software and how these relationships can be modelled in abstract designs. Of relevance in the context of the present work are the UML activity diagrams used for modelling quantum circuits. However, as discussed below, despite fitting such an extension to the UML profile, the generated models for representing quantum circuits present some specific problems in terms of navigation and manipulation. In summary, to date, these are the works that have been identified so far that are taking the first steps towards integrating quantum software development into a model-driven approach. Despite the enormous interest in QC, there are still many challenges to overcome in order to adopt QC in a definitive manner, beyond mere entertainment or curiosity in the use of quantum technology, as well as other aspects of a socio-economic nature, and of the comprehensibility of the paradigm [22]. Most programming languages for quantum software development typically provide an implementation in the Python programming language of the quantum concepts needed to design quantum programs. This is the case for libraries as well-known and used in the sector as Qiskit from IBM, Cirq from Google, or PennyLane from Kanadu. These libraries provide, in the form of classes and objects, implementations of the elements used in quantum programming, such as Qbit, quantum gates (with all its varieties), measurement, classical bit, etc. These classes are linked to the programming language used and, therefore, programs are generally not easily exported to other programming languages. The usual solution to this interoperability problem is to provide back-ends, exporters, or plug-ins that generate a new version of the program for different quantum languages or hardware. Therefore, most quantum programming languages do not follow an approach like the one proposed in this article, but rather their Python libraries directly provide an implementation of quantum programming elements. A notable exception to this is the quantum photonics software library Strawberry Fields [23], which includes a domain-specific language for continuous-variable quantum computation, called Blackbird, embedded in the Python library that provides its functionality. Continuous variable QC [24] employs physical quantities with continuous eigenvalue spectrum to perform quantum computation. In this approach, mathematical tools such as operator theory and the calculus of continuous variables are used to describe and manipulate the quantum states of these systems. Continuous variable QC expands the possibilities of quantum computing by working with more complex and information-rich systems due to the continuity of the variables involved.