Numbering zats

Assignment at mining, transfer by first-in-first-out.

Assignment

Zats are numbered in the order they are mined. The first zat of the genesis block subsidy is zOrdinal 0, the next is 1, and so on through every block subsidy the chain has produced. A block that pays a subsidy of 1.25 ZEC brings 125,000,000 fresh zats into existence, each with the next number in sequence.

Fees do not create new zats. A miner claiming fees is claiming zats that were already numbered when they were first mined.

Transfer

Inputs to a transaction are concatenated in order to form a list of zats. Outputs are then filled from the front of that list, in order. This first-in-first-out rule makes the assignment deterministic for any transparent transaction.

text
inputs:  [a: 3 zats] [b: 2 zats]
list:     a0 a1 a2 b0 b1

outputs: [x: 4 zats] [y: 1 zat]
x -> a0 a1 a2 b0
y -> b1

Fees and the coinbase

  1. Zats paid as fees drop out of the output list and go to the block's coinbase.
  2. The coinbase output is filled first with the new subsidy zats, then with fee zats.
  3. A miner spending that output passes those zats on like any other.

Notation

The same zat can be written several ways, each useful in a different context.

  • Integer1249000000000, the raw zOrdinal number.
  • Decimal1240000.5000, block height and offset within the block.
  • Degree1°35000′0″500‴, halving era, block into the era, upgrade offset and offset into the block.
  • Name — see the names section.

Rules recap

  • Numbers are permanent — a zat keeps its zOrdinal forever.
  • A zat is only ever in one output at a time.
  • Tracking stops the moment a zat enters a shielded pool.