Category Archives: chemlambda

Preparing the microscope

For a new experiment.

ezgif-com-optimize2

If you want to discuss then here are some possibilities: xila@tuta.io drona@keemail.me which supposes that you make first a mail account at tutanota or open an issue at my chemlambda repository and propose me your way. Mind that if I don’t respond you then it means that either I did not got the message or I ignore your message because what you want can be deduced by using the already available public information.

 

What will happen next?

There are a lot of ideas circulating in, or around the chemlambda universe. So, what will happen with them?

First of all there is a way to turn this highly hallucinatory content (as witnessed by many discussions and participants) into a solid and user friendly experience of exploration. Indeed to the point of convergence with the real world applications.

One thing I learned the hard way is that there are moments when it is not good for a project to be too open too soon. One of the features of the chemlambda universe I’m proud about is that for the intelligent and creative people there is a sort of transparency available into the approx 50GB of material available. For the rest, though, things are not clear. This is done on purpose, but it does not scale with the growth of the project. A solution is needed.

Secondly, there is a solution into the frame of Open Science. I need to make some preliminary experiments and I hope to not make too many mistakes in the process.

Thirdly, as concerns the funding problem, there is a solution to that as well. It is a mistake to see this problem as the main and the most important to solve, though. I would be very much relieved if by some miracle this problem is solved instantly, sure, but my experience and gut feeling are telling me that’s not the main concern here.

OK, the TLDR is that I’m not yet in the position to disclose much, although I could go again and again into uncharted territory. I really want to communicate with you, but it is simply not yet the right moment.

That is why  I shall leave this post as it is, with the unnecessary parts “edited“.

Announcement: chemlambda can be done with RNA (final update)

There exists an encoding of chemlambda molecules with RNA, in such a way that the chemlambda model can be realized via real RNA computing. 
I shall update this post with details concerning my motivations and about how the second part of the announcement fits with my activities.
I open a bidding session concerning a contract based collaboration which could convince me that you’re an expert and you can provide me with the means to do this together. As concerns the collaboration, I shall give you an edge into being the first who does it. Letters of interest may be addressed to Marius.Buliga@gmail.com, Marius.Buliga@imar.ro or via the chemlambda repository (gh-pages branch) .
Follow this post for updates.
UPDATE: the bidding session ends on OCT 30 2016. As a funny simulation enjoy
which however does not disclose almost anything about the main subject of this post. Compare it with the simulation (needing js enabled in your browser) from the article Molecular computers (which is the ancestor of the ideas relevant here).

UPDATE 2:  Bidding ends today  OCT 30 2016 at 12 PM UTC time, measured from the timestamp of messages reaching me.  You may say that this is a random boundary and I agree, that is why I propose the following use of words  in future public references to this boundary  distinction. Anybody who meaningfully contacted and contributed to this project before the time boundary will be publicly called a supporter. This will be only a small expression of my gratitude, dear supporters please expect much more.

I thought about using the word legacy in relation to the others. This would be true per the use of the word in computing (or open science). Nah, is enough that I’ll know and you’ll know 🙂

UPDATE 3: Bidding closed.

__________________

More about chemical transactions

There is much more about these chemical transactions and their proofs. First is that transactions are partially independent on the molecules. The blockchain may be useful only for having a distributed database of transactions and proofs, available for further use. But there’s more.

Think about this database as one of valid computations, which can then be reused in any combination or degree of parallelism. Then, that’s the field of several competitions.

The same transaction can have several proofs, shorter or longer. It can have big left pattern therefore costly to use it in another computation. Maybe a transaction goes too long and therefore it is not useful to use in combination with others.

When there is a molecule to reduce, the application of a transaction means:
– identify a subgraph isomorphic with the left pattern and pick one such subgraph
– apply the transaction to this particular subgraph (which is equivalent with: reduce only that subgraph of the molecule, and freeze the rest of the molecule, but do it in one step because the sequence of reductions is already pre-computed)

Now, which is more convenient, to reduce the molecule by using the random algorithm and the available graph rewrites, or to use some transactions which fit, which is fast (as concerns step 2) but costly (as concerns step 1), moreover it may be that there is a transaction with shorter proof for that particular molecule, which mixes parts of several available precomputed transactions.

Therefore the addition of transactions and their proofs (needed to be able to validate them) into the database should be made in such a way which profit from this competition.

If I see the reduction of a molecule (which may be itself distributed) as a service then besides the competition for making available the most useful transactions with the shortest proofs, there is another competition between brute force reducing it and using the available transactions, with all the time costs they need.

If well designed, these competitions should lead to the emergence of clusters of useful transactions (call such a cluster a “chemlisp”) and also to the emergence of better strategies for reducing molecules.

This will lead to more and more complex computations which are feasible with this system and probably fast enough they will become very hard to understand by a human mind, or even by using IT tools on a limited part of the users of the system.

Chemical transactions and their proofs

By definition a transaction is either a rewrite from the list of
accepted rewrites (say of chemlambda) or a composition of two
transaction which match. A transaction has a left and a right pattern
and a proof (which is the transaction expressed as a cascade of
accepted rewrites).

When you reduce a molecule, the output is a proof of a transaction.
The transaction proof itself is more important than the molecule from
the start. Indeed, if you think that the transaction proof looks like
a list

rm leftpattern1
add rightpattern1

where leftpattern1 is a list of lines of a mol file, same for the rightpattern1,

then you can deduce from the transaction proof only the following:
– the minimal initial molecule needed to apply this transaction, call
it the left pattern of the transaction
– the minimal final molecule appearing after the transaction, call it
the right pattern of the transaction

and therefore any transaction has:
– a left pattern
– a right pattern
– a proof made of a chain of other transaction which match (the right
pattern of transaction N contains the left pattern of transaction N+1)

It would be useful to think in term of transactions and their proofs
as the basic objects, not molecules.

A library of chemlambda molecules

More than 400 molecules are now  available at the the github repository for chemlambda, at this link. Many of them have been used to produce the animations from the chemlambda collection at google+.

There are more than 200 animations in that collection, which attracted an average stream of 150000 views/day and more than 30000 followers. I am proud about that because the subject is rather hard and almost all posts contain original research animations.

If you want to identify the mol file (i.e. the molecule) which has been used to create a certain animation, then follow the  path:

  • click on the animation, you’ll be presented with a page where the animated gif runs
  • try to save the gif, you’ll see a name.gif
  • in another window go to the library of molecules and look for name.mol.

In most of the cases this works, but there might be rare cases where I forgot to preserve the correspondence between name.gif and name.mol.

During the time these animations have been produced, I used various versions of the scripts (all available at the repository). They should be all compatible, but it is possible that some mol files will not work as input for the scripts. If this happens, then it is because I used, mistakenly, a port variable in a bad place and then I forgot to delete the faulty version. Please excuse me for that, in case it happens (maybe, maybe 4 or 5 mol files from the about 440 are like this).

To see how to use the repository please go to the README.md file.

It is important to understand how I made the animations.

  • you need a linux or a mac, because the scripts are in shell or awk
  • I used a mac. I went to the folder where the scripts and the mol files are (so if you copy the mol files from the library, then copy  them in the same folder as the folder called “dynamic”, before you use the scripts). In a terminal window I typed, for example “bash quiner_shuffle.sh”. A list of all the mol files in that folder appear.
  • I type the complete name.mol and hit enter
  • then the main script does the magic and I obtain name.html
  • mind that the parameters for the computation are in the most important part, the script quiner_shuffle.awk (and quiner_shuffle.sh is just a wrapper of this, same for all the pairs of scripts .sh and .awk)
  • I used a browser to see name.html. Important: Safari works the best, by far, then Chrome. Firefox sucks for very obscure reasons. There is a solution for making the name.html to work on Firefox as well, is to find in the quiner_shuffle.awk the line “time_val=4; ” and to modify it into something like “time_val=120; “, for example. This variable controls the speed of the javascript animation, bigger is it, slower the animation.
  • You’ll see that the d3.js animation can take, depending on the molecule (and on the number of steps given by this line “cycounter=10000;” in quiner_shuffle.awk), from minutes to hours.
  • I made a screen capture of the animation and then I sped it, for example with ffmpeg.

Enjoy!

If you make nice stuff with it, then tell me and I’ll be glad to host your creation here and in the chemlambda collection.