Aggregates for CHR through Program Transformation

  • Authors:
  • Peter Weert;Jon Sneyers;Bart Demoen

  • Affiliations:
  • Department of Computer Science, K.U.Leuven, Belgium;Department of Computer Science, K.U.Leuven, Belgium;Department of Computer Science, K.U.Leuven, Belgium

  • Venue:
  • Logic-Based Program Synthesis and Transformation
  • Year:
  • 2008

Quantified Score

Hi-index 0.01

Visualization

Abstract

We propose an extension of Constraint Handling Rules (CHR) with aggregates such as sum, count, findall, and min. This new feature significantly improves the conciseness and expressiveness of the language. In this paper, we describe an implementation based on source-to-source transformations to CHR (extended with some low-level compiler directives). We allow user-defined aggregates and nested aggregate expressions over arbitrary guarded conjunctions of constraints. Both an on-demand and an incremental aggregate computation strategy are supported.