Adversarial Search
Adversarial Search
Lecture #
Adversarial Search
In this game Max’s best move is A1, because he is guaranteed a score of at least 3.
Properties of minimax
Complete? Yes (if tree is finite)
Optimal? Yes (against an optimal opponent)
Time complexity? O(bm)
Space complexity? O(bm) (depth-first exploration)
𝛽 𝑣𝑎𝑙𝑢𝑒
≤3
α-β pruning example
𝛼 𝑐𝑢𝑡𝑜𝑓𝑓
α-β pruning example
α-β pruning example
α-β pruning example
Alpha-Beta pruning
𝛼 − 𝑐𝑢𝑡𝑜𝑓𝑓 ∶ search can be discontinued below any MIN
node having a beta value less than or equal to the alpha value
of any of its MAX node ancestors.
𝛽 − 𝑐𝑢𝑡𝑜𝑓𝑓: search can be discontinued below any MAX
node having an alpha value greater than or equal to the beta
value of its MIN node ancestors.
Alpha-Beta pruning
Alpha-Beta is guaranteed to compute the same Minimax
value for the root node as computed by Minimax
In the worst case, Alpha-Beta does NO pruning.
In the best case, Alpha-Beta will examine only 2bm/2 leaf
nodes.
The best case occurs when each player's best move is the
leftmost alternative (i.e., the first child generated). So, at
MAX nodes the child with the largest value is generated
first, and at MIN nodes the child with the smallest value
is generated first.