Gabriel Braun

Cyril Cohen

Charly Gries

Stéphane Kastenbaum

Keywords:

In this thesis, we investigate how a proof assistant can be used to study the foundations of geometry. We start by focusing on ways to axiomatize Euclidean geometry and their relationship to each other. Then, we expose a new proof that Euclid's parallel postulate is not derivable from the other axioms of first-order Euclidean geometry.

This leads us to refine Pejas' classification of parallel postulates. We do so by considering decidability properties when classifying the postulates. However, our intuition often guides us to overlook uses of such properties. A proof assistant allows us to use a perfect tool which possesses no intuition: a computer.

Moreover, proof assistants let us leverage the computational capabilities of computers. We demonstrate how we enable the use of algebraic automated deduction methods thanks to the arithmetization of geometry. Finally, we present a specific procedure designed to automate proofs of incidence properties.

Résumé

Dans cette thèse, nous examinons comment un assistant de preuve peut être utilisé pour étudier les fondements de la géométrie. Nous débutons en nous concentrant sur les fac ¸ons d'axiomatiser la géométrie euclidienne et leurs relations. Ensuite, nous exposons une nouvelle preuve de l'indépendance de l'axiome des parallèles des autres axiomes de la géométrie euclidienne du premier ordre.

Cela nous amène à affiner la classification des plans de Hilbert de Pejas en considérant les propriétés de décidabilité. Mais, notre intuition nous amène souvent à négliger leur utilisation. Un assistant de preuve nous permet d'utiliser un outil parfait qui ne possède aucune intuition : un ordinateur.

De plus, les assistants de preuve nous laissent exploiter les capacités de calcul des ordinateurs. Nous démontrons comment utiliser de méthodes algébriques de déduction automatique en géométrie synthétique. Enfin, nous présentons une procédure spécifique destinée à automatiser des preuves d'incidence.

i First of all, I would like to thank my supervisors: Julien Narboux and Pascal Schreck. Thank you for your feedback, your constant availability, your patience,

Introduction

Throughout the history of mathematical proof, geometry has played a central role. As a matter of fact, one of the most influential work in the history of mathematics concerns geometry: Euclid's Elements [START_REF] Euclid | Euclid's Elements: all thirteen books complete in one volume : the Thomas Little Heath translation[END_REF]. For over 2000 years, it was considered as a paradigm of rigorous argumentation. Even nowadays, it still is the object of research [START_REF] Avigad | A formal system for Euclid's elements[END_REF][START_REF] Beeson | Proof-checking Euclid[END_REF]. Moreover, Euclid's Elements introduced the axiomatic approach which is still used today.

Furthermore, one of the important events in the history of mathematics is the foundational crisis of mathematics. Following the discovery of Russell's paradox, mathematicians searched for a new consistent foundation for mathematics. During this period, three different schools of thought emerged with the leading school opting for a formalist approach. Geometry played a significant role for this leading school. Indeed, it was led by Hilbert who began his work on formalism with geometry which culminated with Grundlagen der Geometrie [START_REF] Hilbert | Foundations of Geometry (Grundlagen der Geometrie[END_REF].

During this crisis, mathematicians started to differentiate theorems from metatheorems to highlight that the latter correspond to theorems about mathematics itself. As well as for mathematics, geometry has had a substantial place in the history of metamathematics. First, the earliest milestone in the history of metamathematics is probably the discovery of non-Euclidean geometry [START_REF] Bolyai | Appendix, Scientiam Spatii absolute veram exhibens[END_REF][START_REF] Lobatschewsky | Geometrische Untersuchungen zur Theorie der Parallellinien[END_REF][START_REF] Beltrami | Saggio di interpretazione della geometria Non-Euclidea[END_REF]. Incidentally, the impact of this discovery was very important in the history of mathematics. Second, aside from Hilbert, another prominent figure in metamathematics, namely Tarski, dedicated a notable part of his research to an axiomatization of geometry [Tar59, SST83, TG99] that he proposed with a special emphasis on its metamathematical properties.

Finally, geometry has influenced other areas of mathematics. When Descartes invented analytic geometry [START_REF] Descartes | La Géométrie. Open Court[END_REF], he started to consider squares of numbers not only as areas but also as lengths. This led him to analyze algebraic equations of degree higher than three which, until then, corresponded to three-dimensional objects and were regarded as the highest dimension of the universe. Thus, the invention of analytic geometry proved to be crucial in the development of modern algebra, yet, it contributed to the discovery of calculus too. Calculus was created by Leibniz [START_REF] Wilhelm | Nova methodus pro maximis et minimis, itemque tangentibus, qua nec fractas nec irrationales quantitates moratur, et singulare pro illi calculi genus[END_REF] and Newton [START_REF] Newton | The Method of Fluxions and Infinite Series (Translated from the Author's Latin Original by John Colson)[END_REF] to study continuously changing quantities. For example, Newton was investigating the evolution of the speed of a falling object. However, prior to him, no mathematician was able to determine this speed. Thanks to analytic geometry, Newton understood that it corresponded to the derivative of the position of the falling object, thus creating calculus. Algebra and calculus are not the only fields that geometry affected. Actually, number theory has always been one of the principal areas of application of geometry. As early as the third century BC, Euclid presented an exposition of number theory based on geometry. In 1995, geometry was still used by Wiles in his proof of Fermat's last theorem [START_REF] Wiles | Modular Elliptic Curves and Fermat's Last Theorem[END_REF][START_REF] Taylor | Ring-Theoretic Properties of Certain Hecke Algebras[END_REF].

One of the purposes of a mathematical proof is to guaranty the veracity of a mathematical statement. To this end, having access to a mechanism to check a mathematical proof becomes very attractive. This idea can be tracked back to Leibniz and his calculus ratiocinator, which, he invented in 1666 [START_REF] Wilhelm | Dissertation on the Art of Combinations[END_REF]. Nevertheless, Leibniz was way ahead of his time since it took hundreds of years for his dream to become reality. Indeed, the first formal system that could be mechanized, namely Frege's Begriffsschrift [START_REF] Frege | Begriffsschrift: Eine der arithmetische nachgebildete Formelsprache des reinen Denkens[END_REF], appeared in 1879 and the first logical framework, namely de Bruijn's Automath [START_REF] Nederpelt | Selected papers on Automath[END_REF], was designed in 1967. Since Automath, a plethora of proof assistants have been developed [START_REF] Wiedijk | The Seventeen Provers of the World: Foreword by Dana Scott[END_REF].

Interestingly, the same reasons that explain the central role of geometry in the history of mathematical proof also motivate computer-assisted proof in geometry. Indeed, the three axiomatic systems that we have mentioned so far, namely Euclid's postulates, Hilbert's axioms and Tarski's system of geometry, have provided the basis for systematic developments. Thus, for computerassisted proofs, these systematic developments can serve as references which contain fewer gaps than the average pen-and-paper proof. Another explanation for this central role was the many application areas, including mathematics itself, physics or more applied areas such as robotics. Hence, the mechanization of geometry paves the way for the formalization of these areas. Moreover, while the visual nature of geometry could suggest that its formalization inside a proof assistant would include unnecessary and tedious steps to derive the validity of facts that seem obvious, we believe on the contrary that dealing with these steps is critical. Either these steps could be automated through a systematic procedure. In this case, finding such a procedure 1 and implementing it would 1 With a view to implement a procedure automating steps of a formal proof, one class of proof assistants stands out: those based on intuitionistic type theories. Thanks to the Curry-Howard correspondence, expressing the relationship between programs and proofs, the procedure and its proof of correctness can be encoded in these proof assistants. Then, B i+1 and C i+1 . So, B i is between A and B i+1 and similarly C i is between A and C i+1 . We know that if two polygons, each being either a triangle or a quadrilateral, with an adjacent side, which combined form either a triangle or a quadrilateral, then the defect of this polygon is equal to the sum of the defects of the two polygons. Therefore, the defect of triangle AB i+1 C i+1 verifies that D( AB i+1 C i+1 ) > 2 D( AB i C i ). Having constructed the desired sequences of points (B i ) i∈N and (C i ) i∈N , we proved that, the existence of a triangle ABC with a positive defect D( ABC) > 0 leads to a contradiction, thus proving that the defect of any triangle is null.

Thanks to the discovery of non-Euclidean geometry, the status of Euclid's parallel postulate as a postulate was confirmed, thus ensuring that Legendre's proof is flawed. So let us examine this proof to find the reason why it does not constitute a demonstration.

The first statement made in this proof is that the defect of any triangle is either positive or null. Saccheri is the first mathematician to have considered the case where Euclid's parallel postulate would not hold [START_REF] Girolamo | Euclides ab omni naevo vindicatus[END_REF]. In doing so, he posed three hypotheses which could all be true. These hypotheses are known as Saccheri's three hypotheses. They are about a specific type of quadrilateral that we consider in Chapter II.4. Saccheri established that only one of these hypotheses could hold and that each of these hypotheses implies that the defect of any triangle is, respectively, either positive, null or negative. He later proved that the hypothesis leading to the defect of any triangle being negative was absolutely false. Nevertheless, there are geometries in which the defect of any triangle is negative such as elliptic geometry [START_REF] Cerroni | Some models of geometries after Hilbert's Grundlagen[END_REF]. This would seem to contradict Saccheri's findings but, in fact, it does not. Indeed, Saccheri was performing his studies in what is known as neutral geometry (or as Hilbert planes) where the defect of any triangle cannot be negative. Neutral geometry is defined by the set of axioms of Euclidean geometry from which the parallel postulate has been removed. Therefore, the reason why Legendre did not prove the parallel postulate must be somewhere else.

The next logical step that can be questioned is the assumption that, given D( ABC) > 0, there is an integer n such that 2 n D( ABC) > π. In order to assert the existence of such an integer n, the following axiom, known as Archimedes' axiom, must hold. Archimedes' axiom can be expressed in the following way. Given two segments AB and CD such that A is different from B, there exist some positive integer n and n + 1 points A 1 , • • • , A n+1 on line CD, such that A j is between A j-1 and A j+1 for 2 < j < n, A j A j+1 and AB are congruent for 1 < j < n, A 1 = C and D is between A n and A n+1 . As a matter of fact, this axiom was already implicitly used. Indeed, Saccheri's proof that the defect of any triangle is either positive or null is based on Archimedes' axiom. The last use of Archimedes' axiom could have more easily been missed: the additivity of the defect for particular polygons. This property is again only true when Archimedes' axiom is assumed because it relies on the associativity of the sum of angles which is only valid when the considered angles make less than two right angles. This last requirement cannot be met if the defect of any triangle is negative, thus making Archimedes' axiom necessary.

Next, we hinted that there are different meanings of being equivalent to Euclid's parallel postulate. We have seen that the importance of axiom system that we assume. So one could think that, in order for the property that the defect of any triangle is null to be equivalent to Euclid's parallel postulate, an extra axiom could be needed and that this axiom could render the axiom system inconsistent when assuming, for example, Archimedes' axiom. In fact, an extra axiom is indeed necessary for it to be equivalent to Euclid's parallel postulate. However, since Archimedes' axiom is sufficient for the equivalence, we still have not located the reason explaining why Legendre's proof is flawed. Actually, the reason for it is very common amongst flawed proof of Euclid's parallel postulate: a statement equivalent to it is implicitly used. Here the implicit assumption is made when asserting the existence of a line l through D i that intersects both sides of ∠BAC in B i+1 and C i+1 .

Searching for the flaw in Legendre's proof has allowed us to highlight the importance of knowing the exact assumptions made for a proof. This makes the use of a proof assistant appealing as a way to avoid implicit assumptions, as they only accept a proof if all the steps are detailed according to their rules. While the process of writing proofs to this level of details entails an obvious cost, the reward makes up for it: these proofs present a much higher level of confidence from which both mathematics and software have benefited.

Formalization of Mathematics and Software Verification

The capacity of proof assistants to deal with very large and complex demonstrations has been leveraged to convince the mathematical community of the status of theorem of several properties. In recent years, mathematical journals have received some proofs that were so long and so complicated that, in order for these proofs to be recognized as such, they had to be formalized inside a proof assistant. The first of these was the four color theorem [START_REF] Appel | Every planar map is four colorable[END_REF]. The four color theorem states that any planar map can be colored in such a way that no two adjacent colors are the same, using at most four colors. Because of the involvement of a computer program in the proof from Appel and Haken, it was only universally accepted when Gonthier and Werner [START_REF] Gonthier | A Computer-Checked Proof of the Four Colour Theorem[END_REF][START_REF] Gonthier | The Four Colour Theorem: Engineering of a Formal Proof[END_REF] formalized it in the Coq proof assistant [START_REF]The Coq Proof Assistant[END_REF]. The next theorem to have obtained its status thanks to a formalization of its proof inside a proof assistant is the Feit-Thompson odd order theorem [START_REF] Feit | Solvability of groups of odd order[END_REF]. This theorem, which expresses the solvability of all groups of odd order, was controversial because of the length of its proof: 255 pages. The formalization of the proof from Feit and Thompson in Coq was achieved by a team led by Gonthier [GAA + 13]. The last mathematical result of the sort is Hales' proof of the Kepler conjecture [START_REF] Callister | The Kepler conjecture[END_REF]. As for the four color theorem, the controversy surrounding this proof was explained by the fact that it relied on a computer program. To bring the debate to a conclusion, Hales led a team which completed the formalization of his proof [HAB + 17] in HOL-Light [START_REF] Harrison | HOL Light: A tutorial introduction[END_REF] and Isabelle [START_REF] Nipkow | Isabelle/HOL: A Proof Assistant for Higherorder Logic[END_REF]. Although their proofs were not questioned by the mathematical community, two other major theorems have been formalized inside proof assistants: the prime number theorem, verified in Isabelle by Avigad, Donnelly, Gray and Raff [START_REF] Avigad | A Formally Verified Proof of the Prime Number Theorem[END_REF] as well as in HOL-Light by Harrison [Har09], and the Jordan curve theorem formalized in HOL-Light by Hales [START_REF] Callister | The Jordan Curve Theorem, Formally and Informally[END_REF].

Proof assistants have not been restricted to the formalization of mathematics. They have also been used to certify computer programs. Some programs are so critical that proving that they are bug-free or respect their specifications can avoid significant losses, be they economical, industrial or even human. Nowadays, the use of computer programs in aerospace, financial, medical or nuclear industries justifies the need for certified software to avoid such losses. To achieve this goal, several formalizations have been conducted in the context of computer science. Probably most notable is the formal verification of the functional correctness of the seL4 microkernel in Isabelle has been achieved by a team led by Klein [KEH + 09]. This certification ensures to correct behavior of the microkernel according to its specifications as well as the absence of bugs such as deadlocks, buffer overflows or arithmetic exceptions. The other formalization effort in computer science that we would like to mention has been completed by a team led by Leroy [START_REF] Leroy | Formal Certification of a Compiler Back-end or: Programming a Compiler with a Proof Assistant[END_REF]. They carried out the specification, the implementation, and the formal verification of the CompCert C compiler in Coq.

Formalization of Geometry

Another way of harvesting the power of computers for theorem proving purposes is to take advantage of their computational capabilities. Due to the success of the application of automated theorem proving to geometry, we focus on it in Part III. Nonetheless, geometry has also been an important subject of research in interactive theorem proving. The major part of this research has been devoted to Euclidean geometry. In fact, in Part I, we cover the formalization of Euclidean geometry. Besides Euclidean geometry, projective geometry has also been explored using proof assistants. Magaud, Narboux and Schreck proposed alternatives to the traditional axiom systems [START_REF] Coxeter | Projective Geometry[END_REF] for plane and space projectice geometry based on the notion of ranks and verified using Coq that Desargues' property holds in the latter [START_REF] Magaud | A Case Study in Formalizing Projective Geometry in Coq: Desargues Theorem[END_REF]. The mutual interpretability of their systems with the traditional ones was then formally proved by Braun, Magaud and Schreck in Coq [START_REF] Braun | An Equivalence Proof Between Rank Theory and Incidence Projective Geometry[END_REF]. Furthermore, the formalization of complex geometry has been investigated by Marić and Petrović [START_REF] Marić | Formalizing Complex Plane Geometry[END_REF]. They defined the extended complex plane both in terms of complex projective lines and as the stereographic projection of the Riemann sphere to study Möbius transformations and generalized circles.

Despite not being branches of geometry, two fields strongly connected to geometry have been the object of significant formalization efforts: non-standard analysis and computational geometry. Non-standard analysis is the field dedicated to the analysis of infinitesimals through hyperreal numbers. Fleuriot formalized notions of non-standard analysis in geometry in Isabelle to mechanize the geometric part of Newton's Principia [START_REF] Fleuriot | Theorem Proving in Infinitesimal Geometry[END_REF] and Kepler's law of Equal Areas [START_REF] Fleuriot | Nonstandard Geometric Proofs[END_REF] using methods of automated theorem proving. Additionally, the discrete model of the continuum known as the Harthong-Reeb line has been formalized in Coq by Magaud, Chollet and Fuchs [START_REF] Magaud | Formalizing a Discrete Model of the Continuum in Coq from a Discrete Geometry Perspective[END_REF] and in Isabelle by Fleuriot [START_REF] Fleuriot | Exploring the Foundations of Discrete Analytical Geometry in Isabelle/HOL[END_REF]. Computational geometry is the study of data structures and algorithms used for solving geometric problems. In Coq, the formalization of combinatorial maps and hypermaps have been caried out by Puitg and Dufourd [START_REF] Franc | Formal specification and theorem proving breakthroughs in geometric modeling[END_REF] as well as Dehlinger and Dufourd [START_REF] Dehlinger | Formalizing generalized maps in Coq[END_REF], and Dufourd [START_REF] Dufourd | A Hypermap Framework for Computer-aided Proofs in Surface Subdivisions: Genus Theorem and Euler's Formula[END_REF], respectively. These structures have allowed to formally prove the correctness of several algorithms such as the plane Delaunay triangulation algorithm, studied by Dufourd and Bertot [START_REF] Dufourd | Formal study of plane Delaunay triangulation[END_REF] in Coq. Furthermore, various convex hull algorithms have also been proved correct by Pichardie and Bertot [START_REF] Pichardie | Formalizing Convex Hull Algorithms[END_REF] in Coq, by Meikle and Fleuriot [MF06] in Isabelle, and by Brun, Dufourd and Magaud [START_REF] Brun | Formal Proof in Coq and Derivation of a Program in C++ to Compute Convex Hulls[END_REF] in Coq.

We invite the reader to refer to [START_REF] Narboux | Computer-assisted Theorem Proving in Synthetic Geometry[END_REF] for a more exhaustive description of the existing formalizations of geometry.

This Thesis

All of these achievements in the field of interactive theorem proving further motivate the formalization of geometry. Yet, we already mentioned three axiom systems for Euclidean geometry: Euclid's, Hilbert's and Tarski's axioms. So, the question that naturally arises is: Which axiom system should we formalize to build a systematic development of geometry? This question is of relevance to foundations of geometry which concern themselves with geometrical axiom systems and metatheorems about them. These metatheorems provide grounds for selecting an axiom system. Once an axiom system has been selected for its metatheoretical properties it seems compelling to not restrict ourselves to the formalization of a systematic development based on this system but to formalize the proof of these properties too. However, metatheoretical properties are not only relative to geometrical theories but also to the logic. In constructive mathematics, where the law of excluded middle and the axiom of choice are not valid, the choice of version of the parallel postulate is crucial for a "folklore theorem" expressing the mutual interpretability of Hilbert's and Tarski's axioms. This theorem is based on the culminating result of both [START_REF] Hilbert | Foundations of Geometry (Grundlagen der Geometrie[END_REF] and [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF], namely the arithmetization of Euclidean geometry. Nevertheless, as we see in this thesis, in constructive mathematics, the arithmetization of Euclidean geometry, as defined by Descartes, cannot be achieved with some versions of the parallel postulate, thus resulting in the validity of this theorem to be dependent on the choice of either the logic or the version of the parallel postulate. As tempting as studying the refinements required for certain metatheoretical properties to remain valid in constructive mathematics may be, it is quite easy to overlook uses of statements that are not valid in constructive mathematics [START_REF] Schechter | Constructivism is difficult[END_REF]. Having a mechanical way to guarantee that a proof is indeed constructive can then be critical, hence making proof assistants based on intuitionistic type theories particularly desirable to perform this kind of studies.

In this thesis, our aim is to extend the GeoCoq library and simultaneously study its axiomatic foundations from a metatheoretical perspective. The GeoCoq library provides a formal development of geometry based on Tarski's system of geometry [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] which can be found at: http://geocoq.github.io/GeoCoq/ Tarski's system of geometry was chosen as a basis for this library for its well-known metamathematical properties, the most relevant ones being its consistency and completeness [START_REF] Tarski | Tarski's System of Geometry[END_REF]. The development is carried out in the Coq proof assistant, which, for the purpose of studying metatheoretical properties in constructive mathematics, is conveniently based on an intuitionistic type theory. The theory behind Coq is the Calculus of Inductive Constructions [START_REF] Coquand | Inductively defined types[END_REF] which unifies Martin-Löf type theory [START_REF] Martin-Löf | Intuitionistic Type Theory[END_REF] and the Calculus of Constructions [START_REF] Coquand | The Calculus of Constructions[END_REF]. The reader not familiar with Coq or SSReflect, which will be used in this thesis, can find in the Coq'Art [START_REF] Bertot | Interactive Theorem Proving and Program Development, Coq'Art: The Calculus of Inductive Constructions[END_REF] and the user manual of SSReflect [START_REF] Gonthier | A Small Scale Reflection Extension for the Coq system[END_REF] introductions to this proof assistant and its extension.

The main contributions of this thesis can be summarized as follows:

• In the context of Tarski's system of geometry, we defined the arithmetic operations geometrically and formalized the proof that they verify the properties of an ordered field. • We formalized that Cartesian planes over a Pythagorean ordered field form a model of Tarski's system of geometry (excluding continuity axioms). • We formally proved that Tarski's axioms for plane neutral geometry can be derived from the corresponding Hilbert's axioms. • We used Herbrand's theorem to give a new proof that Euclid's parallel axiom is not derivable from the other axioms of first-order Euclidean geometry. • We proved that, by dropping the law of excluded middle, point equality decidability is sufficient to achieve the arithmetization of Tarski's geometry.

• We provided a clarification of the conditions under which different versions of the parallel postulate are equivalent and formalized the proofs of equivalence. • We implemented a reflexive tactic for automated generation of proofs of incidence to an affine variety. • In the context of Tarski's system of geometry, we introduced Cartesian coordinates, and provided characterizations of the main geometric predicates, which enabled the use of algebraic automated deduction methods in synthetic geometry.

Most of these contributions have already been described in the following papers:

• Pierre Boutry, Gabriel Braun This thesis collects these papers in slightly modified form. Chapter III.1 contains a generalization of one of the procedure presented in:

• Pierre Boutry, Julien Narboux, Pascal Schreck, and Gabriel Braun. Using small scale automation to improve both accessibility and readability of formal proofs in geometry. In Francisco Botana and Pedro Quaresma, editors, Proceedings of the Tenth International Workshop on Automated Deduction in Geometry, Proceedings of ADG 2014, pages 31-49, 2014

Chapter I.1, Section 2 describes a work not yet published which has been realized in collaboration with Cyril Cohen. We would like to specify that, while we collaborated on the writing of most parts of these papers, the paper entitled Herbrand's theorem and non-Euclidean geometry was almost entirely written by Michael Beeson. We had found an informal proof of the independence of the parallel postulate in Tarski's system of geometry (excluding the continuity axiom) without actually constructing a model of non-Euclidean geometry which we presented to him. He then came up with the idea of using Herbrand's theorem to formalize our argument, extended it to Tarski's system of geometry with continuity axioms using the "Cauchy bound" and wrote the paper for which we only proposed a few modifications. Because Chapter I.3, Section 1, describing the results of this paper, represents the only part of this thesis which has not been formalized, we often misuse "prove" when we actually mean "mechanize the already known proof of" for the sake of brevity.

The formalization described in this thesis is the result of a collaborative work. Therefore we will refrain from providing data such as the number of lines of code, or definitions or lemmas about this development. Nonetheless, we have collaborated to most parts of this development. For example, even for the formalization of the arithmetization of Tarski's system of geometry, where the last chapters of [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] to be formalized were clearly allocated among the contributors, we formalized additional results which were not included in the chapters of [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] allocated to the other contributors in order to complete our part of the formalization.

The rest of this thesis is organized as follows. Part I presents our results on the formalization of foundations of Euclidean geometry. In this part, we focus on Tarski's system of geometry: we mechanize its arithmetization and the proof of its satisfiability. Moreover, we formally prove the mutual interpretability of Hilbert's axioms and Tarski's system of geometry, and expose our proof that Euclid's parallel axiom is not derivable from the other axioms of first-order Euclidean geometry and our progress towards obtaining the decidability of every first-order formula. Part II is devoted to the clarification of the conditions under which different versions of the parallel postulate are equivalent and formalization of the proofs of equivalence. In this part, we refine Pejas' classification of Hilbert planes [START_REF] Pejas | Die Modelle des Hilbertschen Axiomensystems der absoluten Geometrie[END_REF] in the context of constructive mathematics, derive a surprising equivalence between continuity axioms and a decidability property and formalize of a variant of Szmielew's theorem expressing that every statement which is false in hyperbolic geometry and correct in Euclidean geometry is equivalent to the parallel postulate. Finally, we describe our work on automated theorem proving in geometry in Part III. In this part, we develop a reflexive tactic for automated generation of proofs of incidence to an affine variety which has been used throughout the rest of the formalization presented in this thesis, present our approach based on bootstrapping to obtain the characterizations of the geometric predicates, and illustrate the concrete use of our formalization with several applications of the Gröbner basis method in synthetic geometry.

Part I Foundations of Euclidean Geometry

There are several ways to define the foundations of Euclidean geometry on which we focus in this part. In the synthetic approach, the axiom system is based on some geometric objects and axioms about them. The best-known modern axiomatic systems based on this approach are those of Hilbert [START_REF] Hilbert | Foundations of Geometry (Grundlagen der Geometrie[END_REF] and Tarski [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. 1 Readers unfamiliar with Tarski's system of geometry may also refer to [START_REF] Tarski | Tarski's System of Geometry[END_REF] which describes its axioms and their history. In the analytic approach, a field F is assumed (usually R) and the space is defined as F n . In the mixed analytic/synthetic approach, one assumes both the existence of a field and also some geometric axioms. For example, the axiomatic systems proposed by the School Mathematics Study Group for teaching geometry in highschool [START_REF]Mathematics for high school: Geometry. Teacher's commentary[END_REF] in North America in the 1960s are based on Birkhoff's axiomatic system [START_REF] David | A Set of Postulates for Plane Geometry, Based on Scale and Protractor[END_REF]. In this axiom system, the existence of a field to measure distances and angles is assumed. This is called the metric approach. A modern development of geometry based on this approach can be found in the books of Millman or Moise [START_REF] Millman | Geometry: A Metric Approach with Models[END_REF][START_REF] Moise | Elementary Geometry from an Advanced Standpoint[END_REF]. The metric approach is also used by Chou, Gao and Zhang for the definition of the area method [START_REF] Chou | Machine Proofs in Geometry[END_REF] (a method for automated deduction in geometry). Analogous to Birkhoff's axiomatic system, the field serves to measure ratios of signed distances and areas. The formalization in Coq of the axioms can be found in [START_REF] Janičić | The Area Method : a Recapitulation[END_REF]. Finally, in the relatively modern approach for the foundations of geometry, a geometry is defined as a space of objects and a group of transformations acting on it (Erlangen program [START_REF] Klein | A comparative review of recent researches in geometry[END_REF][START_REF] Klein | Vergleichende Betrachtungen über neuere geometrische Forschungen[END_REF]).

Although these approaches seem very different, Descartes proved that the analytic approach can be derived from the synthetic approach by defining addition, multiplication and square root geometrically [START_REF] Descartes | La Géométrie. Open Court[END_REF]. This is called arithmetization and coordinatization of geometry and it represents the culminating result of both [START_REF] Hilbert | Foundations of Geometry (Grundlagen der Geometrie[END_REF] and [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF].

As far as we know, there was no existing formalization of the arithmetization of Euclidean plane geometry inside a proof assistant. However the reverse connection, namely that the Euclidean plane is a model of this axiomatized geometry, has been mechanized by Petrović and Marić [START_REF] Petrović | Formalizing Analytic Geometries[END_REF] as well as by Makarios [START_REF] James | A Mechanical Verification of the Independence of Tarski's Euclidean Axiom[END_REF] in Isabelle. In [START_REF] Marić | Formalizing Complex Plane Geometry[END_REF], Marić and Petrović formalized complex plane geometry in the Isabelle/HOL theorem prover. In doing so, they demonstrated the advantage of using an algebraic approach and the need for a connection with a synthetic approach. Braun and Narboux also formalized the link from Tarski's axioms to Hilbert's in Coq [START_REF] Braun | From Tarski to Hilbert[END_REF], Beeson has later written a note [START_REF] Beeson | Proving Hilbert's axioms in Tarski geometry[END_REF] to demonstrate that the main results to obtain Hilbert's axioms are contained in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. Some formalization of Hilbert's foundations of geometry have been proposed by Dehlinger, Dufourd and Schreck [START_REF] Dehlinger | Higher-Order Intuitionistic Formalization and Proofs in Hilbert's Elementary Geometry[END_REF] in the Coq proof assistant, and by Dixon, Meikle and Fleuriot [START_REF] Meikle | Formalizing Hilbert's Grundlagen in Isabelle/Isar[END_REF] using Isabelle/HOL. Dehlinger, Dufourd and Schreck have studied the formalization of Hilbert's foundations of geometry in the intuitionistic setting of Coq [START_REF] Dehlinger | Higher-Order Intuitionistic Formalization and Proofs in Hilbert's Elementary Geometry[END_REF]. They focus on the first two groups of axioms and prove some betweenness properties. Meikle and Fleuriot have done a similar study within the Isabelle/HOL proof assistant [START_REF] Meikle | Formalizing Hilbert's Grundlagen in Isabelle/Isar[END_REF]. They went up to twelfth 2 theorem of Hilbert's book. Scott has continued the formalization of Meikle using Isabelle/HOL and revised it [START_REF] Scott | Mechanising Hilbert's foundations of geometry in Isabelle[END_REF]. He has corrected some "subtle errors in the formalization of Group III by Meikle". Scott was interested in trying to obtain readable proofs. Later, he developed a system within the HOL-Light proof assistant to automatically fill some gaps in the incidence proofs [START_REF] Scott | An Investigation of Hilbert's Implicit Reasoning through Proof Discovery in Idle-Time[END_REF]. Moreover Richter has formalized a substantial number of results based on Hilbert's axioms and a metric axiom system using HOL-Light [Ric]. Likewise, a few developments based on Tarski's system of geometry have been carried out. For example, Richter, Grabowski and Alama have ported some of our Coq proofs to Mizar [START_REF] Naumowicz | A Brief Overview of Mizar[END_REF] (forty-six lemmas) [START_REF] Richter | Tarski Geometry Axioms[END_REF]. Moreover, Beeson and Wos proved 200 lemmas of the first twelve chapters of [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] with the Otter theorem prover [START_REF] Beeson | Finding Proofs in Tarskian Geometry[END_REF]. Furthermore, Dur dević, Narboux and Janičić [S DNJ15] generated automatically some readable proofs in Tarski's system of geometry. Finally, von Plato's constructive geometry [vP95] has been formalized in Coq by Kahn [START_REF] Kahn | Constructive geometry according to Jan von Plato[END_REF]. None of these formalization efforts went up to Pappus' theorem nor to the arithmetization of geometry.

Some of these approaches have also been the object of metamathematical investigations. One of the first metamathematical results was the proof of the independence of the parallel postulate. Bolyai [START_REF] Bolyai | Appendix, Scientiam Spatii absolute veram exhibens[END_REF] and Lobachevsky [START_REF] Lobatschewsky | Geometrische Untersuchungen zur Theorie der Parallellinien[END_REF] published developments about non-Euclidean geometry which led to Beltrami's independence proof [START_REF] Beltrami | Saggio di interpretazione della geometria Non-Euclidea[END_REF]. In his thesis [START_REF] Narayan | Contributions to the Axiomatic Foundations of Geometry[END_REF], Gupta presented a variant of Tarski's system of geometry which he proved independent by providing independence models. Following the classical approach to prove that Euclid's fifth postulate is not a theorem 1 The first version of this axiomatic system appeared as note of Tarski's paper about his decision method for real closed fields [START_REF] Tarski | A Decision Method for Elementary Algebra and Geometry[END_REF]. 2 We use the numbering of theorems as of the tenth edition.

of neutral geometry, 3 Makarios has provided a formal proof of the independence of Tarski's Euclidean axiom [START_REF] James | A Mechanical Verification of the Independence of Tarski's Euclidean Axiom[END_REF]. He used the Isabelle proof assistant to construct the Klein-Beltrami model, where the postulate is not verified. This independence has also been proved without constructing a model of non-Euclidean geometry. Skolem [START_REF] Skolem | Logisch-kombinatorische Untersuchungen über die Erfüllbarkeit mathematischer Satzsysteme, nebst einem Theoreme über dichte Mengen[END_REF] already in 1920 proved the independence of a form of the parallel axiom from the other axioms of projective geometry, using methods similar to Herbrand's theorem. In 1944, Ketonen invented the system of sequent calculus made famous in Kleene [START_REF] Cole | Introduction to Metamathematics[END_REF] as G3, and used it to revisit Skolem's result and extend it to affine geometry. This result was reformulated using a different sequent calculus in 2001 by von Plato [vP01]. It should be noted that the modern proof of Herbrand's theorem also proceeds by cut-elimination in sequent calculus. More recently, new synthetic approaches have been proposed. These new approaches differ from the previous ones because they are intuitionistic axiomatizations. The first axiom system was due to Heyting [START_REF] Heyting | Axioms for Intuitionistic Plane Affine Geometry[END_REF] who introduced the concept of apartness. Later, von Plato presented an extension of this work which he implemented in type theory [vP95]. Finally, Beeson gave a constructive version of Hilbert's axioms [START_REF] Beeson | Constructive Geometry[END_REF] and Tarski's axioms [START_REF] Beeson | A Constructive Version of Tarski's Geometry[END_REF] and proved several metatheorems about his axiomatic systems. Part I is organized as follows. In Chapter I.1, we start by proving the mutual interpretability of the synthetic approach based on Tarski's system of geometry without continuity axioms and the analytic approach. Then, in Chapter I.2, we provide the proof that Tarski's axioms can be derived from Hilbert's axioms. Finally, in Chapter I.3, we present a new proof that Euclid's parallel postulate is not derivable from the other axioms of first-order Euclidean geometry and prove some decidability properties in the context of Tarski's system of geometry. CHAPTER I.1

Tarski's System of Geometry: a Theory for Euclidean Geometry

In this chapter, we describe the formalization of the mutual interpretability of Tarski's system of geometry without continuity axioms and Cartesian planes over a Pythagorean 1 ordered field. First, in Section 1, we present the axioms of Tarski's system of geometry and their formalization in Coq. Second, in Section 2 we expose our proof that Cartesian planes over a Pythagorean ordered field form a model of these axioms. Third, in Section 3, we report on the formalization of the final results of the systematic development of geometry based on Tarski's system of geometry due to Szmielew and Schwabhäuser [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]: the arithmetization and coordinatization of Euclidean geometry.

Formalization of Tarski's Axioms

In this section, we present Tarski's axioms and their formalization in Coq. We should point out that we omit the "continuity" axiom since the systematic development from Szmielew and Schwabhäuser was realized without relying on it. We also introduce a variant of this axiom system which we use to simplify the proof in the next section.

A Set of Axioms for Euclidean Geometry.

Tarski's axiom system is based on a single primitive type depicting points and two predicates, namely congruence and betweenness. AB ≡ CD states that the segments AB and CD have the same length. A B C means that A, B and C are collinear and B is between A and C (and B may be equal to A or C). For an explanation of the axioms and their history see [START_REF] Tarski | Tarski's System of Geometry[END_REF]. Tab. I.1.1 lists the axioms for Euclidean geometry while the full list of axioms of Tarski's system of geometry is given in Appendix B.

A1

Symmetry

AB ≡ BA A2 Pseudo-Transitivity AB ≡ CD ∧ AB ≡ EF ⇒ CD ≡ EF A3 Cong Identity AB ≡ CC ⇒ A = B A4 Segment construction ∃E, A B E ∧ BE ≡ CD A5 Five-segment AB ≡ A B ∧ BC ≡ B C ∧ AD ≡ A D ∧ BD ≡ B D ∧ A B C ∧ A B C ∧ A = B ⇒ CD ≡ C D A6 Between Identity A B A ⇒ A = B A7 Inner Pasch A P C ∧ B Q C ⇒ ∃X, P X B ∧ Q X A A8 Lower Dimension ∃ABC, ¬A B C ∧ ¬B C A ∧ ¬C A B A9 Upper Dimension AP ≡ AQ ∧ BP ≡ BQ ∧ CP ≡ CQ ∧ P = Q ⇒ A B C ∨ B C A ∨ C A B A10 Euclid A D T ∧ B D C ∧ A = D ⇒ ∃XY, A B X ∧ A C Y ∧ X T Y Table I.1.1.
Tarski's axiom system for Euclidean geometry.

The symmetry axiom for equidistance (A1 on Tab.I.1.1) together with the transitivity axiom for equidistance A2 imply that the equidistance relation is an equivalence relation between pair of points.

The identity axiom for equidistance A3 ensures that only degenerate segments can be congruent to a degenerate segment.

1 A Pythagorean field is a field in which every sum of squares is a square. The identity axiom for betweenness A6 expresses that the only possibility to have B between A and A is to have A and B equal. It also insinuates that the relation of betweenness is non-strict, unlike Hilbert's one. As Beeson suggests in [START_REF] Beeson | A Constructive Version of Tarski's Geometry[END_REF], this choice was probably made to have a reduced number of axioms by allowing degenerate cases of the Pasch's axiom. The inner form of Pasch's axiom A7 is the axiom Pasch introduced in [START_REF] Pasch | Vorlesung über Neuere Geometrie[END_REF] to repair the defects of Euclid. It intuitively says that if a line meets one side of a triangle, then it must meet one of the other sides of the triangle. There are three forms of this axiom. Thanks to Gupta's thesis [START_REF] Narayan | Contributions to the Axiomatic Foundations of Geometry[END_REF], one knows that the inner form and the outer form of this axiom are equivalent and that both of them allow us to prove the weak form. The inner form enunciates Pasch's axiom without any case distinction. Indeed, it indicates that the line BP must meet the triangle ACQ on the side AQ, as Q is between B and C (Fig.

I.1.3).

The lower two-dimensional axiom A8 asserts that the existence of three non-collinear points. [START_REF]Alfred Tarski: Early Work in Poland -Geometry and Teaching[END_REF], the suggestion, made by Gupta [START_REF] Narayan | Contributions to the Axiomatic Foundations of Geometry[END_REF] and others, that this postulate is due to Lorenz [START_REF] Friedrich | Grundriss der reinen und angewandten Mathematik[END_REF] is "doubtful". In fact, the statement to which Gupta refers seems to be the one given in [START_REF] De | The development of Euclidean axiomatics[END_REF] which is indeed different.

While there exist many statements equivalent to the parallel postulate, this version is particularly interesting, as it has the advantages of being easily expressed only in term of betweenness, and being valid in spaces of dimension higher than two.

Formalization in Coq.

Contrary to Hilbert's axiom system [DDS01, BN12], which leaves room for interpretation of natural language, Tarski's system of geometry can be straightforwardly formalized in Coq, as the axioms are stated very precisely. We defined the axiom system using three type classes (Tab. I.1.2). The first class Tarski neutral dimensionless regroups the axioms for neutral geometry of dimension at least two (A1-A8).

With the second class Tarski neutral dimensionless with decidable point equality, we also assume that we can reason by cases on the point equality (point equality decidability). This axiom does not appear in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF], although reasoning by cases on point equality is done as soon as the second chapter (the first chapter being dedicated to the axioms), because it is a tautology in classical logic, while the logic of Coq is intuitionistic. We say that a predicate is decidable when it verifies the excluded middle property.

The third class Tarski 2D corresponds to the axioms of planar neutral geometry (A1-A9) with excluded middle for point equality. Note that we do not assume that we can decide if A=B or not, just that we can reason by cases.

: forall A B C D E F, Cong A B C D -> Cong A B E F -> Cong C D E F; cong_identity : forall A B C, Cong A B C C -> A = B; segment_construction : forall A B C D, exists E, Bet A B E /\ Cong B E C D; five_segment : forall A A' B B' C C' D D', Cong A B A' B' -> Cong B C B' C' -> Cong A D A' D' -> Cong B D B' D' -> Bet A B C -> Bet A' B' C' -> A <> B -> Cong C D C' D'; between_identity : forall A B, Bet A B A -> A = B; inner_pasch : forall A B C P Q, Bet A P C -> Bet B Q C -> exists X, Bet P X B /\ Bet Q X A
P <> Q -> Cong A P A Q -> Cong B P B Q -> Cong C P C Q -> (Bet A B C \/ Bet B C A \/ Bet C A B) }.

Class Tarski_euclidean '(TnEQD : Tarski_neutral_dimensionless_with_decidable_point_equality

) := { euclid : forall A B C D T, Bet A D T -> Bet B D C -> A<>D -> exists X, exists Y, Bet A B X /\ Bet A C Y /\ Bet X T Y }.
Table I.1.2. Formalization of the axiom system in Coq .

Finally, the fourth class Tarski euclidean adds the parallel postulate to the axioms of the second class. For the sake of being able to later extend our results to higher dimension, we chose to handle the parallel postulate separately from the upper two-dimensional axiom.

A Variant of Tarski's System of Geometry.

With a view to simplify the proof in the next section, we introduce a variant of this axiom system. Petrović and Marić [START_REF] Petrović | Formalizing Analytic Geometries[END_REF] have proved formally in Isabelle that the Cartesian plane over the reals is a model of Tarski's axioms with continuity. In their proof of Pasch's axiom they had to distinguish several degenerate cases. This is due to the fact that this axiom allows to prove two properties about the betweenness which are independent of the general case of Pasch's axiom [START_REF] Wlodzimierz | Independence of Pasch's axiom[END_REF]. At first, these properties were taken as axioms by Tarski but later, the system was simplified since they could be derived. To simplify the proof of Pasch's axiom, we decided to reintroduce these properties as axioms: the symmetry of betweenness A143 on Tab. I.1.3 and the inner transitivity of betweenness A15. Furthermore we modified Pasch's axiom to have a version A7' which excludes the degenerate cases where the triangle ABC is flat or when P or Q are respectively not strictly between A and C or B and C. Having added these two axioms, following Gupta [START_REF] Narayan | Contributions to the Axiomatic Foundations of Geometry[END_REF], the identity axiom for betweenness became a theorem and could then be removed from the system. Later, when we were proving Euclid's axiom we realized that the same kind of distinctions was also needed so we decided to restrict this axiom to its general case A10', namely when the angle ∠BAC is non-flat and when D is different from T . It is an easy matter to check that axioms A7 and A10 are theorem of this alternative system so we omit the details.

A1

Cong

Symmetry AB ≡ BA A2 Cong Pseudo-Transitivity AB ≡ CD ∧ AB ≡ EF ⇒ CD ≡ EF A3 Cong Identity AB ≡ CC ⇒ A = B A4 Segment construction ∃E, A B E ∧ BE ≡ CD A5 Five-segment AB ≡ A B ∧ BC ≡ B C ∧ AD ≡ A D ∧ BD ≡ B D ∧ A B C ∧ A B C ∧ A = B ⇒ CD ≡ C D A7' Inner Pasch A P C ∧ B Q C∧ A = P ∧ P = C ∧ B = Q ∧ Q = C∧ ¬ (A B C ∨ B C A ∨ C A B) ⇒ ∃X, P X B ∧ Q X A A8 Lower Dimension ∃ABC, ¬A B C ∧ ¬B C A ∧ ¬C A B A9 Upper Dimension AP ≡ AQ ∧ BP ≡ BQ ∧ CP ≡ CQ ∧ P = Q ⇒ A B C ∨ B C A ∨ C A B A10' Euclid A D T ∧ B D C ∧ A = D ∧ D = T ∧ ¬ (A B C ∨ B C A ∨ C A B) ⇒ ∃XY, A B X ∧ A C Y ∧ X T Y A14 Between Symmetry A B C ⇒ C B A A15 Between Inner Transitivity A B D ∧ B C D ⇒ A B C
Table I.1.3. Variant of Tarski's axiom system for Euclidean geometry.

Satisfiability of the Theory

In this section, we present our proof that Cartesian planes over a Pythagorean ordered field form a model of the variant of Tarski's system of geometry that we have introduced in the previous section. First, we present the structure that we used to define this model. Then we define the model that we used, that is, the way we instantiated the signature of this system. Finally, we detail the proofs of some of the more interesting axioms.

The Real Field

Structure. The structure that was used to define this model was built by Cohen [START_REF] Cohen | Formalized algebraic numbers: construction and first-order theory[END_REF]. The real field structure results of the addition of operators to a discrete4 field: two boolean comparison functions (for strict and large comparison) and a norm operator. Elements of this real field structure verify the axioms listed in Tab. I.1.4. Finally, the elements of a real field structure are all comparable to zero. We should remark that this field is not necessarily Pythagorean. In fact, there is no defined structure in the Mathematical Components library [MT] that we used to define this model. However, the Pythagorean property is only required for the proof of the segment construction axiom A4. So we chose to prove that this axiom holds in our model by admitting an extra axiom which was defined in this library: the real closed field axiom. It states that intermediate value property holds for polynomial with coefficient in the field. Although this axiom is much stronger, we only used it to be able to define the square root of a number which is a sum of square and would therefore have a square root in a Pythagorean field.

The Model.

Let us now define our model. Being based on a single primitive type and two predicates, the signature of Tarski's system of geometry is rather simple. However, this system has the advantage of having a n-dimensional variant. To obtain this variant, one only needs to change the dimension axioms. So far, we have restricted ourselves to the planar version of this system. 6 With a view to extend the library to its n-dimensional variant, we wanted to define a model in which we could prove all but the dimension axioms in an arbitrary dimension to be able to construct a model of the n-dimensional variant by only proving the new dimension axioms. Hence we chose to define Tpoint as a vector of dimension n + 1 with coefficient in the real field structure F (we used the real field structure for all the development at the exception of the proof of the segment construction axiom) for a fixed integer n. We adopted Gupta's definition [START_REF] Narayan | Contributions to the Axiomatic Foundations of Geometry[END_REF] for the congruence, namely that AB ≡ CD if the squares of the Euclidean norms of B -A and D -C are equal. Actually Gupta also proved that any model of the n-dimensional variant of Tarski's system of geometry is isomorphic to his model. He defined that A B C holds if and only if there exists a

k ∈ F such that 0 ≤ k ≤ 1 and B -A = k(C -A). In fact, if such a k exists, it can be computed. By letting A = (a i ) 1≤i≤n+1 , B = (b i ) 1≤i≤n+1 and C = (c i ) 1≤i≤n+1 , if A = C then there exists a i ∈ N such that 1 ≤ i ≤ n + 1 and a i = c i
and in this case we set k to bi-ai ci-ai and if A = C we set k to zero. Therefore we defined a function ratio that computes the possible value for k, thus allowing us to define the betweenness by the boolean equality test. This was actually important as it permitted to directly manipulate the definition for betweenness by rewriting since we defined it as a boolean test. Finally, as it was often necessary to distinguish whether A B C holds due to a degeneracy or not we splitted the definition of the betweenness into two predicates: the first one capturing the general case of k being strictly between 0 and 1 and the second one capturing the three possible degenerate cases, namely either A = B, B = C or A = B and B = C.

Formally, we consider the following model:

2.3.

Proof that the Axioms hold in the Model. Now that we have defined the model, we focus on the proof that the axioms hold in this model. However, we do not detail the proofs of axioms A1, A2, A3 and A14 since they are rather straightforward. For the same reason, we do not cover the decidability of point equality.

Let us start by focusing on axioms A7' and A15 as their proofs are quite similar. When proving axiom A15 we know that A B D and B C D so let k 1 ∈ F be such that 0 < k 1 < 1 and B -A = k 1 (D -A) (the degenerate case of this axiom is trivial so we only consider the general case) and k 2 ∈ F be such that 0 < k 2 < 1 and C -B = k 2 (D -B). In order to prove that A B C we need to find a k ∈ F such that 0 < k < 1 and B -A = k(C -A). By calculation we find that k = k1 k1+k2-k1k2 and we can verify that 0 < k < 1. In a similar way, when proving axiom A7', we know that A P C and B Q C so let k 1 ∈ F be such that 0 < k 1 < 1 and P -A = k 1 (C -A) (the hypotheses imply that 0 < k 1 < 1 because A = P and P = C) and k 2 ∈ F be such that

0 < k 2 < 1 and Q -B = k 2 (C -B).
In order to prove that there exists a point X such that P X B and Q X A we need to find a k 3 ∈ F and a

k 4 ∈ F such that 0 < k 3 < 1, 0 < k 4 < 1 and k 1 (B -P ) + P = k 2 (A -Q) + Q. By calculation we find that k 3 = k1(1-k2) k1+k2-k1k2 and k 4 = k2(1-k1) k1+k2-k1k2
and we can verify that 0 < k 3 < 1 and 0 < k 4 < 1. In both of these proof, the ratios are almost identical to the point that it suffices to prove the following lemma:

Lemma ratio_bet a b c k1 k2 k3 : 0 < k1 -> 0 < k2 -> k1 < 1 -> 0 < k3 -> k3 < k1+k2-k1*k2 -> b -a == ((k1+k2-k1*k2)/k3)ˆ-1 *: (c -a) -> bet a b c.
It allows to prove quite easily both of these axioms. Axiom A4 can be proved in a analogous way: it suffices to set the point E that can be constructed using this axiom to D-C B-A (B -A) + A and to verify this point verifies the desired properties by calculation.

We now turn to axiom A5. We followed Makarios' approach for the proof of this axiom [START_REF] James | A Mechanical Verification of the Independence of Tarski's Euclidean Axiom[END_REF]. In his proof he used the cosine rule: in a triangle whose vertices are the vectors A, B and C we have

C -B 2 = C -A 2 + B -A 2 -2(B -A) • (C -A).
As noted by Makarios, using the cosine rule allows to avoid defining angles and properties about them. Applying the cosine rule for the triangles BCD and B C D allows to prove that D -C 2 = D -C 2 by showing that

(C -B) • (D -B) = (C -B ) • (D -B )
which can be justified, by applying the cosine rule again, this time in the triangles ABD and

A B D , if D -A -D -B -A -B = D -A -D -B -A -B
which we know from the hypotheses and if the ratios corresponding to the betweenness A B C and A B C are equal which can be obtained by calculation.

Next, let us consider axiom A10'. In the next part, we study different versions of the parallel postulate and classify them in groups which may not be equivalent depending on which theory or logic we consider them. It happens that this version is probably the simpler to prove in our model. Indeed, from the hypotheses we have two ratios

k 1 ∈ F and k 2 ∈ F such that 0 < k 1 < 1, 0 < k 2 < 1, D -A = k 1 (T -A) and D -B = k 2 (C -B). Using these ratios, it suffices to define X such that B -A = k 1 (X -A) and Y such that C -A = k 1 (Y -A).
So we know by construction that A B X and A C Y and we easily get that T -X = k 2 (Y -X) by calculation, thus proving that X T Y .

Finally the remaining two axioms are proved in a slightly different setting since they are the dimension axioms. Formally we fix the value of n to 1. In order to simplify the many rewriting steps needed for these proofs we started by establishing the following two lemmas: The reader familiar with SSReflect will have recognized the reflect predicate, described in [START_REF] Cohen | Formalized algebraic numbers: construction and first-order theory[END_REF] for example. In practive, these lemmas allowed to spare many steps that would have been repeated in almost every proof concerning the dimension axioms. Axiom A8 was much more straightforward to prove than axiom A9. In fact, it is enough to find three non-collinear points. We simply took the points (0, 0), (0, 1) and (1, 0): It was then an easy matter to verify axiom A8. For axiom A9, the idea of the proof that we formalized was to first show that, by letting M be the midpoint of P and Q, the equation

Definition
(x P -x M )(x M -x X ) + (y P -y M )(y M -y X ) = 0,
capturing the property that the points P , M , and X form a right angle with the right angle at vertex M , was verified when X would be equal to A, B or C:

Lemma cong_perp (a p q : 'rV[R]_(2)) (m := (1 / (1 + 1)) *: (p + q)) :
cong a p a q -> (p 0 0 -m 0 0) * (m 0 0 -a 0 0) + (p 0 1 -m 0 1) * (m 0 1 -a 0 1) = 0.

Next, we demonstrated that for three points A, B and C verifying

(x A -x B )(y B -y C ) -(y A - y B )(x B -x C ) = 0 are collinear in the sense that A B C ∨ B C A ∨ C A B: Lemma col_2D a b c : (a 0 0 -b 0 0) * (b 0 1 -c 0 1) == (a 0 1 -b 0 1) * (b 0 0 -c 0 0) -> (bet a b c \/ bet b c a \/ bet c a b).
Using the equations implied by cong_perp we could derive that

(x P -x M )(y M -y P ) ((x A -x B )(y B -y C ) -(y A -y B )(x B -x C )) = 0.
We were then left with three cases: either the abscissas of P and M are equal in which case the ordinate of A, B and C were equal thus sufficing to complete the proof, or the ordinates of P and M are equal in which case the abscissas of A, B and C were equal thus completing the proof, or

(x A -x B )(y B -y C ) -(y A -y B )(x B -x C ) = 0
corresponding to the lemma that we had proved and again allowing to conclude.

Putting everything together, we could prove that Cartesian planes over a Pythagorean ordered field form a model of the variant of Tarski's system of geometry, thus proving the satisfiability of the theory:

Global Instance Rcf_to_T2D : Tarski_2D Rcf_to_T_PED.

Global Instance Rcf_to_T_euclidean : Tarski_euclidean Rcf_to_T_PED.

The Arithmetization of Tarski's System of Geometry

In this section, we describe the formalization of the arithmetization of Tarski's system of geometry. First, we define the arithmetic operations. Then, we verify that these operations respect the properties of a Pythagorean ordered field. The summary of the definitions is given in Appendix A using the notations given in Appendix E.

Definition of Arithmetic Operations.

To define the arithmetic operations, we first needed to fix the neutral element of the addition O and the neutral element of the multiplication E. The line OE will then contain all the points for which the operations are well-defined as well as their results. Moreover, a third point E is required for the definitions of these operations. It is to be noticed that these points should not be collinear (collinearity is expressed with the Col predicate defined in Appendix A where all the predicates necessary for the arithmetization and the coordinatization of Euclidean geometry are listed together with their definition). Indeed, if they were collinear the results of these operations would not be well-defined. The three points A, B and C need to belong to line OE. These properties are formalized by the definition Ar2:

Definition Ar2 O E E' A B C := ˜Col O E E' /\ Col O E A /\ Col O E B /\ Col O E C.

Definition of Addition.

The definition of addition that we adopted is the one given in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] which is expressed in terms of parallel projection. 7 One could think of a definition of addition by extending the segment OB by the segment OA, this would work only for points (numbers) which have the same sign. The parallel projection allows to have a definition which is correct for signed numbers. The same definition is given by Hilbert in Chapter V, Section 3 of [START_REF] Hilbert | Foundations of Geometry (Grundlagen der Geometrie[END_REF]. Pj is a predicate that captures parallel projection. Pj A B C D denotes that either lines AB and CD are parallel or C = D. The addition is defined as a predicate and not as a function. Sum O E E' A B C means that C is the sum of A and B wrt. O, E and E .

Definition Sum O E E' A B C := Ar2 O E E' A B C /\ exists A', exists C', Pj E E' A A' /\ Col O E' A' /\ Pj O E A' C' /\ Pj O E' B C' /\ Pj E' E C' C. O E E A B A C C
To prove existence and uniqueness of the last argument of the sum predicate, we introduced an alternative and equivalent definition highlighting the ruler and compass construction presented by Descartes. Proj P Q A B X Y states that Q is the image of P by projection on line AB parallel to line XY and Par A B C D denotes that lines AB and CD are parallel.

Definition Sump O E E' A B C := Col O E A /\ Col O E B /\ exists A', exists C', exists P', Proj A A' O E' E E' /\ Par O E A' P' /\ Proj B C' A' P' O E' /\ Proj C' C O E E E'.
One should note that this definition is in fact independent of the choice of E , and it is actually proved in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. Furthermore, we could prove it by characterizing the sum predicates in terms of the segment congruence predicate:

Lemma sum_iff_cong : forall A B C, Ar2 O E E' A B C -> (O <> C \/ B <> A) -> ((Cong O A B C /\ Cong O B A C) <-> Sum O E E' A B C).
We used properties of parallelograms to prove this characterization and the properties about Sum, contrary to what is done in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] where they are proven using Desargues' theorem. 8 3.1.2. Definition of Multiplication. As for the definition of addition, the definition of multiplication presented in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] uses the parallel projection:

Definition Prod O E E' A B C := Ar2 O E E' A B C /\ exists B', Pj E E' B B' /\ Col O E' B' /\ Pj E' A B' C. O E E A B B C 7
We would like to point out that for the parallel projection to be defined, Proclus' postulate (Postulate 13), which is introduced in the next part, needs to holds. However, Playfair's postulate (Postulate 2), which is also introduced in the next part, would not allow such a construction. This illustrates our remark from the introduction that, in order to define the arithmetic operations as presented by Descartes, the choice of the parallel postulate is crucial. 8 We can remark that we proved the parallel case of this theorem without relying on Pappus' theorem but on properties about parallelograms.

Similarly to the definition of addition, we introduced an alternative definition which underlines that the definition corresponds to Descartes' ruler and compass construction:

Definition Prodp O E E' A B C := Col O E A /\ Col O E B /\ exists B', Proj B B' O E' E E' /\ Proj B' C O E A E'.
Using Pappus' theorem, we proved the commutativity of the multiplication and, using Desargues' theorem, its associativity. We omit the details of these well-known facts [Hil60, SST83].

Construction of an Pythagorean

Ordered Field. In his thesis [START_REF] Narayan | Contributions to the Axiomatic Foundations of Geometry[END_REF], Gupta provided an axiom system for the theory of n-dimensional Cartesian spaces over the class of all ordered fields. In [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF], a n-dimensional Cartesian space over Pythagorean ordered fields is constructed. We restricted ourselves to the planar case.

As remarked by Wu, the proofs are not as trivial as presented by Hilbert:

"However, the proofs are cumbersome and not always easy. They can all be found in Hilbert's 'Grundlagen der Geometrie.' It should be noted that Hilbert's proofs were only given for the generic cases, whereas the degenerate cases also need to be considered. Thus, the complete proofs are actually much more cumbersome than the original ones."

(Wen-Tsün Wu, page 40 [START_REF] Wu | Mechanical Theorem Proving in Geometries[END_REF])

3.2.1. Field Properties. In Tarski's system of geometry, the addition and multiplication are defined as relations capturing their semantics and afterwards the authors of [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] generalize these definitions to obtain total functions. Indeed, the predicates Sum and Prod only hold if the predicate Ar2 holds for the same points. All field properties are then proved geometrically [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. In theory, we could carry out with the relational versions of the arithmetic operators. But in practice, this causes two problems. Firstly, the statements become quickly unreadable. Secondly, we cannot apply the standard Coq tactics ring and field because they only operate on rings and fields whose arithmetic operators are represented by functions.

Obtaining the function from the functional relation is implicit in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. In practice, in the Coq proof assistant, we employed the constructive definite description axiom provided by the standard library: It allows to convert any relation which is functional to a proper Coq function. Another option, would be to change our axiom system to turn the existential axioms into their constructive version. We plan to adopt this approach in the future, but for the time being, we use the constructive definite description axiom provided by the standard library. As the use of the axiom turns the intuitionistic logic of Coq into an almost classical logic [START_REF] Lane | Hilbert's -operator in intuitionistic type theories[END_REF], we decided to postpone the use of this axiom as much as possible. For example, we defined the sum function relying on the following lemma:9 This function is not total, the sum is only defined for points which belong to our ruler (OE). Nothing but total functions are allowed in Coq, hence to define the ring and field structures, we needed a dependent type (a type which depends on a proof), describing the points that belong to the ruler. In Coq's syntax it is expressed as:

Definition F : Type := {P: Tpoint | Col O E P}.
Here, we chose a different approach than in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF], in which, as previously mentioned, the arithmetic operations are generalized to obtain function symbols without having to restrict the domain of the operations. Doing so implies that the field properties only hold under the hypothesis that all considered points belong to the ruler. This has the advantage of enabling the use of function symbols but the same restriction to the points belonging to the ruler is needed.

We defined the equality on F with the standard Coq function proj1 sig which projects on the first component of our dependent pair, forgetting the proof that the points belong to the ruler: Definition EqF (x y : F) := (proj1_sig x) = (proj1_sig y).

This equality is naturally an equivalence relation. One should remark that projecting on the first component is indeed needed. Actually, as we see later in this part, the decidability of the equality implies the decidability of collinearity in this theory. The decidability that we assumed was in Prop and not in Set to avoid assuming a much stronger axiom. By Hedberg's theorem, equality proofs of types which are in Set are unique. This allows to get rid of the proof relevance for dependent types. Nevertheless the decidability of the collinearity predicate is in Prop, where equality proofs are not unique. Therefore, the proof component is not irrelevant here.

Next, we built the arithmetic functions on the type F. In order to employ the standard Coq tactics ring and field or the implementation of setoids in Coq [START_REF] Sozeau | A New Look at Generalized Rewriting in Type Theory[END_REF], we proved some lemmas asserting that the operations are morphisms relative to our defined equality. For example, the fact that A = A and B = B (where = denotes EqF) implies A + B = A + B is defined in Coq as:

Global Instance addF_morphism : Proper (EqF ==> EqF ==> EqF) AddF.
With a view to apply the Gröbner basis method, we also proved that F is an integral domain. This would seem trivial, as any field is an integral domain, but we actually proved that the product of any two non-zero elements is non-zero even before we proved the associativity of the multiplication. Indeed, in order to prove this property, one needs to distinguish the cases where some products are null from the general case. Finally, we can prove we have a field:

Lemma fieldF : field_theory OF OneF AddF MulF SubF OppF DivF InvF EqF. Now, we present the formalization of the proof that the field is Pythagorean (every sum of two squares is a square) . We built a function P yth(A, B) = √ A 2 + B 210 derived from the following PythRel relation. Note that we needed to treat some special cases separately:

Definition PythRel O E E' A B C := Ar2 O E E' A B C /\ ((O = B /\ (A = C \/ Opp O E E' A C)) \/ exists B', Perp O B' O B /\ Cong O B' O B /\ Cong O C A B').
Using Pythagorean theorem (see Chapter III.2, Subsection 1.2), we showed that the definition of PythRel has the proper semantics (A 2 + B 2 = C 2 ):

Lemma PythOK : forall O E E' A B C A2 B2 C2, PythRel O E E' A B C -> Prod O E E' A A A2 -> Prod O E E' B B B2 -> Prod O E E' C C C2 -> Sum O E E' A2 B2 C2.
Then, we proved that if we add the assumption that the last argument of PythRel is positive then the relation is functional:

Lemma PythRel_uniqueness : forall O E E' A B C1 C2, PythRel O E E' A B C1 -> PythRel O E E' A B C2 -> ((Ps O E C1 /\ Ps O E C2) \/ C1 = O) -> C1 = C2.
3.2.2. Order. We proved that F is an ordered field. For convenience we proved it for two equivalent definitions. Namely, that one can define a positive cone on F or that F is equipped with a total order on F which is compatible with the operations. In [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF], one can only find the proof based on the first definition. The characterization of the betweenness predicate in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] is expressed in terms of the order relation and not positivity. The second definition is therefore better suited for this proof than the first one. Nevertheless, for the proof relying on the second definition, we decided 10 We use the √ to indicate that the created point is a square root of this sum but not necessarily the principal square root.

to prove the implication between the first and the second definition. Actually, an algebraic proof, unlike a geometric one, rarely includes tedious case distinctions.

In order to define the positive cone on F, we needed to define positivity. A point is said to be positive when it belongs to the half-line OE. Out O A B indicates that O belongs to line AB but does not belong to the segment AB, or that B belongs to ray OA.

Definition Ps O E A := Out O A E.
A point is lower than another one if their difference is positive and the lower or equal relation is trivally defined. Diff O E E' A B C denotes that C is the difference of A and B wrt. O, E and E .

Definition LtP O E E' A B := exists D, Diff O E E' B A D /\ Ps O E D. Definition LeP O E E' A B := LtP O E E' A B \/ A = B.
The lower or equal relation is then shown to be a total order compatible with the arithmetic operations.

CHAPTER I.2

Hilbert's axioms: a Theory Mutually Interpretable with Tarski's System of Geometry

In a previous work [START_REF] Braun | From Tarski to Hilbert[END_REF], Braun and Narboux have formalized in Coq the proof that Tarski's axioms for planar Euclidean geometry can serve as a model for the corresponding Hilbert's axioms. Having built a formal proof that the Cartesian plane over a Pythagorean ordered field is a model of Tarski's axioms can convince the reader that Tarski's axioms as they are formalized are consistent and hence that this formalization of Hilbert's axiom system as well. However this axiom system could be weaker than necessary. As a matter of fact, the axiom system that was proposed in 2012 was not sufficient to prove Tarski's axioms and we had to complete it. In this chapter, we present a formal proof that the formalization of Hilbert's axioms is not only correct but also sufficient, in the sense that we can obtain the culminating result of both [START_REF] Hilbert | Foundations of Geometry (Grundlagen der Geometrie[END_REF] and [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]: the arithmetization of Euclidean geometry presented in the previous chapter.

In Section 1, we describe Hilbert's axioms for plane Euclidean geometry. In doing so, we present the errors we had to correct in the previous axiomatic system to obtain the mutual interpretability of Hilbert's and Tarski's axioms for plane Euclidean geometry. Finally, in Section 2, we provide the proof that Tarski's axioms can be derived from Hilbert's axioms.

Formalization of Hilbert's Axioms

Our formalization of Hilbert's axiom system is derived from the French translation of the tenth edition annotated by Rossier [START_REF] Hilbert | Les fondements de la géométrie[END_REF]. These axioms are given in Appendix C. Hilbert's axiom system is based on two abstract types: points and lines (as we limit ourselves to two-dimensional geometry we did not introduce 'planes' and the related axioms). In the initial version of Hilbert's axioms from Braun and Narboux, several mistakes were made. None of the axioms were incorrect (as they are formally proved from Tarski's axioms), but some should be strengthened and some others are useless because they can be derived. For each group of axioms, we detail the changes we made to this previous formalization.

1.1. Group I. Group I of axioms contains the incidence axioms. First, we had to change the lower-dimensional axiom (part of Axiom I.31 in Appendix C which corresponds to lower_dim). Hilbert states that there exists three non collinear points and three points are said to be collinear if there exists a line going through these three points. This assumption is not enough, because in a world without lines, assuming that there are three non collinear points does not imply that they are distinct. Indeed, there is a model of the first two groups of Hilbert's axioms with only one point and no lines (interpreting congruence by the empty relation). We can construct a line only if we have two distinct points (Axiom I.1, formalized as line_existence, allows to construct a line given two distinct points). Scott's formalization does not need this modification because in Isabelle/HOL all types are inhabited, hence his formalization includes implicitly the fact that there is at least one line. Meikle's and Richter's formalizations enforce that the three points are distinct.

Hence, for the lower-dimension axiom, we state that there is a line and point not on this line: l0 : Line; P0 : Point; plan : ˜Incid P0 l0;

As part of Axiom I.3 (this part coincide with two_points_on_line) states that there are always at least two points on a line and Axiom I.2 (line_uniqueness) allows to derive the equality of two lines if they share two distinct points, the former axiom stating that there are three non-collinear points can be derived. Finally, as we are working in an intuitionistic setting we had to introduce some decidability properties which allow to perform case distinctions. It would be interesting to formalize a constructive version of Hilbert's axioms, following Beeson's work [START_REF] Beeson | Constructive Geometry[END_REF], we leave this for future work.

Incid_dec : forall P l, Incid P l \/ ˜Incid P l; eq_dec_pointsH : forall A B : Point, A=B \/ ˜A=B;

The complete list of axioms for group I is given in Tab. I.2.1.

Group II.

Group II of axioms contains the betweenness axioms. We denote by A B C Hilbert's betweenness predicate, which is strict. It expresses the fact that B is on the line AC between A and C and different from A and C. We could not derive the fact that if A B C then A = C from our former axioms so we added this property as the axiom between_diff. The fact that A = B and B = C (which is assumed by Greenberg, Hartshorne and Richter) is not necessary as it can be derived from the other axioms. The fact that A should be different from C is not explicit in Hilbert's book. The property between_one states that given three collinear and distinct points at least one of them is between the other two: In our earlier formalization as well as earlier editions of Hilbert's book, this property was taken as an axiom. Following the proof by Wald published by Hilbert in later editions, we derived it from the other axioms. Richter assumes this property. Moreover, in the axiom between_only_one (formalization of Axiom II.3), we removed one of the conjuncts as it can be derived from between_comm (part of Axiom II.1). We now have:

between_only_one : forall A B C, BetH A B C -> ˜BetH B C A; instead of: between_only_one : forall A B C, BetH A B C -> ˜BetH B C A /\ ˜BetH B A C;
The other axioms could be kept unmodified. We can point out that compared to the formalization from Dehlinger, Dufourd and Schreck, the non-degeneracy of the considered points in the axioms have been removed when they were redundant like in the case of between_col (part of Axiom II.1) which now only states that if a point B is between points A and C, then these three points must be collinear. Indeed, the fact that all these points are distinct can be derived from the other axioms. We can also remark that because Hilbert meant to group these axioms so that they only consider the betweenness, Axiom II.2 (here between_out) only corresponds to the part of Tarski's segment construction axiom which allows to extend a segment without specifying any congruence property about the way it is extended. Finally, this version of Pasch's axiom (Fig. I.2.1 2 ) is both stronger and weaker than Tarski's one. Since this version is only valid in a plane, it allows to prove the upper-dimensional axiom from Tarski. However, Tarski's version specifies the segment through which the line passes. The axioms for the second group are given in Tab. I.2.2. 2 Contrary to the previous chapter, we only provide the figure in the Euclidean model in this chapter. Indeed, we prove the mutual interpretability of Hilbert's and Tarski's axioms for neutral geometry.

Group III.

Group III of axioms contains those about congruence of segments and angles. 1.3.1. Congruence of Segments. Hilbert defines congruence as a relation about segments, where segments are defined as unordered pairs of points. In our formalization, we chose to avoid defining the concept of segment. Hence, we have an axiom which says that segments can be permuted on the right. We denote by AB ≡ H CD Hilbert's congruence predicate, which is strict. It expresses the fact that the non-degenerate segments AB and CD are congruent. Other permutations can be derived thanks to Axiom III.2 (cong_pseudo_transitivity). The uniqueness of segment construction can be derived if one assume the reflexivity of congruence of angles, therefore we dropped this axiom. Richter assumes uniqueness of segment construction but we only assumed its existence as Axiom III.1 (cong_existence), which correspond to the construction respecting a given congruence (Fig. I.2.2) unlike Axiom II.2. The other axioms were not changed, the full list is given on Tab. I.2.3. Our formalization of the segment addition axiom follows Hilbert's prose. It is based on the definition of the concept of disjoint segments. Note that in Axiom III.3, the segment addition axiom (Fig. I.2.3), the concept of disjoint segments could be replaced by a betweenness assumption stating that B is between A and C and B is between A and C , we proved it as lemma: In early editions of the Foundations of Geometry, Hilbert had taken pseudo-transitivity of congruence of angles as an axiom. Later Rosenthal has shown that this axiom can be derived from the others [START_REF] Rosenthal | Vereinfachungen des Hilbertschen Systems der Kongruenzaxiome[END_REF]. We used the later version of Hilbert's axioms. Note that, as we need transitivity of congruence in our proofs, we had to formalize Rosenthal's proofs. Richter also assumes the transitivity of congruence of angles. In our previous formalization, we defined the concept of angles ABC as three points A, B and C, with a proof that A = B and B = C. To avoid adding a type for angles we chose to represent angles by a triple of points: the vertex and a point on each side. To be faithful to Hilbert, some non degeneracy conditions are added to ensure that angles are neither flat nor null. This makes the proof of the Tarski's five-segment axiom A5 more involved.

Lemma addition_betH : forall A B C A' B' C', BetH A B C -> BetH A' B' C' -> CongH A B A' B' -> CongH B C B' C' -> CongH A C A' C'.
A B C A' B' C', ColH A B C -> ColH A' B' C' -> disjoint A B B C -> disjoint A' B' B' C' -> CongH A B A' B' -> CongH B C B' C' -> CongH A C A' C';
We used a predicate of arity six for the congruence of angles:

CongaH : Point -> Point -> Point -> Point -> Point -> Point -> Prop;
As for the congruence of segments we need a permutation property about angle congruence:

congaH_permlr : forall A B C D E F, CongaH A B C D E F -> CongaH C B A F E D;
Our approach does not use rays, so we need to state that two angles represented by the same rays are congruent. This is the purpose of axiom congaH_outH_congaH. The predicate outH P A B states that B belongs to the ray P A:

outH := fun P A B => BetH P A B \/ BetH P B A \/ (P <> A /\ A = B); congaH_outH_congaH : forall A B C D E F A' C' D' F', CongaH A B C D E F -> outH B A A' -> outH B C C' -> outH E D D' -> outH E F F' -> CongaH A' B C' D' E F';
Recall that Hilbert's Axiom III.4 (formalized as cong_4_existence and cong_4_uniqueness) states that states that, given an angle ∠ABC, a ray OX emanating from a point O and a point P , not on the line generated by OX, there is a unique point Y , such that the angle ∠XOY is congruent to the angle ∠ABC and such that every point inside ∠XOY and P are on the same side with respect to the line generated by OX (Fig. I.2.4). We simplified the formalization of Hilbert's Axiom III.4, instead of considering every point inside the angle, our proof shows that it is sufficient to state that the point that defines the angle is on the same side as P . Hence, we can save the burden of defining what it means for a point to be inside an angle. Our version is also simpler than Scott's one, which follows Hilbert's definition.

We say that two points are on the same side of a line, if there is a point P such that they are both on opposite sides wrt. P . The fact that two points are on opposite sides of a line is defined by the cut predicate of Group II.

hcong_4_existence : forall A B C O X P, ˜ColH P O X -> ˜ColH A B C -> exists Y, CongaH A B C X O Y /\ same_side' P Y O X; hcong_4_uniqueness : forall A B C O P X Y Y', ˜ColH P O X -> ˜ColH A B C -> CongaH A B C X O Y -> CongaH A B C X O Y' -> same_side' P Y O X -> same_side' P Y' O X -> outH O Y Y'
We can point out that Axiom III.5 does not strictly correspond to the well-known Side-Angle-Side postulate. Indeed, it only allows to prove that the remaining pairs of angles are equal and not that the remaining pair of sides are equal. This can however be derived. The full list of axioms is given in Tab. I.2.4.

Group IV.

Group IV of axioms contains a single axiom (Axiom IV.1) about parallelism known as Playfair's postulate asserting the uniqueness of the parallel. It asserts that given a line l and a point P non-incident to l, if two lines are parallel to l and incident to P , then, they must be equal. In 2012, Braun and Narboux had an axiom saying that given a line and a point there exists a unique parallel line through this point. Nevertheless, only Playfair's postulate (the uniqueness but not the existence) needs to be assumed as the existence can be derived from other axioms.

Playfair's postulate is depicted on Tab. I.2.5. However, as explained in the next chapter, we see that if one would assume Playfair's postulate as our parallel axiom, the decidability of the intersection of lines would be required to obtain the arithmetization of Tarski's system of geometry as Descartes defined it. Therefore we added this axiom in order to be able to complete the proof that Tarski's axioms can be derived from Hilbert's axioms.

This axiom is given on Tab. I.2.6.

1.5. Group V. Group V of axioms contains the continuity axioms. These axioms being not necessary to obtain the arithmetization of geometry we did not formalize them. As a matter of fact, not only the arithmetization of geometry can be achieved without continuity axioms. Without them, Hilbert developed a theory of plane areas [START_REF] Hilbert | Foundations of Geometry (Grundlagen der Geometrie[END_REF] and, we see in the next part that angle arithmetic can also be performed. Moreover, while establishing the mutual interpretability of Archimedean Euclidean Hilbert Planes, i.e. Euclidean Hilbert Planes in which Archimedes' axiom (Axiom V.1) Table I.2.6. Formalization of the axiom of decidability of the intersection of lines holds, and Tarski A1-A10 plus Archimedes' axiom (Axiom 2) would be possible, the same cannot be said of Hilbert's five groups of axioms and Tarski A1-A11'. Indeed, the axiom of line completeness is a second-order statement while Tarski A11' is a first-order statement.

CongaH : Point -> Point -> Point -> Point -> Point -> Point -> Prop; conga_refl : forall A B C, ˜ColH A B C -> CongaH A B C A B C; conga_comm : forall A B C, ˜ColH A B C -> CongaH A B C C B A; congaH_permlr : forall A B C D E F, CongaH A B C D E F -> CongaH C B A F E D; same_side := fun A B l => exists P, cut l A P /\ cut l B P; same_side' := fun A B X Y => X <> Y /\ forall l, Incid X l -> Incid Y l -> same_side A B l; congaH_outH_congaH : forall A B C D E F A' C' D' F', CongaH A B C D E F -> outH B A A' -> outH B C C' -> outH E D D' -> outH E F F' -> CongaH A' B C' D' E F'; cong_4_existence : forall A B C O X P, ˜ColH P O X -> ˜ColH A B C -> exists Y, CongaH A B C X O Y /\ same_side' P Y O X; cong_4_uniqueness : forall A B C O P X Y Y', ˜ColH P O X -> ˜ColH A B C -> CongaH A B C X O Y -> CongaH A B C X O Y' -> same_side' P Y O X -> same_side' P Y' O X -> outH O Y Y'; cong_5 : forall A B C A' B' C', ˜ColH A B C -> ˜ColH A' B' C' -> CongH A B A' B' -> CongH A C A' C' -> CongaH B A C B' A' C' -> CongaH A B C A' B' C'

Proving that Tarski's Axioms follow from Hilbert's

To prove Tarski's axioms we use the axioms of the variant axiomatic system V introduced in Chapter I.1, Subsection 1.3 and we treat the case of neutral geometry separately from the parallel postulate (Fig. I.2.5). In fact, axiom A14 is also an axiom in Hilbert's system and axiom A15 can be easily deduced from Hilbert's first lemma. Moreover, since Hilbert's betweenness is strict, part of the modifications that we made to axioms A7 and A10 were to restrict the hypotheses to the case of strict betweenness, thus making them easier to prove using Hilbert's axioms.

A Hilbert

Plane is mutually interpretable with Tarski A1-A9. Here, we prove that V follows from Hilbert's axioms. Hilbert's betweenness relation is strict, whereas Tarski's one is not. Obviously, we defined Tarski's betweenness relation (Bet) from Hilbert's one (BetH) as: Axioms A1, A2, A3, A4, A8 and A14 are already axioms in Hilbert or easy consequences of the axioms. A15 is a theorem in Hilbert which can be proved easily. Tarski's version of Pasch's axiom is stronger than Hilbert's one, because it provides information about the relative position of the points. We could recover the non-degenerate case of Tarski's version of Pasch A7' using some betweenness properties and repeated applications of Hilbert's version of Pasch. The five-segment axiom requires a longer proof. The non-degenerate case is a trivial consequence of the Side-Side-Side and Side-Angle-Side theorems and the fact that if two angles are congruent their supplements are congruent as well. Those theorems are proved by Hilbert as Theorems 18, 12 and 14 (Fig. I.2.6 and I.2.7). To prove these two theorems we had to formalize the proof of Hilbert's Theorems 12, 15, 16 and 17 as well. Hilbert's proofs can be formalized without serious problem; we only had to introduce some lemmas about the relative position of two points and a line. For example, we had to prove that the same-side relation is transitive: if A and B are of the same side of l, and B and C are on the same side of l then A and C are also on the same side of l. As already noticed by Meikle and Scott, these lemmas, which are as difficult to prove as Hilbert's other theorems are completely implicit in Hilbert's prose. The non-obvious part of the proof has been the degenerate case of the five-segment axiom and the upper two-dimensional axiom A9.

Definition Bet A B C := BetH A B C \/ A = B \/ B = C.
Let us first collect the three theorems from Hilbert's book that are used in the rest of this subsection. 3 Lemma 1 (Theorem 12). Lemma 2 (Theorem 14).

¬ Col A B C ∧ ¬ Col A B C ∧ AB ≡ H A B ∧ AC ≡ H A C ∧ B A C = B A C ⇒ A B C = A B C ∧ A C B = A C B ∧ BC ≡ H B C .
¬ Col A B C ∧ ¬ Col A B C ∧ A B C = A B C ∧ A B D ∧ A B D ⇒ C B D = C B D .
Lemma 3 (Theorem 18).

¬ Col A B C ∧ ¬ Col A B C ∧ AB ≡ H A B ∧ AC ≡ H A C ∧ BC ≡ H B C ⇒ B A C = B A C ∧ A B C = A B C ∧ A C B = A C B .
To prove the degenerate case of the five-segment axiom (when the point D belongs to the line AB), we had to prove that then D also belongs to line A B . We also had to prove many degenerate cases which reduce to segment addition and subtraction. Segment subtraction can be deduced from uniqueness of segment construction and from addition. We give here only the proof of the key lemma (Lemma 5 below), assuming the following lemma: The last axiom we need to prove is the upper two-dimensional axiom. The proof is not completely straightforward because we do not assume decidability of intersection of lines: we can not distinguish cases to know if two lines intersect or not.

Lemma 4. A B C ∧ A B C ∧ AC ≡ H A C ∧ AB ≡ H A B ⇒ A B C . Lemma 5. A B C ∧ AB ≡ H A B ∧ BC ≡ H B C ∧ AC ≡ H A C ⇒ Col A B C .
Let us first prove two useful lemmas. In order to prove Lemma 8 we first prove a particular case which is used repeatedly throughout this proof. Lemma 7. If three distinct points A, B and C are equidistant from two different points P and Q, then, assuming that A is collinear with P and Q, these points are collinear.

Proof. We know that neither B or C are collinear with P and Q because if they were then they would be equal to A, thus obtaining a contradiction. Therefore, using the previous lemma, either B and C are on opposite sides or on the same side of line P Q.

• If they are on opposite sides of line P Q, then we name I the point of intersection between this line and the segment BC. If we can prove that A is equal to point I we will be done.

To do this we just have to prove that I is equidistant from P and Q. Using Hilbert's Theorem 18, we know that the angles P AB and QAB are equal. Then Hilbert's Theorem 12 lets us prove that I is equidistant from P and Q. • If they are on the same side of line P Q, the previous lemma states that either P and Q are on opposite sides or on the same side of line BC.

-If they are on the same side, the uniqueness axioms let us prove that they are equal, therefore obtaining a contradiction. -If they are on opposite side, then we name I the point of intersection between this line and the line P Q. Without loss of generality, let us consider that B is between C and I (if they are equal then A, B and C are trivially collinear). Using Hilbert's Theorems 14 and 18, we know that the angles P BI and QBI are equal. Then Hilbert's Theorem 12 let us prove that I is equidistant from P and Q. Therefore A is equal to I and we are done.

Lemma 8. If three distinct points A, B and C are equidistant from two different points P and Q, then these points are collinear.

Proof. We just have to consider the case where neither A, B or C are collinear with P and Q since otherwise the previous lemma lets us conclude. We know that either at least two of these points are on opposite sides of the line P Q or all the points are one the same side of this line.

• If they are on opposite sides of line P Q, then we name I the point of intersection between this line and the segment formed by the points which are on opposite sides of this line. As in the previous lemma we can prove that I is equidistant from P and Q. Then apply the previous lemma twice we know that A, B and I as well as A, C and I are collinear and the transitivity of collinearity allows us conclude.

• If they are on the same side of line P Q, either P and Q are on opposite sides or on the same side of line AB.

-If they are on the same side, the uniqueness axioms let us prove that they are equal, therefore obtaining a contradiction. -If they are on opposite side, then we name I the point of intersection between this line and the line P Q. As in the previous lemma we can prove that I is equidistant from P and Q. Then apply the previous lemma twice we know that A, B and I as well as A, C and I are collinear and the transitivity of collinearity allows us conclude.

This last lemma assert allows to obtain a result very similar to an equivalence proved by Pambuccian [Pam11]: Hilbert's version of Pasch's axiom is stronger than Tarski's version in the sense that it allows to prove Tarski's upper two-dimensional axiom.

Putting everything together, we could prove that Tarski's axioms for neutral geometry follow from Hilbert's:

Global Instance H2D_to_T2D : Tarski_2D H_to_T_PED.

Combined with the results from Braun and Narboux, it allows to establish the equivalence between Hilbert's and Tarski's axioms for neutral geometry.

A Euclidean Hilbert

Plane is mutually interpretable with Tarski A1-A10. The fact that Playfair's postulate can be derived from Tarski's version of the postulate appears in Chapter 12 of [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF], that we have formalized previously. The reverse implication and many other equivalence results are described in the next part. For this implication, we have to assume the decidability of intersection of lines: given two lines either they intersect or they do not. This completes the proof that Tarski's axioms can be derived from Hilbert's axioms:

Global Instance H_euclidean_to_T_euclidean : Tarski_euclidean H_to_T_PED.

Thus, this establishes the equivalence between these two axiomatic systems thanks to the previous results from Braun and Narboux.

CHAPTER I.3

Metatheorems about Tarski's System of Geometry

Metamathematics has occupied a prominent place in Hilbert's and Tarski's developments. In fact, Hilbert dedicates a chapter of his book to the satisfiability of his axiomatic system and to various independence results [START_REF] Hilbert | Foundations of Geometry (Grundlagen der Geometrie[END_REF] while half of the book exposing results about Tarski's axioms [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] concerns metamethematical results. In both books, the question of the independence of Euclid's parallel postulate is addressed. Both times it is demonstrated by providing independence models. In this chapter we present a new proof that Euclid's parallel postulate is not derivable from the remaining axioms of Tarski's system of geometry. This proof uses a very old and basic theorem of logic together with some simple properties of ruler-and-compass constructions to give a short, simple, and intuitively appealing proof. Similarly to other approaches, this proof is performed without constructing a model of non-Euclidean geometry [START_REF] Skolem | Logisch-kombinatorische Untersuchungen über die Erfüllbarkeit mathematischer Satzsysteme, nebst einem Theoreme über dichte Mengen[END_REF][START_REF] Cole | Introduction to Metamathematics[END_REF][START_REF] Von | Terminating Proof Search in Elementary Geometry[END_REF]. We remark that this proof also allows to show the independence of the decidability of intersection of lines. Following this remark, we study some decidability properties in the context of Tarski's system of geometry by removing the excluded middle from our assumptions. We prove that decidability of point equality is equivalent to the decidability of the two predicates given in the theory: congruence and betweenness. We also expose that the decidability of the other predicates used in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] can be derived from the decidability of point equality in Tarski's system of geometry without continuity axioms.

In Section 1, we present our proof of the independence of Euclid's parallel postulate. Then, in Section 2, we detail our results on decidability properties in the context of Tarski's system of geometry.

Independence of Euclid's Parallel Postulate via Herbrand's Theorem

We recall that some of the Tarski's axioms assert the existence of "new" points that are constructed from other "given" points in various ways. For example, one axiom says that segment AB can be extended past B to a point E, lying on the line determined by AB, such that segment BE is congruent to a given segment CD. That axiom can be written formally, using the logician's symbol ∧ for "and", as

∃E, A B E ∧ BE ≡ CD.
It is possible to replace the quantifier ∃ with a "function symbol". To improve the readability of the formulas in this section, we avoid the use of the notations A B C, A B C and AB ≡ H CD and we replace them with B (A, B, C), T (A, B, C) and E (A, B, C, D) respectively. We denote the point E that is asserted to exist by ext (A, B, C, D). Then the axiom looks like

T (A, B, ext (A, B, C, D)) ∧ E (B, ext (A, B, C, D), C, D) .
This transformation is called Skolemization. This form is called "quantifier-free", because ∃ and ∀ are called "quantifiers", and we have eliminated the quantifiers. Although the meaning of the axioms is the same as if it had ∀A, B, C, D in front, the ∃ has been replaced by a function symbol. When a theory has function symbols, then they can be combined. For example,

ext (A, B, ext (E, F, C, D), ext (A, B, C, D))
is a term. The definition of "term" is given inductively: variables are terms, constants are terms, and if one substitutes terms in the argument places of function symbols, one gets another term. In Tarski's axiomatization of geometry, there are only a few axioms that are not already quantifier-free. One of them is the segment construction axiom already discussed. Another is Pasch's axiom. A quantifier-free version of Tarski's axioms will contain a function symbol for the point asserted to exist by (a version of) Pasch's axiom.

Another axiom in Tarski's theory asserts the existence of an intersection point of a circle and a line, provided the line has a point inside and a point outside the circle. Another function symbol can be introduced for that point. Then the terms of this theory correspond to certain ruler-and-compass constructions. The number of symbols in such a term corresponds to the number of "steps" required with ruler and compass to construct the point defined by the term.

The starting point for the work reported here is this: a quantifier-free theory of geometry, whose terms correspond to ruler-and-compass constructions, viewed as a special case of situation of much greater generality: some first-order, quantifier-free theory. Herbrand's theorem applies in this much greater generality, and we simply investigate what it says when specialized to geometry.

1.1. Herbrand's Theorem. Herbrand's theorem is a general logical theorem about any axiom system whatsoever that is • first-order, i.e. has variables for some kind(s) of objects, but not for sets of those objects, and • quantifier-free, i.e. ∃ has been replaced by function symbols. Herbrand's theorem says that under these assumptions, if the theory proves an existential theorem ∃y φ(a, y), with φ quantifier-free, then there exist finitely many terms t 1 , . . . , t n such that the theory proves φ(a, t 1 (a)) ∨ φ(a, t 2 (a)) . . . ∨ . . . φ(a, t n (a)). The formula φ can, of course, have more variables that are not explicitly shown here, and a and x can each be several variables instead of just one, in which case the t i stand for corresponding lists of terms. For a proof see [START_REF] Buss | Introduction to Proof Theory[END_REF], p. 48.

In order to illustrate the theorem, consider the example when φ is φ(A, B, C, X, Y ), and it says that A = B, and X lies on the line determined by AB, and Y does not lie on that line, and XY is perpendicular to AB and C is between X and Y . Collinearity can be expressed using betweenness, and the relation XY ⊥ AB can also be expressed using betweenness and equidistance. Then ∃X, Y φ(X, Y ) says that there exists a line through point C perpendicular to AB. Usually in geometry, we give two different constructions for such a line, according as C lies on line AB or not. If it does, we "erect" a perpendicular at C, and if it does not, we "drop" a perpendicular from C to line AB. When we "drop" ' a perpendicular, we compute foot 1 (A, B, C), and we can define head 1 (A, B, C) = C. When we "erect" a perpendicular, we compute head 2 (A, B, C), and we can define foot 2 (A, B, C) = C. Thus if C is not on the line, we have φ(A, B, C, foot 1 (A, B, C), head 1 (A, B, C)), and if C is on the line, we have

φ(A, B, C, foot 2 (A, B, C), head 2 (A, B, C).
Since C either is or is not on the line we have

φ(A, B, C, foot 1 (A, B, C), head 1 (A, B, C)) ∨ φ(A, B, C, foot 2 (A, B, C), head 2 (A, B, C).
Comparing this to Herbrand's theorem, we see that we have specifically constructed examples of two lists (of two terms each) t 1 and t 2 illustrating that Herbrand's theorem holds in this case. Herbrand's theorem, however, tells us without doing any geometry that if there is any proof at all of the existence of a perpendicular to AB through C, from the axioms of geometry mentioned above, then there must be a finite number of ruler-and-compass constructions such that, for every given A, B and C, one of those constructions works. We have verified, using geometry, that we can take the "finite number" of constructions to be 2 in this case, but the beauty of Herbrand's theorem lies in its generality.

Non-Euclidean Geometry.

Euclid listed five axioms or postulates, from which, along with his "common notions", he intended to derive all his theorems. The fifth postulate, known as "Euclid 5", had to do with parallel lines, and is also known as the "parallel postulate". See m and l must meet on the right side, provided B (Q, U, R) and P Q makes alternate interior angles equal with k and l.

From antiquity, mathematicians felt that Euclid 5 was less "obviously true" than the other axioms, and they attempted to derive it from the other axioms. Many false "proofs" were discovered and published. All this time, mathematicians felt that geometry was "about" some true notion of space, which was either given by the physical space in which we live, or perhaps by the nature of the human mind itself. Finally, after constructing long chains of reasoning from the assumption that the parallel postulate is false, some people came to the realization that there could be "models of the axioms" in which "lines" are interpreted as certain curves, and "distances" also have an unusual interpretation. Such models were constructed in which Euclid 5 is false, but the other axioms are true. Hence, Euclid 5 can never be proved from the other axioms. There was a good reason for all those failures! See [START_REF] Jay | Euclidean and Non-Euclidean Geometries -Development and History[END_REF] and [START_REF] Hartshorne | Geometry : Euclid and beyond[END_REF] for the full history of these fascinating developments, and descriptions of the models in question.

Tarski's Axioms for Geometry.

In order to state our theorem precisely, we need to mention a specific axiomatization of geometry. For the sake of definiteness, we use the axioms A1-A11 of Tarski. We list those axioms1 in Tab. I.3.1 with the notations used for this section.

A1

Symmetry

E (A, B, B, A) A2 Pseudo-Transitivity E (A, B, C, D) ∧ E (A, B, E, F ) ⇒ E (C, D, E, F ) A3 Cong Identity E (A, B, C, C) ⇒ A = B A4 Segment construction ∃E, T (A, B, E) ∧ E (B, E, C, D) A5 Five-segment E (A, B, A , B ) ∧ E (B, C, B , C ) ∧ E (A, D, A , D ) ∧ E (B, D, B , D ) ∧ T (A, B, C) ∧ T (A , B , C ) ∧ A = B ⇒ E (C, D, C , D ) A6 Between Identity T (A, B, A) ⇒ A = B A7 Inner Pasch T (A, P, C) ∧ T (B, Q, C) ⇒ ∃X, T (P, X, B) ∧ T (Q, X, A) A8 Lower Dimension ∃ABC, ¬ T (A, B, C) ∧ ¬ T (B, C, A) ∧ ¬ T (C, A, B) A9 Upper Dimension E (A, P, A, Q) ∧ E (B, P, B, Q) ∧ E (C, P, C, Q) ∧ P = Q ⇒ T (A, B, C) ∨ T (B, C, A) ∨ T (C, A, B) A10 Euclid T (A, D, T ) ∧ T (B, D, C) ∧ A = D ⇒ ∃XY, T (A, B, X) ∧ T (A, C, Y ) ∧ T (X, T, Y ) A11 Continuity ∀ΞΥ, (∃A, (∀XY, Ξ(X) ∧ Υ(Y ) ⇒ T (A, X, Y ))) ⇒ ∃B, (∀XY, Ξ(X) ∧ Υ(Y ) ⇒ T (X, B, Y )) CA Circle axiom T (A, X, B) ∧ T (A, B, Y ) ∧ E (A, X, A, P ) ∧ E (A, Q, A, Y ) ⇒ ∃Z, E (A, Z, A, B) ∧ T (P, Z, Q) Table I.3.1. Tarski's axioms for geometry.
Of these axioms, we need concern ourselves in detail only with those few that are not already quantifier-free. Axiom A4 is the segment construction axiom discussed above; we introduce the symbol ext (A, B, P, Q) to express it in quantifier-free form. The lower-dimension axiom A8 states that there exists three non-collinear points. We introduce three constants P 1 , P 2 , and P 3 to express it in quantifier-free form. The two modified axioms are explicitly (in Tab. I.3.2):

A4' Segment construction T (A, B, ext (A, B, C, D)) ∧ E (B, ext (A, B, C, D), C, D) A8'
Lower Dimension ¬ T (P 1 , P 2 , P 3 ) ∧ ¬ T (P 2 , P 3 , P 1 ) ∧ ¬ T (P 3 , P 1 , P 2 ) Table I.3.2. Axioms A4 and A8 in quantifier-free form.

1.3.1. Pasch's Axiom. Pasch [START_REF] Pasch | Vorlesung über Neuere Geometrie[END_REF] (see also [START_REF] Pasch | Vorlesung über Neuere Geometrie[END_REF], with an historical appendix by Dehn) supplied (in 1882) an axiom that repaired many of the defects that nineteenth-century rigor found in Euclid. Roughly, a line that enters a triangle must exit that triangle. As Pasch formulated it, it is not in ∀∃ form. There are two ∀∃ versions. These formulations of Pasch's axiom go back to Veblen [START_REF] Veblen | A System of Axioms for Geometry[END_REF], who proved outer Pasch implies inner Pasch. Tarski originally took outer Pasch as an axiom. In [START_REF] Narayan | Contributions to the Axiomatic Foundations of Geometry[END_REF], Gupta proved both that inner Pasch implies outer Pasch, and that outer Pasch implies inner Pasch, using the other axioms of the 1959 system. In the final version [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF], inner Pasch is an axiom. Here are the precise statements of the axioms (in Tab. I.3.3):

A7 Inner Pasch T (A, P, C) ∧ T (B, Q, C) ⇒ ∃X, T (P, X, B) ∧ T (Q, X, A) Outer Pasch T (A, P, C) ∧ T (Q, C, B) ⇒ ∃X, T (A, X, Q) ∧ T (B, P, X) Table I.3.3.
Inner and outer form of Pasch's axiom.

In order to express inner Pasch in quantifier-free form, we introduce the symbol ip (A, P, C, B, Q) for the point X asserted to exist. This corresponds to the ruler-and-compass (actually just ruler) construction of finding the intersection point of lines AQ and P B. There is a codicil to that remark, in that Tarski's axiom allows the degenerate case in which the segments AQ and P B both lie on one line (so that there are many intersection points, rather than a unique one), but we do not care in this section that in such a case the construction cannot really be carried out with ruler and compass. Also, we call the reader's attention to this fact: point C is not needed to draw the lines with a ruler, but it is needed to "witness" that the lines actually "should" intersect. 1.3.2. Continuity and the Circle Axiom. Axiom A11 is the "continuity" axiom. In its full generality, it says that "first-order Dedekind cuts are filled". Closely related to axiom A11 is the "circle axiom" CA, which says that if P lies inside the circle with center A and passing through B, and Q lies outside that circle, then segment P Q meets the circle (see Fig.

I.3.2). 2 A X B Y Q Z P A B X Y Z Q P Figure I.3.2. Circle Axiom CA. Point P is inside, Q is outside, so P Q meets the circle.
Points X and Y in the figure serve as "witnesses" that P and Q are inside and outside, respectively. Specifically, " 'P lies inside the circle" means that AP < AB, which in turn means that there is a point X between A and B such that E (A, X, A, P ), i.e. segment AX is congruent to AP . Similarly, "Q lies outside the circle" means there exists Y with B (A, B, Y ) and E (A, Q, A, Y ). In order to express segment-circle continuity in quantifier-free form, we can introduce a symbol i c (P, Q, A, B, X, Y ) for the point of intersection of P Q with the circle. Even though X and Y are not needed for the ruler-and-compass construction of this point, they must be included as parameters of i c.

We return below to the general axiom A11, but first we show how to finish the proof of our main theorem if only the circle axiom is used, instead of the full schema A11.

1.3.3. The Parallel Axiom. Tarski used a variant formulation for axiom A10 of Euclid 5, illustrated in Fig. II.1.9. One can prove the equivalence between axiom A10 and Euclid 5, 3 and axiom A10 has the advantage of being very simply expressed in a points-only language. Open circles indicate the two points asserted to exist. For our independence proof, we work with Tarski's axiom A10 rather than with Euclid 5. Nevertheless, we include a formulation of Euclid's parallel postulate (in Tab. I.3.4), expressed in Tarski's language (Fig.

II.3.5). Euclid's version mentions angles, and the concept of "corresponding interior angles" made by a transversal.

2 There is no "standard" name for this axiom. Tarski did not give the this axiom a name, only a number; in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] and other German works it is called the "Kreisaxiom", which we translate literally here. In [START_REF] Narayan | Contributions to the Axiomatic Foundations of Geometry[END_REF] it is called the "line and circle intersection axiom", which we find too long. In [START_REF] Jay | Euclidean and Non-Euclidean Geometries -Development and History[END_REF] (p. 131) it is called the "segment-circle continuity principle". 3 We actually do so in the next part.

Euclid 5

B (P, T, Q) ∧ B (R, T, S) ∧ B (Q, U, R) ∧ ¬(T (P, Q, S) ∨ T (Q, S, P ) ∨ T (S, P, Q))∧ E (P, T, Q, T ) ∧ E (R, T, S, T ) ⇒ ∃I, B (S, Q, I) ∧ T (P, U, I) Table I.3.4. A formulation of Euclid 5 expressed in Tarski's language.
1.4. Consistency of non-Euclidean Geometry via Herbrand's Theorem. The point of this subsection is to show that one can use the very general theorem of Herbrand to prove the consistency of non-Euclidean geometry, doing extremely little actual geometry. All the geometry required is the observation that when we construct points from some given points, at each construction stage the maximum distance between the points at most doubles.

In order to state our theorem precisely, we define T to be Tarski's "neutral ruler-and-compass geometry", where "neutral" means that the parallel axiom A10 (equivalent to Euclid 5) is not included, and "ruler-and-compass" means that axiom A11 is replaced by the circle axiom CA. In addition, T uses the quantifier-free versions of the segment-extension and dimension axioms discussed above. The following lemma states precisely what we mean by, "at each construction state the maximum distance between the points at most doubles". Lemma 9. The function symbols of T have the following property, when interpreted in the Euclidean plane R 2 : if f is one of those function symbols, i.e. f is ext or i c or ip, then the distance of f (X 1 , . . . , X j ) from any of the parameters X 1 , . . . X j is bounded by twice the maximum distance between the X j .

Proof. When we extend a segment AB by a distance P Q, the distance of the new point ext (A, B, P, Q) from the points A, B, P and Q is at most twice the maximum of AB and P Q. The point constructed by ip is between some already-constructed points, so ip does not increase the distance at all. The point constructed by i c is no farther from the center A of the circle than the given point B on the circle is, and hence no more than AB farther from any of the other points, and hence no more than twice as far from any of the other parameters of i c as the maximum distance between those points.

Theorem 1. Let T be Tarski's "neutral ruler-and-compass geometry", where "neutral" means that the parallel axiom A10 (equivalent to Euclid 5) is not included, and "ruler-and-compass" means that axiom A11 is replaced by the "circle axiom" CA. Then T does not prove the parallel axiom A10.

Proof. Suppose, for proof by contradiction, that T does prove axiom A10. There is a formula φ(A, B, C, D, T, X, Y ) such that axiom A10 has the form

∃X, Y, φ(A, B, C, D, T, X, Y ),
where φ expresses the betweenness relations shown in the figure. Then, by Herbrand's theorem, there are finitely many terms

X i (A, B, C, D, T ) and Y i (A, B, C, D, T ), for i = 1, 2, . . . , n, such that T proves n i=1 φ(A, B, C, D, T, X i (A, B, C, D, T ), Y i (A, B, C, D, T )).
Let k be an integer greater than the maximum number of function symbols in any of those 2n terms. Choose points A, B, C, D and T in the ordinary plane R 2 as follows (see Fig.

I.3.3). T = (0, 0) A = (0, 1) B = (-1, 1 -2 -k-2 ) C = (1, 1 -2 -k-2 ) D = (0, 1 -2 -k-2 )
Suppose X and Y are as in axiom A10; then one of them has a nonnegative second coordinate, and the other one must have a first coordinate of magnitude at least 2 k+2 . But then, according to the lemma, it cannot be the value of one of the terms X i (A, B, C, D, T ) or Y i (A, B, C, D, T ), which, since they involve k symbols starting with points no more than distance 2 apart, cannot be more than 2 k+1 from any of the starting points. This contradiction completes the proof. 1.5. Full First-Order Continuity. In this subsection we show how to extend the above proof to include the full (first-order) continuity axiom A11 instead of just the circle axiom. The difficulty is that axiom A11 is far from quantifier-free, but instead is an axiom schema. That means, it is actually an infinite number of axioms, one for each pair of first-order formulas (Ξ, Υ). The axiom says, if the points satisfying Ξ all lie on a line to the left of the points satisfying Υ, then there exists a point B non-strictly between any pair of points (X, Y ) such that Ξ(X) and Υ(Y ).

The keys to extending our proof are Tarski's deep theorem on quantifier-elimination for algebra, and the work of Descartes and Hilbert on defining arithmetic in geometry. Modulo these results, which in themselves have nothing to do with non-Euclidean geometry, the proof extends easily to cover full continuity, as we shall see.

A real-closed field is an ordered field F in which every polynomial of odd degree has a root, and every positive element has a square root. 4 Tarski proved in [START_REF] Tarski | A Decision Method for Elementary Algebra and Geometry[END_REF] the following fundamental facts:

• Every formula in Tarski's language is provably equivalent to a quantifier-free formula.

• Every model of Tarski's axioms has the form F 2 , where F is a real-closed field, and betweenness and equidistance are interpreted as you would expect.

Since Descartes and Hilbert showed how to give geometric definitions of addition, multiplication, and square root, there are formulas in Tarski's language defining the operations of multiplying and adding points on a fixed line L, with points 0 and 1 arbitrarily chosen on L, and taking square roots of points to the right of 0 (see the previous chapter). Since the existence of square roots follows from the circle axiom, the full continuity schema is equivalent to the schema that expresses that polynomials of odd degree have zeroes:

(1) ∃x (a 0 + a 1 x + . . . + a n-1 x n-1 + x n = 0).

Note that without loss of generality the leading coefficient can be taken to be 1. Here the algebraic notation is an abbreviation for geometric formulas in Tarski's language. The displayed formula represents one geometric formula for each fixed odd integer n, so it still represents an infinite number of axioms, but Herbrand's theorem applies even if there are an infinite number of axioms. The essential point is that this axiom schemata is purely existential, so we can make it quantifier-free by introducing a single new function symbol f (a 0 , . . . , a n-1 ) for a root of the polynomial.

Theorem 2. Axioms A1-A9 and axiom schema A11 together do not prove the parallel axiom A10.

Proof. Suppose, for proof by contradiction, that axiom A10 is provable from axioms A1-A9 and A11. Then, the models of axioms A1-A9 and A11 are all isomorphic to planes over real-closed fields. Then, as explained above, the full schema A11 is equivalent (in the presence of axioms A1-A10) to the schema (1) plus the circle axiom. 5That is, it suffices to supplement ruler-and-compass constructions by the ability to take a root of an arbitrary polynomial. The point that allows our proof to work is simply that the roots of polynomials can be bounded in terms of their coefficients. For example, the well-known "Cauchy bound" says that any root is bounded by the maximum of 1 + |a i | for i = 0, 1, . . . n -1, which is at most 1 more than the max of the parameters of f (a 0 , . . . , a n-1 ). Below we give, for completeness, a short proof of the Cauchy bound, but first, we finish the proof of the theorem.

We can then modify Theorem 9 to say that the distance is at most the max of 1 and double the previous distance. In the application we start with points that are 1 apart, so the previous argument applies without change. That completes the proof.

Lemma 10 (Cauchy bound). The real roots of a 0 + a 1 x + . . . + a n-1 x n-1 + x n are bounded by the maximum of 1 + |a i |.

Proof. Suppose x is a root. If |x| ≤ 1 then x is bounded, hence we may assume |x| > 1. Let h be the max of the |a i |. Then

-x n = n-1 i=0 a i x i , so |x| n ≤ h n-1 i=0 |x| i = h |x| n -1 |x| -1 . Since |x| > 1 we have |x| -1 ≤ h |x| n -1 |x| n ≤ h.
Therefore |x| ≤ 1 + h. That completes the proof.

1.6. Another Proof via a Model of Dehn's. Dehn, a student of Hilbert, gave a model of axioms A1-A9 plus the circle axiom. Dehn's model is easily described and, like our proof, has no direct relationship to non-Euclidean geometry.

An element x in an ordered field F is called finitely bounded if it is less than some integer n, where we identify n with n k=1 1. F is Archimedean if every element is finitely bounded. It is a simple exercise to construct a non-Archimedean Euclidean field, or even a non-Archimedean realclosed field. (For details about Dehn's model, see Example 18.4.3 and Exercise 18.4 of [START_REF] Hartshorne | Geometry : Euclid and beyond[END_REF].) Dehn's model begins with a non-Archimedean Euclidean field F. Then the set R of finitely bounded elements of F is a Euclidean ring, but not a Euclidean field: there are elements t such that 1/t is not finitely bounded. These are called "infinitesimals". Dehn's point was that R 2 still satisfies the axioms of "Hilbert planes", which are mutually interpretable with (after [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]) axioms A1-A9. The reason is similar to the reason that our Herbrand's-theorem proof works: the constructions given by segment extension and Pasch's axiom can at most double the size of the configuration of constructed points, so they lead from finitely bounded points to other finitely bounded points. Since square roots of finitely bounded elements are also finitely bounded, R 2 satisfies the circle axiom too. But R 2 does not satisfy the parallel axiom, since there are lines with infinitesimal slope through (0, 1) that do not meet the x-axis of R. (They meet the x-axis of F, but not at a finitely bounded point.)

In this way Dehn showed that (the Hilbert-style equivalent of) axioms A1-A9, together with the circle axiom, does not imply the parallel postulate A10. We add to Dehn's proof the extension to the full first-order continuity schema A11, by the same trick as we used for our Herbrand's-theorem proof. Namely, suppose for proof by contradiction that axiom A10 is provable from axioms A1-A9 and A11. Then in axioms A1-A9 plus segment-circle continuity, axiom A11 is equivalent to the schema (1) saying that odd-degree polynomials have roots. Now construct Dehn's model starting from a non-Archimedean real-closed field F. Then R still satisfies (1), because of the Cauchy bound: if the coefficients a i are finitely bounded, so are the roots of the polynomial. But then R 2 satisfies axiom A11, and hence, according to our assumption, it satisfies axiom A10 as well; but we have seen that it does not satisfy A10, so we have reached a contradiction. That contradiction shows that A10 is not provable from axioms A1-A9 and A11.

Note that this proof, like the proof via Herbrand's theorem, does not actually construct a model of non-Euclidean geometry, that is, a model satisfying axioms A1-A9, A11, but not axiom A10. That is the interest of both proofs: the consistency of non-Euclidean geometry is shown, in the one case by proof theory, and the other by algebra (or model theory if you prefer to call it that), without doing any non-Euclidean geometry at all. Moreover, the classical constructions of models of non-Euclidean geometry (the Beltrami-Klein and Poincaré models described in [START_REF] Jay | Euclidean and Non-Euclidean Geometries -Development and History[END_REF], Ch. 7), satisfy not only the first-order continuity schema but also the full second-order continuity axioms. Herbrand's theorem is about first-order logic, so it cannot replace these classical geometrical constructions; but still, we have shown here that a little logic goes a long ways.

Towards the Decidability of Every First-Order Formula

We can start by remarking that the decidability of the intersection of lines allows us to construct arbitrary far away points (in the case where the lines intersect). Thus, by dropping the law of excluded middle, the proof of Theorem 1 can be modified in order to prove the independence of the decidability of the intersection of lines from the axioms of Tarski's system of geometry without parallel and continuity axioms. It suffices to choose points A, B, C and D (the decidibility of intersection concerns the lines AB and CD) in the ordinary plane R 2 as follows A = (0, 1)

B = (1, 1 -2 -k-2 ) C = (0, 0) D = (1, 0)
to construct a point too far away leading to the contradiction needed to prove the independence result. By assuming another version of the parallel postulate, namely Playfair's postulate (presented as Postulate 2 in the next part), we still would not be able to construct the intersection point. The parallel projection, needed to define the arithmetic operations, is a construction based on the fact that one can construct the intersection of any two given non-parallel lines. Therefore, if one would assume Playfair's postulate as our parallel axiom, the decidability of the intersection of lines would be required to obtain the arithmetization of Tarski's system of geometry as presented by Descartes. This illustrates that some decidability properties might be needed to complete the formalization described in Chapter I.1, Section 3. It motivated us to study decidability properties in the context of Tarski's axioms. In this section, we take advantage of our formal proofs to study how classical logic is used in the proofs of Schwabhaüser, Szmielew and Tarski [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. We removed the excluded middle axiom from our formal development and based on our formal proofs and we studied which instances of the excluded middle axiom were used.

Studying these case distinctions has both a theoretical interest per se and also a practical interest in the context of automated deduction. Indeed, as noted6 by Beeson while reproducing proofs of [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] using Otter:

"These arguments by cases caused us a lot of trouble in finding Otter proofs." The excluded middle axiom can be used at every step of the proof search process. This can generate a blow-up of the proof tree. Managing and guiding the automatic theorem prover for using the right case distinctions is essential.

Case Distinctions in Tarski's Proofs.

In our formalization of the first part of [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] there are more than 1500 case distinctions. Note that our proof may perform more case distinctions than necessary. Case distinction was used only on atomic formulas and defined predicates. Tab. I.3.5 lists the predicates with the number of occurrences of case distinctions in our development. Most of these predicates are detailed in the next part. By far, the decidability property which is used most often is decidability of equality of points. It is used as early as the eleventh lemma.

Equivalence of the Decidability of the Basic Relations.

To ensure that we not assume any decidability property, all the proofs in this subsection have been performed in the Tarski_neutral_dimensionless class. In order to prove the equivalence of the decidability of the basic relations, we collect four lemmas that are used throughout this proof.

Lemma 11 (3.1 7 ). A point is between any other point and itself.

Lemma 12. If A B C and AB

≡ H AC then B = C. Lemma 13. If A = B, A B C, A B D and BC ≡ H BD then C = D.
Lemma 14. A point on a given half-line at a given distance is constructible. Now, we give in natural language the proof at the level of details needed for the formalization.

Theorem 3 (Decidability of basic relations). In Tarski's geometry, the following properties are equivalent:

• decidability of point equality;

• decidability of congruence;

• decidability of betweenness. Proof. Assume decidability of point equality, we prove decidability of congruence: Let A, B, C and D be four points.

• Case A = B. -Case C = D. We have AB ≡ CD. -Case C = D.
Using axiom A3, we can conclude that ¬AB ≡ CD.

• Case A = B. -Case C = D.
Using axiom A3, we can conclude that ¬AB ≡ CD.

Decidability of Point Equality is Sufficient.

In this subsection, we prove that decidability of point equality implies decidability of all other predicates. For the predicates whose definitions do not contain quantifiers and involve only predicates which have already been shown to be decidable, such as the Col predicate, the decidability is trivial. Then, for the predicates whose definitions contain quantifiers, there are are two cases. Either, the quantifiers contained in the definition correspond to constructible points and they involve only predicates which have already been shown to be decidable. In this case, it suffices to construct the points which are quantified in the definition and use the proven decidability to conclude, such as for the Per predicate. The other case is where one needs to construct auxiliary points in order to decide if the predicate holds or not. Interestingly, one of the hardest predicate to prove decidable was proved using an lemma omitted in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF], that Braun and Narboux proved in [START_REF] Braun | From Tarski to Hilbert[END_REF]. Indeed, to prove the decidability of being on opposite sides of a line, one needs to prove that if two points are not on opposite sides of a line then there are on the same side of this line. Let us illustrate the case where one needs to construct auxiliary points in order to decide if the predicate holds or not by proving a simple decidability property, namely the decidability of intersection of lines. For this proof we use an alternative version of the parallel postulate, namely the strong parallel postulate (presented as Postulate 18 in the next part). Let us collect three lemmas that are used throughout this proof. 8

Lemma 15 (7.8). The symmetric of a point with respect to another point is constructible.

Lemma 16 (8.22). Midpoints are constructible.

Lemma 17 (12.17). If A and B are distinct and if the segments AC and BD have the same midpoint, then the lines AB and CD are parallel. 9 Proposition 1. One can decide whether two lines intersect or not. Proof. Given four points that we name P , Q, S and U (rather than A, B, C and D, to work with the same name as those in the definition of the strong parallel postulate) we wish to prove that either there exists a point I such that Col I S Q and Col I P U or that there does not exist such a point (Fig. I.3.4). We first eliminate the case where P lies on QS in which there exists such a point I, namely it is P . So we may assume that ¬ Col P Q S and we then eliminate the case of P and U being equal, as again there exists such a point I, namely Q (we could have also taken S to be this point). So we may assume P and U to be different. Now we construct the midpoint T of the segment P Q, using Lemma 16, and the symmetric point R of S with respect to T , using Lemma 15. Finally we distinguish two cases. Either ¬ Col P R U and the strong parallel postulate asserts there exists such a point I, provided that P T Q and R T S, which we easily prove as P and Q are different and ¬ Col P Q S. The other case is when Col P R U . In this case we can prove that lines QS and P U are strictly parallel, using Lemma 17 and the fact ¬ Col P Q S, and by definition of two lines being strictly parallel we know that there does not exist such a point I.

In the previous section we presented the two constructions of a perpendicular to a given line passing through a given point. The two constructions were to "drop" or "erect" a perpendicular. So to construct a perpendicular, one needs to be able to decide whether the point lies on the line or not. This implies that we need to prove the decidability of collinearity before being able to proof that a perpendicular to a given line passing through a given point is constructible. During the proving process, we then had to modify some lemmas to remove unnecessary case distinctions, and reorder many lemmas to obtain results when we need them to prove other results. Lemmas 15 and 16 which asserts the constructibility of some points thus had to be proved without being able to decide whether two lines intersect or not. Another example of such a requirement was hidden in the proof of Proposition 1. In fact, in order to prove that the strong parallel postulate is implied by Tarski's version of the parallel postulate, we used the decidability of being on opposite sides of a line which we originally demonstrated using the decidability of intersection of lines. With the original proof, this would constitute a circular argument: proving a decidability property by using some other lemmas which had been proved using this decidability property or an indirect consequence of it. While this circular argument is easy to detect it illustrates the first reason why we could not have carried out this study without the use of a proof assistant. The other reason being that it would have been very difficult to detect case distinction in an informal proof as, often, degenerate cases are omitted in the proofs as noted in previous results [START_REF] Narboux | Mechanical Theorem Proving in Tarski's geometry[END_REF][START_REF] Braun | From Tarski to Hilbert[END_REF] from Braun and Narboux.

The next step in this work would be to formalize that, assuming the continuity axiom, Tarski's system of geometry admits the quantifier elimination algorithm for real closed fields formalized by Cohen and Mahboubi in [START_REF] Cohen | Formal proofs in real algebraic geometry: from ordered fields to quantifier elimination[END_REF]. To do so, we would need to build a realFieldType. If the 8 We use the notations given in Appendix E. 9 It almost corresponds to the fact that the opposite sides of a non-degenerate quadrilateral which has its diagonals intersecting in their midpoint are parallel. To fully correspond to this fact one would need to add the hypothesis that A and D are distinct. decidability of point equality is sufficient to build a realFieldType, we could prove that every firstorder formula in Tarski's language is provably equivalent to a quantifier-free formula. Therefore, having proved the decidability of the basic relations, we would obtain the decidability of every first-order formula.

Conclusion of Part I

We have showed the mutual interpretability of two systems based on the synthetic approach (Hilbert's axioms and Tarski's system of geometry) and the analytic approach. 10 Besides proving the satisfiability of both systems, we have formalized the arithmetization of Tarski's system of geometry which, thanks to the mutual interpretability of Hilbert's and Tarski's axioms, also provides a formal proof of the arithmetization of the geometry based on Hilbert's axioms. We gave a new proof that Euclid's parallel postulate is not derivable from the other axioms of first-order Euclidean geometry. We should remark that although we proved the mutual interpretability of the theories for neutral geometry based on Hilbert's and Tarski's axioms, our proof does not allow to obtain a proof of independence of the parallel postulate for Hilbert's axioms. Indeed, for reasons that we expose in the next part, the version of the parallel postulate chosen by Hilbert is weaker than the one we studied and our proof cannot be adapted for this specific version. The main contribution of this work is that we proved the independence without actually constructing a model of non-Euclidean geometry. Finally, we have demonstrated that the decidability of point equality in the context of Tarski's system of geometry 11 is sufficient to achieve the arithmetization of Euclidean geometry. Moreover, we proved that we can equivalently assume the decidability of any of its three predicates (betweenness, congruence or point equality). 10 We should point out that the field theory that we built from Tarski's system of geometry does not correspond to realFieldType that we assumed to build our model. However, we plan to extend our work on the arithmetization of Euclidean geometry in order to build a realFieldType.

11 In the context of Hilbert's axioms, the decidability of the incidence of a point to a line as well as the decidability of intersection of lines are also required since we used them to establish the equivalence between Hilbert's and Tarski's axioms.

Part II

Parallel Postulates and Continuity Axioms in Intuitionistic Logic

In this part we focus on the formalization of results about Euclid's fifth postulate:

"If two lines are drawn which intersect a third in such a way that the sum of the inner angles on one side is less than two right angles, then the two lines inevitably must intersect each other on that side if extended far enough."

This postulate is of historical importance because for centuries, many mathematicians believed that this statement was rather a theorem which could be derived from the first four Euclid's postulates. History is rich with incorrect proofs of Euclid's fifth postulate. In 1763, Klügel provided, in his dissertation written under the guidance of Kästner, a survey of about 30 attempts to "prove Euclid's parallel postulate" [START_REF] Simon | Conatuum praecipuorum theoriam parallelarum demonstrandi recensio[END_REF]. Legendre published a geometry textbook Eléments de géométrie in 1774. Each edition of this popular book contained an (incorrect) proof of Euclid's postulate. Even in 1833, one year after the publication by Bolyai of an appendix about non-Euclidean geometry, Legendre was still convinced of the validity of his proofs of Euclid's fifth postulate: "Il n'en est pas moins certain que le théorème sur la somme des trois angles du triangle doit être regardé comme l'une de ces vérités fondamentales qu'il est impossible de contester, et qui sont un exemple toujours subsistant de la certitude mathématique qu'on recherche sans cesse et qu'on n'obtient que bien difficilement dans les autres branches des connaissances humaines."1 -Adrien Marie Legendre [START_REF] Marie | Réflexions sur différentes manières de démontrer la théorie des parallèles ou le théorème sur la somme des trois angles du triangle[END_REF] These proofs are incorrect for different reasons. Some proofs rely on an assumption which is more or less explicit but that the author takes for granted. Some other proofs are incorrect because they rely on a circular argument.

Proving the equivalence of different versions of the parallel postulate requires extreme rigor, as Trudeau has written: "Pursuing the project faithfully will require that we take the extreme measure of shutting out the entreaties of our intuitions and imaginations -a forced separation of mental powers that will quite understandably be confusing and difficult to maintain [...]." -Richard J. Trudeau [START_REF] Trudeau | The Non-Euclidean Revolution[END_REF] To help us in this task, we have a perfect tool which possesses no intuition: a computer. In this part we provide formal proofs, verified using the Coq proof assistant, that 34 different versions of Euclid's fifth postulate are equivalent in the theory defined by a subset of the axioms of Tarski's geometry, namely the two-dimensional neutral geometry using Archimedes' axiom. We also provide more precise results showing the equivalence in intuitionistic logic of four groups of axioms without any continuity assumption. This makes clearer our remark that, in order to define the arithmetic operations, as presented by Descartes, the choice of the parallel postulate is crucial.

Our formal proofs rely on the systematic development of geometry based on Tarski's system of geometry [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] that Schwabhäuser, Szmielew and Tarski produced. Those results have been formalized previously [Nar07b, BN12, BN17] using the Coq proof assistant, and completed by some new results in neutral geometry for this study. Thanks to the results from the previous part, all our proofs are also valid in the context of Hilbert's axioms. The equivalence between twentysix versions of Euclid's fifth postulate can be found in [START_REF] Edward | The Foundations of Geometry and the Non-Euclidean Plane[END_REF]. Greenberg also proves (or leaves as exercises) the equivalence between several versions of the parallel postulate [START_REF] Jay | Euclidean and Non-Euclidean Geometries -Development and History[END_REF]. However, these proofs are not checked mechanically and sometimes only sketched. Moreover, since we restrict ourselves to intuitionistic logic and we use continuity axioms only when necessary, we could not reuse directly all these proofs in our context, because some proofs in these books use the law of excluded middle or a continuity axiom (see Chapter II.1).

Following the classical approach to prove that Euclid's fifth postulate is not a theorem of neutral geometry, Makarios has provided a formal proof of the independence of Tarski's Euclidean axiom [START_REF] James | A Mechanical Verification of the Independence of Tarski's Euclidean Axiom[END_REF]. He used the Isabelle proof assistant to construct the Klein-Beltrami model, where the postulate is not verified. A close result is due to Marić and Petrović who formalized the complex plane using the Isabelle/HOL proof assistant [START_REF] Marić | Formalizing Complex Plane Geometry[END_REF]. Recently, Beeson has also studied the equivalence of different versions of the parallel postulate in the context of a constructive geometry [START_REF] Beeson | Constructive Geometry and the Parallel Postulate[END_REF].

Part II is structured as follows. In Chapter II.1, we give an overview of the results that we formalized, based on four example postulates, each representing a group of postulates which are equivalent. Then, in the Chapters II.2, II.3, II.4 and II.5 (one for each group of postulates), we give the precise statements and an overview of the proofs. The list of all the studied postulates is given in Appendix D, and the summary of the main definitions and notations is given in Appendix E.

CHAPTER II.1

Four Categories of Parallel Postulates

In this chapter, we classify different statements of the parallel postulate into four categories. Throughout this chapter, we focus on one postulate for each of these four categories. These four main postulates are equivalent in Archimedean neutral geometry using classical logic. However, in an intuitionistic logic, and in a non-Archimedean context, they are not equivalent.

Independent Parallel Postulates

Let us consider four versions of the parallel postulate.

(1) The first postulate was chosen by Tarski in [START_REF] Tarski | A Decision Method for Elementary Algebra and Geometry[END_REF] and retained in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. Therefore, we refer to it as Tarski's parallel postulate. It expresses that given a point D between the points B and C and a point T further away from A than D on the half line AD, one can build a line which goes through T and intersects the sides BA and BC of the angle ∠ABC respectively further away from B than A and C (Fig. II.1.9). (2) The second postulate that we study in this section was adopted by Hilbert in [START_REF] Hilbert | Foundations of Geometry (Grundlagen der Geometrie[END_REF] and is known as Playfair's postulate. It states that there is a unique parallel to a given line going through some point (Fig 4) The fourth postulate is due to Bachmann [START_REF] Bachmann | Zur Parallelenfrage[END_REF]. Following Pambuccian [START_REF] Victor Pambuccian | On the equivalence of Lagrange's axiom to the Lotschnittaxiom[END_REF], we refer to it as Bachmann's Lotschnittaxiom. It formulates that given the lines l, m, r and s, if l and r are perpendicular, r and s are perpendicular and s and m are perpendicular, then l and m must meet. In classical logic, these four postulates are equivalent in Archimedean neutral geometry. By Archimedean planar neutral geometry we mean neutral geometry in which Archimedes' axiom1 holds. Archimedes' axiom is a corollary of the continuity axiom of Tarski (A11, which we do not present here) which can be expressed in the following way. Given two segments AB and CD such that A is different from B, there exist some positive integer n and n + 1 points A 1 , • • • , A n+1 on line CD, such that A j is between A j-1 and A j+1 for 2 < j < n, A j A j+1 and AB are congruent for 1 < j < n, A 1 = C and D is between A n and A n+1 .

Nevertheless, by weakening the theory, this equivalence ceases to hold. We presented these postulates, which fall into four distinct categories, in decreasing order of strength.

Tarski's Parallel Postulate is Strictly Stronger than Playfair's Postulate.

By dropping the law of excluded middle, 2 , Tarski's parallel postulate becomes strictly stronger than Playfair's postulate. Indeed, a particular instance of the law of excluded middle, namely the decidability of intersection of lines, is required to prove that Tarski's parallel postulate follows from Playfair's postulate. We present this proof in Chapter II.3 since we did not prove a direct implication, and therefore first need to introduce some other postulates. Now, to prove that the decidability of intersection of lines is indeed needed for the proof, it suffices to show that Tarski's parallel postulate implies the decidability of intersection of lines and that Playfair's postulate does not. We prove the first of these facts in Chapter II.3. The second of these facts has already been partly exposed in the previous part. Now that we have introduced Playfair's postulate, we would like to stress that it does not allow to create any point. This justifies our claim that "we still would not be able to construct the intersection point". This implies that only postulates equivalent to Tarski's parallel postulate allow to obtain the arithmetization and coordinatization of Euclidean geometry, as defined by Descartes.

However, Playfair's postulate can be proved in neutral geometry with decidable point equality assuming Tarski's parallel postulate. This proof is actually in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]: it corresponds to Satz 12.11 which we formalized. In this proof, one does not need to reason by cases on the possibility for two lines to intersect.

Playfair's Postulate is Strictly Stronger than the Triangle Postulate. Just as

Tarski's parallel postulate becomes strictly stronger than Playfair's postulate by dropping the law of excluded middle, Playfair's postulate becomes strictly stronger than the triangle postulate when dropping Archimedes' axiom. Indeed, Dehn, a student of Hilbert, has shown that Playfair's postulate is independent from the axioms of planar neutral geometry extended with the triangle postulate [START_REF] Dehn | Die Legendre'schen Sätze über die Winkelsumme im Dreieck[END_REF]: he gave a non-Archimedean model in which the triangle postulate holds and Playfair's postulate does not. One could then think that Archimedes' axiom is the missing link between these postulates. Actually, Greenberg has showed that, in order to prove that the triangle postulate implies Playfair's postulate, a corollary of Archimedes' axiom is sufficient [START_REF] Jay | Old and New Results in the Foundations of Elementary Plane Euclidean and Non-Euclidean Geometries[END_REF], which we refer to as Greenberg's axiom 3 (Fig. II.1.14). In fact, Greenberg proves that this axiom is a corollary of Archimedes' axiom by proving that it follows 4 from Aristotle's axiom 5 (Fig. II.1.13), itself following from Archimedes' axiom. Greenberg defines Aristotle's and Greenberg's axioms in the following way.

"Given any acute angle, any side of that angle, and any challenge segment P Q, there exists a point Y on the given side of the angle such that if X is the foot of the perpendicular from Y to the other side of the angle, then Y X > P Q." "Given any segment P Q, line l through Q perpendicular to P Q, and ray r of l with vertex Q, if θ is any acute angle, then there exists a point R on r such that P R Q < θ 6 ."

The Triangle Postulate is Strictly

Stronger than Bachmann's Lotschnittaxiom. Similarly, when dropping Archimedes' axiom, the triangle postulate becomes strictly stronger than Bachmann's Lotschnittaxiom. Bachmann demonstrated that this postulate, that he named Lotschnittaxiom, was strictly weaker than the triangle postulate [START_REF] Bachmann | Aufbau der Geometrie aus dem Spiegelungsbegriff[END_REF]. Pambuccian proved that Aristotle's axiom is sufficient to prove that the triangle postulate is implied by Bachmann's Lotschnittaxiom [START_REF] Victor Pambuccian | Zum Stufenaufbau des Parallelenaxioms[END_REF]. Pambuccian's proof uses Pejas' classification of Hilbert planes [START_REF] Pejas | Die Modelle des Hilbertschen Axiomensystems der absoluten Geometrie[END_REF] and, up to our knowledge, there is no synthetic proof of the fact that this corollary is sufficient, therefore we did not formalize this proof.

We can summarize the results from the previous subsections using Fig. 3 One should remark that this axiom is not named after Greenberg in [START_REF] Jay | Old and New Results in the Foundations of Elementary Plane Euclidean and Non-Euclidean Geometries[END_REF]. 4 Pambuccian proved the equivalence between these two axioms after the publication of our paper and we formalized his proof. 5 For the sake of conciseness, we adopted the same name as Greenberg for this axiom which is also known under the name of Aristotle's angle unboundedness axiom. 6 We use < for the strict comparison between angles.

These independence results confirm that the theory in which the statements are proven needs to be precisely defined. Moreover, they illustrate the fact that some postulates can cease to be equivalent if the logic is changed. Therefore, the notion of equivalence is not only relative to the theory but also to the logic. Since, in this part, we classify parallel postulates according to the theory and the logic in which they are equivalent, we now introduce a few notations for the different kinds of equivalence that are considered. Let us denote by N the axioms of planar neutral geometry (A1-A9) with decidability of point equality, by A Archimedes' axiom and by G Greenberg's axiom. We adopt the symbols |= LJ and |= LK to differentiate the intuitionistic and the classical setting. We say that two properties P and Q are respectively

N LJ -equivalent, N G LJ -equivalent, N A LJ -equivalent or N LK -equivalent if N |= LJ P ⇔ Q, N ; G |= LJ P ⇔ Q, N ; A |= LJ P ⇔ Q or N |= LK P ⇔ Q.
The rest of this part is organized according to Fig. II.1.1. In order to determine in which category a version of the parallel postulate belongs we formalize its N LJ -equivalence with one of this four postulates. For the sake of avoiding references to the N LJ -equivalence of some postulates, we start by studying the postulates N LJ -equivalent to Playfair's postulate. Then we proceed in decreasing order of strength, thus considering the postulates N LJ -equivalent to Tarski's parallel postulate, then those N LJ -equivalent to the triangle postulate and finally those N LJ -equivalent to Bachmann's Lotschnittaxiom.

Formal Definitions of Acute Angles, Parallelism and the Sum of non-Oriented Angles

In order to formalize these four postulates and these four axioms, we first need to define acute angles, parallelism and the sum of non-oriented angles. Indeed, Tarski's parallel postulate is the only postulate expressed without any definition. 7 Thus this section is dedicated to defining these concepts. In this part, the exact Coq syntax of the axioms, definitions and main theorems is listed without any pretty printing, to give the reader the opportunity to check what is the exact statement we proved. For the auxiliary lemmas and all the proofs, we use classical mathematical notations. The proofs given in this part serve only as a documentation; the correctness of the results is assured by the mechanical proof checker. Recall that for each postulate, we provide the figure representing the statement in the Euclidean plane and a counter-example in Poincaré disk model. Having a counter-example in non-Euclidean geometry is interesting, as Szmielew proved (assuming Dedekind's axiom for first-order formulas) that every statement which is false in hyperbolic geometry and correct in Euclidean geometry is equivalent to the fifth parallel postulate [START_REF] Szmielew | Some Metamathematical Problems Concerning Elementary Hyperbolic Geometry[END_REF] (we formalize a variant of this theorem in Chapter II.5, Section 4).

Formal Definition of Parallelism.

In this subsection we define parallelism, which is one of the most important definitions for this work. In [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] one can find two definitions of parallelism. The common way of defining it is to consider two lines as parallel if they belong to the same plane but do not meet. This implies that we also define collinearity and coplanarity. The other definition of parallelism includes the previous one and add the possibility for the lines to be equal. Therefore we talk about strict parallelism in the first case and about parallelism in the second.

Definition Col A B C := Bet A B C \/ Bet B C A \/ Bet C A B.
This predicate corresponds to Definition 4.10 of [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. Among the first definitions which are introduced, there is the predicates expressing collinearity. It can be defined using only the betweeness predicate. Col A B C expresses that A, B and C are collinear if and only if one of the three points is between the other two.

Definition Coplanar A B C D := exists X, (Col A B X /\ Col C D X) \/ (Col A C X /\ Col B D X) \/ (Col A D X /\ Col B C X).
We did not define coplanarity in the same way as in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]; we chose to express coplanarity as a 4-ary predicate to avoid the definition of a predicate with an arbitrary number of terms. Restricting ourselves to characterize coplanarity of four points, we could use Satz 9.33 in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] as a definition of coplanarity. This definition states that four points are coplanar if two out of these four points form a line which intersect the line formed by the remaining two points (either X 1 , X 2 or X 3 Yet we keep this definition, because we plan to extend our formalization to higher dimensions in the future, as a large part of our library is available in arbitrary dimension. In fact, in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] the proofs are performed in a n-dimensional space for a fixed positive integer n, given by the statement of variants of the dimension axioms.

Definition Par_strict A B C D := A <> B /\ C <> D /\ Coplanar A B C D /\ ˜exists X, Col X A B /\ Col X C D.
This predicate corresponds to Definition 12.2 of [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. Note that one could have chosen other definitions. For instance, one could have defined two lines (when we consider lines, it is implied that the two points defining them are distinct) to be parallel when they are at constant distance. According to Papadopoulos [START_REF] Papadopoulos | Master Class in Geometry -Chapter 1 -Notes on non-Euclidean geometry[END_REF], this definition was introduced by Posidonius, an early commenter of Euclid's Elements. As we see in Chapter II.4, an implicit change in a definition can have severe consequences in the validity of a proof. This predicate corresponds to Definition 12.3 of [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. This definition asserts that two lines are parallel if they are strictly parallel or if they are equal, since with the previous definition, one line is not parallel to itself.

Formal Definition of the Sum of non-Oriented

Angles. This subsection is devoted to the definition of the sum of non-oriented angles. It is based on the notions of congruence of angles and sides of line, which are presented in this subsection. It should be pointed out that there is no definition for the sum of non-oriented angles in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF].

Definition CongA A B C D E F := A <> B /\ C <> B /\ D <> E /\ F <> E /\ exists A', exists C', exists D', exists F', Bet B A A' /\ Cong A A' E D /\ Bet B C C' /\ Cong C C' E F /\ Bet E D D' /\ Cong D D' B A /\ Bet E F F' /\ Cong F F' B C /\ Cong A' C' D' F'.
This predicate corresponds to Definition 11.2 of [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. Two angles are said to be congruent if one can prolong the sides of the angles to obtain congruent triangles (Fig. II.1.3). A B C = D E F means that angles ∠ABC and ∠DEF are congruent. It should be noticed that even though the definition does not explicitly states that BA ≡ EF or BC ≡ ED , these congruences are provable thanks to Satz 2.11 of [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. This proposition corresponds to a degenerate case of the fivesegment axiom A5 (Fig. I.1.2). This is technically important in Tarski's system of geometry, as it allows us to have fewer axioms in the system. However, the non-degenerate case of this axiom is independent of the other axioms of our theory to which one would add the degenerate case of this axiom [START_REF] Hilbert | Foundations of Geometry (Grundlagen der Geometrie[END_REF]. It is therefore questionable to assume such axioms when using intuitionistic logic. Nevertheless, as proved in [START_REF] Beeson | A Constructive Version of Tarski's Geometry[END_REF] and in Chapter I.3, assuming the decidability of point equality suffices to recover all the propositions of [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] in an intuitionistic setting. In this case one says that these first two points are on opposite sides of the other line. A P Q P Q B indicates that P and Q are on opposite sides of line AB. This definition being a special case of coplanarity, it has the advantage of being valid in spaces of dimension higher than two. This notion is absent in Euclid's Elements [START_REF] Euclid | Euclid's Elements: all thirteen books complete in one volume : the Thomas Little Heath translation[END_REF], in which the relative position of the points on the figure is not justified, but inferred from the figure.

Definition OS A B P Q := exists R, TS A B P R /\ TS A B Q R. A B Q R P A B P Q R Figure II.1.5. Definition of OS.
The last predicate needed to be able to define the sum of non-oriented angles captures the property for two points to be on the same side of a line. This predicate corresponds to Definition 9.7 of [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. The name of this predicate corresponds the abbreviation for one side. Two points are said to be on the same side of a line if there exists a third point with which both of the points are on opposite side of this line ( As we want to study the impact of Archimedes' axiom, we cannot define the sum of angles through the use of a measure for the angles. Indeed, Archimedes' axiom would be needed to define a measure function [START_REF] Rothe | Several Topics from Geometry[END_REF]. Another approach could be to define a function that given two angles would return an angle representing their sum. Again this approach would necessitate an extra axiom: the axiom of choice. As a matter of fact, the axiom of choice would be used to select a representative within the equivalence class of the angles congruent to the sum of our given angles. Thus the sum of angles has to be defined geometrically.

To obtain the sum of two angles ∠ABC and ∠DEF , one constructs a point J such that ∠ABC and ∠CBJ are adjacent and C B J = D E F (Fig. II.1.6). Then the sum of the angles ∠ABC and ∠DEF is ∠GHI if A B J = G H I. One thing which could be surprising is the fact that we specified that the angles ∠ABC and ∠CBJ are adjacent by the fact that A and J are not on the same side of line BC. This choice allows us to do without a disjunction of cases (either A and J are on opposite side of line BC or J belongs to line BC). Actually one cannot simply state that these points are on opposite sides of line BC, as this would imply that the sum of angles is not defined when one of the angles is straight or null.

Definition TriSumA A B C D E F := exists G H I, SumA A B C B C A G H I /\ SumA G H I C A B D E F.
The triangle postulate expresses a property about the sum of the interior angles of a triangle, so we decided to define a predicate stating that the sum of the interior angles of a triangle is congruent to a specific angle. Namely, S( ABC) = D E F means that the sum of the interior angles of triangle ABC is congruent to angle ∠DEF . The fact that we did not define the sum of angles as a function but as a predicate motivated this choice. Indeed, it avoids carrying the witness of the partial sum of the first two angles. Of course, to be able to talk about the sum of the angles of a triangle, it has to be commutative and associative. We see in Chapter II.3, Section 1 that it is only the case under certain conditions that are fulfilled when considering the interior angles of a triangle.

Formal Definition of Acute Angles.

In order to be able to formalize a predicate specifying that an angle is acute, we need to define the concepts of angle comparison and right triangles. Defining these concepts was straightforward, as both of them were already present in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. For the sake of completeness we now present them.

To express a predicate specifying that an angle is acute, we do not need a definition for perpendicularity, but only for right triangles. The definition of a right triangle is more general than the definition of a right angle since it includes the case of a degenerate triangle. In [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF], right triangles are defined through midpoints. Following, we first present Tarski's definition of midpoint and right triangle.

Definition Midpoint M A B := Bet A M B /\ Cong A M M B.
This predicate corresponds to Definition 7.1 of [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. It states that M is the midpoint of A and B. It is the case when M is between A and B and equidistant from them. It is interesting to notice that the existence of the midpoint appears quite late in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. This is because its proof, which does not involve the continuity axiom and is due to Gupta [START_REF] Narayan | Contributions to the Axiomatic Foundations of Geometry[END_REF], cannot be done earlier in the development. The notion of angle comparison is defined by means of a predicate stating that a point belongs to the interior of an angle, itself formulated using a predicate asserting that a point belongs to a ray.

Definition Out P A B := A <> P /\ B <> P /\ (Bet P A B \/ Bet P B A).

This predicate corresponds to Definition 6.1 of [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. P A B indicates that P belongs to line AB but does not belong to the segment AB. This implies that A and B belong to the same ray with initial point P and that neither of these points coincide with P . This predicate is symmetric in its last two points, but we usually choose to prioritize the first of these points to define the ray. Thus, most of the time, P A B expresses the fact that B belongs to the ray P A.

Definition InAngle P A B C :=

A <> B /\ C <> B /\ P <> B /\ exists X, Bet A X C /\ (X = B \/ Out B X P). This predicate corresponds to Definition 11.23 of [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. P ∈ A B C states that P belongs to the interior of angle ∠ABC (Fig. II.1.8). A point P is said to belong to the angle ABC if this angle is well defined, meaning that B is distinct from both A and C, and if there exists a point X on the segment AC such that either P belongs to the ray BX or B and X are equal. This last case occurs when angle ∠ABC is straight and one consider that any point belongs to a straight angle, except its vertex. An alternative to this definition would have been the one Greenberg uses in [START_REF] Jay | Euclidean and Non-Euclidean Geometries -Development and History[END_REF], namely that P belongs to the interior of the angle ABC if P and A are one the same side of line BC and if P and C are on the same side of line BA. The definition from [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] is more general, because according to Greenberg's definition, a point on one of the sides of an angle is not inside it. Assuming that the point we consider is not on a side of the angle, the one we adopted trivially implies the one Greenberg uses, and the converse can be proved by applying Pasch's axiom. However, we chose to adopt the version from [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] since it directly provides the point X. Let us here emphasize again the importance of definitions. The reader could be tempted to define P ∈ A B C as the existence of a segment with endpoints on the sides of a given angle which passes through P . Yet, it is not always the case that this segment exists. Indeed, this property corresponds to Tarski's parallel postulate. This predicate corresponds to Definition 11.27 of [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. An angle ∠ABC is said to be smaller than or equal to another angle ∠DEF if there exists a point P in the interior of this second angle such that angle ∠DEP is congruent to the first angle. The witness point P , which is needed for proving different properties about this order relation, is omitted by this predicate.

Definition LtA A B C D E F := LeA A B C D E F /\ ˜CongA A B C D E F.
This predicate corresponds to Definition 11.38 of [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. It is more straightforward to first define the non-strict comparison between angles. However, in order to obtain a predicate characterizing acute angles, we need to define the strict comparison between angles. This is done by simply excluding the case where the angles are congruent.

Definition Acute A B C := exists A', exists B', exists C', Per A' B' C' /\ LtA A B C A' B' C'.
Finally, we can define a predicate characterizing acute angles. This predicate corresponds to Definition 11.39 of [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. An angle ∠ABC is said to be acute if there exists a right triangle A B C with the right angle at vertex B such that angle ∠ABC is strictly smaller than angle ∠A B C . One can recall that A B C means that angle ∠A B C is right only in the case where B is distinct from both A and C . This is the case thanks to the definition of the angle comparison. This enforces that the angle to which we compare the angle ABC is indeed right.

Formalization of the four Particular Versions of the Parallel Postulate and of the Continuity Axioms

In this section, we formalize Tarski's parallel postulate, Playfair's postulate, the triangle postulate and Bachmann's Lotschnittaxiom, as well as the decidability of intersection of lines, Archimedes', Aristotle's and Greenberg's axioms. Now that we defined acute angles, parallelism and the sum of non-oriented angles, we are able to define these postulates and axioms easily, except for Archimedes' axiom, which requires a few extra definitions. This postulate (Fig. II.1.9) is the official version of the parallel postulate found in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. The statement, due to Lorentz [START_REF] Narayan | Contributions to the Axiomatic Foundations of Geometry[END_REF], is a modification of an implicit assumption made by Legendre while attempting to prove that Euclid's parallel postulate was a consequence of Euclid's other axioms, namely Legendre's parallel postulate which is introduced in Chapter II.5, Section 3. This version is particularly interesting, as it has the advantages of being easily expressed only in term of betweenness, and being valid in spaces of dimension higher than two. ) is one of the best-known versions of the parallel postulate for the modern reader. This postulate corresponds to Satz 12.13 in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. Note that it does not state the existence of the parallel line but only its uniqueness, because the existence can be proved from the axioms of Tarski's neutral geometry (Satz 12.10 of [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]). Proclus, another early commenter of Euclid's Elements, already recognized that an incorrect proof of Euclid's postulate by Ptolemy was making this implicit assumption. [START_REF] Euclid | Euclid's Elements: all thirteen books complete in one volume : the Thomas Little Heath translation[END_REF] and Satz 12.23 in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. We formalized it slightly differently, as it precisely formulates that the sum is equal to a straight angle instead of two right angles. Nevertheless, we have proved that the sum of an angle with itself is equal to a straight angle if and only if the angle is right. This postulate results of a failed attempt at proving Euclid's parallel postulate due to Legendre. This statement was implicitly used in one of Legendre's proofs. Interestingly, the sum of the angles of a triangle allows to set apart hyperbolic, Euclidean and elliptic geometry. This sum is respectively lower, equal or higher than two right angles in hyperbolic, Euclidean and elliptic case.

Tarski's Parallel Postulate. Postulate 1 (Tarski's parallel postulate).

Definition tarski_s_parallel_postulate :

= forall A B C D T, Bet A D T -> Bet B D C -> A <> D -> exists X, exists Y, Bet A B X /\ Bet A C Y /\ Bet X T Y.

Playfair's Postulate. Postulate 2 (Playfair's postulate).

Triangle Postulate.

Postulate 3 (Triangle postulate).

Bachmann's Lotschnittaxiom. Postulate 4 (Bachmann's Lotschnittaxiom).

Definition bachmann_s_lotschnittaxiom : This postulate (Fig. II.1.12) expresses that, given that the lines P Q and QR are perpendicular, the lines P Q and P P 1 are perpendicular and the lines QR and RR 1 are perpendicular, we know that the lines P P 1 and RR 1 must intersect. Here, the perpendicularity hypotheses are expressed using the Per predicates, hence we had to add non-degeneracy hypotheses to exclude the cases where the points P and Q, as well as the points Q and R, are equal. However, since the property is trivially true in the cases where P = P 1 or R = R 1 , we did not exclude these cases. According to Hartshorne [START_REF] Hartshorne | Geometry : Euclid and beyond[END_REF], it "characterizes geometries in which the angle sum of a triangle differs at most infinitesimally" from two right angles. This axiom corresponds to a simple decidability property. However, it holds a special place in this study. Indeed, in the previous part, we studied the impact of working in an intuitionistic setting in Tarski's system of geometry. During this work, we were trying to either prove that Axiom 1 could be derived from the axioms of Tarski's system of geometry with decidable point equality or find an argument justifying its independence. Once we discovered its close relationship with the parallel postulates, we started to investigate which versions of the parallel postulates were implying it. Thus Axiom 1 can be considered as the starting point of the classification of the parallel postulates that we present in this part.

= forall P Q R P1 R1, P <> Q -> Q <> R -> Per P Q R -> Per Q P P1 -> Per Q R R1 -> exists S, Col P P1 S /\ Col R R1 S.

Decidability of Intersection of Lines. Axiom 1 (Decidability of intersection of lines).

Archimedes' Axiom.

Archimedes' axiom can be expressed almost directly using the betweeness and congruence predicates. Following Duprat's work [START_REF] Duprat | Fondements de géométrie euclidienne[END_REF], we defined it inductively without introducing the natural numbers. To state Archimedes' axiom, we first formalized the fact that "there exists some positive integer n and n + 1 points A 1 , • • • , A n+1 on line AB, such that A j is between A j-1 and A j+1 for 2 < j < n, A j A j+1 and AB are congruent for 1 < j < n, A 1 = A and A n+1 = C" as the Grad predicate. This predicate and its variants, which are presented in Chapter II.5, Section 3, represent the only inductive definitions of our library. Actually, we do not specify that "D is between A 1 and A n+1 " in our definition but we use the definition for non-strict comparison between segments from [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF].

Definition Le A B C D := exists E, Bet C E D /\ Cong A B C E.
This predicate corresponds to Definition 5.4 of [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. A segment AB is said to be less than or equal to another one CD if one can construct a point E such that this point is between C and D and the segments AB and CE are congruent. For convenience, this witness, which is needed for proving different properties about this order relation, is omitted by this predicate.

Using this predicate, it suffices to assert that CD ≤ A 1 A n+1 , which allow us to set A 1 = A and to have A 1 , • • • , A n+1 on line AB. This predicate corresponds to Definition 5.14 of [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. The reason for the non-strict comparison to appear before the strict one is simple. Unlike Hilbert, Tarski uses a non-strict betweenness relation. In order to obtain a strict comparison of segments, it suffices to exclude the case where they are congruent.

We are now ready to state Aristotle's axiom. Axiom 3 (Aristotle's axiom). This axiom is very close to the statement from Greenberg [Gre10] that we gave in Subsection 1.2. Here the acute angle is the angle ∠ABC (Fig. II.1.13). Compared to Greenberg's statement, we had to add the condition that this angle is non-null. 8 Moreover, since the triangle BXY can be proved non-degenerate from the other assumptions, we can establish that X is the foot of the perpendicular from Y to the other side of the angle by specifying that BXY is a right triangle with the right angle at vertex X. The other subtle difference is the fact that our version states the existence of both points X and Y . This is due to the fact that one cannot define a function for the orthogonal projection in our current axiom system. In order to obtain such a function, one would either need a stronger axiom system where one would introduce function symbols in the axioms which are not already quantifier-free, or one would require an extra axiom. For example, one could have used the constructive definite description axiom provided by the standard library: 8 Non-degeneracy conditions are often omitted in textbook proofs.

Axiom constructive_definite_description :

forall (A : Type) (P : A->Prop), (exists! x, P x) -> { x : A | P x }.

It allows us to convert a relation which has been proved to be functional to a proper Coq function. As the use of the axiom turns the intuitionistic logic of Coq into an almost classical logic [START_REF] Lane | Hilbert's -operator in intuitionistic type theories[END_REF], we decided to avoid adding this axiom.

Greenberg's Axiom. Axiom 4 (Greenberg's axiom).

Definition greenberg_s_axiom : As for Aristotle's axiom, this axiom does not differ much from Greenberg's statement seen in Subsection 1.2. Again the acute angle is the angle ∠ABC (Fig. II.1.14). The ray r is given through point R. In order to make sure this ray is well defined we had to add the condition that points Q and R are different. Finally the point S asserted to exist corresponds to the point R from the statement given by Greenberg.

= forall P Q R A B C, ˜Col A B C -> Acute A B C -> Q <> R -> Per P Q R -> exists S, LtA P S Q A B C /\ Out Q S R.
Both of these axioms are consequences of Archimedes' axiom, but not conversely [START_REF] Jay | Aristotle's axiom in the foundations of geometry[END_REF][START_REF] Jay | Old and New Results in the Foundations of Elementary Plane Euclidean and Non-Euclidean Geometries[END_REF]. Indeed Aristotle's axiom is a weaker axiom than Archimedes' axiom and Greenberg's axiom is a consequence of Aristotle's axiom.

CHAPTER II.2

Postulates Equivalent to Playfair's Postulate

In this chapter, we present the postulates which are N LJ -equivalent to Playfair's postulate in planar neutral geometry. Some of these properties are expressed using definitions present in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. Thus we also give these definitions in this chapter. Then we discuss the formalization of the equivalence proofs.

Statements of Postulates Equivalent to Playfair's Postulate

Here, we introduce eight postulates which are N LJ -equivalent to Postulate 2 (Playfair's postulate). They correspond to properties about various subjects, namely parallelism, perpendicularity, angles and distance. This variety of subjects represents a specificity of the parallel postulate. We see in the next section how this variety affected the way we proved the equivalence of all of these statements. "Parallel straight lines are straight lines which, being in the same plane and being produced indefinitely in either direction, do not meet one another in either direction." Indeed, it is possible for lines A 1 A 2 and C 1 C 2 to be equal. One should notice here that again definitions are essential. Postulate 6 (Midpoint converse postulate).

Postulate 5 (Postulate of transitivity of parallelism).

Definition midpoint_converse_postulate := forall A B C P Q, ˜Col A B C -> Midpoint P B C -> Par A B Q P -> Col A C Q -> Midpoint Q A C.
This postulate (Fig. II.2.2) is a part of the converse of the midpoint theorem and corresponds to a special case of the intercept theorem. Therefore, we refer to it as midpoint converse postulate. This postulate expresses that, in a non-degenerate triangle ABC, the intersection point Q of side AC with the parallel to side AB which passes through the midpoint P of side BC is the midpoint of side AC. One should notice that the midpoint theorem is valid in planar neutral geometry, whereas its converse is equivalent to the parallel postulate. Indeed, it follows easily from the Satz 13.1 of [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. It is interesting to remark that the second part of the converse of the midpoint theorem, namely that, in any triangle, the midline (the segment P Q on Fig. 3) is commonly known as alternate interior angles theorem. It asserts that a line falling on parallel lines makes the alternate angles equal to one another. One can remark that this postulate, like others, was a proposition in [START_REF] Euclid | Euclid's Elements: all thirteen books complete in one volume : the Thomas Little Heath translation[END_REF] (a part of Proposition I.29) as well as in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] (Satz 12.21). However, Satz 12.21 of [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] is an equivalence and enunciates more than the alternate interior angles theorem. One side of the equivalence corresponds to the alternate interior angles theorem, while the other corresponds to its converse, which is valid in neutral planar geometry, just as for the previous postulate. Postulate 8 (Consecutive interior angles postulate).

II.2. POSTULATES EQUIVALENT TO PLAYFAIR'S POSTULATE

Definition consecutive_interior_angles_postulate := forall A B C D P Q R, OS B C A D -> Par A B C D -> SumA A B C B C D P Q R -> Bet P Q R.
This postulate (Fig. II.2.4) is commonly known as consecutive interior angles theorem. It states that a line falling on parallel lines makes the sum of interior angles on the same side equal to two right angles. It was proved together with the previous postulate in [START_REF] Euclid | Euclid's Elements: all thirteen books complete in one volume : the Thomas Little Heath translation[END_REF] (as a part of Proposition I.29) but not in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF], since the notion of supplementary angles is never introduced in this book. Similarly to the triangle postulate, we formalized this postulate slightly differently, as it precisely formulates that the sum is equal to a straight angle. With a view to defining the next postulate, we need to define perpendicularity, something which we postponed. We adopted the definition given in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF], which used the following intermediate definition. We recall that we already defined a predicate for right triangles, but this definition included the case where the sides of the right angle could be degenerate. Therefore, in order to define perpendicularity using this predicate, one must know the intersection point of the perpendicular lines and exclude the case of the degenerate right triangle. AB ⊥ This postulate (Fig. II.2.6) is commonly known as perpendicular transversal theorem. It expresses that given two parallel lines, any line perpendicular to the first line is perpendicular to the second line. Just as for the previous postulates, the converse of the perpendicular transversal postulate is valid in neutral planar geometry. It corresponds to Satz 12.9 in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] and the perpendicular transversal postulate corresponds to a special case of Satz 12.22 in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. This postulate (Fig. II.2.7), which is designated as postulate of parallelism of perpendicular transversals, is less known than the previous ones. This is probably due to the fact that it can be easily deduced from the perpendicular transversal postulate and its converse. This could explain why it does not appear as a proposition in the most well-known axiomatic developments of Euclidean geometry, which are those of Euclid [START_REF] Euclid | Euclid's Elements: all thirteen books complete in one volume : the Thomas Little Heath translation[END_REF], Hilbert [START_REF] Hilbert | Foundations of Geometry (Grundlagen der Geometrie[END_REF] and Tarski [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. Nevertheless, it is listed amongst the statements equivalent to the parallel postulate in [START_REF] Jay | Euclidean and Non-Euclidean Geometries -Development and History[END_REF] and [START_REF] Edward | The Foundations of Geometry and the Non-Euclidean Plane[END_REF]. It asserts that two lines, each perpendicular to one of a pair of parallel lines, are parallel. It is easy to take this property for granted and assume it implicitly since it corresponds to Satz 12.9 in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF], which is valid in neutral planar geometry, when the two lines known to be parallel are equal. Postulate 11 (Universal Posidonius' postulate).

Definition Perp_at X A B C D := A <> B /\ C <> D /\ Col X A B /\ Col X C D /\ (forall U V, Col U A B -> Col V C D -> Per U X V).
Definition universal_posidonius_postulate := forall A1 A2 A3 A4 B1 B2 B3 B4, Par A1 A2 B1 B2 -> Col A1 A2 A3 -> Col B1 B2 B3 -> Perp A1 A2 A3 B3 -> Col A1 A2 A4 -> Col B1 B2 B4 -> Perp A1 A2 A4 B4 -> Cong A3 B3 A4 B4.
This postulate (Fig. II.2.8) is a property of parallel lines in Euclidean geometry which was taken as definition of parallelism by Posidonius. We refer to it as universal Posidonius' postulate because another postulate (Postulate 22), known as Posidonius' postulate, can be expressed in a similar way with the exception that the points A 1 , A 2 , B 1 and B 2 are quantified existentially and not universally and that the hypothesis of parallelism is replaced by a non-degeneracy condition. It states that, if two lines A 1 A 2 and B 1 B 2 are parallel, then they are everywhere equidistant. This can be formalized by specifying that any two points B 3 and B 4 on B 1 B 2 form with the feet of the orthogonal projection of these points onto the line A 1 A 2 , respectively A 3 and A 4 , congruent segments. However, as we see in Chapter II.4, Section 1, everywhere equidistant lines only exist in Euclidean geometry. This statement being equivalent to the parallel postulate motivates the fact that we list all of the definitions we chose, since, as already mentioned, definitions are critical when studying statements of the parallel postulate.

The last postulate that we analyze in this chapter is a special case of Playfair's postulate where one of the parallel lines shares a common perpendicular with its parallel. Thus, to state this postulate, we first present a refinement of this property which was defined in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. This predicate corresponds to Definition 13.9 of [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. AB |= P CD not only means that the lines AB and CD have a common perpendicular XY but also that XY passes through the point P (Fig. II.2.9). One should remark that AB |= P CD implies, in neutral planar geometry, that the lines AB and CD are parallel. However, not any pair of parallel lines share a common perpendicular. In fact, in hyperbolic geometry, ultraparallel lines only share a unique common perpendicular, and limiting parallels do not share any common perpendicular [START_REF] Borsuk | Foundations of Geometry[END_REF]. Therefore, even in the case of ultraparallel lines, there may be no common perpendicular passing through a given point, since it suffices that this point lies outside their unique common perpendicular.

Definition Perp2 A B C D P := exists X, exists Y, Col P X Y /\ Perp X Y A B /\ Perp X Y C D.

Postulate 12 (Alternative Playfair's postulate).

Definition alternative_playfair_s_postulate := forall A1 A2 B1 B2 C1 C2 P, Perp2 A1 A2 B1 B2 P -

> Col P B1 B2 -> Par A1 A2 C1 C2 -> Col P C1 C2 -> Col C1 B1 B2 /\ Col C2 B1 B2.
Because of the similarity of Postulate 12 (Fig. II.2.10) with Postulate 2 (Playfair's postulate) we decided to name it alternative Playfair's postulate. It asserts that any line parallel to a given line passing through a given point is equal to the line that passes through the given point and shares a common perpendicular with the given line that passes through the given point. One should mention that this postulate does not have the same importance as the other ones, because its role is just to simplify the proofs.

Formalizing the Equivalence Proof

In this section, we focus on the formalization of the proof that the postulates of the previous section (Postulates 5-12) are indeed N LJ -equivalent to Postulate 2 (Playfair's postulate). To make sure it holds, it suffices to prove it within the context of the Tarski_2D type class from Tab. I.1.2. Thus we need a definition for an n-ary equivalence relation. We use the following definition using lists:

Definition all_equiv (l : list Prop) := forall x y, In x l -> In y l -> (x<->y).

We chose to define this n-ary equivalence relation as a predicate on list of propositions. This list of propositions contains the equivalent propositions. This predicates expresses that any two propositions in this list are equivalent. It allows us to reduce the proof of the equivalence or the implication between two properties by checking the membership of these properties to a list. The Coq statement corresponding to the equivalence of any two of Postulates 2, 5-12 is the following. In order to lower the number of equivalences to be proven to complete the proof of the previous theorem, we introduced an alternative predicate for n-ary equivalence relation and proved its equivalence with all_equiv. Lemma all_equiv_equiv : forall l, all_equiv l <-> all_equiv' l.

This definition corresponds to the usual technique to prove equivalences that minimize the number of implications to be proved. Indeed, for a list of length n, n implications would suffice. This is much better than the 2n2 implications required from all_equiv. In Coq, it is convenient 10. 11. 12.

7.

8.

6.

5.

2. 9.

Figure II.2.11. Overview of the proofs in Chapter II.2.

to have the two definitions, one for proving that a list of statements are equivalent and the other to use these equivalences.

In practice the all_equiv' definition is also useful to improve the compilation time of our proofs. Indeed, to prove the n-ary equivalence statements, we put in the context all the implications proved previously manually and we let the tautology checker of Coq (tauto) complete the proof. This technique is convenient, but does not scale well when one uses all_equiv and the number of statements is large. Fig. II.2.11 provides a graphical summary of the implications we formalized to prove Theorem 4. On this figure, a circle with a number n in its center represents Postulate n, an arrow between two circles represents an implication, and a double-headed arrow represents an equivalence. One can observe that most of the implications (eight out of fourteen) that we proved involve Postulate 2 (Playfair's postulate). Indeed, since these postulates correspond to properties about diverse subjects, we found that it was more straightforward, when proving the implication between properties about different subjects, to use parallelism as one of the two subjects. Postulate 2 and Postulate 5 (Postulate of transitivity of parallelism) are the only two postulates about parallelism. Moreover, we have proved that the equality of lines is decidable in planar neutral geometry assuming decidability of point equality, while we could only prove the decidability of parallelism assuming Postulate 5. Therefore, Postulate 2 can be proved by contradiction, whereas Postulate 5 cannot unless we find a proof of the decidability of parallelism valid in planar neutral geometry. Indeed, unless the conclusion is known to be decidable, one cannot use a proof by contradiction to derive it, because the proof by contradiction is not valid in an intuitionistic setting. We should point out that, in the definition of parallelism, the fact that the lines do not meet can be proved by proof of negation,1 while the rest of this definition can be proved by contradiction. However, proving the parallelism in such a way is more tedious than proving the equality of lines by contradiction. This explains why Postulate 2 has such a central role in the formalization of Theorem 4. Thus we only proved implications between properties about the same subject, such as the alternate interior angles postulate and the consecutive interior angles postulate, besides these eight implications.

With a view to keeping a good balance between mathematical aspects, formalization aspects, and explanations, we decided to focus on only one implication which illustrates the impact of working in an intuitionistic setting rather than a classical one. The reader who is interested in the proofs of the implications can find some of them in the literature. 2 In [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF], there is a proof of the implication from Postulate 2 to Postulate 5 (Satz 12.15). In [START_REF] Beeson | Constructive Geometry and the Parallel Postulate[END_REF], the implication from Postulate 2 to Postulate 7 (Lemma 6.6) as well as the implication from Postulate 2 to Postulate 5 (Lemma 6.8) are proved. Finally, in [START_REF] Edward | The Foundations of Geometry and the Non-Euclidean Plane[END_REF], proofs of the equivalence between Postulate Let us now focus on the proof of the implication from Postulate 6 (Midpoint converse postulate) to Postulate 2 (Playfair's postulate). In order to present the proof that we formalized, we collect the lemmas that are used throughout this proof. We believe it is important to list these lemmas, since we saw that it often happens that a statement is valid in neutral planar geometry and that its converse is equivalent to the parallel postulate. By detailing these lemmas and only deriving new facts from the application of these lemmas in our proofs, we make sure we do not implicitly apply a statement equivalent to the parallel postulate, unless we have proved it to follow from the statement from which we are proving a consequence. However, we chose not to include trivial lemmas which state permutation properties of the predicates (e.g. AB CD ⇒ CD AB). We also decided to omit lemmas allowing to weaken a statement (e.g. AB s CD ⇒ AB CD). Besides, one problem one encounters with Tarski's system of geometry is the fact that there is no primitive type line. Therefore, when considering a line, one represents it by two different points. This implies that we need a lemma such as C = D ⇒ AB CD ⇒ Col C D D ⇒ AB CD . This kind of lemma are easily proven in neutral geometry. Moreover, the proofs of collinearity can be automated by a reflexive tactic that we describe in the next part. Therefore we simply use them implicitly, as one would do in a pen-and-paper proof.

Lemma 18 (6.21). Two points are equal if they are at the intersection of two different lines.

Lemma 19 (7.17). There is only one midpoint to a given segment.

Lemma 20. 3 We wish to prove that B 1 , B 2 , C 1 and C 2 are collinear, given that

A 1 A 2 B 1 B 2 , A 1 A 2 C 1 C 2 , Col P B 1 B 2 and Col P C 1 C 2 (Fig. II.2.12
). We can first eliminate the cases where line A 1 A 2 is equal to B 1 B 2 and/or C 1 C 2 . Indeed, if all three lines are equal, we are trivially done, and if two lines are equal and strictly parallel to the third one, then we may also conclude, as we can also prove that this last case is impossible because the lines meet in P . So we may now assume

A 1 A 2 s B 1 B 2 and A 1 A 2 s C 1 C 2 .
We can then construct the symmetric point X of A 1 with respect to P using Lemma 15. Now we prove that there exists a point B 3 on line B 1 B 2 which is strictly between A 2 and X. We know that P is either different from B 1 or from B 2 , as otherwise it would contradict A 1 A 2 s B 1 B 2 . Let us prove the existence of the point B 3 by using Lemma 20 in the triangle A 1 A 2 X with either line P B 1 or P B 2 , depending on whether P is distinct from B 1 or B 2 . We prove the hypotheses of this lemma in the same way in both cases, so let us only consider the case where P and B 1 are distinct. The hypotheses ¬ Col A 2 P B 1 and ¬ Col A 1 X B 1 can be proven by proof of negation. Indeed, assuming Col A 2 P B 1 would contradict A 1 A 2 s B 1 B 2 , and assuming Col A 1 X B 1 would contradict P = B 1 , as these two points would be on lines P A 1 and P B 1 and Lemma 18 would imply that they are equal. Finally, B 3 cannot be between A 1 and A 2 , as assuming

A 1 B 3 A 2 would contradict A 1 A 2 s B 1 B 2 .
Hence, Lemma 20 lets us derive the existence of the point B 3 on line B 1 B 2 which is strictly between A 2 and X. In the same way, we can prove there exists a point C 3 on line C 1 C 2 which is strictly between A 2 and X. Now, it suffices to prove that B 3 and C 3 are equal, as it implies that B 1 , B 2 , C 1 and C 2 are collinear. From Postulate 6 and Lemma 19, we know that they both are the midpoint of the segment A 2 X and are therefore equal. This completes the proof.

The proof of Proposition 2, while being simple, illustrates the impact of working in an intuitionistic setting rather than a classical one. Indeed, in this proof we assert the existence of points at the intersection between two lines, namely the points B 3 and C 3 . Since we do not assume Axiom 1 (decidability of intersection of lines), these points can be proved to exist without reasoning by cases on the possibility for some lines to intersect. However, it often happens that, in a proof, the existence of a point at the intersection between two lines is derived by contradiction, rendering it only valid in a classical setting. Thus, with a view to prove Theorem 4, we had to be very careful not to employ such arguments.

CHAPTER II.3

Postulates Equivalent to Tarski's Parallel Postulate

This chapter follows the same outline to that used in the previous chapter. First, we present the postulates which are N LJ -equivalent to Postulate 1 (Tarski's parallel postulate), together with the necessary definitions. Second, we discuss the formalization of the equivalence proofs.

Statements of Postulates Equivalent to Tarski's Parallel Postulate

We introduce here eight new postulates. All are N LJ -equivalent to Tarski's parallel postulate. Three pairs among these eight postulates could appear to be quite similar. Two of these pairs even express a seemingly analogous property, or so it would seem. We examine the slight differences which, while considering a pair of these postulates, render unclear whether one is stronger, equivalent or weaker than the other one. These postulates correspond to properties about parallelism, intersection, perpendicularity, triangles or angles. As in the previous chapter, the subjects of these postulates are widely different. The first of these postulates (Fig. II.3.1) is known as Proclus' postulate. It asserts that if a line intersects one of two parallel lines, then it intersects the other. One can remark that this statement is the contrapositive of Postulate 5 (the postulate of transitivity of parallelism). It is constructively stronger than its contrapositive, which follows from the fact that in intuitionistic logic, an implication is not equivalent to its contrapositive. In fact, only one of the implications remains valid when dropping the law of excluded middle, namely (P ⇒ Q) ⇒ (¬Q ⇒ ¬P ).

Postulate 13 (Proclus' postulate).

Postulate 14 (Alternative Proclus' postulate).

Definition alternative_proclus_postulate :

= forall A B C D P Q, Perp2 A B C D P -> Col A B P -> ˜Col A B Q -> exists Y, Col P Q Y /\ Col C D Y.
This postulate (Fig. II.3.2) is a special case of Postulate 13. Compared to it, Postulate 14 presents the same modifications as the one we applied to Postulate 2 (Playfair's postulate) to obtain Postulate 12 (Alternative Playfair's postulate). Therefore we decided to name it alternative Proclus' postulate. We recall that there may be more than one parallel to a given line passing by a given point. Thus considering a particular one can be more convenient. We would like to stress that this postulate, unlike the next postulates which resemble another previously defined postulate, really is just defined as a mean to ease some proofs of implication. 3) is referred to as triangle circumscription principle in [START_REF] Beeson | Constructive Geometry and the Parallel Postulate[END_REF]. It states that for any three non-collinear points there exists a point equidistant from them. This version was originally used by Szmielew as an axiom, but later Schwabhäuser chose Postulate 1 (Tarski's parallel postulate) over it [START_REF] Beeson | Constructive Geometry and the Parallel Postulate[END_REF]. This postulate was the triggering factor for this study. Indeed, we used this version of the parallel postulate to obtain the arithmetization of Euclidean geometry, since we could derive Axiom 1 (the decidability of intersection of lines) from it. Thus we wanted to investigate whether or not the same could be done with Tarski's parallel postulate. Postulate 16 (Inverse projection postulate). This postulate (Fig. II.3.4) expresses that, for any given acute angle, any perpendicular raised from a point on one side of the angle intersects the other side. It is designated as inverse projection postulate. It is interesting to notice that although this postulate belongs to the strongest class of postulates that we consider, a modification of its statement (Postulate 31) would render it much weaker to the point that it would belong to the weakest class of postulates that we consider. It could seem like it trivially implies Postulate 1 (Tarski's parallel postulate). Indeed, one could think it suffices to construct the orthogonal projection of the considered point on the bisector of the angle (which makes an acute angle with both sides of the angle) and, with the inverse projection postulate, to assert the existence of a point on each side of the angle which is collinear with these two points. However, betweenness properties required in the statement of Postulate 1 would not be satisfied, and one would not be able to prove the implication in such a fashion.

Postulate 15 (Triangle circumscription principle).

Definition inverse_projection_postulate := forall A B C P Q, Acute A B C -> Out B A P -> P <> Q -> Per B P Q -> exists Y, Out B C Y /\ Col P Q Y.
The next postulates that we present were introduced by Beeson in [START_REF] Beeson | Constructive Geometry and the Parallel Postulate[END_REF]. In this paper, Beeson uses strict betweenness, similarly to Hilbert. Since we assume the axioms of Tarski's system of geometry, in which the betweenness is non-strict, we need to define the strict betweenness.

Definition BetS A B C : Prop := Bet A B C /\ A <> B /\ B <> C.
In [START_REF] Beeson | A Constructive Version of Tarski's Geometry[END_REF], Beeson mentions that the strict and non-strict betweenness "are interdefinable (even constructively)". We adopted his definition of the strict betweenness in terms of the nonstrict betweenness. One can remark that, since we assumed the decidability of point equality, in case we would have had to define the non-strict betweenness in terms of the strict betweenness, we could have adopted a simpler version of Beeson's definition. Actually, he applies Gödel-Gentzen translation to the formula that we would have chosen to obtain a constructively valid definition. "If a straight line falling on two straight lines make the interior angles on the same side less than two right angles, the two straight lines, if produced indefinitely, meet on that side on which are the angles less than the two right angles." He reads "make the interior angles on the same side less than two right angles" into line P U being in the interior of the angle ∠QP R while lines P R and QS make consecutive interior angles 1 with P Q equal to two right angles. Seeing that, in neutral planar geometry, making consecutive interior angles equal to two right angles is the same as making alternate interior angles equal, he uses this equivalent statement. In his definition, given that the two straight lines that make alternate interior angles equal are P R and QS, he formulates it as the quadrilateral P RQS having its diagonals meeting in their midpoint. Yet, it is not obvious that a quadrilateral having its diagonals meeting in their midpoint means that their opposite sides make alternate interior angles equal. This property follows from Satz 7.13 of [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF], which is provable in neutral planar geometry and uses the definition of angle congruence. [START_REF] Beeson | Constructive Geometry and the Parallel Postulate[END_REF], results of the modification of Euclid 5. Both its hypotheses and its conclusion are weaker compared to it. The point U defined in the previous postulate is not supposed to lie inside one of the considered alternate interior angles, but to lie outside line P R. That is, the interior angles on the same side are no longer required to make less than two right angles, but prevented to sum exactly to two right angles. Moreover, the strict betweenness predicates in the conclusion are replaced by collinearity predicates. That is, the two straight lines making interior angles which do not sum to two right angles are asserted to meet without any indication on the side of this intersection. Finally, contrary to Postulate 17, the lines P R and SQ can be equal. This hypothesis was crucial for Postulate 17 as it avoids the case where P = U , in which the postulate is false. Because both the hypotheses and the conclusion are weaker compared to Euclid 5, it is not evident whether these modifications render the strong parallel postulate stronger than Euclid 5, equivalent, or weaker.

We could have chosen to define A B C as

A B C ∨ A = B ∨ B = C, while he defines it ¬ (¬A B C ∧ A = B ∧ B = C).

Postulate 18 (Strong parallel postulate).

To have a more faithful version of Euclid's parallel postulate we introduced a variant of Postulate 17 (Euclid 5). For this sake, we stated this variant in terms of sum of angles. We first introduce a variant of Postulate 18 (Strong parallel postulate) stated in terms of sum of angles. In the same fashion as for the triangle postulate, the fact that the interior angles on the same side do not sum to exactly two right angles is formulated as this sum not being equal to a straight angle. Furthermore, one can notice that, compared to the previous postulate, the lines AB and CD, which correspond to the lines P R and QS, are not equal. This is a due to the hypothesis stating that A and D are on the same side of line BC. Nonetheless, since in the axiom system we adopted, the degenerate case of this statement is trivial and the line equality is decidable, this difference does not impact the possibility for these two postulates to be equivalent.

Postulate 19 (Alternative strong parallel postulate).

Definition alternative_strong_parallel_postulate :

= forall A B C D P Q R, OS B C A D -> SumA A B C B C D P Q R -> ˜Bet P Q R -> exists Y, Col B A Y /\ Col C D Y.
To define a variant of Euclid 5 making an explicit use of the concept of sum of angles, we need to be able to characterize the property for two angles to make less than two right angles. Incidentally, a property very similar to this one is essential when considering the sum of angles. According to Rothe [START_REF] Rothe | Several Topics from Geometry[END_REF], if this property is not satisfied, the considered angles cannot be added, because "the sum would be an over-obtuse angle". In fact, the sum of angles is neither an order-preserving function nor an associative function when some of the considered sums correspond to over-obtuse angles. For example, 160 • = (20

• + 170 • ) + 30 • = 20 • + (170 • + 30 • ) = 180 • . Definition SAMS A B C D E F := A <> B /\ (Out E D F \/ ˜Bet A B C) /\ exists J, CongA C B J D E F /\ ˜OS B C A J /\ ˜TS A B C J.
The name of this predicate is the abbreviation for sum at most straight. Two angles ∠ABC and ∠DEF do not make an over-obtuse angle if there exists a point J such that C B J = D E F , the angles ∠ABC and ∠CBJ are adjacent and the angle ∠ABJ is not an over-obtuse angle. As for the definition of sum of angles (SumA), we specified that angles ∠ABC and ∠CBJ are adjacent by the fact that A and J are not on the same side of line BC, to do without the disjunction of cases between the cases where at least one of the angles is degenerate and the case where both angles are non-degenerate and A and J are on opposite sides of line BC. Interestingly, by formalizing straightforwardly "do not make an over-obtuse angle", one also avoids such a disjunction of cases. This predicate almost corresponds to property for two angles to make less than two right angles. It just does not exclude the case where the two angles make exactly two right angles. Analogously to the predicates for order relations on segments and angles, it is straightforward to exclude this case. ) being intended as a more faithful version of Euclid's parallel postulate, we refer to it as Euclid's parallel postulate. One can notice that, compared to Postulate 17 (Euclid 5), the strict betweenness predicates in the conclusion are replaced by Out predicates (we recall that Out B A Y expresses that Y belongs to the ray BA). This weakening of the conclusion is due to the fact that, in this version, we state the hypothesis that the considered lines "make the interior angles on the same side less than two right angles" without referring to an angle in which one of these lines lies, namely P U being in the interior of the angle ∠QP R in the definition of Postulate 17. Since lying in an angle was expressed in terms of betweenness, it allowed us to be more precise regarding the position of the intersection of the considered lines. This statement is really close to the three previous postulates. However, once more, since both its hypotheses and 18. 15. 1. 17.

Postulate 20 (Euclid's parallel postulate).

20.

19.

16.

14.

13. 10. 11. 12.

7.

8.

6.

5.

2. 9.

Figure II.3.9. Overview of the proofs in Chapter II.3. its conclusion are either stronger or weaker than the ones of these three postulates, it is not obvious that they are equivalent.

Formalizing the Equivalence Proof

This section is dedicated to the formalization of the proof that the postulates of the previous section (Postulates 13-20) are indeed N LJ -equivalent to Postulate 1 (Tarski's parallel postulate) as well as the formalization of the proof that the postulates in Chapter II.2, Section 1 and Chapter II.3, Section 1 are indeed N LK -equivalent to Postulate 2 (Playfair's postulate) and Postulate 1 (Tarski's parallel postulate). As in the previous proof of equivalence, these equivalences are proved in the context of the Tarski_2D type class from Tab. I.1.2. The Coq statement corresponding to the N LJ -equivalence of any two of Postulates 1, 13-20 is the following. A graphical summary of the implications that we formalized to prove Theorem 5 is displayed on Fig. II.3.9. The circles around Postulates 2, 5-12 and around Postulates 1, 13-20 mean that the postulates inside these circles are N LJ -equivalent. One could think that Postulate 1 does not imply Postulate 15 (the triangle circumscription principle) in an intuitionisctic logic. Indeed, in order to prove this implication, we proved that Postulate 1 implies Postulate 2, which implies Postulate 9 (the perpendicular transversal postulate), itself implying Postulate 15.

In fact, even if Postulate 9 (N LJ -equivalent to Postulate 2) does not imply Postulate 15 (equivalent to Postulate 1) in an intuitionisctic logic, we know from Proposition 1 that the decidability of intersection of lines (Axiom 1) follows from Postulate 18, which itself follows from Postulate 1. Furthermore, Proposition 3 demonstrates that, in an intuitionisctic logic, assuming Axiom 1 is enough to prove that Postulate 9 implies Postulate 15.

The implications displayed on In an earlier version of this work, we were proving directly that Postulate 17 (Euclid 5) implies Postulate 18 (the strong parallel postulate). The idea behind this proof was to add an extra hypothesis in Postulate 18, namely that the points P , Q, R and U are coplanar. The motivation behind this idea was double. First, this extra hypothesis is necessary in spaces of dimension higher than two. Second, we could then reason by distinction of cases on the twenty-seven possibilities for these points to be coplanar. This distinction of cases was allowing us to know to which side of lines P R and P S the point U belongs. So we were left with four cases corresponding to the four parts of the plane to which all the considered points belong. We could then use Pasch's axiom in all of these cases to construct a point permitting to apply Postulate 17 and complete this proof.

We already mentioned that Postulate 1 is valid in spaces of dimension higher than two. This is due to the fact that all the points in its statement are coplanar. Therefore the extra hypothesis that we added to Postulate 18 was not altering the possibility to prove that Postulate 1 follows from it. Because Postulate 1 was the only postulate that was proved to directly follow from Postulate 18, we could then prove that this modified version was equivalent to the postulates of Chapter II.3.

This proof was really tedious, even though we could slightly simplify it when we proved that, in the context of planar neutral geometry with decidable point equality, the upper two-dimensional axiom was equivalent to the fact any four points are coplanar. In doing so, we were in fact proving the "two-sides" principle from [START_REF] Beeson | Constructive Geometry and the Parallel Postulate[END_REF] without relying on Axiom 1. This principle asserts that two points A and B not on a line l are either on the same side of l or on opposite sides of l. We would like to stress that this demonstrates a profound difference between the axiom system we adopted and Beeson's modification of Tarski's axioms [START_REF] Beeson | A Constructive Version of Tarski's Geometry[END_REF] to which the results of [START_REF] Beeson | Constructive Geometry and the Parallel Postulate[END_REF] apply. Indeed, according to Theorem 10.3 from [START_REF] Beeson | Constructive Geometry and the Parallel Postulate[END_REF], the "two-sides" principle is not provable. Therefore this proof could not be done in his system, which is why he proved that Postulate 17 implies Postulate 18 by showing that "Euclid 5 suffices to define coordinates, addition, multiplication, and square roots geometrically".

In the current version of this work, this proof is not present anymore. Indeed, when we started to consider Postulate 19 (the alternative strong parallel postulate) and Postulate 20 (Euclid's parallel postulate) we realized that it was straightforward to prove not only the implication from Postulate 17 to Postulate 20 but, more surprisingly, also the one from Postulate 20 to Postulate 19. This is a result of the fact we started to consider these postulates after the development of a small library for the sum of angles which proved very useful for this proof. Moreover, the proof that Postulate 19 implies Postulate 18 was also not as cumbersome as the proof of the implication from Postulate 17 to Postulate 18. As a matter of fact, we had already proved that Postulate 13 (Proclus' postulate). implies Postulate 18 and we found a proof of the implication from Postulate 19 to Postulate 13 which was quite direct to formalize. The major idea behind this proof was to use two intermediary steps, namely Postulate 16 (the inverse projection postulate) and Postulate 14 (Alternative Proclus' postulate). The purpose of using these postulates as an intermediary steps was that they feature hypotheses which could be translated into each other with ease. This highlights a central issue when working with parallel postulates: the variety of the properties which are used to state the different postulates. When proving the equivalence between parallel postulates, one should be careful to which implication one proves, since the difficulty to translate one property into another is far from being constant.

Similarly to the previous chapter we only focus on a single proof, namely Proposition 3. We chose to focus on this proofs because it is the only implication that involve Axiom 1 (besides Proposition 1 proved in the previous part). Unlike the previous chapter, up to our knowledge, the only synthetic and intuitionistic proof in this chapter which can be found in the literature is the implication from Postulate 1 to Postulate 17. This implication is proved in [START_REF] Beeson | A Constructive Version of Tarski's Geometry[END_REF] (Theorem 8.3). In order to present the proof of Proposition 3, we collect two lemmas that are used throughout this proof.

Lemma 21. Given two distinct points, their perpendicular bisector is constructible.

Lemma 22 (12.9). Two lines perpendicular to the same line are parallel.

The following proposition is a classic, but we still give the proof, because we are in a intuitionistic setting and we want to emphasize the use of the decidability of intersection.

Proposition 3. Axiom 1 (decidability of intersection of lines) and Postulate 9 (perpendicular transversal postulate) imply Postulate 15 (triangle circumscription principle).

Proof. Given a non-degenerate triangle ABC we wish to prove the existence of point C C equidistant to A, B and C (Fig. II.3.10). Lemma 21 lets us construct the perpendicular bisector C 1 C 2 of the segment AB and the perpendicular bisector B 1 B 2 of the segment AC, since they are non-degenerate segment as ABC is a non-degenerate triangle. We now prove that it is impossible for lines B 1 B 2 and C 1 C 2 to not intersect to prove the existence of this intersection.2 Assuming they do not intersect, then lines B 1 B 2 and C 1 C 2 are parallel by definition. Using the perpendicular transversal postulate we can deduce that lines AC and C 1 C 2 are perpendicular. Finally Lemma 22 establishes that lines AB and AC are parallel as they are both perpendicular to line C 1 C 2 . This implies that A, B and C are collinear, which is false by hypothesis. Since it is impossible for lines B 1 B 2 and C 1 C 2 to not intersect, Axiom 1 lets us assert that C c is their intersection point, which is equidistant from A and B since it belongs to its perpendicular bisector and equidistant from A and C since it belongs to its perpendicular bisector.

Postulates Equivalent to the Triangle Postulate

The same structure that was used in the previous two chapters is used throughout this one. First, we present the postulates which are N LJ -equivalent to Postulate 3 (the triangle postulate), together with the necessary definitions. Second, we discuss the formalization of the equivalence proofs.

Statements of Postulates Equivalent to the Triangle Postulate

This section study ten new postulates. All are N LJ -equivalent to the triangle postulate. One, namely Postulate 21, is very similar to Postulate 3 (the triangle postulate) but one could wrongly think it is strictly weaker than it. Furthermore, three pairs of postulates present the same kind of similarity. Despite these resemblance, the subjects of these postulates are again mostly heterogeneous. In fact, these postulates affirm properties about triangles, equidistant lines, circles and quadrilaterals. These two postulates correspond to trivial consequences of Postulate 3 and Postulate 11 (the universal Posidonius' postulate). Indeed their definitions are nearly the same as those of these last two postulates. Postulate 21 expresses that there exists a triangle whose angles sum to two rights and Postulate 22 expresses that there exists two lines which are everywhere equidistant. They mainly differ in the type of quantifiers used for some of the considered points in these postulates: they replace some of the universal quantifiers by existential ones. Postulate 3 and Postulate 11 are also more general and can be instantiated to cases which are provable in planar neutral geometry. So Postulate 21 and Postulate 22 add non-degeneracy conditions. For example, in the case of the former one adds that the triangle whose angles sum to two rights is non-flat. The latter is particularly interesting because it represents one of the only two postulates1 which is not N LJ -equivalent to its universally quantified version. In this chapter, we consider three more pairs of postulates differing in the type of quantifiers, and all of them are N LJ -equivalent. Furthermore, Playfair's postulate is proved to be equivalent to the existence of a point and line for which there is a unique parallel line passing through the point in [START_REF] Amira | Sur l'axiome de droites parallèles[END_REF]. However, we did not formalize this proof since it requires the space to be of dimension higher than two. Indeed, it relies on the existence, for any given plane, of a point not incident to it. The same theorem has also been proven synthetically by Piesyk [START_REF] Piesyk | The existential and universal statements on parallels[END_REF], but his proof needs decidability of intersection of lines. : "To every figure there exists a similar figure of arbitrary magnitude". It asserts that there exists two similar but non-congruent triangles. Wallis assumed this postulate in order to prove Euclid's parallel postulate [START_REF] Bonola | Non-Euclidean Geometry: A Critical and Historical Study of Its Development[END_REF] but could have instead assumed Postulate 23. This postulate was also assumed by Laplace [START_REF] Cajori | A History of Elementary Mathematics[END_REF]. Moreover, Gauss produced a proof of Euclid's parallel postulate under the assumption of the existence of a right triangle whose area is greater than any given area [START_REF] Parthenia | History of the Parallel Postulate[END_REF].

Postulate 21 (Postulate of existence of a triangle whose angles sum to two rights) and Postulate 22 (Posidonius' postulate).

Postulate 23 (Postulate of existence of similar but non-congruent triangles).

Definition postulate_of_existence_of_similar_triangles :

= exists A B C D E F, ˜Col A B C /\ ˜Cong A B D E /\ CongA A B C D E F /\ CongA B C A E F D /\ CongA C A B F D E. D A F B C E C D A F B E
"Zwar bin ich auf manches gekommen, was den meisten schon für einen Beweis geltend würde, aber was in meinen Augen sogut wie Nichts beweiset, z. B. wenn man beweisen könnte dass ein geradlinigtes Dreieck möglich sei, dessen Inhalt grösser wäre als eine jede gegebne Fläche, so bin ich im Stande die ganze Geometrie völlig streng zu beweisen."2 -Carl Friedrich Gauss [START_REF] Friedrich | Briefwechsel zwischen Carl Friedrich Gauss und Wolfgang Bolyai[END_REF] It is unclear if the right triangle is required to be similar to another given right triangle. If so,3 and it is probable considering this sentence was part of an informal letter from Gauss to Bolyai, Gauss' assumption would be a special case of Wallis' postulate. One should point out that, even though the formalization of this postulate is straightforward, the triangles need to be non-flat, as the non-degeneracy conditions are often omitted in geometry texts.

Postulate 24 (Thales' postulate) and Postulate 25 (Thales' converse postulate) and Postulate 26 (Existential Thales' postulate).

Definition thales_postulate :

= forall A B C M, ˜Col A B C -> Midpoint M A B -> Cong M A M C -> Per A C B. Definition thales_converse_postulate := forall A B C M, ˜Col A B C -> Midpoint M A B -> Per A C B -> Cong M A M C. Definition existential_thales_postulate := exists A B C M, ˜Col A B C /\ Midpoint M A B /\ Cong M A M C /\ Per A C B.
Here we discuss simultaneously Postulate 24, Postulate 25 and Postulate 26, because the second one is the converse of the first one. Moreover, the third one corresponds to the result of replacing, in the first or second one, the universal quantifiers by existential ones, and the implication between the We now focus on a postulate due to Saccheri, who made "the most elaborate attempt to prove the 'parallel postulate' " according to Coxeter [START_REF] Scott | Non-Euclidean Geometry[END_REF] and was "perhaps before its time" [START_REF] Hartshorne | Geometry : Euclid and beyond[END_REF]. In his attempt to prove Euclid's parallel postulate, he considered a specific kind of quadrilaterals which have since been named after him. These quadrilaterals arise when one studies points that are equidistant to a line. Indeed, S A B C D is a quadrilateral such that the angles at A and D are right and AB ≡ CD (Fig. II.4.3). Still, one needs to add the fact that B and C are on the same side of line AD. 4 Saccheri's investigation of such quadrilaterals was influenced by Clavius' work about Postulate 11 [START_REF] Hartshorne | Geometry : Euclid and beyond[END_REF]. He considered three cases for these quadrilaterals, when the remaining angles are either acute, right or obtuse, known as Saccheri's three hypotheses. He was meaning to prove Euclid's parallel postulate by eliminating the hypotheses of the acute and obtuse angle. As we see in the next chapter, in Archimedean neutral geometry, one can eliminate the hypothesis of the obtuse angle. Nonetheless, one cannot eliminate the hypothesis of the acute angle, which corresponds to hyperbolic geometry. Postulate 27 expresses that the hypothesis of the right angle holds and Postulate 28 expresses that there exists a right Saccheri quadrilateral. The last postulates that we analyze in this chapter are closely related to Saccheri quadrilaterals. Indeed, they regard quadrilaterals that were also studied by Saccheri, though they are named after Lambert [START_REF] Jay | Old and New Results in the Foundations of Elementary Plane Euclidean and Non-Euclidean Geometries[END_REF]. Lambert proceeded in the same way as Saccheri in his attempt at proving Euclid's parallel postulate, namely, disproving the obtuse case and trying to derive a contradiction from the acute case [START_REF] Jay | Euclidean and Non-Euclidean Geometries -Development and History[END_REF]. Postulate 29 and Postulate 30 state, respectively, that all Lambert quadrilaterals are rectangles and that there exists a rectangle. One could think that this postulate is close to Postulate 4 (Bachmann's Lotschnittaxiom), but Postulate 4 asserts the existence of an intersection point, while Postulate 29 states the perpendicularity of two lines known to intersect.

Formalizing the Equivalence Proof

In this section, we address the formalization of the proof that the postulates of the previous section (Postulates 21-30) are indeed N LJ -equivalent to Postulate 3 (the triangle postulate), as well as the N G LJ -equivalence between Postulate 3 and Postulate 2 (Playfair's Postulate). Exactly like in the previous proofs of equivalence, these equivalences are proved in the context of the Tarski_2D type class from Tab. I.1.2. The Coq statement corresponding to the N LJ -equivalence of any two of Postulates 3, 21-30 is the following. One can remark, from the graphical summary of the implications we proved (Fig. II.4.5), that Postulate 27 (the postulate of right Saccheri quadrilaterals) plays a very central role. There is a simple explanation for it: most of these proofs correspond to the formalization of the proofs of some of Saccheri's propositions given in [START_REF] Edward | The Foundations of Geometry and the Non-Euclidean Plane[END_REF]. In this book, Martin establishes equivalences between each of Saccheri's three hypotheses and whether certain angles are acute, right or obtuse. Most of these implications follow easily from these propositions. In order to formalize Martin's proofs, we often proceeded by disjunction of cases on Saccheri's three hypotheses. One should point out that, because case distinctions cannot be performed in existence proofs in Beeson's modification of Tarski's axioms [START_REF] Beeson | A Constructive Version of Tarski's Geometry[END_REF], some of the proofs we mechanized would not be valid in his axiomatic system.

We can now consider the visual representation of all the implications that we formalized to prove Theorem 6 (Fig. Lastly, we detail one proof and compare another one to the pen-and-paper proof from which it is inspired. 5 Both of these proofs illustrate one of the main difference between a theoretical proof and the actual Coq proof, namely dealing with non-degeneracy conditions and betweenness properties. This difference represents one of the main difficulties that one encounters while formalizing a proof in synthetic geometry. These proofs allow us to study the impact of using the tactics developed in [START_REF] Boutry | Using small scale automation to improve both accessibility and readability of formal proofs in geometry[END_REF] 6 as well as their limitations. The proof we have chosen to study is the fact that Postulate 7 (the alternate interior angles postulate) implies Postulate 3 (the triangle postulate). The pen-and-paper proof is short:

Let ABC be a triangle, construct the parallel to AC through B (Fig. II.4.7).

Then, the two pairs of alternate interior angles displayed on the figure are congruent, and hence the sum of the three angles is the straight angle. Now, we compare this argument with the formal proof as formalized in Coq. In order to present the rigorous proof of Proposition 4, we collect five lemmas that are used throughout this proof. Lemma 26. 8 A given angle can be laid off upon a given side of a given ray.

Lemma 27 (12.21 9 ). If two lines share a common transversal which makes a pair of alternate angles equal to one another, then the two lines are parallel. Now, we give in natural language the proof at the level of details needed for the formalization. 5 These proofs have already been presented in French [START_REF] Gries | Somme des angles d'un triangle et unicité de la parallèle : une preuve d'équivalence formalisée en Coq[END_REF]. 6 We describe the tactic which was used most often throughout these proofs in the next part. 7 Usually in geometry, we give two different constructions for the perpendicular to a given line in a given point, whether the given point lies on the given line or not. If it does, we "erect" a perpendicular at this given point, and if it does not, we "drop" a perpendicular from this given point to this given line. 8 This corresponds to the fourth axiom of Group IV from [START_REF] Hilbert | Foundations of Geometry (Grundlagen der Geometrie[END_REF]. 9 This lemma represents only the part that is valid in neutral planar geometry.

two right angles, such as the one given by Amiot [START_REF] Amiot | Éléments de géométrie : rédigés d'après le nouveau programme de l'enseignement scientifique des lycées; suivis d'un Complément à l'usage des élèves de mathématiques spéciales[END_REF].10 In Amiot's proof, the fact that the angles ∠CAB and ∠ABB 2 are alternate interior angles, HTS2 in the Coq proof, is stated without a proof. This lack of justification for the relative position of the points on the figure is a critique that the modern commentators of Euclid's Elements often make about Euclid's proofs. However, Avigad et al. [START_REF] Avigad | A formal system for Euclid's elements[END_REF] claim that these gaps can be filled by some automatic procedure, justifying in some sense the gaps in Euclid's original proofs. This is where we reach the limits of our tactics: they only handle incidence problems, permutation properties and compute the consequences of the negation of the non-degeneracy conditions, but do not provide this kind of justification. Therefore, it would be very useful to have an implementation in Coq of the procedure proposed in [START_REF] Avigad | A formal system for Euclid's elements[END_REF] and implemented in the E Proof Checker [START_REF] Northrop | Automated Diagrammatic Reasoning[END_REF].

Our proof that Axiom 4 and Postulate 3 imply Postulate 12 is inspired from the one Greenberg gives in [START_REF] Jay | Old and New Results in the Foundations of Elementary Plane Euclidean and Non-Euclidean Geometries[END_REF]. Nevertheless, we needed to make two modifications to his proof. The first one is due to the fact that we used a different definition for a point belonging to an angle, as we explained in Chapter II.1, Subsection 2.3. The other modification that we made is due to the use of a proof assistant: because of it we cannot skip the justification for the relative position of the points on the figure.

Postulates Equivalent to Bachmann's Lotschnittaxiom and the Role of Archimedes' Axiom

This chapter is devoted to the role of Archimedes' axiom: we study the implications of assuming this property. First, we provide a proof of the independence of Archimedes' axiom from the axioms of Pythagorean planes.1 Then we introduce three postulates which we prove N LJ -equivalent to Postulate 4 (Bachmann's Lotschnittaxiom). In order to prove these postulates N A LJ -equivalent to the other postulates we present in this part we introduce a new postulate, which was implicitly assumed by Legendre in one of his attempts to prove Euclid's parallel postulate. Thus we refer to it as Legendre's parallel postulate. Having defined this postulate, we formalize the proofs of Legendre's Theorems. Finally, we present the formalization of a variant of Szmielew's theorem, which opens the path towards a mechanized procedure deciding the equivalence to Euclid's parallel postulate.

A Proof of the Independence of Archimedes' Axiom from the Axioms of Pythagorean Planes

In this section, we first establish the N LJ -equivalence between Axiom 1 (decidability of intersection of lines), Axiom 3 (Aristotle's axiom) and Axiom 4 (Greenberg's axiom) under the assumption that Postulate 2 (Playfair's postulate) holds. From this equivalence, and using a syntactic proof of the independence of Axiom 1, we obtain a proof for the independence of Archimedes' axiom from the axioms of Pythagorean planes which is not based on counter-models. We do not prove in Coq this independence property, because it relies on a proof based on Herbrand's theorem, that we have not formalized.

To demonstrate the equivalence between Axiom 1, Axiom 3 and Axiom 4, we show the implications that are represented on Fig. II.5.1. With a view to simplifying this overview, we use the equivalences proved in the previous chapter to replace any postulate N LJ -equivalent to Postulate 1 by Postulate 1 and similarly for Postulate 2. We already showed that Postulate 1 (Tarski's parallel postulate) is implied by the conjunction of Postulate 2 and Axiom 1 (Proposition 3) and that Postulate 1 implies Axiom 1 (Proposition 1). In [START_REF] Jay | Old and New Results in the Foundations of Elementary Plane Euclidean and Non-Euclidean Geometries[END_REF], Greenberg proves that Axiom 4 follows from Axiom 3, itself following from Postulate 1. Therefore, it remains to show that Postulate 1 can be derived from the conjunction Axiom 4 and Postulate 2. To the best of our knowledge, this proof is new and is therefore detailed. Given two parallel lines AB and CD, P a point on line AB and Q a point not on line AB, we wish to prove that lines CD and P Q intersect (Fig. II.5.2). We first eliminate the case of Col C D P , in which P is the point of intersection. Then we drop a perpendicular from P to line CD, meeting line CD at the foot C 0 , using Lemma 23. Then we can eliminate the case where C 0 lies on P Q, in which C 0 is at the intersection between lines CD and P Q. From Lemma 29 we know that there exist a point Q 1 on line P Q such that A C0Q1 C0Q1 B, as well as the points A 1 and C 1 respectively on lines AB and CD such that P Q1A1 Q1A1 C 0 and P Q1C1 Q1C1 C 0 . We now have that Q 1 ∈ C 0 P A 1 thanks to Lemma 28. Yet we know that ∠C 0 P A 1 is right by an application of Postulate 7, and thus the angle This theorem is quite peculiar because it asserts the equivalence between continuity axioms and a decidability property. Theorem 7 proves this equivalence under the strong assumption that Postulate 2 holds.

∠A 1 P Q 1 is acute. Using Axiom 4, we can construct C 2 such that C 0 C 2 C 1 and P C 2 C 0 < A 1 P Q 1 .

By another application of Postulate 7, we know that

A 1 P C 2 = P C 2 C 0 and thus C 2 ∈ A 1 P Q 1 .
Finally, since Axiom 1 is independent from the axioms of planar neutral geometry to which Postulate 2 is added, we get that both Axiom 3 and Axiom 4 are also independent from these axioms. From the following proposition, 4 we obtain that Archimedes' axiom is also independent from these axioms.

Proposition 6. Axiom 3 (Aristotle's axiom) is implied by Axiom 2 (Archimedes' axiom).

Postulates Equivalent to Bachmann's Lotschnittaxiom

Unlike in the previous three chapters, we mostly just present the postulates which we proved N LJ -equivalent to Bachmann's Lotschnittaxiom 5 (Postulate 4), together with the necessary definitions. Indeed, the most interesting proof, in terms of formalization, is the proof that these postulates are N A LJ -equivalent with the previously defined postulates. Therefore, we focus mainly on the proof of N A LJ -equivalence which is detailed in the next section.

in [START_REF] Hartshorne | Geometry : Euclid and beyond[END_REF], the statement look different but actually is the same, because Hartshorne's definition of a point being inside an angle is based on the two-side predicate, whereas the definition we use (borrowed from [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]) states that the ray BP intersects the segment AC. As suggested by the names of these postulates, they correspond to statements similar to postulates that we studied in Chapter II.3. More precisely, Postulate 31 and Postulate 32 are respectively weaker version of Postulate 16 (the inverse projection postulate) and Postulate 1 (Tarski's parallel postulate).

Postulate 31 expresses that for any angle, that, together with itself, make a right angle, any perpendicular raised from a point on one side of the angle intersects the other side. Compared to Postulate 16, this postulate only adds the hypothesis that the considered angle together with itself make a right angle.

Postulate 32 states that, for every right angle and every point T in the interior of the angle, there is a point on each side of the angle such that T is between these two points. The differences in comparison with Postulate 1 are of two kinds. The first one is analogous to the difference between Postulate 31 and Postulate 16. Precisely, the statement is restricted to a certain kind of angle, namely the right angles. The second one resembles the difference between Postulate 17 (Euclid 5) and Postulate 18 (the strong parallel postulate). Indeed, Postulate 32 is less precise than Postulate 1 regarding the position of the points in the hypotheses, which results in a weaker conclusion.

Before introducing the last postulate we need to introduce a definition asserting that some points belong to the perpendicular bisector of a segment.

Definition ReflectL P' P A B := (exists X, Midpoint X P P' /\ Col A B X) /\ (Perp A B P P' \/ P = P').

Definition Perp_bisect P Q A B := ReflectL A B P Q /\ A <> B.

These predicates correspond to Definition 10.3 of [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. A

P • P P • P
B means that P is the image of P by the reflection with respect to the line AB. It is interesting to see that for ReflectL P' P A B to be true when A and B are equal, one must have that P and P are also equal. To define P

A • B A • B
Q, which expresses that the line P Q is the perpendicular bisector of the segment AB, we can therefore just exclude the case where A and B are equal and state that B is the image of A by the reflection with respect to the line P Q.

Postulate 33 (Weak triangle circumscription principle).

Definition weak_triangle_circumscription_principle :

= forall A B C A1 A2 B1 B2, ˜Col A B C -> Per A C B -> Perp_bisect A1 A2 B C -> Perp_bisect B1 B2 A C -> exists I, Col A1 A2 I /\ Col B1 B2 I.
As for the previous postulates, Postulate 33 presents important similarities with another postulate, namely Postulate 15 (Triangle circumscription principle), although the differences are more substantial. It asserts that the perpendicular bisectors of the legs of a right triangle intersect. Postulate 33 is not only the restriction of Postulate 15 to the case of right triangles. Indeed, Postulate 15 states that for any three non-collinear points there exists a point equidistant from them. As our axioms allow to prove that all points are coplanar, being equidistant from two points is equivalent to belonging to the perpendicular bisector of the segment defined by these two points. However we chose to formalize this postulate using the notion of perpendicular bisector to have a definition which is more faithful to its statement in [START_REF] Edward | The Foundations of Geometry and the Non-Euclidean Plane[END_REF]. Fig. II.5.3 provides a graphical summary of the implications we mechanized to prove Theorem 8. Most of these proofs correspond to proofs found in the literature. In [START_REF] Edward | The Foundations of Geometry and the Non-Euclidean Plane[END_REF], there is the proof of 31.

33.

32.

4.

Figure

Legendre's Theorems

This section is dedicated to one of Legendre's flawed proofs of Euclid's parallel postulate. In this proof he implicitly assumed Legendre's parallel postulate, which we introduce. Following [START_REF] Rothe | Several Topics from Geometry[END_REF], we split this proof into four Legendre's Theorems. There are two statements commonly known as Legendre's theorems, but Rothe mentions four such theorems in [START_REF] Rothe | Several Topics from Geometry[END_REF]. What he refers as Legendre's third theorem and Legendre's fourth theorem correspond to the remaining parts of this flawed proof. Throughout this section, we refer to this proof which we mechanized, while emphasizing on the formalization details.

Let us first present Legendre's parallel postulate. Postulate 34 (Legendre's parallel postulate).

Definition legendre_s_parallel_postulate := exists A B C, ˜Col A B C /\ Acute A B C /\ forall T, InAngle T A B C -> exists X Y, Out B A X /\ Out B C Y /\ Bet X T Y.
This posulate formulates that there exists an acute angle such that, for every point T in the interior of the angle, there is a point on each side of the angle such that T is between these two points. Postulate 34 is pretty similar to Postulate 1 (Tarski's parallel postulate). In fact, Postulate 34 mainly differs from Postulate 1 in two aspects. The first difference comes from the way in which the points A, B and C defining the considered angle are quantified (Fig. II.1.9). In this version of the parallel postulate they are existentially quantified. 6 The second difference is about the relative position of the points, which is more precise in Postulate 1. Here, the same situation as in Postulate 32 (Weak Tarski's parallel postulate) occurs: the point through which goes the line asserted to exist is not required to be further away from B than the segment AC, which results in a 6 One could also notice that they are also specified to form a non-degenerate acute angle. The fact it is acute plays a minor role, contrary to the non-degeneracy condition, because if one can find such an obtuse or right angle, every acute angle inside it fulfills the same properties. weaker conclusion, namely that the line intersects the sides of the angles without any precision with regards to the position of the intersections relatively to A and C.

Let us then consider Legendre's first theorem, which can be stated in the following way.

Theorem 9 (Legendre's first theorem). In Archimedean neutral geometry, the angles of every triangle make less than or equal to two right angles.

Theorem 9 is now known as Saccheri-Legendre theorem, as Saccheri proved this statement almost a century before Legendre. In order to formalize the proof of this theorem as exposed in [START_REF] Edward | The Foundations of Geometry and the Non-Euclidean Plane[END_REF], we introduced a variant of the predicate Grad. Indeed, the theorem that is central for this proof, namely Theorem 22.18, constructs pairs of points that, given two segments, correspond to the endpoints of segments constructed by extending the given segments by their own lengths the same number of times (the A i and B i for 1 ≤ i ≤ n on Fig. II.5.47 ). As our formalization of Archimedes' axiom does not use the concept of natural number, we had to express that the segments are extended the same number of times, using the following inductive predicate. Grad2 A B C D E F intuitively means that there exists n such that AC ≡ nAB and DF ≡ nDE.

Inductive Grad2 : Tpoint -> Tpoint -> Tpoint -> Tpoint -> Tpoint -> Tpoint -> Prop := | grad2_init : forall A B D E, Grad2 A B B D E E | grad2_stab : forall A B C C' D E F F', Grad2 A B C D E F -> Bet A C C' -> Cong A B C C' -> Bet D F F' -> Cong D E F F' -> Grad2 A B C' D E F'.
As often in induction proofs, the difficulty lied in finding the appropriate inductive hypotheses. Moreover, the same difficulties as the ones presented in Chapter II.4 arose. Having mechanized Theorem 22.18 of [START_REF] Edward | The Foundations of Geometry and the Non-Euclidean Plane[END_REF], we could demonstrate Theorem 9. The proposition that we showed is the following.

Theorem legendre_s_first_theorem : archimedes_axiom -> forall A B C D E F, SumA C A B A B C D E F -> SAMS D E F B C A.
We should remark that the hypotheses of this theorem are not minimal. Indeed, Greenberg provides a proof only relying on Axiom 3 (Aristotle's axiom) [START_REF] Jay | Euclidean and Non-Euclidean Geometries -Development and History[END_REF] that we also formalized.

The next theorem has already been proven in Chapter II.4. It asserts that Postulate 21 (the postulate of existence of a triangle whose angles sum to two rights) implies Postulate 3 (the triangle postulate) and can be stated in the following way.

Theorem 10 (Legendre's second theorem). In planar neutral geometry, if the angles of one triangle sum to two right angles, then the angles of all triangles sum to two right angles.

Since Theorem 10 is a corollary of Theorem 6, we just give the Coq statement corresponding to it.

Theorem legendre_s_second_theorem :

postulate_of_existence_of_a_triangle_whose_angles_sum_to_two_rights -> triangle_postulate.

Legendre's next theorem expresses that, assuming Axiom 2 (Archimedes' axiom), Postulate 20 (Euclid's parallel postulate) is a consequence of Postulate 3. It can be formulated in the following manner.

Theorem 11 (Legendre's third theorem). In Archimedean neutral geometry, if the angles of every triangle sum to two right angles, then Euclid's parallel postulate holds.

As for Theorem 9, the hypotheses of Theorem 11 can be weakened: from Theorem 7, we know that Axiom 4 (Greenberg's axiom) suffices to derive the implication from Postulate 3 to Postulate 20. Hence, in order to obtain this theorem, we chose to formalize the proof that Axiom 2 implies Axiom 3 (Aristotle's axiom) (Proposition 6). Let us recall Greenberg's definition of Axiom 3.

"Given any acute angle, any side of that angle, and any challenge segment P Q, there exists a point Y on the given side of the angle such that if X is the foot of the perpendicular from Y to the other side of the angle, then Y X > P Q." Let Y 0 be a point on the given side of the angle and X 0 be the foot of the perpendicular from Y 0 to the other side of the angle (Fig. II.5.5). Then, by letting n 0 be a positive integer such that n 0 Y 0 X 0 > P Q and B be the vertex of the angle, one could assume that Axiom 2 would let us conclude by constructing Y such that n 0 Y 0 B ≡ Y B and dropping a perpendicular from Y on the other side of the angle. Nevertheless, following [START_REF] Edward | The Foundations of Geometry and the Non-Euclidean Plane[END_REF], it is much simpler to choose a positive n such 2 n Y 0 X 0 > P Q and prove that a point Y such that 2 n Y 0 B ≡ Y B would suffice.8 Therefore, we defined the following exponential variant of the predicate Grad.

Inductive GradExp : Tpoint -> Tpoint -> Tpoint -> Prop := | gradexp_init : forall A B, GradExp A B B | gradexp_stab : forall A B C C', GradExp A B C -> Bet A C C' -> Cong A C C C' -> GradExp A B C'.
GradExp A B C intuitively asserts that there exists n such that 2 n AB ≡ AC. Yet the positive integer n is not explicit in our definition, it is hidden in the number of times the constructor gradexp_stab is used. We then proved the equivalence between being reachable using Grad or GradExp to complete the proof of Theorem 11. We now provide its Coq statement.

Theorem legendre_s_third_theorem :

archimedes_postulate -> triangle_postulate -> euclid_s_parallel_postulate.

Finally, the last theorem completes Legendre's flawed proof. It states that, assuming Axiom 2, Postulate 21 (the postulate of existence of a triangle whose angles sum to two rights) is a consequence of Postulate 34 (Legendre's parallel postulate). It can be phrased as follows.

Theorem 12 (Legendre's fourth theorem). In Archimedean neutral geometry, if Legendre's postulate holds, then there exists a triangle for which the angles sum to two right angles.

Theorem legendre_s_fourth_theorem :

archimedes_postulate -> legendre_s_postulate -> postulate_of_existence_of_a_triangle_whose_angles_sum_to_two_rights.

To demonstrate Theorem 12, we mechanized the proof given in [START_REF] Edward | The Foundations of Geometry and the Non-Euclidean Plane[END_REF]. In this proof, a concept that we have not encountered so far plays a major role: the defect of a triangle. For a given triangle, its defect together with the sum of the angles of this triangle make two right angles. Having the concept of sum of angles, it is straightforward to define this concept in Coq.

Definition Defect A B C D E F := exists G H I J K L, TriSumA A B C G H I /\ Bet J K L /\ SumA G H I D E F J K L.
Here, D( ABC) = D E F expresses that ∠DEF is the defect of the triangle ABC. This proof eliminates the hypothesis of acute angle by reproducing a construction. Given the acute angle ∠ABC asserted to exist by Postulate 34 and a pair of point A k and C k respectively on the sides BA and BC, this construction creates the points A k+1 and C k+1 , respectively on the sides BA and BC, such that the defect of the triangle A k+1 BC k+1 is at least the double of the defect of the triangle A k BC k . To conclude its proof, Legendre uses Archimedes' axiom to deduce that repeating this construction leads to a triangle A n BC n which has a defect greater than two right angles. This last step need to be detailed in Coq, as it makes the implicit assumption that Axiom 2 implies the Archimedean property for angles. More precisely, the implicit assumption is that every nondegenerate angle can be doubled enough times to obtain an obtuse angle. Therefore, we defined the following variant of the predicate Grad.

Inductive GradAExp : Tpoint -> Tpoint -> Tpoint -> Tpoint -> Tpoint -> Tpoint -> Prop := | gradaexp_init : forall A B C D E F, CongA A B C D E F -> GradAExp A B C D E F | gradaexp_stab : forall A B C D E F G H I, GradAExp A B C D E F -> SAMS D E F D E F -> SumA D E F D E F G H I -> GradAExp A B C G H I.
Hartshorne (Lemma 35.1 in [START_REF] Hartshorne | Geometry : Euclid and beyond[END_REF]) provides an explicit proof that we formalized. We could then prove Theorem 12. Again, the difficulty lied in finding the appropriate induction hypotheses and justifying the position of the points on the figure. By mechanizing the proof that Postulate 34 can be derived from Postulate 4, which is part of Theorem 23.7 of [START_REF] Edward | The Foundations of Geometry and the Non-Euclidean Plane[END_REF], we obtain the following theorem (Fig. II.5.6 provides a summary of the implications needed for its proof).

Theorem 13. In Archimedean neutral geometry, Postulates 1-34 are equivalent.

Towards a Mechanized Procedure Deciding the Equivalence to Euclid's Parallel Postulate

Another interesting consequence of continuity is a very useful result concerning the parallel postulate, that was established by Szmielew in [START_REF] Szmielew | Some Metamathematical Problems Concerning Elementary Hyperbolic Geometry[END_REF]. It states that "Euclid's axiom can be replaced in the axiom system of E n by any sentence whatsoever which is valid in E n but not in H n ". Here E n denotes Tarski's system of geometry, where A8 and A9 are replaced by the lower n-dimensional axiom and the upper n-dimensional axiom, and H n corresponds to E n where Postulate 1 (Tarski's parallel postulate) A10 is replaced by its negation. Hence this result allows us to prove the equivalence of some statements with Tarski's parallel postulate by checking if it holds in Euclidean geometry and does not in hyperbolic geometry. Moreover, because both of these theories are decidable, this gives a procedure deciding if a statement is equivalent to the parallel postulate. In this section, we formalize a result similar to this and we then discuss the possibility for the mechanization of such a procedure.

In Section 3, we formalized the fact that Postulate 1 is equivalent to Postulate 2 when assuming Archimedes' axiom. With a view to proving this result, we chose to use Postulate 2 in place of Postulate 1. We would like to stress that, while Szmielew obtained her result through metamathematical properties, we present here a synthetic proof, so the choice of the parallel postulate matters. This choice was motivated by the fact that the negation of Postulate 2 was easier to work with. However, her proof is valid in spaces of dimension higher than two, whereas our proof is only valid in planar geometry. Another difference is that her proof assumes the first-order version of the axiom of continuity, while our proof assumes Aristotle's axiom (Axiom 3). We defined the negation of Postulate 2 in the following way. We can point out that this definition (we now refer to it as hyperbolic plane postulate) is in fact the negation of a modification of Postulate 2. This modification expresses the existence of a line and a point not on this line such that there is a unique line parallel to this line passing by this point. This modification was showed to be equivalent with Postulate 2 when assuming Axiom 4 for one of the implications. Because of this, we could not classify this modified version of Postulate 2. This explains why we did not present it in Chapter II.2. We now collect four lemmas which are used in the lemma at the core of this proof. Given three non-collinear points A 1 , A 2 and P we wish to prove that there exists two distinct lines B 1 B 2 and C 1 C 2 both parallel to line A 1 A 2 and passing through P (Fig. II.5.7). Lemma 23 lets us drop the perpendicular from P to line A 1 A 2 in Q. A tedious distinction of cases would then allow us to prove that there exists a point X on line A 1 A 2 distinct from A 1 , A 2 and Q. Lemma 15 lets us construct Y , the symmetric point of X with respect to Q. Using Lemma 30, we construct B 1 and C 1 such that S Q P B 1 X and S Q P C 1 Y . We now prove that both lines B 1 P and C 1 P are parallel to line A 1 A 2 , pass by P , and are distinct. The facts that these lines are parallel to line A 1 A 2 and pass by P are respectively due to Lemma 31 and trivial. We proceed by proof of negation to prove that these lines are distinct. So let us assume that they are equal. We can prove that P Lemma 24 applied twice lets us show our claim. We shall now derive a contradiction by proving that B 1 P C 1 < B 1 P C 1 . Since angles ∠XQP and ∠P QY do not make an over-obtuse angle, making exactly two right angles, it suffices to show that

B 1 P Q < P Q X, Q P C 1 < P Q X, B 1 P Q + Q P C 1 = B 1 P C 1 and P Q X + P Q X = B 1 P C 1 .
We have B 1 P Q < P Q X as well as Q P C 1 < P Q X from the hypothesis of the acute angle and B 1 P Q + Q P C 1 = B 1 P C 1 by definition. Thus we will be done if we can show that P Q X + P Q X = B 1 P C 1 . We trivially have X Q P = P Q X and P Q Y = P Q X. By definition we have

X Q P + P Q Y = X Q Y . So it suffices to prove X Q Y = B 1 P C 1 ,
which holds since straight angles are congruent.

Let us state our variant of Szmielew's theorem. We do not detail its proof as it is a tautology knowing the Legendre's first theorem, the previous lemma and the N G LJ -equivalence between Playfair's postulate and the hypothesis of right angle. Following are the informal statement as well as its formulation in Coq. Note that it is the only theorem we state in this part that is expressed using second-order logic. In general, second-order logic is rarely used in our formalization of geometry: it is used only in intermediate definitions and statements needed for the proof of Pappus' theorem [START_REF] Braun | A synthetic proof of Pappus' theorem in Tarski's geometry[END_REF].

Theorem 14. Assuming Aristotle's axiom, any proposition implied by Playfair's postulate and such that its negation is implied by the hyperbolic plane postulate is equivalent to Playfair's postulate.

Theorem variant_of_szmielew_s_theorem : aristotle_s_axiom -> (forall P : Prop, (playfair_s_postulate -> P) -> (hyperbolic_plane_postulate -> ˜P)-> (P <-> playfair_s_postulate)).

Even if Theorem 14 only allows us to prove N A LJ -equivalence, it is a very powerful tool. Indeed, for any statement presenting only universal quantifiers, it suffices to show it is a consequence of any of our 34 versions of the parallel postulate and to provide a counterexample in hyperbolic geometry to prove its N A LJ -equivalence with Playfair's postulate. Moreover, both E n and H n are decidable [START_REF] Szmielew | Some Metamathematical Problems Concerning Elementary Hyperbolic Geometry[END_REF]. Therefore Theorem 14 renders possible a mechanized procedure deciding if a statement is equivalent to Playfair's postulate, using the decidability of both theories. Actually, the quantifier elimination algorithm for real closed fields which has been formalized by Cohen and Mahboubi in [START_REF] Cohen | Formal proofs in real algebraic geometry: from ordered fields to quantifier elimination[END_REF] can be connected to Tarski's system of geometry, thanks to our formalization of the arithmetization of Euclidean geometry. Following [START_REF] Szmielew | A new analytic approach to hyperbolic geometry[END_REF] we could formalize the arithmetization of hyperbolic geometry and extend the same quantifier elimination algorithm to this system. However, we are not sure whether this method would work in practice, because the quantifier elimination algorithm for real closed field by Cohen and Mahboubi has not been designed to be efficient, but to provide a theoretical result. Furthermore, the Gröbner basis method has already been integrated into Coq by Grégoire, Pottier and Théry [START_REF] Grégoire | Proof Certificates for Algebra and Their Application to Automatic Geometry Theorem Proving[END_REF]. Our work on the arithmetization of Euclidean geometry lets us use this method in our axiomatic system. Thus proving that a statement presenting only universal quantifiers is a consequence of Playfair's postulate could, in some cases, be done by computation, although this would require a significant formalization work.

Conclusion of Part II

We have described the formalization within the Coq proof assistant of the proof that 34 versions of the parallel postulate are equivalent. The originality of our proofs relies on the fact that first, the equivalence between these different versions are proved in Tarski's neutral geometry without using the continuity axiom nor line-circle continuity, and second, we work in an intuitionistic logic. 9Assuming decidability of point equality, we clarified the role of the decidability of intersection of lines: we obtained the formal proof that assuming decidability of point equality, some versions of the parallel postulate imply the decidability of the intersection of lines. The use of a proof assistant was crucial to check these proofs. Indeed, it is extremely easy to make a mistake in a pen-andpaper proof in this context. We have to be careful not to use any of the many statements which are equivalent to the parallel postulate, as well as not use classical reasoning.

Part III

Automated Theorem Proving in Geometry

In this part, we focus on the application of automated theorem proving to geometry, one of the fields in which it has been very successful. In fact, one of the first Artificial Intelligence programs was designed to produce readable proofs for geometry theorems [START_REF] Gelernter | Realization of a geometry theorem machine[END_REF]. Since then, several efficient methods have been developed. The most popular ones are the Gröbner basis method of Buchberger and Winkler [BW98], Wu's method [Wu78, Cho88, Wan01], the Cylindrical Algebraic Decomposition from Collins [START_REF] Edwin | Quantifier Elimination for Real Closed Fields by Cylindrical Algebraic Decomposition[END_REF], the area method and the full-angle method of Chou, Gao and Zhang [START_REF] Chou | Machine Proofs in Geometry[END_REF] and geometric algebras from Lu [START_REF] Li | Automated Geometric Theorem Proving, Clifford Bracket Algebra and Clifford Expansions[END_REF]. It is to be noticed that a decision procedure for the theory we are using was given by Tarski [START_REF] Tarski | What is Elementary Geometry? In The axiomatic Method, with special reference to Geometry and Physics[END_REF]. Some of these methods have been formalized in Coq: Janičić, Narboux and Quaresma formalized the area method [Nar04, JNQ12], Pottier and Théry formalized the Gröbner basis method [Thé01, Pot08, GPT11], Genevaux, Narboux and Schreck extended this work to Wu's method [START_REF] Genevaux | Formalization of Wu's simple method in Coq[END_REF], Fuchs and Théry formalized a procedure based on geometric algebras [START_REF] Fuchs | A Formalization of Grassmann-Cayley Algebra in COQ and Its Application to Theorem Proving in Projective Geometry[END_REF]. Finally, the Cylindrical Algebraic Decomposition has been implemented in Coq [START_REF] Mahboubi | Programming and certifying a CAD algorithm in the Coq system[END_REF][START_REF] Mahboubi | Contributions à la certification des calculs dans R : théorie, preuves, programmation[END_REF].

These methods can be divided into three kinds: synthetic deduction methods [START_REF] Gelernter | Realization of a geometry theorem machine[END_REF], algebraic automated deduction methods [BW98, Wu78, Cho88, Wan01, Col75] and invariant algebraic methods [START_REF] Chou | Machine Proofs in Geometry[END_REF][START_REF] Li | Automated Geometric Theorem Proving, Clifford Bracket Algebra and Clifford Expansions[END_REF]. Although synthetic deduction methods are generally the less powerful they have the advantage that they are more readable and do not require the arithmetization of geometry. It implies that these methods can be used to formalize the arithmetization of geometry. Then, this formalization enables us to put the theory proposed by Beeson in [START_REF] Beeson | Proof and Computation in Geometry[END_REF] into practice in order to obtain automatic proofs based on geometric axioms using algebraic automated deduction methods. Indeed, without a "back-translation" from algebra to geometry, algebraic methods only prove theorems about polynomials and not geometric statements. However, thanks to the arithmetization of Euclidean geometry, the proven statements correspond to theorems of any model of Hilbert's and Tarski's Euclidean geometry axioms.

"As long as algebra and geometry traveled separate paths their advance was slow and their applications limited. But when these two sciences joined company, they drew from each other fresh vitality, and thenceforth marched on at a rapid pace toward perfection." -Joseph-Louis Lagrange, Lec ¸ons élémentaires sur les mathématiques; quoted by Morris Kline, Mathematical Thought from Ancient to modern Times, p. 322 A formalization of the characterization of geometric predicates is also motivated by the need to exchange geometric knowledge data with a well-defined semantics. Algebraic methods for automated deduction in geometry have been integrated in dynamic geometry systems for a long time [START_REF] Janičić | GCLC -A Tool for Constructive Euclidean Geometry and More than That[END_REF][START_REF] Ye | An Introduction to Java Geometry Expert[END_REF]. Automatic theorem provers can now be used by non-expert user of dynamic geometry systems such as GeoGebra which is used heavily in classrooms [BHJ + 15]. But, the results of these provers needs to be interpreted to understand in which geometry and under which assumptions they are valid. Different geometric constructions for the same statement can lead to various computation times and non-degeneracy conditions. Moreover, as shown by Botana and Recio, even for simple theorems, the interpretation can be non-trivial [START_REF] Botana | On the Unavoidable Uncertainty of Truth in Dynamic Geometry Proving[END_REF]. Our formalization, by providing a formal link between the synthetic axioms and the algebraic equations, paves the way for storing standardized, structured, and rigorous geometric knowledge data based on an explicit axiom system [START_REF] Chen | Formalization and Specification of Geometric Knowledge Objects[END_REF].

Part III is structured as follows. In Chapter III.1, we describe the formalization and implementation of a reflexive tactic for automated generation of proofs of incidence to an affine variety. Our tactic, a synthetic deduction method which is used in the formalization described in the previous parts, allows us to automate proofs about incidence to an affine variety. Then, in Chapter III.2, we introduce Cartesian coordinates, and provide characterizations of the main geometric predicates obtained by a bootstrapping approach. We also present several applications of the arithmetization, firstly, we give an example of a proof by computation based on the Gröbner basis method, secondly, we show how we derived the formal proof of the axioms for the area method, thirdly, we prove that, given two points, we can build an equilateral triangle based on these two points in Euclidean Hilbert planes.

CHAPTER III.1

Small Scale Automation: a Reflexive Tactic for Automating Proofs of Incidence Relations

Hilbert's and Tarski's axiomatic developments possess the advantageous quality of not being based on set-theoretical notions. Yet the absence of set-theoretical notions has its drawback.

For instance, it induces incidence proofs1 to become particularly tedious. This issue also arises in Hilbert's axiomatic development while straight lines are nevertheless considered. To illustrate how often incidence proofs occur we made some statistics. We studied our formal development (GeoCoq) of Tarski's geometry which is mainly a formalization of [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. Approximately one seventh of the lines of the proof script contains applications of lemmas about collinearity of points. And almost a third of the lemmas of our development have as hypothesis the collinearity of some given points. One should point out two facts which allowed us to lower the ratio of incidence proofs present in our development. Firstly most of the incidence proofs are produced using some automatic tactics, therefore their length is greatly reduced. Secondly we restricted ourselves to the formalization of two-dimensional Euclidean geometry. Thus the greater part of the incidence proofs corresponds to proofs about collinearity while there would have also been proofs about coplanarity if the dimension would have been higher than two.

The particularity of incidence proofs is that they are often omitted in pen-and-paper proofs while they are subject to combinatorial explosion. These proofs are omitted as they do not contribute to the understanding of the proof in which they appear. This particularity calls for a procedure to automate these proofs. In this chapter we describe the reflexive tactic we developed to deal with this issue. Our early version of the tactic was specifically conceived to handle the case of collinearity. We then realized that our approach could be generalized in order to deal with incidence to an affine variety. As well as automating the incidence proofs our tactic allowed us to achieve a higher readability of our proof scripts.

As previously stated, geometry is a successful area of the field of automated theorem proving. But we are not interested in obtaining the most powerful prover which automates the whole proof. On the contrary we want to automate only the proof steps which are usually implicit in a pen-andpaper proof. The basis for this work is the mechanization in Coq of Tarski's axiomatic development about geometry. But for the sake of modularity we defined a type class capturing the minimal set of properties needed to apply our tactic. Our tactic is then applicable to any theory verifying these properties and is thus not restricted to Tarski's system of geometry.

Our work share some motivations with the work of Phil Scott and Jacques Fleuriot [START_REF] Scott | Mechanising Hilbert's foundations of geometry in Isabelle[END_REF][START_REF] Scott | A Combinator Language for Theorem Discovery[END_REF]. They propose a framework to add domain-specific automation and apply it to the case study of Hilbert's geometry. Their approach consists in using the idle computation time to generate new facts using a given set of lemmas in a forward manner. Our method is different, it is specific for incidence problems. Hence it is more efficient because as we know the kind of data we manipulate, we can use a suitable data structure.

Automating the proof steps that are implicit in Euclid's proofs is done by Avigad, Dean and Mumma [START_REF] Avigad | A formal system for Euclid's elements[END_REF].

The rest of this chapter is organized as follows. Section 1 describes the issue in the context of a simple example in elementary geometry. Section 2 presents a reflexive tactic to deal with the pseudo-transitivity of the collinearity predicate. In Section 3, we generalize our approach to other predicates. Finally, in Section 4, we study whether off-the-shelf automated theorem provers and our tactic can solve some incidence problems in a reasonable time.

Illustration of the Issue through a Simple Example

For the sake of clarity, we present the simple example of the midpoints theorem. We present a proof which contains an incidence proof. This allows us to illustrate the issue that arises while doing an incidence proof. The statement of this theorem is the following.

Theorem 15. In a non-degenerate triangle ABC where P is the midpoint of segment BC and Q the midpoint of segment AC, the lines AB and P Q are strictly parallel. 2 First we give the (slightly incorrect) informal proof which is often given in class. Proof. We first construct point X as the symmetric point of P with respect to Q (Fig. III.1.1). Point Q is therefore the midpoint of segment P X. From the assumptions we know that Q is also the midpoint of AC. Thus, the diagonals of the quadrilateral AP CX bisect in their midpoint and hence AP CX is a parallelogram. Now according to the fact that the opposite sides of a parallelogram are parallel and have the same length, we have that AX and CP (or BP ) are parallel and AX ≡ CP . As we know that P is the midpoint of BC we also have AX ≡ P B. The quadrilateral AXP B has two opposite sides which are parallel and of the same length, hence it is a parallelogram. Finally the opposite sides of a parallelogram are parallel, thus AB and P Q are parallel.

Formalizing this simple proof is not as trivial as it seems. Firstly, for a good reason: actually, this proof is not correct because from the fact that the opposite sides of a quadrilateral ABCD are parallel and of the same length we can only conclude that either ABCD or ABDC is a parallelogram. Proving that one is a parallelogram rather than the other is not trivial and should not be omitted. The possibility of overlooking the fact that in order to prove that ABCD is a parallelogram we also need to prove that ABDC cannot be a parallelogram motivates the use of a proof assistant.

Secondly, for some bad reasons: this proof contains proof steps which are implicit in a penand-paper proof that a proof assistant forces us to detail. Degenerate cases appear extremely often in geometry and correspond to cases of incidence of two geometric objects. These cases generally do not appear in pen-and-paper and contribute greatly to the difficulty of generating a proof of a geometric statement. Either the statement that we wish to prove holds in the degenerate case. Then one usually needs to prove the incidence of other pairs of geometric objects in order to prove the statement in the degenerate case. Or it does not and then an extra hypothesis is needed. This hypothesis is often referred to as a non-degeneracy condition and corresponds to the negation of the incidence of two geometric objects. This extra hypothesis generates a proof obligation which is often proven by proof of negation. 3 The contradiction is then shown through an incidence proof.

Therefore handling degenerate cases results most of the time in incidence proofs. The proof of midpoints theorem features such handling of degenerate cases. Indeed one cannot directly deduce that lines AB and P Q are parallel from the fact that ABP X is a parallelogram. In fact this 2 The common way of defining parallelism is to consider two lines as parallel if they belong to the same plane but do not meet. We distinguish between strict parallelism which corresponds to the previous definition and parallelism which add the possibility for the lines to be equal. 3 We recall that we use the expression 'proof of negation' to describe a proof of ¬A assuming A and obtaining a contradiction.

statement is only true when the parallelogram is non-flat. Thus one needs to prove that three of the four points defining the parallelogram are non-collinear. So let us prove A, P and X are non-collinear by proof of negation. Assuming that A, P and X are collinear one can obtain a contradiction by proving that A, B and C are collinear with following proof script. In this script there are six occurrences of lemmas dealing with permutation properties of the predicate Col designating the collinearity of an ordered triple of points. These lemmas correspond to ∀ABCσ,

σ ∈ S {A,B,C} ⇒ Col A B C ⇒ Col σ(A) σ(B) σ(C)
where S X denotes the symmetric group on a finite set X. To avoid the definition of the symmetric group we proved one lemma for each element of the group but the identity element. Moreover there are three occurrences of lemmas handling the pseudo-transitivity of this same predicate. These lemmas correspond to

∀P QABC, P = Q ⇒ Col P Q A ⇒ Col P Q B ⇒ Col P Q C ⇒ Col A B C
where A was chosen so that the first collinearity is trivially satisfied from ∀AB, Col A A B which expresses that two points are always collinear. The lemma of pseudo-transitivity can be understood as the possibility of proving that three points are collinear if they all belong to the same line. The extra hypothesis is needed to ensure that the points really belong to a well-defined line.

Even if we believe that it is important to mention that the parallelogram should be non-flat we would like the incidence proof corresponding to the proof of negation to be done automatically. Indeed besides corresponding to proof steps that should be implicit as they do not bring any understanding of the proof, its proof script is tedious to produce because of the combinatorics underlying the pseudo-transitivity of collinearity. In the next section, we expose the reflexive tactic we developed to automatically prove collinearity properties.

A Reflexive Tactic for Dealing with Permutation Properties and Pseudo-Transitivity of Collinearity

In order to simplify the proving process and to improve readability, we defined a tactic which can prove automatically collinearity properties which are consequences of this pseudo-transitivity.

Our first approaches to deal with this problem were to use the built-in automation of Coq (by creating a base of hints for the Coq tactic eauto) and then to write an ad hoc tactic in the tactic language of Coq. However this approach was not fulfilling our needs as it could not cope with difficult problems in a reasonable time. We therefore opted for a different approach. We chose to implement a reflexive tactic to handle this problem. First introduced in Coq by Boutin [START_REF] Boutin | Using reflection to build efficient and certified decision procedures[END_REF], reflexivity consists in replacing a tactic by an algorithm written in the Coq language and proving that the algorithm is sound. Applying the lemma asserting that the algorithm is sound reduces the problem to the computation of the algorithm. The reader interested in learning more about this now standard approach can also read the last chapter of the Coq'Art [START_REF] Bertot | Interactive Theorem Proving and Program Development, Coq'Art: The Calculus of Inductive Constructions[END_REF]. Using a reflective tactic allows us not only to save the user from doing the tedious work about the pseudo-transitivity of collinearity but also it hides these steps from the proof term. The simple yet effective algorithm used by this tactic is described in the following paragraph. This algorithm can be viewed as both a simpler and a more complex version of the congruence closure algorithm. It is simpler because we deal only with predicate symbols. It is more complex because our equality is not completely transitive, the transitivity relies on a non-degeneracy condition.

Algorithm.

The algorithm is divided into three parts. The first one consists in the initialization phase: it computes the set of all the sets of points known collinear and the sets of pairs of points known distinct. The second part consists in updating our internal data structure to compute the sets of points on each line. Finally we check if three given points are collinear by testing if they belong to a single line. For our algorithm we need a set of sets of points L to represent the sets of points known to be collinear and a set of pairs of points D to represent the points known to be different.

The algorithm is as follows: INPUT: 3 points A B C and the current hypotheses.

(1) Initialize L so that it contains all sets of three points that are assumed to be collinear by the hypotheses in the context and D so that it contains all the pairs of points that are assumed to be different by the hypotheses in the context. (2) For every l 1 and l 2 in L such that there exists a pair (p 1 , p 2 ) in D such that p 1 ∈ l 1 ∩ l 2 and p 2 ∈ l 1 ∩ l 2 , replace L with ((L\l 1 )\l 2 ) ∪ {l 1 ∪ l 2 }4 until there are no such l 1 and l 2 . (3) If there is a set l in L such that A ∈ l, B ∈ l and C ∈ l then A, B and C are collinear. Remark. Our tactic only captures basic properties of incidence, and is complete for only a small theory described below and for intuitionistic logic. Indeed, it can happen that some points A, B and C are collinear (if this fact follows from other geometric theorems) and our tactic fails in yielding a set l ∈ L such that A ∈ l, B ∈ l and C ∈ l.

Implementation.

We now give some technical details about the implementation in Coq of our algorithm.

2.2.1. Data-structures. We need to represent sets of sets of points. To represent points we need a decidable ordered type, hence we use the type of positive numbers as key. To represent finite sets we use the module Msets of the standard library. We could have used the library Containers [START_REF] Lescuyer | First-Class Containers in Coq[END_REF] which is easier to use than Msets because it infers automatically the structures needed to build the finite sets but we have chosen to keep the standard Msets to make our development easier to install as it is included in the standard distribution. We selected the implementation using ordered lists. Notice that using AVLs is not interesting here since we rarely have more than thirty points.

2.2.2. The Tactic. First, our tactic follows the first step of our previous algorithm in order to build the sets L and D by using an associative list so that the positives in our structures identify points. This initialization phase is implemented using the tactic language of Coq.

The second step is implemented as a Coq function defined using the Function package of Coq [START_REF] Barthe | Defining and Reasoning About Recursive Functions: A Practical Tool for the Coq Proof Assistant[END_REF]. To convince Coq that the algorithm terminates we proved the fact that the cardinality of L decreases at each recursive call.

The third step is also implemented as a Coq function which searches for a triple of points in a same set contained in L.

2.2.3. Proof of the Soundness of our Algorithm. For the sake of modularity, we created a type class with the minimal set of properties that a theory needs to verify and we did all the proofs within the context of this type class. The type class mechanism allows us to state axiom systems and to use implicitly the proof that some theory is a model of this axiom system. Type classes are dependent records with some automation: Coq infers some implicit instances [START_REF] Sozeau | First-Class Type Classes[END_REF]. Our tactic is then applicable to any theory verifying these following four properties (our own development about Hilbert's and Tarski's geometries but also, for example, the developments of Guilhot [START_REF] Guilhot | Formalisation en Coq et visualisation d'un cours de géométrie pour le lycée[END_REF], or Duprat [START_REF] Duprat | Fondements de géométrie euclidienne[END_REF]): 5Class Col_theory (CTpoint:Type) (CTCol:CTpoint->CTpoint->CTpoint->Prop

):= { CTcol_trivial : forall A B : COLTpoint, CTCol A A B; CTcol_permutation_1 : forall A B C : COLTpoint, CTCol A B C -> CTCol B C A; CTcol_permutation_2 : forall A B C : COLTpoint, CTCol A B C -> CTCol A C B; CTcol3 : forall X Y A B C : COLTpoint, X <> Y -> CTCol X Y A -> CTCol X Y B -> CTCol X Y C -> CTCol A B C }.
We want to prove that the tactic produces a set L that verifies the property "any triple of points belonging to a set of L are provably collinear". To do so we prove that the L produced by the first step of our algorithm verifies this property and that the second step of the algorithm preserves this property. The original set L trivially verifies this property by construction. We denote by x the point represented by the positive integer x. Now assuming that we have l 1 , l 2 , p 1 and p 2 verifying

p 1 ∈ l 1 ∩ l 2 , p 2 ∈ l 1 ∩ l 2 and (p 1 , p 2 ) ∈ D.
Assuming that the interpretation of any triple of points in l 1 are provably collinear and assuming the same for l 2 then for any p 3 in l 1 , Col p 1 p 2 p 3 holds and for any p 4 in l 2 , Col p 1 p 2 p 4 holds. By the lemma stated previously (CTcol3) the interpretation of any triple of points in l 1 ∪ l 2 are provably collinear. This proves that the second step of our algorithm preserves the property stated above and that, at the end of the second step, we obtain a set L verifying this property.

In Coq, the function x → x is called interp. The functions to manipulate sets of sets of positives are prefixed by SS, the functions for sets of positives are prefixed by S and the functions for sets of pairs of positives are prefixed by SP.

We define a predicate6 expressing that our set of lines is correct; for every line, all points on this line are collinear:

Definition ss_ok (ss : SS.t) (interp: positive -> COLTpoint) := forall s, SS.mem s ss = true -> forall p1 p2 p3, S.mem p1 s && S.mem p2 s && S.mem p3 s = true -> CTCol (interp p1) (interp p2) (interp p3).

We also need a predicate expressing that our set of pairs of distinct points is correct; all pairs are distinct: Finally, we prove that our main function test col (which tests if 3 points belong to the same set s ∈ L after applying our algorithm on L and D) is correct assuming that we start in a correct context:

Lemma test_col_ok : forall ss sp interp p1 p2 p3, ss_ok ss interp -> sp_ok sp interp -> test_col ss sp p1 p2 p3 = true -> CTCol (interp p1) (interp p2) (interp p3).

For the reification phase, we repeat the application of the following lemma, which states that if we know that two points A and B are distinct we can add them to the list of pairs of distinct points: We have a similar lemma to reify collinearity assumptions:

Relation with Equality of Lines and Rank

Functions. If we allow ourselves the concept of line (either by defining it with Tarski's language as Braun and Narboux have done in [START_REF] Braun | From Tarski to Hilbert[END_REF] or by using another language for geometry which includes lines such as Hilbert's axioms), then we can rewrite the pseudo-transitivity property of Col as an equality properties about lines:

A = B ∧ A ∈ l ∧ B ∈ l ∧ A ∈ m ∧ B ∈ m ⇒ l = m.
At first sight this property looks nicer than our properties about Col, but the problem with this formulation is that lines are always defined by pairs of distinct points. In practice using this kind of formulation would imply numerous case distinctions about equality of points.

There is a close link between the concept of rank that Magaud, Narboux and Schreck formalized previously [START_REF] Magaud | Formalizing Desargues' theorem in Coq using ranks in Coq[END_REF] and the properties studied in this section. The rank r of a subset S of elements of the matroid of points is the maximum size of an independent subset of S. Notice that the submodularity property of the rank function is a generalization of the pseudo-transitivity of Col:

r(l ∪ m) + r(l ∩ m) ≤ r(l) + r(m).
Indeed, if l and m are lines then their rank are of 2, and if their intersection contains two distinct points then the rank of the intersection is at least of 2, hence all points in the union are collinear:

r(l ∪ m) ≤ 2 + 2 -2 = 2.

Generalization to Other Incidence Relations

The algorithm presented in the previous section may seem to be very specific. 7 However, it can be generalized to deal with other properties than pseudo-transitivity of collinearity. For example, the lemma to express the pseudo-transitivity of the coplanar predicate has the same form:

∀ABCDP QR, ¬Col P Q R ⇒ Coplanar P Q R A ⇒ Coplanar P Q R B ⇒ Coplanar P Q R C ⇒ Coplanar P Q R D ⇒ Coplanar A B C D.
And the lemma to express the pseudo-transitivity of the concyclic predicate has the same form:

∀ABCDP Q, ¬Col P Q R ⇒ Concyclic P Q R A ⇒ Concyclic P Q R B ⇒ Concyclic P Q R C ⇒ Concyclic P Q R D ⇒ Concyclic A B C D.
In fact, our tactic is generalizable to any incidence relationship with algebraic curves or affine varieties.

The Tactic.

We use an axiomatic approach to define the generalized tactic. The generalization holds for any predicate wd of arity n + 2 and coinc of arity n + 3 for some n which verify the following axioms. Intuitively, wd predicate express the non-degeneracy condition, and coinc the incidence relation.

We assume that the wd and coinc predicates are invariant by permutation:

8 ∀X 1 X 2 . . . X n+2 , wd X 1 X 2 . . . X n+2 ⇒wd X 2 . . . X n+2 X 1 (2) ∀X 1 X 2 . . . X n+2 , wd X 1 X 2 X 3 . . . X n+2 ⇒wd X 2 X 1 X 3 . . . X n+2 (3) ∀X 1 X 2 . . . X n+3 , coinc X 1 X 2 . . . X n+3 ⇒coinc X 2 . . . X n+3 X 1 (4) ∀X 1 X 2 . . . X n+3 , coinc X 1 X 2 X 3 . . . X n+3 ⇒coinc X 2 X 1 X 3 . . . X n+3 .
(5) Moreover, we admit that the coinc predicates trivially holds when two points are equal:

(6) ∀AX 1 X 2 . . . X n+1 , coinc A A X 1 . . . X n+1 .
Finally we need that the pseudo-transitivity property holds:

(7) ∀X 1 . . . X n+2 P 1 . . . P n+3 , wd X 1 . . . X n+2 ∧ n+3 i=1 coinc X 1 . . . X n+2 P i ⇒ coinc P 1 . . . P n+3 .
In Coq's syntax, we can express this axiom system, the dots are replaced by dependent types: We define a class Arity which contains two fields:

• the type of the points that we consider,

• the natural number n such that n + 2 is the arity of the wd (then n + 3 is the arity of coinc):

Class Arity := { COINCpoint : Type; n : nat }.

Coinc_predicates inherits from Arity and contains one field for each predicate:

One can then define the type class corresponding to axioms (2-7):

Class Coinc_theory (Ar : Arity) (COP : Coinc_predicates Ar) := { wd_perm_1 : forall A : COINCpoint, forall X : cartesianPower COINCpoint (S n), app_1_n wd A X -> app_n_1 wd X A; wd_perm_2 : forall A B : COINCpoint, forall X : cartesianPower COINCpoint n, app_2_n wd A B X -> app_2_n wd B A X; coinc_perm_1 : forall A : COINCpoint, forall X : cartesianPower COINCpoint (S (S n)), app_1_n coinc A X -> app_n_1 coinc X A; coinc_perm_2 : forall A B : COINCpoint, forall X : cartesianPower COINCpoint (S n), app_2_n coinc A B X -> app_2_n coinc B A X; coinc_bd : forall A : COINCpoint, forall X : cartesianPower COINCpoint (S n), app_2_n coinc A A X; coinc_n : forall COINC : cartesianPower COINCpoint (S (S (S n))), forall WD : cartesianPower COINCpoint (S (S n)), pred_conj coinc COINC WD -> app wd WD -> app coinc COINC }.

The type T n is denoted by cartesianPower T n. The function app 1 n P X Xn, allows the application of a predicate P of arity n + 1 to be applied to an X of some type T and an Xn of type T n . The functions app n 1 and app 2 n are similar. We denote the n-ary conjunction from axiom (7) by pred conj.

In order to manipulate the set of tuples of a given arity (the generalization of set of pairs of distinct points) we proved that these tuples form an OrderedType ordered using the lexicographic order. For sets of sets and sets of pairs, we used the functor provided by the MSets library to generate the functions together with the proof of their properties. However, to spare the burden of using simultaneously modules and type classes, we decided to write our own functions. We used the Mergesort library to order our tuples. Representing a tuple of points by an ordered list of positive was possible thanks to axioms (2-3). Nevertheless, it required to prove the following lemmas: The CPToList function convert a cartesianPower T n into a list T and the OCP function orders a cartesianPower positive n using mergesort. The first of these lemmas asserts that any permutation of a tuple provably non-degenerate is non-degenerate. The second of these lemmas states that the list converted from a tuple of positive is a permutation of the sorted tuple. It proves that the two generators of the group of permutations induce all permutation properties. The CPToList function was not only allowing the use of functions and lemmas on lists from the standard library but it also permitted to prove most of the properties on lists before transferring them to tuples.

Dealing with dependent types inside the proofs and finding the appropriate inductive hypotheses represented the main difficulties. Although the proofs of the correction and termination of the algorithm became much more involved, its length remained similar (about 1k lines of code). Nevertheless, it relied on a collection of lemmas to deal with the generalization of theory which is larger than these proofs (about 2k lines of code) as well as several subdirectories from the standard library.

Deriving Instances in Tarski's Geometry.

In the context of Tarski's geometry, we derived three instances of the Coinc theory.

3.2.1. Collinearity. It is straightforward to instantiate our theory to obtain a tactic for collinearity as in Section 2. The proofs can be performed within Tarski's neutral dimensionless geometry (without assuming any upper-dimension axiom nor parallel postulate).

3.2.2. Coplanarity. The definition of coplanarity we adopt corresponds to the lemma 9.33 in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. It states that four points are coplanar if (at least) two out of these four points form a line which intersect the line formed by the remaining two points (see Fig. The permutation properties (4-5) and trivial cases (6) of the predicate Coplanar are easy to obtain but the pseudo-transitivity (7) requires the axiom of Pasch (both the inner and outer forms) and many case distinctions. The inner form of Pasch's axiom that we assume is a variant of the axiom Pasch introduced in [START_REF] Pasch | Vorlesung über Neuere Geometrie[END_REF] to repair the defects of Euclid. It intuitively says that if a line meets one side of a triangle and does not pass through the endpoints of that side, then it must meet one of the other sides of the triangle.

III.1.2):

Definition Coplanar A B C D := exists X, (Col A B X /\ Col C D X) \/ (Col A C X /\ Col B D X) \/ (Col A D X /\ Col B C X).
3.2.3. Concyclic. Our last instance allows to prove that points belong to the same circle. To define the concyclic predicate the first idea is to ask for the points to be coplanar and that there is a point (the center of the circle) which is at the same distance of the four points:

Definition Concyclic A B C D := Coplanar A B C D /\ exists O, Cong O A O B /\ Cong O A O C /\ Cong O A O D.
But in order to prove axiom (6), we need a more general definition because three points do not belong to a circle in case they are collinear. We say that four points are concyclic-gen if either they are concyclic or if they all belong to the same line. Note that we do not assume the points to be distinct, so we need four collinearity assumptions to express this fact:

Definition Concyclic_gen A B C D := Concyclic A B C D \/ (Col A B C /\ Col A B D /\ Col A C D /\ Col B C D).
This generalized predicate allows us to instantiate the type class. 3.2.4. Other Instances. It would be of interest to study the generalization of these instances to other cases such as conics, cubics or linear subspaces.

It is well-known that five points in general linear position define a plane conic. Pascal's hexagon theorem (see Fig. III.1.3) is a good mean to define conics geometrically. Assuming Pappus' theorem Magaud, Narboux and Schreck have proved in Coq that the permutation properties of the predicate expressing that six points are coincident to a conic [START_REF] Magaud | A Case Study in Formalizing Projective Geometry in Coq: Desargues Theorem[END_REF]. It remains to show the pseudotransitivity property.

Analysis of the Performance of the Tactic

One could argue that our tactic solves a simple problem which could be solved by general purpose automatic provers as our theory fits in the well-known ∀∃ fragment. But, in pratice we needed a Coq implementation. Still we evaluate in this section at which extent an off-the-shelf automated theorem proving systems can solve the problems solved by our tactic. The purpose of this evaluation is not to actually compare the respective time needed by each prover to solve the different problems but to verify if either these off-the-shelf automated theorem provers or our tactic can solve such incidence problems in a reasonable time. The tedious part of such proofs of incidence was the use of the pseudo-transitivity property. So we designed a way of generating problems requiring an important number of applications of this property to be proved. We used the following algorithm to generate incidence problems for an incidence relation coinc of arity n + 1. • We start with 2n hypotheses stating that there are 2n non-degenerate algebraic curves or affine varieties C 0 , C 1 , • • • , C 2n-1 (each of these are defined by n points). We also have n points P 0 , P 1 , • • • , P n-1 and 2n 2 hypotheses asserting that each of the n points on each of the 2n non-degenerate algebraic curves or affine varieties are coincident with the n points P 0 , P 1 , • • • , P n-1 . • We then add 2n 2 points together with the hypotheses specifying 2n new non-degenerate algebraic curves or affine varieties. Each of these points are supposed to be incident to one of the last non-degenerate algebraic curves or affine varieties in such a way that the added points are provably coincident with the all the other points. We repeat this process a given number of times. • Finally, we take n + 1 points amongst the last 2n 2 added points and we ask whether these points are coincident. To illustrate the kind of problems this procedure generates, let us take the simplest example where n = 2. We start with two points defining a line (A and B on Using this algorithm we generated problems that we expressed in Coq syntax as well as TPTP syntax. It allowed us to select by hand the five fastest automated theorem proving systems available on the TPTP platform for this kind of problem. These provers are: E 1.9 [Sch13], iProver 2.5 [Kor08], Metis 2.3 [START_REF] Hurd | First-order proof tactics in higher-order logic theorem provers[END_REF], Otter 3.3 [START_REF] Mccune | OTTER 3.3 Reference Manual[END_REF] and Vampire 4.1 [START_REF] Riazanov | Vampire[END_REF].

Once we had selected these provers we run the same tests on a single machine to be able to compare the time needed by the different provers to find a proof. We present the results of these tests in Tab. III. The conclusion is that automated theorem provers can solve small problems, but as soon as the number of nested applications of transitivity properties increases, the performance drops to a point such that the systems are not usable in an interactive setting or cannot even solve the problem. Moreover, automated theorem provers really struggle as soon as n = 3. This advocates for the need for an automatic theorem prover having a specialized decision procedure for specific problems. It could be of interest to study the integration of our algorithm in a satisfiability modulo theories solver. For example, Z3 already contains an efficient implementation of a congruence closure algorithm. It would be interesting to see how our work could be ported to this setting.

CHAPTER III.2

Big Scale Automation: Algebraic Methods

In this chapter, we focus on the use of algebraic methods allowed by the arithmetization of Euclidean geometry. To obtain the characterizations of the geometric predicates, we adopted an original approach based on bootstrapping: we used an algebraic prover to obtain new characterizations of the predicates based on already proven ones. To illustrate the concrete use of the formalization of the arithmetization of Euclidean geometry, we derived from Tarski's system of geometry a formal proof of the nine-point circle theorem using the Gröbner basis method. To obtain the characterizations of the geometric predicates needed to express this theorem, we adopted an original approach based on bootstrapping: we used an algebraic prover to obtain new characterizations 1 of the predicates based on already proven ones. Moreover, we derive the axioms for another automated deduction method: the area method. Finally, we solve a challenge proposed by Beeson: we prove that, given two points, an equilateral triangle based on these two points can be constructed in Euclidean Hilbert planes.

The rest of this chapter is organized as follows. We provide the characterization of the main geometric predicates (Section 1) obtained by a bootstrapping approach. In Section 2, we give an example of an automatic proof using an algebraic method. In Section 3, we use the language of vectors defined using coordinates to derive the axioms for another automated deduction method: the area method. In Section 4, we solve a challenge proposed by Beeson: we prove that equilateral triangles can be constructed without any circle-circle continuity axiom. The summary of the definitions is given in Appendix A using the notations given in Appendix E.

Algebraic Characterization of Geometric Predicates

It is well-known that having algebraic characterizations of geometric predicates is very useful. Indeed, if we know a quantifier-free algebraic characterization of every geometric predicate present in the statement of a lemma, the proof can then be seen as verifying that the polynomial(s) corresponding to the conclusion of the lemma belong(s) to the radical of the ideal generated by the polynomials corresponding to the hypotheses of the lemma. Since there are computational ways (for example, the Gröbner basis method) to do this verification, these characterizations allow to obtain proofs by computations. In this section, we present our formalization of the coordinatization of geometry and the method we employed to automate the proofs of algebraic characterizations.

Coordinatization of Geometry.

To define coordinates, we first defined what is a proper orthonormal coordinate system (Cs) as an isosceles right triangle for which the length of the congruent sides equals the unity. 1 By a characterization of a geometric predicate G with subject x we mean an equivalence of the form G(x)

⇔ n k=1 P k (x) = 0 ∧ m k=1 Q k (x)
> 0 for some m and n and for some polynomials P k 1≤k≤n and Q k 1≤k≤m in the coordinates x of the points.

Geometric predicate Algebraic Characterization

A = B x A -x B = 0 ∧ y A -y B = 0 or (x A -x B ) 2 + (y A -y B ) 2 = 0 AB ≡ CD (x A -x B ) 2 + (y A -y B ) 2 -((x C -x D ) 2 + (y C -y D ) 2 ) = 0 A B C ∃t, 0 ≤ t ≤ 1 ∧ t(x C -x A ) = x B -x A ∧ t(y C -y A ) = y B -y A Col A B C (x A -x B )(y B -y C ) -(y A -y B )(x B -x C ) = 0 A I B 2x I -(x A + x B ) = 0 ∧ 2y I -(y A + y B ) = 0 A B C (x A -x B )(x B -x C ) + (y A -y B )(y B -y C ) = 0 AB ⊥ CD (x A -x B )(y C -y D ) -(y A -y B )(x C -x D ) = 0 ∧ (x A -x B )(x A -x B ) + (y A -y B )(y A -y B ) = 0 ∧ (x C -x D )(x C -x D ) + (y C -y D )(y C -y D ) = 0 AB CD (x A -x B )(x C -x D ) + (y A -y B )(y C -y C ) = 0 ∧ (x A -x B )(x A -x B ) + (y A -y B )(y A -y B ) = 0 ∧ (x C -x D )(x C -x D ) + (y C -y D )(y C -y D ) = 0 Table III.2.1. Algebraic Characterizations of geometric predicates. Length O E E' P C C1 -> Length O E E' P D D1 -> Prodg O E E' A1 D1 AD -> Prodg O E E' C1 B1 AD.

Automated Proofs of the Algebraic Characterizations.

In this subsection, we present our formalization of the translation of a geometric statement into algebra adopting the usual formulas as shown on Tab. III.2.1 (here we use the the notations given in Appendix E). In this table we denoted by x P the abscissa of a point P and by y P its ordinate. We use the notations given in Appendix E.

To obtain the algebraic characterizations of the others geometric predicates we adopted an original approach based on bootstrapping: we applied the Gröbner basis method to prove the algebraic characterizations of some geometric predicates which are used in the proofs of the algebraic characterizations of other geometric predicates. The trick consists in a proper ordering of the proofs of the algebraic characterizations of geometric predicates relying on previously characterized predicates.

For example, we characterized parallelism in terms of midpoints and collinearity using the famous midpoint theorem that we previously proved synthetically. 4 Midpoint M A B means that M is the midpoint of A and B. In the end, we only proved the characterizations of congruence, betweenness, equality5 and collinearity manually. The first three were already present in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] and the last one was fairly straightforward to formalize from the characterization of betweenness. However, it is impossible to obtain the characterizations of collinearity from the characterizations of betweenness by bootstrapping. Indeed, only a characterization of a geometric predicate G with subject x of the form

G(x) ⇔ n k=1 P k (x) = 0 ∧ m k=1
Q k (x) = 0 for some m and n and for some polynomials P k 1≤k≤n and Q k 1≤k≤m in the coordinates x of the points can be handled by either Wu's method or Gröbner basis method. Nevertheless, in theory, the characterization of the betweenness predicate could be employed by methods such as the quantifier elimination algorithm for real closed fields formalized by Cohen and Mahboubi in [START_REF] Cohen | Formal proofs in real algebraic geometry: from ordered fields to quantifier elimination[END_REF]. Then we obtained automatically the characterizations of midpoint, right triangles, parallelism and perpendicularity (in this order). The characterization of midpoint can be easily proven from the fact that if a point is equidistant from two points and collinear with them, either this point is their midpoint or these two points are equal. To obtain the characterization of right triangles, we exploited its definition which only involves midpoint and segment congruence. One should notice that the existential quantifier can be handled using a lemma asserting the existence of the symmetric of a point with respect to another one. To obtain the characterization of perpendicularity, we employed the characterizations of parallelism, equality and right triangle. The characterization of parallelism is used to produce the intersection point of the perpendicular lines which is needed as the definition of perpendicular presents an existential representing this point. Proving that the lines are not parallel allowed us to avoid producing the point of intersection by computing its coordinates. This was more convenient as these coordinates cannot be expressed as a polynomial but only as a rational function. Having a proof in Coq highlights the fact that the usual characterizations include degenerate cases. For example, the characterization of perpendicularity in Tab. III.2.1 entails that lines AB and CD are non-degenerate.

An Example of a Proof by Computation

To show that the arithmetization of Euclidean geometry is useful in practice, we applied the nsatz tactic developed by Grégoire, Pottier and Théry [START_REF] Grégoire | Proof Certificates for Algebra and Their Application to Automatic Geometry Theorem Proving[END_REF] to one example. This tactic corresponds to an implementation of the Gröbner basis method. Our example is the nine-point circle theorem (Fig. III.2.1) which states that the following nine points are concyclic: the midpoints of each side of the triangle, the feet of each altitude and the midpoints of the segments from each vertex of the triangle to the orthocenter: 6 6 In fact, many well-known points belong to this circle and this kind of properties can easily be proved formally using barycentric coordinates [START_REF] Narboux | Towards A Certified Version of the Encyclopedia of Triangle Centers[END_REF].

Lemma nine_point_circle : forall

A B C A1 B1 C1 A2 B2 C2 A3 B3 C3 H O, ˜Col A B C -> Col A B C2 -> Col B C A2 -> Col A C B2 -> Perp A B C C2 -> Perp B C A A2 -> Perp A C B B2 -> Perp A B C2 H -> Perp B C A2 H -> Perp A C B2 H -> Midpoint A3 A H -> Midpoint B3 B H -> Midpoint C3 C H -> Midpoint C1 A B -> Midpoint A1 B C -> Midpoint B1 C A -> Cong O A1 O B1 -> Cong O A1 O C1 -> Cong O A2 O A1 /\ Cong O B2 O A1 /\ Cong O C2 O A1 /\ Cong O A3 O A1 /\ Cong O B3 O A1 /\ Cong O C3 O A1.
Compared to other automatic proofs using purely algebraic methods (either Wu's method or Gröbner basis method), the statement that we proved is syntactically the same, but the definitions and axioms are completely different. We did not prove a theorem about polynomials but a geometric statement. This proves that the nine-point circle theorem is true in any model of Hilbert's and Tarski's Euclidean plane geometry axioms (without continuity axioms) and not only in a specific one. We should remark that to obtain the proof automatically with the nsatz tactic, we had to clear the hypotheses that the lines appearing as arguments of the Perp predicate are well-defined. In theory, this should only render the problem more difficult to handle, but in practice the nsatz tactic can only solve the problem without these additional (not needed) assumptions. Non-degeneracy conditions represent an issue as often in geometry. Here we have an example of a theorem where they are superfluous but, while proving the characterizations of the geometric predicates, they were essential.

Connection with the Area Method

The area method, proposed by Chou, Gao and Zhang in the early 1990s, is a decision procedure for a fragment of Euclidean plane geometry [START_REF] Chou | Machine Proofs in Geometry[END_REF]. It can efficiently prove many non-trivial geometry theorems and produces proofs that are often very concise and human-readable.

The method does not use coordinates and instead deals with problems stated in terms of sequences of specific geometric construction steps and the goal is expressed in terms of specific geometric quantities:

(1) ratios of lengths of parallel directed segments, (2) signed areas of triangles, (3) Pythagoras difference of points (for the points A, B, C, this difference is defined as

P y(ABC) = AB 2 + BC 2 -AC 2 .
In a previous work, Janičić, Narboux and Quaresma have formalized in Coq the area method based on a variant of the axiom system used by Chou, Gao and Zhang [START_REF] Janičić | The Area Method : a Recapitulation[END_REF]. The axiom system is based on the concept of signed distance instead of ratio of signed distance. The axioms of Narboux's formalization of the area method are listed on Tab. III.2.2. This allows to deduce some properties of ratios from the field axioms. For example, one can deduce from the field axioms that AB CD CD EF = AB EF . 3.1. Definition of the Geometric Quantities. The first step toward proving the axioms of the area method is to define the geometric quantities in the context of Hilbert's or Tarski's axioms.

First, we defined the usual operations on vectors, cross and scalar products: Then, the ratio of signed distances can be defined using a formula provided by Chou, Gao and Zhang. This formula has the advantage to give a definition which is a total function: 7

AB CD = --→ AB. --→ CD --→ CD.
--→ CD . For the signed area, we used the cross product: Note that in the formal proof, we also used the concept of twice the signed area, because it does not change the ratio of areas, nor the equality between areas but it simplifies the proofs.

In Coq's syntax:

S ABC = 1 2 --→ AB × -→ AC.
To define the Pythagoras difference, we used the square of the signed distance:

Proof that the Axioms

For the Area Method hold in Tarski's System of Geometry. In this subsection, we demonstrate that the assertion, made previously on page 8 of [START_REF] Janičić | The Area Method : a Recapitulation[END_REF] which stated that all the axioms of the area method can be derived from Hilbert's axioms, is indeed correct. In this previous work, Narboux stated that proving the area method axioms from Hilbert's axioms would be cumbersome, but thanks to the arithmetization of Euclidean geometry and algebraic methods for automated deduction in geometry, we can now obtain the proofs of the axioms of the area method quite easily. This shows the strength of using a proof assistant, allowing both synthetic and algebraic proofs together with automated deduction. We believe that mixing synthetic and algebraic proof is very powerful and can have several applications. Indeed, it has been demonstrated recently by Mathis and Schreck. They have resolved open geometric construction problems using a combination of algebraic computation with a synthetic approach [START_REF] Mathis | Determining automatically compass and straightedge unconstructibility in triangles[END_REF].

The first axiom AM 1 is a direct consequence of the characterization of point equality described in Subsection 1.3. The axioms AM 2 , AM 3 and AM 6 are trivial. One only needs to prove that two polynomials are equal, which can be done automatically in most, if not all, of the proof assistants. In Coq, it can be done employing the ring tactic. Notice that a variant of the axiom AM 4 can be proved for ratios even without the assumption that A, B and C are collinear:

Lemma chasles_ratios : forall A B C P Q, P <> Q -> ratio A B P Q + ratio B C P Q =F= ratio A C P Q.
Axiom AM 5 is a direct consequence of Tarski's lower-dimensional axiom (or the corresponding Hilbert's axiom). For the proof of axiom AM 7 , we gave explicitly the coordinates of the point P asserted to exist by this axiom. The axioms AM 8 , AM 9 , AM 10 and AM 13 can be proved using the implementation of Gröbner basis method in Coq. For the axioms AM 11 and AM 12 , the implementation of Gröbner basis method in Coq failed. We had to find another solution. We first proved the equivalence between the definition of the parallelism and perpendicularity predicates using areas and the geometric definition. Indeed, in the area method axioms, collinearity and parallelism are defined using the signed area and perpendicularity using the Pythagoras difference: I is the midpoint of the segment AB, C is finally constructed as a point on the perpendicular to AB through I such that IC ≡ AR. The fact that the midpoint can be constructed without continuity axioms is non-trivial but we have already formalized Gupta's proof [START_REF] Narayan | Contributions to the Axiomatic Foundations of Geometry[END_REF][START_REF] Narboux | Mechanical Theorem Proving in Tarski's geometry[END_REF]. The proof that the whole construction is correct is a consequence of two applications of Pythagoras' theorem but it can be obtained automatically using the Gröbner basis method. Note again that the combination of interactive and automatic reasoning was crucial. We could construct the point by hand and use the automatic prover to check that the construction is correct.

Conclusion of Part III

We described a generic reflexive tactic for proving some specific incidence properties which appear often in the systematic development based on Tarski's system of geometry. During this formalization we appreciated the versatility of the Calculus of Inductive Constructions (CIC) which allows to express easily functions of parameterizable arity.

Our tactic is generic in some sense, but also very specialized: it can solve a small class of goals. Yet, it would have been tedious to manually prove the goals which are solved automatically. Moreover, these sub-proofs are often hidden in an informal text since they are "obvious" and make the whole proof more difficult to read.

Compared to the approach proposed by Scott and Fleuriot [START_REF] Scott | A Combinator Language for Theorem Discovery[END_REF] our approach is more specific since it is dedicated to one task about incidences. But this task is efficiently achieved which is important in Coq while in Isabelle, the theorems proved ahead can be handled with less efficient mechanisms. More precisely, as we know that we manipulate geometric data, we can have a specific data structure to represent lines whereas the approach of Scott and Fleuriot generates a new fact for each combination of triple of points on a given line.

Moreover, based on the arithmetization of Euclidean geometry, we introduced Cartesian coordinates, produced the first synthetic and formal proofs of the intercept and Pythagoras' theorems, and provided characterizations of the main geometric predicates. To obtain the algebraic characterizations of some geometric predicates, we adopted an original approach based on bootstrapping. 8 Our formalization of the arithmetization of Euclidean geometry paves the way for the use of algebraic automated deduction methods in synthetic geometry within the Coq proof assistant. To illustrate the concrete use of this formalization, we derived from Tarski's system of geometry 9 a formal proof of the nine-point circle theorem using the Gröbner basis method. Moreover, we derived the axioms for another automated deduction method: the area method. Finally, we solved a challenge proposed by Beeson: we proved that, given two points, an equilateral triangle based on these two points can be constructed in Euclidean Hilbert planes, i.e., without continuity axioms.

Note that, even if this formalization allows to use algebraic automatic theorem provers to prove theorems assuming synthetic axioms, we cannot obtain in practice a synthetic proof by this method. Indeed, even if it is possible in principle, the synthetic proof that we would obtain by translating the algebraic computations would not be readable. In a different but similar context, Mathis and Schreck have translated by hand an algebraic solution to a ruler-and-compass construction problem [START_REF] Mathis | Determining automatically compass and straightedge unconstructibility in triangles[END_REF]. The construction obtained can be extracted from the algebraic proof. It can even be executed by GeoGebra but it is not the kind of construction that a geometer would expect. 8 Actually, we first proved the characterization of the midpoint predicate manually and afterward we realized that it can be proved automatically. The script of the proof by computation was eight times shorter than our original one, thus highlighting how effective this bootstrapping approach can be. 9 As previously pointed out, thanks to the mutual interpretability of Hilbert's and Tarski's axioms, this proof is also valid in the context of Hilbert's axioms (see Chapter I.2).

Conclusion and Perspectives

Throughout this thesis, we have focused the formalization of the foundations of geometry. We have studied both synthetic and analytic approaches to the foundations of Euclidean geometry. The core of our formalization is based on the synthetic approach due to Tarski. We started by proving the satisfiability of Tarski's system of geometry without continuity axioms. We achieved it by building a model based on the analytic approach: a Cartesian plane over a Pythagorean ordered field. With a view to guarantee that the axiomatic system captures the Euclidean plane geometry, we mechanized the proof of the arithmetization of Euclidean geometry. Then, in order to obtain the same results for another axiomatic system based on the synthetic approach, namely Hilbert's axioms, we built a formal proof that Hilbert's and Tarski's axiom systems are mutually interpretable if we exclude continuity axioms. This result was well-known but was proved indirectly using the characterization of the models of the theories. Up to our knowledge, we built the first synthetic proof of this theorem. Later, we gave a new proof of the independence of the parallel postulate from the other axioms of Tarski's system of geometry. After remarking that this proof also provided us with another independence result, namely the independence of the decidability of intersection of lines, we went on to investigate the decidability properties necessary to obtain the arithmetization. We narrowed them down the decidability of point equality and we demonstrated that we could have equivalently assumed the decidability of either the betweenness or the congruence predicate.

Having remarked that not all versions of the parallel postulate were sufficent to obtain the arithmetization of Euclidean geometry, as defined by Descartes, without adding an additional decidability property, more precisely the decidability of intersection of lines, we decided to study several versions of the parallel postulate. This led us to provide synthetic and formal proofs 10 of the equivalence of postulates belonging to the same class according to Pejas' classification of Hilbert planes. Furthermore, we refined this classification in an intuitionistic setting to obtain four classes instead of three for the 34 postulates that we considered. In fact, not all the versions of the parallel postulate imply the decidability of intersection of lines necessary for the arithmetization of Euclidean geometry, as presented by Descartes. Moreover, we gave a proof of the independence of Archimedes' axiom from the axioms of Pythagorean planes which is not based on a counter-model. Finally, we proposed a way to obtain a mechanized procedure deciding the equivalence to Euclid's parallel postulate.

All of these results were could not have been achieved without the use of automation. We designed a generic reflexive tactic for proving some specific incidence properties. This tactic has been used extensively throughout our formalization effort. Once we achieved the arithmetization of Euclidean geometry, we got access to more powerful methods such as the Gröbner basis method thanks to the introduction of Cartesian coordinates and characterizations of the main geometric predicates obtained with an original approach based on bootstrapping. We presented several applications of the Gröbner basis method in synthetic geometry. One of these applications was to derive the axioms for another automated deduction method: the area method. Thus, we linked our development to a third way of defining the foundations of Euclidean geometry: the mixed analytic/synthetic approach. Fig. III.2.3 provides an overview of the links we formalized between the different approaches. 11 The work described in this thesis could be further developed by following several paths.

Study Variants of the Axiom Systems that we Considered

The first direction in which our work could be extended involves the study of variants of the axiom systems that we considered.

A first variant of Tarski's system of geometry that we could explore concerns the Coq encoding of the axiom system. The field theory that we built from Tarski's system of geometry does not correspond to realFieldType that we assumed to build our model. Thus, we could also extend our work on the arithmetization of Euclidean geometry in order to build a realFieldType. Going in the opposite direction, namely building a model of Tarski's system of geometry using the field theory from the standard library, would imply to start over the formalization of the model. However, with a view to build a realFieldType, we would modify the few axioms that are not already quantifier-free to their equivalents in Type. We would also replace the axiom expressing 10 When we proved the mutual interpretability between Hilbert's and Tarski's axioms, we treated the case of neutral geometry separately from the parallel postulate. It was motivated by the fact that it was allowing us to base our study on Tarski's system of geometry while obtaining their validity in the context of Hilbert's axioms. 11 We remind that the axioms for Tarski's system of geometry were denoted by A1-A10 since we excluded continuity axioms and that Hilbert's axioms were collected into four groups. the decidability of point equality by a function of type Tpoint -> Tpoint -> bool together with an axiom stating its specification. Similarly, the betweenness and congruence predicates could be replaced by boolean predicates. While this would render our axiom system stronger, it would also allow us to avoid the use of the constructive_definite_description axiom. Another advantage of this modification would be that the dependent type that we defined to describe the points that belong to the ruler would not require a defined equality to avoid the problem of proof relevance. Applying these modifications and extending the realFieldType to dispose of a formal theory for Pythagorean ordered fields would allow us to show the mutual interpretability of Tarski's system of geometry and Cartesian planes over a Pythagorean ordered field based on a single formalization of the latter. We could also choose to go to the opposite direction and weaken the decidability of point equality to only assume "stability axioms" for betweenness and congruence allowing proofs by contradiction for betweenness and congruence. By adopting Beeson's variant of Tarski's system of geometry, we could follow his approach based on the Gödel double-negation interpretation to retrieve a significant part of the GeoCoq development [START_REF] Beeson | A Constructive Version of Tarski's Geometry[END_REF]. Then, we would have to formalize the correctness of the constructions that he provides for uniform perpendicular, rotation, and reflection constructions [START_REF] Beeson | A Constructive Version of Tarski's Geometry[END_REF] as well as for addition and multiplication [START_REF] Beeson | Constructive Geometry and the Parallel Postulate[END_REF]. This would provide a formal proof of a theorem due to Beeson [START_REF] Beeson | Constructive Geometry and the Parallel Postulate[END_REF] asserting that "stability axioms" for betweenness and congruence are sufficient for the arithmetization of Euclidean geometry. So far our development has been restricted to planar geometry. Nevertheless, an alternative axiomatic system is given in [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] to capture Euclidean geometry of higher dimension. In fact, the systematic development is actually performed using this system. However, the first eight chapters do not use the upper-dimensional axiom and are therefore valid in any dimension higher or equal than two. The major change compared to our development is that some lemmas have extra hypotheses to state that some points are coplanar. Thus, in order to use these new lemmas, we would have to prove that the considered points are indeed coplanar. Luckily for us, thanks to the tactic described in Chapter III.1, we already have a tool to help us in this task. Therefore, it would be natural to extend our library to Euclidean geometry of higher dimension.

Similarly, in [START_REF] Hilbert | Foundations of Geometry (Grundlagen der Geometrie[END_REF], the set of axioms defines three-dimensional geometry but we restricted ourselves to planar geometry. It would therefore be of interest to use the complete list of axioms and to formalize Hilbert's three-dimensional geometry. Our formalization of Hilbert's axiom system also avoids the concept of sets of points, segments, rays and angles to prevent problems arising from the use of dependent types. Our current formalization can hence be considered less faithful to the original than the one that was presented in 2012. By adopting the same modifications proposed to build a realFieldType, we could also provide a more faithful formalization while having corrected the "mistakes" from the version from 2012.

In Chapter III.2, we illustrated the power of algebraic automated deduction methods with several applications. At the moment, we have been focused on Euclidean geometry. However, we could take advantage of our large library in neutral geometry, and of the proof of the equivalence between the different versions of the postulate, to obtain a library for hyperbolic geometry. The goal would be to obtain the arithmetization of hyperbolic geometry so that these deduction methods would also be available for hyperbolic geometry. For this goal, we could follow the development from Szmielew [START_REF] Szmielew | A new analytic approach to hyperbolic geometry[END_REF].

Finally, we could study the only axiom that we have not used: the continuity axiom. Having established the mutual interpretability of Tarski's system of geometry without continuity axioms and Cartesian planes over a Pythagorean ordered field, we could mechanize a similar proof. Indeed, by adding the continuity axiom, the theory becomes mutually interpretable with Cartesian planes over a real-closed field. While proving the independence of the parallel postulate, we introduced a weaker version of the continuity axiom, namely the Circle axiom. In fact, this version also allows to obtain such a mutual interpretability property where the real-closed field is replaced by a Euclidean field. We could even assume an even weaker system, introduced by Gupta [Gup65], to capture Cartesian planes over an arbitrary ordered field. Furthermore, while Tarski's system of geometry captures polygonal geometry, it can be further extended to describe circle geometry [START_REF] John T Baldwin | Axiomatizing Changing Conceptions of the Geometric Continuum II: Archimedes-Descartes-Hilbert-Tarski[END_REF]. This theory adds π as a constant and an axiom which defines it as the limit of perimeters of regular polygons inscribed and circumscribed in a circle of radius 1. By formalizing such a theory, we could follow the development from Bertot and Allais [START_REF] Bertot | Views of PI: Definition and computation[END_REF] to obtain results about π similar to those of Coq's standard library for real numbers in the context of Tarski's system of geometry.

Study Other Ways to Define the Foundations of Geometry

Another possible path could be to study other ways to define the foundations of geometry. Indeed, we have mainly investigated the synthetic approach and its connection to the analytic approach. Therefore, it would be relevant to investigate Birkhoff's axiomatic system, a mixed analytic/synthetic approach.

Moreover, in Part I, we mentioned the Erlangen program which we have not focused on. It would be interesting to formalize the different geometries obtained by assuming the invariance under the action of several group of transformations. For example, we could start by demonstrating that one obtains Euclidean planes by assuming the invariance under the action of the group of isometries.

Formalization of Metatheoretical Results

The next possible line of extension could be the formalization of metatheoretical results. In Part I, we have described a proof of independence of the parallel postulate. Nevertheless, we have not mechanized this proof. We have also seen that there is a model of the first two groups of Hilbert's axioms with only one point and no line and that this was problematic in Coq but not in Isabelle/HOL where all types are inhabited. The theory that we have formalized is then closely linked to the proof assistant in which it has been defined, in this case Coq. It would then be pertinent to mechanize our proof so that it is applied to our definition of Tarski's axioms.

With a view to demonstrate the independence of the parallel postulate, we could also formalize a model of non-Euclidean geometry. In fact, there exists a model of non-Euclidean geometry which is very similar to the model that we have built to show the satisfiability of the theory: the Klein space over a Pythagorean ordered field. This model is based on the same definition for the betweenness predicate and restrict the points to the open unit n + 1-dimensional ball. 12 Only the congruence predicate is different. Thus, we have already proved some of the axioms in this model and one would just have to modify the proof of the axioms concerning the congruence and of those that are not quantifier-free. For the last ones, we would need to provide the proof that the constructed points belong to the open unit n + 1-dimensional ball. Actually, most of the independence models used by Gupta [START_REF] Narayan | Contributions to the Axiomatic Foundations of Geometry[END_REF] to justify the independence of the variant of Tarski's system of geometry that he introduced correspond to modification of the model that we have formalized. Formalizing these counter-models would then be a logical extension of the work that we realized to build a model for the theory.

We have already stated our interest in proving that, by adding the continuity axiom, Tarski's system of geometry becomes mutually interpretable with Cartesian planes over a real-closed field. Nonetheless, there is another motivation for doing so. Indeed, the quantifier elimination algorithm for real closed fields has been formalized by Cohen and Mahboubi in [START_REF] Cohen | Formal proofs in real algebraic geometry: from ordered fields to quantifier elimination[END_REF]. So, by mechanizing this proof, we would obtain a formal proof of the fact that Tarski's system of geometry has quantifier elimination. This would prove that the decidability of point equality is sufficient to obtain the decidability of every first-order formula.

Develop the Possibilities for Automation

One more possible extension is the development of possibilities for automation. We noticed that providing a formal justification for the relative position of some points is a tedious task and that Avigad et al. [START_REF] Avigad | A formal system for Euclid's elements[END_REF] have designed a automatic procedure to automate such proofs. In order to ease future developments based on GeoCoq, it could be very useful to implement such a procedure in Coq.

We have now access to the Gröbner basis method and the area method. By adding, for example Wu's complete method and the full-angle method of Chou, Gao and Zhang, we could combine them inside a portfolio to follow the approach proposed by Marinković, Nikolić, Kovács and Janičić [START_REF] Marinković | Portfolio Methods in Theorem Proving for Elementary Geometry[END_REF]. Their approach uses machine learning to select the most appropriate prover inside the portfolio while also estimating whether the provers will be able to prove a conjecture in a given amount of time.

Use our Library as a Basis for Applicative Purposes

The final and broader extension that we consider is to use our library as a basis for applicative purposes. We recall that geometry has many application areas. Hence, it motivates the mechanization of geometry in order to allow the formalization of these areas. There exist already formalizations of some of these areas. We believe that they could benefit from our library.

Narboux developed a graphical user interface to deal with proofs in geometry [START_REF] Narboux | A Graphical User Interface for Formal Proofs in Geometry[END_REF]. The software combines a dynamic geometry software with an automatic theorem prover and a proof assistant (Coq). The proof assistant enable the user to prove statements about the construction made using the dynamic geometry software. Three proof modes are supported. The first one is based on the axioms for the area method, the second one on the axioms proposed by Guilhot for high shool geometry [START_REF] Guilhot | Formalisation en Coq et visualisation d'un cours de géométrie pour le lycée[END_REF], and the third one on Tarski's system of geometry. While we have formalized the proof that the axioms for the area method hold in Tarski's system of geometry, we have not mechanized a similar proof about Guilhot's axioms. Doing so would render possible to unify these proof modes by only assuming Tarski's axioms. Moreover, the automated deduction methods could be used within the proof assistant while the software currently separates the automatic theorem prover from the proof assistant.

Balabonski, Delga, Rieg, Tixeuil and Urbain have formalized a proof of the the gathering problem [BDR + 16]. One solves this problem by gathering a set of robots at the same location in finite time. Their proof is based on the axioms from Coq's standard library for real numbers as well as some geometric properties not proven in this library. By assuming Tarski's axioms, these properties could easily be proved and the axioms for real numbers retrieved, thus reducing the number of axioms. Furthermore, with a view to develop more algorithms, the fact that synthetic and algebraic proofs can be combined with automated deduction methods could prove to be an advantage.

APPENDIX C

Hilbert's Axioms

I. 1. There exists a line passing through any pair of points.

2. Two lines both passing through a pair of distinct points must be equal.

3. There exist at least two points on any given line. 4. There exist a line and a point non-incident to it. II. 1. If a point B is between A and C, then A, B and C are collinear and B is also between C and A. 2. Given a pair of distinct points A and B, there exists a point C such that B is between A and C. 3. Given three points on a line, there is at most one that is between the other two. 4. Given three non-collinear points A, B and C and a line l that passes through a point of the segment AB and does not pass through C, l must pass either through the segment AC or through the segment BC. III. 1. There exists a point on a given side on a line forming a segment congruent to a given segment. 2. If two segments CD and EF are both congruent with a segment AB, then the segment CD is congruent with the segment EF . P , then, they must be equal. V. 1. Given two segments AB and CD, there exist some positive integer n and n + 1 points A 1 , • • • , A n+1 on line CD, such that A j is between A j-1 and A j+1 for 2 < j < n, A j A j+1 and AB are congruent for 1 < j < n, A 1 = C and D is between A n and A n+1 . 2. The set of points on a given line, obeying order and congruence relations, is not susceptible of extension in such a manner that the previous relations and the five groups of axioms are still valid. (31) (Weak inverse projection postulate) For any angle, that, together with itself, make a right angle, any point together with its orthogonal projection on one side of the angle form a line which intersects the other side. (32) (Weak Tarski's parallel postulate) For every right angle and every point T in the interior of the angle, there is a point on each side of the angle such that T is between these two points. (33) (Weak triangle circumscription principle) The perpendicular bisectors of the legs of a right triangle intersect. (34) (Legendre's parallel postulate) There exists an acute angle such that, for every point T in the interior of the angle, there is a point on each side of the angle such that T is between these two points. "Si une droite tombant sur deux droites fait les angles intérieurs du même côté plus petits que deux droits, ces droites, prolongées à l'infini, se rencontreront du côté où les angles sont plus petits que deux droits." Legendre est l'un des mathématiciens à avoir effectué une telle tentative. La démonstration1 de Legendre du postulat des parallèles d'Euclide est basée sur une notion spécifique : le déficit d'un triangle. Le déficit d'un triangle est l'angle qui, avec la somme des angles de ce triangle, forme deux angles droits. En fait, la notion de déficit ne se limite pas aux triangles : par exemple, le déficit d'un quadrilatère est l'angle, qui avec la somme des angles de ce quadrilatère, forme quatre angles droits. Afin de démontrer le postulat des parallèles d'Euclide, Legendre démontre que le déficit de tout triangle est nul, puisque cela est équivalent au postulat des parallèles d'Euclide2 . Nous donnons maintenant un aperc ¸u de la démonstration de Legendre [START_REF] Marie | Réflexions sur différentes manières de démontrer la théorie des parallèles ou le théorème sur la somme des trois angles du triangle[END_REF] que le déficit de tout triangle est nul.

Theorem. Le déficit de tout triangle est nul. Grâce à la découverte de la géométrie non euclidienne, le statut de postulat du postulat des parallèles d'Euclide a été confirmé, assurant ainsi que la démonstration de Legendre est incorrecte. Examinons donc cette démonstration pour trouver la raison pour laquelle elle ne constitue pas une preuve.

B i ) i∈N et (C i ) i∈N telles que B 0 = B, C 0 = C et D(△AB i+1 C i+1 ) > 2 D(△AB i C i ) pour i ∈ N. B 0 et C 0 sont
La première assertion faite dans cette démonstration est que le déficit de tout triangle est soit positif, soit nul. Saccheri est le premier mathématicien à avoir examiné le cas où le postulat des parallèles d'Euclide ne serait pas vérifié [START_REF] Girolamo | Euclides ab omni naevo vindicatus[END_REF]. Ce faisant, il a posé trois hypothèses qui peuvent toutes être vérifiées. Ces hypothèses sont connues sous le nom des trois hypothèses de Saccheri. Elles portent sur un type de quadrilatères spécifique que nous examinons au chapitre II.4. Saccheri a établi qu'une seule de ces hypothèses pouvait être vérifiée et que chacune de ces hypothèses implique que le déficit de tout triangle est, respectivement, positif, nul ou négatif. Ensuite, il a prouvé que l'hypothèse impliquant que le déficit de tout triangle soit négatif était absolument fausse. Néanmoins, il existe des géométries dans lesquelles le déficit de tout triangle est négatif comme la géométrie elliptique [START_REF] Cerroni | Some models of geometries after Hilbert's Grundlagen[END_REF]. Cela semble contredire les conclusions de Saccheri, mais en fait, ce n'est pas le cas. En effet, Saccheri effectuait ses études dans ce qu'on appelle la géométrie neutre (ou plans de Hilbert) où le déficit de tout triangle ne peut pas être négatif. La géométrie neutre est définie par l'ensemble des axiomes de la géométrie euclidienne dont on retire le postulat des parallèles. Par conséquent, la raison pour laquelle Legendre n'a pas démontré le postulat des parallèles doit être ailleurs.

L'étape logique qui peut ensuite être remise en question est l'hypothèse que, étant donné D(△ABC) > 0, il existe un entier n tel que 2 n D(△ABC) > π. Afin d'affirmer l'existence d'un tel entier n, l'axiome suivant, connu sous le nom d'axiome d'Archimède, doit être admis. L'axiome d'Archimède peut être exprimé de la manière suivante. Étant donnés deux segments AB et CD, avec A différent de B, il existe un entier positif n et n + 1 points A 1 , • • • , A n+1 sur la droite CD, de sorte que A j est compris entre A j-1 et A j+1 pour 2 < j < n, A j A j+1 et AB sont congruents pour 1 < j < n, A 1 = C et D est entre A n et A n+1 . En fait, cet axiome était déjà implicitement utilisé. En effet, la preuve de Saccheri que le déficit de tout triangle est positif ou nul est basée sur l'axiome d'Archimède. La dernière utilisation de l'axiome d'Archimède aurait pu être plus facilement manquée : l'additivité du déficit pour des polygones particuliers. Cette propriété n'est vraie que lorsque l'axiome d'Archimède est supposé parce qu'elle repose sur l'associativité de la somme des angles qui n'est valable que lorsque les angles considérés font moins de deux angles droits. Cette dernière condition ne peut être remplie si le déficit d'un triangle est négatif, ce qui rend l'axiome d'Archimède nécessaire.

Ensuite, nous avons laissé entendre qu'il y a différentes significations de la notion d'équivalence au postulat des parallèles d'Euclide. Nous avons vu que l'importance du système axiomatique que nous admettons. Ainsi, on pourrait penser que, pour que la propriété que le déficit de tout triangle est nul soit équivalent au postulat des parallèle d'Euclide, un axiome supplémentaire pourrait être nécessaire et que cet axiome pourrait rendre le système axiomatique incohérent en supposant, par exemple, l'axiome d'Archimède. En fait, un axiome supplémentaire est en effet nécessaire pour que cette propriété soit équivalente au postulat des parallèles d'Euclide. Cependant, puisque l'axiome d'Archimède est suffisant pour démontrer l'équivalence, nous n'avons toujours pas trouvé la raison expliquant pourquoi la démonstration de Legendre est incorrecte. En fait, la raison est très fréquente parmi les démonstration erronées du postulat des parallèles d'Euclide : une assertion équivalente à ce postulat est implicitement utilisée. Ici, l'hypothèse implicite est faite lorsqu'on affirme l'existence d'une droite l passant par D i qui intersecte les deux côtés de ∠BAC en B i+1 et C i+1 .

La recherche de la source de l'incorrection dans la démonstration de Legendre nous a permis de souligner l'importance de connaître les hypothèses exactes faites pour une preuve. Cela rend l'utilisation d'un assistant de preuve attrayante comme moyen d'éviter les hypothèses implicites, car ils n'acceptent une démonstration que si toutes les étapes sont détaillées en fonction de leurs règles. Si le processus d'écriture de démonstration à ce niveau de détail entraîne un coût évident, la récompense le justifie : ces démonstrations présentent un niveau de confiance beaucoup plus élevé dont ont bénéficié aussi bien les mathématiques que les logiciels.

Formalisation des mathématiques et vérification des logiciels

La capacité des assistants de preuve à traiter des démonstrations très longues et complexes a été mise à profit pour convaincre la communauté mathématique de l'état de théorème de plusieurs propriétés. Ces dernières années, des revues de mathématiques ont rec ¸u des démonstrations si longues et si compliquées que, pour que ces démonstrations soient reconnues comme telles, elles ont dû être formalisées dans un assistant de preuve. Le premier d'entre eux fut le théorème des quatre couleurs [START_REF] Appel | Every planar map is four colorable[END_REF]. Le théorème des quatre couleurs établit que n'importe quel graphe planaire peut être colorié de telle manière que les couleurs de deux sommets adjacents ne soient pas identiques, en n'utilisant que quatre couleurs différentes. En raison de l'implication d'un programme informatique dans la démonstration d'Appel et Haken, elle n'a été universellement acceptée que lorsque Gonthier et Werner [Gon04, Gon07] l'ont formalisée dans l'assistant de preuve Coq [START_REF]The Coq Proof Assistant[END_REF]. Le deuxième théorème à avoir obtenu son statut grâce à une formalisation de sa preuve dans un assistant de preuve est le théorème de l'ordre impair de Feit-Thompson [START_REF] Feit | Solvability of groups of odd order[END_REF]. Ce théorème, qui exprime que tout groupe d'ordre impair est résoluble, a été controversé en raison de la longueur de sa preuve : 255 pages. La formalisation en Coq de la preuve de Feit et Thompson a été effectuée par une équipe dirigée par Gonthier [GAA + 13]. Le dernier résultat mathématique de ce type est la preuve de Hales de la conjecture de Kepler [START_REF] Callister | The Kepler conjecture[END_REF]. Comme pour le théorème des quatre couleurs, la controverse autour de cette preuve s'explique par le fait qu'elle repose sur un programme informatique. Pour clore le débat, Hales a dirigé une équipe qui a complété la formalisation de sa preuve [HAB + 17] en HOL-Light [START_REF] Harrison | HOL Light: A tutorial introduction[END_REF] et en Isabelle [START_REF] Nipkow | Isabelle/HOL: A Proof Assistant for Higherorder Logic[END_REF]. Bien que leur preuve n'ait pas été remise en cause par la communauté mathématique, deux autres théorèmes majeurs ont été formalisés dans des assistants de preuve : le théorème des nombres premiers, vérifié en Isabelle par Avigad, Donnelly, Gray et Raff [START_REF] Avigad | A Formally Verified Proof of the Prime Number Theorem[END_REF] ainsi qu'en HOL-Light par Harrison [START_REF] Harrison | Formalizing an Analytic Proof of the Prime Number Theorem[END_REF], et le théorème de Jordan formalisé en HOL-Light par Hales [START_REF] Callister | The Jordan Curve Theorem, Formally and Informally[END_REF].

Les assistants de preuve ne se sont pas limités à la formalisation des mathématiques. Ils ont également été utilisés pour certifier des programmes informatiques. Certains programmes sont tellement critiques qu'en prouvant qu'ils sont dépourvus de bogues ou qu'ils respectent leurs spécifications, on peut éviter des pertes importantes, qu'elles soient économiques, industrielles ou même humaines. De nos jours, l'utilisation de programmes informatiques dans les industries aérospatiale, financière, médicale ou nucléaire justifie le besoin de logiciels certifiés pour éviter de telles pertes. Pour atteindre cet objectif, plusieurs formalisations ont été menées dans le cadre de l'informatique. La plus remarquable étant probablement la vérification formelle de la correction du micro-noyau seL4 en Isabelle, obtenue par une équipe dirigée par Klein [KEH + 09]. Cette certification assure la correction du comportement du micro-noyau selon ses spécifications ainsi que l'absence de bogues tels que les interblocages, les dépassements de tampon ou les exceptions arithmétiques. L'autre effort de formalisation en informatique que nous aimerions mentionner a été complété par une équipe dirigée par Leroy [START_REF] Leroy | Formal Certification of a Compiler Back-end or: Programming a Compiler with a Proof Assistant[END_REF]. Ils ont effectué la spécification, l'implémentation et la vérification formelle du compilateur C CompCert en Coq.

Formalisation de la géométrie

Une autre fac ¸on d'exploiter la puissance des ordinateurs dans le but de prouver des théorèmes est de tirer parti de leurs capacités de calcul. En raison du succès de l'application de la démonstration automatique de théorèmes à la géométrie, nous nous y intéressons dans la partie III. Néanmoins, la géométrie a également été un important sujet de recherche en démonstration interactive de théorèmes. La majeure partie de cette recherche a été consacrée à la géométrie euclidienne. De fait, dans la partie I, nous nous concentrons sur la formalisation de la géométrie euclidienne. Outre la géométrie euclidienne, le géométrie projective a également été étudiée en utilisant des assistants de preuve. Magaud, Narboux et Schreck ont proposé des alternatives aux systèmes axiomatiques traditionnels [START_REF] Coxeter | Projective Geometry[END_REF] pour la géométrie projective du plan et de l'espace basées sur la notion de rang et ont vérifié en utilisant Coq que la propriété de Desargues est un théorème de cette dernière [START_REF] Magaud | A Case Study in Formalizing Projective Geometry in Coq: Desargues Theorem[END_REF]. L'interprétabilité mutuelle de leurs systèmes avec les systèmes traditionnels a ensuite été formellement prouvée par Braun, Magaud et Schreck dans Coq [START_REF] Braun | An Equivalence Proof Between Rank Theory and Incidence Projective Geometry[END_REF]. De plus, la formalisation de la géométrie complexe a été étudiée par Marić et Petrović [START_REF] Marić | Formalizing Complex Plane Geometry[END_REF]. Ils ont défini le plan complexe étendu à la fois en termes de droites projectives complexes et comme la projection stéréographique de la sphère de Riemann pour étudier les transformations de Möbius et les cercles généralisés.

Bien que n'étant pas des branches de la géométrie, deux domaines fortement liés à la géométrie ont fait l'objet d'importants efforts de formalisation : l'analyse non standard et la géométrie algorithmique. L'analyse non standard est le domaine dédié à l'analyse des infinitésimaux par des nombres hyperréels. Fleuriot a formalisé des notions d'analyse non standard en géométrie en Isabelle pour mécaniser la partie géométrique des Principia de Newton [START_REF] Fleuriot | Theorem Proving in Infinitesimal Geometry[END_REF] et la deuxième loi de Kepler [START_REF] Fleuriot | Nonstandard Geometric Proofs[END_REF] en utilisant des méthodes de démonstration automatique de théorèmes. De plus, le modèle discret du continuum connu sous le nom de droite de Harthong-Reeb a été formalisé en Coq par Magaud, Chollet et Fuchs [START_REF] Magaud | Formalizing a Discrete Model of the Continuum in Coq from a Discrete Geometry Perspective[END_REF] et en Isabelle par Fleuriot [START_REF] Fleuriot | Exploring the Foundations of Discrete Analytical Geometry in Isabelle/HOL[END_REF]. La géométrie algorithmique est l'étude des structures de données et des algorithmes utilisés pour résoudre les problèmes géométriques. En Coq, la formalisation des cartes et hypercartes combinatoires a été réalisée respectivement par Puitg et Dufourd [START_REF] Franc | Formal specification and theorem proving breakthroughs in geometric modeling[END_REF] ainsi que par Dehlinger et Dufourd [START_REF] Dehlinger | Formalizing generalized maps in Coq[END_REF], et par Dufourd [START_REF] Dufourd | A Hypermap Framework for Computer-aided Proofs in Surface Subdivisions: Genus Theorem and Euler's Formula[END_REF]. Ces structures ont permis de prouver formellement la correction de plusieurs algorithmes tels que l'algorithme de triangulation du plan de Delaunay, étudié par Dufourd et Bertot [START_REF] Dufourd | Formal study of plane Delaunay triangulation[END_REF] en Coq. De plus, divers algorithmes de calcul de l'enveloppe convexe ont également été prouvés corrects par Pichardie et Bertot [START_REF] Pichardie | Formalizing Convex Hull Algorithms[END_REF] en Coq, par Meikle et Fleuriot [START_REF] Meikle | Mechanical Theorem Proving in Computational Geometry[END_REF] en Isabelle, et par Brun, Dufourd et Magaud [START_REF] Brun | Formal Proof in Coq and Derivation of a Program in C++ to Compute Convex Hulls[END_REF] en Coq.

Nous invitons le lecteur à consulter [START_REF] Narboux | Computer-assisted Theorem Proving in Synthetic Geometry[END_REF] pour une description plus exhaustive des formulations existantes de la géométrie.

Cette thèse

Toutes ces réussites dans le domaine de la démonstration interactive de théorèmes motivent davantage la formalisation de la géométrie. Or, nous avons déjà mentionné trois systèmes axiomatiques pour la géométrie euclidienne : les axiomes d'Euclide, de Hilbert et de Tarski. Par conséquent, la question qui se pose naturellement est : Quel système axiomatique devrions-nous formaliser pour mécaniser un développement systématique de la géométrie ? Cette question est relative aux fondements de la géométrie qui s'intéressent aux systèmes axiomatiques pour la géométrie et à leurs métathéorèmes. Ces métathéorèmes fournissent des arguments pour le choix d'un système axiomatique. Une fois qu'un système axiomatique a été choisi pour ses propriétés métathéoriques, il semble attrayant de ne pas se limiter à la formalisation d'un développement systématique basé sur ce système mais aussi de formaliser les preuves de ces propriétés. Cependant, les propriétés métathéoriques ne sont pas seulement relatives aux théories géométriques mais aussi à la logique. En mathématiques constructives, où le principe du tiers exclu et l'axiome du choix ne sont pas admis, le choix de la version du postulat des parallèles est crucial pour un "théorème du folklore mathématique" exprimant l'interprétabilité mutuelle des systèmes axiomatiques de Hilbert et Tarski. Ce théorème est basé sur le résultat culminant des développements de Hilbert [START_REF] Hilbert | Foundations of Geometry (Grundlagen der Geometrie[END_REF] et Tarski [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF], à savoir l'arithmétisation de la géométrie euclidienne. Néanmoins, comme nous le voyons dans cette thèse, en mathématiques constructives, l'arithmétisation de la géométrie euclidienne, telle que définie par Descartes, ne peut être réalisée avec certaines versions du postulat des parallèles, de sorte que la validité de ce théorème dépend soit du choix de la logique soit de celui de la version du postulat des parallèles. Aussi tentante que puisse être l'étude des raffinements nécessaires pour que certaines propriétés métathéoriques restent valables en mathématiques constructives, il est assez facile de négliger les utilisations d'énoncés qui ne sont pas valables en mathématiques constructives [START_REF] Schechter | Constructivism is difficult[END_REF]. Avoir un moyen mécanique de garantir qu'une preuve est effectivement constructive peut alors être critique, ce qui rend les assistants de preuve basés sur des théories des types intuitionnistes particulièrement attractifs pour effectuer ce type d'études.

Dans cette thèse, notre objectif est d'étendre la bibliothèque GeoCoq et d'étudier simultanément ses fondements axiomatiques sous un angle métathéorique. La bibliothèque GeoCoq fournit un développement formel de géométrie basé sur le système axiomatique de Tarski [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] qui peut être trouvé sur le lien suivant : http://geocoq.github.io/GeoCoq/ Le système axiomatique de Tarski a été choisi comme base pour cette bibliothèque pour ses propriétés métamathématiques, les plus pertinentes étant sa cohérence et son complétude [START_REF] Tarski | Tarski's System of Geometry[END_REF]. Le développement est effectué dans l'assistant de preuve Coq, qui, dans le but d'étudier les propriétés métathéoriques en mathématiques constructives, est commodément basé sur une théorie des types intuitionniste. La théorie derrière Coq est le calcul des constructions inductives [START_REF] Coquand | Inductively defined types[END_REF] qui unifie la théorie des types intuitionniste de Per Martin-Löf [START_REF] Martin-Löf | Intuitionistic Type Theory[END_REF] et le calcul des constructions [START_REF] Coquand | The Calculus of Constructions[END_REF]. Le lecteur non familier avec Coq ou SSReflect, qui seront utilisés dans cette thèse, peut trouver dans le Coq'Art [START_REF] Bertot | Interactive Theorem Proving and Program Development, Coq'Art: The Calculus of Inductive Constructions[END_REF] et le manuel d'utilisation de SSReflect [GMT16] des présentations de cet assistant de preuve et de son extension.

Les principales contributions de cette thèse peuvent être résumées comme suit :

• Dans le contexte du système axiomatique de Tarski, nous avons défini les opérations arithmétiques géométriquement et formalisé la preuve qu'elles permettent de vérifier les propriétés d'un corps ordonné. • Nous avons formalisé que les plans cartésiens sur un corps pythagoricien ordonné forment un modèle du système axiomatique de Tarski (à l'exception de l'axiomes de continuité). • Nous avons formellement prouvé que les axiomes de Tarski pour la géométrie neutre du plan peuvent être dérivés des axiomes de Hilbert correspondants. • Nous avons utilisé le théorème de Herbrand pour donner une nouvelle preuve que l'axiome des parallèles d'Euclide n'est pas dérivable des autres axiomes de la géométrie euclidienne du premier ordre. • Nous avons prouvé que, en abandonnant le principe du tiers exclu, la décidabilité de l'égalité des points est suffisante pour obtenir l'arithmétisation de la géométrie de Tarski. • Nous avons clarifié les conditions sous lesquelles les différentes versions du postulat des parallèles sont équivalentes et formalisé les preuves d'équivalence. • Nous avons mis en place une tactique réflexive pour générer automatiquement des preuves d'incidence à des variétés affines. • Dans le contexte du système axiomatique de Tarski, nous avons introduit les coordonnées cartésiennes et fourni des caractérisations aux principaux prédicats géométriques, ce qui a permis l'utilisation de méthodes algébriques de déduction automatique en géométrie synthétique. La plupart de ces contributions ont déjà été décrites dans les articles suivants :

• Cette thèse rassemble ces documents sous une forme légèrement modifiée. Le chapitre III.1 contient une généralisation de l'une des procédures présentées dans :

• Pierre Boutry, Julien Narboux, Pascal Schreck, and Gabriel Braun. Using small scale automation to improve both accessibility and readability of formal proofs in geometry. In Francisco Botana and Pedro Quaresma, editors, Proceedings of the Tenth International Workshop on Automated Deduction in Geometry, Proceedings of ADG 2014, pages 31-49, Coimbra, Portugal, July 2014 Chapitre I.1 section 2 décrit un travail n'ayant pas encore été publié qui a été réalisé en collaboration avec Cyril Cohen. Nous tenons à préciser que, bien que nous ayons collaboré à la rédaction de la plupart des parties de ces articles, l'article intitulé Herbrand's theorem and non-Euclidean geometry a été presque entièrement écrit par Michael Beeson. Nous avions trouvé une preuve informelle de l'indépendance du postulat des parallèles dans le système axiomatique de Tarski (à l'exception de l'axiomes de continuité) n'étant pas basée sur la construction un modèle de non géométrie euclidienne que nous lui avons présentée. Il a ensuite eu l'idée d'utiliser le théorème de Herbrand pour formaliser notre argument, l'a étendu au système axiomatique de Tarski avec axiome de continuité en utilisant la "borne de Cauchy" et a écrit l'article pour lequel nous avons seulement proposé quelques modifications.

La formalisation décrite dans cette thèse est le fruit d'un travail collaboratif. Par conséquent, nous nous abstiendrons de fournir des données telles que le nombre de lignes de code, de définitions ou de lemmes concernant ce développement. Néanmoins, nous avons collaboré à la plupart des parties de ce développement. Par exemple, même pour la formalisation de l'arithmétisation du système axiomatique de Tarski, où les derniers chapitres de [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] à formaliser étaient clairement répartis entre les contributeurs, nous avons formalisé des résultats supplémentaires qui n'étaient pas inclus dans les chapitres de [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] attribués aux autres contributeurs afin de compléter notre partie de formalisation.

Le reste de cette thèse est organisé comme suit. La partie I présente nos résultats sur la formalisation des fondements de la géométrie euclidienne. Dans cette partie, nous nous concentrons sur le système axiomatique de Tarski : nous mécanisons son arithmétisation et la preuve de sa satisfiabilité. En outre, nous prouvons formellement l'interprétabilité mutuelle des axiomes de Hilbert et du système axiomatique de Tarski, et exposons notre preuve que le postulat des parallèles d'Euclide n'est pas dérivable des autres axiomes de la géométrie euclidienne du premier ordre et nos progrès pour obtenir la décidabilité de toute formule du premier ordre. La partie II est consacrée à la clarification des conditions dans lesquelles les différentes versions du postulats des parallèles sont équivalentes et à la formalisation des preuves d'équivalence. Dans cette partie, nous affinons la classification des plans de Hilbert de Pejas [START_REF] Pejas | Die Modelle des Hilbertschen Axiomensystems der absoluten Geometrie[END_REF] dans le contexte des mathématiques constructives, dérivons une équivalence surprenante entre des axiomes de continuité et une propriété de décidabilité et formalisons une variante du théorème de Szmielew qui exprime que chaque énoncé faux en géométrie hyperbolique et correct en géométrie euclidienne est équivalent à un postulat des parallèles. Enfin, nous décrivons nos travaux sur la démonstration automatique de théorèmes en géométrie dans la partie III. Dans cette partie, nous développons une tactique réflexive pour générer automatiquement des preuves d'incidence à des variétés affines qui a été utilisée dans le reste de la formalisation présentée dans cette thèse, présentons notre approche basée sur le bootstrap pour obtenir les caractérisations des prédicats géométriques, et illustrons l'utilisation concrète de notre formalisation avec plusieurs applications de la méthode Gröbner en géométrie synthétique.

Fondements de la géométrie euclidienne

Il y a plusieurs fac ¸ons de définir les fondements de la géométrie euclidienne sur lesquels nous nous concentrons dans cette partie. Dans l'approche synthétique, le système axiomatique est basé sur des objets géométriques et des axiomes à leur sujet. Les systèmes axiomatiques modernes les plus connus basés sur cette approche sont ceux de Hilbert [START_REF] Hilbert | Foundations of Geometry (Grundlagen der Geometrie[END_REF] et Tarski [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] 3 . Les lecteurs qui ne connaissent pas le système axiomatique de Tarski peuvent également se référer à [TG99] qui décrit ses axiomes et leur histoire. Dans l'approche analytique, un corps F est supposé (habituellement R) et l'espace est défini comme F n . Dans l'approche mixte analytique/synthétique, on suppose à la fois l'existence d'un corps et aussi de quelques axiomes géométriques. Par exemple, les systèmes axiomatiques proposés par le School Mathematics Study Group pour l'enseignement de 3 La première version de ce système axiomatique est apparue comme note de l'article de Tarski concernant sa méthode de décision pour les corps réels clos [START_REF] Tarski | A Decision Method for Elementary Algebra and Geometry[END_REF]. la géométrie au secondaire [START_REF]Mathematics for high school: Geometry. Teacher's commentary[END_REF] en Amérique du Nord dans les années 1960 sont basés sur le système axiomatique de Birkhoff [START_REF] David | A Set of Postulates for Plane Geometry, Based on Scale and Protractor[END_REF]. Dans ce système d'axiomes, on suppose l'existence d'un corps pour mesurer les distances et les angles. C'est ce qu'on appelle l'approche métrique. Un développement moderne de la géométrie basé sur cette approche peut être trouvé dans les livres de Millman ou Moise [START_REF] Millman | Geometry: A Metric Approach with Models[END_REF][START_REF] Moise | Elementary Geometry from an Advanced Standpoint[END_REF]. L'approche métrique est également utilisée par Chou, Gao et Zhang pour la définition de la méthode des aires [START_REF] Chou | Machine Proofs in Geometry[END_REF] (une méthode de déduction automatique en géométrie). Comme le système axiomatique de Birkhoff, le corps sert à mesurer les rapports entre les distances et les aires signées. La formalisation en Coq des axiomes se trouve dans [START_REF] Janičić | The Area Method : a Recapitulation[END_REF]. Enfin, dans l'approche relativement moderne des fondements de la géométrie, une géométrie est définie comme un espace d'objets et un ensemble de transformations agissant sur ceux-ci (programme d'Erlangen [START_REF] Klein | A comparative review of recent researches in geometry[END_REF][START_REF] Klein | Vergleichende Betrachtungen über neuere geometrische Forschungen[END_REF]).

Bien que ces approches semblent très différentes, Descartes a prouvé que l'approche analytique peut être dérivée de l'approche synthétique en définissant l'addition, la multiplication et la racines carrée géométriquement [START_REF] Descartes | La Géométrie. Open Court[END_REF]. C'est ce qu'on appelle l'arithmétisation et la coordinatisation de la géométrie et elle représente le résultat culminant de [START_REF] Hilbert | Foundations of Geometry (Grundlagen der Geometrie[END_REF] et de [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF].

À notre connaissance, il n'existait aucune formalisation de l'arithmétisation de la géométrie euclidienne du plan dans un assistant de preuve. Cependant la connexion inverse, à savoir que le plan euclidien est un modèle de cette géométrie axiomatisée, a été mécanisée par Petrović et Marić [START_REF] Petrović | Formalizing Analytic Geometries[END_REF] Certaines de ces approches ont également fait l'objet d'études métamathématiques. L'un des premiers résultats métamathématiques a été la preuve de l'indépendance du postulat des parallèles. Bolyai [START_REF] Bolyai | Appendix, Scientiam Spatii absolute veram exhibens[END_REF] et Lobachevsky [START_REF] Lobatschewsky | Geometrische Untersuchungen zur Theorie der Parallellinien[END_REF] ont publié les premiers développements sur la géométrie non euclidienne qui ont conduit à la preuve d'indépendance de Beltrami [START_REF] Beltrami | Saggio di interpretazione della geometria Non-Euclidea[END_REF]. Dans sa thèse [START_REF] Narayan | Contributions to the Axiomatic Foundations of Geometry[END_REF], Gupta a présenté une variante du système axiomatique de Tarski dont il a prouvé l'indépendance en fournissant des modèles d'indépendance. En suivant l'approche classique pour prouver que le cinquième postulat d'Euclide n'est pas un théorème de la géométrie neutre5 , Makarios a fourni une preuve formelle de l'indépendance de la variante de ce postulat choisie par Tarski pour son système axiomatique [START_REF] James | A Mechanical Verification of the Independence of Tarski's Euclidean Axiom[END_REF]. Il a utilisé l'assistant de preuve Isabelle pour construire le modèle de Klein-Beltrami, dans lequel le postulat n'est pas vérifié. Cette indépendance a également été prouvée sans construire un modèle de géométrie non euclidienne. Déjà en 1920, Skolem [START_REF] Skolem | Logisch-kombinatorische Untersuchungen über die Erfüllbarkeit mathematischer Satzsysteme, nebst einem Theoreme über dichte Mengen[END_REF] a prouvé l'indépendance d'une forme de l'axiome des parallèles des autres axiomes de la géométrie projective, en utilisant des méthodes similaires au théorème de Herbrand. En 1944, Ketonen a inventé le système du calcul des séquents rendu célèbre par Kleene [START_REF] Cole | Introduction to Metamathematics[END_REF] sous le nom de G3, et l'a utilisé pour modifier le résultat de Skolem et l'étendre à la géométrie affine. Ce résultat a été reformulé en 2001 par von Plato [vP01] en utilisant un autre calcul des séquents. Il convient de noter que la preuve moderne du théorème de Herbrand procède également par élimination des coupures dans le calcul des séquents. Plus récemment, de nouvelles approches synthétiques ont été proposées. Ces nouvelles approches diffèrent des précédentes parce que ce sont des axiomatisations intuitionnistes. Le premier système d'axiome était dû à Heyting [START_REF] Heyting | Axioms for Intuitionistic Plane Affine Geometry[END_REF] qui a introduit le concept d'apartness. Plus tard, von Plato a présenté une extension de ce travail qu'il a implémenté en théorie des types [vP95]. Enfin, Beeson a donné une version constructive des axiomes de Hilbert [START_REF] Beeson | Constructive Geometry[END_REF] et de Tarski [START_REF] Beeson | A Constructive Version of Tarski's Geometry[END_REF] et a prouvé plusieurs métathéorèmes sur ses systèmes axiomatiques.

Nous avons montré l'interprétabilité mutuelle de deux systèmes basés sur l'approche synthétique (les axiomes de Hilbert et le système axiomatique de Tarski) et l'approche analytique. En plus de mécaniser la preuve de la satisfiabilité des deux systèmes, nous avons formalisé l'arithmétisation du système axiomatique de Tarski qui, grâce à l'interprétabilité mutuelle des axiomes de Hilbert et de Tarski, fournit également une preuve formelle de l'arithmétisation de la géométrie basée sur les axiomes de Hilbert. Nous avons donné une nouvelle preuve du fait que le postulat des parallèles d'Euclide n'est pas dérivable des autres axiomes de la géométrie euclidienne du premier ordre. Nous devons faire remarquer que bien que nous avons prouvé l'interprétabilité mutuelle des théories pour la géométrie neutre basées sur les axiomes de Hilbert et de Tarski, notre preuve ne permet pas d'obtenir une preuve d'indépendance du postulat des parallèle pour les axioms de Hilbert. En effet, pour des raisons que nous exposons dans la partie suivante, la version du postulat des parallèles choisie par Hilbert est plus faible que celle que nous avons étudiée et notre preuve ne peut pas être adaptée pour cette version spécifique. La principale contribution de ce travail est que nous avons prouvé l'indépendance sans réellement construire un modèle de géométrie non euclidienne. Enfin, nous avons démontré que la décidabilité de l'égalité de points dans le contexte du système axiomatique de Tarski est suffisante pour obtenir l'arithmétisation de la géométrie euclidienne. De plus, nous avons prouvé que nous pouvons supposer de manière équivalente la décidabilité de l'un de ses trois prédicats (betweenness, congruence ou égalité de points).

Postulats des parallèles et axiomes de continuité dans la logique intuitionniste

Dans cette partie, nous nous concentrons sur la formalisation des résultats concernant le cinquième postulat d'Euclide :

"Si une droite tombant sur deux droites fait les angles intérieurs du même côté plus petits que deux droits, ces droites, prolongées à l'infini, se rencontreront du côté où les angles sont plus petits que deux droits." L'importance historique de ce postulat est due au fait que durant des siècles, de nombreux mathématiciens ont cru que cette énoncé était plutôt un théorème qui pourrait être dérivé des quatre premiers postulats d'Euclide. L'histoire est riche en preuves incorrectes du cinquième postulat d'Euclide. En 1763, Klügel a fourni, dans sa thèse rédigée sous la direction de Kästner, une examen d'environ 30 tentatives pour "prouver le postulat des parallèles d'Euclide" [START_REF] Simon | Conatuum praecipuorum theoriam parallelarum demonstrandi recensio[END_REF]. Legendre a publié un manuel de géométrie Eléments de géométrie en 1774. Chaque édition de ce livre populaire contenait une preuve (incorrecte) du postulat des parallèles d'Euclide. Même en 1833, un an après la publication par Bolyai d'une annexe sur la géométrie non euclidienne, Legendre était encore convaincu de la validité de ses preuves du cinquième postulat d'Euclide :

"Il n'en est pas moins certain que le théorème sur la somme des trois angles du triangle doit être regardé comme l'une de ces vérités fondamentales qu'il est impossible de contester, et qui sont un exemple toujours subsistant de la certitude mathématique qu'on recherche sans cesse et qu'on n'obtient que bien difficilement dans les autres branches des connaissances humaines." -Adrien Marie Legendre [START_REF] Marie | Réflexions sur différentes manières de démontrer la théorie des parallèles ou le théorème sur la somme des trois angles du triangle[END_REF] Ces preuves sont incorrectes pour différentes raisons. Certaines preuves reposent sur une hypothèse plus ou moins explicite mais que l'auteur considère comme acquise. D'autres preuves sont incorrectes parce qu'elles reposent sur un argument circulaire.

Pour prouver l'équivalence des différentes versions du postulat des parallèles, il faut faire preuve d'une extrême rigueur, comme l'a écrit Richard J. Trudeau :

"Pursuing the project faithfully will require that we take the extreme measure of shutting out the entreaties of our intuitions and imaginations -a forced separation of mental powers that will quite understandably be confusing and difficult to maintain [...]."6 -Richard J. Trudeau [START_REF] Trudeau | The Non-Euclidean Revolution[END_REF] Pour nous aider dans cette tâche, nous avons un outil parfait qui ne possède aucune intuition : un ordinateur. Dans cette partie, nous fournissons des preuves formelles, vérifiées à l'aide de l'assistant de preuve Coq, de l'équivalence de différentes versions du cinquième postulat d'Euclide dans la théorie définie par un sous-ensemble des axiomes de la géométrie de Tarski, à savoir la géométrie neutre du plan en admettant l'axiome d'Archimède. Nous fournissons également des résultats plus précis montrant l'équivalence en logique intuitionniste de quatre groupes d'axiomes sans aucune hypothèse de continuité.

Nos preuves formelles reposent sur le développement systématique de la géométrie basée sur le système axiomatique de Tarski [START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF] que Schwabhäuser, Szmielew et Tarski ont produit. Ces résultats ont été formalisés précédemment [Nar07b, BN12, BN17] en utilisant l'assistant de preuve Coq, et complétés par quelques nouveaux résultats en géométrie neutre pour les besoins de cette étude. Grâce aux résultats de la partie précédente, toutes nos preuves sont également valables dans le contexte des axiomes de Hilbert. L'équivalence entre vingt-six versions du cinquième postulat d'Euclide peut être trouvée dans [START_REF] Edward | The Foundations of Geometry and the Non-Euclidean Plane[END_REF]. Greenberg prouve également (ou laisse comme exercices) l'équivalence entre plusieurs versions du postulat des parallèles [START_REF] Jay | Euclidean and Non-Euclidean Geometries -Development and History[END_REF]. Cependant, ces preuves ne sont pas vérifiées mécaniquement et parfois seulement esquissées. De plus, puisque nous nous limitons à la logique intuitionniste et que nous n'utilisons les axiomes de continuité que lorsque c'est nécessaire, nous ne pourrions pas réutiliser directement toutes ces preuves dans notre contexte, car certaines preuves de ces livres utilisent le principe du tiers exclu ou un axiome de continuité. Récemment, Michael Beeson a également étudié l'équivalence de différentes versions du postulat des parallèles dans le contexte d'une géométrie constructive [START_REF] Beeson | Constructive Geometry and the Parallel Postulate[END_REF].

Nous avons décrit la formalisation au sein de l'assistant de preuve Coq de la preuve que 34 versions du postulat des parallèles sont équivalentes. L'originalité de nos preuves repose sur le fait que d'une part, l'équivalence entre ces différentes versions est prouvée dans la géométrie neutre de Tarski sans utiliser l'axiome de continuité ni la continuité cercle-droite, et d'autre part, nous travaillons dans une logique intuitionniste. En supposant la décidabilité de l'égalité des points, nous avons clarifié le rôle de la décidabilité de l'intersection des droites : nous avons obtenu la preuve formelle que si l'égalité des points est décidable, certaines versions du postulat des parallèles impliquent la décidabilité de l'intersection des droites. L'utilisation d'un assistant de preuve était cruciale pour vérifier ces preuves. En effet, il est extrêmement facile de faire une erreur dans une preuve papier dans ce contexte. Nous devons veiller à ne pas utiliser les nombreux énoncés équivalents au postulat des parallèles et à ne pas utiliser de raisonnement classique.

Démonstration automatique de théorème en géométrie

Dans cette partie, nous nous concentrons sur l'application de la démonstration automatique de théorèmes à la géométrie, l'un des domaines dans lesquels elle a été très fructueuse. En fait, l'un des premiers programmes d'intelligence artificielle a été conc ¸u pour produire des preuves lisibles pour des théorèmes géométriques [START_REF] Gelernter | Realization of a geometry theorem machine[END_REF]. Depuis, plusieurs méthodes efficaces ont été mises au point. Les plus populaires sont la méthode des bases de Gröbner de Buchberger et Winkler [START_REF] Buchberger | Gröbner Bases and Applications[END_REF], la méthode de Wu [Wu78, Cho88, Wan01], la décomposition algébrique cylindrique de Collins [START_REF] Edwin | Quantifier Elimination for Real Closed Fields by Cylindrical Algebraic Decomposition[END_REF], la méthode des aires et la méthode des angles de Chou, Gao et Zhang [START_REF] Chou | Machine Proofs in Geometry[END_REF] et les algèbres géométriques de Lu [START_REF] Li | Automated Geometric Theorem Proving, Clifford Bracket Algebra and Clifford Expansions[END_REF]. Il est à noter qu'une procédure de décision pour la théorie que nous utilisons a été donnée par Tarski Ces méthodes peuvent être divisées en trois catégories : les méthodes synthétiques [START_REF] Gelernter | Realization of a geometry theorem machine[END_REF], les méthodes algébriques [BW98, Wu78, Cho88, Wan01, Col75]et les méthodes sans coordonnées [START_REF] Chou | Machine Proofs in Geometry[END_REF][START_REF] Li | Automated Geometric Theorem Proving, Clifford Bracket Algebra and Clifford Expansions[END_REF]. Bien que les méthodes de déduction synthétiques soient généralement les moins puissantes, elles ont l'avantage d'être plus lisibles et ne nécessitent pas l'arithmétisation de la géométrie. Cela implique que ces méthodes peuvent être utilisées pour formaliser l'arithmétisation de la géométrie. Ensuite, cette formalisation nous permet de mettre en pratique la théorie proposée par Beeson [START_REF] Beeson | Proof and Computation in Geometry[END_REF] afin d'obtenir des preuves automatiques basées sur des axiomes géométriques utilisant des méthodes algébriques. En effet, sans une "traduction inverse" de l'algèbre à la géométrie, les méthodes algébriques ne prouvent que des théorèmes sur les polynômes et non des énoncés géométriques. Toutefois, grâce à l'arithmétisation de la géométrie euclidienne, les énoncés prouvés correspondent aux théorèmes de tout modèle des systèmes axiomatiques de Hilbert et Tarski.

"As long as algebra and geometry traveled separate paths their advance was slow and their applications limited. But when these two sciences joined company, they drew from each other fresh vitality, and thenceforth marched on at a rapid pace toward perfection." 7 -Joseph-Louis Lagrange, Lec ¸ons élémentaires sur les mathématiques; cité par Morris Kline, Mathematical Thought from Ancient to modern Times, p. 322 Une formalisation de la caractérisation des prédicats géométriques est également motivée par la nécessité de partager des geometric knowledge data avec une sémantique bien définie. Les méthodes algébriques de déduction automatique en géométrie sont intégrées depuis longtemps dans les systèmes géométriques dynamiques [START_REF] Janičić | GCLC -A Tool for Constructive Euclidean Geometry and More than That[END_REF][START_REF] Ye | An Introduction to Java Geometry Expert[END_REF]. Les démonstrateurs automatiques de théorème peuvent maintenant être utilisés par des utilisateurs non experts de systèmes géométriques dynamiques tels que GeoGebra qui est largement utilisé dans les salles de classe [BHJ + 15]. Mais, les résultats de ces démonstrateurs doivent être interprétés pour comprendre dans quelle géométrie et sous quelles hypothèses ils sont valides. Différentes constructions géométriques pour un même énoncé peuvent conduire à des temps de calcul différents et à des conditions de non dégénérescence différentes. De plus, comme le montrent Botana et Recio, même pour des théorèmes simples, l'interprétation peut être non triviale [START_REF] Botana | On the Unavoidable Uncertainty of Truth in Dynamic Geometry Proving[END_REF]. Notre formalisation, en fournissant un lien formel entre les axiomes synthétiques et les équations algébriques, ouvre la voie au stockage de geometric knowledge data normalisées, structurées et rigoureuses basées sur un système d'axiomes explicite [START_REF] Chen | Formalization and Specification of Geometric Knowledge Objects[END_REF].

Nous avons décrit une tactique réflexive générique pour prouver certaines propriétés d'incidence spécifiques qui apparaissent souvent dans le développement systématique basé sur le système axiomatique de Tarski. Au cours de cette formalisation nous avons apprécié la modularité du calcul des constructions inductives qui permet d'exprimer facilement des fonctions d'arité paramétrables.

Notre tactique est générique dans un certain sens, mais aussi très spécialisée : elle peut résoudre une petite catégorie d'objectifs. Pourtant, il aurait été fastidieux de prouver manuellement les buts qui sont résolus automatiquement. De plus, ces sous-preuves sont souvent cachées dans un texte informel car elles sont "triviales" et rendent l'ensemble de la preuve plus difficile à lire.

Par rapport à l'approche proposée par Phil Scott et Jacques Fleuriot [START_REF] Scott | A Combinator Language for Theorem Discovery[END_REF], notre approche est plus spécifique puisqu'elle est dédiée à une tâche sur les incidences. Mais cette tâche est efficacement réalisée ce qui est important dans Coq tandis que dans Isabelle, les théorèmes prouvés en avance peuvent être traités avec des mécanismes moins efficaces. Plus précisément, comme nous savons que nous manipulons des données géométriques, nous pouvons avoir une structure de données spécifique pour représenter des droites alors que l'approche de Scott et Fleuriot génère un fait nouveau pour chaque combinaison du triplé de points sur une droite donnée.

De plus, à partir de l'arithmétisation de la géométrie euclidienne, nous avons introduit les coordonnées cartésiennes, produit les premières preuves synthétiques et formelles des théroèmes de Thalès et Pythagore, et fourni les caractérisations des prédicats géométriques principaux. Pour obtenir les caractérisations algébriques de certains prédicats géométriques, nous avons adopté une approche originale basée sur le bootstrap. Notre formalisation de l'arithmétisation de la géométrie euclidienne ouvre la voie à l'utilisation de méthodes algébriques en géométrie synthétique dans 7 "Tant que l'algèbre et la géométrie suivaient des chemins séparés, leur progression était lente et leurs applications limitées. Mais lorsque ces deux sciences ont uni leurs forces, elles se sont inspirées l'une de l'autre et ont poursuivi leur marche vers la perfection à un rythme rapide." l'assistant de preuve Coq. Pour illustrer l'utilisation concrète de cette formalisation, nous avons obtenu à partir du système axiomatique de Tarski une preuve formelle du théorème du cercle des neuf points en utilisant la méthode des bases de Gröbner. De plus, nous avons dérivé les axiomes d'une autre méthode de déduction automatique : la méthode des aires. Enfin, nous avons résolu un défi proposé par Beeson : nous avons prouvé qu'à partir de deux points, un triangle équilatéral basé sur ces deux points peut être construit dans les plans de Hilbert euclidiens, c'est-à-dire sans axiomes de continuité.

Conclusion et perspectives

Tout au long de cette thèse, nous nous sommes concentrés sur la formalisation des fondements de la géométrie. Nous avons étudié les approches synthétique et analytique des fondements de la géométrie euclidienne. Le coeur de notre formalisation est basé sur l'approche synthétique due à Tarski. Nous avons commencé par vérifier la satisfiabilité du système axiomatique de Tarski sans axiome de continuité. Nous y sommes parvenus en construisant un modèle basé sur l'approche analytique : un plan cartésien sur un corps pythagoricien ordonné. Afin de garantir que le système axiomatique capture effectivement la géométrie euclidienne du plan, nous avons mécanisé la preuve de l'arithmétisation de la géométrie euclidienne. Ensuite, afin d'obtenir les mêmes résultats pour un autre système axiomatique basé sur l'approche synthétique, à savoir les axiomes de Hilbert, nous avons construit une preuve formelle que les systèmes axiomatiques de Hilbert et de Tarski sont mutuellement interprétables si nous excluons les axiomes de continuité. Ce résultat était bien connu mais il était prouvé indirectement en utilisant la caractérisation des modèles des théories. À notre connaissance, nous avons formalisé la première preuve synthétique de ce théorème. Plus tard, nous avons donné une nouvelle preuve de l'indépendance du postulat parallèle par rapport aux autres axiomes du système axiomatique de Tarski. Après avoir constaté que cette preuve nous fournissait également un autre résultat d'indépendance, à savoir l'indépendance de la décidabilité de l'intersection des droites, nécessaire à l'obtention de l'arithmétisation telle que définie par Descartes, nous avons investigué si d'autres propriétés étaient nécessaires à son obtention. Nous les avons réduits à la décidabilité de l'égalité de points et nous avons démontré que nous aurions pu supposer de fac ¸on équivalente la décidabilité de la betweenness et de la congruence.

Ayant remarqué que toutes les versions du postulat des parallèles n'étaient pas suffisantes pour obtenir l'arithmétisation de la géométrie euclidienne, telle que définie par Descartes, sans ajouter une propriété supplémentaire de décidabilité, plus précisément la décidabilité d'intersection de droites, on a choisi de faire une analyse des différentes versions du postulat des parallèles. Cela nous a conduit à fournir des preuves synthétiques et formelles de l'équivalence des postulats appartenant à la même classe selon la classification des plans de Hilbert de Pejas. De plus, nous avons affiné cette classification dans un cadre intuitionniste pour obtenir quatre classes au lieu de trois pour les 34 postulats que nous avons considérés. En fait, toutes les versions du postulat des parallèles n'impliquent pas la décidabilité de l'intersection des droites nécessaire à l'arithmétisation de la géométrie euclidienne, telle que présentée par Descartes. En outre, nous avons donné une preuve de l'indépendance de l'axiome d'Archimède des axiomes des plans de Hilbert qui n'est pas basée sur un contre-modèle. Enfin, nous avons proposé un moyen d'obtenir une procédure mécanisée décidant l'équivalence au postulat des parallèles d'Euclide.

Tous ces résultats n'auraient pas pu être obtenus sans l'utilisation de l'automatisation. Nous avons conc ¸u une tactique réflexive générique pour prouver des propriétés d'incidence spécifiques. Cette tactique a été largement utilisée tout au long de notre effort de formalisation. Une fois l'arithmétisation de la géométrie euclidienne obtenue, nous avons eu accès à des méthodes plus puissantes comme la méthode des bases de Gröbner grâce à l'introduction des coordonnées cartésiennes et des caractérisations des principalux prédicats géométriques obtenues à l'aide d'une approche originale basée sur le bootstrap. Nous avons présenté plusieurs applications de la méthode des bases de Gröbner en géométrie synthétique. L'une de ces applications consistait à dériver les axiomes d'une autre méthode de déduction automatique : la méthode des aires. Ainsi, nous avons lié notre développement à une troisième fac ¸on de définir les fondements de la géométrie euclidienne : l'approche mixte analytique/synthétique. La figure F.1 donne un aperc ¸u des liens que nous avons formalisés entre les différentes approches8 .

Figure I.1. 1 .

 1 Figure I.1.1. Axiom of segment construction A4.

  Figure I.1.2. Five-segment axiom A5.

Figure

  Figure I.1.3. Pasch's axiom A7.

  Figure I.1.4. Upper-dimensional axiom A9.

  -> Tpoint -> Tpoint -> Prop; Cong : Tpoint -> Tpoint -> Tpoint -> Tpoint -> Prop; cong_pseudo_reflexivity : forall A B, Cong A B B A; cong_inner_transitivity

  ; PA : Tpoint; PB : Tpoint; PC : Tpoint; lower_dim : ˜(Bet PA PB PC \/ Bet PB PC PA \/ Bet PC PA PB) }. Class Tarski_neutral_dimensionless_with_decidable_point_equality '(Tn : Tarski_neutral_dimensionless) := { point_equality_decidability : forall A B : Tpoint, A = B \/ ˜A = B }. Class Tarski_2D '(TnEQD : Tarski_neutral_dimensionless_with_decidable_point_equality) := { upper_dim : forall A B C P Q,

  Subadditivity of the norm operator |x + y| ≤ |x| + |y| Compatibility of the addition with the strict comparison 0 < x ∧ 0 < y ⇒ 0 < x + y Definiteness of the norm operator |x| = 0 ⇒ x = 0 Comparability of positive numbers 0 ≤ x ∧ 0 ≤ y ⇒ (x ≤ y)||(y ≤ x) The norm operator is a morphism for the multiplication |x * y| = |x| * |y| Characterization of the large comparison in terms of the norm (x ≤ y) = (|y -x| == y -x) 5 Characterization of the strict comparison in terms of the large comparison (x < y) = (y ! = x)&&(x ≤ y)

  Variable R : realFieldType. Variable n : nat. Implicit Types (a b c d : 'rV[R]_(n.+1)). Definition cong a b c d := (b -a) *m (b -a)ˆT == (d -c) *m (d -c)ˆT. Definition betE a b c := [ || [ && a == b & b == c ], a == b | b == c ]. Definition ratio v1 v2 := if [pick k : 'I_(n.+1) | v2 0 k != 0] is Some k then v1 0 k / v2 0 k else 0. Definition betR a b c := ratio (b -a) (c -a). Definition betS a b c (r := betR a b c) := [ && b -a == r *: (c -a), 0 < r & r < 1]. Definition bet a b c := betE a b c || betS a b c.

  b c d : reflect (sqr_L2_norm_2D a b = sqr_L2_norm_2D c d) (cong a b c d). Lemma betSP' a b c (r := betR a b c) : reflect ([ /\ b 0 0 -a 0 0 = r * (c 0 0 -a 0 0), b 0 1 -a 0 1 = r * (c 0 1 -a 0 1), 0 < r & r < 1]) (betS a b c).

  row2 {R : ringType} (a b : R) : 'rV[R]_2 := \row_p [eta \0 with 0 |-> a, 1 |-> b] p. Definition a : 'rV[R]_(2) := row2 0 0. Definition b : 'rV[R]_(2) := row2 0 1. Definition c : 'rV[R]_(2) := row2 1 0.

  Axiom constructive_definite_description :forall (A:Type) (P : A -> Prop), (exists! x, P x) -> {x : A | P x}.

  between_diff : forall A B C, BetH A B C -> A <> C;

  between_one : forall A B C, A <> B -> A <> C -> B <> C -> ColH A B C -> BetH A B C \/ BetH B C A \/ BetH B A C. BetH : Point -> Point -> Point -> Prop; between_diff : forall A B C, BetH A B C -> A <> C; between_col : forall A B C, BetH A B C -> ColH A B C; between_comm : forall A B C, BetH A B C -> BetH C B A; between_out : forall A B, A <> B -> exists C, BetH A B C; between_only_one : forall A B C, BetH A B C -> ˜BetH B C A; cut := fun l A B => ˜Incid A l /\ ˜Incid B l /\ exists I, Incid I l /\ BetH A I B; pasch : forall A B C l, ˜ColH A B C -> ˜Incid C l -> cut l A B -> cut l A C \/ cut l B C;

C

  Figure I.2.1. Pasch's axiom.

  cong_permr : forall A B C D, CongH A B C D -> CongH A B D C;

  Figure I.2.2. Axiom of existence of a point on a given side on a line forming a segment congruent to a given segment.

Figure

  Figure I.2.3. Axiom of addition of segments.

Figure I.2. 4 .

 4 Figure I.2.4. Axiom of existence of a point on a given side of a line forming an angle congruent to a given angle.

  Hilbert's congruence relation is defined only for non degenerate segments, whereas Tarski's one include the case of the null segment: Definition Cong A B C D := (CongH A B C D /\ A <> B /\ C <> D) \/ (A = B /\ C = D).

3

  We use the notations given in Appendix E.

  Figure I.2.6. Hilbert's Theorems 12 and 18.

Proof.

  We prove this lemma by contradiction so let us assume that B does not belong to line A C . Let B be a point on A C such that A B ≡ H AB. Let C a point such that B C ≡ H BC and A B C (Fig. I.2.8). So the triangle B C C is isosceles in B . Then Hilbert's Theorem 12 lets us prove that B C C = B C C . By Lemma 4, we have that A B C . We can derive B C ≡ H BC by subtraction and then A C ≡ H A C by addition. Therefore triangle C A C is isosceles in A , hence Hilbert's Theorem 12 implies that A C C = A C C . By transitivity of angle congruence (Hilbert's Theorem 19), we know that B C C = A C C . Finally we obtain a contradiction as the uniqueness of angle construction and the fact that B and C are on the same side of C C let us prove that C B is the same ray as C A .

  Figure I.2.8. Proof of Lemma 5.

  Fig. I.3.1.

  Figure I.3.1. Euclid 5.

Figure I.3. 3 .

 3 Figure I.3.3. Construction of a point too far away. Here k = 0 and the constructed points are indicated by the open circles.

-

  Case C = D. Using Lemma 14 we construct D such that A B D ∨ bT AD B and AD ≡ CD. If B = D we have that AB ≡ CD. Otherwise B = D . Assume that AB≡CD, then by transitivity AB≡AD . By case distinction on A B D ∨A D B we can show in both cases that B = D using Lemma 12, hence ¬AB ≡ CD. Let us assume decidability of congruence, we prove decidability of point equality. Let A and B be two points. By decidability of congruence we have that AB ≡ AA ∨ ¬AB ≡ AA. If AB ≡ AA, by axiom A3 we have A = B. Otherwise ¬AB ≡ AA. Assuming A = B we have ¬AA ≡ AA this contradicts axiom A1 hence A = B. Assume decidability of point equality, we prove decidability of betweenness. Construct C a point such that A B C and BC ≡ BC . If C = C then A B C. Otherwise C = C . If A = B then A B C by Lemma 11. Otherwise A = B. Assume A B C using Lemma 13 we obtain that C = C , hence ¬A B C. Let us assume decidability of betweenness, we prove decidability of point equality. Let A, B be two points. By decidability of betweenness we have that A B A ∨ ¬A B A. If A B A then by axiom A6 we have A = B. If ¬A B A, assume A = B then by Lemma 11 we have ¬A A A, hence A = B.

  Figure I.3.4. One can decide whether two lines intersect or not.

  . II.1.10). (3) The third postulate, which we designate as the triangle postulate, corresponds to the implicit assumption made by Legendre in the quote by him from the introduction. It asserts that the sum of the interior angles of a triangle is equal to two right angles (Fig. II.1.11). (

Figure

  Figure II.1.1. Graphical summary of the independence results from Subsections 1.1-1.3.

Figure

  Figure II.1.2. Definition of Coplanar.

  Definition Par A B C D := Par_strict A B C D \/ (A <> B /\ C <> D /\ Col A C D /\ Col B C D).

FigureFigure

  Figure II.1.3. Definition of CongA.

Figure

  Figure II.1.6. Definition of SumA.

Figure

  Figure II.1.7. Definition of Per.

Figure

  Figure II.1.8. Definition of InAngle.

  Definition LeA A B C D E F := exists P, InAngle P D E F /\ CongA A B C D E P.

Figure

  Figure II.1.9. Tarski's parallel postulate (Postulate 1).

Figure

  Figure II.1.10. Playfair's postulate (Postulate 2).

F

  Figure II.1.11. Triangle postulate (Postulate 3).

Figure

  Figure II.1.12. Bachmann's Lotschnittaxiom (Postulate 4).

  Definition decidability_of_intersection := forall A B C D, (exists I, Col I A B /\ Col I C D) \/ ˜(exists I, Col I A B /\ Col I C D).

  Inductive Grad : Tpoint -> Tpoint -> Tpoint -> Prop := | grad_init : forall A B, Grad A B B | grad_stab : forall A B C C', Grad A B C -> Bet A C C' -> Cong A B C C' -> Grad A B C'. Definition Reach A B C D := exists B', Grad A B B' /\ Le C D A B'. Grad A B C expresses that C is on the graduation based on the segment AB. Then, this definition allows us to define Archimedes' axiom in a straightforward manner. Axiom 2 (Archimedes' axiom). Definition archimedes_axiom := forall A B C D, A <> B -> Reach A B C D. 3.7. Aristotle's Axiom. Before defining Aristotle's axiom, we need to introduce the notion of strict comparison between segments. Definition Lt A B C D := Le A B C D /\ ˜Cong A B C D.

Figure

  Figure II.1.13. Aristotle's axiom (Axiom 3).

Figure

  Figure II.1.14. Greenberg's axiom (Axiom 4).

Figure

  Figure II.2.1. Postulate of transitivity of parallelism (Postulate 5).

Figure

  Figure II.2.2. Midpoint converse postulate (Postulate 6).

Figure

  Figure II.2.3. Alternate interior angles postulate (Postulate 7).

Figure

  Figure II.2.4. Consecutive interior angles postulate (Postulate 8).

Figure

  Figure II.2.5. Definition of Perp at.

X

  CD means that lines AB and CD meet at a right angle in X (Fig.II.2.5). The part of the definition that specifies that any point on the first line together with any point on the second line and the intersection point form a right angle is essential to the possibility of choosing any couple of different points to represent the lines.Definition Perp A B C D := exists X, Perp_at X A B C D.This predicate and the previous one correspond to Definition 8.11 of[START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF]. Most of the time, we just want to consider the perpendicularity of two lines AB and CD without specifying the point in which they meet. In such cases, we use AB ⊥ CD. Postulate 9 (Perpendicular transversal postulate). Definition perpendicular_transversal_postulate := forall A B C D P Q, Par A B C D -> Perp A B P Q -> Perp C D P Q.

FigureFigure

  Figure II.2.6. Perpendicular transversal postulate (Postulate 9).

Figure

  Figure II.2.8. Universal Posidonius' postulate (Postulate 11).

Figure

  Figure II.2.9. Definition of Perp2.

Figure

  Figure II.2.10. Alternative Playfair's postulate (Postulate 12).

  Definition all_equiv'_aux (l: list Prop) : Prop. induction l; [exact True|]. induction l; [exact True|]. exact ((a -> a0) /\ IHl). Defined. Definition all_equiv' (l: list Prop) : Prop. induction l; [exact True|]. exact ((last l a -> a) /\ all_equiv'_aux (a::l)). Defined.

  7 and Postulate 8 (Theorem 21.4) and of the implication from Postulate 9 to Postulate 10 (Theorem 23.7) are provided. Putting together the implications from Fig. II.2.11, we can prove the following theorem. Theorem 4. Postulates 2, 5-12 are N LJ -equivalent.

Figure

  Figure II.3.1. Proclus' postulate (Postulate 13).

Figure

  Figure II.3.2. Alternative Proclus' postulate (Postulate 14).

Figure

  Figure II.3.3. Triangle circumscription principle (Postulate 15).

Figure

  Figure II.3.4. Inverse projection postulate (Postulate 16).

Figure

  Figure II.3.5. Euclid 5 (Postulate 17).

Figure

  Figure II.3.6. Strong parallel postulate (Postulate 18).

Figure

  Figure II.3.7. Alternative strong parallel postulate (Postulate 19).

Figure

  Figure II.3.8. Euclid's parallel postulate (Postulate 20).

  Fig. II.3.9 allow us to prove the following theorem. Theorem 5. Postulates 1, 13-20 are N LJ -equivalent and Postulates 1, 2, 5-20 are N LK -equivalent.

  Figure II.3.10. Axiom 1 and Postulate 9 imply Postulate 15.

  Definition postulate_of_existence_of_a_triangle_whose_angles_sum_to_two_rights := exists A B C D E F, ˜Col A B C /\ TriSumA A B C D E F /\ Bet D E F. Definition posidonius_postulate := exists A1 A2 B1 B2, ˜Col A1 A2 B1 /\ B1 <> B2 /\ forall A3 A4 B3 B4, Col A1 A2 A3 -> Col B1 B2 B3 -> Perp A1 A2 A3 B3 -> Col A1 A2 A4 -> Col B1 B2 B4 -> Perp A1 A2 A4 B4 -> Cong A3 B3 A4 B4.

Figure

  Figure II.4.1. Postulate of existence of similar but non-congruent triangles (Postulate 23).

  Figure II.4.2. Thales' postulate (Postulate 24), Thales' converse postulate (Postulate 25) and existential Thales' postulate (Postulate 26).

DefinitionFigure

  Figure II.4.3. Definition of Saccheri.

Figure

  Figure II.4.4. Definition of Lambert.

  L A B C D has right angles at A, B and D (Fig. II.4.4). The reason why Saccheri studied them is because by taking N such that A N D and M such that B M C in a Saccheri quadrilateral S A B C D, one obtains two Lambert quadrilaterals L N M B A and L N M C D.

Figure

  Figure II.4.5. Overview of the proofs in Chapter II.4.

  .4.6). Comparing with Fig. II.3.9 and Fig. II.4.5, one can see two extra implications displayed, namely from Postulate 3 to Postulate 12 (the alternative Playfair's postulate) and from Postulate 7 (the alternate interior angles postulate) to Postulate 3. Indeed, these implications are not necessary to prove that any two postulates that belong to the same circle are equivalent. Nonetheless, in order to prove the following theorem, they are necessary. Theorem 6. Postulates 3, 21-30 are N LJ -equivalent and Postulates 1-3, 5-30 are N G LJ -equivalent. For the sake of completeness, we list the propositions given in [Mar98] that correspond to the implications on Fig. II.4.5. Theorems 22.

  Lemma 23 (8.18). Dropped perpendiculars 7 are constructible.Lemma 24 (9.8). If P

Figure II.5. 1 .

 1 Figure II.5.1. Overview of the proof of the equivalence between Axiom 1, Axiom 3 and Axiom 4.

Figure

  Figure II.5.2. Assuming Axiom 4, Postulate 7 implies Postulate 13.

  Then we can show that P C2Q1 C2Q1 C 0 and P C0Q1 C0Q1 C 2 imply Q 1 ∈ C 0 P C 2 using Lemma 28. By definition it means that there exists a point Y such that C 0 Y C 2 and P Y Q 1 . Therefore point Y is on both lines CD and P Q. Let us recall that Postulate 2 and Postulate 7 (the alternate interior angles postulate) are N LJequivalent and that Postulate 1 and Postulate 13 (Proclus' postulate) are also N LJ -equivalent. Proposition 5 lets us prove our claim. Theorem 7. Axiom 1 (decidability of intersection of lines), Axiom 3 (Aristotle's axiom) and Axiom 4 (Greenberg's axiom) are N LJ -equivalent under the assumption that Postulate 2 (Playfair's postulate) holds.

4

  Proposition 6 corresponds to Theorem 22.24 in[START_REF] Edward | The Foundations of Geometry and the Non-Euclidean Plane[END_REF] which we mechanized. Its proof, which depends on Legendre's first theorem (Theorem 9), is discussed in the next section. 5 These postulates are not the only one which are N LJ -equivalent to Bachmann's Lotschnittaxiom. In fact, Pambuccian recently established the N LJ -equivalence to Bachmann's Lotschnittaxiom for three postulates [Pam94, Pam09, Pam17]. Postulate 31 (Weak inverse projection postulate) and Postulate 32 (Weak Tarski's parallel postulate). Definition weak_inverse_projection_postulate := forall A B C D E F P Q, Acute A B C -> Per D E F -> SumA A B C A B C D E F -> Out B A P -> P <> Q -> Per B P Q -> exists Y, Out B C Y /\ Col P Q Y. Definition weak_tarski_s_parallel_postulate := forall A B C T, Per A B C -> InAngle T A B C -> exists X Y, Out B A X /\ Out B C Y /\ Bet X T Y.

Figure

  Figure II.5.4. Considered points in Theorem 22.18 of [Mar98].

Figure

  Figure II.5.5. Axiom 2 implies Axiom 3.

Figure II.5. 6 .

 6 Figure II.5.6. Overview of the proofs.

  Definition hyperbolic_plane_postulate := forall A1 A2 P, ˜Col A1 A2 P -> exists B1 B2 C1 C2, Par A1 A2 B1 B2 /\ Col P B1 B2 /\ Par A1 A2 C1 C2 /\ Col P C1 C2 /\ ˜Col C1 B1 B2.

Lemma 30 .Figure

 30 Figure II.5.7. The hyperbolic plane postulate holds under the hypothesis of the acute angle.

  have P XY XY Q by definition, as well as P B1X B1X Q and P C1Y C1Y Q from Lemma 33, hence

Figure

  Figure III.1.1. The midpoint theorem.

  Definition sp_ok (sp : SP.t) (interp: positive -> COLTpoint) := forall p, SP.mem p sp = true -> interp (fstpp p) <> interp (sndpp p).

  Lemma collect_diffs :forall (A B : COLTpoint) (H : A <> B) (pa pb sp : positive) (interp : positive -> COLTpoint), interp pa = A -> interp pb = B -> sp_ok sp interp -> sp_ok (SP.add (pa, pb) sp) interp.

  pc : positive) ss (interp : positive -> COLTpoint), interp pa = A -> interp pb = B -> interp pc = C -> ss_ok ss interp -> ss_ok (SS.add (S.add pa (S.add pb (S.add pc S.empty))) ss) interp.

  Class Coinc_predicates (Ar : Arity) := { wd : arity COINCpoint (S (S n)); coinc : arity COINCpoint (S (S (S n))) }. The predicates are elements of the type arity T n representing predicates of type T → ... → T n times → Prop. Its formal definition is the following: Fixpoint arity (T:Type) (n:nat) := match n with | 0 => Prop | S p => T -> arity T p end.

  Lemma PermWdOK : forall (cp1 cp2 : cartesianPower COINCpoint (S (S n))), app wd cp1 -> Permutation.Permutation (CPToList cp1) (CPToList cp2) -> app wd cp2. Lemma OCPPerm {n : nat} : forall (cp : cartesianPower positive (S (S n))), Permutation.Permutation (CPToList cp) (CPToList (OCP cp)).

Figure

  Figure III.1.2. Definition of Coplanar.

Figure

  Figure III.1.3. Pascal's hexagon theorem.

Figure III.1. 4 .

 4 Figure III.1.4. Illustrations of the different steps of algorithm.

  Fig. III.1.4a). We then add eight points, each incident to the previous line, defining four lines (C, D, E, F , G, H, I and J on Fig. III.1.4a). We take four pairs of lines (every line is paired with exactly two other lines) and, for each of these pairs, we add new lines by adding one point on each of the two lines (K, L, M , N , O, P , Q and R on Fig. III.1.4b), thus making a new line (the two points are supposed to be different). By repeating the process k times (in the case where k = 2 we would have added S, T , U , V , W , X, Y and Z on Fig. III.1.4c) we have 4(k + 1) + 1 lines which are all equal.

  Per A B C states that A, B and C form a right triangle. Definition Cs O E S U1 U2 := O <> E /\ Cong O E S U1 /\ Cong O E S U2 /\ Per U1 S U2. The predicate Cd O E S U1 U2 P X Y denotes that the point P has coordinates X and Y in the coordinate system Cs O E S U1 U2. Cong 3 A B C D E F designates that the triangles ABC and DEF are congruent and Projp P Q A B means that Q is the foot of the perpendicular from P to line AB. Definition Cd O E S U1 U2 P X Y := Cs O E S U1 U2 /\ Coplanar P S U1 U2 /\ (exists PX, Projp P PX S U1 /\ Cong_3 O E X S U1 PX) /\ (exists PY, Projp P PY S U2 /\ Cong_3 O E Y S U2 PY).

  Lemma characterization_of_parallelism_F_aux : forall A B C D, Par A B C D <-> A <> B /\ C <> D /\ exists P, Midpoint C A P /\ exists Q, Midpoint Q B P /\ Col C D Q.

Figure

  Figure III.2.1. Euler's nine-point circle.

  Definition vect := (F * F)%type. Definition cross_product (u v : vect) : F := fst u * snd v -snd u * fst v. Definition scalar_product (u v : vect) : F := fst u * fst v + snd u * snd v.

  Definition ratio A B C D := let (Ac, _) := coordinates_of_point_F A in let (Ax, Ay) := Ac in let (Bc, _) := coordinates_of_point_F B in let (Bx, By) := Bc in let (Cc, _) := coordinates_of_point_F C in let (Cx, Cy) := Cc in let (Dc, _) := coordinates_of_point_F D in let (Dx, Dy) := Dc in let VAB := (Bx-Ax, By-Ay) in 7 Since the division is itself a total function returning the default value 0 when dividing by 0.

  let VCD := (Dx-Cx, Dy-Cy) in scalar_product VAB VCD / scalar_product VCD VCD.

  Definition signed_area A B C := let (Ac, _) := coordinates_of_point_F A in let (Ax, Ay) := Ac in let (Bc, _) := coordinates_of_point_F B in let (Bx, By) := Bc in let (Cc, _) := coordinates_of_point_F C in let (Cx, Cy) := Cc in let VAB := (Bx-Ax, By-Ay) in let VAC := (Cx-Ax, Cy-Ay) in 1 / 2 * cross_product VAB VAC.

  Definition square_dist A B := let (Ac, _) := coordinates_of_point_F A in let (Ax, Ay) := Ac in let (Bc, _) := coordinates_of_point_F B in let (Bx, By) := Bc in (Ax -Bx) * (Ax -Bx) + (Ay -By) * (Ay -By). Definition Py A B C := square_dist A B + square_dist B C -square_dist A C.

Figure

  Figure III.2.2. Construction of an equilateral triangle on the base AB without line-circle intersection.

Figure III.2. 3 .

 3 Figure III.2.3. Overview of the links between the axiom systems.

  3. Given two segments AB and BC with no point in common aside from the point B and two other segments A B and B C with no point in common aside from the point B , then, if AB ≡ H A B and BC ≡ H B C , we have AC ≡ H A C . 4. Given an angle ∠ABC, a ray OX emanating from a point O and given a point P , not on the line generated by OX, there is a unique point Y , such that the angle ∠XOY is congruent to the angle ∠ABC and such that every point inside ∠XOY and P are on the same side with respect to the line generated by OX. 5. If in two triangles ABC and A B C , AB ≡ H A B , AC ≡ H A C and B A C = H B A C , then A B C = H A B C . IV. 1. Given a line l and a point P non-incident to l, if two lines are parallel to l and incident to

  (Tarski's parallel postulate) Given a point D between the points B and C and a point T further away from A than D on the half line AD, one can build a line which goes through T and intersects the sides AB and AC of the angle ∠BAC respectively further away from A than B and C.(2) (Playfair's postulate) There is a unique parallel to a given line going through some point. (3) (Triangle postulate) The sum of the angles of any triangle is two right angles. (4) (Bachmann's Lotschnittaxiom) Given the lines l, m, r and s, if l and r are perpendicular, r and s are perpendicular and s and m are perpendicular, then l and m must meet. (5) (Postulate of transitivity of parallelism) If two lines are parallel to the same line then these lines are also parallel. (6) (Midpoint converse postulate) The parallel line to one side of a triangle going through the midpoint of another side cuts the third side in its midpoint. (7) (Alternate interior angles postulate) The line falling on parallel lines makes the alternate angles equal to one another. (8) (Consecutive interior angles postulate) A line falling on parallel lines makes the sum of interior angles on the same side equal to two right angles. (9) (Perpendicular transversal postulate) Given two parallel lines, any line perpendicular to the first line is perpendicular to the second line. (10) (Postulate of parallelism of perpendicular transversals) Two lines, each perpendicular to one of a pair of parallel lines, are parallel. (11) (Universal Posidonius' postulate) If two lines are parallel then they are everywhere equidistant. (12) (Alternative Playfair's postulate) Any line parallel to line l passing through a point P is equal to the line that passes through P and shares a common perpendicular with l going through P . (13) (Proclus' postulate) If a line intersects one of two parallel lines then it intersects the other. (14) (Alternative Proclus' postulate) If a line intersects in P one of two parallel lines which share a common perpendicular going through P , then it intersects the other. (15) (Triangle circumscription principle) For any three non-collinear points there exists a point equidistant from them. (16) (Inverse projection postulate) For any given acute angle, any point together with its orthogonal projection on one side of the angle form a line which intersects the other side. (17) (Euclid 5) Given a non-degenerate parallelogram P RQS and a point U strictly inside the angle ∠QP R, there exists a point I such that Q and U are respectively strictly between S and I and strictly between P and I. (18) (Strong parallel postulate) Given a non-degenerate parallelogram P RQS and a point U not on line P R, the lines P U and QS intersect. (19) (Alternative strong parallel postulate) If a straight line falling on two straight lines make the sum of the interior angles on the same side different from two right angles, the two straight lines meet if produced indefinitely. (20) (Euclid's parallel postulate) If a straight line falling on two straight lines make the interior angles on the same side less than two right angles, the two straight lines, if produced indefinitely, meet on that side on which are the angles less than the two right angles. (21) (Postulate of existence of a triangle whose angles sum to two rights) There exists a triangle whose angles sum to two rights. (22) (Posidonius' postulate) There exist two lines which are everywhere equidistant. (23) (Postulate of existence of similar but non-congruent triangles) There exist two similar but non-congruent triangles. (24) (Thales' postulate) If the circumcenter of a triangle is the midpoint of a side of a triangle, then the triangle is right. (25) (Thales' converse postulate) In a right triangle, the midpoint of the hypotenuse is the circumcenter. (26) (Existential Thales' postulate) There is a right triangle whose circumcenter is the midpoint of the hypotenuse. (27) (Postulate of right Saccheri quadrilaterals) The angles of any Saccheri quadrilateral are right. (28) (Postulate of existence of a right Saccheri quadrilateral) There is a Saccheri quadrilateral whose angles are right. (29) (Postulate of right Lambert quadrilaterals) The angles of any Lambert quadrilateral are right i.e. if in a quadrilateral three angles are right, so is the fourth. (30) (Postulate of existence of a right Lambert quadrilateral) There exists a Lambert quadrilateral whose angles are all right.

Démonstration.

  Nous savons que le déficit de tout triangle est soit positif, soit nul. Donc pour prouver que le déficit de tout triangle est nul, nous procédons par contradiction pour éliminer le cas où le déficit est positif. Supposons donc qu'il existe un triangle ABC avec un déficit positif D(△ABC) > 0. Posons que ∠BAC est aigu en prenant ∠BAC comme étant le plus petit angle du triangle ABC. Évidemment, A, B et C ne sont pas colinéaires puisque D(△ABC) > 0. Soit n un entier tel que 2 n D(△ABC) > π. Nous allons construire un triangle AB n C n de déficit D(△AB n C n ) > 2 n D(△ABC) aboutissant ainsi à une contradiction. Pour ce faire, nous construisons deux séquences de points (

Démonstration

  de Legendre du postulat des parallèles d'Euclide.

  ainsi que par Makarios [Mak12] en Isabelle. Dans [MP15], Marić et Petrović ont formalisé la géométrie du plan complexe en Isabelle/HOL. Ce faisant, ils ont démontré l'avantage d'utiliser une approche algébrique et la nécessité d'une connexion avec une approche synthétique. Braun et Narboux ont également formalisé le fait que les axioms de Hilbert sont interprétables à partir de ceux de Tarski en Coq [BN12], Beeson a ensuite écrit une note [Bee14] pour démontrer que les principaux résultats pour obtenir les axioms de Hilbert sont contenus dans [SST83]. Des formalisations des fondements de la géométrie de Hilbert ont été proposés par Dehlinger, Dufourd et Schreck [DDS01] en Coq et par Dixon, Meikle et Fleuriot [MF03] en Isabelle/HOL. Dehlinger, Dufourd et Schreck ont étudié la formalisation des fondements de la géométriques de Hilbert dans le cadre intuitionniste de Coq [DDS01]. Ils se concentrent sur les deux premiers groupes d'axiomes et vérifient certaines propriétés sur la betweenness. Meikle et Fleuriot ont fait une étude similaire au sein de l'assistant de preuve Isabelle/HOL [MF03]. Ils sont allés jusqu'au douzième 4 théorème du livre de Hilbert. Scott a continué la formalisation de Meikle en utilisant Isabelle/HOL et l'a mise à jour [Sco08]. Il a corrigé quelques "erreurs subtiles dans la formalisation du groupe III de Meikle". Scott était intéressé par la possibilité d'obtenir des preuves lisibles. Plus tard, il a développé un système au sein de l'assistant de preuve HOL-Light pour démontrer automatiquement certaines propriétés d'incidence [SF10]. De même, quelques développements basés sur le système axiomatique de Tarski ont été entrepris. Par exemple, Richter, Grabowski et Alama ont transposé certaines de nos preuves de Coq à Mizar [NK09] (quarante-six lemmes) [RGA14]. De plus, Beeson et Wos ont prouvé 200 lemmes des douze premiers chapitres de [SST83] avec le démonstrateur automatique de théorème Otter [BW17]. Enfin, Durdević, Narboux et Janičić [S DNJ15] ont généré automatiquement quelques preuves lisibles dans le système axiomatique de Tarski. Aucun de ces efforts de formalisation n'est allé jusqu'au théorème de Pappus ni à l'arithmétisation de la géométrie.

  [Tar59]. Certaines de ces méthodes ont été formalisées dans Coq : Janičić, Narboux et Quaresma ont formalisé la méthode des aires [Nar04, JNQ12], Pottier et Théry ont formalisé la méthode des bases de Gröbner [Thé01, Pot08, GPT11], Genevaux, Narboux et Schreck ont étendu ce travail à la méthode de Wu [GNS11], Fuchs et Théry ont formalisé une procédure basée sur les algèbres géométriques [FT10]. Enfin, la décomposition algébrique cylindrique a été implémentée dans Coq [Mah05, Mah06].

  , and Julien Narboux. Formalization of the Arithmetization of Euclidean Plane Geometry and Applications. Journal of Symbolic Computation, 2018 • Gabriel Braun, Pierre Boutry, and Julien Narboux. From Hilbert to Tarski. In Julien Narboux, Pascal Schreck, and Ileana Streinu, editors, Proceedings of the Eleventh International Workshop on Automated Deduction in Geometry, Proceedings of ADG 2016, pages 78-96, 2016 • Michael Beeson, Pierre Boutry, and Julien Narboux. Herbrand's theorem and non-Euclidean geometry. The Bulletin of Symbolic Logic, 21(2):111-122, 2015 • Pierre Boutry, Julien Narboux, Pascal Schreck, and Gabriel Braun. A short note about case distinctions in Tarski's geometry. In Francisco Botana and Pedro Quaresma, editors, Proceedings of the Tenth International Workshop on Automated Deduction in Geometry, Proceedings of ADG 2014, pages 51-65, 2014 • Pierre Boutry, Charly Gries, Julien Narboux, and Pascal Schreck. Parallel Postulates and Continuity Axioms: A Mechanized Study in Intuitionistic Logic Using Coq. Journal of Automated Reasoning, 2017

Table I .

 I 1.4. Axioms of the real field structure.

Table I

 I

	.2.2. Formalization of Group II

Table I

 I

	.2.3. Formalization of Group III, part 1 : segment congruence axioms
	1.3.2. Congruence of Angles.

Table I

 I

	.2.4. Formalization of Group III, part 2: angle congruence axioms
	Para := fun l m => ˜exists X, Incid X l /\ Incid X m;
	euclid_uniqueness :
	forall l P m1 m2,
	˜Incid P l ->
	Para l m1 -> Incid P m1-> Para l m2 -> Incid P m2 ->
	EqL m1 m2

Table I

 I

	.2.5. Formalization of Group IV
	decidability_of_intersection :
	forall l m,
	(exists I, Incid I l /\ Incid I m) \/
	˜(exists I, Incid I l /\ Incid I m)

  The triangle ABC is a right triangle with the right angle at vertex B. 5 CongA_Null_Acute a The angle ∠ABC is null. The lines AB and CD meet at a right angle in X.2 ReflectL P' P A B P is the image of P by the reflection with respect to the line AB. Table I.3.5. Statistics about number of case distinctions.

	Predicate	Meaning	Number of occurrences
	A = B	Points A and B are equal.	1087
	Col A B C	Points A, B and C are collinear.	277
	Bet A B C	B is between A and C.	63
	Out A B C	B belongs to the ray P A.	33
	Cong A B C D	The segments AB and CD are congruent.	21
	CongA A B C D E F	The angles ∠ABC and ∠DEF are congruent.	9
	Par A B C D	The lines AB and CD are parallel.	8
	OS A B P Q	P and Q are on the same side of line AB.	7
	Per A B C
			5
	LeA A B C D E F	The angle ∠ABC is smaller or congruent to the angle ∠DEF .	5
	Inter A B C D	The lines AB and CD intersect.	3
	Line A B C D	The lines AB and CD are equal.	3
	Perp_at X A B C D
			2
	Q_Cong_Null l	The length l is null.	2
	InAngle P A B C	P belongs to the angle ∠ABC.	2

  II.2.2) is congruent to half of the basis (the segment AB on Fig. II.2.2), is equivalent to another statement of the parallel postulate which is strictly weaker than the triangle postulate in the theory of metric planes [AP16, Bac73].

Postulate 7 (Alternate interior angles postulate).

  A line P Q which enters a triangle ABC on side AB and does not pass through C must exit the triangle either on side AC or on side BC.

	Proposition 2. Postulate 6 (midpoint converse postulate) implies Postulate 2 (Playfair's postu-
	late).
	Proof.
		X
	B2	P	C3	C1
	C2		B3	B1
	A1			A2
	Figure II.2.12. Postulate 6 implies Postu-
	late 2.

  .2. Thales' postulate (Postulate 24), Thales' converse postulate (Postulate 25) and existential Thales' postulate (Postulate 26).hypotheses and the conclusion by a conjunction. Postulate 24 states that, if the circumcenter of a triangle is the midpoint of a side of a triangle, then the triangle is right. Postulate 25 states that, in a right triangle, the midpoint of the hypotenuse is the circumcenter. Finally, Postulate 26 states that there is a right triangle whose circumcenter is the midpoint of the hypotenuse. Fig. II.4.2 displays the figure representing the statement of the postulates in the Euclidean plane on the left. A counterexample in Poincaré disk model for Postulate 24 can be found in the center of Fig. II.4.2 and one for Postulate 25 is on the right of Fig. II.4.2.There is no counter-example for Postulate 26, for the reason that it does not state a property that some geometric objects verify in a given configuration, but rather the existence of some geometric objects verifying a given property. Martin qualifies Postulate 24, which is a special case of the inscribed angle theorem (part of Proposition III.31

in

[START_REF] Euclid | Euclid's Elements: all thirteen books complete in one volume : the Thomas Little Heath translation[END_REF]

), as "certainly one of the oldest theorems in mathematics". The proofs of Postulate 24 and Postulate 25, as theorems of Euclidean geometry, have already been studied in Coq assuming Tarski's system of geometry

[START_REF] Braun | Des preuves formelles en Coq du théorème de Thalès pour les cercles[END_REF]

. Nevertheless, Braun et al. proved that they both follow from Postulate 6 (the midpoint converse postulate), which is strictly stronger than both of them. Finally, formalizing these postulates is elementary. Postulate 27 (Postulate of right Saccheri quadrilaterals) and Postulate 28 (Postulate of existence of a right Saccheri quadrilateral).

  3 and 22.10 allow us to prove that Postulate 27 implies Postulate 29 and is implied by Postulate 30. The implications from Postulate 28 to Postulate 27 and from Postulate 27 to Postulate 3 are respectively proved in Theorem 22.10 and Corollary 22.13. From Theorem 22.17 we could deduce that Postulate 27 implies Postulate 24 and is implied by Postulate 26. The fact that Postulate 24 implies Postulate 25 and that Postulate 21 implies Postulate 27 are showed in Theorem 23.7. The implications from Postulate 3 to Postulate 21, from Postulate 27 to Postulate 28, from Postulate 29 to Postulate 30 and from Postulate 25 to Postulate 26 are trivial.Indeed, in each of these implications, one needs to prove that a postulate implies another where some of the universal quantifiers are replaced by existential ones. Thus one only needs to assert the existence of a non-degenerate triangle, a Saccheri quadrilateral, a Lambert quadrilateral and a non-degenerate right triangle. The proof that Postulate 27 is equivalent to Postulate 22 is done in Theorem 23.6 for one side of the equivalence (but using the notion of default for a triangle, which we avoided in this chapter) and in Theorem 23.7 for the other side. Finally, the proof that Postulate 27 is equivalent to Postulate 23 is left as exercise.

	30.	28.	27.	11.	10.	9.	15.	18.	13.
	29.		21.
				12.		2.	1.		14.
	26.		3.
	25.		22.	7.		5.	17.		16.
	24.	23.		8.	6.		20.	19.
	Figure II.4.6. Overview of the proofs in Chapters II.2-II.4.

  2 Let us first collect two lemmas from planar neutral geometry needed for it. Given two intersecting lines AB and CD and a point P not on line AB, there exists a point Q on line CD such that A

	Lemma 28 (Crossbar). 3 If B	CP CP	A and B
		P Q P Q B.
	Proposition 5. Assuming Axiom 4 (Greenberg's axiom), Postulate 7 (alternate interior angles
	postulate) implies Postulate 13 (Proclus' postulate).

AP AP C then P ∈ A B C. Lemma 29.

  II.5.3. Overview of the proofs in Section 2. the implication from Postulate 33 to Postulate 4 (Theorem 23.7) and in [Bac64], the equivalence between Postulate 4, Postulate 31 and Postulate 32 is proved. The implications displayed on Fig. II.5.3 allow us to prove the following theorem.Following is the Coq statement corresponding to Theorem 8.

	Theorem 8. Postulates 4, 31-33 are N LJ -equivalent.
	Theorem equivalent_postulates_without_any_continuity_bis :
	all_equiv
	(bachmann_s_lotschnittaxiom::
	weak_inverse_projection_postulate::
	weak_tarski_s_parallel_postulate::
	weak_triangle_circumscription_principle::
	nil).

  Times in seconds to solve problems for n = 2 and various k.TableIII.1.2. Times in seconds to solve problems for n = 3 and various k.

	Prover k = 1 k = 2	k = 4		k = 8	k = 16
	Coq	0.94	1.74	4.98		22.52	166.59
	E	1.63	9.13	220.29	TIMEOUT TIMEOUT
	iProver	0.50	2.11	13.70		338.09	TIMEOUT
	Metis	5.57 13.84	56.98		310.94	TIMEOUT
	Otter	0.63	3.19 TIMEOUT TIMEOUT TIMEOUT
	Vampire 0.86	2.98	16.33		146.86	TIMEOUT
	Table III.1.1. Prover	k = 1	k = 2	k = 4
		Coq	4.59		11.89		48.36
		E	TIMEOUT TIMEOUT TIMEOUT
		iProver	20.64	143.33	TIMEOUT
		Metis	TIMEOUT TIMEOUT TIMEOUT
		Otter	TIMEOUT TIMEOUT TIMEOUT
	Vampire TIMEOUT TIMEOUT TIMEOUT
	1.1-III.1.2. 9

de Legendre du postulat des parallèles d'Euclide Le

  mentionné jusqu'ici, à savoir les postulats d'Euclide, les axiomes de Hilbert et de Tarski, furent des bases de développements systématiques. De ce fait, pour la preuve assistée par ordinateur, ces développements systématiques peuvent servir de références comportenant moins d'arguments implicites qu'une démonstration papier moyenne. Une autre explication de ce rôle central était les nombreux domaines d'application, y compris les mathématiques elles-mêmes, la physique ou des domaines plus appliqués tels que la robotique. Ainsi, la formalisation de la géométrie ouvre la voie à la formalisation de ces domaines. De plus, bien que la nature visuelle de la géométrie puisse suggérer que sa formalisation à l'intérieur d'un assistant de preuve inclurait des étapes inutiles et fastidieuses pour dériver la validité de faits qui semblent évidents, nous croyons au contraire que le traitement de ces étapes est crucial. Soit ces étapes peuvent être automatisées par une procédure systématique. Dans ce cas, trouver une telle procédure et l'implémenter permettrait de réduire l'écart entre les démonstrations papiers et leur formalisation au sein d'un assistant de preuve, rendant ainsi les assistants de preuve plus accessibles aux mathématiciens. En vue d'implémenter une procédure automatisant les étapes d'une preuve formelle, une classe d'assistants de preuve se distingue : ceux basés sur des théories des type intuitionnistes. Grâce à la correspondence de Curry-Howard, exprimant la relation entre les programmes et les démonstrations, la procédure et sa preuve de correction peuvent être encodées dans ces assistants de preuve. Ensuite, automatiser les étapes fastidieuses revient à appliquer le lemme affirmant que la procédure est correcte pour réduire ces étapes à l'éxecution de la procédure. Une telle procédure pourrait même s'avérer faciliter la tâche des mathématiciens d'une manière similaire aux systèmes de calcul formel. Ou bien, le fait supposé être vérifié par ces étapes pourrait également s'avérer ne pas être évident ou possiblement faux. Dans ce cas, l'utilisation d'assistants de preuve pourrait aider à s'en rendre compte. Illustrons maintenant ce cas à l'aide de la démonstration de Legendre du postulat des parallèles d'Euclide. postulat des parallèles d'Euclide est sans doute le plus célèbre des postulats d'Euclide en raison des nombreuses tentatives faites pour prouver qu'il est un théorème plutôt qu'un postulat. Ce postulat peut s'exprimer de la fac ¸on suivante :

	Démonstration

  trivialement construits donc concentrons-nous sur la fac ¸on de construire B i+1 et C i+1 à partir de B i et C i . Posons D i le symétrique de A par rapport au milieu de B i et C i . Soit l une droite passant par D i qui intersecte les deux côtés de ∠BAC enB i+1 et C i+1 . Comme AB i D i C i est un paralléllogramme, nous savons que AB i C i D i et AC i B i D i donc B i+1 = B i et C i+1 = C i car sinon l n'intersecterait pas les deux côtés de ∠BAC. Ainsi, soit B i+1 se situe entre A et B i , soit B i se situe entre A et B i+1 . En supposant que B i+1 se situe entre A et B i , puisque AC i B i D i et C i+1 est colinéaire avec A et C i ,nous aurions B i+1 et C i+1 du même côté de la droite B i D ce qui contredirait le fait que D i se situe entre B i+1 et C i+1 . Ainsi, B i se situe entre A et B i+1 et de même C i se situe entre A et C i+1 . Nous savons que si deux polygones, chacun étant soit un triangle, soit un quadrilatère, avec un côté adjacent, qui combinés forment soit un triangle, soit un quadrilatère, alors le déficit de ce polygone est égal à la somme des déficits des deux polygones. Par conséquent, le déficit du triangle AB i+1 C i+1 vérifie que D(△AB i+1 C i+1 ) > 2 D(△AB i C i ). Ayant construit les séquences souhaitées de points (B i ) i∈N et (C i ) i∈N , nous avons prouvé que l'existence du triangle ABC avec un déficit positif D(△ABC) > 0 entraîne une contradiction, démontrant ainsi que le déficit de tout triangle est nul.

  Pierre Boutry, Gabriel Braun, and Julien Narboux. Formalization of the Arithmetization of Euclidean Plane Geometry and Applications. Journal of Symbolic Computation, 2018 • Gabriel Braun, Pierre Boutry, and Julien Narboux. From Hilbert to Tarski. In Julien Narboux, Pascal Schreck, and Ileana Streinu, editors, Proceedings of the Eleventh International Workshop on Automated Deduction in Geometry, Proceedings of ADG 2016, pages 78-96, Strasbourg, France, June 2016 • Michael Beeson, Pierre Boutry, and Julien Narboux. Herbrand's theorem and non-Euclidean geometry. The Bulletin of Symbolic Logic, 21(2):111-122, 2015 • Pierre Boutry, Julien Narboux, Pascal Schreck, and Gabriel Braun. A short note about case distinctions in Tarski's geometry. In Francisco Botana and Pedro Quaresma, editors, Proceedings of the Tenth International Workshop on Automated Deduction in Geometry, Proceedings of ADG 2014, pages 51-65, Coimbra, Portugal, July 2014 • Pierre Boutry, Charly Gries, Julien Narboux, and Pascal Schreck. Parallel Postulates and Continuity Axioms: A Mechanized Study in Intuitionistic Logic Using Coq. Journal of Automated Reasoning, Sep 2017

  Vue d'ensemble des liens entre les systèmes axiomatiques.

	Hilbert's Axioms	Tarski's Axioms
	Gr. I Gr. II Gr. III	A1 A2 A3 A4 A5 A6 A7 A8 A9	Cartesian plane over a Pythagorean ordered field	Axioms for the area method
	Gr. IV	A10
	Figure F.1.

Let us recall that neutral geometry designates the set of theorems which are valid in both Euclidean and hyperbolic geometry. Therefore, for any given line and any given point, there exists at least a line parallel to this line and passing through this point. This definition excludes elliptic geometry in the sense that an elliptic geometry is not a neutral geometry. Some authors use "absolute geometry" to designate the set of theorems which are valid in Euclidean, hyperbolic and elliptic geometry.

We interest ourselves in the next part to equivalences between versions of the parallel postulate. This study requires the parallel postulate to be independent from the axioms of the theory in which the study is performed. Such a theory can defined by a subset of the axioms of Tarski's geometry, namely the two-dimensional neutral geometry. To highlight the fact that this subset indeed defines a neutral geometry we provide figures both in the Euclidean model and a non-Euclidean model, namely the Poincaré disk model. The figure on the left hand side illustrates the validity of the axiom in Euclidean geometry. The figure on the right hand side either depicts the validity of the statement in the Poincaré disk model or exhibits a counter-example.

We number them as in[START_REF] Tarski | Tarski's System of Geometry[END_REF].

Discrete fields are fields with a decidable equality.

== denotes the boolean equality test for the elements of the field.

A large part of the lemmas were proved using only axioms A1-A8. Thus, these lemmas are valid in any dimension greater than or equal to two.

We chose to omit the definitions of functions corresponding to the arithmetic operations to avoid technicalities.

We denote the axioms using the numbering in[START_REF] Hilbert | Les fondements de la géométrie[END_REF].

Contrary to what is done in Chapter I.1, we consider the continuity and the circle axioms in this section (axioms A11 and CA). We should remark that, in this section, what we refer to as A11 is referred to as A11' in[START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF].

For convenience, we chose to use this different but equivalent definition of a real-closed field.

It is worth emphasizing that this equivalence depends on developing the theory of perpendiculars without any continuity axiom at all, not even the circle axiom. This was one of the main results of[START_REF] Narayan | Contributions to the Axiomatic Foundations of Geometry[END_REF], and is presented in[START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF], where it serves as the foundation to the development of arithmetic in geometry. It is quite difficult even to prove the circle axiom directly from axiom A11 without Gupta's results, although Tarski clearly believed decades earlier that the circle axiom does follow from axioms A1-A11, or he would have included it as an axiom.2. TOWARDS THE DECIDABILITY OF EVERY FIRST-ORDER FORMULA

http://www.michaelbeeson.com/research/FormalTarski/index.php?include=archive11

The numbers given in parentheses are the numbers of the propositions (i.e. Satz) as given in[START_REF] Schwabhäuser | Metamathematische Methoden in der Geometrie[END_REF].

"It is no less certain that the theorem on the sum of the three angles of the triangle must be regarded as one of those fundamental truths which is impossible to dispute and which are an enduring example of mathematical certitude, which one continually pursues and which one obtains only with difficulty in the other branches of human knowledge." The English translation is borrowed from[START_REF] Laubenbacher | Mathematical Expeditions: Chronicles by the Explorers[END_REF].

In constrast to Euclid, we treat the words "postulate" and "axiom" as synonyms. However, we restrict the use of the word "postulate" to statements of the parallel postulate. For the reader interested in the difference between these two words in terms of meaning we refer to[START_REF] Victor Pambuccian | Axiomatizations of Hyperbolic and Absolute Geometries[END_REF].

As mentioned in Chapter I.1, Subsection 1.2 we assume the decidability of the point equality, which is a tautology in classical logic.

That is the reason why Tarski chose this postulate, as he wanted to avoid definitions in his axiom system.

We use the expression 'proof of negation' to describe a proof of ¬A assuming A and obtaining a contradiction. For the reader who is not familiar with intuitionistic logic, we recall that this is simply the definition of negation and this proof rule has nothing to do with the proof by contradiction (to prove A it suffices to show that ¬A leads to a contradiction), which is not valid in our intuitionistic setting.

Up to our knowledge, the following proofs are the only ones that resemble the ones we formalized.

This lemma is present in[START_REF] Braun | From Tarski to Hilbert[END_REF] as it corresponds to Hilbert's version of Pasch's axiom.

We previously referred to interior angles on the same side of a straight line as consecutive interior angles.

Note that we use here the decidability of intersection of lines.

Here we restrict ourselves to the postulates that we formalized.

"It is true that I have come upon much which by most people would be held to constitute a proof; but in my eyes it proves as good as nothing. For example, if we could show that a rectilinear triangle whose area would be greater than any given area is possible, then I would be ready to prove the whole of (Euclidean) geometry absolutely rigorously." The English translation is borrowed from[START_REF] Kline | Mathematical Thought From Ancient to Modern Times[END_REF].

Otherwise, it would provide yet another illustration of the gravity of definitions.

The comment in French Wikipedia about Amiot's proof seems to say that the proof is valid only in Euclidean geometry because it use the construction of THE parallel to line AC trough B. To be precise, the proof does not rely on the uniqueness of this line, only on its existence, so this first step of the proof is valid also in hyperbolic geometry (but not in elliptic geometry). The Wikipedia comment fails to notice that the proof relies on Postulate 7.

Here we use Greenberg's denomination for models of Hilbert's Axioms Group I, II, III and IV[START_REF] Jay | Old and New Results in the Foundations of Elementary Plane Euclidean and Non-Euclidean Geometries[END_REF].

We already presented this proof in French[START_REF] Gries | Somme des angles d'un triangle et unicité de la parallèle : une preuve d'équivalence formalisée en Coq[END_REF].

This lemma is present in[START_REF] Jay | Euclidean and Non-Euclidean Geometries -Development and History[END_REF] and [Har00] (Proposition 7.3) under the name of Crossbar Theorem. Note that

The B i are not known to be collinear, but the fact B i B i+1 ≡ B 0 B 1 and the quantity nB 0 B 1 appear in this proof.

One should also notice that this proof relies on Theorem

9, although it may not be obvious.

We can remark that, thanks the equivalence between Hilbert's and Tarski's axioms, the equivalence between these different versions are also valid in the context of Hilbert's axioms.

By incidence proof, we mean a proof that an object is contained in another one.

One should remember that we are manipulating sets of sets here.

In order to capture that ∀ABCσ, σ ∈ S {A,B,C} ⇒ Col A B C ⇒ Col σ(A) σ(B) σ(C) it suffices that this proposition holds for the generators of S {A,B,C} , namely (A B) and (A B C).

This predicate expresses a property for sets of sets of positives so we decided to name it with ss as prefix. However, to differentiate it from the functions generated by the MSets library we chose to use lowercase letters for this prefix.

We should remark that it was used for the developments based on both Hilbert's and Tarski's axioms.

Exactly as for Col theory, to capture the permutation properties of wd and coinc, it suffices that the permutation properties hold for the generators of S {X 1 ,X 2 ,...,X n+2 } and S {X 1 ,X 2 ,...,X n+3 } , respectively.

We set a timeout at 600 seconds.

In the statement of this lemma, coordinates of point F asserts the existence for any point of corresponding coordinates in F 2 and the arithmetic symbols denote the operators or relations according to the usual notations

.3 A list of statements of previous formalizations of Pythagoras' theorem can be found on Freek Wiedijk web page: http://www.cs.ru.nl/ ˜freek/100/.

Note that it is important that we have a synthetic proof, because we cannot use an algebraic proof to obtain the characterization of parallelism since an algebraic proof would depend on the characterization of parallelism.

We should notice that Wu's or the Gröbner basis methods rely on the Nullstellensatz and are therefore only complete in an algebraically closed field. Hence, we had to pay attention to the characterization of equality. Indeed, as the field F is not algebraically closed, one can prove that x A = x B and y A = y B is equivalent to (x A -x B ) 2 + (y A -y B ) 2 = 0 but this is not true in an algebraically closed one. Therefore, the tactic nsatz is unable to prove this equivalence.

Nous mettons en italique le mot "démonstration" pour souligner le fait qu'il ne s'agisse que d'une tentative de preuve. En effet, nous verrons plus tard que la démonstration est incorrecte.

Dans la partie II, nous étudions les différentes significations de la notion d'équivalence au postulat des parallèles d'Euclide.

Nous utilisons la numérotation des théorèmes de la dixième édition.

Rappelons que la géométrie neutre désigne l'ensemble des théorèmes qui sont valables à la fois en géométrie euclidienne et hyperbolique. Par conséquent, pour une droite donnée et un point donné, il existe au moins une droite parallèle à cette droite et passant par ce point. Cette définition exclut la géométrie elliptique dans le sens où une géométrie elliptique n'est pas une géométrie neutre. Certains auteurs utilisent "géométrie absolue" pour désigner l'ensemble des théorèmes valables en géométrie euclidienne, hyperbolique et elliptique.

"Poursuivre fidèlement le projet exigera que nous prenions la mesure extrême d'écarter les supplications de nos intuitions et de notre imagination -une séparation forcée des pouvoirs mentaux qui sera tout à fait compréhensiblement déroutante et difficile à maintenir [...]."

Nous rappelons que les axiomes du système axiomatique de Tarski étaient désignés par A1-A10 puisque nous avons exclu l'axiome de continuité et que les axiomes de Hilbert ont été regroupés en quatre groupes.

Acknowledgments

Proposition 4. Postulate 7 (alternate interior angles postulate) implies Postulate 3 (triangle postulate).

Proof. Thanks to the tactics developed in [START_REF] Boutry | Using small scale automation to improve both accessibility and readability of formal proofs in geometry[END_REF] the Coq proof is fairly close to the proof we just gave. The first main difference is that we need to deduce two non-degeneracy conditions, namely HNCol1 and HNCol2. The second main difference is not visible here. In fact, the proof that we just gave is different from usual proof that the sum of the interior angles of a triangle is equal to According to Borsuk and Szmielew [START_REF] Borsuk | Foundations of Geometry[END_REF], in planar neutral geometry (i.e. without assuming the parallel postulate) it cannot be proved that the function associating coordinates to a given point is surjective. But assuming the parallel postulate, we can show that there is a one-to-one correspondence between the pairs of points on the ruler representing the coordinates and the points of the plane:

Algebraic Characterization of Congruence.

We recall that Tarski's system of geometry has two primitive relations: congruence and betweenness. Following Schwabhäuser, we formalized the characterizations of these two geometric predicates. We have shown that the congruence predicate which is axiomatized is equivalent to the usual algebraic formula stating that the squares of the Euclidean distances are equal: 2 The proof relies on Pythagoras' theorem (also known as Kou-Ku theorem). Note that we need a synthetic proof here. It is important to notice that we cannot use an algebraic proof because we are building the coordinatization of geometry. The statements for Pythagoras' theorem that have been proved previously 3 are theorems about vectors: the square of the norm of the sum of two orthogonal vectors is the sum of the squares of their norms. Here we provide the formalization of the proof of Pythagoras' theorem in a geometric context. Length O E E' A B L expresses that the length of the segment AB can be represented by a point called L in the coordinate system O, E, E .

Our formal proof of Pythagoras' theorem itself employs the intercept theorem (also known in France as Thales' theorem). These last two theorems represent important theorems in geometry, especially in the education. Prodg O E E' A B C designates the generalization of the multiplication which establishes as null the product of points for which Ar2 does not hold. Then we proved the equivalence with the geometric definitions:

Finally, we could prove axioms AM 11 and AM 12 which correspond to properties which had already been proved in the context of Tarski's axioms. The fact that we have the possibility to perform both automatic theorem proving and interactive theorem proving in the same setting is very useful: it allows to perform manual geometric reasoning when the algebraic method fails and to get some proofs automatically when it is possible. Table III.2.2. The axiom system for the area method

Equilateral Triangle Construction in Euclidean Hilbert's planes

In this section, we solve a challenge proposed by Beeson in [START_REF] Beeson | Proof and Computation in Geometry[END_REF]: we obtained a mechanized proof that given two points A and B we can always construct an equilateral triangle based on these two points without continuity axioms. This is the first proposition of the first book of Euclid's Elements [START_REF] Euclid | Euclid's Elements: all thirteen books complete in one volume : the Thomas Little Heath translation[END_REF], but Euclid's proof assumes implicitly the axiom of circle-circle continuity, which states that the intersections between two circles exist under some conditions. Assuming circle-circle continuity, the proof is straightforward. The challenge is to complete the proof without continuity axioms. It is possible to prove that such a triangle exists in any Euclidean Hilbert plane. But Pambuccian has shown that this theorem cannot be proved in all Hilbert planes, even if one assumes Bachmann's Lotschnittaxiom or the Archimedes' axiom [START_REF] Victor Pambuccian | Zur Existenz gleichseitiger Dreiecke in H-Ebenen[END_REF]. The proof is based on Pythagoras' theorem, and, as we now have access to automatic deduction in geometry using algebraic methods, the theorem can be proved automatically. Let a be the distance AB, we need to construct the length

Definitions of the Geometric Predicates Necessary for the Arithmetization and the Coordinatization of Euclidean Geometry

Coq Definition

Tarski's Axioms

Definitions and notations of the Geometric Predicates

CD

The lines AB and CD have a common perpendicular which passes through P .

BetS A B C

A B C B is strictly between A and C.

SAMS A B C D E F

The angles ∠ABC and ∠DEF do not make an over-obtuse angle.

Saccheri A B C D S A B C D

The quadrilateral ABCD is a Saccheri quadrilateral.

Lambert A B C D L A B C D

The quadrilateral ABCD is a Lambert quadrilateral.

ReflectL P' P A B A P • P P • P B P is the image of P by the reflection with respect to the line AB.

Perp bisect P Q A B P

The line P Q is the perpendicular bisector of the segment AB.

The angle ∠DEF is the defect of the triangle ABC.

Summary in French

Tout au long de l'histoire de la preuve mathématique, la géométrie a joué un rôle central. En effet, l'un des travaux les plus influents dans l'histoire des mathématiques concerne la géométrie : les Éléments d'Euclide [START_REF] Euclid | Euclid's Elements: all thirteen books complete in one volume : the Thomas Little Heath translation[END_REF]. Pendant plus de 2000 ans, il a été considéré comme un paradigme d'argumentation rigoureuse. Encore de nos jours, ce traité fait toujours l'objet de recherches [ADM09, BNW17]. De plus, les Éléments d'Euclide ont introduit l'approche axiomatique qui est encore utilisée aujourd'hui.

En outre, l'un des événements importants dans l'histoire des mathématiques est la crise des fondements. Après la découverte du paradoxe de Russell, les mathématiciens ont cherché une nouvelle base cohérente pour les mathématiques. Au cours de cette période, trois écoles de pensée différentes ont émergé, l'école dominante ayant opté pour une approche formaliste. La géométrie a joué un rôle important pour cette école dominante. En effet, elle était dirigée par Hilbert qui a commencé son travail sur le formalisme avec la géométrie, travail ayant débouché sur l'ouvrage Grundlagen der Geometrie [START_REF] Hilbert | Foundations of Geometry (Grundlagen der Geometrie[END_REF].

Durant cette crise, les mathématiciens ont commencé à faire la distinction entre les théorèmes et les métathéorèmes pour mettre en évidence que ces derniers correspondent à des théorèmes sur les mathématiques elles-mêmes. Tout comme pour les mathématiques, la géométrie a eu une place importante dans l'histoire des métamathématiques. Tout d'abord, le premier jalon dans l'histoire des métamathématiques est probablement la découverte de la géométrie non euclidienne [Bol32, Lob85, Bel68]. À ce propos, l'impact de cette découverte a été très important dans l'histoire des mathématiques. Ensuite, en dehors de Hilbert, une autre personnalité majeure des métamathématiques, à savoir Tarski, a consacré une partie notable de ses recherches à une axiomatisation de la géométrie [Tar59, SST83, TG99] qu'il propose avec un attention particulière au sujet de ses propriétés métamathématiques.

Enfin, la géométrie a influencé d'autres domaines des mathématiques. Lorsque Descartes a inventé la géométrie analytique [START_REF] Descartes | La Géométrie. Open Court[END_REF], il a commencé à considérer les carrés de nombres non seulement comme des aires, mais aussi comme des longueurs. Cela l'a amené à analyser les équations algébriques de degré supérieur à trois qui, jusque-là, correspondaient à des objets tridimensionnels et étaient considérées comme la dimension la plus élevée de l'univers. Ainsi, l'invention de la géométrie analytique s'est avérée cruciale dans le développement de l'algèbre moderne, mais elle a aussi contribué à la découverte du calcul infinitésimal. Le calcul infinitésimal a été créé par Leibniz [START_REF] Wilhelm | Nova methodus pro maximis et minimis, itemque tangentibus, qua nec fractas nec irrationales quantitates moratur, et singulare pro illi calculi genus[END_REF] et Newton [START_REF] Newton | The Method of Fluxions and Infinite Series (Translated from the Author's Latin Original by John Colson)[END_REF] pour étudier les quantités en constante évolution. Par exemple, Newton étudiait l'évolution de la vitesse de chute d'un objet. Toutefois, avant lui, aucun mathématicien n'était en mesure de déterminer cette vitesse. Grâce à la géométrie analytique, Newton a compris qu'elle correspondait à la dérivée de la position de l'objet tombant, créant ainsi le calcul infinitésimal. L'algèbre et le calcul infinitésimal ne sont pas les seuls domaines que la géométrie a affecté. En fait, la théorie des nombres a toujours été l'un des principaux domaines d'application de la géométrie. Dès le troisième siècle avant J.-C., Euclide a présenté une exposition de la théorie des nombres fondée sur la géométrie. En 1995, la géométrie était toujours utilisée par Wiles dans sa preuve du dernier théorème de Fermat [START_REF] Wiles | Modular Elliptic Curves and Fermat's Last Theorem[END_REF][START_REF] Taylor | Ring-Theoretic Properties of Certain Hecke Algebras[END_REF].

L'un des buts d'une preuve mathématique est de garantir la véracité d'un énoncé mathématique. Dans ce but, avoir accès à un mécanisme de vérification d'une preuve mathématique devient très attrayant. Cette idée remonte à Leibniz et son calculus ratiocinator, qu'il a inventé en 1666 [START_REF] Wilhelm | Dissertation on the Art of Combinations[END_REF]. Néanmoins, Leibniz était très en avance sur son temps car il a fallu des centaines d'années pour que son rêve devienne réalité. En effet, le premier système formel qui pouvait être mécanisé, à savoir le Begriffsschrift [START_REF] Frege | Begriffsschrift: Eine der arithmetische nachgebildete Formelsprache des reinen Denkens[END_REF] de Frege, est apparu en 1879 et le premier langage formel, à savoir le système Automath [NGdV94] de de Bruijn, fut conc ¸u en 1967. Depuis Automath, une pléthore d'assistants de preuve ont été développés [START_REF] Wiedijk | The Seventeen Provers of the World: Foreword by Dana Scott[END_REF]. Fait intéressant, les mêmes raisons qui expliquent le rôle central de la géométrie dans l'histoire de la preuve mathématique motivent également la preuve assistée par ordinateur en géométrie. En effet, les trois systèmes axiomatiques que nous avons