Rook Polynomial Relaxation Labeling Ofir Cohen Shay Horonchik

Preview:

Citation preview

Rook PolynomialRelaxation Labeling

Ofir Cohen Shay Horonchik

Problem Domain

Rooks can only move horizontally or vertically.

Place n Rooks on a n*n chess board with holes, where no piece can challenge other rooks.

This is an NP Complete problem

Problem Domain (cont.)

Rook Polynomial can be reduced to: Resource distribution under constraints

Known Solutions Algorithms using back tracking Include / exclude mechanism

Rook Polynomial via Relaxation Labeling

Set of Objects: We declared each cell (except holes) as an object.

Set of Labels: We declared two labels: {Empty, Rook}

Initial Confidence: Rook => 1 / Maximum between empty cells in row

and clumn Empty => 1 - Empty

bb nB ,...,

1

m,...,2,1

im

i

i

p

p

1

0

1

0

0

Rook Polynomial via Relaxation Labeling

Compatibility -

Example:

Rook Polynomial via Relaxation Labeling

Results: Very long running time it doesn’t converge to the correct solution The algorithm doesn’t try to achieve maximum rook

number on board Successful runs. (only on small boards)

Rook Polynomial via Relaxation Labeling (phase b)

We perform the following changes: Initial confidence

Randomize rooks on several cells on the board Support function

Zeroing cells where found rooks in both row and column Increasing cells value where found an empty

row/column

Implementation

Input: Number Of Columns Number Of Rows Number Of Cells With Holes

Problems And Conclusion

Relaxation algorithm purpose don’t match the problem specification . Relaxation labeling purpose is to match objects and

labels The rook polynomial problem purpose is to find

maximal “Rook labels”

Any Questions ?

Thank You