2- Solving problems by searching Flashcards

1
Q

1.what’s the problem formulation of search problem?

A
  • Initial state of agent
  • Actions available to the agent
  • Transition model :description of each action does
  • Goal test : check if a certain state is a goal
  • Path cost : numeric value to measure
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

2.describe uninformed search algorithms

A

It can be considered as a tree made up all the possible sequenced of actions from initial state.

In the tree the root is initial state, nodes are states, branches are actions.

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

3.Tree search algorithm

A

Function TREE-SEARCH returns either a solution or a failure.
frontier: the set of all leaf nodes available for expansion at any given point.
leaf node: a node with no kid in the tree

Process:
1. Initialize the frontier using the initial state of problem
2. loop do
if the frontier is empty , return failure
choose a leaf node and remove it from the frontier.
if the node contains a goal state then return ther solution. expand the chosen node, adding the resulting nodes to the frontier.

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

4, how to improve tree search algorithm in order to avoid reduant paths?

A

Using explored set that remembers every expanded node.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q
  1. Graph search algorithm(improved tree-search)
A

1,Initialize the frontier using initial state
2, loop do
if the frontier is empty –> return failure
choose a leaf node and remove it from the
frontier
if the node contails a goal state then return the corresponding solution
add the node to explored set.
expand the chosen node, adding the resulting node to the frontier. (only not in frontier or explored set)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q
  1. Breadth-first search algorithm
A

b: branching factor of the search tree
d: depth of least-cost solution
m: maximum depth of the state space

frontier as FIFO: the successor will go at end

time: O(b^d)
space: o(b^d)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q
  1. Depth-first search
A

Explore the deepest unexpanded node.

LIFO: new successor at first
Time : O(b^m) terrible if 𝑚 is much larger than 𝑑
Space:O(b*m)

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

8.Depth-limited search

A

To avoid problems of the limitless trees, we use depth-first search with a depth limit L.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q
  1. Iterative deepening search
A

It repeatedly applies depth-limited search with increasing limits

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q
  1. In what way makkes iterative deepening search better than others?
A

1, if b iif finite, will be complete

  1. Optimal cost for unit step cost
  2. time complexity comparable to breadth-first search
  3. linear sapce complexity
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q
  1. def of Heuristic function?
A

Heuristic function = estimate of cost of the cheapest path from the state of the node N to the goal state.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q
  1. Greedy best first search and A* search?
A

Greedy best-first search : expands the node that appears to be the closest to goal. f(n) = h(n)

A* search : avoid expanding paths that are already expensive

fn = gn + hn

gn: path cost from the start node to node n
hn: estimated cost of the cheapest path from n to goal
fn: estimated cost of the cheapest solution through n

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

13.admissible heuristics and consistent heuristics

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

14.stable marriage definition

A

In a marriage that no pair (man, woman) that not married to each other that would prefer to be together. Or marriage with no blocking pairs.

Blocking pair: in a pair where this wife prefers that marriage’s husband. And this husband prefers that marriage’s wife.

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

14.stable marriage definition

A

In a marriage that no pair (man, woman) that not married to each other that would prefer to be together. Or marriage with no blocking pairs.

Blocking pair: in a pair where this wife prefers that marriage’s husband. And this husband prefers that marriage’s wife.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q
  1. Gale Shapley algorithm
A
  1. Initinize all people are free
  2. while exits a free man
    find best woman he hasnt proposed yet to make proposal
    if this woman is free, then declare they’re engaged.
    else:
    if this woman prefers this proposal to current one, then declare them engaged.
    else this women prefers the current partner, and she reject the proposal.