Presence Encoding (PE) is a way of representing information on the loom by using the presence (or absence) of a marble. It’s one of the two main approaches, the other being Lateral Encoding.
marbles and holes
Just as a marble is a physical object that moves around the loom, we can also think of a hole — the absence of a marble — in the same way.
In this way, every cell of the loom has either a marble or a hole. As we advance the pattern, these marbles and holes will flow around the loom.
Notice that marbles and holes are conserved — the numbers of each stay the same. They only change when:
- We feed marbles into the loom from a reservoir, or
- Marbles exit the loom from one of the edges
binary
We choose to interpret the presence of a marble as a 1, and a hole as a 0. If we look at any particular subsection of the board, we can read off a string of 1s and 0s, which we can interpret as a number (or any other piece of data).
Remember that this interpretation is arbitrary. We choose whatever representation is most useful to us. If you’re building a pattern, and it becomes more convenient to interpret a hole as a 1 and a marble as a 0, you can do that instead! You are free to invent your own representations.
advantages
Presence Encoding has a number of advantages:
- It’s simple.
- It’s compact — signals can be sent along a path just 1 cell wide
- It’s convenient. Roons are designed to interact with marbles and holes, so in a sense, PE is the “native language” of most pieces.
disadvantages
As you advance in roons, you’ll find yourself running up against some limitations of PE.
- It requires specific numbers of marbles/holes. To invert the binary value 0000 into 1111, you need to find 4 marbles from somewhere. This requires you to pipe in reservoirs all across your pattern, which is spatially expensive.