150 likes | 158 Views
This project explores the use of pattern databases in heuristic search, comparing the strategies of Max'ing and Adding for optimizing search. It focuses on a 15 sliding-tile puzzle, discussing partitioning strategies, memory management, and mapping techniques. Experimental results and further plans for optimization are presented.
E N D
Max’ing vs Adding Comput 652 Project Presented by Yi Li
Outline • Introduction • Project setting • Experiment Result • Further plan
Introduction • It is a common technology to use pattern database. • Examples showed that using multiple pattern databases can further benefit the heuristic search. • Two ways to use multiple pattern databases • Max’ing • Adding
Introduction • Max’ing it is admissible if every h is admissible • Adding it is admissible only when the pattern databases is disjoint.
Introducation • Disjoint Pattern Database For sliding-tile puzzle, partition the tiles into disjoint groups. No tile belongs to more than one group. • Key different between max’ing and adding. • Max’ing count all moves required to reach the pattern goal target, including moves of other tiles not in the group. • Adding only count moves of the tiles of the group. It means the move involving blank tile and “don’t care” tile will cost 0.
Introduction • max’ing > adding? Or other way around?
Project setting • Problem domain: 15 sliding-tile puzzle. • Partition size: • 8-7-1. the size 16!/8! = 518,918,400. it is too larger to store in memory. • 5-5-5-1. the size 16!/10! = 5,765,760.
Project setting • How to partition? G1: 1,2,3,6,7 G2: 4,5,8,9,12 G3: 10,11,13,14,15 • General rule, group together tiles that are near each other because they are most likely to interact with one another.
Project setting • Memory. • When comparing max’ing and adding, we will need to store 6 pattern database. Each one has 5,765,760 patterns. • We only need store the h value. For each value, a byte is enough because no h value is large than 256.
Project setting • Mapping: • Sparse table: k-dimensional array. Size Example: a pattern of three tiles(x,y,z) and they are located at position(2,1,3). The array[2][1][3]. • Compact mapping: size 16!/10!. Mapping to an index corresponding to its position in a lexicographic ordering of all permutations. Example: (2,1,3) -> 3 because it is preceded by (1,2,3) and (1,3,2).
Experiment Result • Using BFS backward search. • Stop at certain number of generated nodes.
Experiment Result • An example of max’ing < adding
Experiment Result • An example of Adding < Max’ing
Further Plan • For Adding, we can further don’t consider the blank position. It can further decrease the size of the databases. • The position of the blank is less important in a disjoint pattern database • Using IDA* to test the performance by using Max’ing and Adding.