Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

special casing for functions with only one instance #41

Open
polgreen opened this issue Feb 6, 2018 · 1 comment
Open

special casing for functions with only one instance #41

polgreen opened this issue Feb 6, 2018 · 1 comment

Comments

@polgreen
Copy link
Collaborator

polgreen commented Feb 6, 2018

Implement special casing for functions with only one instance (as in CVC4), do performance comparison

@polgreen polgreen added this to the Algorithmic alternatives milestone Feb 6, 2018
@polgreen polgreen removed this from the Algorithmic alternatives milestone Feb 7, 2018
@cristina-david
Copy link
Collaborator

@pkesseli Here is the decidable fragment of Strong-Single Invocation (SSI) for Conditional Linear Integer Arithmetic (CLIA) from https://arxiv.org/abs/1802.04428. This should be easy to implement.

If the specification is \exists f. \forall x. \phi(f, x), then a formula is in SSI if:

  1. f only occurs in \phi as f(t);
  2. in each atomic formula, f(t) occurs at most once.

As SSI is single invocation, we have \exists f. \forall x. \phi(f, x) logically equivalent to \forall x.\exists z.\phi(z, x). Then, we assume \phi(z, x) is normalized such that every atomic formula is in the form of z>=t(x) or z<=t(x).

Let the set of terms involving x be T, then, for any x, the value of f(x) is always a term from T. Hence, we can build an implementation by enumerating every term t_i(x) in T as the value of f(x) and check if \phi(t_i(x), x) is satisfied:

f(x) = ite(\phi(t_1(x), x), t_1(x),
ite(\phi(t_2(x), x), t_2(x),
ite(...)))

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants