Menu

Post image 1
Post image 2
1 / 2
76

Petri Nets as a Music Sequencer

Hacker News·Petri Nets as a Music Sequencer·about 1 month ago
#Ag0Rwao1
#token#circles#ring#track#beats#article
Reading 0:00
15s threshold

← Home Go to beats.bitwrap.io . Pick a genre — techno, jazz, ambient, drum & bass, 19 in total. Hit Generate. You'll hear a full track: drums, bass, melody, arpeggios. Change the seed, get a different track. Replay the same seed, get the exact same one. There's no piano roll behind this. No timeline grid, no DAW. The whole thing runs on Petri nets — circles connected by arrows, with tokens moving through them. Every note is literally a token moving one step through the diagram. A Drum Machine Made of Tokens Picture a ring of 8 circles connected by arrows. One dot — a token — sits at the first circle. Every tick, it hops to the next one. Some circles trigger a kick drum when the token lands. The rest are silent. The token goes around and around. You've got a beat. The pattern of hits comes from the Bjorklund algorithm — it spreads K hits across N steps as evenly as possible. With 3 hits across 8 steps you get the tresillo , a rhythm that shows up everywhere from Afro-Cuban son to Rihanna.…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.

Read More