Skip to main content

Large-Scale Formal Proof for the Working Mathematician

Periodic Reporting for period 2 - ALEXANDRIA (Large-Scale Formal Proof for the Working Mathematician)

Reporting period: 2019-03-01 to 2020-08-31

Mathematics lies at the heart of science and technology. Everything from medical devices to aircraft to finance relies in part on the work of mathematicians. However, as the world of mathematics becomes ever vaster, more abstract and more complex, questions of correctness become more pressing. Proofs are sometimes hundreds of pages long, a worrying number of errors are discovered, and even some definitions are barely accessible to more than a handful of specialists.

Our solution is to involve the use of computer software, so-called interactive theorem provers (specifically, Isabelle/HOL). These encode the rules of mathematical logic in software, eliminating human error but introducing their own issues. Chief among these are the labour sometimes needed to convince the software of facts that seem obvious to a mathematician, especially where intuition is involved (though intuition can also be a source of errors). Another major issue is how to encompass the immense and varied world of mathematical ideas within the rigid framework of a formal logic. Yet another set of issues concerns how to manage the huge libraries of mathematical knowledge that have already been codified on the computer so that relevant information (not only facts, but reasoning techniques) can easily be found. And these libraries still lack much fundamental material.

We are addressing these issues through several parallel approaches. One has been to consolidate and extend the already considerable Isabelle/HOL libraries for analysis, algebra, etc. Another has been to undertake pilot studies in the formalisation of a wide variety of mathematical topics, concerning transcendental numbers, quantum computing, projective geometry, ordinal partitions, etc. Yet another has focused on verified techniques for performing algebraic computations such as root isolation. More recently, our focus has shifted using machine learning to support searching for facts in libraries using natural language, and eventually, searching for reusable proof fragments.

ALEXANDRIA aims to create a proof development environment attractive to working mathematicians, utilising the best technology available across computer science. Its focus will be the management and use of large-scale mathematical knowledge, both theorems and algorithms. The project objectives include

• The formalisation of core mathematical knowledge, in a machine-checked format
• Codification of core mathematical algorithms, including proofs of their correctness
• Tools for searching and applying this knowledge, based on machine learning
• Linking of all this knowledge to the existing mathematics literature

ALEXANDRIA involves mathematicians and computer scientists working jointly to achieve this vision.
At the start, the two mathematicians on the team selected areas of mathematics to formalise. This had several aims, including familiarising them with the advantages and limitations of Isabelle/HOL and to develop their views on the further directions of the project. They formalised results from two mathematics research papers (Irrational Rapidly Convergent Series; The Transcendence of Certain Infinite Series) and a highly diverse group of advanced mathematical topics. Notable is our work on quantum computation. We formalised some quantum algorithms and related theorems, e.g. quantum teleportation, a quantum communication protocol that allows a quantum state to be exactly transferred from one place to another. We found several errors in mathematics journal papers.

We worked heavily on consolidating and reorganising our libraries and formalised mathematics, producing a user manual identifying the the main topics in the Analysis library's 150K proof lines and 95 formal theories. Substantial amounts of new material was added to the libraries, mostly in the field of analysis but also algebra. These are large formal developments comprising tens of thousands lines of formal proofs.

We developed considerable infrastructure to support intelligent search in the libraries through natural language queries. Our ambitious aim is to index all 2.5 million lines of Isabelle's Archive of Formal Proofs. General mechanisms are in place to apply machine learning to a number of project objectives. Existing approaches to search only work if you know the right keywords and have already loaded the right libraries. This work is still ongoing.

Verified Computer Algebra is another project focus. Computers have long been able to perform algebraic manipulations, but much of this software is not trustworthy enough for the needs of mathematicians. We have developed procedures to count the solutions of polynomial equations satisfying various conditions. Such procedures have numerous applications in engineering.
"We have made progress in several directions. We have achieved the first ever formalisations of many results, across the spectrum of mathematical topics. As noted above, we have found an error in a key paper on quantum computation. Formalising the existence of an algebraic closure for an arbitrary field is another major accomplishment. This work on formalised mathematics will continue.

Recent activity on machine learning, based on the morning of our millions of lines of existing proofs, is just starting to bear fruit and we can expect to see the emergence of a new class of user support based on the ability to find relevant material, both theorems and reusable fragments of proofs, within the next year or two. The next step is the evaluation and refinement of our search engine in a broader user setup. Our intelligent search efforts required the development of considerable infrastructure (i.e. information extraction), which benefits the broad machine learning aspects of the project.

Speaking more generally, mathematics as a subject is beginning to accept the idea of computer-assisted support. The 2020 version of the Mathematics Subject Classification includes the category ""Computer science support for mathematical research / Theorem proving (automated and interactive theorem provers, deduction, resolution, etc.)."" We do not take credit for this development, but it represents recognition of our objectives."