
Heuristic Details1. RandomIn this heuristic, the computer makes a move randomly without taking into consideration the current board configuration. It can be pretty hard to beat this heuristic also, as the random player may not leave its triangle at all and thus denying the chance to the opponent to occupy its winning triangle ! 2. Vertical DisplacementThis heuristic does the most obvious in the strategy for winning i.e. trying to maximize the vertical jumps of any piece. It generates all moves with minimax algorithm and then sums up the vertical distance for its pieces and adds them up. It also adds up the vertical distance of each of the opponent’s pieces. Then it uses the following SEF ( static evaluation function ) to make the best move : Total_{Self} – Total_{Opponent} _{ }Caveats The player does not know anything about the horizontal displacement. Thus it can get stuck in corners and may not be able to move into its triangle easily and may even oscillate. This problem is corrected in the next heuristic 3. Vertical and Horizontal DisplacementIn this heuristic we also consider the horizontal positions of the pieces in deciding the next move. The main idea is that it is best to play in the middle of the board and the opportunity is maximum to make the best move (more chances to jump and so on). This keeps the player’s pieces in the middle and also makes it very easy to move to its destination triangle . The formula is : Wt. Factor * Vertical Displacement + Horizontal Displacemt The Wt. Factor decides how much importance is to be given to keep the pieces in the middle of the board compared to jumping vertically. 4. Vertical/Horizontal Displacement with SplitThis is a new idea, which makes it very easy for the heuristic to win towards the end of the play. The idea is that when the pieces start reaching its destination triangle, then we also need to provide good opportunity for other pieces to come in the destination triangle and the pieces already in the destination triangle should facilitate their entry into the destination triangle.
But the previous strategy of keeping the pieces in the middle may hinder other pieces from entering the triangle. So in this heuristic, we move the pieces to the edges of the destination triangle once they have moved in, to create space for other pieces to come in. We do this by assigning more weights to the edges then the middle of the destination triangle. This is shown below.
5. The Above Strategy + Back Piece moving strategyOne problem with which the previous heuristics suffer from is that some pieces are left at the backend of the board and they have to move one by one at the end thus requiring more number of moves to win. In this heuristic, we give more weightage to the moves where the back pieces move forward than the front pieces. This produces the desired effect, i.e. no lone pieces are left behind on the board and pieces move in clusters. This further reduces the number of moves required to win. This heuristic is very strong and it is very difficult to beat it. 