Counting in Trees for Free [chapter]

Helmut Seidl, Thomas Schwentick, Anca Muscholl, Peter Habermehl
2004 Lecture Notes in Computer Science  
It is known that MSO logic for ordered unranked trees is undecidable if Presburger constraints are allowed at children of nodes. We show here that a decidable logic is obtained if we use a modal fixpoint logic instead. We present a characterization of this logic by means of deterministic Presburger tree automata and show how it can be used to express numerical document queries. Surprisingly, the complexity of satisfiability for the extended logic is asymptotically the same as for the original
more » ... xpoint logic. The non-emptiness for Presburger tree automata (PTA) is PSPACEcomplete, which is moderate given that it is already PSPACE-hard to test whether the complement of a regular expression is non-empty. We also identify a subclass of PTAs with a tractable non-emptiness problem. Further, to decide whether a tree Ø satisfies a formula ³ is polynomial in the size of ³ and linear in the size of Ø. A technical construction of independent interest is a linear time construction of a Presburger formula for the Parikh image of a regular language.
doi:10.1007/978-3-540-27836-8_94 fatcat:xa5ds54akbad5h6ex2mtmqm5x4