Introduction
This article is motivated by the increasing prevalence of cryptocurrencies and decentralized finance topics in mainstream news sources. Exposure to cryptocurrencies using only those mediums is narrow due to their focus on the financial moves within a currency (e.g. bitcoin). In order to enhance baseline understanding and bridge the gap between theory and application, this article aims to serve as a brief primer, including review, discussions and potential research directions for cryptocurrencies.
First, we provide a thorough introduction to the blockchain and consensus protocols in Section \ref{sec:mechanism}. As the mechanisms are important to characterizing cryptocurrencies, we include some computer science concepts but still maintain a high level description. \footnote{The curious reader may refer to chapter 2 of Narayanan, A. \textit{Bitcoin and cryptocurrency technologies : a comprehensive introduction} (\href{https://d28rh4a8wq0iu5.cloudfront.net/bitcointech/readings/princeton_bitcoin_book.pdf?a=1}{Here}) for more details }
Following that, a few of the popular cryptocurrencies are discussed in Section~\ref{sec:coin}, including: bitcoin and it’s derivatives, litecoin, ethereum, and stable coins. The subtle mechanism differences of the cryptocurrencies is the key to develop long-term cryptocurrency investment strategies. In addition, the comparisons provided aims to answer commonly asked questions from investors interested in cryptocurrencies.
Finally, to develop our own methodology for providing investment suggestions for cryptocurrencies, we connect the challenges in cryptocurrency investment with research directions and methods in economics, statistics, applied math, and machine learning. In Section~\ref{sec:next}, we dive into the valuation, selection, and portfolio optimization of cryptocurrencies.
Blockchain and Consensus Protocols
In cryptocurrency terminology, a computer that downloads the blockchain and associated computer program is referred to as a node. A user is the human that operates/creates the node. Each node is identified by a public key and private key that is automatically generated by the computer program. Public keys are identifiers used in interacting with other nodes. Private keys are confidential and act as signatures to confirm individual transactions. More simply, each node can only act as themselves in the network and cannot forge the transactions of others. However, users are allowed to be associated with multiple distinct nodes.
A blockchain is the public ledger system used to keep track of cryptocurrency transactions. A block is composed of a collection of transactions, a timestamp of block creation and an identifier of the block. There is a recursive relation in which each block is aware of the previous block’s identifying hash/indentity. The blocks are chained together as a single entity by hash cryptography, preventing manipulation of individual blocks. Blocks cannot be removed or changed once they are added to the chain. See Fig \ref{fig:block} for a sample schema of a blockchain.
All nodes are allowed to propose a new block to be added to the blockchain. However, the lack of verification by a central authority, means there must be consensus amongst all nodes in order to permanently add a proposed block to the blockchain. Blocks must be verified because invalid transactions undermine the credibility of the entire blockchain. Furthermore, digital content is easy to replicate, and so nodes must incur a cost to propose a new block; otherwise, malicious or adversarial nodes can spam the blockchain with invalid blocks. This incurred cost on the nodes is through expenditure of resources and there are multiple ways to achieve it in practice.
The cost is an enforcement mechanism aimed to prevent illegitimate transactions from occurring in the blockchain. There are three common consensus mechanisms that describe the implementation. For ease of exposition, we refer to nodes that propose to add a block as miners and nodes that verify that the content of block is accurate as nodes.
Proof of Work (PoW)
The Proof of Work mechanism requires that the miners prove that they worked, or expended computational power before they can propose to add a new block to the chain. The miners incur a cost from the investment of computing power, electricity and restriction of multi-tasking capabilities of system. The computational power is spent on solving a hash puzzle that can only be solved through trial and error. See Fig \ref{fig:PoW} for a flowchart of the PoW mechanism.
The chance of success in solving the puzzle is proportional to how quickly the computer can evaluate hash functions. This leads to centralization of mining power as technological equipment becomes cheaper and faster. Miners capable of investing in specialized system parts can increase their computational power to the point where they dominate the total amount of computing resource and solve the hash puzzle frequently. Alternatively, miners are able to collude by pooling computing resources which make this a possibility.
Once this is achieved, the system becomes vulnerable to what is known as the 51\% attack. In the 51\% attack, a miner or group of miners become the central authority of the entire blockchain; and therefore control which transactions are added. Although nodes are able to verify and prevent the addition of invalid transaction, they are unable to reconcile the accuracy of multiple blockchains (forks) due to network delays and simply choose the longest one \footnote{More discussion of the this in Appendix \ref{sec:appforks}}.
However, all hope is not lost. Miners are incentivized to be legitimate because they receive payments in the cryptocurrency from a transaction generated from the blockchain program each time their block is added \footnote{This transation is called the coinbase transaction, see Appendix \ref{sec:applinks}}. Therefore, by undermining the blockchain, the value of their reward diminishes. In practice, miners control large amount of computing resources but choose not to be malicious.
There is no reason why the effort expended has to go into solving the hash puzzle. Other puzzles have been proposed so that the computational resources are spent on challenging but more socially beneficial tasks. See growing projects on Proof of Useful Work (PoUW)
Some examples of PoW blockchains are Bitcoin (Section~\ref{sec:bitcoin}), Ethereum (Section~\ref{sec:ethereum}) and Litecoin (Section~\ref{sec:litecoin}).
Proof of Stake (PoS)
The Proof of Stake mechanism requires that miners prove they have stake in the blockchain. The cost arises from accumulating the cryptocurrency itself. Miners with a larger holding of coins are more likely to solve the puzzle needed to add a block. Or more simply, the puzzle is made easier for miners with more coins. See Fig \ref{fig:PoS} for a flow chart describing PoS.
PoS was designed to be more scaleable and environmentally friendly than PoW. In practice, it has reduced the need for specialized computation hardware that draw electricity. Also, in order for the 51\% attack to happen, a miner must have majority stake in the cryptocurrency. Therefore, they have enough skin in the game that any undermining of the blockchain directly impacts their payoff. Therefore miners are incentivized to be responsible stakeholders.
However, there is still a vulnerabilty in this mechanism. Because there is no work required to propose a block to add to the chain, malicious miners with low stake may spam the blockchain in order to obtain the reward. Technically, they will create forks \footnote{More discussion of forks in Appendix \ref{sec:appforks}} of the chain and work on each one simultaneously. This is known as the Nothing-at-stake attack. It is possible to implement a hybrid of PoW and PoS. Alternately, there is also the Proof of Delegated Stake (PoDS) mechanism in which nodes are voted to become trusted miners by other nodes with a stake in the blockchain. This voting scheme creates a barrier on who can actually become a miner.
An example of a cryptocurrency using PoS is Ethereum 2.0, which is planned for a 2022 release.
Proof of Burn (PoB)
The Proof of Burn mechanism requires that miners prove that they have burned their cryptocurrency by sending it into an unspendable public address (i.e. a node that only receives but cannot send), in order to propose to add a new block to the blockchain. The destruction of coins is an alternative to the waste that is created by PoW. However, in this case, miners are simply paying for virtual computing power with cryptocurrency instead of physical resources. The cryptocurrency burned does not have to be the same as the one that is mined.
PoB is a rarely used consensus mechanism, however, it is included here for completeness. An example of a blockchain using PoB is Peercoin
Smart Contracts
Public trust in a specific money is vital to its adoption. A money deemed reliable by a large network of users, leads to the evolution of the nature of transactions. Examples of transactions include: borrowing/lending money (mortgage), participating in a lottery (betting) or risk sharing (insurance). The nature of these transactions involve agreements, or contracts, between agents.
The simplest contract is a unilateral transfer between two agents: agent 1 (he) gives a specific amount of money to agent 2 (she). He and she must agree that the terms have been met for the contract to be fulfilled. With cash, this contract is fulfilled after the money is in her possession and she confirms the amount. With a digital account, this contract is fulfilled after the request is sent to the financial institution who then confirms he has the money available. With cryptocurrency, the transaction is marked as complete after it enters the blockchain \footnote{Usually after four other blocks have been added}.
This simple use-case is not rich enough to cover the demands of the population. The terms of the contract can be adjusted to include a time of settlement, exclusion/inclusion criteria of permissible agents, referrals to other contracts, and other stipulations. Typically, since contracts are agreements between agents there is an inherent trust between parties involved. As with most transactions today, the trust can be outsourced to a neutral agent that monitors the contract to ensure its fulfillment. These arbiters could be a bank, an auditor or a litigator to settle disputes and enforce penalties.
As the blockchain is inherently trustless and anonymous, there is no single arbiter monitoring adherence to contractual obligations. This leads to a commitment problem and creates incentives for agents to not fulfill terms of contract. However, decentralization and transparency provides an algorithmic mechanism to guarantee the fulfillment of contacts. The blockchain utilizes smart contracts, which are \say{digital, computable contracts where the performance and enforcement of contractual conditions occur automatically, without the need for human intervention}~\citep{szabo1997formalizing}.
A smart contract is a computer program made of executable commands triggered by events that reside on an address on the blockchain. Similar to transactions, any node can create smart contract (usually for a fee). The deployment of the smart contract creates an associated account with a unique public identifier and an account balance. Smart contracts may interact with nodes or other smart contracts by transacting with them through the public identifier. The set of nodes that can interact with the smart contract may be specified into the contract. Actions performed during interaction may be specified as the executable commands once certain conditions are met.
The classical example of a smart contract is the vending machine. Below is a quote from the first paper to refer to smart contracts and an algorithm (Algorithm \ref{lst:smart}) of its implementation.
When the money is paid, an irrevocable set of actions is put in motion. The money is retained and a drink is supplied. The transaction cannot be stopped in mid flow. The money cannot be returned when the drink is supplied. The transaction’s terms are in a sense embedded in the hardware and in the software that runs the machine.
Smart contracts are created by a single node, but any node can and will interact with the contract if they fulfill the conditions and commands in the program code. Interactions with the smart contract are stored on the blockchain and the execution is done on the network. Vulnerability of smart contracts lie in the code within the contract itself. A contract that is not programmatically integral will have security flaws that hackers can exploit. In addition, smart contracts are over-reliant on the blockchain and are difficult to monitor for transactions that occur outside of the blockchain.
Examples of blockchains with a smart contract implementation are Bitcoin and Ethereum. Bitcoin’s smart contract implementation is more crude than the Ethereum’s. As a result, Ethereum has led the way in smart contract development. Furthermore, it has led to a broader concept of performing financial services in a decentralized manner by bringing traditional financial services to the blockchain. This is done through tokenization, the process of intertwining physical assets with the blockchain by representing physical items and concepts with digital tokens/cryptocurrencies \footnote{See \href{https://corpgov.law.harvard.edu/2018/05/26/an-introduction-to-smart-contracts-and-their-potential-and-inherent-limitations/}{here} for a legal review of smart contracts along with challenges for adoption.
Decentralized Finance (De-Fi) Economy
DeFi is fundamentally a competitive marketplace of decentralized financial applications that function as various financial primitives such as exchange, save, lend, and tokenize. These applications benefit from the network effects of combining and recombining DeFi products and attracting increasingly more market share from the traditional financial ecosystem.
Using smart contracts, De-Fi applications (dApps) emulate traditional financial services without the presence of intermediaries such as a bank, brokerage or lawyer. The marketplace for dApp is without barriers, allowing any user to participate without fears of censorship. The process of creating a dApp is as follows: users with programming experience create a smart contract to perform the task of a financial institution; afterwards, they may implement a user interface such as a webpage to complement it. Since the smart contract is deployed on the blockchain, any user can inspect it for validity. The interactions with the dApps is also recorded on the blockchain. In addition, dApps allow for synergies between other dApps without hampering the blockchain due the underlying smart contract. Some practical examples of dApps are listed below.
Equity Tokens \& Initial Coin Offerings (ICO)
Suppose an entrepreneur starts a company and needs investment capital to expand. Usually, an entrepreneur would go to a banker/underwriter to access the capital markets and raise capital. In exchange for the capital, the entrepreneur offers an ownership stake in the company.
Attempts to remove bankers from this process are accomplished by using peer-to-peer lending. This is similar to crowdfunding, in which many individuals fund small portions of a project. Equity tokens performs the same task but with smart contract’s automatic executions.
With a smart contract, the entrepreneur initiates transactions that mimic the sale of ownership of a company. The entrepreneur creates a fixed supply of tokens or digital currency, where each token represents a fixed percentage of the company. Hence, if the owner keeps most of the coins, then they become majority owner of the company. Any node can purchase these tokens and the initial sale of these tokens is called an ICO. The blockchain ledger will keep track of accounting: who owns what, how much they own and how ownership is transferred.
According to Etherscan, there are over 480,000 Etheruem blockchain tokens as of December 2021. With the ease of creation, there are few to no financial protections in these investments.
Non-fungible Tokens (NFT)
Similar to common stock, equity tokens are fungible. Therefore, the balance of holdings is what determines the amount of stake in the company. Most cryptocurrencies are also fungible and result in nodes only keeping track of their wallet balance. However, it is possible to differentiate tokens within the same blockchain. Tokens that are unique and distinct from each other are called NFTs.
Each NFT has its own unique ID associated with it and can therefore be individually tracked. Creators of NFT can inscribe a signature or feature to the token to represent something of value. As a result of the unique IDs, each token will have its own history of owners.
NFTs are popular in the digital art market \footnote{Beeple’s artwork sold for $69 million in March 2021 on online auction hosted by Christies}. They accomplish the task of identifying ownership of a unique good. It is similar to a deed of ownership in the sense of property rights. Although, there are currently no legal precedents, it could be an experiment to bring physical assets (e.g., real estate) into the digital world.
Decentralized Autonomous Organizations (DAO)
Suppose now that an individual wants to create a corporation or conglomerate with membership open to anyone. The corporation could be a venture capital or charity that supports projects deemed worthy. The corporation needs to raise money and have a voting mechanism for members to choose projects. To accomplish this without the need for trust between members is the goal of a DAO.
DAOs are associated with an equity token to determine how much ownership each member has. The number of equity tokens can be dynamic: mint more to sell and increase the pool of capital, and removal of token to reward the current members with higher price. In addition to representing ownership of the company, the equity tokens allow members to vote on proposals for changes to the DAO. If the token majority votes in favor of a proposal, then the change is implemented.
The issues with DAOs deal with the difficulty in fixing bugs/glitches in the contract since a majority of members has to agree to the fix the bug. The delay to fixing the bug means there is more time for users to exploit the bug.
According to DeepDAO, there are about 181 DAOs, with total assets under management of $12 billion as of end of December.
Decentralized Exchange (DeX)
The DeFi movement introduces a token based economy, with each token serving a unique function: membership, ownership, etc. Development of new tokens requires a marketplace to sell the tokens. Furthermore, users’ token portfolio preferences and needs are bound to change over time. An exchange or marketplace to acquire and trade tokens is needed for this portfolio re-balancing.
Traditionally, it is commonplace, and sometimes required, for users to hire a licensed professional as a proxy to represent them in these exchanges. In financial exchanges, these professionals are intermediaries that act as a market-maker (find counter-party), custodian (store/secure asset) and/or broker (settle transaction). As a result of reliance on a central party, these are referred to as centralized exchanges. And as you can guess, those without central intermediaries are DeX \footnote{Interestingly, many cryptocurrency exchanges such as Binance and Coinbase are centralized}. Trading tokens in centralized exchanges is popular because of the conveniences offered: high liquidity, near instant settlement, customer service, ease of use, etc. However, the trade-off of convenience is the loss of anonymity and the required trust in the intermediary to keep the assets secure.
DeXs are intended to streamline peer to peer exchanges by incorporating smart contracts and features of centralized exchanges. It is a small and growing segment of token trading volume; with $110 billion worth of trading volume in decentralized exchanges as of Nov 2021 according to Dune Analytics, with the exchange Uniswap accounting for most of the volume.
The main differences amongst DeXs is the management of liquidity. A simple DeX is similar to the vending machine smart contract: an inventory of tokens are kept on the contracts wallet, prices are quoted and updated regularly, and users interact with the contract by buying or selling tokens. Liquidity has to be actively managed by specified market-makers. This crude use of the smart contract exposes the vulnerability of front-running caused by the transparency in the blockchain’s consensus mechanism. Since all transactions require miner’s approval, it is possible for miners to discard a requested transaction and replicate it with more favorable terms for themselves.
Another type of DeX (e.g., Uniswap) manages liquidity through a liquidity pool generated by voluntary contribution by users. In exchange for providing liquidity, users receive liquidity tokens representing their share of ownership of the pool and granting on-demand withdrawal of their portion. In addition, liquidity tokens entitle them to revenue of the platform from fees charged to traders that trade through the liquidity pool. The vulnerability of this method is slippage or when a shallow liquidity pool leads to large trades move the market.
Some Active Cryptocurrencies
In this section, we review four different cryptocurrencies, and discuss their differences on the mechanism.
Bitcoin (BTC)
Perhaps the most well known cryptocurrency, Bitcoin was introduced in 2008 by a group under the pseudonym of Satoshi Nakamoto and it was created to solve the double spend problem that arises when there is no central auditor of the ledger. Double spend occurs when a consumer attempts to send money that is not in their possession. A central authority can easily block this transaction. However without a central authority, everyone needs to be kept updated on the current balances of everyone.
Bitcoin relies on the Proof of Work mechanism. The computational burden results from miners repeated evaluation of the hash function with two parameters in order to find the hash that is less than some set number. The parameters are (1) content of the block and (2) a number (nonce). The correct nonce is distributed uniformly from a large collection of numbers. As a result there is no way to easily find the nonce without trial and error. Those with more processing power are able to achieve a faster rate of trials. Once the appropriate nonce is found, it is easy for other nodes to verify that is is correct and accept the new block into the chain.
There is a new block added roughly every ten minutes. Miners who successfully add a new block are rewarded by fees from nodes that transacted within the block and there are new coins generated to compensate the miner. There is a limited supply of 21 million bitcoins. Of which, 18.8 are in circulation~\citep{nakamoto2008bitcoin}. See Fig \ref{fig:btc} for an example of a bitcoin transaction.
According to Blockchain.com, there has been on average 1,800 transactions per block each day in Dec 2021. According to Bitinfocharts, the average daily transaction fee this year has been as low as $1.78 and as high as $62; with the highest daily fees occurring in April when the price set new highs.
Bitcoin Cash (BCH)
Bitcoin Cash is an intentional fork of the bitcoin blockchain by programmers who wanted to increase the blocksize of bitcoin blockchain. The fork occured on August 1, 2017. The blocksize is now 32x the size of Bitcoin’s, allowing it to handle a similar magnitude increase in transactions.
Litecoin (LTC)
Litecoin is another of the popular cryptocurrencies, it was spun-off Bitcoin in 2011. It follows all the technical details of Bitcoin (finite supply, decentralized, etc) but proposes a PoW algorithm meant to overcome the high barrier of entry to mining in Bitcoin. As mentioned before, miners with deep pockets are able to invest in the specialized GPU and computer chips that enable faster rate of evaluations in the hash puzzle. This prevents ordinary users from using a simple PC to win the mining reward. In order to prevent the centralization of computational power, which may lead to a 51\% attack, the computational effort required for litecoin is through a computer’s memory and CPU where it is less likely for there to be specialized hardware. Therefore all miners off varying investment capabilities are on the same playing field.
According to the Litecoin website, there is a finite supply of 84 million litecoins with 66.7 million in circulation. The average time to add a block is 2.5 minutes.
Ethereum (ETH)
The Ethereum blockchain launched in 2015 by a small group with the co-founder and current CEO Vitalik Buterin. The Ethereum blockchain transacts using the cryptocurrency ether. Ethereum is perhaps the most flexible use of the blockchain ledger discussed so far. The Bitcoin blockchain has technical limitations in implementing smart contracts. Although Ethereum uses the same PoW consensus mechanism \footnote{It will transition to PoS in future}, it is focused on creating an alternative protocol for building decentralized applications (dApps)~\citep{buterin2013ethereum}. It’s blockchain has a built-in programming language (Solidity) that allows users to create arbitrary contracts by writing up the logic in a few lines of code~\citep{buterin2013ethereum}. As a result of strong developer support, it has allowed for a richer set of financial services including escrows, lending, and other de-fi services.
The Ethereum blockchain differs from the Bitcoin blockchain by allowing greater integration of smart contracts without sacrificing ease of development. This can be seen in the decision to have two types of nodes in the Ethereum blockchain: contract nodes and externally owned nodes. Contract nodes execute a set of instructions in a specific smart contract when requested. This mimics the role a skilled intermediary may perform. For example, a lawyer will execute the instructions of a will in the occurrence of death. Externally owned nodes are all other nodes and are managed by humans. All nodes of the blockchain can be recipients and senders of ether.
Both type of nodes have an many similarities: an account key, an account balance and capable of interaction with all other nodes. Contract nodes are distinct in that they are created by externally owned nodes according to a fixed smart contract for a fee. The contract nodes can receive/send ether and input data from other nodes. The fee charged is increasing in the complexity of the smart contract due to increase resource/memory on the blockchain. In addition, each interaction, and thus execution, with a contract node requires a fee. Similar to how a lawyer charges a fee for each interaction. Externally owned nodes are the only nodes able to initiate a transaction
The fees are in terms of units of computation called gas, and each unit of gas is worth a fraction of ether. The amount of gas required gives a comparison of the computational resourced needed to perform the transaction. Continuing with our lawyer example, the lawyer spends unit of time, say hours, confirming the details of the wills and charges a dollar amount per hour. The purpose of the gas fee is to make it costly to create inefficiently large or many contracts that clog up the blockchain. Also, miners collect the gas fee since they have to use their computational resources to execute these contracts that they add in each block. As gas is proportional to ether, it also has a fluctuating price.
According to Bitcoinchart, the average fee has been as low as $1.59 and as high as $70.
Stable Coins
Based on current trends, cryptocurrencies seem more synonymous with volatile asset than stable monies. The wild swings in a time series from bitcoin and aforementioned cryptocurrencies are easily discernible. The volatility, while great for investors, unfortunately erodes the desirability of cryptocurrencies as a form of money. As an alternative to restore the desirability of cryptocurrencies as monies, stablecoins have been introduced.
A stablecoin is a cryptocurrency where the value is pegged to a basket of other assets (physical or digital). More simply, ownership of a stablecoin provides the right to exchange it for the underlying asset. This right to exchange is a contract between the issuer of a stablecoin and the current owner. The terms of the smart contract detail the design choice: underlying asset, exchange rate, location of underlying assets. etc.
Insufficient collateral on hand by private issuers of private currencies led to many bank runs in the past \footnote{See the history ( \href{https://www.federalreservehistory.org/essays/banking-panics-of-the-gilded-age}{Here})}. Automatic execution of smart contracts during redemption bypass the need to verify if issuer has the collateral available. However, if assets are physical and outside of the control of the blockchain, there is more nuance and the issuer must be trusted. This is the current model of stablecoins, where fiat currencies are used as the underlying assets. Examples include US Dollar Tether, USD Coin and Binance USD.
Tether is owned by the Bitfinex cryptocurrency exchange. It is pegged to the the US dollar and so it has traded very close to a 1:1 with the dollar. As common with issues of interaction of contracts with the outside world, Tether has been marred by controversy and scandals.
In 2018, Bitfinex claimed that $850 million meant to back consumer deposit was permanently lost and cannot be recovered. In addition, the underlying assets now include loans and other cash equivalent assets. Following that, Tether revised its peg from the ratio from 1 to 0.74. New York state has barred the sale of tether until a proper audit is completed. \footnote{Read more at The Verge ( \href{https://www.theverge.com/22620464/tether-backing-cryptocurrency-stablecoin}{Here})}
Through all this, there was not a bank run and the value of tether has stayed stable. However, their market dominance has decreased when compared to other stable coins. There is a decrease in their market share
Stablecoins provide the most similarity to a commercial bank’s deposit account. This has caught the eye of Central Banks around the world who would like to introduce their own stablecoin.
Central Bank Digital Currencies (CBDC)
The current bank model involves bank notes held by everyone, and digital currency held by private banks. The inclusion of private banks to hold digital currency (reserves with Central Bank) is an unnecessary step for distribution of money through bank deposits, which are the main medium of exchange these days. An alternative model, could allow individuals to hold digital currency directly with central bank. This is the proposal that sparked interest in CBDCs, or digital currencies issued by the central bank.
The implications of CBDCs are widespread for commercial banks and while it is important, it is outside the scope of these notes. Central banks around the world are currently researching and piloting CBDCs \footnote{See the progress of CBDCs (\href{https://cbdctracker.org/}{Here})}.