Type of tree for Alpha-Beta Pruning

263 views Asked by At

I am making an AI application where I found about minimax and Alpha-beta pruning. I found that in the program I already used the concept of minimax.

I found that Alpha-beta pruning reduces branches to search for.

So my question is what type of tree should I need to apply the algorithm.

In research, I always found binary tree. (Where each node has exactly two children)

But in my application, each node can generate 1 to 30 child nodes.

So should I use alpha-beta pruning on it? Or it isn't possible. Is there any other algorithm to reduce branches as Alpha-beta pruning does?

1

There are 1 answers

0
Billy Brown On BEST ANSWER

You can certainly use Alpha-beta pruning on a tree where nodes have more than two children. In fact, you can see it in the first image for the English Wikipedia article about Alpha-beta pruning. Alpha-beta pruning is introduced as an optimisation of minimax, which is often used in board game AIs, where more than two choices are available to the player (think of chess, draughts, backgammon, etc.). You should be able to just add Alpha-beta pruning to your current minimax implementation.