Although the pheromone heatmap provides insight into ant behavior for specific generations, we wanted to see how the behavior evolves over all generations. In order to compare different input-to-output correlations and validate our results obtained from the heatmap, we calculate the correlation coefficients between input and output spike trains for the first ant of the best individual every tenth generation. We then fit a linear regression on the coefficients, which returns a p-value and the slope s; a low p-value rejects the null-hypothesis that the slope of the curve is zero, i.e. there is not a correlation. Additionally, we calculate the standard deviation \(\sigma\) of all points.
The visualization in Fig.
16 enables us to determine trends in the ant behavior over generations. Note, that only plots with a p-value below 0.005 are displayed. We hypothesise that the ants progressively learn to avoid the red walls and turn away when approaching them. In contrast, they seem to move towards the food patches and the nest based on sensing the pheromones or on visual stimuli. For example, we observe that
Wall is initially positively correlated to
Move but there is a trend towards anti-correlation over the generations. While
Food and
Move show an increasing trend,
Wall and
Move become increasingly negatively correlated over the generations. Likewise,
Smell Right shows a trend towards an increasing positive correlation with
Right and a negative correlation with
Left.
Smell Left is initially positively correlated to
Move, but this correlation decreases for later generations. In contrast, the correlation between
Smell Left and
Nest Left increases, while it decreases for
Nest Right. It appears that the ants developed a perception for the nest and turn towards the corresponding direction. The sensor for
Smell Middle shows an increasing trend towards positive correlation with
Move.
Nest Middle has an increasing positive correlation with
Left, while
Nest Right has an increasing negative correlation with
Left as the colony evolves. We further hypothesize that the ants have a tendency to move after they visited the nest in order to explore the environment or forage for food. At the end of the evolution there is a positive correlation between
Move and
On Nest and a negative correlation with
Left or
Right and
On Nest. Pheromone is initially dropped in the vicinity of the nest. However, the pheromone output activity, when the ant is in the middle of the nest, decreases over the generations. In contrast,
Food and
Pheromone show an increasing positive trend.
While observing the performance of the ant colony especially at the end of the evolutionary process, pheromone trails emerge and form attractors with higher pheromone concentration. This results from a combination of the evolutionary pressure of the fitness metric towards the pattern: explore, get food, return to nest
, as well as the optimized actions which includes sensing the pheromone and exploiting the pheromone dynamics (evaporation and diffusion). This resembles the actual behavior of ant colonies observed in nature.