Integer Programming Based Algorithms for Peg Solitaire Problem ver. 2.1 - PowerPoint PPT Presentation

1 / 30
About This Presentation
Title:

Integer Programming Based Algorithms for Peg Solitaire Problem ver. 2.1

Description:

Title: peg solitaite problem Author: Tomomi Matsui Last modified by: matsui Created Date: 3/27/1999 10:03:46 AM Document presentation format: – PowerPoint PPT presentation

Number of Views:325
Avg rating:3.0/5.0
Slides: 31
Provided by: tomomi9
Category:

less

Transcript and Presenter's Notes

Title: Integer Programming Based Algorithms for Peg Solitaire Problem ver. 2.1


1
Integer Programming Based Algorithms for Peg
Solitaire Problemver. 2.1
  • Univ. of Tokyo Masashi KIYOMI
  • Univ. of Tokyo Tomomi MATSUI

2
Definitions
  • board a board has holes
  • ? hole on the board
  • example
  • configuration
  • each hole contains at most one peg
  • ?hole with a peg
  • jump operation
  • ??????? ? ? ? ?
  • ??????? ??? ???
  • ? ? ?
    ?

3
Definitions (jump positions)
  • jump position
  • position where a jump operation occurs
  • 38 vertical 38 horizontal
  • jump positions jump positions
  • 76 jump positions in total

4
peg solitaire problem
  • given instance
  • starting configuration finishing
    configuration
  • solution
  • Find a sequence of jump operations, if it exists.
  • If not, say infeasible.

5
previous results
  • complexity
  • Uehara, Iwata (1990)
  • NP-completeness of solitaire problem
  • necessary conditions for feasibility
  • de Bruijn (1972)
  • necessary condition based on finite field
  • Berlekamp, Conway, Guy (1982)(Winning Ways)
  • necessary condition using pagoda function
  • (linear inequality system)
  • Avis, Deza (1996)
  • solitaire cone (polyhedral approach)

6
our results
  • We propose algorithms for peg solitaire problems
    defined on the English board.
  • main idea
  • ordinary backtrack search method
  • search space pruning procedure
  • based on integer programming (IP)

7
upper bound
  • IP finds an upper bound of the number of
  • jump operations at each jump position.
  • start
    finish
  • ?solution, the of jump operations at
  • (the of jump operations) ?1
  • the right-hand-side is a tight upper bound

8
notations
1 2 3 4 5 6 7 ? ?
  • n the number of holes
  • English board n33
  • configuration vector the n-dimensional
  • 0-1 vector corresponding to the configuration

? ? 27 28 29 30 31 32 33
?0,133
1 hole with peg 0 empty hole
9
jump vector
  • jump vectors
  • jump operation subtraction of jump vector
  • (jump vector contains two 1s and one -1)

0 0 0 0 0 0 1 1 -1
0 0 0 0 0 0 0 0 1
0 1 0 0 1 0 1 0 0
0 1 0 0 1 0 0 -1 0
?
?

10
jump matrix
  • jump matrix (holes)(jump position)
  • jump positions
  • 1 -1 ??? -1 0
  • 1 1 ??? 0 0
  • A -1 1 ??? 1 1
  • 0 0 ??? 1 -1
  • 0 0 ??? 0 1
  • configuration p ? configuration p
  • jump operation at jump position j
  • ? pp - A uj (uj jth unit vector)

holes
11
jump matrix and peg solitaire problem
  • A jump matrix (defined by the given board)
  • ps configuration vector of starting config.
  • pf configuration vector of finishing config.
  • If the given peg solitaire problem has a
    solution,
  • then ?x(x1,x2,...,xm)T
  • (1) integer vector indexed by jump positions
  • (2) ps - Ax pf
  • xj of jump operations at position j

12
integer programming
  • IPj max. xj
  • sub. to ps - Ax pf , x?0,
  • x(x1,x2,...,xm)T is
    an integer vector.
  • (1) IPjs are infeasible
  • ? peg solitaire problem is infeasible
  • (2) ( of jump operations at j)?(opt. val. of
    IPj)
  • The optimal value of IPj is an upper bound of
    the of jump operations at position j.
  • Our algorithm solves IPj for each position j.
  • 76 jump positions, 76 variables, 33 constraints

13
example of upper bounds
  • given problem
  • solve 76 IP problems
  • obtained UB

14
example of infeasible peg solitaire problem
  • given problem
  • solve 76 IP problems
  • IPj are infeasible
  • ? peg solitaire problem is infeasible
  • Our computational experiences show that the above
    feasibility check is very powerful.

15
pagoda function approach
  • Berlekamp, Conway, Guy (1982)(Winning Ways)
  • a pagoda function exists ??y, yTA?0, yT(ps - pf
    )lt0
  • ? peg solitaire problem is infeasible
  • Farkas Lemma
  • exactly one of (1) and (2) is satisfied
  • (1) ?y, yTA?0, yT(ps - pf )lt0,
  • (2) ?x, ps - Ax pf , x?0.
  • IPj maxxj ps - Ax pf , x?0, x?Zn
  • Feasibility checking method by IPj is stronger
    than pagoda function approach.

16
example of infeasible peg solitaire problems (2)
  • given problem
  • infeasible!
  • 76 IP problems have optimal solutions
  • obtained UB
  • IP is infeasible ? peg solitaire is infeasible
  • IP is infeasible peg solitaire is infeasible

17
algorithm
  • We propose algorithms for peg solitaire problems
    defined on the English board.
  • main idea
  • ordinary backtrack search method
  • search space pruning procedure
  • based on integer programming (IP)

18
game tree
  • given problem
  • game tree
  • all possible jumps
  • from starting config.
  • node configuration
  • root starting config.
  • childparentjump

finishing config.
19
search of game tree
  • depth first search
  • on game tree

20
DFSUB
starting configuration
  • depth first search
  • UB

2
1
1
0
2
1
0
0
1
1
1
1
1
0
1
1
0
0
finishing configuration
21
DFSUB
starting configuration
  • depth first search
  • UB

2
1
1
0
2
1
0
0
1
1
1
1
1
0
1
1
0
0
finishing configuration
22
hash table
  • We used hash table to avoid searching the same
    configurations more than once.
  • hash size 2,000,000
  • The hash technique saves much computational
    efforts during the depth-first-search.

23
search method
  • forward-only search ordinary DFS
  • forward-backward search

finishing configuration
24
computational experience
  • MMX Pentium 233MHz with 64MB memory
  • problem (i)
  • 76 IPs 9.1 sec.
  • forward-only 37 min.
  • forward-backward1.4 sec.
  • problem (ii)
  • 76 IPs 122 sec.
  • forward-only 3.0 sec.
  • forward-backward hash overflow

25
END
26
(No Transcript)
27
(No Transcript)
28
(No Transcript)
29
(No Transcript)
30
(No Transcript)
Write a Comment
User Comments (0)
About PowerShow.com