Tag Archives: artificial life

The life of a 10-nodes quine, short video

I’m working on an article on the 10-nodes quine (see here and here previous posts) and I have to prepare some figures, well rather js simulations of relevant phenomena.

I thought I’ll made a screencast for this work in progress and put it in the internet archive:

https://archive.org/details/the-life-of-a-10-nodes-quine

UPDATE: I found, by playing, an even more, apparently, assymetrical variant of chemlambda, but also I found a bug in the js version, which is, fortunately, not manifesting in any of the cases from the menu of this page.  For the moment is not completely clear for me if the more, apparently, assymetrical variant behaves so much better, when I reduce lambda terms, because of the bug. I think not. Will tell after I fix the thing. Is something unexpected, not in my current program, but exciting, at least because either way is beneficial: I found a bug or I found a bounty.

10-node quine can duplicate

Only recently I became aware that sometimes the 10-node quine duplicates. Here is a screenshot, at real speed, of one such duplication.

10-n0de-quine-duplicates

You can see for yourself by playing find-the-quine, either here or here.

Pick from the menu “10_nodes quine” or “original 10 nodes quine” (depending on where you play the game), then use “start”. When the quine dies just hit the “reload” button. From time to time you’ll see that it duplicates.  Most of times this quine is short lived, sometimes it lives long enough to make you want to hit “reload” before it dies.

 

 

Find the quine: who ordered this?

I put a version of the Find the Quine on github. You may help (and have fun) to find new chemlambda quines.

The page lets you generate random 10 nodes graphs (molecules), which are variants of a graph called “10_quine”. There are more than 9 billion different variants, therefore the space of all possibilities is vast.

Up to the moment 15 new quines candidates were found. You can see them in that page too.

New phenomena were discovered, to the point that now I believe that chemlambda quines are a dot in a sea of “who ordered this?”.

Who ordered this? Just look at “new quine? 3”.  “10 nodes quine 5”. It displays an amazing range of outcomes. One of them is that it dies fast, but other appear rather frequently. The graph just blooms not into a living creature, more like into a whole ecology.

You can see several interesting pieces there.

There is a “growing blue tip” which keeps the graph alive.

There are “red spiders” who try to reach for the growing blue tip and eat it. But the red spiders sometimes return to the rest of the graph and rearrange it. They live and die.

There is a “blue wave” which helps the growing blue tip by fattening it.

There is a “bones structure” which appears while the red spiders try to eat the growing blue tip. It looks like the bones structure is dead, except that sometimes the red spiders travel back and modify the bones into new structures.

And there are also graphs which clearly are not quines, but they are extremely sensitive to the order of rewrites. See for example “!quine, sensitive 1”. There seems to be a boundary between the small realm of quines and the rest of the graphs. “new quine? 3” is on one side of that boundary and “!quine, sensitive 1” is on the other side.

So, play “Find the Quine” and mail me if you find something interesting!

On top of the page there is a link to my pages to play and learn. Mind that the versions of find the quine there and at github are slightly different, because I update them all the time and so they are not synchronized. I use github in order to have a copy just in case. In some places I can update the github pages, in other places I can update my homepage…

 

 

Fold rewrite, dynamic DNA material and visual DSD

As it happened with chemlambda programs, I decided it is shorter to take a look myself at possible physical realizations of chemlambda than to wait for others, uninterested or very interested really, people.

Let me recall a banner I used two years ago

KeepCalmStudio.com-Shortest-Explanation-Of-Chemlambda-[Knitting-Crown]-Keep-Calm-And-Use-Rna-For-Interaction-Nets

It turns out that I know exactly how to do this. I contacted Andrew Phillips, in charge with Microsoft’ Visual DSD  with the message:

Dear Andrew,

I am interested in using Visual DSD to implement several graph-rewriting formalisms with strand graphs: Lafont Interaction Combinators, knots, spin braids and links rewrite systems, my chemlambda and emergent algebra formalisms.

AFAIK this has not been tried. Is this true? I suggest this in my project chemlambda but I don’t have the chemical expertise.

About me: geometer working with graph rewrite systems, homepage: http://imar.ro/~mbuliga/index.html or
https://mbuliga.github.io/

Some links (thank you for a short reception of the message reply):

Chemlambda:
– github project: https://github.com/chorasimilarity/chemlambda-gui/blob/gh-pages/dynamic/README.md
– page with more links: http://imar.ro/~mbuliga/chemlambda-v2.html
– arXiv version of my Molecular computers article https://arxiv.org/abs/1811.04960

Emergent algebras:
– em-convex https://arxiv.org/abs/1807.02058

 

I still wait for an answer, even if Microsoft’ Washington Microsoft Azure and Google Europe immediately loaded the pages I suggested in the mail.

Previously, I was noticed by somebody [if you want to be acknowledged then send me a message and I’ll update this] about Hamada and Luo Dynamic DNA material with emergent locomotion behavior powered by artificial metabolism  and I sent them the following message

Dear Professors Hamada and Luo,

I was notified about your excellent article Dynamic DNA material with emergent locomotion behavior powered by artificial metabolism, by colleagues familiar with my artificial chemistry chemlambda.

This message is to make you aware of it. I am a mathematician working with artificial chemistries and I look for ways to implement them in real chemistry. The shortest description of chemlambda is: an artificial chemistry where the chemical reactions are alike a Turing complete family of graph rewrites.

If such a way is possible then molecular computers would be not far away.

Here is a list of references about chemlambda:

– GitHub repository with the scripts https://github.com/chorasimilarity/chemlambda-gui/blob/gh-pages/dynamic/README.md
– page which collects most of the resources http://imar.ro/~mbuliga/chemlambda-v2.html

Thank you for letting me know if this has any relation to your interests. For my part I would be very thrilled if so.

Best regards,
Marius Buliga

Again, seems that these biology/chemistry people have problems with replies to mathematicians, but all ths makes me more happy because soon I’ll probably release instructions about how everybody could make molecular computers along the lines of Molecular computers.

I’ll let you know if there are future “inspiration” work. Unrelated to chemlambda, there are several academic works which shamelessly borrow from my open work without acknowledgements, I’ll let you know about these and I’ll react in more formal ways. I hope though this will not be the case with chemlambda, however, this happened before twice at least.  (I say nothing about enzymes/catalysts, category theory and cryptocurrencies… for the moment.)

Finally, here is a realization of the lambda calculus beta rewrite via a FOLD rewrite

arrowlink-2

which shares a relation with the ZIP rewrite from Zipper Logic. It seems I was close to reality,  now though I got it exactly 🙂 .

Let’s talk soon!

 

 

 

Lambda calculus inspires experiments with chemlambda

In the now deleted chemlambda collection I told several stories about how lambda calculus can bring inspiration for experiments with chemlambda. I select for this post a sequence of such experiments. For previous related posts here see this tag and this post.

Let’s go directly to the visuals.

Already in chemlambda v1 I remarked the interesting behaviour of the graph (or molecule) which is obtained from the lambda term of the predecessor applied to a Church number.  With the deterministic greedy algorithm of reductions, after the first stages of reduction there is a repeating pattern of  reduction, (almost) up to the end. The predecessor applied to the Church number molecule looks almost like a closed loop made of pairs A-FO (because that’s how a Church number appears in chemlambda), except a small region which contains the graph of the predecessor, or what it becomes after few rewrites.

In chemlambda v2 we have two kinds of fanouts: FO and FOE.  The end result of the reduction of the same molecule, under the same algorithm, is different: where in chemlambda v1 we had FO nodes (at the end of the reduction), now we have FOE nodes. Other wise there’s the same phenomenon.

Here is it, with black and white visuals

pred

Made by recording of this live (js) demo.

1. What happens if we start not from the initial graph, but from the graph after a short number of rewrites? We have just to cut the “out” root of the initial graph, and some nodes from it’s neighbourhood and glue back, so that we obtain a repeating pattern walking on a circular train track.

Here is it, this time with the random reduction algorithm:

bigpred_train-opt

I previously called this graph an “ouroboros”. Or a walker.

2. That is interesting, it looks like a creature (can keep it’s “presence”) which walks in a single direction in a 1-dimensional world.  What could be the mechanism?

Penrose comes to mind, so in the next animation I also use a short demonstration from a movie by Penrose.

bigpred_penrose-opt

 

3. Let’s go back to the lambda calculus side and recall that the algorithm for the translation of a lambda term to a chemlambda molecule is the same as the one from GLC, i.e the one from Section 3 here. There is a freedom in this algorithm, namely that trees of FO nodes can be rewired as we wish. From one side this is normal for GLC and chemlambda v1,  which have the CO-COMM and CO-ASSOC rewrites

convention_3

In chemlambda v2 we don’t have these rewrites at all, which means that in principle two diferent molecules,  obtained from the same lambda term, which differ only by the rewiring of the FO nodes may reduce differently.

In our case it would be interesting to see if the same is true for the FOE nodes as well. For example, remark that the closed loop, excepting the walker, is made by a tree of FOE nodes, a very simple one. What happens if we perturb this tree, say by permuting some of the leaves of the tree, i.e. by rewiring the connections between FOE and A nodes.

bigpred_train_perm-opt

The “creature” survives and now it walks in a world which is no longer 1 dimensional.

Let’s play more: two permutations, this time let’s not glue the ends of the loop:

bigpred_train_egg

It looks like a signal transduction from the first glob to the second. Can we make it more visible, say by making invisible the old nodes and visible the new ones? Also let’s fade the links by making them very large and almost transparent.

bigpred_train_egg_mist_blue

Signal transduction! (recall that we don’t have a proof that indeed two molecules from the same lambda term, but with rewired FO trees reduce to the same molecule, actually this is false! and true only for a class of lambda terms. The math of this is both fascinating and somehow useless, unless we either use chemlambda in practice or we build chemlambda-like molecular computers.)

4.  Another way to rewire the tree of FOE nodes is to transform it into another tree with the same leaves.

bigpred_tree-opt

 

5. Wait, if we understand how exactly this works, then we realize that we don’t really need this topology, it should also work for topologies like generalized Petersen graphs, for example for a dodecahedron.

dodecahedron_walker

 

This is a walker creature which walks in a dodecaheral “world”.

6. Can the creature eat? If we put something on it’s track, see if it eats it and if it modifies the track, while keeping it’s shape.

walker_bit-opt

So the creature seems to have a metabolism.

We can use this for remodeling the world of the creature. Look what happens after many passes of the creature:

walker_bit_new

 

7. What if we combine the “worlds” of two creatures, identical otherwise. Will they survive the encounter, will they interact or will they pass one through the other like solitons?

bigpred_bif

 

Well, they survive. Why?

8. What happens if we shorten the track of the walker, as much as possible? We obtain a graph wit the following property: after one (or a finite give number of) step of the greedy deterministic algorithm we obtain an isomorphic graph. A quine! chemlambda quine.

At first, it looks that we obtained a 28 nodes quine. After some analysis we see that we can reduce this quine to a 20 nodes quine. A 20-quine.

Here is the first observation of the 20-quine under the random algorithm

20_quine_50steps

According to this train of thoughts, a chemlambda quine is a graph which has a periodic evolution under the greedy deterministic algorithm, with the list of priority of rewrites set to DIST rewrites (which add nodes)  with greater priority than beta and FI-FOE rewrites (which subtract ndoes), and which does not have termination nodes (because it leads to some trivial quines).

These quines are interesting under the random reduction algorithm, which transform them into mortal living creatures with a metabolism.

____________

So this is an example of how lambda calculus can inspire chemlambda experiments, as well as interesting mathematical questions.

How to use the chemlambda collection of simulations

The chemlambda_casting folder (1GB) of simulations is now available on Figshare [1].

How to use the chemlambda collection of simulations? Here’s an example. The synthesis from a tape video [2] is reproduced here with a cheap animated gif. The movie records the simulation file 3_tape_long_5346.html which is available for download at [1].

That simple.

If you want to run it in your computer then all you have to do is to download 3_tape_long_5346.html from [1], download from the same place d3.min.js and jquery.min.js (which are there for your convenience). Put the js libs in the same folder as the html file. Open the html file with a browser, strongly recommend Safari or Chrome (not Firefox which blocks with these d3.js animations, for reasons related to d3). In case your computer has problems with the simulation (I used a macbook pro with safari) then slow it like this: edit the html file (with any editor) and look for the line starting with

return 3000 + (4*(step+(Math.random()*

and replace the “4” by “150”, it should be enough.

Here is a longer explanation. The best would be to read carefully the README [4].
“Advanced”: If you want to make another simulation for the same molecule then follow the steps.

1. The molecule used is 3_tape_long_5346.mol which is available at the library of chemlambda molecules [3].

2. So download the content of the gh-pages branch of the chemlambda repository at github [4] as explained in that link.

3. then follow the steps explained there and you’ll get a shiny new 3_tape_long_5346.html which of course may be different in details than the initial one (it depends on the script used, if you use the random rewrites scripts then of course the order of rewrites may be different).

[1] The Chemlambda collection of simulations
https://doi.org/10.6084/m9.figshare.4747390.v1

[2] Synthesis from a tape
https://plus.google.com/+MariusBuliga/posts/Kv5EUz4Mdyp

[3] The library of chemlambda molecules
https://github.com/chorasimilarity/chemlambda-gui/tree/gh-pages/dynamic/mol

[4] Chemlambda repository (readme) https://github.com/chorasimilarity/chemlambda-gui/blob/gh-pages/dynamic/README.md

Tay has been retired, Blade Runner style

It is always unexpected when fiction becomes real. Tay, the adolescent AI, survived for about 24 hrs on Twitter. She turned into something socially unacceptable. Then she has been retired. See Gizmodo story.

Almost two years ago I posted Microbes take over and then destroy the HAL 9000 prototype. I gave 9 seconds as an estimate for the chance of life of an AI in the real world, where there is no control and faced with  the “extremely dynamic medium of decentralized, artificial life based computation we all use every day“(that post suggests an artificial life, not AI version of the future internet).

Now, the story of Tay seems unbelievably close to the Blade Runner world. The genius of Philip K. Dick manifests here because  he mixes AI with synthetic life with real life.

Real people socially hacked Tay. Virtual microbes destroy HAL 9000. The common themes are: in a decentralized environment and AI vs life (real or virtual).

Not many people understand that today obsessions with security, control, privacy are all lost battles.