Evaluation of Logic Programs with Built-Ins and Aggregation: A Calculus for Bag Relations

10/20/2020
by   Matthew Francis-Landau, et al.
0

We present a scheme for translating logic programs, which may use aggregation and arithmetic, into algebraic expressions that denote bag relations over ground terms of the Herbrand universe. To evaluate queries against these relations, we develop an operational semantics based on term rewriting of the algebraic expressions. This approach can exploit arithmetic identities and recovers a range of useful strategies, including lazy strategies that defer work until it becomes possible or necessary.

READ FULL TEXT

page 1

page 2

page 3

page 4

research
01/27/2021

Tutorial on implementing Hoare logic for imperative programs in Haskell

Using the programming language Haskell, we introduce an implementation o...
research
02/13/2019

Snapshot Semantics for Temporal Multiset Relations (Extended Version)

Snapshot semantics is widely used for evaluating queries over temporal d...
research
02/20/2020

Constructive Game Logic

Game Logic is an excellent setting to study proofs-about-programs via th...
research
12/30/2020

Notes on Computational Graph and Jacobian Accumulation

The optimal calculation order of a computational graph can be represente...
research
05/11/2023

Simplification of General Mixed Boolean-Arithmetic Expressions: GAMBA

Malware code often resorts to various self-protection techniques to comp...
research
01/08/2013

Language ASPf with Arithmetic Expressions and Consistency-Restoring Rules

In this paper we continue the work on our extension of Answer Set Progra...
research
04/06/2022

An Algebraic Approach to Learning and Grounding

We consider the problem of learning the semantics of composite algebraic...

Please sign up or login with your details

Forgot password? Click here to reset