Advanced Strategies for Isolation: Improving Game Performance with Alpha-Beta Pruning Techniques
This project explores innovative strategies for achieving isolation in gaming scenarios, emphasizing the use of a Boolean 2D array to represent the game board. The approach significantly reduces board generation time, making it 3-5 times faster. Key elements include statistical analysis of player distances, evaluation functions to assess game status, and a recursive method for determining optimal isolation paths. The findings suggest that isolation can optimize gameplay by eliminating unnecessary evaluations, allowing for deeper strategic planning and enhancing the likelihood of winning through efficient move selection.
Advanced Strategies for Isolation: Improving Game Performance with Alpha-Beta Pruning Techniques
E N D
Presentation Transcript
COMS W4701 Project 3 Spring 2011 Isolation – Champion Program Albert Jimenez (alj2110)
Board Representation • Graph Representation • Each node is a free block • Gets smaller as the game progresses • Boolean 2D Array • Simpler • 3 – 5 times faster when generating new boards
Alpha Beta • Generating and Ordering New Boards • Statistical analysis • Correlation between distance of players of chosen board and whether the players are directly reachable. • Exploited correlation to achieve more pruning • Evaluation Function • Early in the game it is not clear who is losing/winning • Eval(board) = currentPlayer.numMoves – opponent.numMoves • Ensures more freedom to apply other strategies • Reduces the chances of the opponent trapping you
Main Strategy: Achieving Isolation • Detecting Isolation • Determine if players are separated after generating new boards • If so, this is a terminal node and the second evaluation function can be applied • Can immediately determine if board is likely to be a win/loss without going any deeper • Evaluation Function 2 • Compute number of blocks reachable from both players • Compute difference in reachable blocks = ‘diffReachable’ • Positive value means a likely win • Negative value means a likely loss • Eval2(board) = (diffReachable > 0) ? INFINITY + diffReachable : -INFINITY + diffReachable • Distinguishes between ‘good’ or ’bad’ win/loss
Main Strategy: During Isolation • Alpha Beta becomes Obsolete • It is unnecessary to care about what move the other player might take • By focusing on only one’s own moves, can reach twice the depth • Computing Optimal Isolation Path • Recursive approach to choose the longest path • Heuristics were used to prune bad moves (moves that decrease number of reachable blocks)