Search the Mindcreators site: 

Update Alert!

I have now finished work on a much more advanced version of the insect simulator named AnimatLab. AnimatLab is a software tool that combines biomechanical simulation and biologically realistic neural networks. You can build the body of an animal, robot, or other machine and place it in a virtual 3-D world where the physics of its interaction with the environment are accurate and realistic. You can then design a nervous system that controls the behavior of the body in the environment. The software currently has support for simple firing rate neuron models and leaky integrate and fire spiking neural models. In addition, there a number of different synapse model types that can be used to connect the various neural models to produce your nervous system. On the biomechanics side there is support for a variety of different rigid body types, including custom meshes that can be made to match skeletal structures exactly. The biomechanics system also has hill-based muscle and muscle spindle models. These muscle models allow the nervous system to produce movements around joints. In addition, there are also motorized joints for those interested in controlling robots or other biomimetic machines. This allows the user to generate incredibly complicated artificial lifeforms that are based on real biological systems. Best of all AnimatLab is completely free and it includes free C++ source code!

4.5.2 Eating

1. Introduction

The insect can now explore its environment, and search for and find food. Unfortunately, it still can not eat any of the food it finds. And if it can not eat, then it will soon die. The examples from the appetitive controller all showed the insect reaching the food, and then walking right past it. But in order to eat, it needs to stop directly over top of the food. Once stopped, it must then open and close its mouth to take bites of the food. And finally, it must begin moving again once it has eaten its fill. Also, another problem that must be addressed is that of eating in meals as opposed to constant grazing. Insects like the cockroach usually find a juicy scrap of food and eat until they are full or the food is gone. They do not eat just a little bit until they are no longer hungry and then walk off and immediately get hungry again. They eat an entire meal at one time.

2. Eating Neural System

Eating Neural Layout
Figure 1. This is the neural layout for the eating controller.

The eating controller uses two primary sensors. These are the Mouth Tactile Sensor (MTS) and the Mouth Chemical Sensor (MCS). MTS is setup to only fire when the insects mouth is directly over the top of a pile of food. MCS is very similar to the chemical sensors of the antenna. The main differences are that it is located near the mouth, and it has a very low gain. Food must be very near this chemical sensor for it to fire. These two sensors then feed into the Food Present (FP) neuron. It uses those two sensors to determine if food is currently present under the insects mouth. Food is only present if both of the two sensors are firing simultaneously. If food is present, then the FP neuron stimulates the Consummatory Control (CC) neuron. CC controls whether the insect is actively trying to eat or not. If it is firing, then the insect is attempting to eat. That does not mean it is actually eating, just that it is trying to eat. If CC was firing for some reason while the insect was not directly over a pile of food it would not actually consume anything. It would just be opening and closing its mouth for no apparent reason. However, FP alone can not cause CC to fire and make the insect try to eat. It must also be hungry. And hunger is controlled by the Feeding Arousal (FA) neuron. If the insect is hungry, and food is present, then CC will fire and the insect will begin eating. When CC fires it stimulates the Bite Pacemaker (BP) neuron. This pacemaker is what controls the opening and closing pattern for the mouth. The Mouth Bite Control (MBC) neuron was added to actively inhibit BP whenever food was not present to make sure it can not cause the mouth to open and close. When BP fires it stimulates the Mouth Open (MO) neuron which causes the insect to open its mouth. This in turn inhibits the Mouth Tonic Close (MTC) neuron. That neuron is always trying to close the mouth. If it is disabled, and MO is firing, then the mouth will open. When BP stops firing, MTC will no longer be inhibited, and it will stimulate the Mouth Close (MC) neuron to once again close the mouth and swallow one bite of food. The simulation software for the mouth has code that states that if the mouth passes a specific threshold rotation in a given direction while food is under the mouth then this is seen as a bite of food. One piece of food is removed from the pile, and the energy density for that piece of food is added to the energy stores for the insect.

3. Meals Vs. Grazing

The previous section explains the basics of how the insect takes bites of food, and what triggers it to take the bites. But what is there to keep an insect eating till it is full, as opposed to just eating until it has replenished its energy to the point where FA stops firing enough to stimulate CC? In the examples used for this document the hunger neuron FA and the Energy Sensor neuron ES are setup so that the insect does not begin getting hungry until its energy drops to around 75%. So in that case, when the insect ingests enough food to go over this value it would no longer be hungry and would no longer stimulate CC to continue eating. This would mean that when it came to a plentiful supply of food it would not eat until it was full, but just until it was no longer hungry. However, it is in the animals best interest to eat until its energy is completely renewed. Because while it may have found food now, it may not be so lucky all the time. This is the behavior seen by most animals and insects. Once they find food when they are hungry they eat an entire meal. This happens because the act of eating actually encourages the hunger to a certain point. How many times have you smelled some food cooking and then suddenly realized that you were hungry. The smell and the taste of the food help to stimulate the hunger response. In humans it is things like the sensors in the stomach that finally begin to override this and tell the brain that you are full and shut off the hunger. If this did not happen then you would be stuck in a positive feedback loop and simply continue eating and eating. The simulated insect also uses these principles to eat meals instead of graze. Figure 1 shows an excitatory connection going from the MO neuron to the FA neuron with a weight of 25 na. Figure also shows a modulatory connection between ES and FA. This connection modulates the MO to FA connection. As the insect opens its mouth to take a bite it stimulates the FA neuron and increases the hunger of the insect. As long as FA is causing CC to fire the insect will continue to open and close its mouth further stimulating FA. However, if the insect is very near to being full the modulatory connection greatly diminishes this stimulation from MO, and FA finally falls below the level that will cause CC to fire and the insect no longer opens its mouth.  

4. Eating Analysis

Video 1. This video demonstrates the insects ability to eat food in a grazing manner.

Video Size: 1.9 Mb

This example uses the controller shown in figure 1 with one minor change. The weight for the axon connecting MO to FA is reset to 0 na. Both of these examples also have the random wandering disabled. First notice in the graph that MCS rises as the insect gets near the food, but FP only fires once MTS fires. Immediately thereafter CC also begins firing. Once CC begins firing BP starts generating rhythmic bursts which cause the mouth to rotate open and closed. Each time the mouth does this there is a corresponding jump in the energy level of the insect. Finally, notice that as the insect reaches the 0.5 mark on the energy level that FA begins falling. Once the energy reaches around 0.75 FA is not firing at all and CC also stops firing. At that point the insect stops taking bites of food and begins moving off again. It has found food and eaten some, but it only filled its stomach three quarters full.  

Eating A Meal
Video 2. This video demonstrates the insects ability to eat food in a meal.
Video Size: 2.4 Mb

This example is identical to the one above except that the controller is now intact. Everything happens exactly the same until near the end. In the example above FA began falling at around the 50% mark. But in the example here it does not start falling until around the 80% mark. Why the difference? This is because MO is stimulating FA enough that its capacitance is able to keep it fully charged for longer. So it does not start falling until the modulatory connection has reduced that stimulus enough that it can no longer fully charge FA. However, even once that happens it still has a major effect. Each time the insect closes its mouth it stimulates FA. That is what causes the spikes visible in FA and CC as those two fall. Eventually the insect is completely full and MO is just no longer able to stimulate FA enough to keep it eating. The insect then begins to move off away from the food. However, this time it does so with a full tummy. 

Not Hungry
Video 3. This video demonstrates what happens when the insect encounters food and it is not hungry.
Video Size: 965 Kb

Finally, This example shows what happens when the insect walks directly over food when it is not hungry. First notice that unlike in the two previous examples, FA is not firing. As the insect gets near the food MCS behaves exactly as before. And when it walks over the top of the food both MTS and FP fire. However, This time CC does not fire because FA is not firing. So the insect just ignores the food and keeps walking. 

5. Overview

Eating is a critical behavior for any organism. Everything has to get its energy from somewhere in order to survive, and the simulated insect is no different. The eating controller described here allows the insect to eat food by opening and closing its mouth while on top of a crumb of food. It is also selective. If the insect is not hungry then it will not attempt to stop and take a bit of food. So now the insect can continue to putter around its environment as long as the food holds out and it is able to find some before it starves to death. The next section will discuss what happens when the insects luck runs out and it is unable to find and eat some more food before its energy level hits zero.

<< Previous Contents Home Next >>

MindCreators.Com is edited and maintained by David Cofer. If you have any questions, comments, or just want to discuss the contents of this website, then email me at:

Copyright © 2002 by David Cofer. All rights reserved.