Presentation is loading. Please wait.

Presentation is loading. Please wait.

A Series of Slides in 5 Parts Movement 3. IDFS

Similar presentations


Presentation on theme: "A Series of Slides in 5 Parts Movement 3. IDFS"— Presentation transcript:

1 A Series of Slides in 5 Parts Movement 3. IDFS
Maze Running in C Minor A Series of Slides in 5 Parts Movement 3. IDFS

2 MAX DEPTH: 1 AT: AA STACK: AB KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

3 MAX DEPTH: 1 AT: AB STACK: Note that since we are at depth 1, we do not push any neighbors of AB onto the stack. KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

4 MAX DEPTH: 2 AT: AA STACK: AB KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

5 MAX DEPTH: 2 AT: AB STACK: BB AC Note that we push all neighbors except for the node we just came from. KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

6 MAX DEPTH: 2 AT: BB STACK: AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

7 MAX DEPTH: 2 AT: AC STACK: KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

8 MAX DEPTH: 3 AT: AA STACK: AB KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

9 MAX DEPTH: 3 AT: AB STACK: BB AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

10 MAX DEPTH: 3 AT: BB STACK: CB BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

11 MAX DEPTH: 3 AT: CB STACK: BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

12 MAX DEPTH: 3 AT: BA STACK: AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

13 MAX DEPTH: 3 AT: AC STACK: KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

14 MAX DEPTH: 4 AT: AA STACK: AB KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

15 MAX DEPTH: 4 AT: AB STACK: BB AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

16 MAX DEPTH: 4 AT: BB STACK: CB BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

17 MAX DEPTH: 4 AT: CB STACK: DB BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

18 MAX DEPTH: 4 AT: DB STACK: BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

19 MAX DEPTH: 4 AT: BA STACK: CA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

20 MAX DEPTH: 4 AT: CA STACK: AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

21 MAX DEPTH: 4 AT: AC STACK: KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

22 MAX DEPTH: 5 AT: AA STACK: AB KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

23 MAX DEPTH: 5 AT: AB STACK: BB AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

24 MAX DEPTH: 5 AT: BB STACK: CB BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

25 MAX DEPTH: 5 AT: CB STACK: DB BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

26 MAX DEPTH: 5 AT: DB STACK: DE DC DA BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

27 MAX DEPTH: 5 AT: DE STACK: DC DA BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

28 MAX DEPTH: 5 AT: DC STACK: DA BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

29 MAX DEPTH: 5 AT: DA STACK: BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

30 MAX DEPTH: 5 AT: BA STACK: CA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

31 MAX DEPTH: 5 AT: CA STACK: DA AC Note that we push DA onto the stack even though we’ve already been there. This is an implementation of IDFS where no visit information is kept. KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

32 MAX DEPTH: 5 AT: DA STACK: AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

33 MAX DEPTH: 5 AT: AC STACK: KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

34 MAX DEPTH: 6 AT: AA STACK: AB KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

35 MAX DEPTH: 6 AT: AB STACK: BB AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

36 MAX DEPTH: 6 AT: BB STACK: CB BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

37 MAX DEPTH: 6 AT: CB STACK: DB BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

38 MAX DEPTH: 6 AT: DB STACK: DE DC DA BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

39 MAX DEPTH: 6 AT: DE STACK: EC EA DC DA BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

40 MAX DEPTH: 6 AT: EC STACK: EA DC DA BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

41 MAX DEPTH: 6 AT: EA STACK: DC DA BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

42 MAX DEPTH: 6 AT: DC STACK: CC DA BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

43 MAX DEPTH: 6 AT: CC STACK: DA BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

44 MAX DEPTH: 6 AT: DA STACK: CC BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

45 MAX DEPTH: 6 AT: CC STACK: BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

46 MAX DEPTH: 6 AT: BA STACK: CA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

47 MAX DEPTH: 6 AT: CA STACK: DA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

48 MAX DEPTH: 6 AT: DA STACK: DB AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

49 MAX DEPTH: 6 AT: DB STACK: AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

50 MAX DEPTH: 6 AT: AC STACK: KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

51 MAX DEPTH: 7 AT: AA STACK: AB KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

52 MAX DEPTH: 7 AT: AB STACK: BB AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

53 MAX DEPTH: 7 AT: BB STACK: CB BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

54 MAX DEPTH: 7 AT: CB STACK: DB BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

55 MAX DEPTH: 7 AT: DB STACK: DE DC DA BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

56 MAX DEPTH: 7 AT: DE STACK: EC EA DC DA BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

57 MAX DEPTH: 7 AT: EC STACK: ED EA DC DA BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

58 MAX DEPTH: 7 AT: ED STACK: EA DC DA BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

59 MAX DEPTH: 7 AT: EA STACK: DC DA BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

60 MAX DEPTH: 7 AT: DC STACK: CC DA BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

61 MAX DEPTH: 7 AT: CC STACK: CD BC DA BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

62 MAX DEPTH: 7 AT: CD STACK: BC DA BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

63 MAX DEPTH: 7 AT: BC STACK: DA BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

64 MAX DEPTH: 7 AT: DA STACK: CC BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

65 MAX DEPTH: 7 AT: CC STACK: BA BA AC This is a rather comical situation. KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

66 MAX DEPTH: 7 AT: BA STACK: BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

67 MAX DEPTH: 7 AT: BA STACK: CA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

68 MAX DEPTH: 7 AT: CA STACK: DA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

69 MAX DEPTH: 7 AT: DA STACK: DB AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

70 MAX DEPTH: 7 AT: DB STACK: EB DC CB DA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

71 MAX DEPTH: 7 AT: EB STACK: DC CB DA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

72 MAX DEPTH: 7 AT: DC STACK: CB DA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

73 MAX DEPTH: 7 AT: CB STACK: DA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

74 MAX DEPTH: 7 AT: DA STACK: AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

75 MAX DEPTH: 6 AT: AC STACK: KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

76 MAX DEPTH: 8 AT: AA STACK: AB KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

77 MAX DEPTH: 8 AT: AB STACK: BB AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

78 MAX DEPTH: 8 AT: BB STACK: CB BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

79 MAX DEPTH: 8 AT: CB STACK: DB BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

80 MAX DEPTH: 8 AT: DB STACK: DE DC DA BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

81 MAX DEPTH: 8 AT: DE STACK: EC EA DC DA BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

82 MAX DEPTH: 8 AT: EC STACK: ED EA DC DA BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

83 MAX DEPTH: 8 AT: ED STACK: DD EA DC DA BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT

84 MAX DEPTH: 8 AT: DD STACK: EA DC DA BA AC KEY: GREEN – Start RED – Exit YELLOW – Visited on this iteration Nodes are taken in the order: UP, LEFT, DOWN, RIGHT


Download ppt "A Series of Slides in 5 Parts Movement 3. IDFS"

Similar presentations


Ads by Google