Week 4 (Chapter 5) - Adversarial Search Flashcards

1
Q

In game playing, when “perfection” is unobtainable, what must we do?

A

Must approximate and make trade-offs

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Explain what it means by “deterministic” in game playing.

A

No chance involved.

e.g. Chess, checkers, go, othello

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

How to represent a game as a search problem?

A

Minimax where there are states (nodes) which have a utility function (i.e. a numeric reward for outcome)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What is the pseudo code for Minimax algorithm?

A

function Minimax-Decision(game) returns an operator
__for each op in Operators[game] do
____Value[op] ← Minimax-Value(Apply(op, game), game)
__end
__return the op with the highest Value[op]

====

function Minimax-Value(state, game) returns a utility value
__if Terminal-Testgame then
____return Utilitygame
__else if max is to move in state then
____return the highest Minimax-Value of Successors(state)
__else
____return the lowest Minimax-Value of Successors(state)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Properties of minimax?

A

Complete - Yes, if tree if finite

Optimal - Yes, against an optimal opponent. Otherwise might result in infinite loop

Time - O(b^m)

Space - O(bm), depth first exploration

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

How to impose resource limits for Minimax?

A
  • Cutoff (depth limit)

- Evaluation function (estimate the desirability of a position)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

a-b pruning example

A

Page 14 - 18 Lecture 4

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Properties of a-b?

A

Pruning does not affect final result

Good move ordering improves effectiveness of pruning
- order better moves to be considered first

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What is the time complexity of a-b pruning with “perfect ordering”

A

O(b^(m/2))

- Doubles depth of search

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Give an example of a method of metareasoning

A

a-b pruning

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What is the pseudocode of a-b pruning

A

Basically it’s Minimax AND keeping track of alpha, beta AND pruning

function Max-Value(state, game, α, β) returns the minimax value of state

inputs:
- state, current state in game
- game, game description
- α, the best score for max along the path to state
- β, the best score for min along the path to state

\_\_if Cutoff-Test(state) then return Eval(state)
\_\_for each s in Successors(state) do
\_\_\_\_α ← Max(α, Min-Value(s, game, α, β))
\_\_\_\_if α ≥ β then return β
\_\_end
\_\_return α

=====

function Min-Value(state, game, α, β) returns the minimax value of state
__if Cutoff-Test(state) then return Eval(state)
__for each s in Successors(state) do
____β ← Min( β, Max-Value(s, game, α, β))
____if β ≤ α then return α
__end
__return β

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Examples of non-deterministic games

A
  • Backgammon
  • Monopoly

In Backgammon and Monopoly the dice rolls determine the legal moves

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

Is it possible to apply a-b pruning in nondeterministic games?

[Follow-up]

A

Yes, a version of expectiminimax is possible for a-b pruning.

HOWEVER, only if the leaf values are bounded.

As depth increases, probability of reaching a given node shrinks
- Value of lookahead is diminished

a-b pruning is much less effective

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

When representing games as a search function, when do exact values matter and don’t matter?

A

Deterministic = Don’t matter (chess)

Non-deterministic = Matter (backgammon/monopoly)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Does minimax give perfect play?

A

Yes for deterministic games, perfect-information games.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

Does expectiminimax give perfect play

A

Yes

17
Q

What’s the benefit of iterative deepening with minimax?

A

obviously with minimax for any iteration of minimax with a depth below the max depth, the minimax algo has to pick the best move based only on the eval function, not the final reward

so the idea i have is
minmax gives you an estimate of the best move
which you then explore first, in your next iteration

and the reason that improves pruning is because pruning is optimised when the best moves are selected first
however its not perfect
because your eval function could suck
in which case you would not end up pruning anything

=====

implementing a cutoff depth limit helps with resource limits such as time or space