you’ll have to pardon me while i wax anthropomorhpic for a moment. why is it that robots, designed or imagined, always exist solely to fulfill a purpose or pleasure for human beings? don’t they have feelings too? maybe it’s about time we made some robots whose sole purpose is to hook up with other robots, get a little freaky, and make some robot progeny.
in this article we’ll be exploring robot love. i made a couple of simple lego mindstorms robots and programmed them to reproduce — i.e. they can swap code. effectively, two robots come together, trade their genome, die, and two new robots are born in their place.
turn up the barry white. get out your mindstorms. let’s get it on.
when i started working on this project, i had to make some initial decisions about how robot reproduction would actually work. since they can’t create a new robot, their reproduction will have to function a little differently than what we are accustomed to.
what i wanted was some mechanism that would enable two parent robots to combine their software to produce two distinct child robots, which would replace their parents and exhibit new and unique behavior.
the robots i am using are simple two-wheel, two-sensor bots. in these bots, the genome will serve to determine the behaviors of the robot’s normal life processes, namely:
the robot’s primary execution loop
what to do if the left sensor is hit
what to do if the right sensor is hit
the genetic code determines what happens in each of these three tasks. possible actions can be any combination of the following:
attempt to reproduce
so a reasonable execution loop might be: forward, mate, forward, etc.
a left sensor loop might be: backward, right, right, etc.
getting it on
each of the three life processes has a fixed length. when the robot is turned on, these are initialized to a very basic routine and most of the possible actions are filled with noops.
when a robot attempts to mate, it sends out a signal on the ir port. if the other robot is able to see this signal, it will initiate a handshake to begin the genome transfer. the parents trade one piece of a routine at a time, replacing their former actionwith the new child program.
in order to deter child generations from becoming lazy, i added a requirement that a certain number of movements had to occur between each successful mating before they could become ‘mature’ and capable of initiating the mating procedure.
when two robots reproduce, each recieves a copy of the other’s genetic code. the outcome for each possible action for each life routine is a random choice between the two parent codes. this alone would result in some pretty booring children, given that both parents are initialized with the same code, so i added a roughly 1 percent chance that a mutation will occur for each action that is copied.
the idea is that a robot which is better capable of maneuvering around without getting stuck will have a better chance of finding another robot and procreating.
unfortunately, i only have two robots at my disposal, but the results have still been really interesting. all sorts of different behaviors have cropped up, from robots that drive in big circles and zig-zags, to ones that always go in the same direction when they hit something.
in a small population, however, things don’t always work out for the best. one of the robots pictured above mutated such that it didn’t turn when a sensor was hit. the second robot managed to mate with it once, but then became plagued with the same genetic malfunction. they were unable to get out of the corner and basically became extinct.
with a larger population, you would probably see fewer mass extinctions and more interesting group behavior. with only two robots, they tend to have a nearly identical makeup in each generation.
one could imagine a larger colony breaking up into different classes — some robots that don’t move much and are easy to be found, and others that are good at wandering and spreading throughout the community.
if anyone out there has access to a bunch of mindstorms, give it a try and let us know about your results.
aside from just being a simple and fun way to model life and evolution (not to mention a shameless title for an article), sex bots have some interesting potential applications.
when i released my robots for the first time, the software that i initialized them with was not ideally suited for the environment i placed them in. occasionally they got hung up in corners, or moved around in continuous circles that would never intersect and allow them to see eachother.
with a small starter community, you could just turn them loose in their environment and let them run for a while. they would genetically optimize their routine to fit their environment. those that couldn’t find eachother would essentially become extinct. the rest would adapt to maneuvering in their environment while maintaining communication.
automatic software updates
you could also pretty easily code in a version identifier. when mating, a robot would check to see if they are from the same version pool as the other. a previous version would adopt the new version in whole, whereas two robots of the same version would mate normally. imagine a distributed, loose network of robots that need a software upgrade. simply release a few robots with the new software and the population would eventually convert automatically to the new version.
your idea here
there are undoubtedly many ways to go about making a reproducing robot, and i’m sure there are many more uses for this technology that i haven’t even though of. so go make your own sex bots and let us know about it!