Since the banking system has always worked in terms of that, it is of course not unworkable. Relationship also have same principles, a balance that can go positive and negative. Biologically, probably serotonin system (it was metabolic byproducts of using tryptophane amino acid for energy which signaled sociality among bacteria, was co-opted as a social coordination hormone, territorial coordination, i.e., “money”).
Like Tom said, a simple direct tab between two friends works. But it achieves little. The next step up, is novation. A “novation network”. Here, you are not even doing multiple hops. It is always just one hop. But it achieves the clearing by novation.
Such “novation network” is a good “primitive”. Maybe it is meaningful even without the 2nd tier below it. Might be many groups or people who mainly want to interact within such system, exchanges between one another right now. Who knows. It is a thing in itself, and the one step above Tom’s “friends keep a tab”.
The 3-node coordination I suggested does not work. But the direction was the right one. The interesting thing with 3 nodes is majority vote works well. This stops working with more (“sybil attack”, N nodes can attack and win majority vote but damage themselves less than the rest). It is symmetric with 3 nodes.
Such needs both majority vote for commit and abort. It also needs to signal when voting starts. I think a majority hash lock that is:
“prepare”, here majority abort can be signed with 2-of-3 abort preimages (avoids node 2 attack). debtor locks X amount to transfer, can commit at any time. creditor also locks X to enforce cooperation. can abort at any time.
“pre-commit”, this is decided by the initiator releasing the pre-commit preimage, who only they hold
“commit”, majority vote with 2-of-3 commit preimages
This might seem complex. But majority vote to either commit or abort is very common pattern. The “pre-commit” preimage solves knowing if everyone has agreed to do the vote, the vote cannot enforce anything unless people have first set up an agreement with the hash lock as condition…
