=Paper= {{Paper |id=Vol-3733/paper15 |storemode=property |title=Some Decidability Issues Concerning C^n Real Functions |pdfUrl=https://ceur-ws.org/Vol-3733/paper15.pdf |volume=Vol-3733 |authors=Gabriele Buriola,Domenico Cantone,Gianluca Cincotti,Eugenio Omodeo,Gaetano SpartΓ  |dblpUrl=https://dblp.org/rec/conf/cilc/BuriolaCCOS24 }} ==Some Decidability Issues Concerning C^n Real Functions== https://ceur-ws.org/Vol-3733/paper15.pdf
                         Some decidability issues concerning 𝐢 𝑛 real functions
                         Gabriele Buriola1,* , Domenico Cantone2 , Gianluca Cincotti2 , Eugenio G. Omodeo3 and
                         Gaetano T. SpartΓ 4
                         1
                           Dept. of Computer Science, University of Verona, Italy
                         2
                           Dept. of Mathematics and Computer Science, University of Catania, Italy
                         3
                           Dept. of Mathematics, Informatics and Geosciences, University of Trieste, Italy
                         4
                           Pontifical Gregorian University, Rome, Italy


                                      Abstract
                                      This paper adapts preexisting decision algorithms to a family β„›π’Ÿβ„± = {RDF𝑛 | 𝑛 ∈ N} of languages regarding
                                      one-argument real functions; each RDF 𝑛 is a quantifier-free theory about the differentiability class 𝐢 𝑛 , embodying
                                      a fragment of Tarskian elementary algebra. The limits of decidability are also highlighted, by pointing out that
                                      certain extensions of RDF 𝑛 are undecidable. The possibility of extending RDF 𝑛 into a language RDF ∞ regarding
                                      the class 𝐢 ∞ , without disrupting decidability, is briefly discussed.
                                          Two sorts of individual variables, namely real variables and function variables, are available in each RDF 𝑛 .
                                      The former are used to construct terms and formulas that involve basic arithmetic operations and comparison
                                      relators between real terms, respectively. In contrast, terms designating functions involve function variables,
                                      constructs for addition of functions and scalar multiplication, andβ€”outermost—𝑖-th order differentiation 𝐷𝑖 [ ]
                                      with 𝑖 β©½ 𝑛. An array of predicate symbols designate various relationships between functions, as well as function
                                      properties, that may hold over intervals of the real line; those are: function comparisons, strict and non-strict
                                      monotonicity / convexity / concavity, comparisons between a function (or one of its derivatives) and a real term.
                                          The decidability of RDF 𝑛 relies, on the one hand, on Tarski’s celebrated decision algorithm for the algebra
                                      of real numbers, and, on the other hand, on reduction and interpolation techniques. An interpolation method,
                                      specifically designed for the case 𝑛 = 1, has been previously presented; another method, due to Carla Manni, can
                                      be used when 𝑛 = 2. For larger values of 𝑛, further research on interpolation is envisaged.
                                      MS Classification 2020: 03B25, 26A06, 20F10.

                                      Keywords
                                      Decidable theories, Tarski’s elementary algebra, Functions of a real variable




                         Introduction
                         This paper addresses the decision problem for a fragment of real analysis exploiting the renowned
                         decidability result for elementary real algebra due to Tarski [22, 23]. The Tarskian algebra being referred
                         to here is the first-order theory of the ordered field (R, 0, 1, +, Β·, =, β©½) of real numbers: within its
                         context, unlike with other first-order theories about numerical domainsβ€”most prominent, among those,
                         the Dedekind–Peano integer arithmetic (see, e.g., [16, Chapter 3])β€”, an algorithm can establish whether
                         or not any given sentence is true. This motivates one in seeking extensions of elementary real algebra
                         where this decidability result is preserved: e.g., the decidability of Tarskian algebra enriched with the
                         exponential function resists, since long, as an unsolved issue [14]. We undertook years ago a systematic
                         study on enhancements of the Tarskian language, or fragments thereof, endowed with provisions
                         regarding real functions.
                            The language, dubbed RDF 𝑛 , to be discussed in this paper is devoid of quantifiers but embodies,
                         in addition to the algebraic operators and relators, predicate symbols expressing strict and nonstrict

                          CILC 2024: 39th Italian Conference on Computational Logic, June 26–28, 2024, Rome, Italy
                         *
                           Corresponding author.
                          $ gabriele.buriola@univr.it (G. Buriola); domenico.cantone@unict.it (D. Cantone); cincotti@dmi.unict.it (G. Cincotti);
                          eomodeo@units.it (E. G. Omodeo); g.sparta@unigre.it (G. T. SpartΓ )
                          Β€ https://www.dmi.unict.it/cantone (D. Cantone); https://sites.units.it/eomodeo/index.html/ (E. G. Omodeo)
                           0000-0002-1612-0985 (G. Buriola); 0000-0002-1306-1166 (D. Cantone); 0000-0001-8460-1708 (G. Cincotti);
                          0000-0003-3917-1942 (E. G. Omodeo); 0000-0002-8993-5851 (G. T. SpartΓ )
                                   Β© 2024 Copyright for this paper by its authors. Use permitted under Creative Commons License Attribution 4.0 International (CC BY 4.0).




CEUR
                  ceur-ws.org
Workshop      ISSN 1613-0073
Proceedings
monotonicity, concavity, and convexity of 𝐢 𝑛 functions of one real variable, as well as strict and
non-strict comparisons β€˜>’ and β€˜β©Ύβ€™ between functions, over bounded or unbounded intervals. Further
primitive constructs available in the language are: operators designating pointwise addition of functions,
multiplication of a function by a scalar, and differentiation operators (up to the 𝑛-th derivative).1 We
reduce the satisfiability problem regarding the formulas of RDF 𝑛 to the truth problem for purely
existential sentences of the elementary algebra of reals; we can thus rely upon improved versions of
Tarski’s original method.2
   This paper is a sequel of [2] and [1]β€”hence, indirectly, of their antecedents [3, 5, 8]. As for semantics,
RDF 𝑛 deals with functions endowed with continuous derivatives (up to the 𝑛-th order): in consequence
of this, a satisfiable RDF π‘š formula might cease to be satisfiable in RDF 𝑛 when π‘š < 𝑛.3 Our present
language RDF 𝑛 differs from the language RDF * studied in [1] in that its syntax is richer: now we
have a batch of differentiation constructs only one of which was available in RDF * ; this calls for an
enhancement of the decision algorithm, to wit, an enhanced reduction to Tarskian algebra.
   Another novelty of the subject matter of this paper, with respect to its antecedents, is greater attention
bestowed to assessing where the boundary between decidable and undecidable fragments of analysis
precisely lies.
   The ongoing is organized as follows. In Sec. 1, we introduce syntax and semantics of the language of
interest, and illustrate its expressive power through a gallery of small examples. Before providing the
detailed specification of our decision algorithm in Sec. 3, in Sec. 2 we exemplify its use by manually
working out an emulation of how it would process a specific, valid formula. Then Sec. 4 provides clues
on the correctness of the proposed decision algorithm, specifying the role of an ad hoc interpolation
method. Sec. 5 explores the other side of the problem in asking which further enrichments lead to
undecidability. To end, we outline possible connections with related work, and draw conclusions.4


1. The interpreted RDF 𝑛 language
The augmented version RDF 𝑛 of the theory RDF * of Reals with Differentiable Functions [1] is an
unquantified first-order theory dealing with reals and with real functions of class 𝐢 𝑛 of one real
variable, namely functions with continuous 𝑛-th derivative. The function symbols of RDF 𝑛 designate
the basic operations of real arithmetic and pointwise addition, scalar multiplication, and differentiation
(up to the 𝑛th order) of functions. Its predicate symbols designate: comparisons between reals, pointwise
comparisons of functions; strict and non-strict monotonicity, convexity, and concavity; comparisons
between functions, and comparison between their derivatives (up to the 𝑛-th order), and real terms.
   This section introduces the language underlying RDF 𝑛 , explains the intended meanings of its con-
structs, and briefly illustrates its use.

                                                 Syntax and semantics
The language RDF 𝑛 has two infinite supplies of individual variables, belonging to the respective sorts:
numerical variables π‘₯, 𝑦, 𝑧, . . . and function variables 𝑓, 𝑔, β„Ž, . . . Numerical and function variables are
supposed to range, respectively, over the set R of real numbers and over the collection of functions
which interests us. Four constants are also available:

     β€’ the symbols 0 and 1;

     β€’ the distinguished symbols +∞ and βˆ’βˆž, occurring as ends of interval specifications (see below).
1
  Usage of the differentiation operators 𝐷𝑖 [ ] must be reasonably restrained, e.g., each of them can only appear as lead operator
  in a function term g (which will then coincide with a term of the form 𝐷[ f ]).
2
  To make an example, polynomial methods for existential formulas with a fixed number of variables are available [19].
3
  Partial evidence of this emerges from an example provided in [1, p. 128].
4
  To ease the comparison between RDF 𝑛 and similar previous theories, mainly RDF + and RDF * , the first three sections follow
  much the same structure as the companion papers [2] and [1].
      We next specify the syntax of terms, atoms, and formulas for RDF 𝑛 .

Definition 1.1. Function terms, numerical terms, and interval specs are so defined:

     a.1) Function variables are function terms;

     a.2) if f and g are function terms, then f + g is a function term;

     a.3) if f is a function term, then any β€œscalar multiple” 𝑠 f, with 𝑠 a numerical term, is a function term.

     b.1) Numerical variables and the constants 0, 1 are numerical terms;

     b.2) if 𝑠 and 𝑑 are numerical terms, the following also are numerical terms:

                                                       𝑠+𝑑,       π‘ βˆ’π‘‘,           and 𝑠 Β· 𝑑 ;

     b.3) if 𝑑 is a numerical term, 𝛼 a natural number between 1 and 𝑛, and f is a function term, then

                                                          f(𝑑)         and     𝐷𝛼 [f](𝑑)

           are numerical terms.5

     c.1) An interval spec 𝐴 is an expression of any of the forms

                                        [𝑒1 , 𝑒2 ] ,    [𝑒1 , 𝑒2 [ ,     ]𝑒1 , 𝑒2 ] ,   and    ]𝑒1 , 𝑒2 [ ,

           where 𝑒1 stands for either a numerical term or βˆ’βˆž, and 𝑒2 for either a numerical term or +∞;

     c.2) we dub the β€œextended” numerical terms 𝑒1 , 𝑒2 of such an 𝐴 the ends of 𝐴 .                                          ⊣

   Throughout, f and g stand for function terms, 𝑠 and 𝑑 for numerical terms, and 𝐴 stands for an
interval spec.

Definition 1.2. An atom of RDF 𝑛 is an expression of one of the forms

                          𝑠 = 𝑑,                𝑠 > 𝑑,                      f(𝑠) = 𝑑,               𝐷𝛼 [f](𝑠) = 𝑑,
                      (f = g)𝐴 ,            (f > g)𝐴 ,                     (f ◁▷ 𝑑)𝐴 ,             (𝐷𝛼 [f] ◁▷ 𝑑)𝐴 ,
                        Up(f)𝐴 ,           Down(f)𝐴 ,                    Convex(f)𝐴 ,              Concave(f)𝐴 ,
                     S_Up(f)𝐴 ,          S_Down(f)𝐴 ,                  S_Convex(f)𝐴 ,            S_Concave(f)𝐴 ,

where ◁▷ ∈ {=, <, >, β©½, β©Ύ } and 𝛼 is a natural number between 1 and 𝑛.                                                        ⊣

Definition 1.3. A formula of RDF 𝑛 is any truth-functional combination of RDF 𝑛 atoms.                                        ⊣

  For definiteness, we will construct the RDF 𝑛 formulas from RDF 𝑛 atoms by means of the usual
propositional connectives Β¬, ∧, ∨, β†’, ↔.
  The semantics of RDF 𝑛 revolves around the designation rules listed in our next definition, with which
any truth-value assignment for the formulas of RDF 𝑛 must comply.

Definition 1.4. An assignment for RDF 𝑛 is a mapping 𝑀 whose domain consists of all terms and
formulas of RDF 𝑛 , satisfying the following conditions:

       0. 𝑀 0 and 𝑀 1 are the real numbers 0 and 1.
5
    As for the syntax, the availability of 𝐷𝛼 [ ] with 𝛼 > 1 is the only novelty with respect to [1]. We will signal in the body
    of the decision algorithm which changes this enrichment entails. The true challenge, with this enrichment, is the need to
    redesign the algorithm correctness proof.
       1. For each numerical variable π‘₯, 𝑀 π‘₯ is a real number.

       2. For each function variable 𝑓 , (𝑀 𝑓 ) is an everywhere defined real function of one real variable
          of class 𝐢 𝑛 , i.e., with all the first 𝑛-th derivatives continuous.
                                                                        (οΈ€     )οΈ€
       3. For each function term of the form f + g, the image 𝑀 (f + g) (π‘Ÿ) of any real number π‘Ÿ is
          (𝑀 f)(π‘Ÿ) + (𝑀 g)(π‘Ÿ).

       4. For each function term    )οΈ€ form 𝑠 f, the function 𝑀 (𝑠 f) is
                             (οΈ€ of the                                 (οΈ€ defined )οΈ€to be 𝑀𝑠 (𝑀 f).
          Namely, the image 𝑀 (𝑠 f) (π‘Ÿ) of any real number π‘Ÿ is 𝑀𝑠 (𝑀 f)(π‘Ÿ) .

       5. For each numerical term of the form 𝑑1 βŠ— 𝑑2 with βŠ— ∈ {+, βˆ’, Β·}, 𝑀 (𝑑1 βŠ— 𝑑2 ) is the real number
          𝑀 𝑑1 βŠ— 𝑀 𝑑2 .

       6. For each numerical term of the form f(𝑑), 𝑀 (f(𝑑)) is the real number (𝑀 f)(𝑀 𝑑); for each
          numerical term 𝐷𝛼 [f](𝑑), 𝑀 (𝐷𝛼 [f](𝑑)) is the real number 𝐷𝛼 [(𝑀 f)](𝑀 𝑑), where 𝐷𝛼 [(𝑀 f)]
          denotes the 𝛼-th derivative of (𝑀 f).

       7. For each interval specification 𝐴, 𝑀 𝐴 is an interval of R of the appropriate kind, whose endpoints
          are the evaluations via 𝑀 of the ends of 𝐴.6
          For example, when 𝐴 = ]𝑑1 , 𝑑2 ], then 𝑀 𝐴 = ]𝑀 𝑑1 , 𝑀 𝑑2 ].

       8. Truth values are assigned to formulas of RDF 𝑛 according to the following rules, where 𝑠 and 𝑑
          stand for numerical terms and f, g for function terms:
             a) 𝑠 = 𝑑 (respectively 𝑠 > 𝑑) is true iff 𝑀 𝑠 = 𝑀 𝑑 (resp. 𝑀 𝑠 > 𝑀 𝑑) holds;
             b) (f = g)𝐴 is true iff (𝑀 f)(π‘₯) = (𝑀 g)(π‘₯) holds for all π‘₯ in 𝑀 𝐴;
             c) (f > g)𝐴 is true iff (𝑀 f)(π‘₯) > (𝑀 g)(π‘₯) holds for all π‘₯ in 𝑀 𝐴;
             d) (f ◁▷ 𝑑)𝐴 , with ◁▷ ∈ {=, <, >, β©½, β©Ύ}, is true iff (𝑀 f)(π‘₯) ◁▷ 𝑀 𝑑 holds for all π‘₯ in 𝑀 𝐴;
             e) (𝐷[f] ◁▷ 𝑑)𝐴 , with ◁▷ ∈ {=, <, >, β©½, β©Ύ}, is true iff 𝐷[(𝑀 f)](π‘₯) ◁▷ 𝑀 𝑑 holds for all π‘₯ in
                𝑀 𝐴;
              f) Up(f)𝐴 (respectively S_Up(f)𝐴 ) is true iff (𝑀 f) is a monotone nondecreasing (resp. strictly
                 increasing) function in 𝑀 𝐴;
             g) Convex(f)𝐴 (respectively S_Convex(f)𝐴 ) is true iff (𝑀 f) is a convex (resp. strictly convex)
                function in 𝑀 𝐴;
             h) the truth values of Down(f)𝐴 , Concave(f)𝐴 , S_Down(f)𝐴 , and S_Concave(f)𝐴 are defined
                in close analogy with items f) and g);
              i) the truth value which 𝑀 assigns to a formula whose lead symbol is any of Β¬, ∧, ∨, β†’, ↔
                 complies with the usual semantics of the propositional connectives.

      An assignment 𝑀 is said to model a set Ξ¦ of formulas when 𝑀 πœ™ is true for every πœ™ in Ξ¦.                             ⊣

      Note that RDF 𝑛 coincides with RDF * (see [1]) when 𝑛 = 1.

Definition 1.5 (Derived symbols). In light of the above semantics, we tacitly enrich our language,
much as in [2], with derived dyadic and triadic comparators involving numerical terms 𝑑1 , 𝑑2 , and 𝑑3 ;
namely 𝑑1 ◁ 𝑑2 and 𝑑1 ◁▷ 𝑑2 /𝑑3 , where ◁ ∈ {ΜΈ=, <, β©½, β©Ύ} and ◁▷ ∈ {=, <, >, β©½, β©Ύ}.
  Additional relators intermixing function terms and numerical terms, e.g., the construct

                              Linear(𝑓 )𝐴        ↔Def      Concave(𝑓 )𝐴 ∧ Convex(𝑓 )𝐴 ,

can also be introduced by means of shortening definitions.                                                                ⊣
6
    It goes without saying what is meant when 𝑀 is undefined at either end of 𝐴 (actually, 𝑀 (βˆ’βˆž) and 𝑀 (+∞) are undefined).
                                               Some examples
Basic facts of real analysis stateable by means of RDF 𝑛 formulas, with 𝑛 > 1, are:

   β–Ά Linear(𝑓 )]βˆ’βˆž,+∞[ ↔ 𝐷2 [𝑓 ] = 0 ]βˆ’βˆž,+∞[ .
                                  (οΈ€        )οΈ€

    A function 𝑓 of class 𝐢 2 is linear if and only if its second derivative is constantly null.
    {οΈ€                [οΈ€
   β–Ά (π‘Ž < π‘₯ < 𝑏) ∧ (S_Convex(𝑓 )[π‘Ž,π‘₯] ∧ S_Concave(𝑓 )[π‘₯,𝑏] ) ∨
                                                       β†’ 𝐷2 [𝑓 ](π‘₯) = 0 .
                                                  ]οΈ€}οΈ€
       (S_Concave(𝑓 )[π‘Ž,π‘₯] ∧ S_Convex(𝑓 )[π‘₯,𝑏] )
     Let π‘₯ be an inflection point of a 𝐢 2 function 𝑓 , then the second derivative of 𝑓 in π‘₯ is null.
            [︁(οΈ€                                                  ]︁
                 π·π‘˜βˆ’1 [𝑓 ] = 𝑦 ]βˆ’βˆž,+∞[ β†’ π·π‘˜ [𝑓 ] = 0 ]βˆ’βˆž,+∞[ ∧
                              )οΈ€            (οΈ€           )οΈ€
   β–Ά
     {︁(οΈ€                                                                          ]οΈ€}︁
          π·π‘˜ [𝑓 ] = 0 ]βˆ’βˆž,+∞[ β†’ π·π‘˜βˆ’1 [𝑓 ](π‘₯) = 𝑦 β†’ π·π‘˜βˆ’1 [𝑓 ] = 𝑦 ]βˆ’βˆž,+∞[ .
                     )οΈ€              [οΈ€                     (οΈ€           )οΈ€

       Let 𝑓 be a function of class 𝐢 𝑛 , and π‘˜ an integer, 0 < π‘˜ β©½ 𝑛. Then the (π‘˜ βˆ’ 1)-st derivative of 𝑓
       is constant if and only if the π‘˜-th derivative of 𝑓 is null everywhere. (Note: π·π‘˜βˆ’1 [𝑓 ] stands for 𝑓
       when π‘˜ = 1.)
               {︁                             (οΈ€         )οΈ€                 }︁
   β–Ά             (π‘Ž < π‘₯ < 𝑏) ∧ 𝐷[𝑓 ](π‘₯) = 0 ∧ 𝐷2 [𝑓 ] β©Ύ 0 [π‘Ž,𝑏] ∧ 𝑓 (π‘₯) = 𝑦        β†’ (𝑓 β©Ύ 𝑦)[π‘Ž,𝑏] ;
               {︁                             (οΈ€         )οΈ€                 }︁
                 (π‘Ž < π‘₯ < 𝑏) ∧ 𝐷[𝑓 ](π‘₯) = 0 ∧ 𝐷2 [𝑓 ] β©½ 0 [π‘Ž,𝑏] ∧ 𝑓 (π‘₯) = 𝑦        β†’ (𝑓 β©½ 𝑦)[π‘Ž,𝑏] .

       Let 𝑓 be a function of class 𝐢 2 , whose first derivative vanishes at some point π‘₯ and whose second
       derivative is non-negative (resp., non-positive) all over a neighborhood [π‘Ž, 𝑏] of that π‘₯. Then
       π‘₯ is a relative minimum (resp., maximum) point for 𝑓 . Note that an analogous conclusion can
       be drawn about any function of class 𝐢 2π‘˜+2 , whose first, second, . . . , and (2π‘˜ + 1)-st derivative
       vanish at some point π‘₯ and whose (2π‘˜ + 2)-nd derivative is non-negative (resp., non-positive)
       all over a neighborhood [π‘Ž, 𝑏] of that π‘₯.

   β–Ά                    {οΈƒ
                             (π‘Ž < [︁π‘₯ < 𝑏) ∧ 𝐷[𝑓 ](π‘₯) = 0 ∧ 𝐷2 [𝑓 ](π‘₯) ]︁= 0 ∧
                                                                                  }οΈƒ
                                    (οΈ€ 3                                                β†’
                                      𝐷 [𝑓 ] < 0 [π‘Ž,𝑏] ∨ 𝐷3 [𝑓 ] > 0 [π‘Ž,𝑏]
                                                )οΈ€       (οΈ€         )οΈ€

                                    {οΈƒ (οΈ€                                          )οΈ€ }οΈƒ
                                            S_Convex(𝑓 )[π‘Ž,π‘₯] ∧ S_Concave(𝑓 )[π‘₯,𝑏] ∨
                                             (οΈ€                                        )οΈ€ .
                                                S_Concave(𝑓 )[π‘Ž,π‘₯] ∧ S_Convex(𝑓 )[π‘₯,𝑏]

       Let 𝑓 be a function of class 𝐢 3 , whose first and second derivative vanish at some point π‘₯,
       where the third derivative of 𝑓 assumes a nonzero value. Then π‘₯ is an inflection point of 𝑓 . (A
       generalized variant of this statement is left to the insightful reader.)


2. The decision algorithm at work
Establishing that an RDF 𝑛 formula πœ™ is valid is the same as establishing that its negation Β¬πœ™ is unsatis-
fiable; moreover, once Β¬πœ™ has been put in disjunctive normal form, satisfying it amounts to satisfying
one of its clauses. Thus, the core task regarding the decidability of RDF 𝑛 is: how to determine whether
or not a given conjunction of RDF 𝑛 literals (that is, RDF 𝑛 atoms and negations thereof) is satisfiable?

                                 Main steps of the decision algorithm
Via routinary flattening techniques, and in view of some basic properties of 𝐢 𝑛 functions, the said task
can be converted to the one of determining the satisfiability of an arbitrary conjunction πœ™0 of atoms of
the forms
               π‘₯=𝑦             ,                 π‘₯>𝑦      ,           𝑧 =π‘₯·𝑦       ,              𝑧 =π‘₯+𝑦         ,
            𝑦 = 𝑓 (π‘₯)          ,            (𝑓 > 𝑔)𝐴      ,         (𝑓 = 𝑧 𝑔)𝐴     ,           (β„Ž = 𝑓 + 𝑔)𝐴      ,
        𝑦 = 𝐷𝛼 [𝑓 ](π‘₯)         ,       (𝐷𝛼 [𝑓 ] ◁▷ 𝑧)𝐴    ,          S_Up(𝑓 )𝐴     ,           S_Down(𝑓 )𝐴       ,
          Convex(𝑓 )𝐴          ,        Concave(𝑓 )𝐴      ,      S_Convex(𝑓 )𝐴     ,         S_Concave(𝑓 )𝐴      ,

and of literals that are the complements of atoms of these forms involving an interval spec.7 As always,
π‘₯, 𝑦, 𝑧 stand for numerical variables and 𝑓, 𝑔, β„Ž stand for function variables.
   Through a possibly furcating process, πœ™0 will undergo a series πœ™0 ↝ πœ™1 ↝ πœ™2 ↝ πœ™3 ↝ πœ™4 = πœ™              Μ‚οΈ€ of
transformations, with no function variables occuring in the ending formula πœ™;    Μ‚οΈ€ thereby, the satisfiability
of πœ™
   Μ‚οΈ€ can be tested by means of Tarski’s renowned decision algorithm [23, 9]. With a slight, harmless
ambiguity we dub β€œour algorithm” at times our rewriting technique alone, and at times the entire
validity test consisting of it, preceded by various preparations (e.g., flattening), and supplemented with
Tarski’s decision method.
   The transformations πœ™π‘–βˆ’1 ↝ πœ™π‘– (𝑖 = 1, 2, 3, 4) aim to the following purposes:
       1. Behavior at the ends: For a thorough comparison between relevant values (e.g., the values of a
          derivative at the endpoints of specific open or semi-open intervals), we must divide each literal
          containing a function- or derivative-comparison into subcases, thus of either the form (𝑓 > 𝑔)𝐴
          or the form (𝐷𝛼 [𝑓 ] ◁▷ 𝑑)𝐴 , unless 𝐴 is a closed interval. By relying on function continuity, we
          split each such literal into a finite disjunction   covering all possible behaviors  at ends. E.g.,
          (𝐷𝛼 [𝑓 ] < 𝑑)[𝑣,𝑀[ becomes (𝐷𝛼 [𝑓 ] < 𝑑)[𝑣,𝑀] ∨ (𝐷𝛼 [𝑓 ] < 𝑑)[𝑣,𝑀[ βˆ§π·π›Ό [𝑓 ](𝑀) = 𝑑 .
                                                         (οΈ€                                 )οΈ€

       2. Negative clause removal: Each negative literal with an interval specification is replaced by an
          implicit existential assertion. E.g.,Β¬(𝑓 = 𝑔)[𝑣,𝑀] is replaced by 𝑣 β©½ π‘₯ β©½ 𝑀 ∧ 𝑓 (π‘₯) ΜΈ= 𝑔(π‘₯), where
          π‘₯ is a new variable.

       3. Explicit evaluation of function variables: With certain salient variables 𝑣𝑗 , dubbed β€œdomain
          variables” (e.g., the variable 𝑣 in 𝑓 (𝑣) = 𝑦), associate new variables 𝑦𝑗𝑓 , 𝑑1,𝑓          𝑛,𝑓
                                                                                         𝑗 , . . . , 𝑑𝑗 (one for each
           function variable 𝑓 ) subject to the constraints 𝑦𝑗𝑓 = 𝑓 (𝑣𝑗 ), 𝑑1,𝑓                      𝑛,𝑓
                                                                            𝑗 = 𝐷[𝑓 ](𝑣𝑗 ), . . . , 𝑑𝑗   = 𝐷𝑛 [𝑓 ](𝑣𝑗 ).
                          2
           E.g., if in RDF a formula involves one function variable 𝑓 and three domain variables 𝑣1 , 𝑣2 , 𝑣3
           altogether, then this step brings 9 new numerical variables in, along with 9 equations:

                                     𝑦1𝑓 = 𝑓 (𝑣1 ),     𝑑1,𝑓
                                                         1 = 𝐷[𝑓 ](𝑣1 ),    𝑑2,𝑓  2
                                                                             1 = 𝐷 [𝑓 ](𝑣1 ),
                                     𝑦2𝑓 = 𝑓 (𝑣2 ),     𝑑1,𝑓
                                                         2 = 𝐷[𝑓 ](𝑣2 ),    𝑑2,𝑓  2
                                                                             2 = 𝐷 [𝑓 ](𝑣2 ),
                                     𝑦3𝑓 = 𝑓 (𝑣3 ),     𝑑1,𝑓
                                                         3 = 𝐷[𝑓 ](𝑣3 ),    𝑑2,𝑓  2
                                                                             3 = 𝐷 [𝑓 ](𝑣3 ).

       4. Elimination of function variables: Get rid of all literals involving function variables, whose
          behaviours are already mimicked by the variables 𝑦𝑗𝑓 , 𝑑1,𝑓          𝑛,𝑓
                                                                  𝑗 , . . . , 𝑑𝑗   introduced above. This elimi-
          nation is obtained by introducing new number variables subject to suitable algebraic constraints.
                                                                                        𝑑1,𝑓  1,𝑓
          E.g., roughly speaking, (𝐷2 [𝑓 ] < 𝑠)[𝑣,𝑀] becomes 𝑑2,𝑓            2,𝑓
                                                              𝑣 < 𝑠 ∧ 𝑑𝑀 < 𝑠 ∧
                                                                                         𝑀 βˆ’π‘‘π‘£
                                                                                           π‘€βˆ’π‘£    < 𝑠.

                                                      A worked example
Our decision algorithm for RDF 𝑛 is specified in full in Sec. 3; here, to convey a feel of how it works, we
consider a paradigmatic formula πœ“ and carry out one by one the key transformations leading from πœ“ to
a formula directly submittable to Tarski’s algorithm for elementary real algebra.
   Suppose that we want to establish whether the formula

                                                                             β†’ 𝐷2 [𝑓 ](π‘₯) = 0,
           {οΈ€                                                            }οΈ€
             (π‘Ž < π‘₯ < 𝑏) ∧ S_Convex(𝑓 )[π‘Ž,π‘₯] ∧ S_Concave(𝑓 )[π‘₯,𝑏]
7
    Here again 𝛼 ∈ {1, . . . , 𝑛}.
dubbed πœ“ in the ongoing, is true under every value assignment; equivalently, we can check whether
its negation Β¬πœ“ is unsatisfiable. Using classical properties of implication, the negation amounts to the
following formula πœ™:

           (π‘Ž < π‘₯ < 𝑏) ∧ S_Convex(𝑓 )[π‘Ž,π‘₯] ∧ S_Concave(𝑓 )[π‘₯,𝑏] ∧ 𝐷2 [𝑓 ](π‘₯) ΜΈ= 0.

Then πœ™ undergoes the following transformations:

    1. Behavior at the ends: Generally speaking, function-comparison literals of the form (𝑓 > 𝑔)𝐴
       must be bestowed special care, possibly leading to a subcase analysis. Since no such literal
       appears in our πœ™, this phase produces πœ™1 := πœ™ .

    2. Negative
           (οΈ€ 2 clause removal:
                       )οΈ€         This phase removes negative literals with interval specifications,
                                                                                        (οΈ€ 2         )οΈ€such
       as Β¬ 𝐷 [𝑓 ] = 𝑦 [π‘Ž,𝑏] , substituting them with suitable witnesses; for example, Β¬ 𝐷 [𝑓 ] = 𝑦 [π‘Ž,𝑏]
       would be replaced by the following conjunction:

                                                 π‘Ž β©½ π‘₯ β©½ 𝑏 ∧ 𝐷2 [𝑓 ](π‘₯) = 𝑠 ∧ 𝑠 ΜΈ= 𝑦.

       Since the only negated literal in πœ™, 𝐷2 [𝑓 ](π‘₯) ΜΈ= 0, is pointwise, this phase produces πœ™2 := πœ™1 .

    3. Explicit evaluation of function variables: This phase introduces a new variable to designate each
       function-application term β„“(𝑣), where β„“ stands for a function variable of πœ™ and 𝑣 for one of its
       so-called β€˜domain’ variables. To describe evaluation more transparently, let us do the renaming:
       π‘Ž ↝ 𝑣1 , π‘₯ ↝ 𝑣2 , 𝑏 ↝ 𝑣3 . From the previous formula πœ™2 we get the following πœ™3 :

           (𝑣1 < 𝑣2 < 𝑣3 ) ∧            S_Convex(𝑓 )[𝑣1 ,𝑣2 ]    ∧   S_Concave(𝑓 )[𝑣2 ,𝑣3 ]       ∧ 𝐷2 [𝑓 ](𝑣2 ) ΜΈ= 0 ∧
                 𝑓 (𝑣1 ) = 𝑦1𝑓    ∧          𝑓 (𝑣2 ) = 𝑦2𝑓       ∧          𝑓 (𝑣3 ) = 𝑦3𝑓         ∧
           𝐷 [𝑓 ](𝑣1 ) = 𝑑𝑓1
             1
                                  ∧       𝐷 [𝑓 ](𝑣2 ) = 𝑑𝑓2
                                             1
                                                                 ∧     𝐷 [𝑓 ](𝑣3 ) = 𝑑𝑓3
                                                                            1
                                                                                                  ∧
           𝐷2 [𝑓 ](𝑣1 ) = 𝑠𝑓1     ∧       𝐷2 [𝑓 ](𝑣2 ) = 𝑠𝑓2     ∧     𝐷2 [𝑓 ](𝑣3 ) = 𝑠𝑓3         ∧      𝑠𝑓2 ΜΈ= 0.

    4. Elimination of function variables: This final phase removes all literals still containing function
       variables. We get rid of them by suitable replacements involving algebraic conditions, such as
       the difference quotient for literals regarding derivatives. At the end we obtain an equisatisfiable
       formula that can be tested for satisfiability by Tarski’s algorithm.
       From the previous formula πœ™3 we get the following final formula πœ™4 :

                                 (𝑣1 < 𝑣2 < 𝑣3 )             ∧   𝑠𝑓2 ΜΈ= 0        ∧
                                      𝑦2𝑓 βˆ’π‘¦1𝑓
                            𝑑𝑓1 <     𝑣2 βˆ’π‘£1     < 𝑑𝑓2       ∧   𝑠𝑓1 β©Ύ 0         ∧          𝑠𝑓2 β©Ύ 0    ∧
                                      𝑦3𝑓 βˆ’π‘¦2𝑓
                            𝑑𝑓2 >     𝑣3 βˆ’π‘£2     > 𝑑𝑓3       ∧   𝑠𝑓2 β©½ 0         ∧          𝑠𝑓3 β©½ 0.

In particular, the unsatisfiability of this last formula is given by the conjunction:

                                                 𝑠𝑓2 ΜΈ= 0 ∧ 𝑠𝑓2 β©Ύ 0 ∧ 𝑠𝑓2 β©½ 0.


3. The decision algorithm, in detail
When one deals with an unquantified language such as RDF 𝑛, which is closed with respect to proposi-
tional connectives, being able to determine algorithmically whether or not a formula is valid amounts
to establishing whether the negation thereof is satisfiable or unsatisfiable. }οΈ€(E.g., ascertaining the validity
of the formula (π‘Ž < π‘₯ < 𝑏) ∧ S_Convex(𝑓 )[π‘Ž,π‘₯] ∧ S_Concave(𝑓 )[π‘₯,𝑏] β†’ 𝐷2 [𝑓 ](π‘₯) = 0 amounts
                {οΈ€

to checking (π‘Ž < π‘₯ < 𝑏) ∧ S_Convex(𝑓 )[π‘Ž,π‘₯] ∧ S_Concave(𝑓 )[π‘₯,𝑏] ∧ 𝐷2 [𝑓 ](π‘₯) ΜΈ= 0 for unsatisfiability .)
We prefer to address the satisfiability problem for RDF 𝑛 here, so our algorithm is supposed to produce
a yes/no answer, where β€˜yes’ means that πœ™ admits a model.
   The idea is to transform, through a finite number of steps, the given RDF 𝑛 formula πœ™ to be tested
for satisfiability into a finite collection of formulas πœ“π‘– , still devoid of quantifiers, each belonging to
elementary algebra of real numbers; this will be done so that πœ™ is satisfiable if and only if at least one of
the resulting πœ“π‘– ’s is satisfiable. Each resulting πœ“π‘– can be tested via Tarski’s decision algorithm.
   First we discuss how to reduce our formula πœ™ to a particular format, called ordered form.
                                               Normalization
Let T be an unquantified, possibly multi-sorted, first-order theory, endowed with: equality =, a
denumerable infinity of individual variables π‘₯1 , π‘₯2 , . . . , function symbols 𝐹1 , 𝐹2 , . . . , and predicate
symbols 𝑃1 , 𝑃2 , . . . .
Definition 3.1. A formula πœ™ of T is said to be flat if it is a conjunction of literals of the forms:
            π‘₯ = 𝑦 , π‘₯ = 𝐹 (π‘₯1 , . . . , π‘₯𝑛 ) , π‘₯ ΜΈ= 𝑦 ,    𝑃 (π‘₯1 , . . . , π‘₯𝑛 ) , ¬𝑃 (π‘₯1 , . . . , π‘₯𝑛 ) ,
with π‘₯, 𝑦, and the π‘₯𝑖 ’s numerical variables, 𝐹 a function symbol and 𝑃 a predicate symbol.
  Let S be the class of all flat formulas of T ; the following holds:
Lemma 3.1. The decision problem for T , to wit, the problem of algorithmically determining whether or
not any given formula πœ™ in T is satisfiable, reduces to the analogous problem regarding S .
Proof. Each satisfiability algorithm for formulas in T clearly works also for formulas in the sublanguage
S of T . For the converse, suppose that an algorithmic satisfiability test for S is available, and let πœ™
be any formula of T . Via routinary techniques, which in our case include rewriting rules such as
                    (β„Ž > 𝑓 + 𝑔)𝐴        ↝    (β„Ž > π‘˜)𝐴          ∧    (π‘˜ = 𝑓 + 𝑔)]βˆ’βˆž,+∞[        ,
                (𝐷𝛼 [𝑓 + 𝑔] = 𝑦)𝐴       ↝    (𝐷𝛼 [π‘˜] = 𝑦)𝐴     ∧    (π‘˜ = 𝑓 + 𝑔)]βˆ’βˆž,+∞[        ,
                  (S_Up(𝑓 + 𝑔))𝐴        ↝    (S_Up(π‘˜))𝐴        ∧    (π‘˜ = 𝑓 + 𝑔)]βˆ’βˆž,+∞[        ,
                                                                                                               (‑)
                 (𝑓 + 𝑔 = β„Ž + 𝑙)𝐴       ↝    (π‘˜ = β„Ž + 𝑙)𝐴      ∧    (π‘˜ = 𝑓 + 𝑔)]βˆ’βˆž,+∞[        ,
                      𝑓 (𝑓 (π‘₯)) = 𝑦     ↝    𝑦 = 𝑓 (𝑧)         ∧    𝑧 = 𝑓 (π‘₯)                 ,
                         (Up(𝑓 ))𝐴      ↝    (𝐷[𝑓 ] β©Ύ 0)𝐴
(likewise, 𝐷[𝑓 ](𝐷[𝑓 ](π‘₯)) = 𝑦 reduces to 𝑦 = 𝐷[𝑓 ](𝑧) ∧ 𝑧 = 𝐷[𝑓 ](π‘₯), etc.), one transforms πœ™ into an
equisatisfiable formula πœ“ such that
   (1) every term occurring in πœ“ either is an individual variable or has the form 𝐹 (π‘₯1 , π‘₯2 , . . . , π‘₯𝑛 ),
       where π‘₯1 , π‘₯2 , . . . , π‘₯𝑛 are individual variables and 𝐹 is a function symbol;
   (2) every atom in πœ“ either has the form π‘₯ = 𝑑, where π‘₯ and 𝑑 are an individual variable and a term,
       respectively, or has the form 𝑃 (π‘₯1 , π‘₯2 , . . . , π‘₯𝑛 ), where π‘₯1 , π‘₯2 , . . . , π‘₯𝑛 are individual variables
       and 𝑃 is a predicate symbol.
   Then one brings πœ“ to disjunctive normal form, thus obtaining a formula πœ“1 ∨ Β· Β· Β· ∨ πœ“πœ… , where all
πœ“π‘– ’s are conjunctions. Additionally, we may assume that each πœ“π‘– is flat, because any literal of type
Β¬ π‘₯ = 𝐹 (𝑦1 , . . . , 𝑦𝑛 ) within it can be replaced by the conjunction π‘₯ ΜΈ= 𝑧 ∧ 𝑧 = 𝐹 (𝑦1 , . . . , 𝑦𝑛 ), where 𝑧
is a brand new variable. Our claim follows, since
                        πœ™ is satisfiable ↔ πœ“ is satisfiable ↔ πœ“π‘– is satisfiable for some 𝑖
and since all transformations used to obtain the conjunctions πœ“1 , . . . , πœ“πœ… are effective.
   We can now proceed to define an ordered form for RDF 𝑛 formulas.
Definition 3.2. A domain variable in a formula πœ™ of RDF 𝑛 is a numerical variable π‘₯ that occurs in πœ™
either as the argument of a term of one of the forms 𝑓 (π‘₯) and 𝐷𝛼 [𝑓 ](π‘₯), with 𝑓 a function variable, or
as an end of some interval mentioned in πœ™ (as exemplified by Convex(𝑓 )[π‘₯,+∞[ ).
Definition 3.3. An RDF 𝑛 formula is said to be in ordered form if it is flat and has the form πœ™ ∧
β‹€οΈ€ π‘›βˆ’1
   𝑖=1 (π‘₯𝑖 < π‘₯𝑖+1 ), where {π‘₯1 , . . . , π‘₯𝑛 } is the set of all distinct domain variables in πœ™.
  The family RDF π‘›π‘œπ‘Ÿπ‘‘ of all ordered formulas of RDF 𝑛 is a strict subset of RDF 𝑛 ; notwithstanding:
Lemma 3.2. (Cf. [8, Lemma 1.4.3 on p.15]) RDF 𝑛 is decidable if and only if RDF π‘›π‘œπ‘Ÿπ‘‘ is decidable.
                                             The algorithm
We describe next the decision algorithm for satisfiability of formulas of RDF 𝑛 . In view of Lemma 3.2,
w.l.o.g. we assume that πœ™ is given in ordered form. Moreover, using new function variables β„Ž subject to
constraints of either the form (β„Ž = 𝑓 + 𝑔)𝐴 or the form (β„Ž = 𝑧 𝑔)𝐴 , all literals, except those defining
these new β„Žβ€™s have been superseded by literals where no compound function terms occur. For example,
(𝑓 + 𝑔 = 3 Β· π‘˜)[0,1] gets rewritten as (β„Ž1 = 𝑓 + 𝑔)]βˆ’βˆž,+∞[ ∧ (β„Ž2 = 3 Β· π‘˜)]βˆ’βˆž,+∞[ ∧ (β„Ž1 = β„Ž2 )[0,1]
β€” further examples can be found in the rules in (‑). Hence, in view of some basic properties of 𝐢 𝑛
functions, the algorithm will only need to consider atomic formulas of the types
           π‘₯=𝑦       ,                  π‘₯>𝑦     ,            𝑧 =π‘₯·𝑦      ,             𝑧 =π‘₯+𝑦        ,
        𝑦 = 𝑓 (π‘₯)    ,             (𝑓 > 𝑔)𝐴     ,          (𝑓 = 𝑧 𝑔)𝐴    ,          (β„Ž = 𝑓 + 𝑔)𝐴     ,
    𝑦 = 𝐷𝛼 [𝑓 ](π‘₯)   ,        (𝐷𝛼 [𝑓 ] ◁▷ 𝑧)𝐴   ,           S_Up(𝑓 )𝐴    ,          S_Down(𝑓 )𝐴      ,
      Convex(𝑓 )𝐴    ,         Concave(𝑓 )𝐴     ,       S_Convex(𝑓 )𝐴    ,        S_Concave(𝑓 )𝐴     ,
where ◁▷ ∈ {=, <, >, β©½, β©Ύ }. (These types form a streamlined subset of the ones seen in Def. 1.2,
since they result from the flattening process mentioned earlier.) Moreover,
Remark 1. Leaving out of consideration literals of the types (𝑓 > 𝑔)𝐴 , (𝐷𝛼 [𝑓 ] > 𝑦)𝐴 , (𝐷𝛼 [𝑓 ] < 𝑦)𝐴 ,
it suffices to take into account only closed intervals 𝐴; in fact, by continuity, the other properties are
valid in an open or semi-open interval if and only if they are valid in its closure, e.g., (𝑓 = 𝑔)]𝑀1 ,𝑀2 [
holds iff (𝑓 = 𝑔)[𝑀1 ,𝑀1 ] holds.                                                                        ⊣
                                                                            𝑛
   We can now focus on the algorithm which takes a formula πœ™ of RDF and reduces it, via a series
πœ™ ↝ πœ™1 ↝ πœ™2 ↝ πœ™3 ↝ πœ™4 = πœ“ of transformations, to a formula πœ“ such that:
   1. πœ™ and πœ“ are equisatisfiable,
   2. πœ“ is a Tarskian formula, i.e., one containing only numerical variables, the arithmetical operators
      +, Β· and the predicate symbols =, <.
As recalled in the introduction, there exists a decision algorithm for Tarskian formulas (cf. [23, 9]). A
decision algorithm for RDF 𝑛 results from integrating Tarski’s decision algorithm with the reduction
πœ™ ↝ πœ“ we are about to present.
  In the following, 𝑀𝑖 denotes a numerical variable, 𝑧𝑖 an β€œextended” numerical variable and 𝛼 a natural
number between 1 and 𝑛.
  The series of transformations we need goes as follows:
   1. πœ™ ↝ πœ™1 : behavior at the endpoints.
         a) We rewrite each atom of the form (𝑓 > 𝑔)]βˆ’βˆž,𝑀2 [ , where 𝑓, 𝑔 are function variables and
            𝑀2 is a numerical variable, as the formula (𝑓 > 𝑔)]βˆ’βˆž,𝑀1 ] ∧ (𝑓 > 𝑔)[𝑀1 ,𝑀2 [ ∧ 𝑀1 < 𝑀2 ,
            where 𝑀1 is the first variable in the ordering of domain variables, if 𝑀2 is preceded by at
            least one such variable; otherwise, 𝑀1 is a brand new domain variable.
            We also perform the specular rewriting:
                       (𝑓 > 𝑔)]𝑀1 ,+∞[ ↝ (𝑓 > 𝑔)]𝑀1 ,𝑀2 ] ∧ (𝑓 > 𝑔)[𝑀2 ,+∞[ ∧ 𝑀1 < 𝑀2 .
             Thanks to the rewritings just made, every comparison between functions will refer either
             to a closed interval or to a bounded interval. (The rewritings to be made at step c) will
             serve a similar aim.)
         b) Let π‘Ž, 𝑏 be real numbers such that π‘Ž < 𝑏, and 𝑓, 𝑔 be real continuous functions in the closed
            interval [π‘Ž, 𝑏]; then 𝑓 > 𝑔 holds in the open interval ]π‘Ž, 𝑏[ if and only if either
                i. 𝑓 > 𝑔 all over [π‘Ž, 𝑏]; or
               ii. 𝑓 > 𝑔 all over [π‘Ž, 𝑏[, and 𝑓 (𝑏) = 𝑔(𝑏); or
              iii. 𝑓 > 𝑔 all over ]π‘Ž, 𝑏], and 𝑓 (π‘Ž) = 𝑔(π‘Ž); or
              iv. 𝑓 > 𝑔 all over ]π‘Ž, 𝑏[, and 𝑓 (π‘Ž) = 𝑔(π‘Ž) ∧ 𝑓 (𝑏) = 𝑔(𝑏)
             holds. By virtue of the previous equivalences, we perform the following actions:
    b1 ) We rewrite a conjunct of this or of an alike form, namely an atom of one of the forms
                            (𝑓 > 𝑔)]𝑀1 ,𝑀2 [ , (𝑓 > 𝑔)[𝑀1 ,𝑀2 [ , (𝑓 > 𝑔)]𝑀1 ,𝑀2 ] ,
         as an equivalent disjunction comprising 4 or just 2 alternatives; in particular:

              (𝑓 > 𝑔)]𝑀1 ,𝑀2 [ ↝ (𝑓 > 𝑔)[𝑀1 ,𝑀2 ] ∨
                                 ((𝑓 > 𝑔)[𝑀1 ,𝑀2 [ ∧ 𝑓 (𝑀2 ) = 𝑔(𝑀2 )) ∨
                                 ((𝑓 > 𝑔)]𝑀1 ,𝑀2 ] ∧ 𝑓 (𝑀1 ) = 𝑔(𝑀1 )) ∨
                                 ((𝑓 > 𝑔)]𝑀1 ,𝑀2 [ ∧ 𝑓 (𝑀1 ) = 𝑔(𝑀1 ) ∧ 𝑓 (𝑀2 ) = 𝑔(𝑀2 )) ,
              (𝑓 > 𝑔)[𝑀1 ,𝑀2 [ ↝ (𝑓 > 𝑔)[𝑀1 ,𝑀2 ] ∨ ((𝑓 > 𝑔)[𝑀1 ,𝑀2 [ ∧ 𝑓 (𝑀2 ) = 𝑔(𝑀2 )) ,
              (𝑓 > 𝑔)]𝑀1 ,𝑀2 ] ↝ (𝑓 > 𝑔)[𝑀1 ,𝑀2 ] ∨ ((𝑓 > 𝑔)]𝑀1 ,𝑀2 ] ∧ 𝑓 (𝑀1 ) = 𝑔(𝑀1 )) ,

    b2 ) Each such rewriting disrupts the structure of the overall formula, which we can
         readily restore by bringing it again to disjunctive normal form 𝛿1 ∨ 𝛿2 ∨ Β· Β· Β· ∨ 𝛿𝑛 (where
         𝑛 ∈ {2, 4}) by means of the distributive law (𝛼 ∨ 𝛽) ∧ 𝛾 ↔ (𝛼 ∧ 𝛾) ∨ (𝛽 ∧ 𝛾) , and
         then working on each 𝛿𝑖 separately in the sequel of this algorithm.
    b3 ) Let 𝑀1 , 𝑀2 be numerical variables and 𝑓, 𝑔 be function variables. In each 𝛿𝑖 where
         the literals (𝑓 > 𝑔)]𝑀1 ,𝑀2 [ , 𝑓 (𝑀1 ) = 𝑔(𝑀1 ), and 𝑓 (𝑀2 ) = 𝑔(𝑀2 ) occur together, when
         𝑀1 < 𝑀2 as ordered domain variables and there are no domain variables between
         𝑀1 and 𝑀2 , we add the literals 𝑀1 < 𝑀, 𝑀 < 𝑀2 and 𝑓 (𝑀) = 𝑧, where 𝑀 and 𝑧 are
         new numerical variables. Plainly, the resulting formula and the original one are
         equisatisfiable.
c) We then rewrite each atom of the form (𝐷𝛼 [𝑓 ] > 𝑦)]βˆ’βˆž,𝑀2 [ , where 𝑓 is a function variable
   and 𝑦, 𝑀2 are numerical variables, as the formula (𝐷𝛼 [𝑓 ] > 𝑦)]βˆ’βˆž,𝑀1 ] ∧ (𝐷𝛼 [𝑓 ] >
   𝑦)[𝑀1 ,𝑀2 [ ∧ 𝑀1 < 𝑀2 , where 𝑀1 is the first variable in the ordering of domain variables if
   𝑀2 is preceded by at least one such variable; otherwise, 𝑀1 is a brand new domain variable.
   We also perform the specular rewriting:
       (𝐷𝛼 [𝑓 ] > 𝑦)]𝑀1 ,+∞[ ↝ (𝐷𝛼 [𝑓 ] > 𝑦)]𝑀1 ,𝑀2 ] ∧ (𝐷𝛼 [𝑓 ] > 𝑦)[𝑀2 ,+∞[ ∧ 𝑀1 < 𝑀2 .
   We handle similarly also the two cases (𝐷𝛼 [𝑓 ] < 𝑦)]βˆ’βˆž,𝑀2 [ and (𝐷𝛼 [𝑓 ] < 𝑦)]𝑀1 ,+∞[ .
   By these transformations we obtain an equisatisfiable formula.
d) Let π‘Ž, 𝑏, and 𝑑 be real numbers and 𝑓 a function, with 𝑓 ∈ 𝐢 𝑛 ([π‘Ž, 𝑏]). Then 𝑓 𝛼 , the 𝛼-th
   derivative of 𝑓 , is greater than 𝑑 in ]π‘Ž, 𝑏[, 𝑓 𝛼 > 𝑑, if and only if one of the following holds:
      i. 𝑓 𝛼 > 𝑑 in [π‘Ž, 𝑏],
     ii. 𝑓 𝛼 > 𝑑 in [π‘Ž, 𝑏[ and 𝑓 𝛼 (𝑏) = 𝑑,
    iii. 𝑓 𝛼 > 𝑑 in ]π‘Ž, 𝑏] and 𝑓 𝛼 (π‘Ž) = 𝑑,
    iv. 𝑓 𝛼 > 𝑑 in ]π‘Ž, 𝑏[, 𝑓 𝛼 (π‘Ž) = 𝑑 and 𝑓 𝛼 (𝑏) = 𝑑.
   The actions to be made are similar to the ones made under b):
    d1 ) We rewrite conjuncts of the forms (𝐷𝛼 [𝑓 ] > 𝑦)]𝑀1 ,𝑀2 [ , (𝐷𝛼 [𝑓 ] > 𝑦)[𝑀1 ,𝑀2 [ , and
         (𝐷𝛼 [𝑓 ] > 𝑦)]𝑀1 ,𝑀2 ] , as equivalent disjunctions;(οΈ€for example:
          )οΈ€(𝐷 [𝑓 ] > 𝑦)]𝑀1 ,𝑀2 ] ↝ (𝐷 [𝑓 ] > 𝑦)[𝑀1 ,𝑀2 ] ∨ (𝐷 [𝑓 ] > 𝑦)]𝑀1 ,𝑀2 ] ∧ 𝐷 [𝑓 ](𝑀1 ) =
              𝛼                          𝛼                        𝛼                   𝛼

         𝑦 .
         We proceed similarly for (𝐷𝛼 [𝑓 ] < 𝑦)]𝑀1 ,𝑀2 [ , (𝐷𝛼 [𝑓 ] < 𝑦)[𝑀1 ,𝑀2 [ , (𝐷𝛼 [𝑓 ] < 𝑦)]𝑀1 ,𝑀2 ] .
    d2 ) We bring again the overall formula into disjunctive normal form, taking the distributive
         law into account.
    d3 ) If in a formula three literals (𝐷𝛼 [𝑓 ] > 𝑦)]𝑀1 ,𝑀2 [ , 𝐷𝛼 [𝑓 ](𝑀1 ) = 𝑦, and 𝐷𝛼 [𝑓 ](𝑀2 ) = 𝑦
         occur together, and they are such that 𝑀1 < 𝑀2 as ordered domain variables, and
         there are no domain variables between 𝑀1 and 𝑀2 , we add the following literals:
         𝑀1 < 𝑀, 𝑀 < 𝑀2 and 𝑓 (𝑀) = 𝑧.                          We treat (𝐷𝛼 [𝑓 ] < 𝑦)]𝑀1 ,𝑀2 [ likewise.
  By applying rules a), b), c), and d) to a formula πœ“ in ordered form, we obtain a finite disjunction
  of πœ“π‘– ordered formulas such that πœ“ is satisfiable if and only if at least one of the πœ“π‘– is satisfiable.
  To each πœ“π‘– we apply the rest of the algorithm.

2. πœ™1 ↝ πœ™2 : negative-clause removal.
  From πœ™1 we construct an equisatisfiable formula πœ™2 within which literals refferring to intervals
  have no negative occurrences. The general idea applied in this step is to substitute every negative
  clause involving a function symbol along with an interval spec with an implicit existential
  assertion.
  For the sake of simplicity, in the following:
      β€’ π‘₯, π‘₯1 , π‘₯2 , π‘₯3 , 𝑦1 , 𝑦2 , 𝑦3 will be numerical variables, new w.r.t. the formula considered;
      β€’ we use the notation π‘₯ β‰Ό 𝑦 as a shorthand for π‘₯ β©½ 𝑦 when π‘₯, 𝑦 are both numerical variables;
        when either π‘₯ is βˆ’βˆž or 𝑦 is +∞, π‘₯ β‰Ό 𝑦 stands for a true literal (e.g., 0 = 0).
    a) Replace each literal Β¬(𝑓 = 𝑧 𝑔)[𝑧1 ,𝑧2 ] occurring in πœ™1 by the formula (involving a new
       function variable β„Ž) (𝑧1 β‰Ό π‘₯ β‰Ό 𝑧2 )βˆ§π‘¦1 = 𝑓 (π‘₯)βˆ§π‘¦2 = β„Ž(π‘₯)∧¬(𝑦1 = 𝑦2 )∧(β„Ž = 𝑧 𝑔)[𝑧1 ,𝑧2 ] .
    b) Replace each literal Β¬(β„Ž = 𝑓 + 𝑔)[𝑧1 ,𝑧2 ] occurring in πœ™1 by the formula (involving a new
       function variable 𝑙) (𝑧1 β‰Ό π‘₯ β‰Ό 𝑧2 )βˆ§π‘¦1 = β„Ž(π‘₯)βˆ§π‘¦2 = 𝑙(π‘₯)∧¬(𝑦1 = 𝑦2 )∧(𝑙 = 𝑓 +𝑔)[𝑧1 ,𝑧2 ] .
     c) Replace each literal Β¬(𝑓 > 𝑔)[𝑧1 ,𝑧2 ] occurring in πœ™1 by the formula:
                                (𝑧1 β‰Ό π‘₯ β‰Ό 𝑧2 ) ∧ 𝑦1 = 𝑓 (π‘₯) ∧ 𝑦2 = 𝑔(π‘₯) ∧ (𝑦1 β©½ 𝑦2 ).
    d) Replace each literal Β¬(𝐷𝛼 [𝑓 ] ◁▷ 𝑦)[𝑧1 ,𝑧2 ] occurring in πœ™1 by the formula:
                  (𝑧1 β‰Ό π‘₯ β‰Ό 𝑧2 ) ∧ 𝑦1 = 𝐷𝛼 [𝑓 ](π‘₯) ∧ Β¬(𝑦1 ◁▷ 𝑦) , where β—β–·βˆˆ {<, β©½, =, β©Ύ, >} .
     e) Replace each literal Β¬S_Up (𝑓 )[𝑧1 ,𝑧2 ] (resp. Β¬ S_Down (𝑓 )[𝑧1 ,𝑧2 ] ) occurring in πœ™1 by the
        formula Ξ“ ∧ 𝑦1 β©Ύ 𝑦2 (resp. Ξ“ ∧ 𝑦1 β©½ 𝑦2 ) , where Ξ“ := (𝑧1 β‰Ό π‘₯1 < π‘₯2 β‰Ό 𝑧2 ) ∧ 𝑦1 =
        𝑓 (π‘₯1 ) ∧ 𝑦2 = 𝑓 (π‘₯2 ).
     f) Replace each literal Β¬ Convex(𝑓 )[𝑧1 ,𝑧2 ] (resp. Β¬ S_Convex (𝑓 )[𝑧1 ,𝑧2 ] ) occurring in πœ™1 by
        Ξ“βˆ§(𝑦2 βˆ’π‘¦1 )(π‘₯3 βˆ’π‘₯1 ) > (π‘₯2 βˆ’π‘₯1 )(𝑦3 βˆ’π‘¦1 ) (resp. Ξ“βˆ§(𝑦2 βˆ’π‘¦1 )(π‘₯3 βˆ’π‘₯1 ) β©Ύ (π‘₯2 βˆ’π‘₯1 )(𝑦3 βˆ’
        𝑦1 )) , where Ξ“ := (𝑧1 β‰Ό π‘₯1 < π‘₯2 < π‘₯3 β‰Ό 𝑧2 ) ∧ 𝑦1 = 𝑓 (π‘₯1 ) ∧ 𝑦2 = 𝑓 (π‘₯2 ) ∧ 𝑦3 = 𝑓 (π‘₯3 ).
        Literals of the forms Β¬ Concave(𝑓 )[𝑧1 ,𝑧2 ] , Β¬ S_Concave (𝑓 )[𝑧1 ,𝑧2 ] are handled similarly.
  Analogously, with only slight changes, we can remove literals about open and semi-open intervals:
  e.g., Β¬(𝑓 > 𝑔)]𝑀1 ,𝑀2 ] becomes (𝑀1 < π‘₯ β©½ 𝑀2 ) ∧ 𝑦1 = 𝑓 (π‘₯) ∧ 𝑦2 = 𝑔(π‘₯) ∧ (𝑦1 β©½ 𝑦2 ).
  Equisatisfiability of the formulas πœ™1 and πœ™2 is straightforward to prove. According to Lemma 3.1
  and Lemma 3.2, we can transform πœ™2 , to obtain an equivalent formula in ordered form with
  domain variables 𝑣1 , 𝑣2 , . . . , π‘£π‘Ÿ .

3. πœ™2 ↝ πœ™3 : explicit evaluation of function variables.
  This step is preparatory to the elimination of the functional clauses, by explicit evaluation of
  function variables over domain variables. For each such variable 𝑣𝑗 and for every function
  variable 𝑓 occurring in πœ™2 , introduce 𝑛 + 1 new numerical variables 𝑦𝑗𝑓 , 𝑑1,𝑓          𝑛,𝑓
                                                                              𝑗 , . . . , 𝑑𝑗   and add
  the literals 𝑦𝑗𝑓 = 𝑓 (𝑣𝑗 ), 𝑑1,𝑓                      𝑛,𝑓
                               𝑗 = 𝐷[𝑓 ](𝑣𝑗 ), . . . , 𝑑𝑗   = 𝐷𝑛 [𝑓 ](𝑣𝑗 ) to πœ™2 . Moreover, for each literal
  π‘₯ = 𝑓 (𝑣𝑗 ) already occurring in πœ™2 , add the literal π‘₯ = 𝑦𝑗𝑓 into πœ™3 ; and similarly, for each literal of
  type π‘₯ = 𝐷𝛼 [𝑓 ](𝑣𝑗 ) already occurring in πœ™2 , insert the literal π‘₯ = 𝑑𝛼,𝑓
                                                                          𝑗   into πœ™3 .
  The formula πœ™3 resulting from these insertions and the original πœ™2 are clearly equisatisfiable.

4. πœ™3 ↝ πœ™4 : elimination of function variables.
  As a final step, we get rid of all literals containing function variables.
           Define the index function 𝑖𝑛𝑑 : 𝑉 βˆͺ {βˆ’βˆž, +∞} β†’ {1, 2, . . . , π‘Ÿ} over the set {𝑣1 , 𝑣2 , . . . , π‘£π‘Ÿ } of
           distinct domain variables of πœ™3 as ⎧      follows:
                                                     ⎨ 1 if π‘₯ = βˆ’βˆž,
                                         𝑖𝑛𝑑(π‘₯) :=       𝑙 if π‘₯ = 𝑣𝑙 for some 𝑙 ∈ {1, 2, . . . , π‘Ÿ},
                                                         π‘Ÿ if π‘₯ = +∞.
                                                     ⎩

           For each function symbol 𝑓 occurring in πœ™3 , introduce new numerical variables π‘˜0𝑓 , π‘˜π‘Ÿπ‘“ , 𝛾01,𝑓, . . . , 𝛾0𝑛,𝑓,
           π›Ύπ‘Ÿ1,𝑓, . . . , π›Ύπ‘Ÿπ‘›,𝑓, and proceed as follows:
              a) For each literal (𝑓 = 𝑔)[𝑧1 ,𝑧2 ] occurring in πœ™3 , add all literals 𝑦𝑖𝑓 = 𝑦𝑖𝑔 , 𝑑1,𝑓𝑖  = 𝑑1,𝑔
                                                                                                             𝑖 ,...,
                  𝑛,𝑓      𝑛,𝑔
                 𝑑𝑖 = 𝑑𝑖 whose subscript 𝑖 satisfies 𝑖𝑛𝑑(𝑧1 ) β©½ 𝑖 β©½ 𝑖𝑛𝑑(𝑧2 ); moreover, if 𝑧1 = βˆ’βˆž
                 introduce the literals 𝛾01,𝑓 = 𝛾01,𝑔 , . . . , 𝛾0𝑛,𝑓 = 𝛾0𝑛,𝑔 , and if 𝑧2 = +∞ introduce the literals
                 π›Ύπ‘Ÿ1,𝑓 = π›Ύπ‘Ÿ1,𝑔 , . . . , π›Ύπ‘Ÿπ‘›,𝑓 = π›Ύπ‘Ÿπ‘›,𝑔 .
              b) For each literal (𝑓 = 𝑧 𝑔)[𝑧1 ,𝑧2 ] occurring in πœ™3 , add all literals 𝑦𝑖𝑓 = 𝑧 𝑦𝑖𝑔 , 𝑑1,𝑓  𝑖 =
                    1,𝑔          𝑛,𝑓    𝑛,𝑔
                 𝑧 𝑑𝑖 , . . . , 𝑑𝑖 = 𝑧 𝑑𝑖 , whose subscript 𝑖 satisfies 𝑖𝑛𝑑(𝑧1 ) β©½ 𝑖 ⩽𝑖𝑛𝑑(𝑧2 ); moreover, if
                 𝑧1 = βˆ’βˆž then introduce the literals 𝛾01,𝑓 = 𝑧 𝛾01,𝑔 , . . . , 𝛾0𝑛,𝑓 = 𝑧 𝛾0𝑛,𝑔 , and if 𝑧2 = +∞
                 then introduce the literals π›Ύπ‘Ÿ1,𝑓 = 𝑧 π›Ύπ‘Ÿ1,𝑔 , . . . , π›Ύπ‘Ÿπ‘›,𝑓 = 𝑧 π›Ύπ‘Ÿπ‘›,𝑔 .
              c) For each literal (β„Ž = 𝑓 + 𝑔)[𝑧1 ,𝑧2 ] occurring in πœ™3 , add all literals π‘¦π‘–β„Ž = 𝑦𝑖𝑓 + 𝑦𝑖𝑔 , 𝑑1,β„Ž 𝑖 =
                  1,𝑓   1,𝑔        𝑛,β„Ž  𝑛,𝑓 𝑛,𝑔
                 𝑑𝑖 +𝑑𝑖 , . . . , 𝑑𝑖 = 𝑑𝑖 +𝑑𝑖 whose subscript 𝑖 satisfies 𝑖𝑛𝑑(𝑧1 ) β©½ 𝑖 β©½ 𝑖𝑛𝑑(𝑧2 ); moreover,
                 if 𝑧1 = βˆ’βˆž then introduce the literals 𝛾01,β„Ž = 𝛾01,𝑓 + 𝛾01,𝑔 , . . . , 𝛾0𝑛,β„Ž = 𝛾0𝑛,𝑓 + 𝛾0𝑛,𝑔 , and if
                 𝑧2 = +∞ then introduce the literals π›Ύπ‘Ÿ1,β„Ž = π›Ύπ‘Ÿ1,𝑓 + π›Ύπ‘Ÿ1,𝑔 , . . . , π›Ύπ‘Ÿπ‘›,β„Ž = π›Ύπ‘Ÿπ‘›,𝑓 + π›Ύπ‘Ÿπ‘›,𝑔 .
              d) For literals of type (𝑓 > 𝑔)𝐴 , we consider separately bounded and unbounded intervals:
                   d1 ) For each literal (𝑓 > 𝑔)[𝑀1 ,𝑀2 ] (resp. (𝑓 > 𝑔)]𝑀1 ,𝑀2 [ , (𝑓 > 𝑔)[𝑀1 ,𝑀2 [ , (𝑓 > 𝑔)]𝑀1 ,𝑀2 ] ) oc-
                        curring in πœ™3 , add the literals 𝑦𝑖𝑓 > 𝑦𝑖𝑔 with 𝑖𝑛𝑑(𝑀1 ) β©½ 𝑖 β©½ 𝑖𝑛𝑑(𝑀2 ) (resp. 𝑖𝑛𝑑(𝑀1 ) <
                        𝑖 < 𝑖𝑛𝑑(𝑀2 ), 𝑖𝑛𝑑(𝑀1 ) β©½ 𝑖 < 𝑖𝑛𝑑(𝑀2 ), and 𝑖𝑛𝑑(𝑀1 ) < 𝑖 β©½ 𝑖𝑛𝑑(𝑀2 )). Moreover, if
                        𝑀1 < 𝑀2 as domain variables, in the case (𝑓 > 𝑔)]𝑀1 ,𝑀2 [ (resp. (𝑓 > 𝑔)[𝑀1 ,𝑀2 [ , (𝑓 >
                        𝑔)]𝑀1 ,𝑀2 ] ) also add the literals 𝑑1,𝑓         1,𝑔         1,𝑓         1,𝑔              1,𝑓
                                                             𝑖𝑛𝑑(𝑀1 ) β©Ύ 𝑑𝑖𝑛𝑑(𝑀1 ) , 𝑑𝑖𝑛𝑑(𝑀2 ) β©½ 𝑑𝑖𝑛𝑑(𝑀2 ) (resp. 𝑑𝑖𝑛𝑑(𝑀2 ) β©½
                        𝑑1,𝑔          1,𝑓         1,𝑔
                         𝑖𝑛𝑑(𝑀2 ) or 𝑑𝑖𝑛𝑑(𝑀1 ) β©Ύ 𝑑𝑖𝑛𝑑(𝑀1 ) ).
                   d2 ) For each literal (𝑓 > 𝑔)]βˆ’βˆž,+∞[ (resp. (𝑓 > 𝑔)]βˆ’βˆž,𝑀1 ] , (𝑓 > 𝑔)[𝑀1 ,+∞[ ) occurring in
                        πœ™3 , add the literal 𝑦𝑖𝑓 > 𝑦𝑖𝑔 with 1 β©½ 𝑖 β©½ π‘Ÿ (resp. 1 β©½ 𝑖 β©½ 𝑖𝑛𝑑(𝑀1 ), 𝑖𝑛𝑑(𝑀1 ) β©½ 𝑖 β©½ π‘Ÿ), and
                        the literals π‘˜0𝑓 β©Ύ π‘˜0𝑔 , π‘˜π‘Ÿπ‘“ β©Ύ π‘˜π‘Ÿπ‘” (resp. π‘˜0𝑓 β©Ύ π‘˜0𝑔 or π‘˜π‘Ÿπ‘“ β©Ύ π‘˜π‘Ÿπ‘” ).
              e) For literals of type (𝐷𝛼 [𝑓 ] ◁▷ 𝑦)𝐴 , we consider separately closed and unclosed interval
                 specifications:8
                   e1 ) For each literal (𝐷[𝑓 ]𝛼 ◁▷ 𝑦)[𝑧1 ,𝑧2 ] occurring in πœ™3 , where β—β–·βˆˆ {=, <, >, β©½, β©Ύ}, add
                        the following formulas:
                                                                         π‘‘π›Όβˆ’1,𝑓 βˆ’π‘‘π›Όβˆ’1,𝑓
                                                   𝑑𝛼,𝑓
                                                    𝑖   ◁▷ 𝑦, 𝑗+1𝑣𝑗+1 βˆ’π‘£
                                                                       𝑗
                                                                         𝑗
                                                                           ◁▷ 𝑦,
                        for 𝑖𝑛𝑑(𝑧1 ) β©½ 𝑖 β©½ 𝑖𝑛𝑑(𝑧2 ) and 𝑖𝑛𝑑(𝑧1 ) β©½ 𝑗 < 𝑖𝑛𝑑(𝑧2 ), and if β—β–·βˆˆ {β©½, β©Ύ} add the
                        implication:      (οΈ‚                 )οΈ‚
                                                  π‘‘π›Όβˆ’1,𝑓
                                                   𝑗+1 βˆ’π‘‘π‘—
                                                           π›Όβˆ’1,𝑓

                                                     𝑣𝑗+1 βˆ’π‘£π‘—    =𝑦        β†’ (𝑑𝛼,𝑓
                                                                               𝑗   = 𝑦 ∧ 𝑑𝛼,𝑓
                                                                                          𝑗+1 = 𝑦);

                        moreover, if 𝑧1 = βˆ’βˆž, introduce the literal 𝛾0𝛼,𝑓 ◁▷ 𝑦, and if 𝑧2 = +∞, introduce the
                        literal π›Ύπ‘Ÿπ›Ό,𝑓 ◁▷ 𝑦.
                   e2 ) For each literal (𝐷𝛼 [𝑓 ] ◁▷ 𝑦)]𝑀1 ,𝑀2 [ (resp. (𝐷𝛼 [𝑓 ] ◁▷ 𝑦)]𝑀1 ,𝑀2 ] , (𝐷𝛼 [𝑓 ] ◁▷ 𝑦)[𝑀1 ,𝑀2 [ )
                        occurring in πœ™3 , where β—β–·βˆˆ {=, <, >, β©½, β©Ύ}, add the formulas:
8
    The treatment of these literals, novel with respect to [1], is a straightforward refinement of the corresponding algorithm step
    [1, step 4.e)].
                                                             π‘‘π›Όβˆ’1,𝑓 βˆ’π‘‘π›Όβˆ’1,𝑓
                                             𝑑𝛼,𝑓
                                              𝑖   ◁▷ 𝑦, 𝑗+1𝑣𝑗+1 βˆ’π‘£
                                                                 𝑗
                                                                   𝑗
                                                                      ◁▷ 𝑦 ,
                  for 𝑖𝑛𝑑(𝑀1 ) β©½ 𝑗 < 𝑖𝑛𝑑(𝑀2 ) and 𝑖𝑛𝑑(𝑀1 ) < 𝑖 < 𝑖𝑛𝑑(𝑀2 ) (resp. 𝑖𝑛𝑑(𝑀1 ) < 𝑖 β©½ 𝑖𝑛𝑑(𝑀2 )
                  and 𝑖𝑛𝑑(𝑀1 ) β©½ 𝑖 < 𝑖𝑛𝑑(𝑀2 )).
         f) For each literal S_Up(𝑓 )[𝑧1 ,𝑧2 ] (resp. S_Down(𝑓 )[𝑧1 ,𝑧2 ] ) occurring in πœ™3 , add the literals
                                            𝑑1,𝑓
                                              𝑖   β©Ύ 0 (resp. β©½), 𝑦𝑗+1 𝑓
                                                                             > 𝑦𝑗𝑓 (resp. <),
            for 𝑖𝑛𝑑(𝑧1 ) β©½ 𝑖 β©½ 𝑖𝑛𝑑(𝑧2 ) and 𝑖𝑛𝑑(𝑧1 ) β©½ 𝑗 < 𝑖𝑛𝑑(𝑧2 ); moreover, if 𝑧1 = βˆ’βˆž, introduce
            the literal 𝛾01,𝑓 > 0 (resp. <) and, if 𝑧2 = +∞, introduce the formula π›Ύπ‘Ÿ1,𝑓 > 0 (resp. <).
         g) For each literal Convex(𝑓 )[𝑧1 ,𝑧2 ] (resp. Concave(𝑓 )[𝑧1 ,𝑧2 ] ) occurring in πœ™3 , add:
                                        𝑦𝑓   βˆ’π‘¦ 𝑓
                                𝑑1,𝑓 β©½ 𝑣𝑖+1       𝑖
                                                    β©½ 𝑑1,𝑓
                                                       𝑖+1 (resp. β©Ύ), )︂𝑑2,𝑓 β©Ύ 0 (resp. β©½)
                               (οΈ‚ 𝑖 𝑓    𝑓
                                           𝑖+1 βˆ’π‘£π‘–
                                                         𝑓     𝑓
                                                                         𝑖
                                  𝑦𝑖+1 βˆ’π‘¦π‘–              𝑦𝑖+1 βˆ’π‘¦π‘–
                                                                             (︁              )︁
                                                1,𝑓                 1,𝑓           1,𝑓    1,𝑓
                                  𝑣𝑖+1 βˆ’π‘£π‘–  =  𝑑𝑖    ∨  𝑣𝑖+1 βˆ’π‘£π‘– = 𝑑𝑖+1    β†’    𝑑 𝑖   = 𝑑𝑖+1 ,

            for each 𝑖𝑛𝑑(𝑧1 ) β©½ 𝑖 < 𝑖𝑛𝑑(𝑧2 ); moreover, if 𝑧1 = βˆ’βˆž, introduce the literal 𝛾01,𝑓 β©½ 𝑑1,𝑓
                                                                                                   1
            (resp. β©Ύ), and, if 𝑧2 = +∞, introduce the literal π›Ύπ‘Ÿ1,𝑓 β©Ύ 𝑑1,𝑓
                                                                       π‘Ÿ   (resp. β©½).
         h) For each literal S_Convex(𝑓 )[𝑧1 ,𝑧2 ] (resp. S_Concave(𝑓 )[𝑧1 ,𝑧2 ] ) occurring in πœ™3 , add:
                                        𝑦𝑓   βˆ’π‘¦ 𝑓
                                𝑑1,𝑓
                                 𝑖   < 𝑣𝑖+1   𝑖
                                        𝑖+1 βˆ’π‘£π‘–
                                                < 𝑑1,𝑓             2,𝑓
                                                   𝑖+1 (resp. >), 𝑑𝑖   β©Ύ 0 (resp. β©½)
             for 𝑖𝑛𝑑(𝑧1 ) β©½ 𝑖 < 𝑖𝑛𝑑(𝑧2 ); moreover, if 𝑧1 = βˆ’βˆž, introduce the literal 𝛾01,𝑓 < 𝑑1,𝑓
                                                                                               1 (resp. >),
             and, if 𝑧2 = +∞, introduce the literal π›Ύπ‘Ÿ1,𝑓 > 𝑑1,𝑓
                                                              π‘Ÿ    (resp. <).
          i) If there are literals involving variables of type π‘˜, i.e., literals of the form π‘˜π‘–π‘“ β©Ύ π‘˜π‘–π‘” with
             𝑖 ∈ {0, π‘Ÿ} and 𝑓, 𝑔 function variables, perform the following steps:
               i. for each variable π‘˜π‘–π‘“ , add the formula βˆ’1 β©½ π‘˜π‘–π‘“ β©½ +1, with 𝑖 ∈ {0, π‘Ÿ};
               ii. if both literals π‘˜π‘–π‘“ β©Ύ π‘˜π‘–π‘” and π‘˜π‘–π‘” β©Ύ π‘˜π‘–β„Ž occur in πœ™4 , add literals π‘˜π‘–π‘“ β©Ύ π‘˜π‘–β„Ž and 𝑦𝑖𝑓 > π‘¦π‘–β„Ž ,
                   with 𝑖 ∈ {0, π‘Ÿ};
              iii. if literals π‘˜0𝑓 β©Ύ π‘˜0𝑔 , 𝛾01,𝑓 ⊡ π‘š and 𝛾01,𝑔 ⊴ 𝑛 occur together, with ⊡ ∈ {β©Ύ, >, =} and
                   ⊴ ∈ {β©½, <, =}, add literal π‘š β©½ 𝑛; specularly, in the case π‘˜π‘Ÿπ‘“ β©Ύ π‘˜π‘Ÿπ‘” , π›Ύπ‘Ÿ1,𝑓 ⊴ π‘š and
                   π›Ύπ‘Ÿ1,𝑔 ⊡ 𝑛, add the literal π‘š β©Ύ 𝑛.
          j) Remove all literals that involve function variables.

The formula πœ™4 resulting at the end involves only numerical variables, hence it can be decided by means
of Tarski’s method.


4. Remarks on the correctness of the algorithm
Proving the correctness of the algorithm amounts to showing that each one of the (terminating)
transformations πœ™ ↝ πœ™1 , πœ™1 ↝ πœ™2 , πœ™2 ↝ πœ™3 , πœ™3 ↝ πœ™4 is satisfiability preserving. As for the first three
transformations (behavior at the endpoints, negative-clause removal, explicit evaluation of function
variables), this emerges as a rather straightforward fact.
   We must focus on the equisatisfiability of the formulas πœ™3 and πœ™4 , because the transformation
πœ™3 ↝ πœ™4 is less transparent than the previous ones: we are, in fact, comparing a formula whose
predicates regard the behavior of functions in real intervals with another one, which only involves
relations between numerical variables. Let us sketch the idea behind the proof, which as usual consists
of two parts: soundness and completeness. Recall that πœ™4 is obtained from πœ™3 by adding some formulas
that involve only numerical variables and removing all predicates that refer to function variables.
Soundness: If a model exists for πœ™3 , it can be extended to a model that also verifies the numerical
formulas added in πœ™4 , since these formulas reflect the properties of the functions in πœ™3 at specific points
in real intervals.
Completeness: Conversely, if there exists a model for πœ™4 , it should be possible to extend it to πœ™3 by
interpreting the function variables with suitable interpolating functions. Thus, showing the correctness
of the fourth transformation calls for an ad hoc interpolation method, which we have produced explicitly
for the case 𝑛 = 1 in [1]; when 𝑛 = 2, we could borrow an interpolation method due to Manni [15];
when 𝑛 > 2, we hope for, and remain in debt with the reader of, a proof of existence of the suitable
interpolating function.
                                      Completeness for RDF 2 , a bird’s-eye view
The completeness for RDF 2 relies on the interpolation method developed by Manni [15] which is a shape-
preserving 𝐢 2 interpolation method. This means that, given a grid of real numbers 𝑣1 < 𝑣2 < Β· Β· Β· < π‘£π‘Ÿ
and real values 𝑦𝑖 , 𝑑𝑖 , 𝑠𝑖 with 𝑖 ∈ {1, . . . , π‘Ÿ}, Manni’s method builds a 𝐢 2 real function 𝑓 such that, for
all 𝑖 ∈ {1, . . . , π‘Ÿ}:
                                   𝑓 (𝑣𝑖 ) = 𝑦𝑖 , 𝑓 β€² (𝑣𝑖 ) = 𝑑𝑖 and 𝑓 β€²β€² (𝑣𝑖 ) = 𝑠𝑖 .                        (1)
Moreover, Manni’s method has three properties relevant for our aims:

       1. It preserves the β€œgeometric properties” [10] of the given data 𝑣𝑖 , 𝑦𝑖 , 𝑑𝑖 , 𝑠𝑖 ; e.g, if the data are
          increasing, 𝑦𝑖 β©½ 𝑦𝑖+1 and 𝑑𝑖 β©Ύ 0 for all 𝑖, so will be the interpolating function.

       2. The interpolation of a sum of data is the sum of the two interpolations; namely given two series
          of values 𝑦𝑖𝑓 , 𝑑𝑓𝑖 , 𝑠𝑓𝑖 and 𝑦𝑖𝑔 , 𝑑𝑔𝑖 , 𝑠𝑔𝑖 over the same grid 𝑣1 < 𝑣2 < Β· Β· Β· < π‘£π‘Ÿ with, respectively,
          two interpolating functions 𝑓 and 𝑔, then 𝑓 + 𝑔 is the interpolating function for the values
          𝑦𝑖𝑓 + 𝑦𝑖𝑔 , 𝑑𝑓𝑖 + 𝑑𝑔𝑖 , 𝑠𝑓𝑖 + 𝑠𝑔𝑖 .

       3. Beside the given data 𝑣𝑖 , 𝑦𝑖 , 𝑑𝑖 , 𝑠𝑖 , the interpolating function 𝑓 built by the method depends on a
          shrinking parameter π‘˜ and we will use the notation π‘“π‘˜ to emphasize the dependency from this
          parameter π‘˜. As π‘˜ tends toward 0, the function π‘“π‘˜ tends to the piece-wise linear interpolation
          passing through the points (𝑣1 , 𝑦1 ), . . . , (π‘£π‘Ÿ , π‘¦π‘Ÿ ); more precisely limπ‘˜β†’0 ||π‘“π‘˜ βˆ’ π‘ž||∞ = 0 where
          ||π‘“π‘˜ βˆ’ π‘ž||∞ = sup𝑣1 β©½π‘₯β©½π‘£π‘Ÿ |π‘“π‘˜ (π‘₯) βˆ’ π‘ž(π‘₯)| and π‘ž is the piece-wise linear interpolation passing
          through the points (𝑣𝑖 , 𝑦𝑖 ).9

Roughly speaking, having Manni’s method at our disposal the completeness proof goes as follows.
   Given a numerical model 𝑀 for πœ™4 , i.e., a set of real values which satisfies all the algebraic constraints
in πœ™4 , we use Manni’s method to build from 𝑀 a functional model β„± for πœ™3 , namely a set of real
functions interpreting all the function variables of πœ™3 and satisfying all the function requirements.
More precisely, let 𝑣¯ denote the interpretation 𝑀 𝑣 of the numerical variable 𝑣 under the model M.
Given a function variable 𝑓 in πœ™3 , we apply Manni’s method to the values 𝑣¯𝑖 , 𝑦¯𝑓𝑖 , ¯𝑑𝑓𝑖 and ¯𝑠𝑓𝑖 to obtain a
𝐢 2 function 𝑓¯ which will be the interpretation of 𝑓 . By (1), 𝑓¯ satisfies all point-wise conditions such
as 𝐷[𝑓 ](𝑣3 ) = 𝑑𝑓3 . The remaining part consists in proving that, for π‘˜ small enough, the interpolating
function 𝑓¯ π‘˜ satisfies also all the other possible atomic formulas, e.g. (𝐷[𝑓 ] > 𝑠)[𝑣𝑖 ,𝑣𝑗 [ ; this part heavily
relies on the three interpolation properties previously exposed.


5. The threshold of undecidability
Tarski himself showed that decidability of his full elementary algebra of real numbers [23] would be
disrupted if its language were enriched with a periodic real function, e.g., sin π‘₯. Richardson proved
in [20] the undecidability of the existential theory of reals extended with the numbers log 2 and πœ‹,
and with the functions 𝑒π‘₯ , sin π‘₯; Richardson’s results have been subsequently improved by Caviness
[7], Wang [24] and Laczkovich [13]. More precisely: Caviness removed the use of 𝑒π‘₯ and ln 2; Wang
extended Caviness’ result from undecidability for comparison with 0, namely of type 𝐴(π‘₯) < 0, to

                                                                   π‘₯βˆ’π‘£π‘–
9
    Over the interval [𝑣𝑖 , 𝑣𝑖+1 ], π‘ž is defined as π‘ž(π‘₯) := 𝑦𝑖 + 𝑣𝑖+1 βˆ’π‘£π‘–
                                                                          Β· (𝑦𝑖+1 βˆ’ 𝑦𝑖 ).
undecidability for equality to 0, i.e., 𝐴(π‘₯) = 0; Laczkovich removed the need of πœ‹ and reduced the use
of function composition.
   In consequence of Laczkovich’s result and of our reduction of RDF 𝑛 to Tarskian algebra, any extension
        𝑛
(οΈ€ RDF
of        enabling  us to express sin π‘₯ turns out to be undecidable. For example, an atomic formula
    2
            )οΈ€
  𝐷 [𝑓 ] = 𝑔 𝐴 for equality between a second derivative and a function would allow one to specify
𝑓 = sin π‘₯ through the differential characterization:
                         𝑓 (0) = 0 ∧ 𝐷1 [𝑓 ](0) = 1 ∧ (𝐷2 [𝑓 ] = (οΈ€ βˆ’π‘“ )]βˆ’βˆž,+∞[
                                                                            )οΈ€ .
Thus, for 𝑛 β©Ύ 2, the introduction of atomic formulas of type 𝐷2 [𝑓 ] = 𝑔 𝐴 would make RDF 𝑛 unde-
cidable. Establishing whether or not an analogous extension of RDF 1 is decidable is harder. As far as
we now, having comparison between first derivatives and functions does not allow one to define sin π‘₯;
however, it enables the definition of 𝑒π‘₯ via
                                    𝑓 (0) = 1 ∧ (𝐷1 [𝑓 ] = 𝑓 )]βˆ’βˆž,+∞[ ,
but, since even the decidability of Tarskian algebra extended with the exponential function is still an
open
(οΈ€ 1 problem)οΈ€ [14], we cannot judge whether such an enrichment, i.e., function-derivative comparison
  𝐷 [𝑓 ] = 𝑔 𝐴 , would disrupt the decidability of RDF 1 .

Conclusions
                                                       Applications
The decidability result presented in this paper is not merely of theoretical interest, but can be seen
as a contribution to the automated reasoning field; as a matter of fact RMCF + , one of the decision
algorithms from which it originates, was discussed in the monograph [21], which is a companion of the
proof-verification system Γ†tnaNova: if it were implemented inside such a system, a decision algorithm
akin to it could play the role of a sophisticated and specialized inference mechanism.10 Regrettably,
though, the worst-case algorithmic complexity of the known algorithms concerned with real functions,
in their present forms, is not encouraging [3]; discouragement can be alleviated by considerations about
the behaviour in typical cases, as discussed in the same context (cf. [3, pp. 775–776]).
   Envisaged applications of a system such as Γ†tnaNova regard proof checking as well as program-
correctness verification; parts of it specialized on real algebra and analysis might also assist in formal
hardware validation and in the study of hybrid systems.
   Given the enduring popularity of resolution, research on decision algorithmsβ€”whether focusing on
fragments of mathematical theories or logical calculi, or addressing entire theoriesβ€”has only sporadically
influenced the field of automated deduction. Notable exceptions include the influential papers by Nelson-
Oppen [17, 18]. These works are significant not because they add to the inventory of decidable theories,
but because they address the integration of decision algorithms. In this regard, their impact and long-
term influence are comparable to that of the DPLL algorithm, which, besides being directly applicable
as a test for propositional logic, often serves as a crucial and ubiquitous inference mechanism.
                                               Related and future work
This article has presented a decision algorithm for a fragment RDF 𝑛 of real analysis, which extends
the unquantified part of Tarski’s elementary algebra EAR of real numbers with variables designating
functions of a real variable endowed with continuous derivatives up the 𝑛-th order.
  The decidability of the theory RDF 𝑛 is a follow-up of a series of previous results, regarding the
theories RMCF, RMCF + , RDF, RDF + and RDF * [5, 3, 8, 4, 2, 1]. A general survey on those results, save
the last two, can be found in [6], where other decidability results on real analysis are also treated, in
particular the FS theory [11, 12].
  It is hoped that decision methods regarding differentiable functions from R𝑛 to Rπ‘š are amenable to
the approach discussed above: an encouraging indication in this direction comes from [5, Sec. 4] which,

10
     Actually, less specialized than it may seem at first glance: as shown in [5, Sec. 5], a decision algorithm conceived for
     real numbers and univariate real functions could be exploited to reason about a totally ordered set (𝑆, <) and monotone
     functions from 𝑆 to 𝑆.
however, deals with continuous function (with no concern about differentiability).
   A decidability problem that seems worth being investigated regards the theory RDF ∞ , whose set of
formulas is the union of all RDF 𝑛 formulas with 𝑛 ∈ N (hence we have a differentiation operator 𝐷𝑖 [ ]
for every natural number 𝑖); the intended semantics will refer to the real functions of class 𝐢 ∞ . The
decision algorithm will proceed in full analogy with the one of each RDF 𝑛 ; the correctness proof seems
more challenging, though, because the interpolating method needs to accommodate an arbitrarily high
number of derivative constraints. Thus far, we have no evidence in favor or against the existence of the
sought 𝐢 ∞ interpolant.


References
 [1] Buriola G., Cantone D., Cincotti G., Omodeo E.G., SpartΓ  G.T., A decidable theory treating addition of differentiable real
     functions. Theoretical Computer Science, 940:124-148, 2023.
 [2] Buriola G., Cantone D., Cincotti G., Omodeo E.G., SpartΓ  G.T., A decidable theory of differentiable functions with
     convexities and concavities on real intervals. In Francesco Calimeri, Simona Perri, and Ester Zumpano, eds, Proceedings
     of the 35th Italian Conference on Computational Logic - CILC 2020, Rende, Italy, October 13-15, 2020, CEUR Workshop
     Proceedings, 2710:231-247. CEUR-WS.org, 2020.
 [3] Cantone D., Cincotti G., Gallo G., Decision algorithms for fragments of real analysis. I. Continuous functions with strict
     convexity and concavity predicates. J. Symb. Comput., 41(7):763-789, 2006.
 [4] Cantone D., Cincotti G., Decision algorithms for fragments of real analysis. II. A theory of differentiable functions with
     convexity and concavity predicates. List of CILC 2007 papers, 14 pp., 2007. https://www.programmazionelogica.it/
     wp-content/uploads/2014/10/cilc2007.pdf
 [5] Cantone D., Ferro A., Omodeo E.G., Schwartz J.T., Decision algorithms for some fragments of analysis and related areas.
     Comm. Pure Appl. Math., 40(3):281-300, 1987.
 [6] Cantone D., Omodeo E.G., SpartΓ  G.T., Solvable (and unsolvable) cases of the decision problem for fragments of analysis.
     Rend. Istit. Mat. Univ. Trieste, 44:313-348, 2012.
 [7] Caviness B.F., On Canonical Forms and Simplification, Journal of the ACM 17 (2) (1970), 385β€”396.
 [8] Cincotti G., Decision algorithms for fragments of real analysis and graph theory, Ph.D. Thesis, UniversitΓ  degli Studi di
     Catania, Catania, Italy, ix+136 pp., 2000.
 [9] Collins G., Quantifier elimination for real closed fields by cylindrical algebraic decomposition. In: Second GI Conference
     on Automata Theory and Formal Languages, LNCS Vol.33, Springer-Verlag, Berlin, 1975.
[10] Goodman T.N.T., Shape preserving interpolation by curves, Algorithms for Approximation IV, editors Levesley J., Anderson
     I. and Mason J., 2002.
[11] Friedman H. and Seress Á., Decidability in elementary analysis. I, Adv. Math. 76 (1989), no. 1, 94–115.
[12] Friedman H. and Seress Á., Decidability in elementary analysis. II, Adv. Math. 79 (1990), no. 1, 1–17.
[13] Laczkovich M., The removal of πœ‹ from some undecidable problems involving elementary functions, Proceedings of the
     AMS 131 (7) (2002), 2235β€”2240.
[14] Macintyre, A. and Wilkie, A.J., On the Decidability of the Real Exponential Field, Kreiseliana. About and Around Georg
     Kreisel, (1996), 441–467.
[15] Manni C., On Shape Preserving 𝐢 2 Hermite Interpolation, BIT Numerical Mathematics, vol. 41 (2001), pp. 127–148.
[16] Mendelson, E., Introduction to Mathematical Logic, CRC Press, Discrete Mathematics and Its Applications, 2015 ISBN
     9781482237788.
[17] Nelson, G. and Oppen, D.C., Simplification by cooperating decision procedures, ACM Trans. on Programming Languages
     and Systems 1(2) (1979), 245–257.
[18] Nelson, G. and Oppen, D.C., Fast decision procedures based on congruence closure, Journal of the ACM 27(2) (1980),
     356–364.
[19] Renegar J., A faster PSPACE algorithm for deciding the existential theory of the reals, 29th Annual Symposium on
     Foundations of Computer Science (FOCS 1988, Los Angeles, Ca., USA), IEEE Computer Society Press, Los Alamitos
     (1988), pp. 291–295.
[20] Richardson D., Some undecidable problems involving elementary functions of a real variable, J. Symbolic Logic 33 (1968),
     514–520.
[21] Schwartz J.T., Cantone D., Omodeo E.G., Computational logic and set theory: Applying formalized logic to analysis.
     Springer-Verlag, 2011. ISBN 978-0-85729-807-2. Foreword by M. Davis.
[22] Tarski A., The completeness of elementary algebra and geometry, Institut Blaise Pascal, Paris, 1967, iv+50 pp. (Late
     publication of a paper which had been submitted for publication in 1940)
[23] Tarski A., A decision method for elementary algebra and geometry, prepared for publication by J.C.C McKinsey, U.S
     Air Force Project RAND, R-109, the RAND Corporation, Santa Monica, 1948, iv+60 pp.; a second, revised edition was
     published by the University of California Press, Berkeley and Los Angeles, CA, 1951, iii+63 pp.
[24] Wang P.S., The undecidability of the existence of zeros of real elementary functions, Journal of the ACM 21 (4) (1974),
     586-589.