Combinatory Chemistry: Towards a Simple Model of Emergent Evolution

by   Germàn Kruszewski, et al.

Researching the conditions for the emergence of life – not necessarily as it is, but as it could be – is one of the main goals of Artificial Life. Answering this question requires a model that can first explain the emergence of evolvable units, namely, structures that (1) preserve themselves in time (2) self-reproduce and (3) can tolerate a certain amount of variation when reproducing. To tackle this challenge, here we introduce Combinatory Chemistry, an Algorithmic Artificial Chemistry based on a simple computational paradigm named Combinatory Logic. The dynamics of this system comprise very few rules, it is initialized with an elementary tabula rasa state, and features conservation laws replicating natural resource constraints. Our experiments show that a single run of this dynamical system discovers a wide range of emergent patterns with no external intervention. All these structures rely on acquiring basic constituents from the environment and decomposing them in a process that is remarkably similar to biological metabolisms. These patterns involve autopoietic structures that maintain their organisation, recursive ones that grow in linear chains or binary-branching trees, and most notably, patterns able to reproduce themselves, duplicating their number at each generation.


page 1

page 2

page 3

page 4


Emergence of self-reproducing metabolisms as recursive algorithms in an Artificial Chemistry

Researching the conditions for the emergence of life – not necessarily a...

Formal Definitions of Unbounded Evolution and Innovation Reveal Universal Mechanisms for Open-Ended Evolution in Dynamical Systems

Open-ended evolution (OEE) is relevant to a variety of biological, artif...

Emergence-focused design in complex system simulation

Emergence is a phenomenon taken for granted in science but also still no...

Lenia - Biology of Artificial Life

We report a new model of artificial life called Lenia (from Latin lenis ...

Composition Machines: Programming Self-Organising Software Models for the Emergence of Sequential Program Spaces

We are entering a new era in which software systems are becoming more an...

Procedural Wang Tile Algorithm for Stochastic Wall Patterns

The game and movie industries always face the challenge of reproducing m...

1 Introduction

Figure 1: Metabolic cycle (showing one of the possible pathways) of the self-reproducing structure , where . It takes three copies of from its environment, using two to create a copy of itself, and metabolises the third one to carry out the process. It autonomously emerges from the dynamics of Combinatory Chemistry.

Finding the minimal set of conditions that lead to open-ended evolution in a complex system is a central question in Artificial Life, and a fundamental question of science in general. The main driving hypothesis in this line of research is that living systems emerge from the complex interaction of simple components. Environments like Avida (Ofria and Wilke, 2004) or Tierra (Ray, 1991) have been used to explore this question by allowing self-reproducing programs to mutate and evolve in time. Yet, the reproductive and mutation mechanisms, as well as the organisms’ capacity to tolerate such mutations, depend on the hand-coded design of the human engineers. Instead, Artificial Chemistries try to uncover how such evolvable units emerge in the first place by simulating the properties of natural chemical systems at different levels of abstraction (see Dittrich et al. (2001) for a thorough review). It has been hypothesized that they emerge thanks to self-organising chemical networks forming attractors that preserve their structure in time (Walker and Ashby, 1966; Wuensche et al., 1992; Kauffman, 1993). While some Artificial Chemistries study these questions by mimicking as closely as possible the properties of the chemistry that gave rise to life on Earth (Flamm et al., 2010; Högerl, 2010; Young and Neshatian, 2013), others abstract away from the particularities of natural chemistries to focus only on their hypothesized core computational properties (Fontana and Buss, 1994; di Fenizio and Banzhaf, 2000; Tominaga et al., 2007; Buliga and Kauffman, 2014). In line with this latter line of work, in this paper we introduce an Algorithmic Artificial Chemistry based on Combinatory Logic (Schönfinkel, 1924; Curry et al., 1958) featuring a minimalistic design and three key properties. First, it is Turing-complete, enabling it to express an arbitrary degree of complexity. Second, it is strongly constructive, meaning that as the complex system evolves in time it can create new components that can in turn modify its global dynamics. Third, it features intrinsic conservation laws, which limit the total size of the system to the experimenter’s wish. Limiting the size of the system is important from both practical and theoretical reasons. On one hand, to simulate the system in a computer it is necessary to bound its size so that the simulation does not become too large to be efficiently computed. On the other hand, constraining the amount of total resources can create selective pressures that can later drive an evolutionary process with intrinsic emergent fitness. Previous work has relied on applying extrinsic conservation laws, such as for instance keeping a maximum number of total elements in the system by randomly removing exceeding ones (Fontana and Buss, 1994; di Fenizio and Banzhaf, 2000). Here, instead, we propose dynamics that, like natural chemical systems, are intrinsically conservative, so that the number of total elements in the system remains constant throughout its evolution.

We simulate a Chemical Reaction System  (Hordijk et al., 2015; Dittrich et al., 2001) based on Combinatory Logic, which starting from a tabula rasa state with only elementary components, it produces a diversity explosion that develops into a state dominated by self-organized emergent structures, including autopoietic (Varela and Maturana, 1973), recursive and self-replicating ones. Notably, all these types of structures emerge at different points in time during a single run of the system, without requiring any external interventions. These structures preserve themselves by absorbing compounds from their environment and decomposing them step-by-step, in a process that has a striking resemblance with the metabolism of biological organisms. Importantly, we also introduce a technique that allows us to emulate the effects of having larger systems without having to compute them explicitly. This makes considerably more efficient the search for these complex structures.

The paper is organized as follows. First, we describe earlier work in Artificial Chemistry that is most related to our approach. Then, we explain the basic workings of Combinatory Logic and how we adapted it into an Artificial Chemistry. Third, following earlier work, we discuss how autocatalytic sets can be used to detect emerging phenomena in this system, and propose a novel measure of emergent complexity that are well-adapted to the introduced system. Finally, we describe our experiments that showcase the emergence of complex structures in Combinatory Chemistry.

2 Artificial Chemistries

Artificial Chemistries (AC) are models inspired in natural chemical systems that are usually defined by three different components: a set of possible molecules, a set of reactions, and a reactor algorithm describing the reaction vessel and how molecules interact through the available reactions to let the system evolve over time (Dittrich et al., 2001). In the following discussion we will focus on algorithmic chemistries that are the closest to the present work.

AlChemy (Fontana and Buss, 1994) is an AC where molecules are given by -calculus expressions.

-calculus is a mathematical formalism that, like Turing machines, can describe any computable function. (This is the Church-Turing thesis.) In AlChemy, pairs of randomly sampled expressions are joined through function application, and the corresponding result is added back to the population. To keep the population size bounded, expressions are randomly discarded. Fontana and Buss showed that system expressions that computed themselves quickly emerged in this system, which they called level 0 organisations. Furthermore, when these expressions were explicitly prohibited, a more complex organization emerged where where every expression in a set was computed by other expressions within the same set (level 1 organisations). Finally, mixing level 1 organisations could lead to higher order interactions between them (level 2 organisations). Yet, several ad-hoc conditions had to be introduced. First, each level of organisation was reached through external intervention. Also, programs that do not reach a normal form, that is, that can continue to be rewritten through the application of

-calculus rules are banned from the system, preventing recursive programs to emerge. Furthermore, expressions which after being combined with existing expressions cannot be reduced are also banned. On the other hand, when expressions are combined, they are not removed from the system, allowing the system to temporarily grow in size. If these conditions are not met, complex organisations fail to emerge. The authors link these last two conditions with the natural analogues of food and waste. Yet, it is not clear under which circumstances these external interventions would not be needed anymore, so that the system can evolve autonomously. Finally, the fact that the total number of expressions has to be kept bounded by randomly removing exceeding ones adds an external source of perturbations to the system that can affect the dynamics in unknown ways.

In this work, we propose an AC based on Combinatory Logic. This formalism has been explored before in the context of AC by di Fenizio and Banzhaf (2000). While this work shares with us the enforcement of conservation laws, it relies for it on a normalisation process that introduces noise into the system dynamics. Furthermore, as AlChemy, it reduces expressions until they reach their normal forms, explicitly forbidding recursive and other type of expressions that do not converge.

Finally, Chemlambda (Buliga and Kauffman, 2014) is a Turing-complete graph rewriting AC that allows the encoding of -calculus and combinatory logic operators. As such, it is complementary in many ways with the system proposed here. Yet, while both Chemlambda and our system can express similar constructions, we are not aware of any reactor algorithm proposed for Chemlambda, nor about explorations of emerging phenomena with this formalism.

3 Combinatory Logic

Combinatory Logic (CL) is a minimalistic computational system that was independently invented by Moses Schönfinkel, John Von Neumann and Haskell Curry (Cardone and Hindley, 2006). Other than its relevance to computability theory, it has also been applied in Cognitive Science as a model for a Language of Thought (Piantadosi, 2016). One of the main advantages of CL is its formal simplicity while capturing Turing-complete expressiveness. In contrast to other mathematical formalisms, such as -calculus, it dispenses with the notion of variables and all the necessary bookkeeping that comes with it. For instance, a function would be nonsensical, and a system relying on -calculus for searching in the space of possible programs would need to have explicit rules to avoid the formation of such expressions. Instead, CL expressions are built by composing elementary operators called combinators. Here, we restrict to the , and combinators, which form a Turing-complete basis111As a matter of fact, and suffice because can be written as . The inclusion of simply allows to express more complex programs with shorter expressions, and follow these rewriting rules:

An expression that contains a term of the form given in the left hand side of the rules above is called a “reducible expression” or redex. Otherwise, it is said to be in normal form. The application of these rules to any redex within an expression is called a (weak) reduction. For example, the expression could be reduced as follows (underlining the corresponding redexes being rewritten): . Thus, this expression reduces to itself. We will later see that expressions such as this one will be important for the self-organizing behaviour of the system introduced here. Also note that has two redexes that can be rewritten, namely, the outermost or the innermost identity combinators . Even though many different evaluation order strategies have been defined (Pierce, 2002), here we opt for picking a redex at random222For practical efficiency reasons, we restrict to sampling from the first 100 possible reductions in an outer-to-inner order., both because this is more natural for a chemical system and to avoid limitations that would come from following a fixed deterministic evaluation order.

4 Combinatory Chemistry

One of our main contributions deals with reformulating these reduction rules as reactions in a chemical system. For this we postulate the existence of a multiset of CL expressions . Note that if we were to apply plain CL rules to these expressions, the total number of combinators in the system would not be preserved: On one hand, the application of a reduction rule always removes the combinator from the resulting expression. On the other hand, while some a combinator like discards a part of the expression (the argument ), the combinator duplicates its third argument . Thus, to make a chemical system with conservative laws, we define the following reduce reactions:


The plus symbol denotes a separation between different expressions. An expression in Combinatory Chemistry is said to be reducible if it contains a Combinatory Chemistry redex (CC-redex). A CC-redex is a plain CL redex, except when it involves the reduction of an combinator, in which case a copy of its third argument must also be present in the multiset for it to be a redex in Combinatory Chemistry. For example, the expression is reducible if and only if the third argument of the combinator , namely , is also present in the set. When a reduction operation is applied, the redex is rewritten following the rules of combinatory logic, removing any substrate from and adding back to it all by-products, as specified in brackets on the right hand size of the reaction. For instance, reducing removes these two elements from , adding back and to it. Notably, each of these reduction rules preserves the total number of combinators in the multiset, intrinsically enforcing conservation laws in this chemistry. It is also worth noticing that each of these combinators play different roles in the creation of novel compounds. While the combinator splits an expression, reducing its total size and complexity, the combinator is the only one that creates a novel, larger, and possibly more complex expression from smaller parts.

Completing the set of possible reactions in this chemistry, condensations and cleaveges can generate novel expressions through random recombination:


While other chemistries start from a population of randomly constructed compounds, this system is initialised with elementary combinators only. In this way, diversity materializes only as emergent property rather than through the product of an external intervention. Then, at each step, an expression from

is randomly sampled (in proportion to their corresponding concentrations). If the expression is reducible, then a redex is chosen at random, and the expression replaced with the result of applying the reduction operation. At the same time, any required substrates are removed from the multiset, while any resulting by-products are added back into it. By applying one reduction at a time, we uniformly distribute the computational budget between all programs living in the system. Therefore, if complex structures emerge, more efficient ones will have a selective advantage. Furthermore, we do not need to take additional precautions to avoid infinitely reducing expressions that never reach a normal form, allowing more interesting functions to form part of our system’s dynamics. The complete algorithm describing the temporal evolution of our system is summarized on Algorithm

1333We make available our implementation at

Input: Total number of combinators , ,
Initialize multiset while True do
      Let if IsReducible() then
           Let Remove one from Remove one substrate from (if applies) Add one and all by-products to
                Randomly pick cleave or condense if cleave then
                     Remove one from Add one and one to
                     else if  is set then
                          Remove one and one from Add to
                               Set ;
                               Function IsReducible():
                                    if  or or
                                    and  then
                                         return True
                                         else if  then
                                              return False
                                                   return any IsReducible() :
Algorithm 1 Reactor Algorithm

5 Autocatalytic Sets

Emergent order by self-organization in complex systems is hypothesized to be driven by the existence of attracting states in the system’s dynamics (Walker and Ashby, 1966; Wuensche et al., 1992; Kauffman, 1993). Autocatalytic Sets (Kauffman, 1993) were first introduced by Stuart Kauffman in 1971 as one type of such attractors that could help explaining the emergence of life in chemical networks444See Hordijk (2019) for a comprehensive historical review on the topic.. Similar ideas were introduced before with the concepts of autopoiesis (Varela and Maturana, 1973), and the hypercycle model (Eigen and Schuster, 1978). Autocatalytic Sets (AS) are reaction networks that self-perpetuate in time by relying on a network of catalysed reactions, where every substrate and catalyser of a reaction is produced by at least some reaction in the network, or they are freely available components in the environment. This notion was later formalized in a mathematical form (Hordijk and Steel, 2004; Hordijk et al., 2015) into the concept of Reflexively Autocatalytic Food-generated sets (RAFs). A Chemical Reaction System (CRS) is a mathematical construct defining the set of possible molecules, the set of possible reactions and a catalysis set indicating which reactions are catalysed by which molecules. Furthermore, it assumed to exist a set of molecules freely available in the environment called the “food set”. An autocatalytic set (or RAF set) of a CRS with associated food set is a subset of reactions, which is:

  1. reflexively autocatalytic (RA): each reaction is catalysed by at least one molecule that is either present in or can be formed from by using a series of reactions in itself.

  2. food-generated (F): each reactant of each reaction in is either present in or can be formed by using a series of reactions from itself.

In our system, all reducing reactions take precedence over random condensations and cleavages without the need of any catalyser. Thus, they are all reflexively autocatalytic (automatically satisfying condition 1), and autocatalytic sets are defined only in terms of reaction subsets that satisfy condition 2: That is, those reaction subsets in which every reactant is formed by a reaction in the set or is freely available in the environment. Because of the dynamics of Combinatory Chemistry, the most common expressions are elementary combinators, which can be randomly combined through random condensations to form longer expressions. Yet, the longer the expression, the exponentially larger systems are required for them to be just as common. To by-pass this latter obstacle, we propose the substrate assemblage mechanism, introduced in the following section.

For example, Figure 2 shows a simple emergent autocatalytic set associated with the expression , if belongs to the food set. As shown, when the formula is first reduced on reaction , a substrate is absorbed from the environment. Next, the combinators in this substrate are applied and realised back into the multiset , returning back to the same original expression. We refer to this process as a metabolic cycle because of its strong resemblance to its natural counterpart. For convenience, we write this cycle as , where is a function that returns the atomic combinators in and the double head arrow means that there exists a pathway of reduction reactions from the reactives in the left hand size to the products in the right hand size.

Figure 2: form an autocatalytic set, granted that belongs to the food set. metabolic cycle starts with applying the reduction rule, and taking as substrate. Then, the cycle is completed by the reduction of the two identity combinators, in any of the possible orders.

6 Substrate assemblage

As argued above, freely available expressions can be generated by random condensation of simpler components. However, longer substrates come in smaller concentrations, and thus considerably larger systems should be simulated for them to arise in large numbers. This makes the experimental process considerably inefficient, particularly for allowing the emergence of complex structures that depend on such substrates. Here, we introduce a technique that we call substrate assemblage to facilitate the exploration of larger systems without needing to simulate them in full. The central idea is to arbitrarily define a food set containing the expressions that would be freely available had the system been sufficiently large and evolved for long enough. Then, whenever the system needs to reduce an combinator involving a substrate that is not available in the multiset, but is part of this predefined food set, the substrate would be constructed on the spot from freely available atomic combinators. In this way, we can can simulate the productivity of sufficiently large environments, without explicitly needing to compute them. On the other hand, this technique does not bypasses the need of discovering the main reagent, namely, the expression being reduced. Instead, it just focuses on creating the required substrates. Furthermore, as the total number of combinators in the system is limited, ceiling effects can be observed if the number of freely available atoms start to dwindle. Even with these concerns in mind, we experimentally show that there are considerable gains in terms of emergent complexity by applying this technique. Therefore, Algorithm 1 is modified at the point of sampling a reduction by the steps in Algorithm 2.

Input: Maximum substrate size
Let if  and  then
      Let if  and and  then
           Remove from Remove from Remove from Add one to
Algorithm 2 Substrate assemblage

7 Autopoiesis, recursion and self-reproduction

While autocatalytic sets provide a compelling formalism to study emergent organization in Artificial Chemistries, it leaves some blind spots for detecting emergent structures of interest. Such is the case for recursive expressions. Consider, for instance, . This expression is composed of two copies of applied to itself . As shown in Figure 3, its metabolic cycle will use two copies of the element , metabolising one to perform its computation, and appending the other one to itself, thus . As time proceeds, the same computation will take place recursively, thus , and so on. While this particular behaviour cannot be detected through autocatalytic set, because the resulting expression is not exactly equal to the original one, it still involves a structure that preserves in time its functionality.

Figure 3: One of the possible pathways in the reduction of the tail-recursive structure with . It appends one to itself by metabolising another copy absorbed from the environment.

Moreover, while the concept of autocatalytic set captures both patterns that perpetuate themselves in time and patterns that in addition, they also multiply their numbers, it does not explicitly differentiate between them. A pattern with a metabolic cycle of the form (as in Figure 2) keeps its own structure in time by metabolising one in the food set, but it does not self-reproduce. We call such patterns simple autopoietic (Varela and Maturana, 1973). In contrast, for a pattern to be self-reproducing it must create copies of itself that are later released as new expressions in the environment. For instance, consider a metabolic cycle in Figure 1 with the form . This structure creates a copy of itself from 2 freely available units of and metabolises a third one to carry out the process.

All these structures have in common the need to absorb food expressions from the environment to preserve themselves in homoeostasis. Furthermore, because they follow a cyclical process, the types of food expressions upon which they rely will always be the same. Thus, we propose substrate counting as a metric that can capture all these different types of structures. For this, we note that the only operation that allows an expression to incorporate some other expression into its own body is the reduction of the combinator. Therefore, counting the number of times each substrate has been used in a reaction can serve as a proxy for detecting the existence of a structure relying on this element for food.

8 Experiments and Discussion

(a) Diversity
(b) Mean expressions length
(c) Reductions
Figure 4: System metrics for different values of substrate assemblage size .

We simulated a CRS based on Combinatory Logic for M iterations, starting from just k evenly distributed , , and combinators. We applied substrate assemblage with substrate size parameter on a range between (corresponding to no substrate assemblage) and , repeating the process times with different random seeds for each configuration.

We began by analysing general metrics of the system. Figure 3(a) shows the expression diversity as a function of the number of performed reactions. As it can be seen, diversity explodes in the first few k reactions, before reaching a peak of about expressions. Then, it starts to decline at different speeds, depending on the value of the substrate assemblage parameter . When this mechanism is disabled (), the decline occurs at a slow and steady rate. Yet, when this parameter reaches the value , the decline of diversity becomes much faster, only accelerating after that. This difference could be explained by the fact that reduction expressions involving combinators, the only ones that compute increasingly longer expressions, are more likely to be successful thanks to the substrate assemblage mechanism getting into action. Therefore, the limited available combinators tend to be clustered in fewer and longer expressions, as confirmed by Figure 3(b). On the other hand, as the number of freely available combinators needed to assemble the substrates becomes scarce, the corresponding reduction operations cannot be executed, and more random operations start to take place instead (Figure 3(c)). Thus, the system self-regulates the ratio of deterministic operations –as given by reductions– to stochastic ones –as given by random condensations or clevages– occurring in it.

(f) Combinator population in the simulation of Fig. (c)
Figure 5: (a-e) Substrate consumption computed over a window of k reactions on different runs with different substrate assemblage sizes . Different line styles distinguish substrates used by different types of expressions: Dotted lines represent substrates used by simple non-attracting expressions; Dash-dotted lines are substrates used by simple autopoietic patterns; Dashed lines are substrates used by recursive patterns; Solid lines are substrates used by self-reproducing patterns.

Yet, it is unclear from these results whether the reduction in diversity is driven by emergent complex structures that act as attractors, or some other different reason. To answer this question, we used substrate counting (see above) to detect whether specific substrates where more prominently used, possibly hinting at the existence of expressions that were metabolising them to preserve themselves in time. In particular, we looked at the 10 most frequently used substrates, from which we are selecting a few to simplify the presentation. Results are shown in Figure 5 for five different runs. In each of these, we can see the emergence of different types of structures, including simple autopoietic patterns, recursive structures, and self-reproducing ones. Interestingly, they can emerge at different points in time, co-exist, and sometimes some of them can drive others to extinction.

Notably, we observed that expressions that consume any given substrate are typically composed of multiple juxtaposed copies of this substrate, confirming the old adage: “Tell me what you eat and I will tell you what you are”. For instance, in Figure 4(a) we can appreciate the emergence of the autopoietic pattern , composed of two copies of the substrate , and a metabolic cycle of the form , as shown on Figure 2. Binary substrates such as and unitary ones such as do not form part of any self-preserving structure. Instead, they are only used in the reduction of randomly or semi-randomly produced expressions. Yet, they are used with considerable frequency as any randomly-produced redexes featuring an combinator will likely take shorter arguments because of them being more frequent. As unitary substrates are more frequent than binary ones, their consumption levels are also considerably higher. Yet, even though by the same argument the consumption rate of should be below binary substrates, self-organization into autopoietic patterns drives the usage of this substrate above what would be expected if chance would be the only force at play. At around 2M-3M reactions, the system reaches a point in which the consumption levels of this substrate stabilizes, constrained by free the availability of the substrate: For the consumption levels to increase here, structures need to be formed by chance by the collision of two substrate copies, and also kept alive by metabolising freely available substrates. When we start assembling substrates of size at most (Figure 4(b)), we facilitate this second restriction to the extent that and combinators are freely available in the environment, thus allowing the formation of an even larger number of structures. At the same time, rarer autopoietic structures can emerge in this conditions, such as one based on three juxtaposed copies of . This expression has a metabolic cycle of the form (details in Appendix), meaning that it acquires two copies of the substrate from the environment, metabolises one, and releases the other one back intact. We note that this last copy of could be construed as an emergent catalyser for the reaction: Even though we can interpret each reduce reaction to be auto-catalysed, multiple reactions taken together can have emergent properties, such as in this case, where a substrate is just used to complete the metabolic cycle, and then released.

From we start to see growing structures. In particular, recursive ones. In Figure 4(c) () we can observe two such structures. The first one uses the substrate , and follows a tail-recursive cycle that linearly increases the size of the structure: (as shown on Figure 3). The second one is a more complex binary-branching recursive structure, with substrate . In this case, follows a somewhat larger metabolic cycle that can end up in each copy of duplicating so that becomes (details in Appendix). When recursive structures come into play, we can see that simple autopoietic patterns are driven into extinction. These extinction events are related to the assemblage mechanism, as it puts recursive and autopoietic structures in direct competition for combinators. Figure 4(f) displays the amount of freely available combinators in this simulation. As shown, combinators are exhausted at around 3M reactions. At around this point the simple autopoietic structure around the substrate goes into a slow decline. Yet, when all freely available combinators are depleted, this structure is driven into a quick extinction: When resources start to dwindle, reductions that rely on a given substrate can fail, and thus the system falls back to either breaking up the expression or combining it with another one. When is broken into two independent elements it looses its ability to compute itself. In contrast, recursive structures can cope with conditions of low resources quite effectively, as demonstrated by the fact that they still continue to consume at stable rate their corresponding substrates after and combinators are not freely available anymore. A possible reason why this does not bring them into catastrophic failure is their fractal structure: A recursive structure broken up will still have the same function, but it will be smaller. For instance, still leaves a functioning structure. When new resources become available through the continuous influx of combinators released by every computed reduction, it can consume them and grow back again. In the future, to avoid such direct competition for basic resources between all emergent structures, the substrate assemblage could be limited, for instance, to be applied only when there is a minimum buffer of freely available combinators.

Finally, in Figures 4(d) and 4(e) we can observe the emergence of a full-fledged self-reproducing structure with substrate . It follows a cycle of the form , thus duplicating itself, and metabolising one substrate in the process. As it replicates exponentially, this structure quickly grows into one of the most active ones. Yet, when resources run out it enters in direct competition with the recursive structure based on the substrate. In 4(d) the substrate consumption rate for this last structure is considerably lower than in 4(e)

, probably due to the fact that the recursive structure

can either reduce the internal part, thus consuming one copy of , or at the most external level, consuming , which in this case it is facilitated by substrate assemblage when . On the other hand, the self-reproducing pattern suffers from the same problem of simple autopoietic structures: When it fails to acquire its substrate from the environment it decomposes into an expression that looses its functionality. However, in contrast with simple autopoietic patterns that rely on being produced by chance, self-reproducing ones can recover their population through reproduction. Nevertheless, the recursive structure still keeps an advantage over the self-reproducing one, especially when , where it quickly drives the self-reproducing pattern into extinction.

9 Conclusions

We have introduced Combinatory Chemistry, an Algorithmic Artificial Chemistry based on Combinatory Logic. Even though it has simple dynamics, it gives rise to a wide range of complex structures, including recursive and self-reproducing ones. Thanks to Combinatory Logic being Turing-complete, our system can theoretically represent patterns of arbitrary complexity. Furthermore, the computation is distributed uniformly across the system thanks to single-step reactions applied at each iteration. As a consequence, emergent structures feature reaction cycles that bear a striking resemblance to natural metabolisms. Moreover, conservation laws keep the system bounded while not introducing any extrinsic source of noise. Finally, our system does not need to start from a random set of initial expressions to kick-start diversity. Instead, this initial diversity is the product of the system’s own dynamics, as it is only initialized with elementary combinators. In this way, we can expect that this first burst of diversity is not just a one-off event, but it is deeply embedded into the mechanics of the system, possibly allowing it to keep on developing novel structures continually. On the other hand, we observed that to keep complex structures functioning, they require a constant influx of specific types of substrates. While only much larger systems would allow for such continual production of these food elements, we bypassed the problem of needing simulate such larger systems by constructing the required substrates on the spot when they were needed. In these way, we have successfully simulated systems where we could observe a large variety of emerging structures, including structures that would self-sustain, but without changing their number (simple autopoietic); recursive expressions that would keep growing until reaching the system’s limit; and self-reproducing patterns that increase their number exponentially. To conclude, we have introduced a simple model of emergent complexity in which self-reproduction emerges autonomously from the system dynamics. It is still to be seen whether this can be used to explain the emergence of evolvability, one of the central questions in Artificial Life. Yet, we believe that the simplicity of our model, the encouraging results, and its dynamics that balance computation with random recombination to creatively search for new forms, leaves it in good standing to tackle this challenge.

10 Acknowledgements

We would like to especially thank Alessandra Macillo for the idea behind substrate assemblage and feedback, Sebastian Riedel for his invaluable support and feedback, and the rest of FAIR London team and the Complexity Interest Group for all the feedback and interesting discussions.


  • M. Buliga and L. Kauffman (2014) Chemlambda, universality and self-multiplication. In Artificial Life Conference Proceedings 14, pp. 490–497. Cited by: §1, §2.
  • F. Cardone and J. R. Hindley (2006) History of lambda-calculus and combinatory logic. Handbook of the History of Logic 5, pp. 723–817. Cited by: §3.
  • H. B. Curry, R. Feys, W. Craig, J. R. Hindley, and J. P. Seldin (1958) Combinatory logic. Vol. 1, North-Holland Amsterdam. Cited by: §1.
  • P. S. di Fenizio and W. Banzhaf (2000) A less abstract artificial chemistry. Artificial Life 7, pp. 49–53. Cited by: §1, §2.
  • P. Dittrich, J. Ziegler, and W. Banzhaf (2001) Artificial Chemistries-A Review. Articial Life 7, pp. 225–275. Cited by: §1, §1, §2.
  • M. Eigen and P. Schuster (1978) The hypercycle. Naturwissenschaften 65 (1), pp. 7–41. Cited by: §5.
  • C. Flamm, A. Ullrich, H. Ekker, M. Mann, D. Högerl, M. Rohrschneider, S. Sauer, G. Scheuermann, K. Klemm, I. L. Hofacker, et al. (2010) Evolution of metabolic networks: a computational frame-work. Journal of Systems Chemistry 1 (1), pp. 4. Cited by: §1.
  • W. Fontana and L. W. Buss (1994) What would be conserved if ’the tape were played twice’?. Proceedings of the National Academy of Sciences of the United States of America 91 (2), pp. 757–761. Cited by: §1, §2.
  • D. Högerl (2010) Simulation of prebiotic chemistries. Master’s Thesis, Institute for Theo- retical Chemistry, University of Vienna. Cited by: §1.
  • W. Hordijk, J. I. Smith, and M. Steel (2015) Algorithms for detecting and analysing autocatalytic sets. Algorithms for Molecular Biology 10 (1), pp. 15. Cited by: §1, §5.
  • W. Hordijk and M. Steel (2004) Detecting autocatalytic, self-sustaining sets in chemical reaction systems. Journal of theoretical biology 227 (4), pp. 451–461. Cited by: §5.
  • W. Hordijk (2019) A history of autocatalytic sets. Biological Theory 14 (4), pp. 224–246. Cited by: footnote 4.
  • S. A. Kauffman (1993) The origins of order: self-organization and selection in evolution. Oxford University Press, USA. Cited by: §1, §5.
  • C. Ofria and C. O. Wilke (2004) Avida: a software platform for research in computational evolutionary biology. Artificial life 10 (2), pp. 191–229. Cited by: §1.
  • S. T. Piantadosi (2016) The computational origin of representation and conceptual change. (under review). External Links: Link Cited by: §3.
  • B. C. Pierce (2002) Types and programming languages. MIT press. Cited by: §3.
  • T. S. Ray (1991) An approach to the synthesis of life. Artificial life II, pp. 371–408. Cited by: §1.
  • M. Schönfinkel (1924) Über die bausteine der mathematischen logik. Mathematische annalen 92 (3), pp. 305–316. Cited by: §1.
  • K. Tominaga, T. Watanabe, K. Kobayashi, M. Nakamura, K. Kishi, and M. Kazuno (2007) Modeling molecular computing systems by an artificial chemistry—its expressive power and application. Artificial Life 13 (3), pp. 223–247. Cited by: §1.
  • F. J. Varela and H. R. Maturana (1973) De máquinas y seres vivos: una teoría sobre la organización biológica. Santiago de Chile: Editorial Universitaria. Cited by: §1, §5, §7.
  • C. Walker and W. R. Ashby (1966) On temporal characteristics of behavior in certain complex systems. Kybernetik 3 (2), pp. 100–108. Cited by: §1, §5.
  • A. Wuensche, M. Lesser, and M. J. Lesser (1992) Global dynamics of cellular automata: an atlas of basin of attraction fields of one-dimensional cellular automata. Vol. 1, Andrew Wuensche. Cited by: §1, §5.
  • T. J. Young and K. Neshatian (2013) A constructive artificial chemistry to explore open-ended evolution. In

    Australasian Joint Conference on Artificial Intelligence

    pp. 228–233. Cited by: §1.

11 Appendix

The following derivations show one of the possible pathways that each of the described structures can undertake as they develop. They demonstrate how can these structures preserve their function in time. Note that every expression written as can also be written simply as . This “trick” is known as Uncurrying.

11.1 Metabolic cycle of a simple autopoietic pattern

Let . Then,

11.2 Metabolic cycle of a ternary autopoietic pattern

Let . Then,

11.3 Metabolic cycle of a tail recursive structure

Let . Then,

11.4 Metabolic cycle of a binary-branching structure

Let . Then can follow the metabolic pathway:

Then each copy of can be reduced as follows

Thus, the complete pathway can be summarized as .

11.5 Metabolic cycle of a self-reproducing expression