UTXO model vs. account model
The many cryptocurrencies that use the UTXO model do not use accounts or balances. Instead, individual coins (UTXOs) are transferred between users, much like physical coins or cash. The UTXO model treats currency as objects. The history of a UTXO is stored only in the blocks when it is transferred, and to find the total balance of an account one must scan each block to find the latest UTXOs which point to that account. UTXOs are valid no matter their age; it is only necessary to acknowledge their ownership when they are sent, and not in each and every block. Though all nodes on a single chain must all agree on the block history, the relevant blocks to any single account's balance will likely be unique to that account. On the other hand, an account model keeps track of each account and its respective balance for every block added to the network. This allows account balances to be checked without scanning historical blocks, but increases the raw size of each block (compression of unchanged account balances can reduce space requirements). Checking account balances is quicker, but like the UTXO model, fully verifying the origin of coins still requires auditing past blocks to the coin's origin.UTXO set
The total UTXOs present in a blockchain represents a set, every transaction consumes elements from this set and creates new ones that are added to the set. Thus, the set represents all the coins in a particular cryptocurrency system. The complete UTXO set can be summed to calculate the total supply of a cryptocurrency at a given point in time. Outputs are a superset of UTXOs. Accordingly, UTXOs are a subset of the outputs superset. Bitcoin UTXO lifespans have been studied. In the case of a valid blockchain transaction, unspent outputs (and only unspent outputs) may be used to fund further transactions. The requirement that only unspent outputs may be used in further transactions is necessary to prevent double-spending and fraud. For this reason, inputs on a blockchain are removed from the UTXO set when a transaction occurs, whilst at the same time, outputs create new UTXOs, which are added to the UTXO set. These unspent transaction outputs may be used (by the holders of private keys; for example, persons with cryptocurrency wallets) for the purpose of future transactions.Origins
The UTXO model can be attributed to Hal Finney's ''Reusable Proofs of Work'' proposal, which is based on Adam Back's 1997 Hashcash proposal.See also
* Distributed ledgerReferences
Cryptocurrencies Digital currencies Financial cryptography Payment systems Distributed computing {{Cryptocurrency-stub