215k views
5 votes
The monkey-and-bananas problem is faced by a monkey in a laboratory with some bananas hanging out of reach from the ceiling. A box is available that will enable the monkey to reach the bananas if he climbs on it. Initially, the monkey is at A, the bananas at B, and the box at C. The monkey and box have height Low, but if the monkey climbs onto the box he will have height High, the same as the bananas. The actions available to the monkey include Go from one place to another, Push an object from one place to another, ClimbUp onto or ClimbDown from an object, and Grasp or Ungrasp an object. The result of a Grasp is that the monkey holds the object if the monkey and object are in the same place at the same height.a. Write down the initial state description.b. Write the six action schemas.C . show a complete partial order plan that achieves the goal state Have(Monkey, Bananas).

User Frank W
by
3.3k points

1 Answer

4 votes

Answer:

a) initial state description

At(Monkey, A) ∧ At(Bananas, B) ∧ At(Box, C) ∧

Height(Monkey, Low) ∧ Height (Box, Low) ∧

Height (Bananas, High) ∧ Push(Box) ∧ ClimbUp(Box)

b) the six action schemas.

1 - Go from one place to another

Action (Go(x, y),

PRECONDITION: At (Monkey, x)

EFFECT: At (Monkey, y) ∧¬At(Monkey, x))

2 - Push an object from one place to another

Action (Push(b, x, y),

PRECONDITION: At (Monkey, x) ∧ Can Push(b)

EFFECT: At(b, y) ∧ At (Monkey, y) ∧¬At(b, x) ∧¬At(Monkey, x))

3 - Climb up unto an object

Action (ClimbUp(b),

PRECONDITION: At(b, x) ∧ At(Monkey, x) ∧ ClimbUp(b)

EFFECT: On (Monkey, b) ∧¬Height (Monkey, High))

4 - ClimbDown from an object

Action (ClimbDown (b),

PRECONDITION: On (Monkey, b) ∧ Height (Monkey, High)

EFFECT: ¬On (Monkey, b) ∧¬Height (Monkey, High) ∧ Height(Monkey, Low))

5 - Grasp an object

Action (Grasp (object, position, height),

PRECONDITION: Height(Monkey, h) ∧ Height(b, h) ∧ At(Monkey, x) ∧ At(b, x)

EFFECT: Has(Monkey, b))

6 - Ungrasp an object

Action (Ungrasp(b),

PRECONDITION: Have(Monkey, b)

EFFECT: Has(Monkey, object))

c) general goal state.

Has(Monkey, Bananas, s) ∧ (ЗхAt(Box, x, s₁) ∧ At(Box, x, s))

STRIPS only consider about goal state, there is no relation between two states within the plan, so there is no way to represent this goal.

User VamsiKrishna
by
3.9k points