Kosmo MQP Final Report
Kosmo MQP Final Report
Stephen Kosmo
Abstract
Following the 2008 financial crisis, a new and mostly unstudied technique has
become a central tenet of today’s financial markets: portfolio trade compression.
Trade compression is a service offered by third party vendors that lowers a
bank’s gross notional exposures, while keeping net exposures the same. However,
the effects of compression on systemic risk are unknown. In order to test the
effectiveness of trade compression in risk mitigation, we compare the loss after
default in markets with a variety of structures.
1
Contents
1 Background 4
2 Market Structures 6
2.1 Bilateral Market Model . . . . . . . . . . . . . . . . . . . . . . . 9
2.2 Single Central Clearing Party Model . . . . . . . . . . . . . . . . 10
2.3 Multiple Central Clearing Party Market . . . . . . . . . . . . . . 11
4 Modeling Overview 13
4.1 Compression Models . . . . . . . . . . . . . . . . . . . . . . . . . 14
4.2 Risk Propagation Model . . . . . . . . . . . . . . . . . . . . . . . 16
5 Results 18
6 Conclusions 26
7 References 28
A Proofs 30
A.1 Lemma 1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30
A.2 Theorem 2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30
2
List of Figures
1 A graphical example of compression (from: D’Errico, Roukny) . 5
2 Claimed reductions in counterparty risk exposures after the use
of triReduce on uncleared trades [Source: TriOptima (2017)] . . 6
3 The weighted adjacency matrix for a given market with 10 coun-
terparties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
4 The graph representation of the given adjacency matrix (edge
darkness indicates weight) . . . . . . . . . . . . . . . . . . . . . . 8
5 A centrally cleared version of the market in figure 4 . . . . . . . 10
6 Bilateral IRS market loss after triggering default (title market in
blue, other markets in gray), and the distribution of losses . . . . 20
7 Centrally cleared IRS market Loss after triggering default (title
market in blue, other markets in gray), and the distribution of
results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
8 Bilateral Forex market loss after triggering default (title market
in blue, other markets in gray), and the distribution of losses . . 22
9 Centrally cleared Forex market Loss after triggering default (title
market in blue, other markets in gray), and the distribution of
losses . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
10 Bilateral Credit market loss after triggering default (title market
in blue, other markets in gray), and the distribution of losses . . 24
11 Centrally cleared Credit market Loss after triggering default (title
market in blue, other markets in gray), and the distribution of
losses . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
List of Tables
1 Value lost calculated from risk propagation model in each market.
Average of results from 10,000 market chain (Loss in millions $) 19
2 The difference in average value lost compared to the base (bilat-
eral) market . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
3
1 Background
In financial markets, participants can take additional risks by writing
Over-the-Counter (OTC) derivatives, which come in the form of swaps, for-
wards, futures, and options. These contracts increase profit or loss by betting
on change in an underlying asset. Many experts agree that it was the use of
OTC derivatives that lead to the financial crisis of 2007-2008; large institutions
wrote these OTC derivative contracts to bet against mortgage defaults. The
most notable of these institutions was Lehman Brothers, who leveraged their
assets 44:1 trading credit default swaps. However, the risk associated with these
contracts was not well understood; these institutions thought default was highly
unlikely, and thus looked at the OTC derivative market as virtually risk free.
Unfortunately, this was not the case. In the first quarters of 2008, many people
started to default on mortgage payments, causing Lehman, and many others,
to lose out on their positions. Lehman contacted other lenders, such as Bank
of America and the London based Barclays, looking for a buyout, but no offer
was made. Due to Lehman’s large level of leverage, and the lack of a buyout,
they did not have the physical capital to pay their losses. As a result, Lehman
defaulted, creating huge losses for institutions that held contracts with Lehman.
AIG was one such institution. The lack of payout from Lehman to AIG would
have caused the bankruptcy of AIG. Due to a bailout, this did not happen,
but had AIG not been bailed out, losses would have even further propagated
throughout the system, causing more institutions to default.
In response to the financial crisis that followed, the US passed the Dodd-
Frank act that mandated the clearing of certain OTC derivatives, alongside
many other regulations. This means that institutions trading OTC derivatives
now have to go through a central counterparty (CCP), which keeps various
default safety funds to protect against the kind of leveraging that lead to the
Lehman brothers default. International policy changed as well. For example, the
EU passed EMIR mandating the clearing of various classes of OTC derivatives.
In addition to clearing, banks started applying other risk management prac-
4
tices in the form of portfolio trade compression, a key tool in handling the fallout
from the financial crisis. Due to the use of portfolio compression, Lehman trade
positions were considerably smaller than their gross totals: while cleaning up
trades in October 2008, after the default, CLS Group, a third party middleman
for interbank transactions, processed $5.2 billion in net settlements, correspond-
ing to $72 billion notional amount (London Clearing House, 2012). In addition,
trade compression has gained traction since the financial crisis: TriOptima and
LCH.Clearnet Limited (LCH.Clearnet) compressed out $110 trillion in total no-
tional volume in EUR, JPY, GBP and USD interest rate swaps... using TriOp-
tima’s triReduce since 2008 (TriOptima, 2017). However, while it is clear that
trade compression can significantly reduce market exposure levels, the effect of
trade compression on systemic risk is unclear.
Theoretically, trade compression looks to eliminate chains of trades in a
network.
B B
10 5
5 C 5 D C 5 D
10 5
A A
Ideally, compression would eliminate all such cycles from a network. How-
ever, the complexity of markets often prevents this (D’Errico, 2017). Therefore,
firms offering compression services often use a conservative approach to com-
pression, wherein trades are only removed to a given extent.
Currently, the main provider of trade compression is TriOptima, with over
260 clients globally (TriOptima, 2017). LCH, SwapClear and CLS all have deals
5
with TriOptima to use their service on cleared and settled trades respectively.
TriOptima’s compression service, triReduce, uses a hybrid of conservative and
nonconservative compression, cycling through dealer and client trades and com-
presses trades based on their own constraints, as well as constraints set by cus-
tomers detailing the exposures they are open to taking on (TriOptima, 2017).
According to TriOptima, triReduce has greatly reduced counterparty exposure.
Figure 2 shows the exposure levels (z-axis) between two counterparties (x-axis
and y-axis intersection) before (left) and after (right) applying compression.
Figure 2: Claimed reductions in counterparty risk exposures after the use of triRe-
duce on uncleared trades [Source: TriOptima (2017)]
2 Market Structures
In order to test trade compression, we must model various asset classes of
OTC derivatives. First, we model the bilateral case; to this, we can apply each
6
form of compression, and then central clearing. In a discussion with Roukny,
he stressed that ”the interaction between central clearing and compression is
not well understood”, so the models presented in this paper are a simplified
case where compression is only applied to markets prior to clearing (personal
communication, Oct 30, 2017).
To define the base structure for the markets presented in this paper, we
consider the weighted adjacency matrix of counterparty exposures E. In this
matrix, a given counterparty i has exposures given by the corresponding row i,
where an expected inflow of capital is a positive position, whereas an outflow is
negative. Note then, that this adjacency matrix will be skew-symmetric, as can
be seen in the example matrix given in figure 3.
Figure 3: The weighted adjacency matrix for a given market with 10 counterparties
7
Figure 4: The graph representation of the given adjacency matrix (edge darkness
indicates weight)
n
X n
X
ai = eij li = eji
j=1 j=1
8
and Veraart: first, we sample net notional from a normal distribution, then we
find an initial feasible network, finally, we use Gibbs sampling to converge to
our target distribution (Gandy, 2016). To this bilateral market, we can apply
central clearing. For central clearing, we define two models: a market with a
single central clearing party, and a market with multiple central clearing parties.
The following sections outline the exact methodologies used.
n
X
gi = |eij |.
j=1
and liabilities e−
i values as
gi + ai gi − ai
e+
i = e−
i = .
2 2
−
Note that e+
i and ei are vectors containing the positive and negative values
−
of ei , respectively. Thus ei = e+
i − ei . However, to compute this, we need to
estimate ai , as the net asset data is not available. To do this, we must define
an initial feasible network. First, we define an Erdös-Rényi graph, using assets
and liabilities to constrain the market. We then apply the Edmonds-Karp max
flow algorithm to this graph. Now we have our initial feasible network. Finally,
we use Gibbs sampling, a type of Monte Carlo Markov Chain, on the initial
network to build a chain of networks that converge to the assumed distribution
of our market.
9
2.2 Single Central Clearing Party Model
10
2.3 Multiple Central Clearing Party Market
In real world markets, there are often more than one CCP for a single
type of derivative asset class. Thus, we will look into adding multiple CCPs to
a market with and without the various types of compression.
Similar to the single CCP case, the multi-CCP case is a restructuring of the
original market. In this case, we create an (n+c)×(n+c) matrix, where c is the
number of CCPs in the market. Now we populate the entries in the first c rows.
To get the first c entries in column i, we sum the entries of column (i − c) in
the original matrix, with the first c entries in the new matrix being zero. Note
that this sum is equal to the exposure between i and a single CCP. In this case,
we take this exposure, and scale it by the proportion i is exposed to each CCP,
i.e. we distribute the net exposure of i among each CCP. Each entry is then the
given proportion of the total sum for column i − c. We do likewise for the rows.
The first c entries of a given row i, are the sum of row (i − c) in the original
matrix. Then a normal distribution is sampled, and the c entries are populated
with the given proportion of the row sum. The rest of the matrix is populated
with zeros.
(note that at least one inequality must be strict). Thus compression keeps
net positions, or assets, constant, and reconfigures edges such that the gross
position is decreased for at least one counterparty. In order to optimally apply
compression to a market, we will further define the market itself; in a market, a
11
counterparty is defined as a dealer if they are both buying and selling, otherwise
they are defined as a customer. A market can be partitioned into two subsets,
Gd and Gc where Gd = (N, E d ), Gc = (N, E c ), E d ∩ E c = ∅ and E d ∪ E c = E.
In order to analyze the efficiency of various methods of compression, we
compare the decrease in the value of positive trades. Note that this decrease
is bounded by the net positions for each counterparty. The difference between
the value of positive trades and net value for each counterparty is defined as the
excess. Thus, for a given market G, the excess ∆(G) is defined as
P P Pn
i∈N j∈N |eij | − j=1 |eij |
∆(G) = .
2
12
counterparties. Therefore, the efficiency of each operation, defined by the re-
duction in excess, is as follows:
4 Modeling Overview
In this section, we will outline the exact models for compression and
risk analysis in the aforementioned market structures. For our trade compres-
sion algorithms, we will implement non-conservative, hybrid, and conservative
compression. For conservative and hybrid compression, we will be using the
network simplex method, as outlined in D’Errico and Roukny. The network
simplex is simply a minimum-flow algorithm. In this case, we define node po-
sitions and trade bounds to constrain the network, then we apply the network
simplex to find the minimum flow that allows for our network to be feasible.
Non-conservative compression will use L1 matrix minimization as an equivalent
algorithm to network compression.
To measure risk levels in each market structure, we will apply the interbank
contagion model proposed in Eisenberg and Noe. As this model simulates de-
fault at a single counterparty, the model will be applied to each counterparty
in the market, and the average risk will be calculated over all cases. We simu-
late a trigger at each node individually with a shock. For simplicity, the shock
will completely wipe out the triggering counterparty. As the relation between
clearing and compression is not well understood, any CCPs in the market will
be ignored in the triggering step, and will be regarded as unable to default.
To check if a bank defaults, we look to their reserve levels to see if there
13
is sufficient capital to avoid a default. Reserve levels are taken from Federal
Reserve data on the top 25 U.S. banks. To calculate reserves, we take the
consolidated assets, normalize to find the ratio of assets for each bank, and then
multiply by the total level of net assets for all U.S. banks.
In the CCP case, we assume ”cover two” default model, where each CCP
holds enough in reserve to cover the larger of either the largest exposure, or
the sum of the second two largest exposures. In addition, we add a buffer to
account for surplus reserve levels.
14
for non-conservative compression. In this paper, we propose the use of L1 matrix
minimization as a form of non-conservative compression.
n
X n
X
ai = eij = eij = −li .
j=1 j=1
In addition to always finding a feasible solution, we will now prove that the
solution to L1 minimization is a form of non-conservative compression.
Proof. If every institution has either positive or negative trades, they are ei-
ther only buying or only selling. By definition, this makes every institution a
customer.
15
Corollary. Minimizing the L1 norm of the adjacency matrix E of a market
eliminates all excess in the underlying market
Proof. Any market where all participants are customers has 0 excess (D’Errico,
2017). Thus, as L1 minimization results in a market with only customers, it
eliminates all excess.
Thus E 1 now represents the total amount traded after taking into account the
default of i. We also define r1 as:
/ Γ1
r(i) i ∈
r1 = .
0 i ∈ Γ1
16
Now, to determine if this causes j to default, we calculate p1j , the net position
of j:
X
p1j = rj1 + e1kj .
k∈N
Continue the above until no new counterparties default, we will call this step ∗.
At this point either all counterparties have defaulted, or the parties remaining
are resistant to default.
Now we calculate the loss of value due to the default of the triggering coun-
terparty i:
X X
V Li = (rj − rj∗ ) + (eij − e∗ij ).
j∈N i,j
This takes into account the loss to capital reserves, as well as value lost on assets
traded. After repeat the above algorithm for all i. Now we compute the average
value lost as follows:
N
1 X
L= V Li .
N i=1
17
5 Results
The data used in the base bilateral market model are the gross notional
amounts from the fourth quarter of 2016 for the top 25 commercial banks,
savings associations, and trust companies in the United States (Comptroller,
2017). This data contains the gross notional for three asset classes: Interest
Rate Swaps, Foreign Exchange, and Credit Derivatives. In addition, the surplus
reverse for the CCP case were calculated using EU stress tests data; the average
CCP held a 13% surplus on required capital, thus each CCP’s reserve levels
have a multiplier of 1.13 (ESMA, 2018).
Using the aforementioned gross notional data with the bilateral market
model, we create a chain of 10,000 bilateral trading networks for each asset
class. For the Gibbs sampling, we want the output to start when the data
has already converged, thus we define a burn-in period of 1,000,000 samples.
Furthermore, we do not want successive markets to be correlated, so we thin
the data by sampling between each market. The thinning step used was 10,000
samples, to ensure little correlation between subsequent markets in the chain.
For each market in the aforementioned chain, we apply conservative, hy-
brid, and non-conservative compression algorithms, resulting in three additional
chains, one for each compression method. Then, for each market in each chain,
we restructure the market to account for all CCPs in the given asset class, re-
sulting in a four additional chains. Thus, for each of the three asset class used,
we are left with eight chains: four bilateral, and four cleared. We apply the risk
propagation model to each network in all 24 chains. Table 1 shows the average
result for each chain.
18
Table 1: Value lost calculated from risk propagation model in each market. Average
of results from 10,000 market chain (Loss in millions $)
IRS FX Credit
Compression Method Bilateral Cleared Bilateral Cleared Bilateral Cleared
Base Market 3,441.92 1,638.32 1,365.75 496.49 675.77 278.57
Conservative 3,282.71 1,638.32 1,222.33 496.49 614.13 278.57
Hybrid 1,719.35 1,638.32 592.06 496.49 360.48 278.57
Non-conservative 1,687.42 1,638.32 588.31 496.49 341.85 278.57
The graphs in figures 6 through 11 show the risk results for each of the 10,000
networks in a given chain. The averages shown in table 1 were calculated using
the data in figures 6 through 11.
19
Figure 6: Bilateral IRS market loss after triggering default (title market in blue,
other markets in gray), and the distribution of losses
20
Figure 7: Centrally cleared IRS market Loss after triggering default (title market in
blue, other markets in gray), and the distribution of results
21
Figure 8: Bilateral Forex market loss after triggering default (title market in blue,
other markets in gray), and the distribution of losses
22
Figure 9: Centrally cleared Forex market Loss after triggering default (title market
in blue, other markets in gray), and the distribution of losses
23
Figure 10: Bilateral Credit market loss after triggering default (title market in blue,
other markets in gray), and the distribution of losses
24
Figure 11: Centrally cleared Credit market Loss after triggering default (title market
in blue, other markets in gray), and the distribution of losses
25
6 Conclusions
For each asset class, compression had no effect on the loss in the cleared
market. Thus, it is apparent that compression does not make a difference in
cleared markets. A possible explanation for this could be that central clearing
results in a restructuring of the market based on net positions. As compression
does not change net positions, it is obvious that compression will not change
the structure of a market after clearing. In addition, the model used did not
take into account cross-asset class netting, and the data is a ”snapshot” of the
market where time to maturity is disregarded. The effects of either of these
cases on results is unknown.
In all three asset classes, we see similar levels of reduction in loss for bi-
lateral, compression, and clearing. Furthermore, between the different types of
compression, we again see similar levels of reduction for conservative, hybrid,
and non-conservative methods. Table 3 shows these differences in relation to
the level of loss seen in the bilateral market. Note that central clearing is gen-
eralized to a single case for each asset class, as compression did not effect the
value lost.
Table 2: The difference in average value lost compared to the base (bilateral) market
26
pression, on the other hand, is always possible, and reduces gross positions by
as much as possible, thus, we see more of a difference between non-conservative
and the bilateral market.
Interestingly, hybrid compression offered a reduction similar to non-conservative.
There are several possible explanations for this. First, it is possible that the
simulated markets did not have many customers, and thus hybrid compression
mostly dealt with non-conservative compression over many dealers. Another
possibility is dealer exposures are more important than client exposures, and
thus the non-conservative compression over dealers was key to preventing de-
fault. The data do not strongly support either case, as most markets average a
50/50 split between dealers and customer.
As all forms of compression reduced value lost compared to the base market,
with non-conservative resulting in a reduction comparable to clearing, we con-
clude that a reduction in exposure may correlate with a reduction in default risk.
Additionally, as cleared markets had equal loss over all forms of compression,
it would seem that compression is not necessary in those markets. However,
the interaction between compression and clearing is not well understood. Real
world markets are far more complex than the models used, and the addition of
model complexity in the form of cross-asset netting or time to maturity might
have effects on value lost, but this is not in the scope of this project.
27
7 References
1. Culp, Christopher L.(2010). OTC-Cleared Derivatives: Benefits, Costs,
and Implications of the Dodd-Frank Wall Street Reform and Consumer
Protection Act. Journal of Applied Finance, 1 (2) Available at http:
//www.rmcsinc.com/articles/OTCCleared.pdf
28
9. TriOptima. (2017). triReduce Portfolio Compression Fact-sheet. Avail-
able at https://www.trioptima.com/media/filer_public/31/f1/31f1\
4682-5137-4ef1-80af-e8bb09835dce/trireduce_general_factsheet.
pdf
29
A Proofs
A.1 Lemma 1
Proof. Let E be an L1 minimal matrix such that row r has values era > 0 and
erb < 0. Then
X
|E|1 = |eij | ≥ |era | + |erb |
i,j∈N
but for row r, ar = era + erb < |era | + |erb |. Thus we have
X
|E|1 > |ai |
i∈N
However, ai is the lower bound for each row i, so |E|1 is greater than the
minimum bound, meaning E is not L1 minimal, and we have a contradiction.
Thus, if E is L1 minimal, then eij = 0, or sgn(eij ) = sgn(ai ) and sgn(eij ) =
sgn(gj ) ∀i, j ∈ N .
A.2 Theorem 2
Proof. Let E be the adjacency matrix associated with a given market, and a
the vector of assets. If a = ~0, then E can be redefined as a matrix of 0s and we
are done. If a 6= ~0, then there exists an ai in a such that ai 6= 0. We know that
X
ai = 0
i∈N
Thus there exists some aj ≤ −ai . Now we partition the vector a into a+ =
{ai ∈ a|ai < 0}, and a− = {ai ∈ a|ai > 0}. Similarly we partition l into
−
l+ = {li ∈ l|li < 0}, and l− = {li ∈ l|li > 0}. Note that a+
i = −li and
a− +
i = −li for all i in N .
30
we know there exists j such that aj ≤ −ai we find other entries in l to populate
the rest of the row similarly. Now let another row in a+ be given. This row can
be populated similarly, with the exception that now lc is bounded by lc − ar .
Continue this for all rows in l+ . As we have not used negative values yet, the
same operation can work for all rows in a− . Finally, for any rows not in a+ or
a− , the value of ai here is clearly 0, and thus the row can be populated with 0.
By definition, our constructed E ∗ contains only values that pass the optimality
check in lemma 1. As E ∗ was defined using an arbitrary matrix E, it is always
possible to compress a network to be L1 minimal.
31
B Pseudocode for Algorithms
B.1 Network Simplex
32
B.3 Risk Propagation
33