title | author | classoption |
---|---|---|
Atomic Finance |
Keith A. Lewis |
fleqn |
\newcommand\ZZ{\bm{Z}}
There is an inevitable trajectory in the financial world toward more data, faster calculations, and increasing complexity.
The atoms of finance are holdings: an amount, instrument, and the owner of the holding. Holding an instrument often entails auxiliary cash flows for the owner. A buyer can exchange the amount and instrument of their holding with that of a seller. The price of the exchange is the ratio of buyer amount to seller amount. A portfolio is a collection of holdings. Portfolios evolve over time via exchanges. A transaction is a collection of associated exchanges.
Let
Let
For example, if a buyer holds 8 dollars and a seller holds 2 shares of
Ford stock and quotes a price of 4 dollars per share then the buyer can
acquire two shares of F for
A portfolio is a collection of holdings. Exchanges act on portfolios.
A portfolio
A transaction is a set of related exchanges, for example an exchange may involve a broker fee or tax payment.
Given a portfolio the value of instrument
The mark-to-market of a position in a cash numeraire
Mathematics allows you to think big. We can let
It is quite common for owners to have different best guesses of
Holdings are stored in a relational table with columns Id
, Amount
,
Instrument
, and Owner
. The Id
is a unique identifier that includes
the time the holding was entered. (E.g., UUID Version-4 or Time-First.)
The Amount
is an signed integer value indicating the multiple of the
minimum trading increment of the Instrument
. The Owner
can be more
refined than, e.g., a Legal Entity Identifier. Legal entities have
subgroups and even individual employees associated with a holdings.
A unique identifier including the time a holding was inserted into the Holdings table.
Integral multiple of smalled instrument trading unit. 64-bit signed integer. 32-bit is too small.
This can be more refined than a stock ticker or CUSIP. For example, a stock might trade on multiple exchanges. CUSIPs can be reused so this should be taken into account.
LEI is too coarse. Need to subdivide into groups or even employee. This requires a slowly time-varying auxiliary table.
If it is complicated, it is wrong.
Can we make it a function? (Easier to reason about.)