Evolutionary RoboticsUsing A Formal Grammar To
Evolve Robot Bodies and Brains
Hornby, G.S., Pollack, J. (2001)Creating high-level components with a generative representation
for body-brain evolution.GECCO 2001.
Turtle Graphics (from computer graphics)
Turtle moves over a 2D surface.
Possesses:
1. Position2. Orientation3. Pen, which can be up or down.
“Code” for drawing:1. Move forward 10 paces2. Turn left 95 degrees3. Drop pen4. Move forward5. Lift pen…
Evolutionary RoboticsUsing A Formal Grammar To
Evolve Robot Bodies and Brains
Hornby, G.S., Pollack, J. (2001)Creating high-level components with a generative representation
for body-brain evolution.GECCO 2001.
1. Drop pen2. For i = 1 to 10003. forward 1 + i/10004. turn 85 degrees left5. Lift pen
Evolutionary RoboticsUsing A Formal Grammar To
Evolve Robot Bodies and Brains
Hornby, G.S., Pollack, J. (2001)Creating high-level components with a generative representation
for body-brain evolution.GECCO 2001.
Formal grammar:
1. Define an alphabet V that containselements that can be replaced (variables)
2. Define a starting ‘sentence’ composed ofelements from V(eg. ‘AB’)
3. Define a set of production rules:rule is composed of two strings:
the predecessor andthe successor
(eg. A ABB A)
4. If a symbol C in V does not match any predecessor, then C is a constant.
5. Apply the productions rules to the start sentence.
6. Continue to apply the rules until the sentenceonly contains constants.
Using A Formal Grammar To Evolve Robot Bodies and
Brains
Hornby, G.S., Pollack, J. (2001)Creating high-level components with a generative representation
for body-brain evolution.GECCO 2001.
Evolutionary Robotics
A = algaeB = bud (cannot reproduce)
A AB is a model of growth:algae ‘spawns’ a bud.
B A models maturation:bud becomes adult algaecapable of reproduction.
Evolutionary RoboticsUsing A Formal Grammar To
Evolve Robot Bodies and Brains
Lindenmayer system =
A system in which ‘turtle graphics’ commandsserve as the elements in a formal grammar.
Example: “Drawing” Cantor dust.
variables : A B
constants : none
start : A {starting character string}
rules : (A → ABA), (B → BBB)
Let A mean "draw forward" and B mean "move forward".
Evolutionary RoboticsUsing A Formal Grammar To
Evolve Robot Bodies and Brains
Lindenmayer system =
Given the right L-system, one can producestructures that look like biological plants:
Example: Fractal plant
variables : X Fconstants : + −start : Xrules : (X → F-[[X]+X]+F[+FX]-X),
(F → FF)
F means "draw forward", - means "turn left 25°", and + means "turn right 25°". X does not correspond to any drawing action.[ = ‘push’ position and angle] = ‘pop’ position and angle
Building bodies with L-systems
Hornby, G.S., Pollack, J. (2001)Creating high-level components with a generative representation
for body-brain evolution.GECCO 2001.
Evolutionary Robotics
[ = push state] = pop state{block}(n) = repeat enclosed
block n times.forward: create bar forwardbackward: move backwardRevolute-1: move forward,
add joint around ZRevolute-2: move forward,
add joint around Yup(n): rotate heading +n*90o
about turtle’s X axisdown(n): rotate –n*90o around Xleft/right(n): … around Ycounter/clockwise(n): … around Z
Turtle ‘lives’ on synapses.
If turtle’s ‘home’ link connects neuron A to neuron B…
[ = push ‘home’ link] = pop new ‘home’ link
decrease-weight(n): subtract n from weight of current link.
duplicate(n): Create new link from A to B with weight n.
loop(n): Create new link from B to itself with weight n.
merge(n): Merge neurons A and B into single neuron, C. new ‘home’ link is nth input link to C.
parent(n): move to nth input link to A.
next(n): move to nth output link from B.
reverse: link changed to point from B to A.
output(n): neuron A sends commands to the closest joint.
split(n): create new neuron C; attach edge from A to C; andcreate a new edge from C to B with weight n.
Building brains with L-systems
In the formal grammar, throw ‘body’ and ‘brain’elements together.
Turtle ‘points’ to both a body part and a synapse.
If a ‘joint’ element is called, output(1) is also called:
connects part of the neural network to the joint.
Connecting Body and Brain
Hornby, G.S., Pollack, J. (2001)Creating high-level components with a generative representation
for body-brain evolution.GECCO 2001.
Hornby, G.S., Pollack, J. (2001)Creating high-level components with a generative representation
for body-brain evolution.GECCO 2001.
Top Related