Octagonal Domains for Continuous Constraints Marie Pelleau - - PowerPoint PPT Presentation

octagonal domains for continuous constraints
SMART_READER_LITE
LIVE PREVIEW

Octagonal Domains for Continuous Constraints Marie Pelleau - - PowerPoint PPT Presentation

Octagonal Domains for Continuous Constraints Marie Pelleau Charlotte Truchet Frdric Benhamou TASC, University of Nantes CP 2011 September 13, 2011 M. Pelleau, C. Truchet, F. Benhamou (TASC, University of Nantes) TASC, Nantes September


slide-1
SLIDE 1

Octagonal Domains for Continuous Constraints

Marie Pelleau Charlotte Truchet Frédéric Benhamou

TASC, University of Nantes

CP 2011

September 13, 2011

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 1 / 22

slide-2
SLIDE 2

Table of contents

Outline

1

Context

2

Octagons Computer Representation Octagonal Consistency Octagonal Solving

3

Results

4

Conclusion

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 2 / 22

slide-3
SLIDE 3

Context

Context

Continuous Constraint Satisfaction Problem: CSP < V, D, C > V = (v1 . . . vn) real variables D = (D1 . . . Dn) interval domains C = (C1 . . . Cp) continuous constraints Solving process in CP relies on Cartesian product of intervals

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 3 / 22

slide-4
SLIDE 4

Context

Context

Continuous Constraint Satisfaction Problem: CSP < V, D, C > V = (v1 . . . vn) real variables D = (D1 . . . Dn) interval domains C = (C1 . . . Cp) continuous constraints Solving process in CP relies on Cartesian product of intervals

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 3 / 22

slide-5
SLIDE 5

Context

Context

Continuous Constraint Satisfaction Problem: CSP < V, D, C > V = (v1 . . . vn) real variables D = (D1 . . . Dn) interval domains C = (C1 . . . Cp) continuous constraints Solving process in CP relies on Cartesian product of intervals

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 3 / 22

slide-6
SLIDE 6

Context

Context

Continuous Constraint Satisfaction Problem: CSP < V, D, C > V = (v1 . . . vn) real variables D = (D1 . . . Dn) interval domains C = (C1 . . . Cp) continuous constraints Solving process in CP relies on Cartesian product of intervals

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 3 / 22

slide-7
SLIDE 7

Context

Context

Continuous Constraint Satisfaction Problem: CSP < V, D, C > V = (v1 . . . vn) real variables D = (D1 . . . Dn) interval domains C = (C1 . . . Cp) continuous constraints Solving process in CP relies on Cartesian product of intervals

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 3 / 22

slide-8
SLIDE 8

Context

Context

Our goal

Continuous Constraint Solving We don’t live in a Cartesian world! Can we use other domain representations? There exist several domain representations in other fields (e.g. ellipsoids, zonotopes in Abstract Interpretation) Our Contribution Show that the basic tools of CP can be defined for non-Cartesian domain representations

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 4 / 22

slide-9
SLIDE 9

Octagons Computer Representation

Octagons

The Octagon Abstract Domain

Definition (Octagon [Miné, 2006]) Set of points satisfying a conjunction of constraints of the form ±vi ± vj ≤ c, called octagonal constraints v1 v2

v1 ≥ 1 v1 ≤ 5 v2 ≥ 1 v2 ≤ 5 v2 − v1 ≤ 2 v1 − v2 ≤ 2.5 v1 + v2 ≥ 3

In dimension n, an octagon has at most 2n2 faces An octagon can be unbounded

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 5 / 22

slide-10
SLIDE 10

Octagons Computer Representation

Octagons

The Octagon Abstract Domain

A Difference Bound Matrix (DBM) to represent an octagon vj vi    . . . · · · c    vj − vi ≤ c

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 6 / 22

slide-11
SLIDE 11

Octagons Computer Representation

Octagons

The Octagon Abstract Domain

A Difference Bound Matrix (DBM) to represent an octagon vj vi    . . . · · · c    vj − vi ≤ c v1 + v2 ≤ c → v1 − (−v2) ≤ c and v2 − (−v1) ≤ c

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 6 / 22

slide-12
SLIDE 12

Octagons Computer Representation

Octagons

The Octagon Abstract Domain

A Difference Bound Matrix (DBM) to represent an octagon vj vi    . . . · · · c    vj − vi ≤ c v1 + v2 ≤ c → v1 − (−v2) ≤ c and v2 − (−v1) ≤ c Need of two rows and columns for each variable (vi, −vi)

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 6 / 22

slide-13
SLIDE 13

Octagons Computer Representation

Octagons

The Octagon Abstract Domain

v1 v2

v1 ≥ 1 v1 ≤ 5 v2 ≥ 1 v2 ≤ 5 v2 − v1 ≤ 2 v1 − v2 ≤ 2.5 v1 + v2 ≥ 3

    −2 2 −3 10 +∞ 2.5 2.5 −3 −2 +∞ 2 10    

v1 −v1 v2 −v2 v1 −v1 v2 −v2

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 7 / 22

slide-14
SLIDE 14

Octagons Computer Representation

Octagons

Canonical Representation

Different DBMs can correspond to the same octagon ⇒ need for a canonical form It has been proved that a modified version of Floyd-Warshall shortest path algorithm computes in O(n3) the smallest DBM representing an octagon of dimension n [Miné, 2006] This canonical form corresponds to the consistency of the difference constraints [Dechter et al., 1991]

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 8 / 22

slide-15
SLIDE 15

Octagons Computer Representation

Octagons

Representation for CP

v1 v2

v1 ≥ 1 v1 ≤ 5 v2 ≥ 1 v2 ≤ 5 v2 − v1 ≤ 2 v1 − v2 ≤ 2.5 v1 + v2 ≥ 3

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 9 / 22

slide-16
SLIDE 16

Octagons Computer Representation

Octagons

Representation for CP

v1 v2

v1 ≥ 1 v1 ≤ 5 v2 ≥ 1 v2 ≤ 5 v2 − v1 ≤ 2 v1 − v2 ≤ 2.5 v1 + v2 ≥ 3

v1 = v′

1 cos

π

4

  • + v′

2 sin

π

4

  • v2 = v′

2 cos

π

4

  • − v′

1 sin

π

4

  • v1

v2

π 4

v′

1

v′

2

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 9 / 22

slide-17
SLIDE 17

Octagons Computer Representation

Octagons

Representation for CP

Rotation v1 = v′

1 cos

π

4

  • + v′

2 sin

π

4

  • v2 = v′

2 cos

π

4

  • − v′

1 sin

π

4

  • Constraint Translation

2v1 − v2 ≤ 4

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 10 / 22

slide-18
SLIDE 18

Octagons Computer Representation

Octagons

Representation for CP

Rotation v1 = v′

1 cos

π

4

  • + v′

2 sin

π

4

  • v2 = v′

2 cos

π

4

  • − v′

1 sin

π

4

  • Constraint Translation

2v1 − v2 ≤ 4 ⇔ 2(v′

1 cos

π

4

  • + v′

2 sin

π

4

  • ) − v′

2 cos

π

4

  • + v′

1 sin

π

4

  • ≤ 4
  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 10 / 22

slide-19
SLIDE 19

Octagons Computer Representation

Octagons

Representation for CP

Rotation v1 = v′

1 cos

π

4

  • + v′

2 sin

π

4

  • v2 = v′

2 cos

π

4

  • − v′

1 sin

π

4

  • Constraint Translation

2v1 − v2 ≤ 4 ⇔ 2(v′

1 cos

π

4

  • + v′

2 sin

π

4

  • ) − v′

2 cos

π

4

  • + v′

1 sin

π

4

  • ≤ 4

⇔ 3

√ 2 2 v′ 1 + √ 2 2 v′ 2 ≤ 4

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 10 / 22

slide-20
SLIDE 20

Octagons Computer Representation

Octagons

Representation for CP

Representation in O(n2) for a CSP with n variables and p constraints

n2 variables p(n(n − 1) + 2)/2 constraints

Back to the boxes Direct definition of the needed tools for the resolution

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 11 / 22

slide-21
SLIDE 21

Octagons Octagonal Consistency

Octagonal Consistency

Octagonal HC4

v1 v2

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 12 / 22

slide-22
SLIDE 22

Octagons Octagonal Consistency

Octagonal Consistency

Octagonal HC4

v1 v2 HC4

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 12 / 22

slide-23
SLIDE 23

Octagons Octagonal Consistency

Octagonal Consistency

Octagonal HC4

v1 v2 v′

1

v′

2

H C 4

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 12 / 22

slide-24
SLIDE 24

Octagons Octagonal Consistency

Octagonal Consistency

Octagonal HC4

v1 v2 v′

1

v′

2

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 12 / 22

slide-25
SLIDE 25

Octagons Octagonal Consistency

Octagonal Consistency

Octagonal HC4

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 13 / 22

slide-26
SLIDE 26

Octagons Octagonal Consistency

Octagonal Consistency

Octagonal HC4

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 13 / 22

slide-27
SLIDE 27

Octagons Octagonal Consistency

Octagonal Consistency

Octagonal HC4

Use the DBM and apply the consistency

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 13 / 22

slide-28
SLIDE 28

Octagons Octagonal Consistency

Octagonal Consistency

Octagonal HC4

Use the DBM and apply the consistency The canonical DBM corresponds to the smallest octagon

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 13 / 22

slide-29
SLIDE 29

Octagons Octagonal Solving

Octagonal Exploration

Splitting Process

A splitting operator, splits a variable domain v1 v2 v1 v2 v1 v2

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 14 / 22

slide-30
SLIDE 30

Octagons Octagonal Solving

Octagonal Exploration

Splitting Process

A splitting operator, splits a variable domain v1 v2 v′

1

v′

2

v1 v2 v′

1

v′

2

v1 v2 v′

1

v′

2

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 14 / 22

slide-31
SLIDE 31

Octagons Octagonal Solving

Octagonal Exploration

Choice Heuristic

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 15 / 22

slide-32
SLIDE 32

Octagons Octagonal Solving

Octagonal Exploration

Choice Heuristic

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 15 / 22

slide-33
SLIDE 33

Octagons Octagonal Solving

Octagonal Exploration

Choice Heuristic

Take the "best" basis, the box with the minimum of the maximum width Split the largest domain in this basis, the domain with the maximum width

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 15 / 22

slide-34
SLIDE 34

Octagons Octagonal Solving

Octagonal Solving

What we got

We defined:

an octagonal consistency Correctness Assume that, for all constraint C there exists a propagator ρC, such that ρC reaches Hull consistency, that is, ρC(D1 × ... × Dn) is the Hull consistent box for C. Then the propagation scheme as defined computes the Oct-consistent

  • ctagon for the constraints
  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 16 / 22

slide-35
SLIDE 35

Octagons Octagonal Solving

Octagonal Solving

What we got

We defined:

an octagonal consistency a splitting operator Completeness The union of the two octagonal subdomains is the original octagon, thus the split does not lose solutions

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 16 / 22

slide-36
SLIDE 36

Octagons Octagonal Solving

Octagonal Solving

What we got

We defined:

an octagonal consistency a splitting operator a choice heuristic a precision (see paper)

We obtain an Octagonal Solver which is correct and complete

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 16 / 22

slide-37
SLIDE 37

Results Octagonal Exploration

Experiments

Protocol

Prototype in Ibex [Chabert and Jaulin, 2009] Different type of problems from the COCONUT benchmark Same configuration Timeout of 3 hours

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 17 / 22

slide-38
SLIDE 38

Results Octagonal Exploration

Results

Octagonal Exploration First solution All the solutions name nbvar ctrs In Oct In Oct h75 5 ≤ 41.40 0.03

  • hs64

3 ≤ 0.01 0.05

  • h84

5 ≤ 5.47 2.54

  • 7238.74

KinematicPair 2 ≤ 0.00 0.00 53.09 16.56 pramanik 3 = 28.84 0.16 193.14 543.46 trigo1 10 = 18.93 1.38 20.27 28.84 brent-10 10 = 6.96 0.54 17.72 105.02 h74 5 = ≤ 305.98 13.70 1 304.23 566.31 fredtest 6 = ≤ 3 146.44 19.33

  • CPU time in seconds
  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 18 / 22

slide-39
SLIDE 39

Results Octagonal Exploration

Results

Octagonal Exploration

First solution All the solutions name nbvar ctrs In Oct In Oct h75 5 ≤ 1 024 085 149

  • hs64

3 ≤ 217 67

  • h84

5 ≤ 87 061 1 407

  • 22 066 421

KinematicPair 2 ≤ 45 23 893 083 79 125 pramanik 3 = 321 497 457 2 112 801 1 551 157 trigo1 10 = 10 667 397 11 137 5 643 brent-10 10 = 115 949 157 238 777 100 049 h74 5 = ≤ 8 069 309 138 683 20 061 357 1 926 455 fredtest 6 = ≤ 29 206 815 3 281

  • Number of created nodes during the search
  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 19 / 22

slide-40
SLIDE 40

Conclusion and Perspectives

Conclusion and Perspectives

Conclusion No need to be Cartesian Paradox: New representation in O(n2) but efficient

Efficient Octagonal-consistency thanks to the modified version of Floyd-Warshall algorithm Good choice heuristic

Use existent consistencies to define the Octagonal-consistency Future work Improvement of the implementation

Constraints rewriting Improvement of the octagonal constraints

Other numerical abstract domains

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 20 / 22

slide-41
SLIDE 41

CPAIOR 2012

C for CPAIOR 2012

Remember, Remember the 5th of December 2011 (Deadline)

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 21 / 22

slide-42
SLIDE 42

Questions

Questions?

  • M. Pelleau, C. Truchet, F. Benhamou

(TASC, University of Nantes) TASC, Nantes September 13, 2011 22 / 22