42
OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION Solving Strategies using a Hybridization Model for Local Search and Constraint Propagation ACM SAC 2005, Santa Fe, New Mexico, USA Tony Lambert and Éric Monfroy and Frédéric Saubion LERIA, Université de Angers, France and LINA, Université de Nantes, France March 16, 2005 1/42

Lambert Sac2005

Embed Size (px)

DESCRIPTION

Solving Strategies using a Hybridization Model for LocalSearch and Constraint Propagation

Citation preview

Page 1: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Solving Strategies using a Hybridization Modelfor Local Search and Constraint Propagation

ACM SAC 2005, Santa Fe, New Mexico, USA

Tony Lambert and Éric Monfroy and Frédéric Saubion

LERIA, Université de Angers, Franceand

LINA, Université de Nantes, France

March 16, 2005

1 / 42

Page 2: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Outline

• Hybridization• Constraint propagation• Local search• Hybrid model• Some results• Conclusion

2 / 42

Page 3: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Hybridization for CSP

• complete methods (such as propagation + split)• complete exploration of the search space• detects if no solution• generally slow for hard combinatorial problems• global optimum

• incomplete methods (such as local search)

• focus on some “promising” parts of the search space• does not answer to unsat. problems• no guaranteed global optimum• “fast” to find a “good” solution

3 / 42

Page 4: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Hybridization for CSP

• complete methods (such as propagation + split)• complete exploration of the search space• detects if no solution• generally slow for hard combinatorial problems• global optimum

• incomplete methods (such as local search)• focus on some “promising” parts of the search space• does not answer to unsat. problems• no guaranteed global optimum• “fast” to find a “good” solution

4 / 42

Page 5: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Hybridization : getting the best of both methods

• But, generally :• Ad-hoc systems• Master-slaves approaches• Coarse grain cooperation

• Idea :

• Fine grain control• More strategies

• Technique :

• Decomposing solvers into basic functions• Adapting chaotic iterations for hybrid solving

5 / 42

Page 6: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Hybridization : getting the best of both methods

• But, generally :• Ad-hoc systems• Master-slaves approaches• Coarse grain cooperation

• Idea :• Fine grain control• More strategies

• Technique :

• Decomposing solvers into basic functions• Adapting chaotic iterations for hybrid solving

6 / 42

Page 7: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Hybridization : getting the best of both methods

• But, generally :• Ad-hoc systems• Master-slaves approaches• Coarse grain cooperation

• Idea :• Fine grain control• More strategies

• Technique :• Decomposing solvers into basic functions• Adapting chaotic iterations for hybrid solving

7 / 42

Page 8: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

CSP (Constraint Satisfaction Problem)

X

Y

Constraints

VariablesU

TZ

C1

C2

C5C4

C3

8 / 42

Page 9: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Problems are modeled as CSP (X , D, C)

Variable (X )Set of variable domains (D)

Dx = a; b; c; . . .

Dy = a; b; c; . . .

Dz = a; b; c; . . .

. . .

Set of constraints (C)

C1 : X ≤ Y ∗ 3

C2 : Z 6= X − Y

. . .

9 / 42

Page 10: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Solving CSP with a complete method

ConstraintPropagation

EnumerationSplitting

10 / 42

Page 11: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Constraint Propagation

Arc consistency : C(X , Y )

DX

DY

a

b

c

a

b

c

Values

pairs of valuesConsistent

11 / 42

Page 12: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Constraint Propagation

Arc consistency : C(X , Y )

DX

DY

a

b

c

a

b

c

Values

pairs of valuesConsistent

Removed by arcconsistency

12 / 42

Page 13: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Constraint Propagation

Propagation

Propagation

inconsistency

Local consistency

13 / 42

Page 14: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Constraint propagation and domain splitting

Propagation

Splitting

14 / 42

Page 15: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Constraint propagation and domain splitting

Propagation

Propagation Splitting

15 / 42

Page 16: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Abstract Model K.R. Apt [CP99]

CSP

Applicationof functions

Constraint Reduction functions

Fixed point

Partial Ordering

Abstraction

16 / 42

Page 17: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

A Generic Algorithm

F = set of split and propagation functions

X =

X = initial CSPG = FWhile G 6= ∅

choose g ∈ GG = G − gG = G ∪ update(G, g, X )X = g(X )

EndWhile

17 / 42

Page 18: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Our Purpose : Hybrid Model

• Integration of local search• Use of an existing theoretical model for CSP solving• Definition of the solving process

18 / 42

Page 19: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Local search

• Search space : set of possible configurations• Tools : neighborhood and evaluation function

Set ofpossibleconfigurations

19 / 42

Page 20: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Local search

• Search space : set of possible configurations• Tools : neighborhood and evaluation function

s 1 s 2

s 3 s 4

s 5

s 6

Neighborhoodof s Set of

possibleconfigurations

20 / 42

Page 21: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Local search

• Search space : set of possible configurations• Tools : neighborhood and evaluation function

s 1 s 2

s 3 s 4

s 5

s 6

Neighborhoodof s Set of

possibleconfigurations

21 / 42

Page 22: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Local search

• Search space : set of possible configurations• Tools : neighborhood and evaluation function

s 1

s 1

2s s n

2s s n s n+1

Neighborhoodof s Set of

possibleconfigurations

p = (

p’ = (

LS(p) = p’

,

, , ...,

, ..., )

, )

ss

ss

ss

21

34

5

6

22 / 42

Page 23: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Integrating CSP Resolution Techniques in a Hybrid Model

• Extend the existing Apt ′ s theoretical model for CSPsolving

• Fixpoint computation on a partial ordering

23 / 42

Page 24: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

The theoretical model for CSP solving

Partial ordering :

Ω1

Ω2

Ω3

Ω4

Ω5

Set of CSP

domain reduction function orApplication of a reduction :

splitting function

Terminates with a fixed point : set of solutions or inconsistent CSP

24 / 42

Page 25: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

The theoretical model for CSP solving

Reduction : by constraint propagation

Ω Ω’

CSP1 CSP3Ω

CSP2’ CSP3CSP1Ω

Constraint Propagation

CSP2

25 / 42

Page 26: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

The theoretical model for CSP solving

Reduction : by domain splitting

Ω Ω’

CSP1 CSP2’ CSP2’’’CSP2’’ CSP3Ω

CSP1 CSP3ΩSplit

CSP2

26 / 42

Page 27: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

LS process as moves on partial ordering

Moves on a partial ordering

1p

2p

3p

4p

p

Function to pass from one LSstate to another

5

Terminates with a fixed point : local minimum, maximum number of iteration

State of LS

27 / 42

Page 28: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

LS Ordering

Characteristics of a LS path

• Notion of Solution• Maximum Length

Operational (computational) point of view : path = samples

28 / 42

Page 29: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Integration of samples for local search into the CSP

• A sample :• Depends on a CSP• Corresponds to a LS state

• An SCSP contains :• A set of domains ;• A set of constraints ;• A (list of) sample for local search.

29 / 42

Page 30: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Hybridization model

Ordering over SCSP

− domain reduction,

− or LS step.− splitting,

A solution before the end of the process, given by LS

Ω3

Ω2

Ω1

Ω4

Ω5

Set of SCSP

Application of a reduction :function :

Terminates with a fixed point : set of solutions or inconsistent SCSP

30 / 42

Page 31: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Hybridization model

Ordering over SCSP

Ψ v Ψ′ with : Ψ = 〈C; D; p〉Ψ′ = 〈C; D′; p′〉

if : D ⊆ D′

or if : D′ = D and p v p′

31 / 42

Page 32: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Algorithm

Same Generic AlgorithmX = initial SCSPG = FWhile G 6= ∅

choose g ∈ GG = G − gG = G ∪ update(G, g, X )X = g(X )

EndWhile

32 / 42

Page 33: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

General Process

Sets of

Global

ConstraintSCSP

Fixed point

Applicationof functions

LS solution

33 / 42

Page 34: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Algorithm

• In the chaotic iteration framework• Finite domains (sets of SCSP)• Monotonic functions (LS move, domain reduction, splitting)• Decreasing functions• → termination and computation of fixed point (solution of

CP)• Practically : can stop before with a LS solution

34 / 42

Page 35: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Examples

• SEND + MORE = MONEY• Zebra• Golomb• Magic square• Langford Number

35 / 42

Page 36: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Modeling Strategies through Reduction Functions

• Reduction / Split / LS functions• Choose a / several SCPS to apply functions• Choose a / several domains (Prop. - Split)• Tests : Random - Depth first - FC

36 / 42

Page 37: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Strategy : ratio LS-CP

• Ratio of LS functions applied and CP functions applied :Triple(red%,split%,ls%)

• 10% of split compared to reduction• CP alone : (90,10,0)• LS alone : (0,0,100)

• LS strategy : tabu• Choose : LS, reduction, or split but keep the given ratios

37 / 42

Page 38: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Langford number 4 2

0

100

200

300

400

500

600

700

800

10 20 30 40 50 60 70 80 90 100

Num

ber

of o

pera

tions

Propagation percentage

Average

standard deviation

38 / 42

Page 39: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

SEND + MORE = MONEY

200

400

600

800

1000

1200

1400

1600

1800

2000

10 20 30 40 50 60 70 80 90 100

Num

ber

of o

pera

tions

Propagation percentage

Average

standard deviation

39 / 42

Page 40: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Problem S+M LN42 Zebra M. square GolombRate FC 70-80 15 - 25 60-70 30-45 30 - 40

TAB.: Best range of propagation rate (α) to compute a solution

Strategy Method S+M LN42 M. square GolombRandom LS 1638 383 3328 3442

CP+LS 1408 113 892 909CP 3006 1680 1031 2170

D-First LS 1535 401 3145 3265CP+LS 396 95 814 815

CP 1515 746 936 1920FC LS 1635 393 3240 3585

CP+LS 22 192 570 622CP 530 425 736 1126

TAB.: Avg. nb. of operations to compute a first solution40 / 42

Page 41: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Conclusion

• A generic model for hybridizing complete (CP) andincomplete (LS) methods

• Implementation of modules working on the same structure• Complementarity of methods• Design of strategies

41 / 42

Page 42: Lambert Sac2005

OUTLINE HYBRIDIZATION CONSTRAINT PROPAGATION LOCAL SEARCH HYBRID MODEL SOME RESULTS CONCLUSION

Future work

• Adaptation of the model for optimization• Study of other methods (G.A.)• Design of strategies using composition operators• A generic implementation

42 / 42