Towards a Framework Generalizing Decision Diagrams - Alban Linard

Jun 24, 2010 - Towards a Framework Generalizing Decision Diagrams. Alban Linard123. Emmanuel Paviot-Adet2. Fabrice Kordon2. Didier Buchs1. Samuel ...
434KB taille 1 téléchargements 245 vues
Polymorphic Decision Diagrams Towards a Framework Generalizing Decision Diagrams

Alban Linard123 Emmanuel Paviot-Adet2 Fabrice Kordon2 Didier Buchs1 Samuel Charron3 1 University

of Geneva

2 LIP6 3 LRDE

24 june 2010

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Decision Diagrams?

1/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Decision Diagrams? r p

q

1/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Decision Diagrams? r p

q

 State space ⇔ Function

p

,

p



 ×

q

,

q



 ×

r , r

 →B

1/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Decision Diagrams? r p

q

 State space ⇔ Function

p

,

p



 ×

q

,

q



 ×

r , r (

p q

×

(

r

×

(

7→

0

0

0

0

0

0

1

1



 →B p q

, ,

p

)

q

)

r , r

)

B

1/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Decision Diagrams? (

p q

×

(

r

×

(

7→

0

0

0

0

0

0

1

1



p q

, ,

p

)

q

)

r , r

)

B

1/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Decision Diagrams? (

p q

×

(

r

×

(

7→

0

0

0

0

0

0

1

1



p q

, ,

p

)

q

)

r , r

)

B

DAG with maximal sharing q

r

1

q

r

0

p

1/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Decision Diagrams? (

p q

×

(

r

×

(

7→

0

0

0

0

0

0

1

1



p q

, ,

p

)

q

)

r , r

)

B

DAG with maximal sharing q

r

1

q

r

0

p

1/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Decision Diagrams? (

p q

×

(

r

×

(

7→

0

0

0

0

0

0

1

1



p q

, ,

p

)

q

)

r , r

)

B

DAG with maximal sharing q

r

1

q

r

0

p

1/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Decision Diagrams? (

p q

×

(

r

×

(

7→

0

0

0

0

0

0

1

1



p q

, ,

p

)

q

)

r , r

)

B

DAG with maximal sharing q

r

1

q

r

0

p

1/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Decision Diagrams? (

p q

×

(

r

×

(

7→

0

0

0

0

0

0

1

1



p q

, ,

p

)

q

)

r , r

)

B

DAG with maximal sharing q

r

1

q

r

0

p

1/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Decision Diagrams? (

p q

×

(

r

×

(

7→

0

0

0

0

0

0

1

1



p q

, ,

p

)

q

)

r , r

)

B

DAG with maximal sharing q

r

1

q

r

0

p

1/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Decision Diagrams? (

p q

×

(

r

×

(

7→

0

0

0

0

0

0

1

1



p q

, ,

p

)

q

)

r , r

)

B

DAG with maximal sharing q

r

1

q

r

0

p

1/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Decision Diagrams? (

p q

×

(

r

×

(

7→

0

0

0

0

0

0

1

1



p q

, ,

p

)

q

)

r , r

)

B

DAG with maximal sharing q

r

1

q

r

0

p

1/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Decision Diagrams? (

p q

×

(

r

×

(

7→

0

0

0

0

0

0

1

1



p q

, ,

p

)

q

)

r , r

)

B

DAG with maximal sharing q

r

1

q

r

0

p

1/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Decision Diagrams? (

p q

×

(

r

×

(

7→

0

0

0

0

0

0

1

1



p q

, ,

p

)

q

)

r , r

)

B

DAG with maximal sharing q

r

1

q

r

0

p

1/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Decision Diagrams? (

p q

×

(

r

×

(

7→

0

0

0

0

0

0

1

1



p q

, ,

p

)

q

)

r , r

)

B

DAG with maximal sharing q

r

1

q

r

0

p

1/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Decision Diagrams? (

p q

×

(

r

×

(

7→

0

0

0

0

0

0

1

1



p q

, ,

p

)

q

)

r , r

)

B

DAG with maximal sharing q

r

1

q

r

0

p

1/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Decision Diagrams? (

p q

×

(

r

×

(

7→

0

0

0

0

0

0

1

1



p q

, ,

p

)

q

)

r , r

)

B

DAG with maximal sharing q

r

1

q

r

0

p

1/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Decision Diagrams? (

p q

×

(

r

×

(

7→

0

0

0

0

0

0

1

1



p q

, ,

p

)

q

)

r , r

)

B

DAG with maximal sharing q

r

1

q

r

0

p

1/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

lat ion

tio n

ma nip u

nta rep res e

ing od enc Problem

Function

DD

Solution

2/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

lat ion

tio n

ma nip u

nta rep res e

ing od enc Problem

Function

DD

Solution

2/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

ma nip u tio

ma nip u

ent a rep res

Function

Solution

lat ion

n

DD

ing od enc

lat ion

tio n nta rep res e

ing od enc

Function

Problem

DD

cho

ice

Problem

Solution

DD category

2/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

ma nip u tio

ma nip u

ent a rep res

Function

Solution

lat ion

n

DD

ing od enc

lat ion

tio n nta rep res e

ing od enc

Function

Problem

DD

cho

ice

Problem

Solution

DD category

2/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

3/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Lack of unifying description for DD categories!

In this talk: only DDs with results in terminals (BDD, ZDD, ADD, MDD, DDD, etc.) not Edge-Valued DDs

3/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Function’s characteristics Fixed number of variables Finite variable domains

{x:B; y :B; z:B}→ B

Finite codomain

4/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Function’s characteristics Fixed number of variables {x:B; y :B; z:B}→ B

Finite variable domains Finite codomain Example 0

y

1

z

0, 1

0

0

x

1 1

y 0, 1

z

0

1

4/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Example 0

y

1

z

0, 1

0

0

x

1 1

y 0, 1

z

0

1

Category description x

hx, Bi 7→ y

hy , Bi 7→ z

hz, Bi 7→ τ B

4/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Example 0

1

y

z

0, 1

0

0

x

1 1

y

z

0, 1

0

1

Category description x

hy , Bi 7→ z

hz, Bi 7→ τ B

hx, Bi 7→ y

4/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Example 0

y

1

z

0, 1

0

0

x

1 1

y 0, 1

z

0

1

Category description x

hz, Bi 7→ τ B

(

hx, Bi 7→ y hy , Bi 7→ z

4/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Example 0

y

1

z

0, 1

0

0

x

1 1

y 0, 1

z

0

1

Category description x

  hx, Bi 7→ y hy , Bi 7→ z   hz, Bi 7→ τ 4/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Example 0

1

y

z

0, 1

0

0

x

1 1

y

z

0, 1

0

1

Category description first

(

hi, B, succ(i)i hlast, B, τ i

when i 6= last

i ∈ [x, y , z] Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

4/11

Function’s characteristics Infinite variable domains

{x:B; y :N} → B

5/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Function’s characteristics {x:B; y :N} → B

Infinite variable domains Example 0

y

x 1

{n ∈ N | n is even } {n ∈ N|n is o d d}

y

0

1 N

5/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Function’s characteristics {x:B; y :N} → B

Infinite variable domains Example y

0 x 1

{n ∈ N | n is even } {n ∈ N|n is o d d}

y

0

1 N

Category description hx, Bi 7→ y

hy , Ni 7→ z B

5/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Function’s characteristics | A of {x1 :B}

Discriminant

| B of {x2 :{0, 1, 2}; y :{0, 1, 2}}

→B

6/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Function’s characteristics | A of {x1 :B}

Discriminant

| B of {x2 :{0, 1, 2}; y :{0, 1, 2}}

→B

Example à faire

Category description

d

hd , {A, B}i 7→ x1

hx1 , Bi 7→ x2

hx2 , {0, 1, 2}i 7→ y hy , {0, 1, 2}i 7→ τ B 6/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Function’s characteristics | A of {x1 :B}

Discriminant

| B of {x2 :{0, 1, 2}; y :{0, 1, 2}}

→B

Example à faire

Category description

d

hd , {A, B}i 7→ x1

lehxs,!{0, 1, 2}i 7→ y b a i var

hx1 , Bi 7→ x2

ed

s Unu

2

hy , {0, 1, 2}i 7→ τ B 6/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Function’s characteristics | A of {x1 :B}

Discriminant

| B of {x2 :{0, 1, 2}; y :{0, 1, 2}}

→B

Example à faire

Category description

d

hd , {A, B}i 7→ x

hx, {0, 1, 2}i 7→ y

hy , {0, 1, 2}i 7→ τ B

6/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Function’s characteristics | A of {x1 :B}

Discriminant

| B of {x2 :{0, 1, 2}; y :{0, 1, 2}}

→B

Example à faire

Category description

d

ns! i a hd , {A, B}i 7→ x hx, {0, 1, 2}i 7→m o y hy , {0, 1, 2}i 7→ τ d rge a l To o

B

6/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Function’s characteristics | A of {x1 :B}

Discriminant

| B of {x2 :{0, 1, 2}; y :{0, 1, 2}}

→B

Example à faire

Category description ( d

hd , {A}i 7→ x1 hd , {B}i 7→ x2

hx1 , Bi 7→ τ hx2 , {0, 1, 2}i 7→ y

hy , {0, 1, 2}i 7→ τ B

6/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Function’s characteristics | A of {x1 :B}

Discriminant

| B of {x2 :{0, 1, 2}; y :{0, 1, 2}}

→B

Example à faire

Category description

d

hd

hx1 , Bi 7→ τ

x1 }i 7→ , {A

B

hd , { B }i

7→ x

2

hx2 , {0, 1, 2}i 7→ y

τ }i 7→ 2 , 1 0, hy , { 6/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Function’s characteristics →B

Several codomains

| A of {x1 :B}

Infinite codomains

| B of {x2 :{0, 1, 2}; y :{0, 1, 2}}

→N

7/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Function’s characteristics →B

Several codomains

| A of {x1 :B}

Infinite codomains

| B of {x2 :{0, 1, 2}; y :{0, 1, 2}}

→N

Example à faire

7/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Function’s characteristics →B

Several codomains

| A of {x1 :B}

Infinite codomains

| B of {x2 :{0, 1, 2}; y :{0, 1, 2}}

→N

Example à faire

Category description

d

hd

x1 }i 7→ , {A

hd , {

B }i

hx1 , Bi 7→ τ B

7→ x

2

hx2 , {0, 1, 2}i 7→ y

hy , {0, 1, 2}i 7→ τ

N 7/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Function’s characteristics l → B where Recursive domain

type l = Nil | Cons of {x:B; n:l }

8/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Function’s characteristics l → B where Recursive domain

type l = Nil | Cons of {x:B; n:l }

Example Representation of { [1], [1;1], [1;0], [0;0], [0;1] }

Nil 1 l

Cons Nil

l

Cons

x

1 {0, 1}

x

l 0

l

Cons

x

Nil Cons

x

{0, 1}

...

{0, 1} 0

Nil

8/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Example Representation of { [1], [1;1], [1;0], [0;0], [0;1] }

Nil 1 l

Cons Nil

l

Cons

1

x

{0, 1}

x

l 0

l

Cons

Nil Cons

x

{0, 1}

...

{0, 1}

x

0

Nil

Category description l B

hx, Bi 7→ l

hl , {Nil }i 7→ τ hl , {Cons}i 7→ x 8/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Example Representation of { [1], [1;1], [1;0], [0;0], [0;1] }

Nil 1 l

Cons Nil

l

Cons

1

x

{0, 1}

x

l 0

l

Cons

Nil Cons

x

{0, 1}

...

?

{0, 1}

x

0

Nil

Category description l B

hx, Bi 7→ l

hl , {Nil }i 7→ τ hl , {Cons}i 7→ x 8/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Example Representation of { [1], [1;1], [1;0], [0;0], [0;1] }

Nil 1 l

Cons Nil

l

x 0

l

Cons

1

x

{0, 1}

Redx

Cons

s!

ion t c u

l

Nil Cons

x

{0, 1}

...

?

{0, 1}

0

Nil

Category description l B

hx, Bi 7→ l

hl , {Nil }i 7→ τ hl , {Cons}i 7→ x 8/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

9/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

10/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

11/11

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams

Bibliography

Linard, Paviot-Adet, Kordon, Buchs, Charron

Polymorphic Decision Diagrams