‹ BackHN Continuity

Thread

L-systems generate weevils, pizza toppings, and matriarchal lineages

15 points · 3 comments · surprisetalk

Loading the complete thread in the background. This saved snapshot is available now. Refresh

  1. abound · · focus · HN ↗
    > I tried to get Claude to help me with this article, but it said the premise was too stupid so I had to do it myself.
    1. mjd · · focus · HN ↗
      Let that be a warning to the rest of you.
    2. chuneezy · · focus · HN ↗
      I love this haha
  2. kragen · · focus · HN ↗
    This is hilarious. Most of these L-systems generate &quot;morphic words&quot;, <a href="https:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;Morphic_word" rel="nofollow">https:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;Morphic_word, a kind of L-system I have a particular affection for, because it seems to me like the simplest kind of aperiodic sequence.

    As a fascinating coincidence, it was specifically thanks to Mark Dominus that I was fiddling with L-systems on Monday, even though I was not yet aware of this article. I wanted plant models that were a little more stochastic and expressive than bare L-systems, but less verbose and clunky than the CGA shape grammars used in CityEngine. Claude suggested parameterizing Chris Coyne&#x27;s &quot;context-free design grammars&quot;, giving very pleasing results like

      # A monopodial tree: every node puts out one lateral and the axis carries
      # on at `ratio` scale, so the laterals shrink, and crowd together, in the
      # same geometric progression toward the tip.
    
      param ratio = 0.9 in 0.7..0.97
      param lateral = 0.5 in 0.2..0.8
      param spread = 50 in 0..90
      param divergence = 137.5 in 0..180
      param droop = 6 in -20..30
    
      start shoot
    
      shoot when size &lt; 0.03: leaf 6 3
      shoot:
          limb 1 0.09
          shoot roll divergence tilt 0±5 scale ratio
          shoot tilt spread±10 bend droop scale lateral
    
    Further examples and 3-D rendering at <a href="http:&#x2F;&#x2F;canonical.org&#x2F;~kragen&#x2F;sw&#x2F;plants" rel="nofollow">http:&#x2F;&#x2F;canonical.org&#x2F;~kragen&#x2F;sw&#x2F;plants.
Open on Hacker News to reply ↗

Unofficial Hacker News client; not affiliated with Y Combinator.