Lecture 3 Flashcards
What does a search algorithm do (in generic terms)?
A search algo takes a search problem as input and returns a solution or indication of failure.
In what kind of environment is the solution to any problem a fixed solution of actions?
In an environment that is fully observable, deterministic, and known.
What is an admissible heuristic?
One that never overestimates the cost to reach the goal. Thereofore, it is optimistic.
How do we decide which node from the frontier to expand next?
Using a search function, such as best-first, breadth-first, or depth-first search.
What are the 4 ways to measure the performance of a search algorithm?
- Completeness
- Cost Optimality
- Time Complexity
- Space Complexity
What is the difference between an informed and uninformed search?
Informed knows how far the node is from the goal at any given step of the algorithm, whereas uninformed never has any idea of its distance from the goal.
How can you implement a BFS using Best-First Search?
f(n) = n.depth
Using the node’s depth as the evaluation function.
How can you implement a DFS using Best-First Search?
f(n) = -n.depth
Using the negative of the node’s depth as the evaluation function.
How can you implement a Dijkstra’s using Best-First Search?
f(n) = n.pathCost
Using the node’s path cost as the evaluation function.
What could go wrong if you use greedy best-first search for path-finding?
It is prone to getting stuck in local optima or dead ends. Because the algorithm always prioritizes nodes that appear to be closest to the goal, it may not explore other potentially useful paths or nodes that are further away from the goal but could ultimately lead to a better solution.
Is A* cost-optimal?
It depends on the heuristic function. If the heuristic function is admissible or consistent, A* is cost-optimal. Otherwise it may not be cost-optimal.
What is the performance difference between running hill-climbing search (or simulated-annealing) for k times and beam search of size k?
hill-climbing search with 5 threads could have essentially the same result. (the 4 that are bad will stay until the end because there is no way to prune them)
in local beam-search, bad options are pruned from the beginning, and you’re taking the k best
Considering the vanilla implementation of MINIMAX, discuss the disadvantages and possible solutions to fix them.
Memory and speed problems due to the algorithm’s requirement to expand a node on the tree all the way to the bottom of the tree.
- Alpha-Beta pruning can help speed up the algorithm by preventing some nodes from even being calculated.
- Depth-limit will solve the problem. We use heuristics to estimate the possible score for non-goal states.
What is a competitive Environment?
An environment in which two or more agents have conflicting goals.
Adversarial agents can be considered one of which 3 environment stances?
- an economy
- part of the environment (making it non-deterministic)
- explicitly modelled