X hits on this document

Powerpoint document

Lecture 2: Problem Solving using State Space Representations - page 35 / 49

110 views

0 shares

0 downloads

0 comments

35 / 49

Slide Set 2: State-Space Search 35

ICS 271, Fall 2007: Professor Padhraic Smyth

Production Rules for the Water Jug Problem

Fill the 4-gallon jug

Fill the 3-gallon jug

Pour some water out of the 4-gallon jug

Pour some water out of the 3-gallon jug

Empty the 4-gallon jug on the ground

Empty the 3-gallon jug on the ground

Pour water from the 3-gallon jug into the 4-gallon jug until the 4-gallon jug is full

1 (x,y) (4,y)

  if x < 4

2 (x,y) (x,3)

  if y < 3

3 (x,y) (x – d,y)

  if x > 0

4 (x,y) (x,y – d)

  if x > 0

5 (x,y) (0,y)

  if x > 0

6 (x,y) (x,0)

  if y > 0

7 (x,y) (4,y – (4 x))

  if x + y 4 and y > 0

Document info
Document views110
Page views110
Page last viewedMon Dec 05 10:29:20 UTC 2016
Pages49
Paragraphs815
Words3134

Comments