Given the sets of commitments and nullifiers S at block n

Problem 1: Merging Sets S = {A, B} and S = {A, C}

The goal is to merge two proposed blocks with new sets of transactions, {A, B} and {A, C}, without conflicts. This is a relatively straightforward scenario where there is no conflict between the sets A, B, and C, and the final set would be the union of all elements, i.e., $S' = S \cup \{A, B, C\}$.

Solution 1:

  1. Since each transaction modifies the state (via commitments and nullifiers), the merge requires updating the Merkle trees for commitments and nullifiers.
  2. Leaders proposing blocks need to verify that no transactions modify the same note or result in a double spend. Given that there are no conflicts in this case, the leader would simply include all transactions in the next block.

The result would be $S' = S \cup \{A, B, C\}$, as all transactions can coexist without issues.

Thus, we can merge the two sets as long as there is no conflict, and the only requirement is to update the state of commitments and nullifiers.

Problem 2: Conflict Resolution Between A1 and A2

This scenario introduces conflicting transactions A1 and A2, which cannot be included together. The goal is to detect the conflict and merge the sets by discarding one of the conflicting transactions (based on an arbitrary rule).

Solution 2:

  1. Each transaction generates a nullifier that corresponds to the spent note. When combining transactions from different proposed blocks, the protocol would check for conflicts based on the nullifiers. If both A1 and A2 produce the same nullifier, then they are conflicting (i.e., a double spend is detected).
  2. To resolve the conflict, you would apply an arbitrary rule to pick either A1 or A2. This rule could be based on priority (e.g., timestamp, block proposer, or deterministic randomness). Let’s assume we choose A1.
  3. After choosing A1, the nullifier generated by A2 is discarded. The resulting set is $S' = S \cup \{A1, B, C\}$.

So, it can be detected the conflict via nullifier checks and merge the blocks by discarding one of the conflicting transactions.

Problem 3: Discarding Descendants of A2