reset password
Author Message
rabbott
Posts: 1649
Posted 17:38 Apr 21, 2013 |

You guys didn't listen to the description of Robby carefully enough (ssection 5.2). There is a good reason why there are 243 symbols in the strategy string. Each strategy consists of an instruction for each possible situation the robot can be in. A situation consists of the contents of the robot's cell along with the contents of the cells North, South, East, and West. Since a cell can contain Empty, Can, or Wall there are 3^5 = 243 possible situations.  For each of these the robot takes an action. So a strategy consists of the action the robot should take for each of the 243 possible situations.

Essentially a strategy is a table where the first 5 columns are the contents of the cells and the last column is the action to be taken if that situation holds. But since the table consists of all possible combinations of (E, C, W) there is no need to write them down. First of all, think of E as 0, C as 1, and W as 2. Then the rows are all numbers from 000 to 222. Each strategy has the same rows. The only thing that differs from one row to another is the action to be taken, the final column.

Since there are 7 possible actions, the number of possible strategies is 7^243. (Can you explain why that's true?)

Do you understand how the evolved strategy "remembered" how to get all cans in a cluster?

 

Last edited by rabbott at 17:42 Apr 21, 2013.
Yehcheng
Posts: 10
Posted 19:34 Apr 21, 2013 |

Now I understand better this model, for some reason I missed the second video for the section 5.2. In the program the string with 234 symbols are the actions Robby should do. Each symbol in the string, mean one action corresponding to a situation.

Since there are 7 possible actions, the number of possible strategies is 7^243. We can show this is true by thinking that there is 243 windows next to each other. Each windows can show a number from 0 to 6. That mean the number of combination would be 7x7x7x7x....x7 = 7^243 (2.284671e+205). In this case, each window would represent a symbol in the string in the code.

The evolved strategy "remembered" how to get all cans in a cluster by simply taking the correct action when there is a situation when there is 2 cans or more in Robby's 'sight'. For example the situation when there is a can on the north, a can on the east and a can on the current location, Robby can move north or east instead of picking up the can. By taking that action, when Robby move to either north or east, lets assume he move east. His new situation after moving east can be, a can on the current location, a can on west (where he was) and no cans on the north,east,south. Then his next action would be picking up the can on the current location which change his situation to, no can on current location,north,south,east and a can on the west. Since he didn't pick up the can to the west, he can backtrack and move back to west and pick up the can, then move north and pick up the last can. This strategy can make you believe that Robby actually developed memory when he doesn't have.

rabbott
Posts: 1649
Posted 21:03 Apr 21, 2013 |

Right.

About crossover probability, it's not where the crossover point is allowed to be in the 243 symbols. It's whether or not crossover will occur. This seems like a strange idea. Why create children from two parents if there is no crossover. If the coin-toss according to the crossover probability is don't cross over, the two children will be the same as the parents. If it's cross over, crossover occurs as usual. The default for the program as written is always do crossover. The only advantage I can think of for not doing crossover is that it preserves existing elements of the population.  That's one way to keep good elements from one generation to the next. But there are better ways.

Last edited by rabbott at 21:50 Apr 21, 2013.