Contagion in Bitcoin networks
C\'elestin Coquid\'e, Jos\'e Lages, and Dima L. Shepelyansky

TL;DR
This paper models contagion in Bitcoin networks using Google matrices, revealing a phase transition in user bankruptcy risk related to trade balance thresholds and highlighting the vulnerability of top-ranked users due to their interconnectedness.
Contribution
It introduces a novel application of Google matrix analysis to Bitcoin transaction networks, modeling contagion and bankruptcy thresholds in a large-scale real-world financial network.
Findings
Phase transition at trade balance threshold κ_c≈0.1
Top PageRank users are highly interconnected and vulnerable
Most users remain safe when κ>0.55
Abstract
We construct the Google matrices of bitcoin transactions for all year quarters during the period of January 11, 2009 till April 10, 2013. During the last quarters the network size contains about 6 million users (nodes) with about 150 million transactions. From PageRank and CheiRank probabilities, analogous to trade import and export, we determine the dimensionless trade balance of each user and model the contagion propagation on the network assuming that a user goes bankrupt if its balance exceeds a certain dimensionless threshold . We find that the phase transition takes place for with almost all users going bankrupt. For almost all users remain safe. We find that even on a distance from the critical threshold the top PageRank and CheiRank users, as a house of cards, rapidly drop to the bankruptcy. We attribute this effect to…
| Network | Network | Network | ||||||
|---|---|---|---|---|---|---|---|---|
| BC10Q3 | 37818 | 57437 | BC11Q3 | 1546877 | 2857232 | BC12Q3 | 3742174 | 8381654 |
| BC10Q4 | 70987 | 111015 | BC11Q4 | 1884918 | 3635927 | BC12Q4 | 4671604 | 11258315 |
| BC11Q1 | 204398 | 333268 | BC12Q1 | 2186107 | 4395611 | BC13Q1 | 5997717 | 15205087 |
| BC11Q2 | 696948 | 1328505 | BC12Q2 | 2645039 | 5655802 | BC13Q2 | 6297009 | 16056427 |
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
11institutetext: Institut UTINAM, OSU THETA, Université de Bourgogne Franche-Comté, CNRS, Besançon, France
11email: {celestin.coquide,jose.lages}@utinam.cnrs.fr
22institutetext: Laboratoire de Physique Théorique, IRSAMC, Université de Toulouse, CNRS, UPS, 31062 Toulouse, France
22email: [email protected]
Contagion in Bitcoin networks
Célestin Coquidé 11
José Lages 11
Dima L. Shepelyansky 22
Abstract
We construct the Google matrices of bitcoin transactions for all year quarters during the period of January 11, 2009 till April 10, 2013. During the last quarters the network size contains about 6 million users (nodes) with about 150 million transactions. From PageRank and CheiRank probabilities, analogous to trade import and export, we determine the dimensionless trade balance of each user and model the contagion propagation on the network assuming that a user goes bankrupt if its balance exceeds a certain dimensionless threshold . We find that the phase transition takes place for with almost all users going bankrupt. For almost all users remain safe. We find that even on a distance from the critical threshold the top PageRank and CheiRank users, as a house of cards, rapidly drop to the bankruptcy. We attribute this effect to strong interconnections between these top users which we determine with the reduced Google matrix algorithm. This algorithm allows to establish efficiently the direct and indirect interactions between top PageRank users. We argue that this study models the contagion on real financial networks.
Keywords:
Markov chains Google matrix Financial networks.
1 Introduction
The financial crisis of 2007-2008 produced an enormous impact on financial, social and political levels for many world countries (see e.g. [1, 2]). After this crisis the importance of contagion in financial networks gained a practical importance and generated serious academic research with various models proposed for the description of this phenomenon (see e.g. Reviews [3, 4]). The interbank contagion is of especial interest due to possible vulnerability of banks during periods of crisis (see e.g. [5, 6]). The bank networks have relatively small size with about bank units (nodes) for the whole US Federal Reserve [7] and about for bank units of Germany [8]. However, the access to these bank networks is highly protected that makes essentially forbidden any academic research of real bank networks.
However, at present the transactions in cryptocurrency are open to public and the analysis of the related networks are accessible for academic research. The first cryptocurrency is bitcoin launched in 2008 [9]. The first steps in the network analysis of bitcoin transactions are reported in [10, 11] and overview of bitcoin system development is given in [12]. The Google matrix analysis of the bitcoin network (BCN) has been pushed forward in [13] demonstrating that the main part of wealth of the network is captured by a small fraction of users. The Google matrix describes the Markov transitions on directed networks and is at the foundations of Google search engine [14, 15]. It finds also useful applications for variety of directed networks describe in [16]. The ranking of network nodes is based on the PageRank and CheiRank probabilities of matrix which are on average proportional to the number of ingoing and outgoing links being similar to import and export in the world trade network [17, 18]. We use these probabilities to determine the balance of each user (node) of bitcoin network and model the contagion of users using the real data of bitcoin transactions from January 11, 2009 till April 10, 2013. We also analyze the direct and hidden (indirect) links between top PageRank users of BCN using the recently developed reduced Google matrix (REGOMAX) algorithm [19, 20, 21, 22].
2 Datasets, algorithms and methods
We use the bitcoin transaction data described in [13]. However, there the network was constructed from the transactions performed from the very beginning till a given moment of time (bounded by April 2013). Instead, here we construct the network only for time slices formed by quarters of calendar year. Thus we obtain 12 networks with users and directed links for each quarter given in Table 1. We present our main results for BC13Q1.
The Google matrix of BCN is constructed in the standard way as it is described in detail in [13]. Thus all bitcoin transactions from a given user (node) to other users are normalized to unity, the columns of dangling nodes with zero transactions are replaced by a column with all elements being . This forms matrix of Markov transitions which is multiplied by the damping factor so that finally where the matrix has all elements being unity. We also construct the matrix for the inverted direction of transactions and then following the above procedure for . The PageRank vector is the right eigenvector of , , with the largest eigenvalue (). Each component with is positive and gives the probability to find a random surfer at the given node (user ). In a similar way the CheiRank vector is defined as the right eigenvector of with eigenvalue , i.e., . Each component of gives the CheiRank probability to find a random surfer on the given node (user ) of the network with inverted direction of links (see [16, 23]). We order all users by decreasing PageRank probability . We define the PageRank index such as we assign to user with the maximal , then we assign to the user with the second most important PageRank probability, and so on …, we assign to the user with the lowest PageRank probability. Similarly we define the CheiRank indexes using CheiRank probabilities . () is assigned to user with the maximal (minimal) CheiRank probability.
The reduced Google matrix is constructed for a selected subset of nodes. The construction is based on methods of scattering theory used in different fields including mesoscopic and nuclear physics, and quantum chaos. It describes, in a matrix of size , the full contribution of direct and indirect pathways, happening in the global network of nodes, between selected nodes of interest. The PageRank probabilities of the nodes are the same as for the global network with nodes, up to a constant factor taking into account that the sum of PageRank probabilities over nodes is unity. The -element of can be viewed as the probability for a random seller (surfer) starting at node to arrive in node using direct and indirect interactions. Indirect interactions describes pathways composed in part of nodes different from the ones of interest. The computation steps of offer a decomposition into matrices that clearly distinguish direct from indirect interactions, [20]. Here is generated by the direct links between selected nodes in the global matrix with nodes. The matrix is usually rather close to the matrix in which each column is given by the PageRank vector . Due to that does not bring much information about direct and indirect links between selected nodes. The interesting role is played by . It takes into account all indirect links between selected nodes appearing due to multiple pathways via the global network nodes (see [19, 20]). The matrix has diagonal () and non-diagonal () parts where describes indirect interactions between nodes. The explicit mathematical formulas and numerical computation methods of all three matrix components of are given in [19, 20, 21, 22].
Following [18, 21, 22], we remind that the PageRank (CheiRank) probability of a user is related to its ability to buy (sell) bitcoins, we therefore determine the balance of a given user as . We consider that a user goes to bankruptcy if . If it is the case the user ingoing flow of bitcoins is stopped. This is analogous to the world trade case when countries with unbalanced trade stop their import in case of crisis [17, 18]. Here has the meaning of bankruptcy or crisis threshold. Thus the contagion model is defined as follows: at iteration , the PageRank and CheiRank probabilities are computed taking into account that all ingoing bitcoin transactions to users went to bankruptcy at previous iterations are stopped (i.e., these transactions are set to zero). Using these new PageRank and CheiRank probabilities we compute again the balance of each user, determining which additional users went to bankruptcy at iteration . Initially at the first iteration, , PageRank and CheiRank probabilities and thus user balances are computed using the Google matrices and constructed from the global network of bitcoin transactions (a priori no bankrupted users). A user who went bankrupt remains in bankruptcy at all future iterations. In this way we obtain the fraction, , of users in bankruptcy or in crisis at different iteration times .
3 Results
The PageRank and CheiRank algorithms have been applied to the bitcoin networks BCyyQq presented in Tab. 1. An illustration showing the rank of the twenty most present users in the top 100s of these bitcoin networks is given in Fig. 1. We observe that the most present user (#1 in Fig. 1) was, from the third quarter of 2011 to the fourth quarter of 2012, at the very top positions of both the PageRank ranking and of the CheiRank ranking. Consequently, this user was very central in the corresponding bitcoin networks with a very influential activity of bitcoin seller and buyer. Excepting the case of the most present user (#1 in Fig. 1), the other users are (depending of the year quarter considered) either top sellers (well ranked according to CheiRank algorithm, ) or top buyers of bitcoins (well ranked according to PageRank algorithm, ). In other words excepting the first column associated to user #1 there is almost no overlap between left and right panels of Fig. 1.
From now on we concentrate our study on the BC13Q1 network. For this bitcoin network, the density of users on the PageRank-CheiRank plane is shown in Fig. 2a. At low , users are centered near the diagonal that corresponds to the fact that on average users try to keep balance between ingoing and outgoing bitcoin flows. Similar effect has been seen also for world trade networks [17].
The dependence of the fraction of bankrupt users on the bankruptcy threshold is shown in Fig. 2b at different iterations . At low almost 100% of users went bankrupt at large .
Indeed, Fig. 3 shows that the transition to bankruptcy is similar to a phase transition so that at large we have for , in the range there are only about – of users in bankrupcy while for almost all users remain safe at large times.
The distribution of bankrupt and safe users on PageRank–CheiRank plane is shown in Fig. 4 at different iteration times . For crisis thresholds and , we see that very quickly users at top indexes go bankrupt and with growth of more and more users go bankrupt even if they are located below the diagonal thus having initially positive balance . However, the links with other users lead to propagation of contagion so that even below the diagonal many users turn to bankruptcy. This features are similar for and but of course the number of safe users is larger for . For a crisis threshold , the picture is stable at every iterations , the contagion is very moderate and concerns only the white region comprising roughly the same number of safe and bankrupt users. This white region broadens moderately as increases. We note that even some of the users above remain safe. We observe also that for about a third of top users remain safe.
Fig. 5 presents the integrated fraction, , of users which have a PageRank index below or equal to and which went bankrupt at . We define in a similar manner the integrated fraction of CheiRank users being bankrupts. From Fig. 5 we observe and . Formal fits of the data in the range give for and for . Formal fits of the data in the range give for and for .
The results of contagion modeling show that PageRank and CheiRank top users enter in contagion phase very rapidly. We suppose that this happens due to strong interlinks existing between these users. Thus it is interesting to see what are the effective links and interactions between these top PageRank and top CheiRank users. With this aim we construct the reduced Google matrix for the top 20 PageRank users of BC13Q1 network. This matrix and its three components , and are shown in Fig. 6. We characterize each matrix component by its weight defined as the sum of all matrix elements divided by . By definition the weight of is . The weights of all components are given in the caption of Fig. 6. We see that has the weight of about 50% while and have the weight of about 25%. These values are significantly higher comparing to the cases of Wikipedia networks (see e.g. [20]). The matrix component (Fig. 6 bottom left panel) is similar to the bitcoin mass transfer matrix [13] and the -element of is related to direct bitcoin transfer from user to user . As , the PageRank top20 users directly transfer among them on average about of the total of bitcoins exchanged by these users. In particular, about of the bitcoin transfers from users and are directed toward user . Also user buy about of the bitcoins sold by user . We observe a closed loop between users and which highlights between them an active bitcoin trade during the period 2013 Q1. Also of bitcoins transferred from user were bought buy user . The reduced Google matrix (Fig. 6 top left panel) gives a synthetic picture of bitcoin direct and indirect transactions taking into account direct transactions between the users encoded in the global Google matrix . We clearly see that many bitcoin transfers converge toward user since this user is the most central in the bitcoin network. Although the matrix component indicates that user obtains about to of the bitcoins transferred from its direct partners, the matrix component indicates that indirectly the effective amount transferred from direct and indirect partners are greater about to more than . In particular, although no direct transfer exists from users and to user , about of the bitcoins transferred in the network from users and converge indirectly to user . Looking at the diagonal of the matrix we observe that about of the transferred bitcoins from user returns effectively to user , the same happen, e.g, with user and user with about of transferred bitcoins going back. The matrix component (Fig. 6 bottom right panel) gives the interesting picture of hidden bitcoin transactions, i.e., transactions which are not encoded in the matrix component since they are not direct transactions, and which are not captured by the matrix component as they do not necessarily involve transaction paths with the most central users. Here we clearly observe that of the total transferred bitcoins from user converge indirectly toward user . We note that this indirect transfer is the result of many indirect transaction pathways involving many users other than the PageRank top20 users. We observe also a closed loop of hidden transactions between users and .
4 Discussion
We performed the Google matrix analysis of Bitcoin networks for transactions from the very start of bitcoins till April 10, 2013. The transactions are divided by year quarters and the Google matrix is constructed for each quarter. We present the results for the first quarter of 2013 being typical for other quarters of 2011, 2012. We determine the PageRank and CheiRank vectors of the Google matrices of direct and inverted bitcoin flows. These probabilities characterize import (PageRank) and export (CheiRank) exchange flows for each user (node) of the network. In this way we obtain the dimensionless balance of each user () and model the contagion propagation on the network assuming that a user goes bankrupt if its dimensional balance exceeds a certain bankruptcy threshold (). We find that the phase transition takes place in a vicinity of the critical threshold below which almost 100% of users become bankrupts. For almost all users remain safe and for about 60% of users go bankrupt. It is interesting that, as house of cards, the almost all top PageRank and Cheirank users rapidly drop to bankruptcy even for being not very close to the critical threshold . We attribute this effect to strong interconnectivity between top users that makes them very vulnerable. Using the reduced Google matrix algorithm we determine the effective direct and indirect interactions between the top 20 PageRank users that shows their preferable interlinks including the long pathways via the global network of almost 6 million size.
We argue that the obtained results model the real situation of contagion propagation of the financial and interbank networks.
Acknowledgments: We thank L.Ermann for useful discussions. This work was supported by the French “Investissements d’Avenir” program, project ISITE-BFC (contract ANR-15-IDEX-0003) and by the Bourgogne Franche-Comté Region 2017-2020 APEX project (conventions 2017Y-06426, 2017Y-06413, 2017Y-07534; see http://perso.utinam.cnrs.fr/~lages/apex/). The research of DLS is supported in part by the Programme Investissements d’Avenir ANR-11-IDEX-0002-02, reference ANR-10-LABX-0037-NEXT France (project THETRACOM).
The reference list from the paper itself. Each links out to its DOI / PubMed record.
- 1[1] Financial crisis of 2007 - 2008 , https://en.wikipedia.org/w/index.php?title=Financial_crisis_of_2007%E 2%80%932008&oldid=882711856 (Accessed April (2019)).
- 2[2] Three weeks that changed the world , The Guardian Dec 27 (2008), https://www.theguardian.com/business/2008/dec/28/markets-credit-crunch-banking-2008 (Accessed April (2019)).
- 3[3] Gai P. and Kapadia S.: Contagion in financial networks , Proc. R. Soc. A 466 , 2401 (2010). \doi 10.1098/rspa.2009.0410
- 4[4] Elliott M., Golub B. and Jackson M.: Financial networks and contagion , Am. Econ, Rev. 104(10) , 3115 (2014). \doi 10.1257/aer.104.10.3115
- 5[5] Anand K., Craig B. and von Peter G.: Filling in the blanks: network structure and interbank contagion , Quantitative Finance 15(4) m 625 (2015). \doi 10.1080/14697688.2014.968195
- 6[6] Fink K., Kruger U., Meller B. and Wong L.-H.: The credit quality channel: modeling contagion in the interbank market , J. Fin. Stab. 25 , 83 (2016). \doi 10.1016/j.jfs.2016.06.002
- 7[7] Soramaki K., Bech M.L., Arnold J., Glass R.J. and Beyeler W.E.: The topology of interbank payment flows , Physica A 379 , 317 (2007). \doi 10.1016/j.physa.2006.11.093
- 8[8] Craig B. and von Peter G.: Interbank tiering and money center banks , J. Finan. Intermediation 23(3) , 322 (2014). \doi 10.1016/j.jfi.2014.02.003
