Abstract

We formalize the theory of quantum Hoare logic (QHL) [TOPLAS 33(6),19], an extension of Hoare logic for reasoning about quantum programs. In particular, we formalize the syntax and semantics of quantum programs in Isabelle/HOL, write down the rules of quantum Hoare logic, and verify the soundness and completeness of the deduction system for partial correctness of quantum programs. As preliminary work, we formalize some necessary mathematical background in linear algebra, and define tensor products of vectors and matrices on quantum variables. As an application, we verify the correctness of Grover’s search algorithm. To our best knowledge, this is the first time a Hoare logic for quantum programs is formalized in an interactive theorem prover, and used to verify the correctness of a nontrivial quantum algorithm.

Highlights

  • Due to the rapid progress of quantum technology in the recent years, it is predicted that practical quantum computers can be built within 10–15 years

  • We formally prove the main results of quantum Hoare logic in Isabelle/HOL

  • It is to be expected that formal verification of quantum Hoare logic and quantum algorithms will take much more effort

Read more

Summary

Introduction

Due to the rapid progress of quantum technology in the recent years, it is predicted that practical quantum computers can be built within 10–15 years. Programmable superconductor quantum computers and trapped ion quantum computers have been built in universities and companies [1,3,4,6,23]. In another direction, intensive research on quantum programming has been conducted in the last decade [16,45,51,53], as surveyed in [27,52]. Several quantum programming languages have been defined and their compilers have been implemented, including Quipper [31], Scaffold [35], QWire [47], Microsoft’s LIQUi| [25] and Q# [57], IBM’s OpenQASM [22], Google’s Cirq [30], ProjectQ [56], Chisel-Q [40], Quil [55] and Q |SI [39]. These research allow quantum programs to first run on an ideal simulator for testing, and on physical devices [5]. Many small quantum algorithms and protocols have already been programmed and run on IBM’s simulators and quantum computers [1,2]

Objectives
Discussion
Conclusion
Full Text
Published version (Free)

Talk to us

Join us for a 30 min session where you can share your feedback and ask us any queries you have

Schedule a call