<!DOCTYPE article PUBLIC "-//NLM//DTD JATS (Z39.96) Journal Archiving and Interchange DTD v1.0 20120330//EN" "JATS-archivearticle1.dtd">
<article xmlns:xlink="http://www.w3.org/1999/xlink">
  <front>
    <journal-meta>
      <journal-title-group>
        <journal-title>These authors contributed equally.
$ domenico.cantone@unict.it (D. Cantone); eomodeo@units.it (E. G. Omodeo); alberto.policriti@uniud.it
(A. Policriti)
 https://www.dmi.unict.it/cantone/ (D. Cantone)</journal-title>
      </journal-title-group>
    </journal-meta>
    <article-meta>
      <title-group>
        <article-title>Continued Hereditarily Finite Set-Approximations⋆</article-title>
      </title-group>
      <contrib-group>
        <contrib contrib-type="author">
          <string-name>Domenico Cantone</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Eugenio G. Omodeo</string-name>
          <xref ref-type="aff" rid="aff1">1</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Alberto Policriti</string-name>
          <xref ref-type="aff" rid="aff2">2</xref>
        </contrib>
        <aff id="aff0">
          <label>0</label>
          <institution>University of Catania</institution>
          ,
          <addr-line>DMI, viale Andrea Doria, 6, I-95125 Catania</addr-line>
          ,
          <country country="IT">Italy</country>
        </aff>
        <aff id="aff1">
          <label>1</label>
          <institution>University of Trieste</institution>
          ,
          <addr-line>DMG, via Alfonso Valerio 12/1, I-34127 Trieste</addr-line>
          ,
          <country country="IT">Italy</country>
        </aff>
        <aff id="aff2">
          <label>2</label>
          <institution>University of Udine</institution>
          ,
          <addr-line>DMIF, via delle Scienze 206</addr-line>
          ,
          <country country="IT">Italy</country>
        </aff>
      </contrib-group>
      <pub-date>
        <year>2023</year>
      </pub-date>
      <volume>000</volume>
      <fpage>0</fpage>
      <lpage>0002</lpage>
      <abstract>
        <p>We study an encoding R that assigns a real number to each hereditarily finite set, in a broad sense. In particular, we investigate whether the map R can be used to produce codes that approximate any positive real number  to arbitrary precision, in a way that is related to continued fractions. This is an interesting question because it connects the theory of hereditarily finite sets to the theory of real numbers and continued fractions, which have important applications in number theory, analysis, and other fields.</p>
      </abstract>
      <kwd-group>
        <kwd>eol&gt;Ackermann codes</kwd>
        <kwd>hereditarily finite sets</kwd>
        <kwd>continued fractions</kwd>
        <kwd>set-approximations</kwd>
      </kwd-group>
    </article-meta>
  </front>
  <body>
    <sec id="sec-1">
      <title>1. Introduction</title>
      <p>
        We consider the following mapping of (hereditarily finite) sets into real numbers (see [
        <xref ref-type="bibr" rid="ref1">1</xref>
        ])
defined in complete analogy with the celebrated function
      </p>
      <p>
        R() =
N() =
∑︁ 2− R(),
∈
∑︁ 2N()
∈
proposed by W. Ackermann in 1937 as a recursive encoding of hereditarily finite sets by natural
numbers (see [
        <xref ref-type="bibr" rid="ref2">2</xref>
        ]).
      </p>
      <p>The encoding R(· ) can be used to map its domain, which is formed by the union of the
following universes, into real numbers:</p>
      <sec id="sec-1-1">
        <title>1. HF: the well-founded hereditarily finite sets (h.f. sets, for short);</title>
        <sec id="sec-1-1-1">
          <title>2. HF : the hereditarily finite multisets (see [3]);</title>
          <p>
            3. HF1: the hereditarily finite circular sets (hypersets,1 from now on; see [
            <xref ref-type="bibr" rid="ref4 ref5">4, 5</xref>
            ]);
4. HF1/2: the hereditarily finite rational hypersets, that is the sub-universe of HF1 consisting
of those hypersets whose transitive closures are finite.
          </p>
        </sec>
      </sec>
      <sec id="sec-1-2">
        <title>The following inclusions hold:</title>
        <p>HF ⊊ HF1/2 ⊊ HF1
∧</p>
        <p>HF ⊊ HF .</p>
        <p>In what follows, for any set ℏ that belongs to one of the aforementioned universes, we will
refer to the real number R(ℏ) as the code of ℏ.2</p>
        <p>
          In [
          <xref ref-type="bibr" rid="ref6">6</xref>
          ], it has been proven that each element of HF1/2 has a uniquely defined code. In the
following, we contend that sets belonging to any of the universes listed above have unique
codes as well.
        </p>
        <p>Furthermore, we will demonstrate that every real number can be approximated arbitrarily
closely by a (possibly infinite) sequence of codes of well-founded hereditarily finite sets. Building
on this result, we will then show that every positive real number can be expressed as the code
of a single element in HF1. The proof of this fact relies on introducing a set-theoretic version of
the process used to define the continued fraction uniquely associated with any given positive
real number.</p>
        <p>Our construction introduces the concept of set-approximation, which is a sequence of sets that
may not be unique and may have diferent ways of being obtained, but whose codes eventually
converge to any given non-negative real number  ∈ R0+. However, we will show that there
exists a unique first approximation, which is obtained by using codes of sets in HF selected
according to a minimality criterion (minimum N-code). This notion of optimality will serve
as a set-theoretic counterpart to the concept of first approximation introduced in the study of
continued fractions.</p>
        <p>The mapping of universes of hereditarily finite sets into finitely-branching directed graphs
provides a connection between the material presented here and graph theory.</p>
      </sec>
    </sec>
    <sec id="sec-2">
      <title>2. Basics</title>
      <p>Let N and N+ be the set of natural numbers and positive integers, respectively, and let P(· )
denote the powerset operator.</p>
      <p>Definition 1 (Hereditarily finite sets) . HF = ⋃︀∈N HF is the collection of all hereditarily
ifnite sets, where
{︃</p>
      <p>HF0 = ∅,</p>
      <p>
        HF+1 = P(HF), for  ∈ N.
1A term introduced by Barwise and Etchemendy in [
        <xref ref-type="bibr" rid="ref4">4</xref>
        ].
      </p>
      <sec id="sec-2-1">
        <title>2We will use ℏ instead of plain ℎ to stress that ℏ may represent a hyperset.</title>
        <sec id="sec-2-1-1">
          <title>The Ackermann code N recalled above, where</title>
          <p>N() = ∑︁ 2N()</p>
          <p>∈
h0, h1, h2, h3, . . .</p>
          <p>R() = ∑︁ 2− R().</p>
          <p>∈
for every hereditarily finite set , induces a natural ordering
of the hereditarily finite sets, known as the Ackermann order, where N(h) =  for every  ∈ N.</p>
          <p>Consider next the following map R over HF, obtained from N by simply placing a minus
sign in front of each exponent in the definition of N:
(1)
From (1), it readily follows that all (valid) R-codes are nonnegative. For instance, we have:
R(∅) = 0,</p>
          <p>1
R({∅}3) = √ ,
2</p>
          <p>R({∅}) = 1,
R({∅}4) = 2− √12 ,</p>
          <p>1
R({∅}2) = 2 ,
R({∅}5) = 2− 2− √12 , etc.,
where {∅}0 = ∅ and, recursively, {∅}+1 = {︀ {∅}}︀ .</p>
          <p>
            In the following, it will be convenient to introduce a graph-theoretic point of view on
hereditarily finite sets (see [
            <xref ref-type="bibr" rid="ref7">7</xref>
            ]). Such view is based on the introduction of the so-called membership
graph (see Section 2.3.1). Just two notions will be instrumental in order to introduce membership
graphs: the notion of transitive closure of a set and the notion of bisimulation, which we briefly
recall here.
          </p>
        </sec>
      </sec>
      <sec id="sec-2-2">
        <title>The transitive closure of a set ℏ is defined, recursively or otherwise, as the</title>
        <p>Definition 2.
collection</p>
        <p>TrCl (ℏ) =</p>
        <p>ℏ ∪ ⋃︀∈ℏ TrCl ().</p>
        <p>Definition 3. A bisimulation on a given graph  = (, ) is a relation  ⊆  ×  such that,
for all 0, 1 ∈  for which ⟨0, 1⟩ ∈  holds, the following two conditions hold as well:
• ∀1[⟨1, 1⟩ ∈  → ∃0(⟨0, 0⟩ ∈  ∧ ⟨0, 1⟩ ∈ )];
• ∀0[⟨0, 0⟩ ∈  → ∃1(⟨1, 1⟩ ∈  ∧ ⟨0, 1⟩ ∈ )].</p>
        <p>
          It can be shown that, given a graph , there always exists a bisimulation on  that includes
all others. When the graph  is understood, the symbol ∼= will be used to denote such a maximal
bisimulation, which is an equivalence relation — named bisimilarity — on the set  of nodes.
2.1. Continued Fractions
Continued fractions (see [
          <xref ref-type="bibr" rid="ref8">8</xref>
          ]) are introduced, among many other reasons, as a simple and elegant
means to denote real numbers. In the most basic setting, where elements of the continued
fractions are simply natural numbers, the idea is the following. Given a positive real number
 ∈ R+, either  ∈ N, in which case we are done, or 0 &lt;  − ⌊  ⌋ &lt; 1. In the latter case, we
can express  as ⌊ ⌋ + 1 , for some  &gt; 1. By iterating the above process, we ultimately obtain
a (possibly infinite) continued fraction
 = 0 +
,
where the  are natural numbers, which can be conveniently represented as [0; 1, 2, . . .].
        </p>
        <p>Based on the above initial steps, a rich theory has been developed. In particular, it can be easily
proved that every  ∈ R+ can be arbitrarily approximated by a (possibly infinite) sequence
⟨  ⟩ of rational numbers, satisfying the following recursive relations: for any  ⩾ 2,
 
{︃ = − 1 + − 2 ,</p>
        <p>= − 1 + − 2 .</p>
        <p>
          Continued approximations built using the above ideas turn out to be optimal in the sense
described in [
          <xref ref-type="bibr" rid="ref8">8</xref>
          ]:
        </p>
        <p>Let us agree that a fraction / (for  &gt; 0) is a best approximation of a real number  if
every other rational fraction with the same or smaller denominator difers from  by a
greater amount, in other words, if the inequalities 0 &lt;  ⩽ , and / ̸≡ / imply that:
⃒⃒⃒  −  ⃒⃒ ⃒  ⃒⃒ .</p>
        <p>
          ⃒ &gt; ⃒⃒  −  ⃒
2.2. The Universe HF of Hereditarily Finite Multisets
To define the collection HF of hereditarily finite multisets, we use the finitary
operator P (see [
          <xref ref-type="bibr" rid="ref3">3</xref>
          ]). Given a multiset , we put
        </p>
        <p>P () = {︀ {11, . . . , } | 1, . . . ,  ∈  (distinct) , 1, . . . ,  ∈ N+,  ∈ N︀} .
Thus, each element  of P () has the form {︀ 11, . . . , }︀ , where 1, . . . ,  are finitely
many distinct members of  and 1, . . . ,  ∈ N+ are their multiplicities in .</p>
        <p>Then, the cumulative hierarchy HF of the hereditarily finite multisets is defined as
 -power-set
HF = ⋃︁ HF,</p>
        <p>∈N
where HF0 = ∅ and, recursively, HF+1 = P (HF) for  ∈ N.</p>
        <p>The map R can be extended in a very natural manner to a map R over the collection HF
of the h.f. multisets, by putting recursively, for every multiset  ∈ HF ,</p>
        <p>R() = ∑︁   () · 2− R().</p>
        <p>
          ∈
2.3. Set Systems
Both well-founded and circular sets can be presented as (unique) solutions to systems of
settheoretic equations such as the ones introduced by the following definition (taken from [
          <xref ref-type="bibr" rid="ref6">6</xref>
          ], see
also [
          <xref ref-type="bibr" rid="ref5">5</xref>
          ]). A collection ℏ1, . . . , ℏ of sets solving a given set system in the variables 1, . . . ,  is
downward closed with respect to membership and is fully described by the equations appearing
in the system. As a matter of fact, the solution set turns out to be a complete listing of the sets
in TrCl ({ℏ1, . . . , ℏ}).
        </p>
        <p>Definition 4 (Set systems). A set system S (1, . . . , ) in the distinct set unknowns
1, . . . ,  is a collection of set-theoretic equations of the form
⎧1 = {1,1, . . . , 1,1 }
⎪
⎪⎨ ..</p>
        <p>.
⎪
⎪⎩ = {,1, . . . , , },
(2)
with  ⩾ 0 for  ∈ {1, . . . , }, where each unknown ,, for  ∈ {1, . . . , } and  ∈
{1, . . . , }, also occurs among the unknowns 1, . . . , .3</p>
        <p>The directed graph S = (S , S ) associated with the system S = S (1, . . . , ), with
S = {1, . . . , },
S = {︀ ⟨, ,⟩ :  ∈ {1, . . . , },  ∈ {1, . . . , }︀} ,
is the membership graph of S .</p>
        <p>
          Remark 2.1. Note that we are not insisting that the membership graph be acyclic; if we did, we
would be considering only conventional, well-founded sets; this is because we want our notions
to adjust to all intricacies inherent in Aczel’s notion of ‘non-well-founded’ (albeit finite) sets, cf.
[
          <xref ref-type="bibr" rid="ref5">5</xref>
          ].
        </p>
        <p>Definition 5. A set system S (1, . . . , ) is normal if there exist  pairwise distinct (i.e.,
non-bisimilar4) hypersets ℏ1, . . . , ℏ ∈ HF1/2 such that the assignment  ↦→ ℏ satisfies all the
set equations of S (1, . . . , ).</p>
        <p>For every ℎ = {ℎ1, . . . , ℎ} ∈ HF with  members, the code R(ℎ) can be expressed as the
sum</p>
        <p>R({ℎ1}) + · · ·
+ R({ℎ}).5
3When  = 0, the expression {,1, . . . , , } reduces to {}, designating the empty set.
4Bisimilarity (see lines below Definition 3) is now referred to the graph S .
5Disjoint additivity property.</p>
        <p>⎧⎪1 = {2, 3}
⎪
⎪⎪⎪2 = { }
⎪
⎪
⎪⎪⎪3 = {4, 5}
⎪
⎪
⎨4 = {2}
⎪⎪5 = {6, 7}
⎪
⎪
⎪⎪⎪6 = {4}
⎪
⎪⎩⎪⎪⎪ ...</p>
        <p>1
3
5
.
.
.</p>
        <p>.
.
.</p>
        <p>2
4
6</p>
        <p>
          Since R({ℎ}) = 2− R(ℎ) ⩽ 1, we can therefore conclude that R(ℎ) ⩽ |ℎ|. As a matter of
fact, in [
          <xref ref-type="bibr" rid="ref6">6</xref>
          ] it is proved that if ℎ is the (unique) solution to a system S of set-theoretic equations
involving one variable for each of the elements in TrCl (ℎ), R(ℎ) is the point of convergence of
a sequence of codes of multisets approximating ℎ. Such multiset code-values, whose definition is
given so as to generalise naturally the definition given for sets, start with 0 and |ℎ| and oscillate
alternatively below and above R(ℎ), eventually converging to it.
2.3.1. The Universes HF1 and HF1/2 of Hereditarily Finite Hypersets
The collection HF1 of hereditarily finite hypersets can be seen as consisting of the unique
solutions to infinite set systems defined as in the previous subsection. Equivalently, HF1 can be
seen as the smallest collection of finite hypersets, all of whose elements are finite. Albeit each
element of HF1 has finitely many members, this is not necessarily true for its transitive closure.
        </p>
        <p>HF1/2 is the sub-collection of the hypersets in HF1 whose transitive closures are finite.
Example 1. In Figure 1 is an infinite set system describing a set TrCl ({ℏ1}) with ℏ1 ∈ HF1∖HF1/2
and in Figure 2 its membership graph.</p>
        <p>In analogy with what has been done for set systems, it is convenient to “depict” also a
hyperset ℏ by its membership graph ℏ = (ℏ, ℏ), namely a directed graph whose nodes are
the hypersets in TrCl ({ℏ}) and whose arcs represent the membership relation among them:
⟨ℏ′′, ℏ′⟩ ∈ ℏ
if and only if
ℏ′ ←
ℏ′′
if and only if
ℏ′ ∈ ℏ′′.</p>
        <p>Graphs bisimilar to ℏ (with, possibly, more than |TrCl ({ℏ})| nodes) will depict (possibly
redundantly) the same hyperset ℏ: ℏ will be the (minimal) representative of its ∼=-equivalence
class. All graphs  bisimilar to ℏ will also be dubbed membership graphs. It turns out that
every node in each such graph  is reachable from a node bisimilar to ℏ, which is called the
point of the (pointed) graph .</p>
        <p>We can identify HF1 as the quotient by bisimulation of the collection  of directed and
pointed graphs, all of whose nodes have a finite-size in-neighborhood.</p>
        <p>The unfolding of a graph in  is a finitely branching tree and can be seen as an “approximation”
of the graph. More formally:
Definition 6. For all  ∈ N and  ∈ , the -th unfolding u() of  is the finitely branching
tree whose nodes are paths of length less than or equal to  starting from the point in , and
whose arcs correspond to a one-step extension of paths of length less than .</p>
        <p>
          Given ℏ ∈ HF1, the infinite unfolding u(ℏ) of ℏ is defined to be u(ℏ) = lim→∞ u(ℏ).6
Since a finite tree is essentially a hereditarily finite multi-set (see [
          <xref ref-type="bibr" rid="ref3">3</xref>
          ]), the above definitions
allow us to extend the notion of R-code to HF1, via the generalisation R of R to multi-sets.
Lemma 2.2. For any ℏ ∈ HF1, there exists  ∈ R0+ such that:
 = lim R(u(ℏ)).
        </p>
        <p>
          →∞
Proof. The proof of this fact is a generalisation to infinite sets of Lemma 4 and Theorem 4 in
[
          <xref ref-type="bibr" rid="ref6">6</xref>
          ].
        </p>
        <p>The above lemma allows us to extend the mapping R to hypersets, according to the following
definition:
Definition 7. For any ℏ ∈ HF1, we put</p>
        <p>R(ℏ) = lim R(u(ℏ)).</p>
        <p>→∞</p>
      </sec>
    </sec>
    <sec id="sec-3">
      <title>3. Continued Approximations of Codes</title>
      <p>
        As observed in [
        <xref ref-type="bibr" rid="ref6">6</xref>
        ], the codes of elements of HF can get arbitrarily large and arbitrarily small.
      </p>
      <sec id="sec-3-1">
        <title>This is proved in the following lemma.</title>
        <p>Lemma 3.1. For every  ∈ R+ there exist (nonempty) ℎ, ℎ′ ∈ HF such that R(ℎ) &gt;  and
0 &lt; R(ℎ′) &lt;  .</p>
        <p>Proof. Notice that for any odd natural number , we have ∅ ∈ h . Thus, we have R(h ) ⩾
R({∅}) = 20 = 1, R({h }) = 2− R(h) ⩽ 2− 1 = 21 , and R({{h }}) = 2− R({h}) ⩾
2− 1/2 &gt; 21 .</p>
        <p>Given  ∈ R+, let  = ⌈4 ⌉ and consider the ( + 1)-element hereditarily finite set
ℎ = {︀ {h } :  ⩽ }︀ . Then, we have:</p>
        <p>R(ℎ) = ∑︁ R(︀ {{h }} ︀) ⩾
=0</p>
        <p>∑︁
=0
 is odd</p>
        <p>R(︀ {{h }} ︀) &gt;
1 ⌈︂  ⌉︂
2 · 2</p>
        <p>1 ⌈︂ ⌈4 ⌉ ⌉︂
= 2 · 2
⩾ 21 · ⌈42 ⌉ ⩾  .</p>
        <p>Next, to prove that for all  ∈ R+ there exists ℎ′ ∈ HF such that 0 &lt; R(ℎ′) &lt;  , it sufices
to pick any ℎ ∈ HF such that R(ℎ) &gt; 1 and set ℎ′ = {ℎ}. Indeed, by recalling that the
inequality  &gt; 12 holds for all  &gt; 0, we have:</p>
        <p>0 &lt; R(ℎ′) = R({ℎ}) = 2− R(ℎ) &lt; 2− 1 &lt; .
6The definition of infinite unfolding is well-given, since</p>
        <p>u() is a subtree of u+1() for all  ∈  and  ∈ N.</p>
      </sec>
      <sec id="sec-3-2">
        <title>An immediate consequence of the preceding lemma is the following:</title>
        <p>Corollary 3.2. For every  ∈ R+ there exist infinitely many ℎ, ℎ′ ∈ HF such that R(ℎ) &gt; 
and R(ℎ′) &lt;  .</p>
        <p>The above lemma allows us to conclude that we can arbitrarily approximate any real number
in the following sense.</p>
        <p>Definition 8. Given  ∈ R0+ (= R+ ∪ {0}), a sequence ⟨ℎ, ⟩∈N of hereditarily finite sets is
said to approximate  or to be an  -approximation, if
∑︁ R(ℎ, ) = .</p>
        <p>∈N</p>
        <p>Even though Lemma 3.1 easily implies, for every  ∈ R+, the existence of  -approximating
sequences (in which repetitions are allowed), the above definition, clearly, by no means identifies
a unique such a sequence.</p>
        <p>In the following, we will address the question of giving a sensible notion of first approximation
and proving its uniqueness.</p>
        <p>Remark 3.3. We will prove below that introducing (first) approximating sequences — whose
elements are codes of elements in HF — is a way to capture (by approximations) the uncountably
many real numbers by means of the countably many (codes of) elements of HF.</p>
        <p>Since the cardinality of HF1 is larger than  and since our notion of R-code extends
to hypersets, the above remark suggests the following question, which will be addressed in</p>
      </sec>
      <sec id="sec-3-3">
        <title>Section 3.3:</title>
        <p>Question (HF1-approximations).</p>
        <p>Given  ∈ R, is there any element ℏ( ) ∈ HF1 such that R(ℏ( )) =  ?
3.1. On the Existence and Uniqueness of First Approximations
Given  ∈ R0+, consider any sequence ⟨ℎ, ⟩∈N that approximates  . In the most interesting
case, that is when  can be approximated only by sequences that are not eventually constant,
the values R(ℎ, ) get arbitrarily small. Since for any  ∈ N there are only finitely many
hereditarily finite sets whose Ackermann number N is smaller than N(ℎ, ), this implies
that N(ℎ, ) (as well as the rank rk(ℎ, )) must get arbitrarily large.</p>
        <p>The above considerations motivate, for any  ∈ R0+, the following definition, setting the
stage for uniquely identifying a first approximating sequence.</p>
        <p>Definition 9. Given  ∈ R+, the least approximation of  , denoted ℎ , is the (nonempty) h.f.
set whose N-code is minimum among all the sets ℎ in HF such that 0 &lt; R(ℎ) ⩽  .</p>
        <p>We also let ∅ be the least approximation of 0.</p>
        <p>In view of Lemma 3.1, the above definition is well-given. The same idea used in it, which
allowed us to identify the single first approximation for  ∈ R0+, can iteratively be exploited to
characterize a sequence of least approximations.</p>
        <p>Definition 10.</p>
        <p>Given  ∈ R0+, the first 7 set-theoretic approximating sequence ⟨ℎ, ⟩∈N of  is
7In the conclusions we will justify our choice of calling the approximation defined here as “first” instead of “best”.
recursively defined as follows, for  ∈ N:
1. if R(⋃︀− =10 ℎ, ) =  , then ℎ, = ∅;
2. otherwise ℎ, is the set in HF whose N-code is minimum among the sets in HF such
ℎ ̸⊆
⋃︀− =10 ℎ,
and</p>
        <p>R(ℎ ∪ ⋃︀− =10 ℎ, ) ⩽  .</p>
        <p>(3)
(4)</p>
        <sec id="sec-3-3-1">
          <title>We will refer to the (possibly infinite) set ⋃︀</title>
          <p>approximating sequence ⟨ℎ, ⟩∈N of  .
∈N ℎ, as the cumulus of the first set-theoretic</p>
        </sec>
      </sec>
      <sec id="sec-3-4">
        <title>Remark 3.4. The preceding definition is well-given. Indeed, if</title>
        <p>some  ∈ N, then Corollary 3.2 yields the existence of infinitely many sets
R(ℎ) ⩽  − R(⋃︀− =10 ℎ, ). Hence, there exist infinitely many sets ℎ in HF such that (3)
ℎ in HF such that
R(⋃︀− =10 ℎ, ) &lt;  holds for</p>
        <p>In the rest of the section, we let  ∈ R0+ and ⟨ℎ, ⟩∈N be the first set-theoretic approximating
sequence ⟨ℎ ⟩∈N is ⊆ -monotone, that is:</p>
        <p>Denote by ℎ the hereditarily finite set ⋃︀</p>
        <p>⩽ ℎ, and call the sequence of ⟨ℎ ⟩∈N the
cumulative version of the set-theoretic approximating sequence ⟨ℎ, ⟩∈N. The cumulative
ℎ0 ⊆ ℎ1 ⊆ · · · ⊆
ℎ ⊆ · · ·
.</p>
        <p>Plainly, its set-theoretic limit ℎ∞ = ⋃︀
⟨ℎ, ⟩∈N from which it derives.
holds that:</p>
        <sec id="sec-3-4-1">
          <title>As yet, we cannot exclude that ℎ,</title>
          <p>= ℎ,
holds for some pair ,  of distinct pedices.
with  ̸= . These possibilities are ruled out by the following lemma.</p>
          <p>Moreover, even if we had ℎ, ̸
= ℎ,</p>
          <p>when  ̸= , it could still be the case that ℎ, ∩ ℎ, ̸= ∅
Lemma 3.5. Given a first set-theoretic approximating sequence ⟨ℎ, ⟩∈N of some  ∈ R0+, it
∈N ℎ coincides with the cumulus of the sequence
that
holds.
sequence of  .</p>
          <p>i) ℎ, ∩ ℎ, = ∅, for all distinct ,  ∈ N;
ii) ℎ, is the least approximation of  − R(ℎ− 1) when  &gt; 0;
iii) ℎ ∩ ℎ, +1 = ∅, for all  ∈ N;
iv) either
– for all  ∈ N it holds that ℎ ⊊
– there exists ¯ such that ℎ ⊊
ℎ+1, or</p>
          <p>v) R(ℎ ) = R ︁( ⨄︀
⩽ ℎ,
︁)
= ∑︀⩽ R(ℎ, ).</p>
          <p>ℎ+1, for all  &lt; ¯, and ℎ = ℎ

¯ , for all  ⩾ ¯;
the claim follows Definitions 9 and 10.</p>
        </sec>
      </sec>
      <sec id="sec-3-5">
        <title>Finally, points iii), iv), and v) easily follow from i).</title>
        <p>setting ℎ′,
R(ℎ, ∪
N-code of ℎ, .</p>
        <p>⋃︀
Proof. To see i), arguing by contradiction assume that ℎ,
ℎ, and ℎ, are nonempty and ℎ, ⊈
= ℎ,
∖ ℎ, , we would have ℎ′</p>
        <p>, ⊈
ℎ, holds by point 2 of Definition 10. Hence, by
⋃︀
⩽− 1 ℎ, , R(ℎ′, ∪
⋃︀</p>
        <p>⩽− 1 ℎ, ) =
∩ ℎ, ̸
= ∅, for some  &lt; . Then
⩽− 1 ℎ, ) ⩽  , and N(ℎ′, ) &lt; N(ℎ, ), contradicting the minimality of the
As for ii), notice that from i) it follows that R(⋃︀⩽ ℎ, ) = R(ℎ, ) + R(ℎ− 1). Hence
Theorem 3.6. Given  ∈ R0+, the first set-theoretic approximating sequence ⟨ℎ, ⟩∈N is unique.
Proof. Arguing by contradiction, let ⟨ℎ, ⟩∈N and ⟨ℎ′, ⟩∈N be two distinct first approximating
sequences of the same real number</p>
        <p>+
∈ R0 . We can immediately rule out the case 
= 0,
since from Definition 10 the first approximating sequence of
0 is the constant null-set sequence
⋃︀
that ℎ,</p>
        <p>⩽− 1 ℎ,
⟨∅, ∅, ∅, . . .⟩. Hence, let  &gt;
= ⋃︀</p>
        <p>⩽− 1 ℎ′
= ℎ′, , a contradiction.</p>
        <p>, holds, so that by points 1 and 2 of Definition 10 it readily follows
0, and let  ∈ N be the first index such that
ℎ, ̸
= ℎ′, . Thus,</p>
      </sec>
      <sec id="sec-3-6">
        <title>A useful technical fact is stated in the following lemma.</title>
        <p>and let ⟨ℎ ⟩∈N be its cumulative version. Also, let ℎ ∈ HF and  ∈ N be such that
+
Lemma 3.7. Let ⟨ℎ, ⟩∈N be the first set-theoretic approximating sequence of a given  ∈ R0 ,
Then it holds that
ℎ ̸⊆ ℎ


and</p>
        <p>R(ℎ ∪ ℎ) ⩽ .</p>
        <p>R(︀ ℎ
+N(ℎ))︀ ⩾ R(ℎ ∪ ℎ).</p>
        <p>of the following N(ℎ) sets
Proof. If, for contradiction, (5) were false, we would have ℎ ̸⊆ ℎ+N(ℎ). Hence, the N-codes

ℎ, +1, ℎ, +2, . . . , ℎ, +N(ℎ)</p>
        <sec id="sec-3-6-1">
          <title>N-code greater than 0 and less than N(ℎ).</title>
          <p>in the sequence ⟨ℎ, ⟩∈N would be pairwise distinct, non-null, and strictly less than N(ℎ).
However, this is impossible, as there are at most N(ℎ) − 1 pairwise distinct h.f. sets with
3.2. Convergence of First Approximating Sequences
Consider the limit set ℎ∞ = ⋃︀</p>
        </sec>
        <sec id="sec-3-6-2">
          <title>R-code to the (possibly infinite) set</title>
          <p>∈N ℎ of ⟨ℎ, ⟩∈N (and of ⟨ℎ ⟩∈N). We extend the notion of
ℎ∞ by putting
∈N
R(ℎ∞) = ∑︁ R(ℎ, ) = lim R(ℎ ).</p>
          <p>→∞
In other words, the code of the limit set ℎ∞ is defined as the limit of the codes of the components
of ⟨ℎ ⟩∈N, thus generalising property v) of Lemma 3.5. Clearly, the interesting case arises when
ℎ∞ is infinite, and the natural question to ask is whether we can prove that R(ℎ∞) =  . This

will be our task in the current section.</p>
          <p>The following lists of sets will be very useful for the purpose:
(5)
(6)
• super-singletons , defined as:</p>
          <p>, defined as:
• sets of  super-singletons 
and  = {∅} = {− 1}, for  ∈ N+;</p>
          <p>,, defined as:
• sets of  sets of  super-singletons</p>
          <p>= {, +1, . . . , +− 1};
, = {, +1, . . . , +− 1}.</p>
          <p>Next, let Ω be the (unique) real solution to the equation  = 2− , which turns out to have
the approximate value 0.6411857...; then, the following approximation results hold:
i) the limit of the codes of super-singletons is Ω;
ii) the limit of the codes of sets of  super-singletons is Ω;
iii) the limit of the codes of sets of  sets of  super-singletons is Ω.</p>
          <p>
            The first limit follows from the following result, whose proof can be carried out along the
same lines of the proof of Theorem 4 in [
            <xref ref-type="bibr" rid="ref6">6</xref>
            ]:
Lemma 3.8. The sequences ⟨R(2)⟩∈N and ⟨R(2+1)⟩∈N are strictly increasing and strictly
decreasing, respectively, and they both converge to Ω. Hence, lim→∞ R() = Ω.
          </p>
        </sec>
      </sec>
      <sec id="sec-3-7">
        <title>The limits ii) and iii) are proved in the following two lemmas.</title>
        <p>Lemma 3.9. lim→∞ R() = Ω, for all  ∈ N.
Proof. If  ∈ N+, then for all  ∈ N we have</p>
        <p>R() = R({, +1, . . . , +− 1})</p>
      </sec>
      <sec id="sec-3-8">
        <title>Hence,</title>
        <p>On the other hand, if  = 0 then 0 = ∅, for all  ∈ N, and therefore</p>
        <p>lim R() = ∑︁ lim R(+) = ∑︁ Ω = Ω.
→∞ =1 →∞ =1
lim R(0 ) = lim R(∅) = 0.</p>
        <p>→∞ →∞
Hence, the thesis follows for all  ∈ N.</p>
        <p>,) = Ω, for all ,  ∈ N.</p>
        <p>Lemma 3.10. lim→∞ R(
= R({}) + R({+1}) + · · · + R({+− 1}) = ∑︁ R(+).
=1

Proof. If  ∈ N+, then for all  and  in N we have</p>
        <p>R(
,) = R({ , +1, . . . , +− 1})</p>
        <p>Hence, by Lemma 3.9 and recalling that Ω = 2− Ω, we have:
= R({}) + R({+1}) + · · ·

+ R({+− 1}) = ∑︁ 2− R(+).</p>
        <p>On the other hand, if  = 0 then</p>
        <p>,0 = ∅, for all  and  in N, and therefore
→∞
lim R(,0) = lim R(∅) = 0.</p>
        <p>→∞</p>
        <p>Next, after recalling when a set of positive reals is dense in R+, we prove that the set
Hence, the thesis follows for all ,  ∈ N.
{Ω | ,  ∈ N} is dense in R+.</p>
        <p>Definition 11.
such that | − | &lt; .</p>
        <p>A set  ⊆ R+ is dense in R+, if for all  ∈ R+ and  ∈ R+ there exists  ∈ 
exists  ∈ N such that:
Lemma 3.11. For every 0 ∈ N, the set 0 = {Ω0+ | ,  ∈ N} is dense in R+.
Proof. Let 0 ∈ N. To see that 0 is dense in R+, let  and  be any positive reals. Then, there
0 ⩽  −
⌊ Ω− 0− 
Ω− 0− 
⌋ &lt; .
and since 0 ⩽  Ω− 0−  − ⌊  Ω− 0− ⌋ &lt; 1, we have
In fact, it is enough to take  ∈ N such that Ω0+ ⩽  (we recall that Ω ≈ 0.6411857 &lt; 1),
Ω− 0− 
0 ⩽
 Ω− 0−</p>
        <p>− ⌊  Ω− 0− ⌋ &lt; Ω0+ ⩽ .
dense in R+.</p>
        <p>Hence, putting  = ⌊ Ω− 0− ⌋, we have 0 ⩽  − Ω0+ &lt; , proving that the set 0 is
Lemma 3.12. The R-code of the cumulus ℎ∞ = ⋃︀  = ⋃︀
approximating sequence ⟨ℎ, ⟩∈N of a given  ∈ R0+∈isNeℎqual to  , i.e.,
∈N ℎ, of the first set-theoretic</p>
        <p>R(ℎ∞) = .
holds trivially.</p>
        <p>Proof. In view of (6), it is enough to show that lim→∞ R(ℎ ) =  .</p>
        <p>If R(ℎ0 ) =  for some 0 ∈ N, then ℎ = ℎ0 for all  ⩾ 0, and so lim→∞ R(ℎ ) = 

Thus, let us assume that we have R(ℎ ) &lt;  for all  ∈ N.</p>
        <p>We intend to show the existence of a function  : N → N such that the following inequalities
() &gt; 
and</p>
        <p>R(ℎ ) + 
2
&lt; R(ℎ
()) &lt; 
are verified for all  ∈ N.
 ′ =  − R(ℎ ). Then, from Lemma (3.11) there exist  ⩾ 0 and  ∈ N+ such that</p>
        <p>Thus, let  be any natural number in N and consider the set ℎ , and let 0 = rk(ℎ ) and
In addition, from Lemma (3.10) there exists  ∈ N such that
5 ′
8
&lt; Ω &lt;
7 ′
8</p>
        <p>.
|R(
,) − Ω| &lt;
 ′
8
.</p>
        <p>Since  &lt;  , we have
⎩
 +</p>
        <p>2
⎧⎨0 = R(ℎ0) &lt; 
&lt; +1 &lt; ,
 =  +  &lt;  + 
&lt; +1, for  ∈ N.</p>
        <p>(7)
(8)
Hence,  ′ &lt;
R(ℎ ∪ 
2 ,) = R(ℎ ) + R(</p>
        <p>,) and so
,) &lt;  ′, and since  ⩾ rk(ℎ ) we have 
,
∩ ℎ = ∅ too. Thus,
R(ℎ ) +</p>
        <p>2</p>
      </sec>
      <sec id="sec-3-9">
        <title>Therefore, by Lemma (3.7), we have</title>
        <p>′
2
= R(ℎ ) +
&lt; R(ℎ ∪</p>
        <p>,) &lt; R(ℎ ) +  ′ = .</p>
        <p>R(ℎ ) + 
2
&lt; R(ℎ ∪ 
,) ⩽ R ℎ</p>
        <p>︁(
+N(
,))︁</p>
        <p>&lt; .</p>
        <p>,), it is immediate to check that the sought-after inequalities (7)
hold.</p>
        <p>By letting () =  + N(
following recurrence:</p>
        <p>Using the function  : N → N just defined, we can set forth a sequence ⟨⟩∈N obeying the
{︃ 0 = 0</p>
        <p>+1 = () , for  ∈ N.
lim→∞ R(ℎ) =  .</p>
        <p>Letting  = R(ℎ) for  ∈ N, we have:
Next, let us consider the subsequence ⟨</p>
        <p>ℎ⟩∈N of the cumulative sequence ⟨ℎ ⟩∈N. As is
plain, lim→∞ R(ℎ) = lim→∞ R(ℎ ), hence to complete the proof it sufices to show that
Thus, the sequence ⟨⟩∈N is strictly increasing and bounded above by  , and so it converges.</p>
      </sec>
      <sec id="sec-3-10">
        <title>Letting r be its limit, by (8) we have</title>
        <p>r ⩽
3.3. On the Existence of HF1-Approximations</p>
      </sec>
      <sec id="sec-3-11">
        <title>We now state our final result and highlight its proof:</title>
        <p>any  ∈ R0+ is the code of some set in HF1.</p>
        <p>Proposition 3.13. For every  ∈ R0+, there exists ℏ ∈ HF1 such that</p>
        <p>R(ℏ) = .</p>
        <p>Proof sketch. Given  ∈ R0+, we provide a (possibly infinite) procedure to build a set ℏ ∈ HF1
such that R(ℏ ) =  .</p>
        <p>If  = 0, then R(∅) = 0, and we are done. Otherwise, if  ∈ R+, let ⟨ℎ, ⟩∈N be the first
set-theoretic approximation for  , ⟨ℎ ⟩∈N be its cumulative variant.</p>
        <p>We define two (possibly finite) sequences</p>
        <p>and
of positive reals and related indices, respectively, by putting:</p>
        <p>-  0 =  ,
and, for  ∈ N,
-  +1 = − log(  − R(ℎ )),
where  is the least integer in N such that:
•   − R(ℎ ) ⩽ 1 and
• for all  ⩽ , it holds that   − R(ℎ ) ̸= R(ℎ , ),
provided that   − R(ℎ ) ̸= 0 ; otherwise  +1 is not defined and the sequences are
terminated.8</p>
        <sec id="sec-3-11-1">
          <title>8Plainly, ⟨ℎ  ⟩∈N is the cumulative set-theoretic approximating sequence for  .</title>
          <p>When the sequences (9) are finite, say equal to ⟨ 0,  1, . . . ,  ⟩ and to ⟨0, 1, . . . , ⟩
for some  ∈ N, respectively, we put</p>
        </sec>
      </sec>
      <sec id="sec-3-12">
        <title>It can be shown that</title>
        <p>for  = 0, 1, . . . , . Hence,
{︃ = ℎ ,</p>
        <p>= ℎ ∪ ︀{ +1︀} , for  &lt; .
 ∈ HF
and</p>
        <p>R( ) =   ,</p>
        <p>R(0) =  0 = .</p>
        <p>In the case in which the sequences (9) are infinite, we need to step into the universe HF1. Let
us consider the infinite set system
Letting ⟨ℏ⟩∈N be the solution in HF1 of (10), we have
 = ℎ ∪ {+1} ,</p>
      </sec>
      <sec id="sec-3-13">
        <title>This is a consequence of the following facts:</title>
        <p>• We can build an infinite sequence 0 ⊂  1 ⊂ · · · ⊂   ⊂ · · · of finitely-branching finite
trees, where  can be seen as the picture of the hereditarily finite set ℏ, truncated by
replacing ℏ+1 by ∅ in the definition of ℏ.</p>
        <p>The limit for  that goes to infinity of  is a picture  of ℏ0 (including pictures of ℏ, for
 &gt; 0).
• Every finite system of set-theoretic equations induced by , for  ⩾ 0, introduces also
hereditarily finite sets, ℏ, for 0 &lt;  ⩽  ⩽ , that are increasingly more complete
set-theoretic approximations of ℏ, for  ⩽ .</p>
        <p>• The codes R(ℏ ), for  ⩽ , approximate  . That is lim→∞ R(ℏ ) =  .</p>
      </sec>
    </sec>
    <sec id="sec-4">
      <title>4. Conclusions</title>
      <p>
        In this paper we investigated a sort of set-theoretic counterpart of the apparatus (as called by
Khinchin in [
        <xref ref-type="bibr" rid="ref8">8</xref>
        ]) of continued fractions. Instrumental in establishing a parallel between the
continued fraction approach to denote real numbers is the notion of the code R, which assigns
a real number to every hyperset in HF1.
      </p>
      <p>The two, rather initial, results we proved are the possibility of capturing every positive real
 as the code of an infinite set  of hereditarily sets, and — building on the previous result —
the fact that there exists ℏ ∈ HF1 such that R(ℏ) =  .</p>
      <p>The approximation defined here as “first” is, in fact, coarser than necessary — and hence
not “best”. E.g., consider the case of ℎ ∈ HF, N(ℎ) even, and  = R(ℎ) &gt; 1. According to
Definition 10, ℎ, 0 = {∅} will be a subset of the first HF1-approximation of  : this prevents the
possibility of producing ℎ as a (correct) set-theoretic approximation of  , since ∅ ∈/ ℎ follows
from the fact that N(ℎ) is even.</p>
      <p>There are still many intriguing questions that are yet to be answered, including the following:
Open Question (Recurrence).</p>
      <p>Can we find a recursive relation providing the hereditarily finite set
hereditarily finite sets ℎ−− 11 , ℎ−− 22 , in case  is infinite?
ℎ in terms of previous</p>
      <p>
        The sketched proof of Proposition 3.13 bears a strong similarity with the proof of the
construction of a (regular) continued fraction for a given real number. A positive answer to the
above question would provide a recurrence relation that could be seen as the set-theoretic
counterpart of what Khinchin calls “the rule for the formation of the convergents” (mentioned
in Section 2.1, see also Theorem 1 in [
        <xref ref-type="bibr" rid="ref8">8</xref>
        ]):
 = − 1 + − 2,
 = − 1 + − 2.
      </p>
    </sec>
  </body>
  <back>
    <ref-list>
      <ref id="ref1">
        <mixed-citation>
          [1]
          <string-name>
            <given-names>A.</given-names>
            <surname>Policriti</surname>
          </string-name>
          ,
          <article-title>Encodings of sets and hypersets</article-title>
          ,
          <source>in: Proceedings of the 28th Italian Conference on Computational Logic</source>
          , Catania, Italy,
          <source>September 25-27</source>
          ,
          <year>2013</year>
          ,
          <year>2013</year>
          , pp.
          <fpage>235</fpage>
          -
          <lpage>240</lpage>
          . URL: http://ceur-ws.
          <source>org/</source>
          Vol-
          <volume>1068</volume>
          /paper-s02.
          <fpage>pdf</fpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref2">
        <mixed-citation>
          [2]
          <string-name>
            <given-names>W.</given-names>
            <surname>Ackermann</surname>
          </string-name>
          , Die Widerspruchfreiheit der allgemeinen Mengenlehre,
          <source>Mathematische Annalen</source>
          <volume>114</volume>
          (
          <year>1937</year>
          )
          <fpage>305</fpage>
          -
          <lpage>315</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref3">
        <mixed-citation>
          [3]
          <string-name>
            <given-names>D.</given-names>
            <surname>Cantone</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            <surname>Policriti</surname>
          </string-name>
          ,
          <article-title>Squeezing multisets into real numbers</article-title>
          ,
          <source>Rend. Istit. Mat. Univ. Trieste</source>
          <volume>53</volume>
          (
          <year>2021</year>
          )
          <fpage>1</fpage>
          -
          <lpage>32</lpage>
          . doi:
          <volume>10</volume>
          .13137/
          <fpage>2464</fpage>
          -8728/33312, electronic: Article 26.
        </mixed-citation>
      </ref>
      <ref id="ref4">
        <mixed-citation>
          [4]
          <string-name>
            <given-names>J.</given-names>
            <surname>Barwise</surname>
          </string-name>
          ,
          <string-name>
            <given-names>J.</given-names>
            <surname>Etchemendy</surname>
          </string-name>
          ,
          <source>The Liar: An Essay on Truth and Circularity</source>
          , Oxford, England and New York, NY, USA: Oxford University Press USA,
          <year>1987</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref5">
        <mixed-citation>
          [5]
          <string-name>
            <given-names>P.</given-names>
            <surname>Aczel</surname>
          </string-name>
          ,
          <string-name>
            <surname>Non-Well-Founded</surname>
            <given-names>Sets</given-names>
          </string-name>
          , volume
          <volume>14</volume>
          <source>of CSLI Lecture Notes</source>
          , Stanford: CSLI Publications, Stanford, CA,
          <year>1988</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref6">
        <mixed-citation>
          [6]
          <string-name>
            <given-names>D.</given-names>
            <surname>Cantone</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            <surname>Policriti</surname>
          </string-name>
          ,
          <article-title>Encoding sets as real numbers</article-title>
          , in: M.
          <string-name>
            <surname>Cristiá</surname>
            ,
            <given-names>D.</given-names>
          </string-name>
          <string-name>
            <surname>Delahaye</surname>
            ,
            <given-names>C.</given-names>
          </string-name>
          Dubois (Eds.),
          <source>Proceedings of the 3rd International Workshop on Sets and Tools (SETS</source>
          <year>2018</year>
          ), volume
          <volume>2199</volume>
          ,
          <source>CEUR Workshop Proceedings, ISSN 1613-0073</source>
          ,
          <year>2018</year>
          , pp.
          <fpage>2</fpage>
          -
          <lpage>16</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref7">
        <mixed-citation>
          [7]
          <string-name>
            <given-names>E. G.</given-names>
            <surname>Omodeo</surname>
          </string-name>
          ,
          <string-name>
            <given-names>A.</given-names>
            <surname>Policriti</surname>
          </string-name>
          ,
          <string-name>
            <surname>A. I. Tomescu</surname>
          </string-name>
          ,
          <source>On Sets and Graphs. Perspectives on Logic and Combinatorics</source>
          , Springer,
          <year>2017</year>
          .
        </mixed-citation>
      </ref>
      <ref id="ref8">
        <mixed-citation>
          [8]
          <string-name>
            <given-names>A. Y.</given-names>
            <surname>Khinchin</surname>
          </string-name>
          , Continued Fractions, Phoenix Books, The Univ. of Chicago Press,
          <year>1964</year>
          .
        </mixed-citation>
      </ref>
    </ref-list>
  </back>
</article>