Introduction
Ethereum is, by far, the most popular blockchain, which it owes not only to its technical attributes but also to its economical and most decentralized attributes. This beautiful machinery boils to numerous mathematical artifacts, laid out in the Yellow Paper, each moving part pertaining to some equation.
My search for explanations of all things mathematical from the Yellow Paper on the internet always resulted articles that dodged the very equations/equivalences and mathematical symbols revolving around them - obscuring the meanings they convey. And I'm not really in enough proximity (physically or digitally) of a Mathematician chad to ask for stuff here and there. Therefore, I'm writing these series of writings to solidify what I already know. And hopefully, along the way, to help you too, anon.
Before you move on, this is not an article focused on describing what Ethereum or EVM is or their constituent mean. Instead, this series is focused on the mathematical artifacts governing the blockchain. Therefore I assume, you already have some knowledge of Ethereum's structure. I assume the terms like - transaction, gas, block, world state, fork, nonce, contract etc. makes sense to you and you have at least some basic knowledge of high-school level set theory.
All said, this will deepen your Ethereum knowledge to the bare bones, so do read anyway :). Alright - let's start with some conventions used in the paper.
Symbols & Conventions
This section might be a great reference for further, subsequent parts of this series. Also, I might probably update it as I proceed.
Following are some mathematical symbols - some of which you might know already but I'm going to put some here for completeness:
denotes equivalence i.e. value on LHS and RHS are equivalent. denotes that an element/variable belongs to a particular set. , denote logical OR and AND operator respectively. These are usually used to constraint the values that can be assigned to components of a tuple. For example, the expression, conveys that " must be in set and must be in set ". denotes universal quantification i.e. for all elements in a set.
Note that the paper, almost everywhere uses equivalence (using
Following are the conventions used for choosing a particular symbol and example below:
Top level state values are bold and lowercase Greek letters:
Function operating on these (top-level) state are uppercase Greek letter:
Specialized and externally defined functions in typewriter text:
Tuples denoted by uppercase letter:
Scalars and fixed size bytes denote by small case letters:
Dynamic length sequences denoted by bold lower case letters:
Last item of a given sequence, e.g. a byte sequence,
where,
Square brackets to index into and reference individual items or subsequences of a sequence:
Other Assumptions:
-
All scalars are non-negative integers. That is, all scalars belong to set
. Similarly set of all byte-sequences is . If the set is constrained to particular subset, it is denoted by subscript: is all non-negative integers less that is set of all byte-sequences of fixed length
-
If unmodified input is denoted by
. Then: : modified/utilizable value , : intermediate values
-
When considering the use of existing functions, given a function
, the denotes similar element-wise version of . Therefore: =
Miscellaneous:
-
A particular set of functions in the paper are denoted by
(e.g. ). These functions are referred as "collapse-functions" in the paper. These are serialization functions that serialize (collapse) multiple constituent values to produce a byte sequence output. The produces this collapsed output mostly by RLP-encoding and/or keccak hashing of constituents of complex entity. For example, given a transaction , the corresponding serialization function is function. operation basically concatenates the transaction components/constituents (type, nonce, gasPrice, to etc.) in particular order in an encoding and dictates what components to include in encoding depending on type of transaction. -
The first block number of a particular fork is specially denoted by
with a subscript name of fork. Below are forks with their first block number:
Another thing to notice is the tags (
And this is it for the pilot of this series. I'm not expecting you to understand exhaustive meaning of everything above, it will be uncovered later. This will however, serve as great reference for the rest of the series.