Next Article in Journal
Toward a Distributed Potential Game Optimization to Sensor Area Coverage Problem
Previous Article in Journal
Computation of the Approximate Symmetric Chordal Metric for Complex Numbers
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

A Machine Proof of the Filter-Method Construction for Real Numbers

Beijing Key Laboratory of Space-Ground Interconnection and Convergence, School of Electronic Engineering, Beijing University of Posts and Telecommunications, Beijing 100876, China
*
Author to whom correspondence should be addressed.
Mathematics 2025, 13(17), 2707; https://doi.org/10.3390/math13172707
Submission received: 15 June 2025 / Revised: 19 August 2025 / Accepted: 20 August 2025 / Published: 22 August 2025
(This article belongs to the Section E1: Mathematics and Computer Science)

Abstract

This paper presents a machine verification of a real number theory where real numbers are constructed using concepts related to filters. The theory encompasses a special filter, namely the non-principal arithmetical ultrafilter whose existence can be proven with the Continuum Hypothesis, to establish several non-standard number sets: *N, *Z and *Q. The set of real numbers, R , is subsequently obtained by the equivalence classification of a specific subset of *Q. The entire theory is thoroughly formalized, with each detail verified to ensure rigor and precision. The verification is implemented using the Coq proof assistant and is grounded in the Morse–Kelley axiomatic set theory. This work contributes a new selection of foundational material for the formalization of mathematical theories.

1. Introduction

This paper is dedicated to implementing the mechanized proof (also known as formalization or formal/machine verification) of a specific real number theory, which was first mentioned by Wang in [1], then introduced in one of his monographs [2] published in 2018. This mathematical theory employs a special filter, named the “non-principal arithmetical ultrafilter” [3], to facilitate the construction of real numbers. In this paper, we refer to it as the “filter-method construction for real numbers” (FMCR). The proof is implemented in the Coq proof assistant (The Coq proof assistant was renamed “Rocq Prover” in 2025, see https://rocq-prover.org, accessed on 19 August 2025), an interactive theorem-proving tool, and is based on Morse–Kelley axiomatic set theory (MK) [4].
Mechanized theorem proving refers to the formal verification of mathematical theorems or computer software and hardware systems using computers through formal methods [5]. “The word ‘formal’ indicates the use of formal languages to write assertions, define objects, and specify constraints. It also indicates the use of formal semantics, that is, accounts of the meaning of a syntactic expression, which can be used to specify the desired behavior of a system or the properties of an object sought” [6]. Mechanized theorem proving can be divided into interactive theorem proving (ITP) and automated theorem proving (ATP). And the former is likely to be more desirable to formalize most non-trivial theorems in mathematics or computer system correctness [5,7].
ITP emerged in the 1960s [8], and interactive theorem-proving tools are also known as proof assistants. “ITP involves the use of proof assistants to construct formal proofs of mathematical claims using the axioms and rules of a formal foundation that is implemented by the system. The user of such an assistant generally has a proof in mind and works interactively with the system to transform it into a formal derivation. Proofs are presented to the system using a specialized proof language, much like a programming language. The proof assistants process the input, complains about the parts it cannot understand, keeps track of goals and proof obligations, and responds to queries, say, about definitions and theorems in the background libraries. Most importantly, every inference is checked for correctness using a small, trusted body of code, known as the kernel or trusted computing base” [6]. With the continuous advancement of computer science and technology, various theorem-proving tools such as Coq [9,10], Isabelle/HOL [11], HOL Light [12], Mizar [13], and Lean [14] have emerged. ITP has also gradually gained recognition and attention in the academic community.
The formal verification of mathematical theorems is the practice of using a rigorously structured formal language, often within proof assistants on a computer, to describe mathematical definitions and theorems. These definitions and theorems are then proven using a corresponding proof language, ultimately resulting in the establishment of a formal mathematical library that encompasses mathematical definitions, theorems and their formal proofs [6,15,16]. To date, many core theorems of mathematics have been formally verified in various proof assistants, such as the prime number theorem [17], the four color theorem [18], the Jordan curve theorem [19], Gödel’s first and second incompleteness theorems [20], the Cartan fixed-point theorems [21], and the central limit theorem [22]. In November 2008, the Notices of the American Mathematical Society devoted a special issue to the topic of interactive theorem proving, which provides an overview of the state of the field at the time [15]. In 2013, Georges Gonthier and thirteen co-authors announced the culmination of a six-year project that resulted in the verification of the Feit–Thompson odd order theorem [23]. In 2015, the formal verification of the Kepler conjecture was completed under the leadership of Thomas Hales [24]. In December 2023, the project initiated by Terence Tao to formalize the proof of the Polynomial Freiman–Rusza Conjecture also succeeded [25]. These achievements contribute to the growing influence of mechanized proving of mathematical theorems in the academic community. The renowned mathematician and computer scientist Freek Wiedijk believes that the ongoing formalization of mathematics is a mathematical revolution [26]. “With the help of computational proof assistants, formal verification could become the new standard for rigor in mathematics” [15].
As far as real number theory is concerned, in the initial stage of its formulation, methods can be broadly categorized into two approaches: the Dedekind cut method introduced by Dedekind and the Cauchy sequence method proposed by Cantor, both of which have become well established in mathematical discourse. These two enduring and classic theories continue to be widely accepted and applied in contemporary mathematical research. Nevertheless, it appears that human curiosity concerning the real numbers is not quite quenched with just these two constructions and there are still new methods of constructing real numbers proposed up to the 21th century [27]. Meanwhile, fueled by applications in automated (mechanized) theorem proving and verification, where one must represent the real numbers in a computer, nuances of the differences between various constructions of the reals become very pronounced [27]. As a result, the formal verification of these theories on real numbers represents both a profound exploration of the fundamental theories of mathematics and a significant enrichment of the foundational materials required for the formalization of mathematical theorems. This enrichment, in turn, offers a broader array of choices for future formalization efforts. Therefore, the formalization of FMCR serves as not only a comprehensive and rigorous verification of the theory itself but also a means to provide further starting points and possibilities for future formalization work.
FMCR employs a special filter, the non-principal arithmetical ultrafilter (NPAUF), to construct real numbers. Filter and ultrafilter are mathematical concepts that can be derived from topology. In [28,29], we, respectively, presented the formalization of filter-related theories and the existence of NPAUF in Coq. This paper will further introduce the Coq formalization of the entire process of constructing real numbers using NPAUF.
Compared to classical real number theories, FMCR possesses several distinctive features:
1. The construction involves the non-standard extension of number systems. With the use of NPAUF, the set of natural numbers can be extended to the non-standard natural number set *N, which is a useful non-standard model that has simple construction and superior properties [1]. *N includes some special elements at infinity that can be named infinity natural numbers. Infinity numbers are greater than all natural numbers (infinitely large) but follow the general arithmetic properties (addition, multiplication, order, etc.) of natural numbers. Following the idea of equivalence classification, *N can be further extended to the non-standard integer set *Z inclusive of infinity integers, and the non-standard rational number set *Q, which encompasses both infinity and infinitesimal numbers (numbers that are infinitely small). The structure of real numbers is then obtained by equivalently classifying a specific subset of *Q.
2. The establishment of this method requires additional set theory hypotheses as premises, for the existence of NPAUF has not been proven within general axiomatic set theories [2,30]. In [29], we implemented the Coq formalization of the proof provided by Wang in [2,30] that the Continuum Hypothesis (CH) implies the existence of NPAUF. Therefore, in order to formalize FMCR, CH actually needs to be acknowledged as a precondition or axiom. CH is consistent and compatible with the general axiomatic set theories, and can be safely employed [31,32].
3. This method could potentially be extended to establish the foundation of non-standard analysis—non-standard real numbers, also known as hyper-reals. Robinson once quoted Gödel’s statements in the preface of his masterpiece Nonstandard Analysis [33]: “There are good reasons to believe that non-standard analysis, in some version or other, will be the analysis of the future”. The majority of literature on non-standard analysis typically utilizes the ultrapower method to provide a model for hyper-reals [33,34,35]. Although FMCR does not directly construct hyper-reals, the construction process involves some non-standard number sets: *N, *Z and *Q. The underlying concepts involving NPAUF might serve as an alternative to the ultrapower method for hyper-real construction. As mentioned in [28,29], our long-term goal is to formalize the non-standard analysis.
Following the previous work in [28,29], we choose the Coq proof assistant to implement the formal verification, and the formal system of Morse–Kelley axiomatic set theory (MK) in Coq [36,37] as the basis for the work in this paper. Indeed, set theory is the foundation of modern mathematics, and axiomatic set theories, developed to address Russell’s Paradox, can undoubtedly serve as the basis for highly rigorous formal verification of mathematical theorems. Furthermore, MK recognizes a broader range of mathematical objects than just “sets”, called “classes”, making it a proper extension of Zermelo–Fraenkel axiomatic set theory (with the Axiom of Choice) (ZFC) and relatively more convenient to utilize in the formalization process [28,29,36,37].
The mathematical descriptions of definitions and theorems used in this paper are mainly taken from textbooks [2,4,30] ([4] contributes to the part of MK and [2,30] to the filters and FMCR). The entire Coq code is available at https://github.com/1DGW/formal-verification-of-the-filter-method-construction-for-real-numbers, accessed on 19 August 2025.
The paper is organized as follows: Section 2 presents the relevant preliminary knowledge required for this paper; Section 3 presents the formalization of the construction of the sets *N, *Z and *Q; Section 4 presents the formalization of real number set R and the verification of elementary properties of real numbers; Section 5 gives the conclusion and further perspectives.

2. Preliminary Knowledge

In this section, we outline some fundamental usages of Coq tailored to our work, and present basic formalization results required for FMCR.

2.1. About Coq

The process of formalizing a mathematical theory can be roughly divided into two parts: one is to describe definitions and theorems using a formal language, which is like a “translation process” from a natural language; and the other entails gradually discharging proof goals using formal proof tactics in an interactive environment in order to ensure the correctness of the described content. Due to significant differences in logic, syntax, and semantics between natural and formal languages, accurately translating a natural language into a logically rigorous formal language becomes the most crucial step in the formalization process.
In Coq, there are several commands that can be used to describe mathematical definitions such as “Definition”, “Inductive”, “Fixpoint”, etc. Each of them has different roles, and “Definition” is sufficient for our system.
The description of a definition is written “Definition c : A := t.” For this definition to be accepted, it is necessary that t is well typed in the current environment and context, that the type of c is A, and that c does not clash with the name of another global variable. The Coq system has a type-inference mechanism that can determine the type of t; thus, the definition sometimes can be simply written “Definition c := t.
From the mathematical perspective, c can be regarded as the name of a definition and t the specific content of it. For example, to define the square of a natural number n, the definition is described as:
  • Mathematics 13 02707 i001
where “fun” is the key word used to write anonymous programming functions in Coq. Here, it takes a natural number n and returns its square n · n . To make the code concise, the definition is often written:
  • Mathematics 13 02707 i002
In this form, n can be regarded as the parameter of this definition, and the type “nat” of n can be determined by the Coq system and thus can be defaulted.
Additionally, to simplify the expressions, we can introduce notations for definitions:
  • Mathematics 13 02707 i003
The command “Declare Scope” declares the scope “scope_nat” where the notation is interpreted. All notations in scope_nat can be interpreted when the scope is open with the command “Open Scope”. “Delimit Scope” links the delimiting key “nat” to scope_nat, which helps to interpret the notations in scope_nat when the scope is close or to distinguish those identical notations but in different scopes. For example, “(3 2)%nat” still can be interpreted as the square of the natural number 3 even if “3 2” would represent a different definition in another scope, or scope_nat would be close.
The “Theorem” command is used to state that one wants to prove a theorem, indicating the name of this theorem and its statement. For example, to prove the logic proposition “For every proposition P , Q , R , ( P Q ) ( ( Q R ) ( P R ) ) ”, we can write:
  • Mathematics 13 02707 i004
where “prop_trans” represents the name of this theorem, and “->”, right-associative, can serve as “⟹”. Followed by Theorem, proofs start with the “Proof” command and end with “Qed”. Between Proof and Qed, proof tactics need to be written to discharge all proof goals and make the code able to run and pass successfully. For the example above, the complete formal verification is as follows:
  • Mathematics 13 02707 i005
The tactic “intros” is used to introduce the premises (i.e., the parameters P, Q, R and the premises (P -> Q), (Q -> R) and P) to the proof environment as hypotheses. The tactic “auto” is a built-in automated tactic in Coq, designed to solve simple proof goals.
Table 1 lists some fundamental tactics with their semantics. For additional tactics and detailed usage, refer to [9,10].
As previously mentioned, the critical step of the formalization process is the formal description of definitions and theorems. Therefore, this paper focuses on formal descriptions of definitions and theorems, and in Section 4.3 we present brief semantic explanations of formal proofs (tactics) through the verification of Archimedean property and completeness of real numbers. Readers can run the code we provide to verify the correctness of the descriptions and proofs.
Besides Theorem, there are many other synonymous commands, such as “Lemma”, “Corollary”, “Proposition”, “Property” and “Fact”, that can be interchangeably used as needed.
In some cases, we may need to declare a proposition that is temporarily unprovable or a mathematical object that is temporarily unconstructible, such as in the description of axioms. In such situations, the commands “Axiom” or “Parameter” are used. Their usage is similar to Theorem, but the contents declared by these two commands do not require proofs and can be invoked directly.
At this point, the understanding for Coq is sufficient to comprehend the content of the following sections. For more details on Coq usage, refer to [9,10].

2.2. About MK

Our team has finished the formalization of Morse–Kelley axiomatic set theory (MK) [36,37], and the entire code has been included in the Coq official contribution repository, indexed at https://coq.inria.fr/coq-package-index, accessed on 19 August 2025. Here, we summarize its important content as preparatory knowledge.
MK is grounded in Classical Logic [4], whereas the Coq system adopts Intuitionistic Logic [9]. Therefore, the Law of Excluded Middle needs to be assumed:
  • Mathematics 13 02707 i006
MK acknowledges “classes” (which are more numerous than sets) as fundamental objects. That is to say, every mathematical object (ordered pair, function, integer, etc.) is a class, and only those classes belonging to some other ones are defined as sets. The non-set classes are named “proper classes”. The term “class” does not appear in any axiom, it is a term that is directly recognized without definition. In Coq, the term “class” is declared as a new type “Class”, using the command “Parameter”.
  • Mathematics 13 02707 i007
There are two primitive constants in addition to the term “class”. The first is “∈”, which is read “is a member of” or “belongs to”. This means that one mathematical object (class) can be an element of another. The second is denoted “ { · · : } ” and is read “the class of all · · such that ⋯”. It is the classifier and represents a class consisting of classes that satisfy a specific property. For example, “ { x : x y } ” represents the class that consists of all members not belonging to y. The constant “∈” is described as “In” and “ { · · : } ” as “Classifier”.
  • Mathematics 13 02707 i008
The type of “In” is actually “Class -> Class -> Prop”, indicating that it takes two classes as input and produces a proposition. For instance, given classes x and y, “x ∈ y” represents the proposition that x belongs to y.
The type of “Classifier” is slightly more intricate. In its type “(Class -> Prop) -> Class”, the first “Class” corresponds to the first placeholder in the classifier constant, intended to be filled by a variable representing a member of the classifier. The “Prop” corresponds to the second placeholder, meant for a proposition (whether correct or not). The last “Class” indicates that the classifier is indeed a class, but we do not know if there are members in it. Taken together, “(Class -> Prop)” implies that the proposition in the second placeholder takes the variable from the first as a parameter. Thus, in the notation “\{ P \}”, the type of “P”, which represents a proposition with a parameter, is precisely “Class -> Prop”.
The constants “class”, “∈” and “ { · · : } ” form the basic structure of MK, through which all the axioms, definitions and theorems in MK can be described.
The definition of “set” is one of the most crucial definitions in MK, it constrains the concept of set to avoid Russell’s Paradox, excluding certain classes that are deemed “too large” (e.g., { u : u = u } , { u : u u } ) [4,36,37].
Definition 1 (Set).
x is a set if and only if for some y, x y .
  • Mathematics 13 02707 i009
MK inherits most elementary concepts and operations concerning sets (e.g., intersection, union, complement, pairs) from naive set theory and extends them to all classes. For example, x y in MK represents the intersection of classes x and y, either of which could be a set or not. Nevertheless, most objects discussed in this paper can be proven sets; if there are no specific instructions, we will directly use the term “set” rather than “class” to describe them.
The table presented in Appendix A lists partial definitions and mathematical meanings in MK along with their formalization in Coq, which will be frequently used in later sections. For more details about MK, refer to [4,36,37]; or access Coq-related source code of MK from https://github.com/1DGW/Formalization-of-Morse-Kelley-axiomatic-set-theory, accessed on 19 August 2025.

2.3. About Filters

The study of filters needs to be conducted within the context of set theories, so MK is an appropriate foundation to formalize the related concepts. The earliest concept related to filter is ultrafilter, which was apparently enunciated first by Frigyes Riesz in an address [38] in 1909 that unfortunately did not receive at the time the attention it deserved [39]. The concept of a filter, more concise and abstract, was introduced after the ultrafilter in [40,41] by Henri Paul Cartan in 1937 and subsequently adopted by Bourbaki in their book General Topology  [42].
The ultrafilter can be classified as principal ultrafilter and non-principal ultrafilter (also called free ultrafilter), and the former is relatively straightforward to construct and formalize.
Definition 2 (Principal Ultrafilter).
For every a A , the following set
{ u : u A a u } ,
denoted as F a , is an ultrafilter over A. Each F a , corresponding to the element a of A, is called a principal ultrafilter over A.
F a consists of all subsets of A that include the element a; it can be regarded as the sum of all properties of a in A. Formalizing this definition requires two steps: the first is to construct the set F a , and the second is to verify that F a is indeed an ultrafilter.
  • Mathematics 13 02707 i010
The formal definition of F a requires two parameters A and a. And the formal proposition “Fa_P2_b” declared by the command “Property” indicates that when A is a set (Ensemble A) and a belongs to A (a ∈ A), F a is an ultrafilter over A.
The construction of a non-principal ultrafilter is not as succinct or direct, and proving its existence usually requires a theorem called the Filter Extension Principle (FEP) [2,30], which is a conclusion derivable from the Axiom of Choice (AC) and named the Ultrafilter Theorem in [43].
Theorem 1 (Filter Extension Principle).
Let F be a filter over A, then there exists an ultrafilter G over A such that F G .
FEP asserts that every filter can be extended to an ultrafilter, with the use of which a non-principal ultrafilter can be extended from a specific filter called Fréchet Filter (denoted F σ ) [2,30]. The proof of FEP requires AC, so it is actually a non-constructive proof. In other words, a non-principal ultrafilter cannot be directly constructed but can only be formalized in the form of a proposition or theorem:
  • Mathematics 13 02707 i011
where “Ensemble A” and “∼ Finite A” represents that A is an infinite set and “∃ F0, free_ultraFilter F0 A” indicates the existence of a non-principal ultrafilter over A. The non-principal ultrafilter is also called the free ultrafilter, and “free_ultraFilter” is an invocation of its formalization.
In 1979, Daguenet-Teissier noticed a special ultrafilter in [44] with a specific property [1]. Subsequently, drawing from this research, Wang observed that non-principal ultrafilters with this property can be used to establish arithmetic models, including a real number model, with simple structures and superior properties [1]. Consequently, Wang refers to ultrafilters with this property as the “arithmetical ultrafilter (AUF)” and non-principal ones as the “non-principal arithmetical ultrafilter (NPAUF)” [3].
Definition 3 (Arithmetical Ultrafilter).
For every ultrafilter F over an infinite set A, F is an arithmetical ultrafilter if and only if:
f , g A A , f F = g F f = F g .
Here, f , g A A means f and g are functions whose domain is A and range is contained in A; f F = { u : u A f 1 u F } where f 1 u = { u : u d o m a i n f f ( u ) A } ; and f = F g means { u : u A f ( u ) = g ( u ) } F , where f and g are F-equivalent or f and g are almost equal about F. The formalization of AUF is as follows:
  • Mathematics 13 02707 i012
The formal definition consists of three assumptions: “∼ Finite A” indicates that A is an infinite set, “F ∈ ( β A)” indicates that F is an ultrafilter over A as “( β A)” represents the set consisting of all the ultrafilters over set A, and the last assumption rules that for each function f and g, f F = g F implies that f and g are F-equivalent, where f F is formally denoted as “f〈F∣A〉” because the parameter “A” cannot be omitted in code.
It is straightforward to prove that every principal ultrafilter is an AUF [2], but the existence of a non-principal AUF (NPAUF) is challenging to prove within the framework of general set theories. In one of Wang’s publications [30], he introduces various methods to prove the existence of NPAUF using different set theory hypotheses independent of ZFC. Among them, we chose the Continuum Hypothesis (CH) as the precondition to formally verify the existence of NPAUF, which ensures the safety and consistency of our formal system because CH is also consistent with MK [29,31,32].
Figure 1 presents the relationships among the filters involved in our formalization. As shown in the figure, an ultrafilter is also called a maximal filter; a non-principal ultrafilter is also called a free ultrafilter, so the principal ultrafilter is equivalent to the non-free ultrafilter. With the use of FEP, every filter can be extended to an ultrafilter and the Fréchet Filter to a non-principal ultrafilter. And every principal ultrafilter can be proven to be an AUF but the proof of the existence of NPAUF relies on CH.
Appendix B shows the fundamental definitions and mathematical meanings about filters along with their formalization in Coq. For details on filter theories, refer to [2,30,43]; for details about our formalization of filters, refer to [28,29] or review the Coq code.

3. Construction of * N , * Z and * Q

3.1. Construction of * N

The construction of * N depends on the existence of an NPAUF, so first a specific NPAUF must be chosen. Since NPAUF cannot be constructed directly, we use the command “Parameter” to introduce it.
  • Mathematics 13 02707 i013
The content stated in the above code has been formally verified in [29]. The first line defines a global variable F0 of type Class, which is equivalent to acknowledging an unproven class in mathematics, since in MK, all mathematical objects are classes. The second line further specifies that F 0 is an NPAUF over ω (the set of natural numbers in MK), where “Arithmetical_ultraFilter F0 ω ” indicates that F 0 is an AUF, and “∀ m, F0 <> (F ω m)” indicates that F 0 is not equal to any principal ultrafilters over ω , thus making F 0 an NPAUF.
The set * N is then constructed as follows:
* N = { u : f , f ω ω u = f F 0 } ,
where f ω ω indicates that f is a function whose domain is ω and range is contained in ω , and f F 0 = { u : u ω f 1 u F 0 } ( f 1 u = { u : u ( d o m a i n f ) f ( u ) ω } ). The Coq formalization is aligned with the mathematical description:
  • Mathematics 13 02707 i014
It can be proven that for every ultrafilter F and a function f, f F is still an ultrafilter, and f F is called a transformation of F under f [29,30]. Therefore, * N is the set consisting of all transformations from F 0 and each element of * N is at least an ultrafilter (of course, it could also be an AUF or an NPAUF).
* N is a non-standard extension of ω due to the existence of a proper subset of * N isomorphic to ω , and all elements outside this subset are infinity numbers. To present this isomorphism process, the order and operations on * N should be formalized first.
Definition 4 (Order on *N).
For each f , g ω ω , u , v * N and u = f F 0 , v = g F 0 , then the order of u and v is defined as follows:
u < v f F 0 < g F 0 { n : f ( n ) g ( n ) } F 0 .
The order on * N is a total order, meaning that for any u , v , w * N , it satisfies:
(1) Irreflexivity: u < u ,
(2) Transitivity: u < v v < w u < w ,
(3) Trichotomy: u < v v < u u = v .
  • Mathematics 13 02707 i015
In the code, “Connect” is the formalization of the MK concept that is equivalent to the concept of trichotomy [4,36].
Definition 5 (Addition on *N).
For each f , g ω ω , u , v * N and u = f F 0 , v = g F 0 , then the sum of u and v is defined as follows:
u + v = f F 0 + g F 0 = ( f + g ) F 0 ,
where f + g represents the addition of functions in ω ω , f + g = { ( u , v ) : u ω v = f ( u ) + g ( u ) } .
  • Mathematics 13 02707 i016
In the formalization, the addition of u and v is defined in the form of “∩({⋯})”. This is because mathematically, if the set constructed by the classifier { } is a singleton { a } , then { a } is exactly equal to the unique element a. Here, the unique element is the result of u + v .
The formalization of multiplication follows the same process as addition, simply by replacing the addition operation with multiplication. Furthermore, the order, addition and multiplication on * N satisfy the basic arithmetic properties (commutativity, associativity, distributivity, etc.) of the natural numbers, which has also been formalized.
The subset isomorphic to ω is defined as:
* N N = { u : u i s a p r i n c i p a l u l t r a f i l t e r o v e r ω } ,
so * N N consists of all the principal ultrafilters over ω .
  • Mathematics 13 02707 i017
Here “F ω n” represents the principal ultrafilter F n corresponding to n which is an element of ω .
Since every element of ω corresponds to a principal ultrafilter, the elements in ω are in one-to-one correspondence with the elements in * N N . The two sets are isomorphic.
Proposition 1 ( ω and * N N are isomorphic).
The function φ = { ( u , v ) : u ω v = F u } is a 1-1 function (bijective function) whose domain is ω and range is * N N , and for each m , n ω , φ preserves order and operations:
(1) 
φ ( 0 ) = F 0 φ ( 1 ) = F 1 .
(2) 
Order Preservation: m < n φ ( m ) < φ ( n ) .
(3) 
Addition Preservation: φ ( m + n ) = φ ( m ) + φ ( n ) .
(4) 
Multiplication Preservation: φ ( m · n ) = φ ( m ) · φ ( n ) .
where 0 and 1 are, respectively, defined by the empty setand the singleton { } in MK.
To formalize this proposition, the function φ should be described first:
  • Mathematics 13 02707 i018
Then, to verify the properties that φ satisfies:
  • Mathematics 13 02707 i019
In the code, “m ∈ n” indicates that m is less than n, because in MK the order on ω is exactly defined as the relation “∈”. And “(m + n)% ω ” means that m + n should be interpreted as the addition on ω , and ( φ [m] + φ [n])%n’ as the addition on * N .
Now * N N can be deemed as a set of natural numbers as well because of the isomorphism. Moreover, it can be verified that * N is a non-standard extension of * N N , namely a non-standard extension of natural number set.
  • Mathematics 13 02707 i020
From the first line, it can be observed that * N N is a proper subset of * N , and the second line shows that the elements outside * N N are all greater than those in * N N . The expression “t ∈ (N’ ∼ N’_N)” is the formalization of the mathematical expression t * N * N N , which means that t belongs to * N but not in * N N . The elements in * N * N N can be called “infinity natural numbers”, because they are greater than all the general natural numbers (they are infinitely large).
Therefore, * N is actually a non-standard natural number set and its structure can be intuitively depicted as:
0 < 1 < 2 < < n < * N N < τ < ( τ + 1 ) <
where τ represents an infinity natural number.

3.2. Extension from * N to * Z

The extension from * N to * Z adopts the idea of equivalence classification and the relevant definitions and theorems should be formalized.
Definition 6 (Equivalence Relation).
For each set a, let R be a subset of a × a ; R is called an equivalence relation over a if it satisfies:
(1) Reflexivity: x a , x R x .
(2) Symmetry: x , y a , if x R y then y R x .
(3) Transitivity: x , y , z a , if x R y and y R z then x R z , where a × a = { ( u , v ) : u a v a } (Cartesian Product) and x R y stands for ( x , y ) R , namely ( x , y ) satisfies R-relation.
  • Mathematics 13 02707 i021
A trivial example of equivalence relation is identity relation. Because for every a and its members x and y, it obviously satisfies x = x (reflexivity), if x = y then y = x (symmetry), and if x = y and y = z then x = z (transitivity). The identity relation over a can be set as { ( u , v ) : u a v a u = v } .
  • Mathematics 13 02707 i022
Definition 7 (Equivalence Class).
Let R be an equivalence relation over a; for each x in a, the set
{ u : u a u R x }
is called the equivalence class represented by x with respect to the R-relation, denoted [ x ] R .
To formalize this definition, three parameters are required: the first one serves as the representation x of this equivalence class, the second the equivalence relation R and the last the set a.
  • Mathematics 13 02707 i023
Definition 8 (Quotient Set).
Let R be an equivalence relation over a, the quotient set of a is:
a / R = { u : x , x a u = [ x ] R } .
  • Mathematics 13 02707 i024
A quotient set a / R consists of all equivalence classes with respect to R; it is the result of equivalently classifying the elements of a.
The construction of * Z actually equivalently classifies the elements of * N × * N , and a specific equivalence relation over * N × * N must be set first:
R * N = { ( ( m , n ) , ( p , q ) ) : m , n , p , q * N m + q = n + p } ,
where m + q and n + p indicate the addition on * N .
  • Mathematics 13 02707 i025
The expression “N’ × N’” represents * N × * N ( = { ( u , v ) : u * N v * N } ); it is the formalization of the Cartesian Product of * N . To simplify the formalization code, we introduce the notation “\[ \]” for the equivalence class with respect to R * N .
  • Mathematics 13 02707 i026
According to the equivalence relation, we can observe many equivalent elements in * N × * N . For example, ( 0 , 0 ) , ( 1 , 1 ) , ( 2 , 2 ) , ⋯, ( τ , τ ) , ⋯ are equivalent; ( 0 , 1 ) , ( 1 , 2 ) , ( 2 , 3 ) , "EF, ( τ , τ + 1 ) , ⋯ are equivalent; and so are ( 2 , 0 ) , ( 3 , 1 ) , ( 4 , 2 ) , ⋯, ( τ + 2 , τ ) , ⋯, where τ represents an infinity natural number. In a planar dot array composed of elements in * N × * N , we can connect equivalent points with straight lines and thus obtain Figure 2.
In Figure 2, every oblique line represents an equivalence class of * N × * N , and intuitively the order of these oblique lines on the horizontal axis forms a new number “sequence” (this “sequence” is extended to infinity numbers) and the lines extended by dashed lines extend this “sequence” to a range of negative numbers. Then, the set consisting of all these oblique lines, namely the quotient set of * N × * N with respect to R * N , is exactly * Z .
* Z = ( * N × * N ) / R * N = { u : x , x * N × * N u = [ x ] R * N } .
  • Mathematics 13 02707 i027
The suffix “%eqr” indicates that the notation “/” should be interpreted as the quotient set operation.
In the similar ways following * N , the order, addition and multiplication on * Z can be formalized:
  • Mathematics 13 02707 i028
The order and operation properties of * N are also shared by * Z . In addition, * Z has an extra property: for every element u * Z , there exists a unique element v such that u + v = 0 ; namely, every element of * Z has a corresponding negative element.
  • Mathematics 13 02707 i029
The symbol “∃!” above represents the unique existence of v, namely for each v that satisfies u + v = 0 , v must be equal to v. And “Z’0” is the formalization of 0 (the zero element) in * Z ; it is equal to the equivalence class [ ( F 0 , F 0 ) ] R * N where F 0 is the principal ultrafilter corresponding to 0 ( ω ).
  • Mathematics 13 02707 i030
* Z has an important proper subset:
* Z Z = { u : m , n * N N u = [ ( m , n ) ] R * N }
  • Mathematics 13 02707 i031
* Z Z consists of the equivalence classes whose elements are all from * N N × * N N , and * N N is the finite section of * N . This implies that * Z Z is also the finite section of * Z , making * Z Z suitable to serve as a set of general integers. And every member of * Z * Z Z is greater (for the positive ones) or smaller (for the negative ones) than all the elements in * Z Z .
  • Mathematics 13 02707 i032
Therefore, the elements in * Z * Z Z are either positive infinity or negative infinity; they can be called the “infinity integers”. * Z is a non-standard extension of the integer set.
In addition, just as ω is isomorphic to * N N , * N is isomorphic to the following subset of * Z :
* Z * N = { u : m , m * N u = [ ( m , F 0 ) ] R * N } ,
namely, there exists a 1-1 function between * N and * Z * N that preserves order and operations. * Z * N consists of the non-negative elements of * Z .
  • Mathematics 13 02707 i033
Now the structure of * Z can be intuitively depicted as: Mathematics 13 02707 i067 where τ represents an infinity integer.

3.3. Extension from * Z to * Q

Similar to the process from * N to * Z , * Q is also obtained by equivalence classification, and the equivalence relation is defined on * Z × ( * Z { * Z 0 } ) :
R * Z = { ( ( a , b ) , ( c , d ) ) : a , c * Z b , d ( * Z { * Z 0 } ) a · d = b · c } ,
where *Z0 is the 0 element in * Z , formalized as “Z’0”.
  • Mathematics 13 02707 i034
The definition “Z’_De” in the code gives * Z × ( * Z { * Z 0 } ) a shorter symbol, making the formal description more convenient. The notation of the equivalence class with respect to R * Z is the same as that with respect to R * N , but distinguished by scope.
  • Mathematics 13 02707 i035
According to the definition of R * Z , for two equivalence classes [ ( a , b ) ] R * Z and [ ( c , d ) ] R * Z , [ ( a , b ) ] R * Z = [ ( c , d ) ] R * Z means a · d = b · c , which aligns with the general understanding of a / b = c / d . Thus, each equivalence class [ ( a , b ) ] R * Z can be interpreted as the fraction a / b , and R * Z essentially generates fractions.
Figure 3 presents the classification process of R * Z .
In the planar dot array composed of elements in * Z × ( * Z { * Z 0 } ) , every line connecting equivalent points represents an equivalence class of * Z × ( * Z { * Z 0 } ) , and certainly the lines are dense, which means that there always exists such a line between any two and the inverse elements such as 1 / 2 are contained. The set consisting of all these lines, namely the quotient set of * Z × ( * Z { * Z 0 } ) with respect to R * Z , is exactly * Q .
* Q = ( * Z × ( * Z { * Z 0 } ) ) / R * Z = { u : x , u = [ x ] R * Z } .
  • Mathematics 13 02707 i036
It is possible to define the order and operations on * Q in the same way as the usual definitions for fractions, and it can be verified that the elements in * Q satisfy all the arithmetic properties of the rational numbers.
But different from the general rational numbers, * Q introduces not only the infinity numbers but also the infinitesimal numbers. To clarify this point, the elements of * Q can be divided into two categories.
Elements of one category, called finitely large elements of * Q , constitute a crucial subset of * Q :
Q < = { u : u * Q k * Q N , | u | = k | u | < k } .
Q < is called the Archimedes Subset of * Q because every element u satisfies the Archimedean Property:
k * Q N , | u | = k | u | < k ,
where * Q N is the subset isomorphic to ω and * N N , representing the natural number set; and | u | denotes the absolute value of u.
It can be observed that the absolute value of every element in Q < is always smaller than a certain natural number, which means that all elements in Q < are measurable or finitely large. Thus, the elements of the other category belong to * Q Q < ; they are greater than all natural numbers (infinitely large), called infinity numbers.
To implement the formalization of Q < , the formalization of * Q N and the concept of absolute value are required. The latter can be straightforwardly formalized as a function:
  • Mathematics 13 02707 i037
The formal definition “Q’_Abs” defines a function that takes an element u in * Q and outputs three different value dependent on the order relation of u and 0 (formalized by “Q’0”), which aligns with the usual understanding of the absolute value. The notation “| u |” then represents the expression “(Q’_Abs)[u]”, the value of u under the function.
The formalization of * Q N is a little more complicated, for there are no instructions provided for the specific construction of * Q N in [2]. Inspired by the isomorphism introduced in previous sections, one feasible method is to construct a subset isomorphic to ω , and the isomorphism function is formally described as:
  • Mathematics 13 02707 i038
Here, “ φ ” is the formalization of the isomorphism function φ between ω and * N N ; namely, the domain of φ is ω , the range is * N N and φ preserves the order and operations on ω and * N N . “ φ 1” represents the isomorphism function between * N and * Z * N , and “ φ 2” represents that between * Z and * Q * Z (the subset of * Q isomorphic to * Z ). Therefore, the composition of the three functions, denoted as φ 4 , can be verified to be an isomorphism function whose domain is ω and the range is contained in * Q .
  • Mathematics 13 02707 i039
Then, * Q N is formally defined as the range of φ 4 , after which the set Q < can also be formalized.
  • Mathematics 13 02707 i040
Another important subset of * Q is the set of infinitesimal numbers, denoted as I . Intuitively, an infinitesimal number is an inverse element of an infinity number (i.e., 1 / τ where τ * Q N < ). For each non-zero natural number k, an infinitesimal number should be smaller than 1 / k .
I = { u : u * Q ( k ( * Q N { * Q 0 } ) , | u | < ( * Q 1 / k ) ) } ,
where * Q0 and * Q1, respectively, are the zero element 0 and identity element 1 in * Q , formalized as “Q’0” and “Q’1”.
  • Mathematics 13 02707 i041
Obviously, the zero element 0 is an infinitesimal number, but there are non-zero elements in I , meaning that the singleton { 0 } can be proven a proper subset of I . And I should be a subset of Q < because infinitesimal numbers are also finitely large.
  • Mathematics 13 02707 i042
Besides the sets introduced above, * Q also has some other important subsets: * Q * N that is isomorphic to * N , * Q * Z that is isomorphic to * Z , * Q Z that is isomorphic to * Z Z and can serve as a set of integers, and * Q Q that can serve as a set of rational numbers. And undoubtedly * Q N , * Q Z and * Q Q are all subsets of Q < because their elements are finitely large and measurable. Here, we directly present their formalization.
  • Mathematics 13 02707 i043
The formal expression “Z’0” and “Z’1”, respectively, represent the zero element 0 and the identity element 1 in * Z , and “Q’0” represents 0 in * Q .
Therefore, * Q actually has a structure much more complicated than usual the rational number set and even than the real number set. Including both infinity and infinitesimal numbers, * Q is a non-standard extension of the rational number set. Figure 4 shows the structures involved from ω to * Q .

4. Real Number Set R

4.1. From Q < to R

Now it is sufficient to perform equivalence classification on Q < to obtain the real number set R , and the equivalence relation is defined as:
R * Q = { ( u , v ) : u Q < v Q < u v I } .
  • Mathematics 13 02707 i044
The formal proposition “R_Q’_is_equRelation” verifies that R * Q is an equivalence relation on Q < , and the equivalence class with respect to R * Q is also denoted by the notation “\[ u \]”.
Then, the real number set R is defined as the quotient set of Q < :
  • Mathematics 13 02707 i045
It is obvious that R is obtained by equivalence classification of a single set, whereas * Z and * Q are obtained by classifying the Cartesian Product of two sets. This means that the elements in R are all equivalence classes, each of which can be represented by a single element from Q < . That is to say, each u R can be denoted as [ a ] R * Q where a is the representation of u and an element in Q < . Thus, the order and operations on R can be directly defined according to those on * Q ( Q < is a subset of * Q ).
  • Mathematics 13 02707 i046
In addition, since the natural number set * Q N is contained in Q < , the natural number set N contained in R can be defined as the set consisting of equivalence classes represented by members from * Q N . And the same idea applies to the integer set Z and the rational number set Q .
  • Mathematics 13 02707 i047
Clearly, * Q N is isomorphic to N , and consequently ω is also isomorphic to N (since ω is isomorphic to * Q N ). Moreover, * Q Z is isomorphic to Z , and * Q Q is isomorphic to Q .
Figure 5 shows the structures from Q < to R .

4.2. What Are Real Numbers?

Although the set R has been constructed, it needs to be clarified how to ensure that R is indeed the set of real numbers required in mathematical analysis.
Firstly, concerning the order and operations, the elements in R satisfies the following properties:
(I)
Properties of Addition
(1)
u + 0 = u .
(2)
existence of negative element: ! u 0 , u + u 0 = 0 .
(3)
associative law: ( u + v ) + w = u + ( v + w ) .
(4)
commutative law: u + v = v + u .
  • Mathematics 13 02707 i048
(II)
Properties of Multiplication
(1)
u · 1 = u .
(2)
existence of inverse element: ! u 1 , u · u 1 = 1 .
(3)
associative law: ( u · v ) · w = u · ( v · w ) .
(4)
commutative law: u · v = v · u .
  • Mathematics 13 02707 i049
(I,II)
Connection between Addition and Multiplication
(1)
distributive law: u · ( v + w ) = ( u · v ) + ( u · w ) .
  • Mathematics 13 02707 i050
(III)
Properties of Order
(1)
0 < 1 .
(2)
reflexivity: u u .
(3)
transitivity: u < v v < w u < w .
(4)
trichotomy: u < v v < u u = v .
  • Mathematics 13 02707 i051
(I,III)
Connection between Addition and Order: u < v ( u + w ) < ( v + w ) .
  • Mathematics 13 02707 i052
(II,III)
Connection between Multiplication and Order: u < v ( u · w ) < ( v · w ) , where 0 < w .
  • Mathematics 13 02707 i053
In the above code, “R0” and “R1”, respectively, represent the zero and identity element in the set R .
These are all the elementary properties of real numbers familiar to us all, and a structure satisfying the above properties is called an ordered field in mathematics.
However, merely satisfying the properties of ordered fields is not sufficient to constitute the set of real numbers. In the process of FMCR, several sets can be verified ordered fields, such as * Q , * Q Q , Q , R . But only R can serve as the real number set because R possesses both of two additional properties:
  • Archimedean Property: r R , k N , | r | k .
  • Completeness (there are numerous equivalent statements of the Archimedean property and completeness [45,46], and the formulations here are quoted from [2]): A monotonically increasing and bounded sequence must possess a supremum (least upper bound).
A structure satisfying the ordered field properties, the Archimedean property and completeness constitutes a complete ordered field, and can serve as a real number set [46]. What mathematical analysis needs is exactly the complete ordered field.

4.3. Formally Proving the Archimedean Property and Completeness

Obtained from the equivalence classification of Q < which is exactly defined by the Archimedean property, R logically satisfies the Archimedean property.
  • Mathematics 13 02707 i054
The expression “|r|” here indicates the absolute value of the real number r; it is formalized as the value of a function.
  • Mathematics 13 02707 i055
The key to proving the Archimedean property lies in addressing the case where 0 < r , since for r < 0 , one only needs to consider r (which is greater than 0). As for the case where r = 0 , the theorem can be easily verified: | 0 | 0 .
Therefore, we use the tactic “assert” to introduce the following assertion to the proof environment as a hypothesis.
  • Mathematics 13 02707 i056
The statements asserted by this tactic need to be proven. The proof code is typically enclosed in curly braces “{” and “}”, after which the asserted content can be utilized as a hypothesis within the proof environment.
We briefly introduce the manual proof of this assertion:
Proof. 
For 0 < r , let r = [ q ] R * Q where q Q < ; thus, there exists an n * Q N such that | q | n . By the definition of the order on R , 0 < q holds, which implies | q | = q and q n . Consequently, we have [ n ] R * Q N and | r | = r = [ q ] R * Q [ n ] R * Q .    □
Now we can present a relatively complete machine proof of the Archimedean property.
  • Mathematics 13 02707 i057
For brevity, the machine proof details of the assertion at { … } are omitted here, with corresponding manual proof presented above. The verification approach for the remaining code is as follows:
4 Introduce r R and 0 R as hypotheses into the proof environment.
5 Split the proof into three cases by trichotomy: 0 < r , r < 0 and r = 0 . The case 0 < r is already covered by the previous assertion in line 3.
6–8 (case r < 0 ) Let r = r 0 ; then, 0 < r 0 and | r | = | r 0 | . We can rewrite | r | as | r 0 | in the proof goal, making it align with the assertion in line 3.
9 (case r = 0 ) Directly specify the constant 0 (R0 in code), which satisfies 0 R and | 0 | 0 .
The Archimedean property means the measurability of numbers, and * Q does not satisfy this property because of the infinity numbers. Thus, * Q cannot serve as the real number set.
As for the completeness, the concept of sequence needs to be described first. A sequence of R is exactly a function whose domain is the natural number set N and range is contained in R . Up to now, we have seen several sets that can serve as the natural number set: ω , * N N , * Q N and N . Considering its concise set structure, we choose ω as the foundation of a formal definition of sequence.
  • Mathematics 13 02707 i058
In addition, the concepts of monotonicity and supremum also need to be formalized precisely. The monotonicity illustrates that if m < n then the value of a sequence f should satisfy f ( m ) f ( n ) .
  • Mathematics 13 02707 i059
In MK, the order relation on ω is exactly the “∈” relation, so the expression “m ∈ n” exactly means that m is smaller than n. Supremum also can be called the least upper bound; it can be formalized with the use of two formal definitions.
  • Mathematics 13 02707 i060
The first definition states that r is an upper bound of f if r is equal to or greater than all values of f. And the second definition illustrates that if r is the supremum of f, r should be an upper bound of f and each number smaller than r cannot be an upper bound of f, which makes r the smallest among all the upper bounds of f.
Then, the completeness can be formally proven:
  • Mathematics 13 02707 i061
The overall approach of the machine verification is as follows (here, we also omit the proofs of assertions made by the tactic “assert”, and some details of proven conclusions such as “R_Seq_Property2”, “R_RatSeq”, etc., are not elaborated):
4–5 Introduce the premises to the proof context as hypotheses and restructure them.
6 “R_Seq_Property2” is a previously established result stating that any monotonically increasing sequence f can be divided into two cases:
(i)
f becomes constant after some term, or
(ii)
there exists a strictly increasing subsequence of f.
Here, we apply this result to split the proof into two parts: lines 7–16 for case (i), and lines 17–45 for case (ii).
7–16 (case i) Let the constant value in case (i) be r 1 , and the term be x. Thus, for each m > x , we have f ( m ) = r 1 . Obviously, r 1 is the least upper bound of sequence f, where lines 9–13 prove that r 1 is an upper bound of f and lines 14–16 prove that r 1 is the smallest one among all the upper bounds of f.
17–45 (case ii) Let the strictly increasing subsequence of f be h; then, we can construct a rational sequence k such that
n ω , k ( n ) Q h ( n ) < k ( n ) < h ( n ) ,
where n is the successor of n. Then, it can be proven that k has a least upper bound, denoted a (the assertion in line 35). Furthermore, a can be proven the least upper bound of h (the assertion in line 36) and f (proofs in lines 38–45).
It should be noted that in the proof of case (ii), the construction of the rational sequence k is particularly crucial as it necessitates the use of the Axiom of Choice (AC), which is often overlooked in manual proofs.
In line 24, we firstly use the tactic “set” (which is used to introduce local definitions during proof construction) to define a set
A n = { u : u Q h ( n ) < u < h ( n ) } ,
denoted “A n” in code. For each n ω , A n consists of all the (infinitely many) rational numbers between h ( n ) and h ( n ) , but we only need to choose a single element of A n .
Then, in line 25, we invoke AC (AxiomIX in code), which introduces a choice function c into the proof environment such that for each set x, c ( x ) x holds. In other words, the choice function c can select a specific element for every set. Consequently, for every n ω , c ( A n ) A n holds, according to which we can define the rational number sequence
k = { ( u , v ) : u ω v = c ( A u ) } ,
as formally defined in line 27.
Lines 28–33 verify that k is a strictly increasing rational sequence, and for each n ω , k ( n ) = c ( A n ) and h ( n ) < k ( n ) < h ( n ) hold.
Among the various sets ( * N , * Z , * Q , Q < , R , etc.) constructed previously, only R possesses completeness, making it capable of serving as the real number set.
At last, as one of the classical examples, the real number 2 can be verified to be an irrational number.
  • Mathematics 13 02707 i062

5. Conclusions and Outlook

5.1. Non-Standard Extension of Number Systems

The process of FMCR is accomplished in several steps: extending the natural number set ω to the non-standard natural number set * N through an NPAUF; extending * N to the non-standard integer set * Z and the non-standard rational number set * Q through the idea of equivalence classification; then, classifying the Archimedean subset Q < to obtain the real number set R . Therefore, this is a method of obtaining the real numbers by performing non-standard extensions of the number systems, and the most crucial step is the extension from ω to * N , which directly introduces the infinity numbers. Additionally, to prove the existence of NPAUF, the Continuum Hypothesis (CH) is utilized.
Inspired by the process from ω to * N , we believe that this process can be applied to the existing real number set R , thereby obtaining the set of non-standard real numbers * R , also known as the hyper-real numbers [33,35]. Specifically, in the formalization of * N :
  • Mathematics 13 02707 i063
If the expression “ran(f) ⊂ ω ” is replaced with “ran(f) ⊂ R ”, then this set should become the hyper-real number set. Note that, as presented in Section 3.1, “F0” would still be the specific NPAUF introduced by the command “Parameter”.
Thus, we have:
* R = { u : f , f R ω u = f F 0 } ,
where f R ω indicates that f is a function whose domain is ω and range is contained in R , and f F 0 = { u : u R f 1 u F 0 } ( f 1 u = { u : u ( d o m a i n f ) f ( u ) R } ).
  • Mathematics 13 02707 i064
The order and operations on * R can be defined by analogy with those on * N . For hyper-real numbers u , v * R , if u = f F 0 and v = g F 0 , we can define:
u < v f F 0 < g F 0 { n : f ( n ) < g ( n ) } , u + v = f F 0 + g F 0 = ( f + g ) F 0 , u · v = f F 0 · g F 0 = ( f · g ) F 0 ,
Similar to the construction of * N N , we can construct the standard part of * R :
* R R = { u : r , r R u = F r } ,
where F r represents the principal ultrafilter corresponding to the real number r. Consisting of all the principal ultrafilters over R , * R R is the standard real number set contained in * R ; it can be formally described as:
  • Mathematics 13 02707 i065
where “F R r” (see Definition 2 in Section 2.3) is the formalization of the principal ultrafilter F r over R .
Given that every real number r uniquely corresponds to a principal ultrafilter F r , the real number set R is isomorphic to * R R , and the latter is also a concrete model of the real number set. This aligns with the isomorphism between ω and * N N , both of which are models of the natural number set, as introduced in Section 3.1.
In * R * R R , there exist positive numbers smaller than every positive real number—these are precisely the infinitesimals.
For example, let y = { ( u , v ) : u ω v = 1 / u + 1 ¯ } , where u + 1 ¯ ( N ) is the image of u + 1 under the isomorphism between ω and N . Thus, we have y R ω and y F 0 * R . And for each n ω , y ( n ) = 1 / n + 1 ¯ R holds. Here, we introduce a manual proof demonstrating that y F 0 is an infinitesimal:
Proof. 
Firstly, we have F 0 < y F 0 { n : 0 < y ( n ) } F 0 { n : 0 < 1 / n + 1 ¯ } F 0 ω F 0 , where F 0 is the zero element (i.e., the principal ultrafilter corresponding to 0) in * R and F 0 is the NPAUF introduced above.
Then, for each positive r R , y F 0 < F r { n : 1 / n + 1 ¯ < r } F 0 . Since 1 / n + 1 ¯ is in fact a decreasing sequence, there exists N ω such that m > N , 1 / m + 1 ¯ < r holds, namely { n : 1 / n + 1 ¯ < r } = { n : n > N } . Because F 0 is a non-principal ultrafilter, { n : n N } { n : n > N } = ω F 0 holds. Then, according to the properties of non-principal ultrafilters (see Definitions 3 and 5 in [29]), we have { n : n > N } F 0 , namely { n : 1 / n + 1 ¯ < r } F 0 and y F 0 < F r , which implies that y F 0 is a positive infinitesimal (smaller than all positive real numbers but greater than zero).    □
In the above proof, the equivalences F 0 < y F 0 { n : 0 < y ( n ) } F 0 and y F 0 < F r { n : 1 / n + 1 ¯ < r } F 0 must be derived from the definition of the arithmetical ultrafilter. And according to this proof, we can verify the following formal theorem in Coq to demonstrate the existence of infinitesimals in * R .
  • Mathematics 13 02707 i066
where “F R R0” represents the principal ultrafilter F 0 (i.e., the zero element in * R ).
As briefly discussed above, NPAUF enables the construction of a hyper-real number model where each element (hyper-real number) is represented by an arithmetical ultrafilter. This achieves methodological consistency with the filter-method construction of real numbers presented in this paper.
To advance further, we plan to implement the formalization of hyper-real numbers and even non-standard analysis using NPAUF. This could be a meaningful attempt and piece of research. On the one hand, from the mathematical perspective, hyper-real numbers are the foundation of non-standard analysis, which unfortunately is still not widely understood. Machine proof may become a new pathway for people to learn about this theory. On the other hand, the application of NPAUF unifies the construction of the real and hyper-real numbers, which is also of positive significance for mathematical research.

5.2. Notes on the Implementation

This work is grounded in the Coq formalization of the Morse–Kelley axiomatic set theory (MK) [4,36,37], and paves the way for the formal verification of non-standard analysis. The contribution is the Coq verification for proofs of the filter-method construction of real numbers (FMCR) introduced in [1,2].
The formalization of FMCR comprises 9 (.v)files and approximately 13,000 lines of Coq code (excluding MK and filter formalization). It is self-contained and does not rely on any official libraries of Coq. All code has been successfully executed in the Coq IDE (integrated development environment). Figure 6 shows the dependency of our Coq development, where each ellipse represents a (.v)file.
The MK part (red ellipses) and filter part (blue ellipses) are our previous works [28,29,36,37] that this paper is based on, and the part of green ellipses for FMCR is our development presented in this paper. The gray ellipses represent some required auxiliary formalization, the contents of which are not meticulously reflected in the manual proofs but necessary for the machine verification. In particular, in the file existence_of_NPAUF.v, the existence of non-principal arithmetical ultrafilters is formally verified with the use of the Continuum Hypothesis [29]. This guarantees that FMCR itself is logically sound and consistent with MK. Readers can verify the details in our Coq code.
The mechanized proof of mathematical theorems undoubtedly can strengthen the rigor of theories. To verify the correctness of a theory, people do not need to understand the tedious and complicated proofs, but only to check if the formal descriptions of relevant definitions and theorems are right. And if the code is executed successfully, the proof is correct. In addition, the formalization can also help people study and comprehend the theories, since every detail of the proofs must be verified in a computer. As the famous saying in the programming community goes: “Talk is cheap, show me the code!” It should be believed that computer-assisted verification may become a new trend in mathematical research [6,15,26,47,48].

Author Contributions

Conceptualization, G.D. and W.Y.; methodology, G.D.; software, G.D.; validation, G.D. and W.Y.; formal analysis, G.D.; investigation, G.D.; resources, G.D.; data curation, G.D.; writing—original draft preparation, G.D.; writing—review and editing, G.D.; visualization, G.D.; supervision, W.Y.; project administration, G.D. and W.Y.; funding acquisition, W.Y. All authors have read and agreed to the published version of the manuscript.

Funding

This research was supported by the National Natural Science Foundation of China (Grant Nos. 62476028 and 61936008).

Data Availability Statement

The entire Coq formalization code of FMCR in this research is available at https://github.com/1DGW/formal-verification-of-the-filter-method-construction-for-real-numbers, accessed on 19 August 2025.

Conflicts of Interest

The authors declare no conflicts of interest. The funders had no role in the design of the study; in the collection, analyses, or interpretation of data; in the writing of the manuscript; or in the decision to publish the results.

Abbreviations

    The following abbreviations are used in this manuscript:
ACAxiom of Choice
AUFarithmetical ultrafilter
CHContinuum Hypothesis
FEPFilter Extension Principle
FMCRthe filter-method construction for reals
IDEintegrated development environment
MKMorse–Kelley axiomatic set theory
NPAUFnon-principal arithmetical ultrafilter
ZFCZermelo–Fraenkel axiomatic set theory with AC

Appendix A. Partial Definitions and Notations of MK

Mathematical MeaningMathematical Symbol
Definition in Coq 1Notation in Coq
union of x and y x y
Union x y := \{  λ  z, z ∈ x \/ z ∈ y \}x ∪ y
intersection of x and y x y
Intersection x y := \{  λ  z, z ∈ x /\ z ∈ y \}x ∩ y
complement of x ¬ x
Complement x := \{  λ  y, y ∉ x \}¬x
difference of x and y; complement of y relative to x x y
Setminus x y := x ∩ (¬ y)x ∼ y
void class; empty set; 0
Φ := \{  λ  x, x <> x \} Φ
universe, the class including all sets U
μ := \{  λ  x, x = x \} μ
class of the intersection of the members of x x
Element_I x := \{  λ  z, ∀ y, y ∈ x -> z ∈ y \}x
class of the union of the members of x x
Element_U x := \{  λ  z, ∃ y, z ∈ y /\ y ∈ x \}x
x is a subclass of y; x is contained in y x y ; x y
Included x y := ∀ z, z ∈ x -> z ∈ yx ⊂ y
power class of x 2 x
PowerClass x := \{  λ  y, y ⊂ x \}pow(x)
singleton class of x { x }
Singleton x := \{  λ  z, x ∈ μ -> z = x \}[x]
unordered pair of x and y { x y }
Unordered x y := [x] ∪ [y][x|y]
ordered pair of x and y ( x , y )
Ordered x y := [[x]|[x|y]][x,y]
the first coordinate of z1stcoord z
First z := z
the second coordinate of z2stcoord z
Second z := ( z)∪( z) ∼ ( z)
r is a relation iff its members are ordered pairs
Relation r :=  ∀ z, z ∈ r -> ∃ x y, z = [x,y]
composition of r and s r s
Composition r s := \{\ λ x z, ∃ y, [x,y] ∈ s /\ [y,z] ∈ r \}\ 2r ∘ s
relation inverse to r r 1
Inverse r := \{\  λ  x y, [y,x] ∈ r \}\ r 1
f is a function
Function f := Relation f /\ (∀ x y z, [x,y] ∈ f -> [x,z] ∈ f -> y = z)
domain of the class fdomain f
Domain f := \{  λ  x, ∃ y, [x,y] ∈ f \}dom(f)
range of the class frange f
Range f := \{  λ  y, ∃ x, [x,y] ∈ f \}ran(f)
value of f at x or image of x under f f ( x )
Value f x := ∩(\{  λ  y, [x,y] ∈ f \})f[x]
f is a 1-1 function (bijective function)
Function1_1 f := Function f /\ Function ( f 1 )
class consisting of functions whose domain is x and range is contained in y y x
Exponent y x := \{  λ  f, Function f /\ dom(f) = x /\ ran(f) ⊂ y \}
cartesian product of x and y x × y
Cartesian x y := \{\  λ  u v, u ∈ x /\ v ∈ y \}\x × y
restriction of f to x f | x
Restriction f x := f ∩ (x × μ )f|(x)
x is r-related to y or x r-precedes y x r y
Rrelation x r y := [x,y] ∈ r
r connects x (trichotomy)
Connect r x := ∀ u v, u ∈ x -> v ∈ x
  -> (Rrelation u r v) \/ (Rrelation v r u) \/ (u = v)
x is full (each member of a member of x is a member of x)
Full x := ∀ m, m ∈ x -> m ⊂ x
E is the ∈-relationE
E := \{\  λ  x y, x ∈ y \}\E
x is an ordinal
Ordinal x := Connect E x /\ Full x
class consisting of all ordinal numbers 3R
R := \{  λ  x, Ordinal x \}R
x is an ordinal number if and only if x R
Ordinal_Number x := x ∈ R
successor of x x ; x + 1
PlusOne x := x ∪ [x]
there exists a 1-1 function between x and y; x y
x is equivalent (equipotent) to y; x and y are equipollent
Equivalent x y :=  ∃ f, Function1_1 f /\ dom(f) = x /\ ran(f) = yx ≈ y
x is a cardinal number
Cardinal_Number x := Ordinal_Number x /\ (∀ y, y ∈ R -> y ∈ x -> ∼ (x ≈ y))
class consisting of all cardinal numbersC
C := \{  λ  x, Cardinal_Number x \}C
cardinality function that maps a set to its cardinalityP
P := \{\  λ  x y, x ≈ y /\ y ∈ C \}\P
set of non-negative integers (i.e., set of natural numbers) ω
ω  := \{  λ  x, Integer x \} ω
x is finite
Finite x := P[x]  ω
1 All definitions are defined with the command “Definition”. 2 The notation “ \{\ ⋯ \}\ ” is denoted for the classifiers whose members are ordered pairs: Notation "\{\ P \}\" := (\{ λ z, ∃ x y, z = [x,y] /\ P x y \})(at level 0), where the type of P is “Class -> Class -> Prop”. 3 R is an ordinal but not an ordinal number.

Appendix B. Partial Definitions and Notations About Filters

Mathematical MeaningMathematical Symbol
Definition in CoqNotation in Coq
B is a filter base over A
FilterBase B A := B <> Φ /\ B ⊂ pow(A) /\ Φ ∉ B
/\ (∀ a b, a ∈ B -> b ∈ B -> (a ∩ b) ∈ B)
F is a filter over A
Filter F A := F ⊂ pow(A) /\ Φ ∉ F /\ A ∈ F
/\ (∀ a b, a ∈ F -> b ∈ F -> (a ∩ b) ∈ F)
/\ (∀ a b, a ⊂ b -> b ⊂ A -> a ∈ F -> b ∈ F)
F is an ultrafilter over A
ultraFilter F A := Filter F A
/\ (∀ a, a ⊂ A -> a ∈ F \/ (A ∼ a) ∈ F)
F is a maximal ultrafilter over A
maxFilter F A := Filter F A
/\ (∀ G, Filter G A -> F ⊂ G -> G = F)
the principal ultrafilter corresponding to the element a of A F a
F A a := \{ λ u, u ⊂ A /\ a ∈ u \}denoted as “F A a” or “F a” when A is replaced by ω
F is a free ultrafilter (non-principal ultrafilter) over A
free_ultraFilter F A := ultraFilter F A
/\ (∀ a, a ⊂ A -> Finite a -> a ∉ F)
Fréchet Filter over A F σ
Definition F σ A := \{ λ a, a ⊂ A /\ Finite (A ∼ a) \}
{ u : i s a n u l t r a f i l t e r o v e r A } β
(ultrafilter space on A, the set consisting of all ultrafilters over A) denoted as “ β ω ” when A is replaced by ω
β A := \{ λ u, ultraFilter u A \}
{ u : x , u = f ( x ) x A } (the image set of f at A) f A
ImageSet f A := \{ λ u, ∃ m, u = f[m] /\ m ∈ A \}f⌈A⌋
{ u : u d o m a i n f f ( u ) A } (the preimage set of f at A) f 1 A
PreimageSet f A := \{ λ u, u ∈ dom(f) /\ f[u] ∈ A \} f 1 ⌈A⌋
{ u : u B f 1 u F } f F
(transformation of ultrafilter F under function f)f〈F|B〉 ; denoted as “f〈F〉” when B is replaced by ω
Transform F f B := \{ λ u, u ⊂ B /\ f 1 ⌈u⌋ ∈ F \}
{ u : u A f ( u ) = g ( u ) } F , functions f and g are F-equivalent f = F g
AlmostEqual f g A B F := Function f /\ Function g
/\ dom(f) = A /\ dom(g) = A  /\ ran(f) ⊂ B /\ ran(g) ⊂ B
/\ F ∈ ( ω A) /\ \{ λ u, u ∈ A /\ f[u] = g[u] \} ∈ F
F is an arithmetical ultrafilter over A f , g A A , f F = g F f = F g
Arithmetical_ultraFilter F A := ∼ Finite A /\ F ∈ ( ω A)
/\ (∀ f g, Function f -> Function g
  -> dom(f) = A -> dom(g) = A -> ran(f) ⊂ A -> ran(g) ⊂ A
  -> f〈F∣A〉 = g〈F∣A〉 -> AlmostEqual f g A A F)

References

  1. Wang, F. On a special kind of points in stone-cˇech compactification βω. J. China Univ. Sci. Technol. 1998, 28, 567–570. [Google Scholar]
  2. Wang, F. Mathematical Foundations, 2nd ed.; Higher Education Press: Beijing, China, 2018. (In Chinese) [Google Scholar]
  3. Wang, F. A result on arithmetical ultrafilters. J. China Univ. Sci. Technol. 2000, 30, 517–522. [Google Scholar]
  4. Kelley, J.L. General Topology; Springer: New York, NY, USA, 1955. [Google Scholar]
  5. Jiang, N.; Li, Q.; Wang, L.; Zhang, X.; He, Y. Overview on mechanized theorem proving. J. Softw. 2020, 31, 82–112. (In Chinese) [Google Scholar] [CrossRef]
  6. Avigad, J. The machenization of mathematics. Not. Am. Math. Soc. 2018, 65, 681–690. [Google Scholar]
  7. Harrison, J.; Urban, J.; Wiedijk, F. History of interactive theorem proving. In Handbook of the History of Logic; North-Holland: Amsterdam, The Netherlands, 2014; Volume 9, pp. 135–214. [Google Scholar] [CrossRef]
  8. Wang, H. Toward mechanical mathematics. IBM J. Res. Dev. 1960, 4, 2–22. [Google Scholar] [CrossRef]
  9. Bertot, Y.; Castéran, P. Interactive Theorem Proving and Program Development–Coq’Art: The Calculus of Interactive Constructions; Springer: Berlin/Heidelberg, Germany, 2004. [Google Scholar]
  10. The Reference Manual of the Rocq Prover, v: 9.0.0. Available online: https://rocq-prover.org/doc/V9.0.0/refman (accessed on 15 June 2025).
  11. Nipow, T.; Paulson, L.C.; Wenzel, M. Isabelle/HOL: A Proof Assistant for Higher-Order Logic; Lecture Notes in Computer Science (LNCS); Springer: Berlin/Heidelberg, Germany, 2002; Volume 2283. [Google Scholar] [CrossRef]
  12. The HOL Light Theorem Prover. Available online: https://hol-light.github.io/ (accessed on 15 June 2025).
  13. Bancerek, G.; Bylinski, C.; Grabowski, A.; Korniłowicz, A.; Matuszewski, R.; Naumowicz, A.; Pak, K.; Urban, J. Mizar: State-of-the-art and Beyond. In Proceedings of the 8th International Conference on Intelligent Computer Mathematics (CICM 2015), Washington, DC, USA, 13–17 July 2015; pp. 261–279. [Google Scholar] [CrossRef]
  14. Moura, L.; Ullrich, S. The Lean 4 theorem prover and programming language. In Proceedings of the 28th International Conference on Automated Deduction (CADE 2021), Virtual Event, 12–15 July 2021; pp. 625–635. [Google Scholar] [CrossRef]
  15. Avigad, J.; Harrison, J. Formally verified mathematics. Commun. ACM 2014, 57, 66–75. [Google Scholar] [CrossRef]
  16. Beeson, M. The mechanization of mathematics. In Alan Turing: Life and Legacy of a Great Thinker; Teuscher, C., Ed.; Springer: Berlin/Heidelberg, Germany, 2004; pp. 77–134. [Google Scholar] [CrossRef]
  17. Avigad, J.; Donnelly, K.; Gray, D.; Raff, P. A formally verified proof of the prime number theorem. ACM Trans. Comput. Log. 2007, 9, 2-es. [Google Scholar] [CrossRef]
  18. Gonthier, G. Formal proof–the Four Color Theorem. Not. Am. Math. Soc. 2008, 55, 1382–1393. [Google Scholar]
  19. Hales, T. The Jordan curve theorem, formally and informally. Am. Math. Mon. 2007, 114, 882–894. [Google Scholar] [CrossRef]
  20. Paulson, L. A machine-assisted proof of Gödel’s incompleteness theorems for the theory of hreditarily finite sets. Rev. Symb. Log. 2014, 7, 484–498. [Google Scholar] [CrossRef]
  21. Ciolli, G.; Gentili, G. Maggesi, M. A certified proof of the Cartan Fixed Point Theorems. J. Autom. Reason. 2011, 47, 319–336. [Google Scholar] [CrossRef]
  22. Avigad, J.; Hölzl, J.; Serafin, L. A formally verified proof of the Central Limit Theorem. J. Autom. Reason. 2017, 59, 389–423. [Google Scholar] [CrossRef]
  23. Gonthier, G.; Asperti, A.; Avigad, J.; Bertot, Y.; Cohen, C.; Garillot, F.; Roux, S.L.; Mahboubi, A.; O’Connor, R.; Pasca, I.; et al. A machine-checked proof of the Odd Order Theorem. In Proceedings of the 4th International Conference on Interactive Theorem Proving (ITP 2013), Rennes, France, 22–26 July 2013; pp. 163–179. [Google Scholar] [CrossRef]
  24. Hales, T.; Adams, M.; Bauer, G.; Dang, T.D.; Harrison, J.; Hoang, L.T.; Kaliszyk, C.; Magron, V.; Mclaughlin, S.; Nguyen, Q.T.; et al. A formal proof of the Kepler Conjecture. arXiv 2015, arXiv:1501.02155. [Google Scholar] [CrossRef]
  25. Formalizing the Proof of PFR in Lean4 Using Blueprint: A Short Tour. Available online: https://terrytao.wordpress.com/2023/11/18/formalizing-the-proof-of-pfr-in-lean4-using-blueprint-a-short-tour/ (accessed on 15 June 2025).
  26. Wiedijk, F. Formal proof – getting started. Not. Am. Math. Soc. 2008, 55, 1408–1414. [Google Scholar]
  27. Weiss, I. Survey article: The real numbers—A survey of constructions. J. Math. 2015, 45, 737–762. [Google Scholar] [CrossRef]
  28. Dou, G.; Yu, W. Formalization of the Filter Extension Principle (FEP) in Coq. In Proceedings of the 6th Conference on Intelligent Networked Things (CINT 2024), Xi’an, China, 18 May 2024; pp. 95–106. [Google Scholar] [CrossRef]
  29. Dou, G.; Chen, S.; Yu, W.; Zhang, R. The Continuum Hypothesis Implies the Existence of Non-principal Arithmetical Ultrafilters—A Coq Formal Verification. In Proceedings of the 25th International Conference on Formal Engineering Methods (ICFEM 2024), Hiroshima, Japan, 2–6 December 2024; pp. 257–277. [Google Scholar] [CrossRef]
  30. Wang, F. Arithmetical Ultrafilters: End-Extenstions of N in βN; University of Science and Technology of China Press: Hefei, China, 2016. (In Chinese) [Google Scholar]
  31. Bell, J.L. Set Theory: Boolean-Valued Models and Independence Proofs (Oxford Logic Guides 47), 3rd ed.; Clarendon Press: Oxford, UK, 2005. [Google Scholar]
  32. Cohen, P.J. Set Theory and the Continuum Hypothesis; W.A.Benjamin, Inc.: New York, NY, USA, 1966. [Google Scholar]
  33. Robinson, A. Non-Standard Analysis, revised ed.; North Holland Publishing Company: Amsterdam, The Netherlands, 1974. [Google Scholar]
  34. Hewitt, E. Rings of real-valued continuous functions. I. Trans. Am. Math. Soc. 1948, 64, 45–99. [Google Scholar] [CrossRef]
  35. Jin, R. Nonstandard analysis and its applications. Sci. Sin. Math. 2016, 46, 371–408. (In Chinese) [Google Scholar] [CrossRef]
  36. Sun, T.; Yu, W. A formal system of axiomatic set theory in Coq. IEEE Access 2020, 8, 21510–21523. [Google Scholar] [CrossRef]
  37. Yu, W.; Sun, T.; Fu, Y. A Machine Proof System for Axiomatic Set Theory; Science Press: Beijing, China, 2020. (In Chinese) [Google Scholar]
  38. Riesz, F. Stetigkeitsbegriff und abstrakte Mengenlehre; Atti del IV Congresso Internazionale del Matematici; Castelnuovo, G., Ed.; Tipografia della R. Accademia dei Lincei: Rome, Italy, 1909; Volume 2, pp. 18–24. [Google Scholar]
  39. Comfort, W.W.; Negrepontis, S. The Theory of Ultrafilters; Springer: Berlin/Heidelberg, Germany, 1974. [Google Scholar]
  40. Cartan, H.P. Théorie des filtres. Comptes Rendus Hebdomadaires des Séances de L’Académie des Sciences 1937, 205, 595–598. [Google Scholar]
  41. Cartan, H.P. Filtres et ultrafilters. Comptes Rendus Hebdomadaires des Séances de L’Académie des Sciences 1937, 205, 777–779. [Google Scholar]
  42. Bourbaki, N. Elements of Mathematics: General Topology: Chapters 1–4; Springer: Berlin/Heidelberg, Germany, 1995. [Google Scholar]
  43. Thomsa, J.J. The Axiom of Choice; North-Holland Publishing Company: Amsterdam, The Netherlands, 1973. [Google Scholar]
  44. Daguenet-Teissier, M. Ultrafilters à la Facon de Ramsey. Trans. Am. Math. Soc. 1979, 250, 91–120. [Google Scholar]
  45. Fu, Y.; Yu, W. Formalization of the equivalence among completeness theorems of real number in Coq. Mathematics 2021, 9, 38. [Google Scholar] [CrossRef]
  46. Zorich, V.A. Mathematical Analysis, 7th expanded version; MCCME Publ.: Moscow, Russia, 2015. [Google Scholar]
  47. de Bruijn, N.G. Checking mathematics with computer assistance. Not. Am. Math. Soc. 1991, 38, 8–15. [Google Scholar]
  48. Simpson, C. Computer theorem proving in mathematics. Lett. Math. Phys. 2004, 69, 287–315. [Google Scholar] [CrossRef]
Figure 1. Relationships among filters.
Figure 1. Relationships among filters.
Mathematics 13 02707 g001
Figure 2. Equivalence classification of elements in * N × * N .
Figure 2. Equivalence classification of elements in * N × * N .
Mathematics 13 02707 g002
Figure 3. Equivalence classification of elements in * Z × ( * Z { * Z 0 } ) .
Figure 3. Equivalence classification of elements in * Z × ( * Z { * Z 0 } ) .
Mathematics 13 02707 g003
Figure 4. The process from ω to *Q.
Figure 4. The process from ω to *Q.
Mathematics 13 02707 g004
Figure 5. The process from *Q to R .
Figure 5. The process from *Q to R .
Mathematics 13 02707 g005
Figure 6. The dependency graph of our Coq development (.v)files.
Figure 6. The dependency graph of our Coq development (.v)files.
Mathematics 13 02707 g006
Table 1. Fundamental proof tactics in Coq.
Table 1. Fundamental proof tactics in Coq.
Tactic Semantics
intro/introsintroduce a single premise/all premises to proof environment as hypotheses
pose proof Hintroduce an existing hypothesis H or a previously established theorem
splitsplit the conjunction in the goal to generate two subgoals
destruct Hsplit disjunctions or conjunctions/instantiate existential quantifiers in hypothesis H, where H can be a proven theorem
assumptionsearch through all available hypotheses to find an exact match for the goal and solve it
apply H (in H1)apply the hypothesis H to the proof goal (to the hypothesis H1), where H can be a proven theorem
unfold A (in H)unfold definition A in the goal (in hypothesis H)
rewrite H (in H1)perform equality substitution on the proof goal (or hypothesis H1) using equation H to replace corresponding variables
exists ainstantiate the existential quantifier in the goal with a
left/rightextract the left/right disjunct from the goal’s disjunction as a new subgoal
repeat Trepeat applying tactic T until it is no longer applicable
autoautomatically and repeatedly execute basic tactics including assumption, intros and apply
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Dou, G.; Yu, W. A Machine Proof of the Filter-Method Construction for Real Numbers. Mathematics 2025, 13, 2707. https://doi.org/10.3390/math13172707

AMA Style

Dou G, Yu W. A Machine Proof of the Filter-Method Construction for Real Numbers. Mathematics. 2025; 13(17):2707. https://doi.org/10.3390/math13172707

Chicago/Turabian Style

Dou, Guowei, and Wensheng Yu. 2025. "A Machine Proof of the Filter-Method Construction for Real Numbers" Mathematics 13, no. 17: 2707. https://doi.org/10.3390/math13172707

APA Style

Dou, G., & Yu, W. (2025). A Machine Proof of the Filter-Method Construction for Real Numbers. Mathematics, 13(17), 2707. https://doi.org/10.3390/math13172707

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop