Hacker News new | ask | show | jobs
by Kotlopou 28 days ago
Thanks for responding this way! This had flame-war potential that didn't get realised. I'll try and reply in a similar spirit.

I still find it curious how few holes there are (took a while to find one!), and finally figured out why: imagine a large square grid. It would probably have a different density than the rhombus grid, and it seems nontrivial to match it up. It seems that in the code this is done by each rhombus having edge length 50 while the periodic table elements are 38 x 42 pixels in size.

This, if I understand it correctly, means that this tiling is not just aperiodic but (in this regard) also anisotropic -- it's denser in one direction than another. And thus I have learned a new thing about Penrose tilings. :)

1 comments

I had not thought about it that way and to be clear some of the parameters (such as the sizes you mention and also the row numbers in ELEMENTS) were found by a bit of experimentation. With the fundamental algorithm in place there was a bit of iteration to get something that looks good on screen (almost all the time).

The other thing was the title. The code originally could have had two letters (e.g. P and E in APERIODIC) joined at a vertex and it looked odd (it looked like the word was broken) so there's specific code to make sure that doesn't happen.