English

On Refactoring Quantum Programs

Software Engineering 2023-06-21 v1 Programming Languages Quantum Physics

Abstract

Refactoring is a crucial technique for improving the efficiency and maintainability of software by restructuring its internal design while preserving its external behavior. While classical programs have benefited from various refactoring methods, the field of quantum programming lacks dedicated refactoring techniques. The distinct properties of quantum computing, such as quantum superposition, entanglement, and the no-cloning principle, necessitate specialized refactoring techniques. This paper bridges this gap by presenting a comprehensive set of refactorings specifically designed for quantum programs. Each refactoring is carefully designed and explained to ensure the effective restructuring of quantum programs. Additionally, we highlight the importance of tool support in automating the refactoring process for quantum programs. Although our study focuses on the quantum programming language Q\#, our approach is applicable to other quantum programming languages, offering a general solution for enhancing the maintainability and efficiency of quantum software.

Keywords

Cite

@article{arxiv.2306.10517,
  title  = {On Refactoring Quantum Programs},
  author = {Jianjun Zhao},
  journal= {arXiv preprint arXiv:2306.10517},
  year   = {2023}
}