Thank you Hundredrabbits!

Today I discovered Hundredrabbits by reading this HN post. And I felt upon this particular article by Hundredrabbits

https://100r.co/site/weathering_software_winter.html

Hey, brothers!

Just replace in the article “artist” by “mathematician” and you get a perhaps better version of chorasimilarity :))

The same problems as mine, for different, more beautiful to live reasons.

They are on a boat, I try to do open science.

They are on a quest for a computing system which is self-sufficient, that is the same problem I have in OS, where the goal is to just do it, give to the potential reader everything you have, in a form which is simple enough to be used without dependencies.

Heck, even the love for garbage computers, how much I long for understanding in this materialistic world, thank you Hundredrabbits!

And then I saw this illustration (screenshot of phone screenshot from chorasimilarity telegram)

Oooh, this is an image from Zipper logic V, a post from 2014!

So they considered the possibility hahaha: “I went down that rabbit hole, and I barely emerged back alive.”

And also the repeated arguments that this or that does not port easily to silicone… Like chemlambda, where you have to destroy all the time the extra information the silicone needs to describe graphs and therefore most of the computation is actually needed to jump randomly….

Fractions? I know what you refer to, but fractions? What about rational fractions, have you seen Pure See?

I understand the choice of (but not yet fall in love with) Forth, eventually.

What a great post, nice to learn about you, from my virtual boat ;)))

Cost corrected in chemSKI with tokens

Follows after this post.

I updated chemistry.js, because there was a bug in the rewrite S-K, which affected the cost.

The rewrite S-K is described in the article here. As you see, it has an Arrow token in the input. Or in the rewrite S-K as performed by chemistry.js, there was no Arrow element because the rewiring was done directly. This was not affecting the behaviour of the reductions, because it is like a COMB rewrite is done after the rewrite S-K.

But it did affect the cost, because in the cost function there was an Arrow token substracted even if in the program the original S-K used no Arrow, so there was no future COMB to add the Arrow back.

Therefore the behaviour of the cost was skewed to accumulate Arrow debt.

Now the rewrite S-K adds an Arrow node, as described in the article. See the modification between lines 1370-1389.

Try the programs to see that the Arrow count is correct, here:

https://mbuliga.github.io/chemski/chemski-with-tokens.html#PlayPlace

Play with terms in chemlambda vs dirIC, chemSKI

I record here some differences in reduction between chemlambda and dirIC, then I’ll talk very briefly about chemSKI for SKI or SK calculus.

Chemlambda vs dirIC

Chemlambda and directed Interaction Combinators (dirIC) are not equal.

Play with div from https://github.com/tromp/AIT/blob/master/numerals/div.lam

Use https://mbuliga.github.io/quinegraphs/lambda2mol.html

As chemlambda or dirIC want only one term to be inputted, we have to build it progressively, so here is the process:

with all parantheses…

1tuple = (\x.(\f.(f x)))

id = (\x.x)

F = (\m.(\f.(\t.((((m (\x.(\f.(f x)))) (\c. f (c t))) (\x.x))))))

K = (\x.(\y.x))

div = (\n.(\m.(\f.(\x.(((n (\x.(\f.(f x)))) ((\x.(\y.x)) x)) ((n (((\m.(\f.(\t.((((m (\x.(\f.(f x)))) (\c. f (c t))) (\x.x)))))) m) f)) x))))))

we prepare the term

term = (((div number1) number2) a) b

replaced div

term = ((((\n.(\m.(\f.(\x.(((n (\x.(\f.(f x)))) ((\x.(\y.x)) x)) ((n (((\m.(\f.(\t.((((m (\x.(\f.(f x)))) (\c. f (c t))) (\x.x)))))) m) f)) x)))))) number1) number2) a) b

for

number1 = (\f.(\x.(f (f (f (f (f (f x)))))))) (ie Church 6)

number2 = (\f.(\x.(f (f (f x))))) (ie Church 3)

we get

term = ((((\n.(\m.(\f.(\x.(((n (\x.(\f.(f x)))) ((\x.(\y.x)) x)) ((n (((\m.(\f.(\t.((((m (\x.(\f.(f x)))) (\c. f (c t))) (\x.x)))))) m) f)) x)))))) (\f.(\x.(f (f (f (f (f (f x))))))))) (\f.(\x.(f (f (f x)))))) a) b

which works in chemlambda but not in dirIC.

For the term

term1 = (div number1) number2

we replace div, number1 and number2

term1 = ((\n.(\m.(\f.(\x.(((n (\x.(\f.(f x)))) ((\x.(\y.x)) x)) ((n (((\m.(\f.(\t.((((m (\x.(\f.(f x)))) (\c. f (c t))) (\x.x)))))) m) f)) x)))))) (\f.(\x.(f (f (f (f (f (f x))))))))) (\f.(\x.(f (f (f x)))))

works in chemlambda, not in dirIC.

For

number1 = (\f.(\x.(f (f (f (f (f (f (f x))))))))) (ie Church 7)

number2 = (\f.(\x.(f (f (f x))))) (ie Church 3)

we get

term1 = ((\n.(\m.(\f.(\x.(((n (\x.(\f.(f x)))) ((\x.(\y.x)) x)) ((n (((\m.(\f.(\t.((((m (\x.(\f.(f x)))) (\c. f (c t))) (\x.x)))))) m) f)) x)))))) (\f.(\x.(f (f (f (f (f (f (f x)))))))))) (\f.(\x.(f (f (f x)))))

works in chemlambda 7 div 3 = 2

_________________

ChemSKI for SKI or SK calculus

I does not matter which one is used, in the sense that if you don’t input any I combinator, then you don’t get any. There is a lot of waste, but now this is managed by waste rewrites.

Maybe relevant in the larger discussion chemSKI not Kind.

Examples:

Use https://mbuliga.github.io/chemski/chemski-with-tokens.html#PlayPlace

Down the page tromp.github.io is a minimal SK version of the Y combinator.

S S K (S (K (S S (S(S S K)))) K)

Applied to I should give a quine

((((S S) K) ((S (K ((S S) (S ((S S) K))))) K)) I)

Applied to S K K instead should work as well

((((S S) K) ((S (K ((S S) (S ((S S) K))))) K)) (S K K))

It does. ChemSKI rules rule!