<!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 />
    <article-meta>
      <contrib-group>
        <contrib contrib-type="author">
          <string-name>Fabian Zaiser</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Luke Ong</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <aff id="aff0">
          <label>0</label>
          <institution>University of Oxford</institution>
          ,
          <country country="UK">United Kingdom</country>
        </aff>
      </contrib-group>
      <abstract>
        <p>The first-order theory of algebraic datatypes (and codatatypes) is an important theory implemented in many SMT solvers. It is related to the theory of finite and infinite trees, which has been studied since the eighties, especially by the logic programming community. Following Djelloul, Dao and Frühwirth, we consider an extension of the latter theory with an additional predicate for finiteness of trees, which is useful for expressing properties about (not just datatypes but also) codatatypes. Based on their work, we present a simplification procedure that determines whether any given (not necessarily closed) formula is satisfiable, returning a simplified formula which enables one to read of all possible models. Our extension makes the algorithm usable for algebraic (co)datatypes, which was impossible in their original work due to restrictive assumptions. To this end, we clarify the relationship between the two theories and describe a translation procedure. We find that trees are in some ways more expressive than (co)datatypes while preserving decidability, which makes them interesting for SMT applications. We also provide a prototype implementation of our simplification procedure and evaluate it on instances from the SMT-LIB. The full article (DOI: 10.4204/EPTCS.320.14) is published in the proceedings of the 2020 ETAPS workshop Horn Clauses for Verification and Synthesis .</p>
      </abstract>
      <kwd-group>
        <kwd>eol&gt;theory of trees</kwd>
        <kwd>decision procedure</kwd>
        <kwd>first-order theory</kwd>
        <kwd>algebraic datatypes</kwd>
        <kwd>inductive datatypes</kwd>
        <kwd>coinductive datatypes</kwd>
      </kwd-group>
    </article-meta>
  </front>
  <body />
  <back>
    <ref-list />
  </back>
</article>