Quantifier Elimination Helpful lemmas Let S be a set of sentences. - - PowerPoint PPT Presentation

quantifier elimination helpful lemmas
SMART_READER_LITE
LIVE PREVIEW

Quantifier Elimination Helpful lemmas Let S be a set of sentences. - - PowerPoint PPT Presentation

Quantifier Elimination Helpful lemmas Let S be a set of sentences. Helpful lemmas Let S be a set of sentences. Lemma S | = F iff S | = F Helpful lemmas Let S be a set of sentences. Lemma S | = F iff S | = F Lemma If S | = F G then


slide-1
SLIDE 1

Quantifier Elimination

slide-2
SLIDE 2

Helpful lemmas

Let S be a set of sentences.

slide-3
SLIDE 3

Helpful lemmas

Let S be a set of sentences.

Lemma

S | = F iff S | = ∀F

slide-4
SLIDE 4

Helpful lemmas

Let S be a set of sentences.

Lemma

S | = F iff S | = ∀F

Lemma

If S | = F ↔ G then S | = H[F] ↔ H[G],

slide-5
SLIDE 5

Helpful lemmas

Let S be a set of sentences.

Lemma

S | = F iff S | = ∀F

Lemma

If S | = F ↔ G then S | = H[F] ↔ H[G], i.e. one can replace a subterm F of H by G.

slide-6
SLIDE 6

Quantifier elimination

slide-7
SLIDE 7

Quantifier elimination

Definition

If T | = F ↔ F ′ we say that F and F ′ are T-equivalent.

slide-8
SLIDE 8

Quantifier elimination

Definition

If T | = F ↔ F ′ we say that F and F ′ are T-equivalent.

Definition

A theory T admits quantifier elimination if for every formula F there is a quantifier-free T-equivalent formula G

slide-9
SLIDE 9

Quantifier elimination

Definition

If T | = F ↔ F ′ we say that F and F ′ are T-equivalent.

Definition

A theory T admits quantifier elimination if for every formula F there is a quantifier-free T-equivalent formula G such that fv(G) ⊆ fv(F).

slide-10
SLIDE 10

Quantifier elimination

Definition

If T | = F ↔ F ′ we say that F and F ′ are T-equivalent.

Definition

A theory T admits quantifier elimination if for every formula F there is a quantifier-free T-equivalent formula G such that fv(G) ⊆ fv(F). We call G a quantifier-free T-equivalent of F.

slide-11
SLIDE 11

Quantifier elimination

Definition

If T | = F ↔ F ′ we say that F and F ′ are T-equivalent.

Definition

A theory T admits quantifier elimination if for every formula F there is a quantifier-free T-equivalent formula G such that fv(G) ⊆ fv(F). We call G a quantifier-free T-equivalent of F.

Examples

In linear real arithmetic: ∃x∃y (3 ∗ x + 5 ∗ y = 7) ↔ ?

slide-12
SLIDE 12

Quantifier elimination

Definition

If T | = F ↔ F ′ we say that F and F ′ are T-equivalent.

Definition

A theory T admits quantifier elimination if for every formula F there is a quantifier-free T-equivalent formula G such that fv(G) ⊆ fv(F). We call G a quantifier-free T-equivalent of F.

Examples

In linear real arithmetic: ∃x∃y (3 ∗ x + 5 ∗ y = 7) ↔ ? ∀y (x < y ∧ y < z) ↔ ?

slide-13
SLIDE 13

Quantifier elimination

Definition

If T | = F ↔ F ′ we say that F and F ′ are T-equivalent.

Definition

A theory T admits quantifier elimination if for every formula F there is a quantifier-free T-equivalent formula G such that fv(G) ⊆ fv(F). We call G a quantifier-free T-equivalent of F.

Examples

In linear real arithmetic: ∃x∃y (3 ∗ x + 5 ∗ y = 7) ↔ ? ∀y (x < y ∧ y < z) ↔ ? ∃y (x < y ∧ y < z) ↔ ?

slide-14
SLIDE 14

Quantifier elimination

slide-15
SLIDE 15

Quantifier elimination

A quantifier-elimination procedure (QEP) for a theory T and a set

  • f formulas F is a function that computes for every F ∈ F a

quantifier-free T-equivalent.

slide-16
SLIDE 16

Quantifier elimination

A quantifier-elimination procedure (QEP) for a theory T and a set

  • f formulas F is a function that computes for every F ∈ F a

quantifier-free T-equivalent.

Lemma

Let T be a theory such that

◮ T has a QEP for all formulas and ◮ for all ground formulas G, T |

= G or T | = ¬G, and it is decidable which is the case.

slide-17
SLIDE 17

Quantifier elimination

A quantifier-elimination procedure (QEP) for a theory T and a set

  • f formulas F is a function that computes for every F ∈ F a

quantifier-free T-equivalent.

Lemma

Let T be a theory such that

◮ T has a QEP for all formulas and ◮ for all ground formulas G, T |

= G or T | = ¬G, and it is decidable which is the case. Then T is decidable and complete.

slide-18
SLIDE 18

Simplifying quantifier elimination: one ∃

slide-19
SLIDE 19

Simplifying quantifier elimination: one ∃

Fact

If T has a QEP for all ∃x F where F is quantifier-free, then T has a QEP for all formulas.

slide-20
SLIDE 20

Simplifying quantifier elimination: one ∃

Fact

If T has a QEP for all ∃x F where F is quantifier-free, then T has a QEP for all formulas. Essence: It is sufficient to be able to eliminate a single ∃

slide-21
SLIDE 21

Simplifying quantifier elimination: one ∃

Fact

If T has a QEP for all ∃x F where F is quantifier-free, then T has a QEP for all formulas. Essence: It is sufficient to be able to eliminate a single ∃ Construction:

slide-22
SLIDE 22

Simplifying quantifier elimination: one ∃

Fact

If T has a QEP for all ∃x F where F is quantifier-free, then T has a QEP for all formulas. Essence: It is sufficient to be able to eliminate a single ∃ Construction: Given: a QEP qe1 for formulas of the form ∃x F where F is quantifier-free

slide-23
SLIDE 23

Simplifying quantifier elimination: one ∃

Fact

If T has a QEP for all ∃x F where F is quantifier-free, then T has a QEP for all formulas. Essence: It is sufficient to be able to eliminate a single ∃ Construction: Given: a QEP qe1 for formulas of the form ∃x F where F is quantifier-free Define: a QEP for all formulas

slide-24
SLIDE 24

Simplifying quantifier elimination: one ∃

Fact

If T has a QEP for all ∃x F where F is quantifier-free, then T has a QEP for all formulas. Essence: It is sufficient to be able to eliminate a single ∃ Construction: Given: a QEP qe1 for formulas of the form ∃x F where F is quantifier-free Define: a QEP for all formulas Method: Eliminate quantifiers bottom-up by qe1, use ∀ ≡ ¬∃¬

slide-25
SLIDE 25

Simplifying quantifier elimination: ∃x literals

slide-26
SLIDE 26

Simplifying quantifier elimination: ∃x literals

Lemma

If T has a QEP for all ∃x F where F is a conjunction of literals, all of which contain x, then T has a QEP for all ∃x F where F is quantifier-free.

slide-27
SLIDE 27

Simplifying quantifier elimination: ∃x literals

Lemma

If T has a QEP for all ∃x F where F is a conjunction of literals, all of which contain x, then T has a QEP for all ∃x F where F is quantifier-free. Construction:

slide-28
SLIDE 28

Simplifying quantifier elimination: ∃x literals

Lemma

If T has a QEP for all ∃x F where F is a conjunction of literals, all of which contain x, then T has a QEP for all ∃x F where F is quantifier-free. Construction: Given: a QEP qe1c for formulas of the form ∃x (L1 ∧ · · · ∧ Ln) where each Li is a literal that contains x

slide-29
SLIDE 29

Simplifying quantifier elimination: ∃x literals

Lemma

If T has a QEP for all ∃x F where F is a conjunction of literals, all of which contain x, then T has a QEP for all ∃x F where F is quantifier-free. Construction: Given: a QEP qe1c for formulas of the form ∃x (L1 ∧ · · · ∧ Ln) where each Li is a literal that contains x Define: qe1(∃x F) where F is quantifier-free

slide-30
SLIDE 30

Simplifying quantifier elimination: ∃x literals

Lemma

If T has a QEP for all ∃x F where F is a conjunction of literals, all of which contain x, then T has a QEP for all ∃x F where F is quantifier-free. Construction: Given: a QEP qe1c for formulas of the form ∃x (L1 ∧ · · · ∧ Ln) where each Li is a literal that contains x Define: qe1(∃x F) where F is quantifier-free Method: DNF; miniscoping; qe1c

slide-31
SLIDE 31

Simplifying quantifier elimination: ∃x literals

Lemma

If T has a QEP for all ∃x F where F is a conjunction of literals, all of which contain x, then T has a QEP for all ∃x F where F is quantifier-free. Construction: Given: a QEP qe1c for formulas of the form ∃x (L1 ∧ · · · ∧ Ln) where each Li is a literal that contains x Define: qe1(∃x F) where F is quantifier-free Method: DNF; miniscoping; qe1c This is the end of the generic part of quantifier elimination.

slide-32
SLIDE 32

Simplifying quantifier elimination: ∃x literals

Lemma

If T has a QEP for all ∃x F where F is a conjunction of literals, all of which contain x, then T has a QEP for all ∃x F where F is quantifier-free. Construction: Given: a QEP qe1c for formulas of the form ∃x (L1 ∧ · · · ∧ Ln) where each Li is a literal that contains x Define: qe1(∃x F) where F is quantifier-free Method: DNF; miniscoping; qe1c This is the end of the generic part of quantifier elimination. The rest is theory specific.

slide-33
SLIDE 33

Eliminating “¬”

slide-34
SLIDE 34

Eliminating “¬”

Motivation: ¬x < y ↔ y < x ∨ y = x for linear orderings

slide-35
SLIDE 35

Eliminating “¬”

Motivation: ¬x < y ↔ y < x ∨ y = x for linear orderings Assume that there is a computable function aneg that maps every negated atom to a quantifier-free and negation-free T-equivalent formula.

slide-36
SLIDE 36

Eliminating “¬”

Motivation: ¬x < y ↔ y < x ∨ y = x for linear orderings Assume that there is a computable function aneg that maps every negated atom to a quantifier-free and negation-free T-equivalent formula.

Lemma

If T has a QEP for all ∃x F where F is a conjunction of atoms, all of which contain x, then T has a QEP for all ∃x F where F is quantifier-free.

slide-37
SLIDE 37

Eliminating “¬”

Motivation: ¬x < y ↔ y < x ∨ y = x for linear orderings Assume that there is a computable function aneg that maps every negated atom to a quantifier-free and negation-free T-equivalent formula.

Lemma

If T has a QEP for all ∃x F where F is a conjunction of atoms, all of which contain x, then T has a QEP for all ∃x F where F is quantifier-free. Construction:

slide-38
SLIDE 38

Eliminating “¬”

Motivation: ¬x < y ↔ y < x ∨ y = x for linear orderings Assume that there is a computable function aneg that maps every negated atom to a quantifier-free and negation-free T-equivalent formula.

Lemma

If T has a QEP for all ∃x F where F is a conjunction of atoms, all of which contain x, then T has a QEP for all ∃x F where F is quantifier-free. Construction: Given: a QEP qe1ca for formulas of the form ∃x (A1 ∧ · · · ∧ An) where each atom Ai contains x

slide-39
SLIDE 39

Eliminating “¬”

Motivation: ¬x < y ↔ y < x ∨ y = x for linear orderings Assume that there is a computable function aneg that maps every negated atom to a quantifier-free and negation-free T-equivalent formula.

Lemma

If T has a QEP for all ∃x F where F is a conjunction of atoms, all of which contain x, then T has a QEP for all ∃x F where F is quantifier-free. Construction: Given: a QEP qe1ca for formulas of the form ∃x (A1 ∧ · · · ∧ An) where each atom Ai contains x Define: qe1(∃x F) where F quantifier-free

slide-40
SLIDE 40

Eliminating “¬”

Motivation: ¬x < y ↔ y < x ∨ y = x for linear orderings Assume that there is a computable function aneg that maps every negated atom to a quantifier-free and negation-free T-equivalent formula.

Lemma

If T has a QEP for all ∃x F where F is a conjunction of atoms, all of which contain x, then T has a QEP for all ∃x F where F is quantifier-free. Construction: Given: a QEP qe1ca for formulas of the form ∃x (A1 ∧ · · · ∧ An) where each atom Ai contains x Define: qe1(∃x F) where F quantifier-free Method: NNF; aneg; DNF; miniscoping; qe1ca

slide-41
SLIDE 41

Quantifier Elimination

Dense Linear Orders Without Endpoints

slide-42
SLIDE 42

Dense Linear Orders Without Endpoints

Σ = {<, =}

slide-43
SLIDE 43

Dense Linear Orders Without Endpoints

Σ = {<, =} Let DLO stand for “dense linear order without endpoints” and for the following set of axioms:

slide-44
SLIDE 44

Dense Linear Orders Without Endpoints

Σ = {<, =} Let DLO stand for “dense linear order without endpoints” and for the following set of axioms: ∀x∀y∀z (x < y ∧ y < z → x < z)

slide-45
SLIDE 45

Dense Linear Orders Without Endpoints

Σ = {<, =} Let DLO stand for “dense linear order without endpoints” and for the following set of axioms: ∀x∀y∀z (x < y ∧ y < z → x < z) ∀x ¬(x < x)

slide-46
SLIDE 46

Dense Linear Orders Without Endpoints

Σ = {<, =} Let DLO stand for “dense linear order without endpoints” and for the following set of axioms: ∀x∀y∀z (x < y ∧ y < z → x < z) ∀x ¬(x < x) ∀x∀y (x < y ∨ x = y ∨ y < x)

slide-47
SLIDE 47

Dense Linear Orders Without Endpoints

Σ = {<, =} Let DLO stand for “dense linear order without endpoints” and for the following set of axioms: ∀x∀y∀z (x < y ∧ y < z → x < z) ∀x ¬(x < x) ∀x∀y (x < y ∨ x = y ∨ y < x) ∀x∀z (x < z → ∃y (x < y ∧ y < z)

slide-48
SLIDE 48

Dense Linear Orders Without Endpoints

Σ = {<, =} Let DLO stand for “dense linear order without endpoints” and for the following set of axioms: ∀x∀y∀z (x < y ∧ y < z → x < z) ∀x ¬(x < x) ∀x∀y (x < y ∨ x = y ∨ y < x) ∀x∀z (x < z → ∃y (x < y ∧ y < z) ∀x∃y x < y

slide-49
SLIDE 49

Dense Linear Orders Without Endpoints

Σ = {<, =} Let DLO stand for “dense linear order without endpoints” and for the following set of axioms: ∀x∀y∀z (x < y ∧ y < z → x < z) ∀x ¬(x < x) ∀x∀y (x < y ∨ x = y ∨ y < x) ∀x∀z (x < z → ∃y (x < y ∧ y < z) ∀x∃y x < y ∀x∃y y < x

slide-50
SLIDE 50

Dense Linear Orders Without Endpoints

Σ = {<, =} Let DLO stand for “dense linear order without endpoints” and for the following set of axioms: ∀x∀y∀z (x < y ∧ y < z → x < z) ∀x ¬(x < x) ∀x∀y (x < y ∨ x = y ∨ y < x) ∀x∀z (x < z → ∃y (x < y ∧ y < z) ∀x∃y x < y ∀x∃y y < x Models of DLO?

slide-51
SLIDE 51

Dense Linear Orders Without Endpoints

Σ = {<, =} Let DLO stand for “dense linear order without endpoints” and for the following set of axioms: ∀x∀y∀z (x < y ∧ y < z → x < z) ∀x ¬(x < x) ∀x∀y (x < y ∨ x = y ∨ y < x) ∀x∀z (x < z → ∃y (x < y ∧ y < z) ∀x∃y x < y ∀x∃y y < x Models of DLO?

Theorem

All countable DLOs are isomorphic.

slide-52
SLIDE 52

Quantifier elimination example

Example

DLO | = ∃y (x < y ∧ y < z) ↔

slide-53
SLIDE 53

Eliminiation of “¬”

Elimination of negative literals (function aneg): DLO | = ¬x = y ↔ x < y ∨ y < x DLO | = ¬x < y ↔ x = y ∨ y < x

slide-54
SLIDE 54

Quantifier elimination for conjunctions of atoms

slide-55
SLIDE 55

Quantifier elimination for conjunctions of atoms

QEP qe1ca(∃x (A1 ∧ · · · ∧ An) where x occurs in all Ai:

slide-56
SLIDE 56

Quantifier elimination for conjunctions of atoms

QEP qe1ca(∃x (A1 ∧ · · · ∧ An) where x occurs in all Ai:

  • 1. Eliminate “=”:
slide-57
SLIDE 57

Quantifier elimination for conjunctions of atoms

QEP qe1ca(∃x (A1 ∧ · · · ∧ An) where x occurs in all Ai:

  • 1. Eliminate “=”: Drop all Ai of the form x = x.
slide-58
SLIDE 58

Quantifier elimination for conjunctions of atoms

QEP qe1ca(∃x (A1 ∧ · · · ∧ An) where x occurs in all Ai:

  • 1. Eliminate “=”: Drop all Ai of the form x = x.

If some Ai is of the form x = y (x and y different), eliminate ∃x:

slide-59
SLIDE 59

Quantifier elimination for conjunctions of atoms

QEP qe1ca(∃x (A1 ∧ · · · ∧ An) where x occurs in all Ai:

  • 1. Eliminate “=”: Drop all Ai of the form x = x.

If some Ai is of the form x = y (x and y different), eliminate ∃x: ∃x (x = t ∧ F) ≡ F[t/x] (x does not occur in t)

slide-60
SLIDE 60

Quantifier elimination for conjunctions of atoms

QEP qe1ca(∃x (A1 ∧ · · · ∧ An) where x occurs in all Ai:

  • 1. Eliminate “=”: Drop all Ai of the form x = x.

If some Ai is of the form x = y (x and y different), eliminate ∃x: ∃x (x = t ∧ F) ≡ F[t/x] (x does not occur in t) Otherwise:

slide-61
SLIDE 61

Quantifier elimination for conjunctions of atoms

QEP qe1ca(∃x (A1 ∧ · · · ∧ An) where x occurs in all Ai:

  • 1. Eliminate “=”: Drop all Ai of the form x = x.

If some Ai is of the form x = y (x and y different), eliminate ∃x: ∃x (x = t ∧ F) ≡ F[t/x] (x does not occur in t) Otherwise:

  • 2. Eliminate x < x: return ⊥
slide-62
SLIDE 62

Quantifier elimination for conjunctions of atoms

QEP qe1ca(∃x (A1 ∧ · · · ∧ An) where x occurs in all Ai:

  • 1. Eliminate “=”: Drop all Ai of the form x = x.

If some Ai is of the form x = y (x and y different), eliminate ∃x: ∃x (x = t ∧ F) ≡ F[t/x] (x does not occur in t) Otherwise:

  • 2. Eliminate x < x: return ⊥
  • 3. Separate atoms into lower and upper bounds for x and use

DLO | = ∃x(

m

  • i=1

li < x ∧

n

  • j=1

x < uj) ↔

m

  • i=1

n

  • j=1

li < uj

slide-63
SLIDE 63

Quantifier elimination for conjunctions of atoms

QEP qe1ca(∃x (A1 ∧ · · · ∧ An) where x occurs in all Ai:

  • 1. Eliminate “=”: Drop all Ai of the form x = x.

If some Ai is of the form x = y (x and y different), eliminate ∃x: ∃x (x = t ∧ F) ≡ F[t/x] (x does not occur in t) Otherwise:

  • 2. Eliminate x < x: return ⊥
  • 3. Separate atoms into lower and upper bounds for x and use

DLO | = ∃x(

m

  • i=1

li < x ∧

n

  • j=1

x < uj) ↔

m

  • i=1

n

  • j=1

li < uj Special case: 0

k=1 Fk = ⊤

slide-64
SLIDE 64

Quantifier elimination for conjunctions of atoms

QEP qe1ca(∃x (A1 ∧ · · · ∧ An) where x occurs in all Ai:

  • 1. Eliminate “=”: Drop all Ai of the form x = x.

If some Ai is of the form x = y (x and y different), eliminate ∃x: ∃x (x = t ∧ F) ≡ F[t/x] (x does not occur in t) Otherwise:

  • 2. Eliminate x < x: return ⊥
  • 3. Separate atoms into lower and upper bounds for x and use

DLO | = ∃x(

m

  • i=1

li < x ∧

n

  • j=1

x < uj) ↔

m

  • i=1

n

  • j=1

li < uj Special case: 0

k=1 Fk = ⊤

Examples

∃x (x < z ∧ y < x ∧ x < y′) ↔ ?

slide-65
SLIDE 65

Quantifier elimination for conjunctions of atoms

QEP qe1ca(∃x (A1 ∧ · · · ∧ An) where x occurs in all Ai:

  • 1. Eliminate “=”: Drop all Ai of the form x = x.

If some Ai is of the form x = y (x and y different), eliminate ∃x: ∃x (x = t ∧ F) ≡ F[t/x] (x does not occur in t) Otherwise:

  • 2. Eliminate x < x: return ⊥
  • 3. Separate atoms into lower and upper bounds for x and use

DLO | = ∃x(

m

  • i=1

li < x ∧

n

  • j=1

x < uj) ↔

m

  • i=1

n

  • j=1

li < uj Special case: 0

k=1 Fk = ⊤

Examples

∃x (x < z ∧ y < x ∧ x < y′) ↔ ? ∀x (x < y) ↔ ?

slide-66
SLIDE 66

Quantifier elimination for conjunctions of atoms

QEP qe1ca(∃x (A1 ∧ · · · ∧ An) where x occurs in all Ai:

  • 1. Eliminate “=”: Drop all Ai of the form x = x.

If some Ai is of the form x = y (x and y different), eliminate ∃x: ∃x (x = t ∧ F) ≡ F[t/x] (x does not occur in t) Otherwise:

  • 2. Eliminate x < x: return ⊥
  • 3. Separate atoms into lower and upper bounds for x and use

DLO | = ∃x(

m

  • i=1

li < x ∧

n

  • j=1

x < uj) ↔

m

  • i=1

n

  • j=1

li < uj Special case: 0

k=1 Fk = ⊤

Examples

∃x (x < z ∧ y < x ∧ x < y′) ↔ ? ∀x (x < y) ↔ ? ∃x∃y∃z (x < y ∧ y < z ∧ z < x) ↔ ?

slide-67
SLIDE 67

Complexity

slide-68
SLIDE 68

Complexity

Quadratic blow-up with each elimination step

slide-69
SLIDE 69

Complexity

Quadratic blow-up with each elimination step ⇒ Eliminating all ∃ from ∃x1 . . . ∃xm F where F has length n needs O( ), assuming F is DNF.

slide-70
SLIDE 70

Complexity

Quadratic blow-up with each elimination step ⇒ Eliminating all ∃ from ∃x1 . . . ∃xm F where F has length n needs O(n2m), assuming F is DNF.

slide-71
SLIDE 71

Consequences

slide-72
SLIDE 72

Consequences

◮ Th(DLO) has quantifier elimination

slide-73
SLIDE 73

Consequences

◮ Th(DLO) has quantifier elimination ◮ Th(DLO) is decidable and complete

slide-74
SLIDE 74

Consequences

◮ Th(DLO) has quantifier elimination ◮ Th(DLO) is decidable and complete ◮ All models of DLO (for example (Q, <) and (R, <))

are elementarily equivalent:

slide-75
SLIDE 75

Consequences

◮ Th(DLO) has quantifier elimination ◮ Th(DLO) is decidable and complete ◮ All models of DLO (for example (Q, <) and (R, <))

are elementarily equivalent: you cannot distinguish models of DLO by first-order formulas.

slide-76
SLIDE 76

Quantifier Elimination

Linear real arithmetic

slide-77
SLIDE 77

Linear real arithmetic

R+ = (R, 0, 1, +, <, =), R+ = Th(R+)

slide-78
SLIDE 78

Linear real arithmetic

R+ = (R, 0, 1, +, <, =), R+ = Th(R+) For convenience we allow the following additional function symbols:

slide-79
SLIDE 79

Linear real arithmetic

R+ = (R, 0, 1, +, <, =), R+ = Th(R+) For convenience we allow the following additional function symbols: For every c ∈ Q:

slide-80
SLIDE 80

Linear real arithmetic

R+ = (R, 0, 1, +, <, =), R+ = Th(R+) For convenience we allow the following additional function symbols: For every c ∈ Q:

◮ c is a constant symbol

slide-81
SLIDE 81

Linear real arithmetic

R+ = (R, 0, 1, +, <, =), R+ = Th(R+) For convenience we allow the following additional function symbols: For every c ∈ Q:

◮ c is a constant symbol ◮ c·, multiplication with c, is a unary function symbol

slide-82
SLIDE 82

Linear real arithmetic

R+ = (R, 0, 1, +, <, =), R+ = Th(R+) For convenience we allow the following additional function symbols: For every c ∈ Q:

◮ c is a constant symbol ◮ c·, multiplication with c, is a unary function symbol

A term in normal form: c1 · x1 + . . . + cn · xn + c where ci = 0, xi = xj if i = j.

slide-83
SLIDE 83

Linear real arithmetic

R+ = (R, 0, 1, +, <, =), R+ = Th(R+) For convenience we allow the following additional function symbols: For every c ∈ Q:

◮ c is a constant symbol ◮ c·, multiplication with c, is a unary function symbol

A term in normal form: c1 · x1 + . . . + cn · xn + c where ci = 0, xi = xj if i = j. Every atom A is R+-equivalent to an atom 0 ⊲ ⊳ t in normal form (NF) where ⊲ ⊳ ∈ {<, =} and t is in normal form.

slide-84
SLIDE 84

Linear real arithmetic

R+ = (R, 0, 1, +, <, =), R+ = Th(R+) For convenience we allow the following additional function symbols: For every c ∈ Q:

◮ c is a constant symbol ◮ c·, multiplication with c, is a unary function symbol

A term in normal form: c1 · x1 + . . . + cn · xn + c where ci = 0, xi = xj if i = j. Every atom A is R+-equivalent to an atom 0 ⊲ ⊳ t in normal form (NF) where ⊲ ⊳ ∈ {<, =} and t is in normal form. An atom is solved for x if it is of the form x < t, x = t or t < x where x does not occur in t.

slide-85
SLIDE 85

Linear real arithmetic

R+ = (R, 0, 1, +, <, =), R+ = Th(R+) For convenience we allow the following additional function symbols: For every c ∈ Q:

◮ c is a constant symbol ◮ c·, multiplication with c, is a unary function symbol

A term in normal form: c1 · x1 + . . . + cn · xn + c where ci = 0, xi = xj if i = j. Every atom A is R+-equivalent to an atom 0 ⊲ ⊳ t in normal form (NF) where ⊲ ⊳ ∈ {<, =} and t is in normal form. An atom is solved for x if it is of the form x < t, x = t or t < x where x does not occur in t. Any atom A in normal form that contains x can be transformed into an R+-equivalent atom solved for x.

slide-86
SLIDE 86

Linear real arithmetic

R+ = (R, 0, 1, +, <, =), R+ = Th(R+) For convenience we allow the following additional function symbols: For every c ∈ Q:

◮ c is a constant symbol ◮ c·, multiplication with c, is a unary function symbol

A term in normal form: c1 · x1 + . . . + cn · xn + c where ci = 0, xi = xj if i = j. Every atom A is R+-equivalent to an atom 0 ⊲ ⊳ t in normal form (NF) where ⊲ ⊳ ∈ {<, =} and t is in normal form. An atom is solved for x if it is of the form x < t, x = t or t < x where x does not occur in t. Any atom A in normal form that contains x can be transformed into an R+-equivalent atom solved for x. Function solx(A) solves A for x.

slide-87
SLIDE 87

Eliminiation of “¬”

Elimination of negative literals (function aneg): R+ | = ¬x = y ↔ x < y ∨ y < x R+ | = ¬x < y ↔ x = y ∨ y < x

slide-88
SLIDE 88

Fourier-Motzkin Elimination

slide-89
SLIDE 89

Fourier-Motzkin Elimination

QEP qe1ca(∃x (A1 ∧ · · · ∧ An), all Ai in NF and contain x:

slide-90
SLIDE 90

Fourier-Motzkin Elimination

QEP qe1ca(∃x (A1 ∧ · · · ∧ An), all Ai in NF and contain x:

  • 1. Let S = {solx(A1), . . . , solx(An)}
slide-91
SLIDE 91

Fourier-Motzkin Elimination

QEP qe1ca(∃x (A1 ∧ · · · ∧ An), all Ai in NF and contain x:

  • 1. Let S = {solx(A1), . . . , solx(An)}
  • 2. Eliminate “=”:
slide-92
SLIDE 92

Fourier-Motzkin Elimination

QEP qe1ca(∃x (A1 ∧ · · · ∧ An), all Ai in NF and contain x:

  • 1. Let S = {solx(A1), . . . , solx(An)}
  • 2. Eliminate “=”:

If (x = t) ∈ S for some t, eliminate ∃x: ∃x (x = t ∧ F) ≡ F[t/x] (x does not occur in t)

slide-93
SLIDE 93

Fourier-Motzkin Elimination

QEP qe1ca(∃x (A1 ∧ · · · ∧ An), all Ai in NF and contain x:

  • 1. Let S = {solx(A1), . . . , solx(An)}
  • 2. Eliminate “=”:

If (x = t) ∈ S for some t, eliminate ∃x: ∃x (x = t ∧ F) ≡ F[t/x] (x does not occur in t) Otherwise return

  • (l<x)∈S
  • (x<u)∈S

l < u

slide-94
SLIDE 94

Fourier-Motzkin Elimination

QEP qe1ca(∃x (A1 ∧ · · · ∧ An), all Ai in NF and contain x:

  • 1. Let S = {solx(A1), . . . , solx(An)}
  • 2. Eliminate “=”:

If (x = t) ∈ S for some t, eliminate ∃x: ∃x (x = t ∧ F) ≡ F[t/x] (x does not occur in t) Otherwise return

  • (l<x)∈S
  • (x<u)∈S

l < u Special case: empty is ⊤

slide-95
SLIDE 95

Fourier-Motzkin Elimination

QEP qe1ca(∃x (A1 ∧ · · · ∧ An), all Ai in NF and contain x:

  • 1. Let S = {solx(A1), . . . , solx(An)}
  • 2. Eliminate “=”:

If (x = t) ∈ S for some t, eliminate ∃x: ∃x (x = t ∧ F) ≡ F[t/x] (x does not occur in t) Otherwise return

  • (l<x)∈S
  • (x<u)∈S

l < u Special case: empty is ⊤ All returned formulas are implicitly put into NF.

slide-96
SLIDE 96

Fourier-Motzkin Elimination

QEP qe1ca(∃x (A1 ∧ · · · ∧ An), all Ai in NF and contain x:

  • 1. Let S = {solx(A1), . . . , solx(An)}
  • 2. Eliminate “=”:

If (x = t) ∈ S for some t, eliminate ∃x: ∃x (x = t ∧ F) ≡ F[t/x] (x does not occur in t) Otherwise return

  • (l<x)∈S
  • (x<u)∈S

l < u Special case: empty is ⊤ All returned formulas are implicitly put into NF.

Examples

∃x∃y (3x + 5y < 7 ∧ 2z − 3y < 2) ↔ ?

slide-97
SLIDE 97

Fourier-Motzkin Elimination

QEP qe1ca(∃x (A1 ∧ · · · ∧ An), all Ai in NF and contain x:

  • 1. Let S = {solx(A1), . . . , solx(An)}
  • 2. Eliminate “=”:

If (x = t) ∈ S for some t, eliminate ∃x: ∃x (x = t ∧ F) ≡ F[t/x] (x does not occur in t) Otherwise return

  • (l<x)∈S
  • (x<u)∈S

l < u Special case: empty is ⊤ All returned formulas are implicitly put into NF.

Examples

∃x∃y (3x + 5y < 7 ∧ 2z − 3y < 2) ↔ ? ∃x∀y (3y ≤ x ∨ x ≤ 2y) ↔ ?

slide-98
SLIDE 98

Can DNF be avoided?

slide-99
SLIDE 99

Ferrante and Rackoff’s theorem

slide-100
SLIDE 100

Ferrante and Rackoff’s theorem

Theorem

Let F be quantifier-free and negation-free and assume all atoms that contain x are solved for x.

slide-101
SLIDE 101

Ferrante and Rackoff’s theorem

Theorem

Let F be quantifier-free and negation-free and assume all atoms that contain x are solved for x. Let Sx be the set of atoms that contain x.

slide-102
SLIDE 102

Ferrante and Rackoff’s theorem

Theorem

Let F be quantifier-free and negation-free and assume all atoms that contain x are solved for x. Let Sx be the set of atoms that contain x. Let L = {l | (l < x) ∈ Sx}, U = {u | (x < u) ∈ Sx}, E = {t | (x = t) ∈ Sx}.

slide-103
SLIDE 103

Ferrante and Rackoff’s theorem

Theorem

Let F be quantifier-free and negation-free and assume all atoms that contain x are solved for x. Let Sx be the set of atoms that contain x. Let L = {l | (l < x) ∈ Sx}, U = {u | (x < u) ∈ Sx}, E = {t | (x = t) ∈ Sx}. Then R+ | = ∃x F ↔ F[−∞/x] ∨ F[∞/x] ∨

  • t∈E

F[t/x] ∨

  • l∈L
  • u∈U

F[0.5(l + u)/x]

slide-104
SLIDE 104

Ferrante and Rackoff’s theorem

Theorem

Let F be quantifier-free and negation-free and assume all atoms that contain x are solved for x. Let Sx be the set of atoms that contain x. Let L = {l | (l < x) ∈ Sx}, U = {u | (x < u) ∈ Sx}, E = {t | (x = t) ∈ Sx}. Then R+ | = ∃x F ↔ F[−∞/x] ∨ F[∞/x] ∨

  • t∈E

F[t/x] ∨

  • l∈L
  • u∈U

F[0.5(l + u)/x] where F[−∞/x] (F[∞/x]) is the following transformation of all solved atoms in F: x < t → ⊤

slide-105
SLIDE 105

Ferrante and Rackoff’s theorem

Theorem

Let F be quantifier-free and negation-free and assume all atoms that contain x are solved for x. Let Sx be the set of atoms that contain x. Let L = {l | (l < x) ∈ Sx}, U = {u | (x < u) ∈ Sx}, E = {t | (x = t) ∈ Sx}. Then R+ | = ∃x F ↔ F[−∞/x] ∨ F[∞/x] ∨

  • t∈E

F[t/x] ∨

  • l∈L
  • u∈U

F[0.5(l + u)/x] where F[−∞/x] (F[∞/x]) is the following transformation of all solved atoms in F: x < t → ⊤ (⊥)

slide-106
SLIDE 106

Ferrante and Rackoff’s theorem

Theorem

Let F be quantifier-free and negation-free and assume all atoms that contain x are solved for x. Let Sx be the set of atoms that contain x. Let L = {l | (l < x) ∈ Sx}, U = {u | (x < u) ∈ Sx}, E = {t | (x = t) ∈ Sx}. Then R+ | = ∃x F ↔ F[−∞/x] ∨ F[∞/x] ∨

  • t∈E

F[t/x] ∨

  • l∈L
  • u∈U

F[0.5(l + u)/x] where F[−∞/x] (F[∞/x]) is the following transformation of all solved atoms in F: x < t → ⊤ (⊥) t < x → ⊥

slide-107
SLIDE 107

Ferrante and Rackoff’s theorem

Theorem

Let F be quantifier-free and negation-free and assume all atoms that contain x are solved for x. Let Sx be the set of atoms that contain x. Let L = {l | (l < x) ∈ Sx}, U = {u | (x < u) ∈ Sx}, E = {t | (x = t) ∈ Sx}. Then R+ | = ∃x F ↔ F[−∞/x] ∨ F[∞/x] ∨

  • t∈E

F[t/x] ∨

  • l∈L
  • u∈U

F[0.5(l + u)/x] where F[−∞/x] (F[∞/x]) is the following transformation of all solved atoms in F: x < t → ⊤ (⊥) t < x → ⊥ (⊤)

slide-108
SLIDE 108

Ferrante and Rackoff’s theorem

Theorem

Let F be quantifier-free and negation-free and assume all atoms that contain x are solved for x. Let Sx be the set of atoms that contain x. Let L = {l | (l < x) ∈ Sx}, U = {u | (x < u) ∈ Sx}, E = {t | (x = t) ∈ Sx}. Then R+ | = ∃x F ↔ F[−∞/x] ∨ F[∞/x] ∨

  • t∈E

F[t/x] ∨

  • l∈L
  • u∈U

F[0.5(l + u)/x] where F[−∞/x] (F[∞/x]) is the following transformation of all solved atoms in F: x < t → ⊤ (⊥) t < x → ⊥ (⊤) x = t → ⊥

slide-109
SLIDE 109

Ferrante and Rackoff’s theorem

Theorem

Let F be quantifier-free and negation-free and assume all atoms that contain x are solved for x. Let Sx be the set of atoms that contain x. Let L = {l | (l < x) ∈ Sx}, U = {u | (x < u) ∈ Sx}, E = {t | (x = t) ∈ Sx}. Then R+ | = ∃x F ↔ F[−∞/x] ∨ F[∞/x] ∨

  • t∈E

F[t/x] ∨

  • l∈L
  • u∈U

F[0.5(l + u)/x] where F[−∞/x] (F[∞/x]) is the following transformation of all solved atoms in F: x < t → ⊤ (⊥) t < x → ⊥ (⊤) x = t → ⊥ (⊥)

slide-110
SLIDE 110

Ferrante and Rackoff’s theorem

Theorem

Let F be quantifier-free and negation-free and assume all atoms that contain x are solved for x. Let Sx be the set of atoms that contain x. Let L = {l | (l < x) ∈ Sx}, U = {u | (x < u) ∈ Sx}, E = {t | (x = t) ∈ Sx}. Then R+ | = ∃x F ↔ F[−∞/x] ∨ F[∞/x] ∨

  • t∈E

F[t/x] ∨

  • l∈L
  • u∈U

F[0.5(l + u)/x] where F[−∞/x] (F[∞/x]) is the following transformation of all solved atoms in F: x < t → ⊤ (⊥) t < x → ⊥ (⊤) x = t → ⊥ (⊥)

Examples

∃x (y < x ∧ x < z) ↔ ?

slide-111
SLIDE 111

Ferrante and Rackoff’s theorem

Theorem

Let F be quantifier-free and negation-free and assume all atoms that contain x are solved for x. Let Sx be the set of atoms that contain x. Let L = {l | (l < x) ∈ Sx}, U = {u | (x < u) ∈ Sx}, E = {t | (x = t) ∈ Sx}. Then R+ | = ∃x F ↔ F[−∞/x] ∨ F[∞/x] ∨

  • t∈E

F[t/x] ∨

  • l∈L
  • u∈U

F[0.5(l + u)/x] where F[−∞/x] (F[∞/x]) is the following transformation of all solved atoms in F: x < t → ⊤ (⊥) t < x → ⊥ (⊤) x = t → ⊥ (⊥)

Examples

∃x (y < x ∧ x < z) ↔ ? ∃x x < y ↔ ?

slide-112
SLIDE 112

Ferrante and Rackoff’s procedure

slide-113
SLIDE 113

Ferrante and Rackoff’s procedure

Define qe1(∃x F):

slide-114
SLIDE 114

Ferrante and Rackoff’s procedure

Define qe1(∃x F):

  • 1. Put F into NNF, eliminate all negations,

put all atoms into normal form, solve those atoms for x that contain x.

slide-115
SLIDE 115

Ferrante and Rackoff’s procedure

Define qe1(∃x F):

  • 1. Put F into NNF, eliminate all negations,

put all atoms into normal form, solve those atoms for x that contain x.

  • 2. Apply Ferrante and Rackoff’s theorem.
slide-116
SLIDE 116

Ferrante and Rackoff’s procedure

Define qe1(∃x F):

  • 1. Put F into NNF, eliminate all negations,

put all atoms into normal form, solve those atoms for x that contain x.

  • 2. Apply Ferrante and Rackoff’s theorem.

Theorem

Eliminating all quantifiers with Ferrante and Rackoff’s procedure from a formula of size n takes space O(2cn) and time O(22dn).

slide-117
SLIDE 117

Quantifier Elimination

Linear Integer Arithmetic

See [Harrison] or [Enderton] under “Presburger”