# Dealing with Degeneracies in Automated Theorem Proving in Geometry

^{1}

^{2}

^{3}

^{*}

^{†}

## Abstract

**:**

## 1. Introduction

## 2. Automated Reasoning Tools in GeoGebra

- For conjecturing some geometric property (e.g., “...these three lines visually “seem” to meet at one point. Is this actually true?...”);
- For rigorously confirming or denying a proposed conjecture (e.g., yielding an affirmative answer after internally verifying, using Computer Algebra tools, that the equations describing the three selected lines have always a common solution);
- For suggesting some complementary hypotheses for the truth of a given (initially false) statement (i.e., declaring some further restrictions in the geometric elements involved in the statement, that are required for its verification).

#### 2.1. The Altitude Theorem

#### 2.2. A problem from a Spanish ‘Oposiciones’ Exam

#### 2.3. Ongoing Work

## 3. A Simplified Introduction to the Algebro-Geometric Background

## 4. Complications

`EliminationIdeal(<(c_1-o_1)^2+(c_2-o_2)^2-(a_1-o_1)^2-(a_2-o_2)^2,``o_1-(a_1+b_1)/2, o_2-(a_2+b_2)/2,``((c_1-b_1)*(c_1-a_1)+(c_2-b_2)*(c_2-a_2))*t-1>,``{a_1,a_2,b_1,b_2,c_1});``<1>`

## 5. Reflecting about Degeneracy Conditions

## 6. A Proposal to Avoid Working with Degeneracy Conditions

**Definition**

**1.**

**Remark**

**1.**

**Proposition**

**1.**

**Proposition**

**2.**

**Definition**

**2.**

- How to fully verify the generally false case when $dim\left(H\right)\ne d$? See Example 2 in [15], for a situation where the zero elimination requirement derived from Proposition 2 is necessary but not sufficient for being not generally false.
- How to discriminate non-degenerate components where the thesis holds from those where the thesis fails, in the “true on components” case? This is usually a source of geometric insight, as it shows further restrictions that have to be added for a certain statement to be always true, usually related to the lack of precision of the algebraic translation (e.g., not declaring if the vertex C of an equilateral triangle $A(0,0),B(1,0),C(x,y)$ stands up or down the x-axis, see Example 1 in [15]).

- (1)
- Isolating the collection of non-degenerate components of H by means of saturation, see Proposition 3 below, and then applying the criteria from the above Propositions.
- (2)
- Working directly in a zero-dimensional context (as in [16] but without having to compute zero-divisors), extending ideal H to the ring $K\left(Y\right)\left[Z\right]$, i.e., including the selected free variables as elements of the coefficient field.

**Proposition**

**3**

**.**If S is a multiplicatively closed subset of a ring A and I is a decomposable ideal of A, with a minimal primary decomposition $I=\cap {Q}_{i},i=1\dots n$, then ${S}^{-1}I$ decomposes with a minimal primary decomposition as $\cap {S}^{-1}{Q}_{i},i=1\dots m$, where ${Q}_{i},i=1\dots m$ denote those primary components such that the associated prime ideals do not meet S. Its contraction (the contraction of the “extension of $={S}^{-1}I=S\left(I\right)$”, also called saturation of I) has also as primary minimal decomposition the intersection of ${Q}_{i},i=1\dots m$.

**Proposition**

**4.**

**Proof.**

**Proposition**

**5.**

**Proof.**

**Corollary**

**1.**

**Proof.**

- Choose—from the geometric construction—a meaningful maximal set of independent variables Y. Verify they are actually maximally independent from the algebraic point of view, using elimination commands.
- Restrict the hypotheses variety to the union of non-degenerate components, by using the saturation $S\left(H\right)$ of the hypotheses ideal with respect to S, the polynomial ring in the Y variables.
- Use the elimination commands, as in Proposition 1 and 2, to test the general truth or falsity of the statement over $S\left(H\right)$; or use the Corollary over ${S}^{-1}H$.
- If the output is ‘true on some, false on some’ non-degenerate components, perform a primary decomposition of ${S}^{-1}HK\left(Y\right)\left[Z\right]$. Use Proposition 5 to analyze individually each component, as this proposition shows that the result is valid over the corresponding components in $HK[Y,Z]$.

## 7. An Example

**Example**

**1.**

`EliminationIdeal(<(x-a1)^2+(y-a2)^2-((a1-b1)^2+(a2-b2)^2),``(u-b1)^2+(v-b2)^2-((a1-b1)^2+(a2-b2)^2),``(x-a1)*(b1-a1)+ (y-a2)*(b2-a2),``(u-b1)*(b1-a1)+(v-b2)*(b2-a2),``((u-x)*(b2-a2) -(v-y)*(b1-a1))*t-1>,{a1,a2,b1,b2});``<0>``EliminationIdeal(<(x-a1)^2+(y-a2)^2-((a1-b1)^2+(a2-b2)^2),``(u-b1)^2+(v-b2)^2-((a1-b1)^2+(a2-b2)^2),(``x-a1)*(b1-a1)+ (y-a2)*(b2-a2),``(u-b1)*(b1-a1)+(v-b2)*(b2-a2),``((u-x)*(b2-a2) -(v-y)*(b1-a1))>,{a1,a2,b1,b2});``<0>`

## 8. Conclusions

## Author Contributions

## Funding

## Conflicts of Interest

## References

- Wu, W.T. On the decision problem and the mechanization of theorem-proving in elementary geometry. Sci. Sin.
**1978**, 21, 159–172, Reprinted in Automated Theorem Proving: After 25 Years; Bledsoe, W. W., Loveland, D. W., Eds.; Contemporary Mathematics; AMS: Providence, RI, USA, 1984; Volume 29, pp. 213–234. [Google Scholar] - Botana, F.; Hohenwarter, M.; Janičić, P.; Kovács, Z.; Petrović, I.; Recio, T.; Weitzhofer, S. Automated Theorem Proving in GeoGebra: Current Achievements. J. Autom. Reason.
**2015**, 55, 39–59. [Google Scholar] [CrossRef] - Kovács, Z.; Recio, T.; Vélez, M.P. Using Automated Reasoning Tools in GeoGebra in the Teaching and Learning of Proving in Geometry. Int. J. Technol. Math. Educ.
**2018**, 25, 33–50. [Google Scholar] - Alsina, C.; Nelsen, R.B. Icons of Mathematics: An Exploration of Twenty Key Images; Mathematical Association of America: Washington, DC, USA, 2011. [Google Scholar]
- Etayo, F.; de Lucas, N.; Recio, T.; Vélez, M.P. Inventando teoremas con GeoGebra: Un nuevo Teorema de la Altura. Boletín de la Sociedad “Puig Adam” de Profesores de Matemáticas
**2021**, 111, 8–28. [Google Scholar] - Kovács, Z.; Recio, T.; Vélez, M.P. Merging Maple and GeoGebra Automated Reasoning Tools. In Maple in Mathematics Education and Research; Corless, R.M., Gerhard, J., Kotsireas, I., Eds.; Communications in Computer and Information Science Series; Springer Nature Switzerland AG: Cham, Switzerland, 2021; accepted. [Google Scholar]
- Chou, S.C. Mechanical Geometry Theorem Proving; D. Reidel Publishing Company: Dordrecht, The Netherlands, 1988. [Google Scholar]
- Gamboa, J.M.; Baena, F.J.; de Diego, B.; Llerena, A.; Lorenzo, J.M.; Rodríguez, B.; Fernando, J.F.; Salgueiro, B. Problemas Resueltos de Oposiciones. Tomo 9 (2017 y 2018), 2nd ed.; Editorial Deimos: Madrid, Spain, 2019. [Google Scholar]
- Kovács, Z.; Recio, T.; Vélez, M.P. Automated Reasoning Tools with GeoGebra: What are they? What are they good for? In Mathematics Education in the Age of Artificial Intelligence; Richard, P.R., Vélez, M.P., Van Vaerenbergh, S., Eds.; Mathematics Education in the Digital Era Series; Springer Nature Switzerland AG: Cham, Switzerland, 2022; accepted. [Google Scholar]
- Botana, F.; Kovács, Z.; Recio, T. A Mechanical Geometer. Math. Comput. Sci.
**2020**. [Google Scholar] [CrossRef] - Kovács, Z.; Recio, T. GeoGebra reasoning tools for humans and for automatons. In Electronic, Proceedings of the 25th Asian Technology Conference in Mathematics, Online, 14–16 December 2020; Published by Mathematics and Technology, LLC; ISSN 1940-4204. (Online Version); Available online: http://atcm.mathandtech.org/EP2020/invited/21786.pdf (accessed on 13 August 2021).
- Recio, T.; Vélez, M.P. Automatic Discovery of Theorems in Elementary Geometry. J. Autom. Reason.
**1999**, 23, 63–82. [Google Scholar] [CrossRef] - Kovács, Z.; Recio, T.; Sólyom-Gecse, C. Rewriting input expressions in complex algebraic geometry provers. Ann. Math. Artif. Intell.
**2019**, 85, 73–87. [Google Scholar] [CrossRef] - Vajda, R.; Kovács, Z. GeoGebra and the realgeom Reasoning Tool. In Joint, Proceedings of the 7th Workshop on Practical Aspects of Automated Reasoning (PAAR) and the 5th Satisfiability Checking and Symbolic Computation Workshop (SC-Square) Workshop, 2020, Co-Located with the 10th International Joint Conference on Automated Reasoning (IJCAR 2020), Virtual, June–July 2020; Fontaine, P., Korovin, K., Kotsireas, I.S., Römmer, P., Tourret, S., Eds.; CEUR Workshop Proceedings 2752; 2020; pp. 204–219. Available online: http://ceur-ws.org/Vol-2752 (accessed on 13 August 2021).
- Kovács, Z.; Recio, T.; Vélez, M.P. Detecting truth, just on parts. Revista Matematica Complutense
**2019**, 32, 451–474. [Google Scholar] [CrossRef][Green Version] - Zhou, J.; Wang, D.; Sun, Y. Automated reducible geometric theorem proving and discovery by Gröbner basis method. J. Autom. Reason.
**2017**, 59, 331–344. [Google Scholar] [CrossRef] - Ladra, M.; Páez-Guillán, P.; Recio, T. Dealing with negative conditions in automated proving: Tools and challenges. The unexpected consequences of Rabinowitsch’s trick. Revista de la Real Academia de Ciencias Exactas Físicas y Naturales
**2020**, 114, 1–16. [Google Scholar] [CrossRef] - Giac/Xcas Homepage. Available online: https://www-fourier.ujf-grenoble.fr/~parisse/giac.html (accessed on 14 December 2020).
- Kovács, Z.; Parisse, B. Giac and GeoGebra—Improved Gröbner basis computations. In Computer Algebra and Polynomials; Gutierrez, J., Schicho, J., Weimann, M., Eds.; Lecture Notes in Computer Science; Springer: Cham, Switzerland, 2015; Volume 8942, pp. 126–138. [Google Scholar]
- Dalzotto, G.; Recio, T. On protocols for the automated discovery of theorems in elementary geometry. J. Autom. Reason.
**2009**, 43, 203–236. [Google Scholar] [CrossRef] - Atiyah, M.F.; Macdonald, I.G. Introduction to Commutative Algebra; Addison-Wesley: Reading, MA, USA, 1969. [Google Scholar]

**Figure 1.**Left, GeoGebra is asked about the validity of the Altitude Theorem over an arbitrary triangle. Right, it declares it is false.

**Figure 2.**Left, possible locus of C for the validity of the Altitude Theorem. Right, confirmation after placing C on the hyperbola.

**Figure 6.**The Automated Geometer at work, finding in 5 s 28 theorems concerning the selected relations: collinearity of three points, perpendicularity, parallelism of lines, or equality of segments, holding over the given figure.

**Figure 7.**Two different outputs (Boolean Value $d=true$, or “true on parts, false on parts”) for the thesis of the Altitude Theorem over a right triangle, when the Prove, respectively, the Relation commands are used.

Publisher’s Note: MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations. |

© 2021 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https://creativecommons.org/licenses/by/4.0/).

## Share and Cite

**MDPI and ACS Style**

Kovács, Z.; Recio, T.; Tabera, L.F.; Vélez, M.P. Dealing with Degeneracies in Automated Theorem Proving in Geometry. *Mathematics* **2021**, *9*, 1964.
https://doi.org/10.3390/math9161964

**AMA Style**

Kovács Z, Recio T, Tabera LF, Vélez MP. Dealing with Degeneracies in Automated Theorem Proving in Geometry. *Mathematics*. 2021; 9(16):1964.
https://doi.org/10.3390/math9161964

**Chicago/Turabian Style**

Kovács, Zoltán, Tomas Recio, Luis F. Tabera, and M. Pilar Vélez. 2021. "Dealing with Degeneracies in Automated Theorem Proving in Geometry" *Mathematics* 9, no. 16: 1964.
https://doi.org/10.3390/math9161964