The theorems translated from Metamath reside in the MMI_Complex_ZF, MMI_Complex_ZF_1 and MMI_Complex_ZF_2 theories. The proofs of these theorems are very verbose and for this reason the theories are not shown in the proof document or the FormaMath.org site. This theory file contains some examples of theorems translated from Metamath and formulated in the complex0 context. This serves two purposes: to give an overview of the material covered in the translated theorems and to provide examples of how to take a translated theorem (proven in the MMIsar0 context) and transfer it to the complex0 context. The typical procedure for moving a theorem from MMIsar0 to complex0 is as follows: First we define certain aliases that map names defined in the complex0 to their corresponding names in the MMIsar0 context. This makes it easy to copy and paste the statement of the theorem as displayed with ProofGeneral. Then we run the Isabelle from ProofGeneral up to the theorem we want to move. When the theorem is verified ProofGeneral displays the statement in the raw set theory notation, stripped from any notation defined in the MMIsar0 locale. This is what we copy to the proof in the complex0 locale. After that we just can write "then have ?thesis by simp" and the simplifier translates the raw set theory notation to the one used in complex0.
In this sectin we import a couple of theorems about the extended real line and the linear order on it.
Metamath uses the set of real numbers extended with \(+\infty\) and \(-\infty\). The \(+\infty\) and \(-\infty\) symbols are defined quite arbitrarily as \(\mathbb{C}\) and \(\mathbb{\{ C\} }\), respectively. The next lemma that corresponds to Metamath's renfdisj states that \(+\infty\) and \(-\infty\) are not elements of \(\mathbb{R}\).
lemma (in complex0) renfdisj:
shows \( \mathbb{R} \cap \{+\infty ,-\infty \} = 0 \)proofThe order relation used most often in Metamath is defined on the set of complex reals extended with \(+\infty\) and \(-\infty\). The next lemma allows to use Metamath's xrltso that states that the \( \lt \) relations is a strict linear order on the extended set.
lemma (in complex0) xrltso:
shows \( \lt \text{ orders } \mathbb{R} ^* \)proofMetamath defines the usual \(<\) and \(\leq\) ordering relations for the extended real line, including \(+\infty\) and \(-\infty\).
lemma (in complex0) xrrebndt:
assumes A1: \( x \in \mathbb{R} ^* \)
shows \( x \in \mathbb{R} \longleftrightarrow ( -\infty \lt x \wedge x \lt +\infty ) \)proofA quite involved inequality.
lemma (in complex0) lt2mul2divt:
assumes A1: \( a \in \mathbb{R} \), \( b \in \mathbb{R} \), \( c \in \mathbb{R} \), \( d \in \mathbb{R} \) and A2: \( 0 \lt b \), \( 0 \lt d \)
shows \( a\cdot b \lt c\cdot d \longleftrightarrow a / d \lt c / b \)proofA real number is smaller than its half iff it is positive.
lemma (in complex0) halfpos:
assumes A1: \( a \in \mathbb{R} \)
shows \( 0 \lt a \longleftrightarrow a / 2 \lt a \)proofOne more inequality.
lemma (in complex0) ledivp1t:
assumes A1: \( a \in \mathbb{R} \), \( b \in \mathbb{R} \) and A2: \( 0 \leq a \), \( 0 \leq b \)
shows \( (a / (b + 1 ))\cdot b \leq a \)proofIn standard mathematics natural numbers are treated as a subset of real numbers. From the set theory point of view however those are quite different objects. In this section we talk about "real natural" numbers i.e. the conterpart of natural numbers that is a subset of the reals.
Two ways of saying that there are no natural numbers between \(n\) and \(n+1\).
lemma (in complex0) no_nats_between:
assumes A1: \( n \in \mathbb{N} \), \( k \in \mathbb{N} \)
shows \( n\leq k \longleftrightarrow n \lt k + 1 \), \( n \lt k \longleftrightarrow n + 1 \leq k \)proofMetamath has some very complicated and general version of induction on (complex) natural numbers that I can't even understand. As an exercise I derived a more standard version that is imported to the complex0 context below.
lemma (in complex0) cplx_nat_ind:
assumes A1: \( \psi (1 ) \) and A2: \( \forall k \in \mathbb{N} .\ \psi (k) \longrightarrow \psi (k + 1 ) \) and A3: \( n \in \mathbb{N} \)
shows \( \psi (n) \)proofSome simple arithmetics.
lemma (in complex0) arith:
shows \( 2 + 2 = 4 \), \( 2 \cdot 2 = 4 \), \( 3 \cdot 2 = 6 \), \( 3 \cdot 3 = 9 \)proofReal numbers form a complete ordered field. Here we import a couple of Metamath theorems about supremu and infimum.
If a set \(S\) has a smallest element, then the infimum of \(S\) belongs to it.
lemma (in complex0) lbinfmcl:
assumes A1: \( S \subseteq \mathbb{R} \) and A2: \( \exists x\in S.\ \forall y\in S.\ x \leq y \)
shows \( \text{Infim}(S,\mathbb{R} , \lt ) \in S \)proofSupremum of any subset of reals that is bounded above is real.
lemma (in complex0) sup_is_real:
assumes \( A \subseteq \mathbb{R} \) and \( A \neq 0 \) and \( \exists x\in \mathbb{R} .\ \forall y\in A.\ y \leq x \)
shows \( \text{Sup}(A,\mathbb{R} , \lt ) \in \mathbb{R} \)proofIf a real number is smaller that the supremum of \(A\), then we can find an element of \(A\) greater than it.
lemma (in complex0) suprlub:
assumes \( A \subseteq \mathbb{R} \) and \( A \neq 0 \) and \( \exists x\in \mathbb{R} .\ \forall y\in A.\ y \leq x \) and \( B \in \mathbb{R} \) and \( B \lt \text{Sup}(A,\mathbb{R} , \lt ) \)
shows \( \exists z\in A.\ B \lt z \)proofSomething a bit more interesting: infimum of a set that is bounded below is real and equal to the minus supremum of the set flipped around zero.
lemma (in complex0) infmsup:
assumes \( A \subseteq \mathbb{R} \) and \( A \neq 0 \) and \( \exists x\in \mathbb{R} .\ \forall y\in A.\ x \leq y \)
shows \( \text{Infim}(A,\mathbb{R} , \lt ) \in \mathbb{R} \), \( \text{Infim}(A,\mathbb{R} , \lt ) = ( - \text{Sup}(\{z \in \mathbb{R} .\ ( - z) \in A \},\mathbb{R} , \lt ) ) \)proof