Towards the Matrix: How Simulation and Artificial Life Research Proceeds

about the project



ALiEn is an artificial life simulation program based on a dedicated physics and rendering engine in CUDA. It is designed to simulate digital organisms embedded in artificial ecosystems and to simulate conditions for (pre) biotic evolution.



Learn about the goals of the project and how to get started .







Functions



  • Realistic physical calculations of kinematic and thermodynamic processes of damaged and glued solids
  • Programmable material for modeling digital organisms and evolution
  • Built-in graphics editor for designing your own machines
  • GPU Modeling and Rendering
  • The software is open source and available under the GNU General Public License, Version 3 (GPLv3) .


Under the cut there are two examples ("Self-checking replicators" and "Information-based replication") of the use of this software package.



Case One: Self-Testing Replicators



1. Source replicators



Self-checking replicators are machines that can scan their own structure and repair it. Thus, there is no need to store design information. We will experiment with three types of self-checking replicators, differing in size and topological complexity.



image



  • . , , -, . , , , .
  • , , . .
  • , .


2.



2.1. Setup



We will run a simulation for each type of replicator. The idea is to start with a small universe filled with energy and a few initial replicators. Namely:



  • universe size: 1000 x 1000 units
  • 5,000 randomly distributed 8 x 4 rectangular blocks as "nutrients"
  • 20 replicators


The simulation parameters were chosen to create a β€œfriendly” universe, such as low mutation rate, low radiation, low energy cost for cell functions, etc. A simulation with this preconfiguration can be downloaded here:





2.2. Simulations



2.2.1. Small replicators



image



Initially, the number of replicators grows exponentially until all resources are used up. After that, an equilibrium is established in which the number of replicators (about 6000) remains constant. The video below shows how the replicators are consuming the last free resources. After that, they need to consume each other. However, due to the mutation, minor optimizations occurred, which led to the emergence of more adapted individuals. The growth of dense colonies can sometimes be observed. This phenomenon is shown in the figure taken at step 114,000. Each luminous point represents a separate individual / replicator.



Colonies tend to concentrate energy in a hostile universe and only appear stable when the universe is relatively dense due to the surrounding pressure of other materials. The high density within the colony allows for easy energy consumption by the replicators. Since they are more or less ideally adapted to their environment, there have been no further significant changes. A closer look reveals that the replicators have lost the ability to move on their own because this is no longer necessary.



Below you will find two videos: the first shows how replicators take over all available resources in a small universe. The second video gives a detailed view of the processes inside the colony.







After this initial phase, we gradually increase the size of the universe to 4000 x 1000 units and gradually increase the properties of the simulation parameter cell function -> weapons -> energy cost to 1.4. These changes, on the one hand, lower the ambient pressure and lead to the dispersal of colonies. On the other hand, energy consumption becomes more difficult. Suddenly there is a need for adaptation. Replicators develop mobility in order to more actively consume resources. After several million time steps and fixing the above parameter, the new equilibrium merges. They consume each other and produce offspring. But the number of replicators remains constant. This behavior can be seen in the first video taken after 22 million evolutionary time steps.





We then increase the above parameter to 2.4. This leads to imbalance because the replicator loses energy too quickly. However, they found a way to survive. Whenever resources are concentrated locally, they are risked, consumed and replicated as quickly as possible. After that, they disperse and most of them die. Destroyed / faulty replicators drift through space. When many of them come close, they will be absorbed by others. Thus, a more complex equilibrium arises when material waves periodically collide and are quickly absorbed by several existing replicators. The number of replicators grows very quickly in a short time. Then most of them die and form a new material wave. This phenomenon can be seen in the video.





The replicator resulting from evolution after 70 million time steps is shown below. The video shows how you will spread in a "friendly" universe. An interesting behavior that can be observed in simulations is that many of these replicators do not actually replicate, while only a few of them produce many descendants. This can be beneficial if many of them compete for limited resources.





image



evolved small replicator



2.2.2. Large replicators





The evolution of this larger type of replicator follows a slightly different pattern. On the one hand, its larger structure offers more opportunities for optimization and therefore adaptation to new conditions. On the other hand, the replication process takes more time and energy. As a consequence, the development of periodic material waves occurred in a much weaker form, because the replicator was not fast enough to capture the material.



Below you can find the evolution product after 82 million time steps and a video showing its creation. The replicator moves very abruptly and sometimes suicidal. Such aggressive behavior seems to be beneficial in universes with scarce resources. Its structure has evolved but is still relatively close to its original configuration. You may also notice that its structure and function have not changed much in later times. Compared to the beginning, a lot more tokens rotate on its cells, which leads to faster activity.





image



evolved large replicator



2.2.3. Complex replicators



The largest version of the original replicator creates smaller structures in fairly short periods of time. As for the large variation above, there is more freedom to optimize and more complex behavior patterns can be observed compared to the small initial replicator. This fact also affects the general structures of the Universe. There is a wider variety of clusters of different sizes. Also, there are no periodic material waves. Instead, there is more chaotic movement and local congestion of replicator machines. You can see this phenomenon in the video below.





Such conditions may be more suitable for evolution towards higher complexity. In the simulation, after 26 million time steps, a completely new structure emerged. It attracts attention with its massive interior workmanship. It is like a growing crystal structure without active movement or energy consumption. Childbirth occurs by the destruction of the structure due to physical influences. The pieces can grow again. An enlarged image of this amazing evolutionary product is shown at the bottom right.





crystalline structure



This exotic creature coexists with other advanced replicators. An example of such a replicator is shown below, along with a video showing its distribution.





image



evolved complex replicator



4. Conclusions



All three types of replicators undergo the greatest changes in the first million time steps due to mutation and natural selection. The higher complexity of the initial configuration offers more opportunities for optimization. However, once environmental conditions (parameters for modeling and measuring the universe) are fixed, evolutionary adaptation slows down. Even silent mutations cannot survive in a population.



All types of original replicators evolve into variants that reproduce and consume resources much faster. The most complex structural start-ups also develop more complex behaviors.



An unexpected product was the emergence of crystalline structures that can grow, but do not have the functions of active movement, energy consumption and replication. They reproduce themselves, decaying under the influence of external factors. The parts are mostly still functional.



Case Two: Information-Driven Replication



1. Initial replicator



The main subject of this study is a self-replicating machine using a digital analogue of DNA. Compared to self-checking replicators, child construction commands are stored in the data container as pure information. Thanks to this approach, we gain more flexibility in creating new machines, since they arise from the manipulation of information.



Let's start our experiment with a loop structure that performs all the necessary operations in one main loop. The build instructions are encoded in the memory of a token that spins in a circular structure. In addition, to obtain the necessary energy, some random movements and attacks on neighboring cells are made.



In the pictures below, we can see snapshots in the process of replication. As long as the replicator has enough power, it produces new cells, the building instructions for which are described in the token data section. Each time a token passes through a computer cell, the assembly instructions are copied byte by byte into its target field. This can take up to 45 turns around the structure. After the process of copying from memory is completed, the creation of a daughter cell begins, which is repeated if there is not enough energy available. The constructor receives instructions from the token and gradually builds all 6 cells. After building the last cell, the token will be duplicated and the copy will be propagated to the offspring. During this process, a mutation is applied to the token's memory. In addition, the construction site is divided into two individuals.



After many replication cycles, the number of offspring grows exponentially, provided sufficient nutrients are available in the form of surrounding cells or energy particles. Replicating structures after several reproduction cycles are visible on the right. Due to the applied mutation, some of them may have different properties, which in most cases leads to some malfunctions.



image



information-based replicator



2. Evolutionary experiment



2.1. Setting



For our evolutionary experiment, we created a simulation with the following settings:



  • initial size of the universe: 1000 x 1000 units
  • 5000 randomly distributed rectangular clusters of 8x4 cells every 100 energy units
  • 20 replicators


The full initial configuration can be downloaded here .



2.2. Simulation

During simulation, we gradually increase the size of the universe to 6000 x 1000 units. The universe is then scaled to 60,000 x 1,000 units, resulting in a 10-fold increase in energy. The number of replicators grows exponentially and stabilizes at the level of 80 to 90 thousand copies. At this point, the number can be read on active clusters on the monitor. The results below cannot be replicated directly as all simulations are different. However, some general effects can be observed.



Over time, you can see that dense colonies of replicators can coalesce over time. Because in the current conditions it is beneficial for replicators to develop lazy behaviors that do not make any movements and massively attack their environment. To prevent such a convenient survival pattern arising, we can change the environmental conditions. To this end, we punish the cell attack by increasing the parameters of the simulation function -> weapon -> energy cost. We do not increase its value to 3 immediately, but gradually after 100 thousand time steps, so that replicators can adapt to new conditions.



When the universe is filled with replicators, the density of the material can vary greatly from region to region. Because the moving replicators create forces that push away the remaining material. This phenomenon can be seen in the following screenshot taken 2 million time steps apart.



image



Bright spots are visible in the center of the area. These are thousands of replicators. Over time, they mutated, and some of them took on a different color. On the left and right, you can see mostly blue - sparsely distributed leftover material. This screenshot shows only a tiny fraction of the entire universe. In our test system, the simulation runs at approximately 20 steps per second.



Below you can see an excerpt from the same simulation across 7 million time steps. Replicators have mutated and can multiply faster in their environment.



image



After 59 million time steps and a change in the rate of mutations from low to high and vice versa, the dynamics of the simulated universe changed with the emergence of new types of structures. Their behavior is very different from that of the original replicators. At first glance, they appear to be malfunctioning mutants. But what is most interesting, they grow and disintegrate into pieces that can grow on their own.



It seems that a new type of artificial lifestyle has emerged that could not have been imagined in the original conditions. In the following screenshots, we represent sections of the universe after 61 million time steps. The simulation file for this time step can be downloaded here .



image



The white crystalline structure in the center looks quite noticeable. Its color is the result of many circulating tokens. In the editor, we can observe more detailed information about this structure.



image



Upon further enlargement, we find that this structure basically consists of two types of cells that are repeated in spatial patterns: a computer cell and a design cell. Almost every cell has three tokens containing data for the build process. As soon as enough energy is available in some part of the structure, it grows in an orthogonal direction.



image



The structure can be downloaded here .



4. Conclusions



Through this experiment, we could observe the emergence of growing crystal structures. The same phenomenon was observed for self-inspecting replicators. Moreover, they were stable, spread throughout the universe and became the dominant species. From this we can conclude that such forms of self-reproduction are not so rare and can occur in various situations.



There were no significant differences in the development of information copying machines compared to self-checking machines in this experiment. The hypothesis that such machines can better adapt to their environment and are more suited to unlimited evolution needs to be explored in more extensive experiments.



In addition, it turns out that the following extensions should be considered for further experimentation:



  • automatic change of modeling parameters so that the population does not become extinct,
  • reward larger replicator structures.


Extras: Artworks



All of the screencasts that follow show real-time simulations recorded on a GeForce 2080 TI system. It is recommended to watch videos in 1080p (HD) quality. More videos can be found on the YouTube channel .



Physics engine capabilities











Artificially programmed matter











Constructions on the built-in graphic editor








All Articles