State-Based Models and Search Algorithms Overview

0.0(0)
studied byStudied by 0 people
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
Card Sorting

1/59

encourage image

There's no tags or description

Looks like no tags are added yet.

Study Analytics
Name
Mastery
Learn
Test
Matching
Spaced

No study sessions yet.

60 Terms

1
New cards

State space

Provides a number of possible solutions to a given problem.

2
New cards

Problem space

The problem domain where the knowledge is represented.

3
New cards

Solution

The answer for the problem that can be searched for in the space.

4
New cards

Blind search

Algorithms that search through all the problem spaces for the solution.

5
New cards

Backtracking

A blind search algorithm that searches every possible combination. Recursive and uses a depth-first approach.

6
New cards

Brute force search

Another name for backtracking search.

7
New cards

Exhaustive search

Another name for backtracking search.

8
New cards

Breadth-first search

Systematically searches for a solution along all nodes on one level before considering nodes at the next level.

Guaranteed to find the shortest path.

9
New cards

Time complexity of BFS

O(b^d)

(b = branching factor; d = depth; Exponential).

10
New cards

Space complexity of BFS

O(b^d)

(b = branching factor; d = depth; Exponential).

11
New cards

Depth-first search

Looks for a solution along each branch of a problem space to its full vertical length.

12
New cards

Blind alley

A situation where DFS goes deeper into the search space without finding anything.

13
New cards

Time complexity of DFS

O(b^d)

(b = branching factor; d = depth; Exponential).

14
New cards

Space complexity of DFS

O(d)

(d = depth; linear)

15
New cards

Uniform cost search

Uses the lowest cumulative COST to find a path from the source to the destination.

Special case of A* where heuristic is constant.

16
New cards

Priority queue

The structure used to store the frontier in uniform cost search.

17
New cards

Iterative deepening depth first search (ID-DFS)

Hybridizes BFS and DFS, also known as depth limited DFS.

18
New cards

Time complexity of ID-DFS

O(b^d)

(b = branching factor; d = depth; Exponential)

19
New cards

Space complexity of ID-DFS

O(bd)

(b = branching factor; d = depth)

20
New cards

Heuristic search

Algorithms that use a rule of thumb (a HEURISTIC) to select which state to explore first.

21
New cards

Heuristic

A rule of thumb that hints at how close a state is to the goal.

Sum of cost to node and estimate of cost from node to goal.

22
New cards

Greedy best first search

Attempts to find the most promising path (best HEURISTIC) from a given starting point to a goal.

Special case of A* where edge weights are constant

23
New cards

Heuristic function

The function $h(n)$ used to estimate the cost to reach the goal.

24
New cards

A-star search

Uses the heuristic function $h(n)$ along with the cost to reach the node $n$ from the start state $g(n)$.

25
New cards

Fitness number

The path with the lowest $f(n) = h(n) + g(n)$.

26
New cards

Admissible heuristic

A heuristic that never overestimates the true optimal cost from a node to the goal.

27
New cards

Adversarial games

Real-world problems where the agent is not the only one making decisions, such as turn-based board games.

28
New cards

Game tree

Models the possible choices that can be made by either player throughout the game.

29
New cards

Depth

Refers to the number of turns since the start state.

30
New cards

Ply

Refers to a single cycle of all players' turns.

31
New cards

2-player zero-sum game

Played between 2 players where one player's gain is equivalent to the other player's loss.

32
New cards

Zero-sum game structure

Defines the structure of a zero-sum game with players, start state, actions, successor function, end state, utility, and player turn.

33
New cards

Players

The set Players = {agent, opp}

34
New cards

Start state

s_start: The initial state of the game

35
New cards

Actions

Actions(s): The possible actions from a state s.

36
New cards

Successor function

Succ(s, a): The resulting state when choosing an action a from a state s.

37
New cards

End state

IsEnd(s): True iff s is an end state (game is finished).

38
New cards

Utility

Utility(s): Agent's utility at an end state $s$ (i.e., the expected value of an end state $s$).

39
New cards

Player turn

Player(s): Whose turn it is at state $s$ (agent or opponent).

40
New cards

Policy

Describes how the opponent behaves at a given action point.

41
New cards

Probability of action

π_opp(s, a) represents the probability of the opponent choosing a specific action a in state s.

42
New cards

Dumb opponent

The opponent picks a random move with equal probability

43
New cards

Stochastic opponent

The opponent picks a move based on some probability distribution, e.g. π_opp(s, a) ∈ [0, 1]

44
New cards

Expectimax

The expectimax search function will attempt to pick the best move for the agent assuming a stochastic opponent policy.

45
New cards

Expected value for expectimax

The expected value of a state $s$ is given by the evaluation function

46
New cards

End state in expectimax

The value is given by the utility function.

47
New cards

Agent's turn in expectimax

The value is the max out of the values of all possible actions.

48
New cards

Opponent's turn in expectimax

The value is a weighted average (based on probability) of the values of all possible actions.

49
New cards

Minimax

The *minimax search function will attempt to pick the best move for the agent assuming an optimally smart* opponent.

50
New cards

Expected value for minimax

For the cases where $s$ is an end state and for where $s$ is the agent's turn, identical to expectimax.

51
New cards

Opponent's turn in minimax

The value is the minimum of the values of all possible actions.

52
New cards

Characteristics of minimax

*Complete if the game tree is finite; Optimal* iff the opponent also behaves optimally; Time complexity: $O(b^d)$; space complexity: $O(bD)$.

53
New cards

Minimax algorithm

Finds the optimal strategy (or just the best first move) for max (agent).

54
New cards

Brute-force approach in minimax

1. Generate the *entire game tree; 2. Apply the utility function to the leaves (their value*); 3. Back-up values from leaves towards the root; 4. Upon reaching the root: choose max value and the corresponding move.

55
New cards

Optimizing the minimax algorithm

There are three main ways to further optimize the minimax algorithm.

56
New cards

Pruning redundant states

Prune redundant states based on the rules of the game.

57
New cards

Depth-limited search

For game trees that are too deep, set a limit to the depth to be explored.

58
New cards

Evaluation function

An *evaluation function* is an estimation of how good the state is for the agent.

59
New cards

Alpha-beta pruning

Don't explore a branch if we're sure a better path already exists, which may significantly shrink the search space.

60
New cards

Alpha-beta pruning process

1. Initialize alpha to $-\infty$ and beta to $\infty$; 2. Perform the minimax algorithm, but update alpha and beta values accordingly.