Keywords

1 Introduction

Agent-based method is a rather new approach in economics and finance, as we reach the point where computation capacity and behavioral economics have developed strongly enough to be used in practical applications. This method has a clear advantage in building better models to represent our realistic, finite, imperfect decision-making human-beings society, since agents in such models are not required to behave perfectly rationally as in traditional research. Better insight of fundamental patterns in the market is achieved by observing results of interaction between numerous agents.

Related to inter-bank system, there are a few studies using an agent-based approach. However, most of studies of Vietnamese banking network are qualitative and have not provided interaction mechanism. This article, therefore, aims to offer an advanced approach which combines financial knowledge, mathematical modeling and computation to build a full-scale agent-based model (ABM) to represent Vietnam’s banking system. The network is comprised of 19 banks whose available data is adequate to construct such a model. Rules for lending and borrowing between banks are agent-driven and based on banks’ historical balance sheets and general behavior pattern from practical findings.

Unfortunately, due to data insufficiency, it is not the intention of this article to construct a real Vietnamese market, but it is to make a tool to simulate and study the development of inter-bank network under various circumstances, to gain insight into the questions: how different kinds of shock affect the whole system? More specifically, how default of a particular bank affects other banks and the system; how default of multiple banks affects the system; and how system shock affects the system? Whether the topology of banking system affects its resilience and how?

The first contribution of this article is to introduce the mechanism of inter-bank activities based on banks’ balance sheets, in which banks can form new relationship and reform the network. Several approaches to build the full network are also provided. The article makes a second contribution by testing the network under a number of shocks to examine its resilience and role of inter-bank network on contagion effect. The third contribution is to provide a tool for the regulators to interact with the model, change parameters and test effects of new policies.

The article is structured as follows. Section 2 reviews current literature related to inter-bank network, associated risks, contagions, and agent based approach. Section 3 discusses methods to extrapolate inter-bank matrix - one of the most important inputs of the model from raw data. Section 4 provides model experiments. Section 5 presents the results. Finally, the article concludes in Sect. 6 by assessing the results and the methodology’s contribution.

2 Literature Review

This section provides overview on three key aspects of modeling interconnections in a banking system: (1) credit risk and contagion (2) inter-bank network structure (3) agent-based modeling applied in inter-bank market.

2.1 Credit Risk and Contagion

Credit risk can be defined as a risk of changes in the value that is associated with unexpected changes in the credit quality of other counter-parties; see, e.g., [35]. Banks are particularly vulnerable to this kind of risk, as their main function is to receive money and make loans to other parties.

Two approaches that are often applied in early studies are structural and reduced-form models. The former explicitly modeled assets of banks as dynamic time series and assumed that default occurs when asset value decreased below a threshold [32]. The latter modeled a company’s time to default as a stochastic process with parameters acquired from historical data.

However, despite their complexity, these models were criticized for not being able to predict financial turmoils. A major critique was that they failed to evaluate the market as a complex system with large-number of heterogeneous entities interacting and affecting each other. This is particularly true for inter-bank market where banks interlace each others through links created from their inter-bank exposures.

Research on spread of contagion (see, e.g., [1, 2, 5, 25]) had identified the role of connectivity and network topology in systemic risk. Increasing connectivity made network less affected by systemic risk thanks to risk sharing mechanism. However, too high connectivity can lead to a crisis especially in the presence of high magnitude shocks as the trigger. In this case, linkages between banks became propagation channels for contagion and a source of systemic risk. This could in turn significantly froze the economy, as firms (even firms with high credibility) could not obtain capital to finance their projects. Currently, there are not many studies on the formation of banking network, as well as changes of this network after shocks like occurrences of defaults or introduction of new policies happen. Fortunately this trend is attracting more researchers and some progress can be seen in this direction. Some early research focused on agents’ decisions to balance costs and benefits of maintaining and forming links with other agents (see, e.g., [4]). More recent works have paid attention to the impact of network formation to systemic risk (see, e.g., [1]), whereas [21] used features of agent trading decisions to form a network.

2.2 Inter-bank Network Structure

The first challenge to be overcome before testing the resilience of the network using agent-based approach is to reproduce full inter-bank exposures. Contagions and system risks spread through the inter-bank network, which is represented by lending and borrowing matrix of all banks in the network. This matrix is unobserved since banks do not public detailed information of inter-bank loans. Available data is just the total of inter-bank lending and borrowing of a particular bank in the network. Therefore, several methods to estimate the network has been developed, that can be named: Maximum Entropy (ME) method, Minimum Density (MD) method and agent-based simulation method.

The Maximum Entropy is the most popular one, which was based on the assumption that banks diversified their exposures by spreading borrowing and lending across all other banks in the network; see, e.g., [38]. This approach created a complete dense network; see, e.g., [11].

The Minimum Density adopted an opposite approach in that the network is built minimizing the number of linkages in while satisfying other constraints; see, e.g., [3]. It was based on the real fact that banks tended to lend or borrow other banks it had relationship with. This was to minimize the cost of inter-bank linkage. This approach created a sparse network.

Other approaches tried to create a mechanism to simulate banks’ business and assumed banks follow rules, such as determining their lending-borrowing structure by maximizing profit and minimizing risk associated. For example, [10] offered Nash equilibrium of networks maximizing the investors’ payoff which depended on the inter-bank neighborhood of banks in which an investor allocated their fund. [22] proposed a portfolio optimization model, whereby banks allocated their inter-bank exposures while balancing the return and risk of counter-party default risk, from that new links were created and networks were formed in equilibrium.

2.3 Agent-Based Approach for Inter-bank Network

Agent-based modelling (ABM) is defined as a simulation framework which comprised autonomous agents with interacting behaviors, connections between agents, and an exogenous environment; see, e.g., [31]. ABM is a strong tool to replicate real social phenomena, to represent adaptive behaviors and information diffusion of agents.

Recently, agent-based method has become a new trend in financial research, thanks to plenty of advantages and development in computation capacity and behavioral economics. Comparing to traditional network theoretic-based models, agent based modelling promises flexibility and enhances fidelity to observed data.

In case of inter-bank network, ABMs was utilized to analyze contagion risk through inter-bank channels; see, e.g., [19, 29]. Moreover, different kinds of inter-bank loans (short-term, long-term and overnight) were also considered in extended research; see, e.g., [40]. Furthermore, [28] studied a multi-layer relationship which represented three different kinds of dependencies (long-term, short-term exposures and sharing of common asset portfolio) among banks. For other approaches and results, see [6, 8, 14, 15, 18, 20, 23, 27, 30, 36] and references therein.

3 Inter-bank Network Extrapolation

3.1 Inter-bank Network Problem

The inter-bank network consists of N banks. The matrix \(X \in [0,\infty )^{N \times N}\) represents gross inter-bank positions, where \(x_{ij}\) represents the loan bank i lending to bank j. For each bank i, the row sum of X shows total inter-bank assets, while the column sum of X shows total inter-bank liabilities.

  • Total inter-bank assets: \(A_i = \sum ^N_{j=1}x_{ij}\).

  • Total inter-bank liabilities: \(L_i = \sum ^N_{j=1}x_{ji}\).

The value of \(x_{ij}\) is unobservable since banks do not public this kind of information. However, we have values of \(A_i\) and \(L_i\) from banks’ balance sheets. Since each value of bilateral positions is crucial for further modeling, we need to resort to a method to fill the inter-bank matrix, given the marginals \({A_i, L_i}\).

3.2 Maximum Entropy Approach

The first and most popular approach is Maximum Entropy; see, e.g., [17, 37]. The fundamental assumption of this approach is that we don’t have any information, so the matrix is filled in the way of “spreading exposures as evenly as possible given the assets and liabilities reported in the balance sheets of all other banks”. The rationale is that when there is no information about parameters, uniform distribution is used. Such assumption ensures that no information which would affect the estimates is offered. Bilateral exposures \({x_{ij}}\) minimizing the relative entropy function subjects to constraints of total assets and liabilities is the solution of this approach. Translated to the current setting, maximizing entropy of the matrix X means no any structure is imposed besides the information in the balance sheets.

Maximizing entropy of a matrix was first applied to contagion issue by [34]. It was then developed by [16, 38] to solve the zeros diagonal of the matrix.

The method works as follows:

  1. 1.

    Finding matrix X as the solution of maximizing entropy without the constraint of zero diagonal. \(a_i\) and \(l_i\) with appropriate standardization can be consider as realizations of marginal distributions f(a) and f(b) and \(x_{ij}\) is realization of joint distribution. If f(a) and f(b) are independent, then \(x_{ij} = a_i l_j\).

    However, this can lead to non-zero diagonal, which is not consistent with the fact that bank does not lend to itself.

  2. 2.

    Finding \(X^*\), the most similar matrix to X and satisfy the zero-diagonal constraint. First, we must modify the independence assumption by setting \(x_{ij} = 0\) for \(i = j\). Then we need to minimize the relative entropy of a matrix \(X^*\) with respect to the previous maximum entropy matrix X:

    $$\begin{aligned} \min _{x*} x^{*'} \ln \frac{x^*}{x} = \min \sum _{k=1}^{N^2-N} {x_k}^* \ln \frac{{x_k}^*}{x_k}, \end{aligned}$$
    (1)

    such that \(x \ge 0\) and \(Ax^* = [a',l]'\), where \(x^*\) and x are \((N^2 - N) \times 1 \) vectors containing the off-diagonal elements of \(X^*\) and X, A is a matrix containing the adding-up restrictions \(a_i = \sum _j x_{ij}\) and \(l_j = \sum _ i x_{ij}\). The RAS algorithm can be used to solve the problem, since the objective function is strictly concave; see, e.g., [38].

The Maximum entropy approach is criticized for delivering an unrealistic network structure. The created network is a complete network in which linkages of banks are dense. Such a network tends to underestimate contagion in stress tests; see, e.g., [2]. Simulations show that these networks may reduce the probability of crisis, but may also raise its severity when a crisis happens; see, e.g., [33].

3.3 Minimum Density Approach

Minimum Density Approach is based on the premise of high cost in establishing and maintaining network linkages. These costs includes information processing and hedging against credit risks. Actually, banks often lend and borrow banks having relationship with them previously and inter-bank network is sparse in reality. [7, 12] show that the number of active linkages is less than \(1\%\) of potential bilateral linkages. The network is also disassortative (or negatively assortative) in the sense that agents with dissimilar characteristics tend to have relationship. In the case of an inter-bank network, less-connected banks are more likely to trade with well-connected banks than with other less-connected banks; see, e.g., [7, 26].

The Minimum Density adopts an opposite approach to Maximum Entropy in that it determines a pattern of linkages for allocating inter-bank positions that is efficient in minimizing these costs; see, e.g., [3]. This means the matrix X should minimize the total number of linkages necessary for allocating inter-bank positions, subject to the total lending and borrowing constraints:

$$\begin{aligned} \min _X c \sum _{i=1}^N \sum ^N _{j=1} \mathbf 1 _{[x_{ij}>0]} , \end{aligned}$$
(2)

such that

$$\sum ^N_{j=1} x_{ij} = A_i \forall i = 1,2,... N, $$
$$ \sum ^N_{i=1} x_{ij} = L_j \forall j = 1,2,... N, $$
$$x_{ij} \ge 0\,\,\forall i, j. $$

This problem is very similar to the optimal network design problem in transportation and communication network. They are known to be non-deterministic polynomial-time hard except in very special cases; see, e.g., [9]. To create a more realistic network, in this paper, we will loosen some constraints of the problem, as well as adding elements in the objective function.

First, we soften the constrains by assigning penalties for deviations from the marginals:

$$\begin{aligned} AD_i = (A_i - \sum _j x_{ij}), \end{aligned}$$
(3)
$$\begin{aligned} LD_i = (L_i - \sum _j x_{ji}). \end{aligned}$$
(4)

\(LD_i\) measures bank i’s current deficit. Defining these deviations helps to make the optimization problem smooth, so that the only non-smooth part lies in the cost of links; see, e.g., [3]. We want to create the sparse network, but also want to minimize the deviations from marginals. Thus, the objective function is to maximize

$$\begin{aligned} V(X) = -c \sum _{i=1}^N \sum ^N _{j=1} \mathbf 1 _{[x_{ij}>0]} - \sum ^N_{i=1}[\alpha _i AD_i^2 + \sigma _i LD_i^2] . \end{aligned}$$
(5)

We also want to cover the disassortative feature of the network. This feature reflects the reality that small banks tend to seek relationship (lending or borrowing) with larger banks. The probability that bank i lends to bank j increases if either bank i or bank j is a small bank and the other is a large one. We denote this feature by \({Q_{ij}}\):

$$\begin{aligned} Q_{ij} = \max \left( \frac{AD_i}{LD_j}, \frac{LD_i}{AD_j}\right) . \end{aligned}$$
(6)

Sparse network will have high value of V(X), while the usage of \(Q_{ij}\) ensure relationships between large and small banks. [39] proposed a method to cover this trade-off. Defining P(X) as the probability distribution over network configurations, our target now is to maximize the objective function as sum of two terms. The first term favors sparse network and less deviation from marginals. The second term is to create a disassortative network in which small and large banks tend to make relationship. The optimization problem now reads

$$\begin{aligned} \max _P \sum _{X} P(X) V(X) + \theta R(P || Q), \end{aligned}$$
(7)

in which P(X) is the probability distribution over network configurations, \(\theta \) is a scaling parameter, and R is the relative entropy between Q and the optimal distribution. We note that relative entropy measures the ‘distance’ between two probability distributions. The interpretation here is that we guess Q as the true probability distribution, but only trust it partly (reflected by the value of \(\theta \)). With this belief, we consider many other plausible probabilities P with plausibility diminishing proportionally to their ‘distance’ from Q. [24] provides the solution, and the first-order conditions is

$$\begin{aligned} P(X) \propto Q(X) e^{\theta V(X)}. \end{aligned}$$
(8)

If all network configurations can be obtained and sorted based on their value of P(X), we can get the optimal solution. However, due to complexity, heuristic approaches are usually applied. [3] provides a heuristic procedure to allocate links.

Result of this approach is a sparse network. This result and the maximum entropy result are at opposite extremes of the spectrum, which is far from reality. However, with the introduction of the parameter \(\lambda < 1\), we could scale the loadings for selected links as \(x_{ij} = \lambda \min (AD_i, LD_j)\). This will produce the effect of creating more linkages between banks. The advantage here is that we are free to choose the parameter \(\lambda \) and create networks of different structures.

3.4 Network Analysis

This section provides several criteria to evaluate the connectivity of a network, so that we can analyze the inter-bank networks obtained from the above methods. In-degree (\(d_{in}(i)\)) of node i represents the number of links terminating at i, and out-degree (\(d_{out}(i)\)) represents the number of links originating from i.

3.4.1 Network Density

The density of a graph is the ratio of the number of edges and the number of possible edges. For directed graphs, the formula for graph density is

$$\begin{aligned} D = \frac{|E|}{|n| ( |n| - 1)}, \end{aligned}$$
(9)

where E is the number of edges and n is the number of nodes.

3.4.2 Network Centrality

Centrality is the fundamental concept to measure a network’s connectivity. Here, we will present four kinds of centrality to evaluate the importance of a bank in the network, as well as the level of connectivity of a particular network.

  • Degree centrality Degree centrality of a node is its degree. The relative degree centrality of node (bank) i is

    $$\begin{aligned} C_D(i) = \frac{c_D(i)}{(n-1)}. \end{aligned}$$
    (10)

    Degree centralization of a network is the variation in the degrees of nodes divided by the maximum degree variation which is possible in a network of the same size (see, e.g., [13]):

    $$\begin{aligned} C_D(G) = \frac{\sum ^n_{i=1}[c_D(n^*) - c_D(n_i)]}{n^2-3n+2}, \end{aligned}$$
    (11)

    where \(c_D(n^*)\) is the maximum value in the network.

  • Closeness centrality

    Closeness centrality of a node measures how close a bank is to other banks.

    $$\begin{aligned} c_C(i) = \frac{1}{\sum _{j \in G} d(i,j)}, \end{aligned}$$
    (12)

    in which d(i.j) is the network theoretic distance between banks i and j and G is the set of all banks in the network. Relative closeness centrality is defined as

    $$\begin{aligned} C_C(i) = (n-1) c_C(i). \end{aligned}$$
    (13)

    Closeness centralizaton of a network is the variation in the closeness centrality of nodes divided by the maximum variation in closeness centrality scores possible in a network of the same size.

    $$\begin{aligned} C_C(G) = \frac{\sum ^n_{i=1}[C_C(n^*) - C_C(n_i)]}{(n^2-3n+2)(2n-3)}. \end{aligned}$$
    (14)
  • Betweeness centrality

    The betweenness centrality of a bank reflects the amount of control that this bank exerts over the interactions of other banks in the network. Betweenness value of node i with respect to node pair j, k is the ratio:

    $$\begin{aligned} b_{jk}(i) = \frac{g_{jk}(i)}{g_{jk}}, \end{aligned}$$
    (15)

    in which \(g_{jk}\) is the number of jk shortest paths, and \(g_{jk}(i)\) is the number of j, k shortest paths that contains i. Betweenness centrality of a node i is

    $$\begin{aligned} c_B(i) = \sum ^n_{k=1} \sum ^{k-1}_{j=1}b_{jk}(i). \end{aligned}$$
    (16)

    Relative betweeness centrality of node i is

    $$\begin{aligned} C_B(i) = \frac{2c_B(i)}{n^2-3n+2}. \end{aligned}$$
    (17)

    Betweeness centrality of a network is

    $$\begin{aligned} C_B(G) = \frac{\sum ^n_{i=1}[C_B(n^*) - C_B(n_i)]}{n-1}. \end{aligned}$$
    (18)
  • Eigen-vector Centrality

    Eigen-vector Centrality can be said to be enhancement of degree centrality. In-degree centrality counts every link a node participate. However, not all nodes are relevant, some nodes are more important than others, so links from a more relevant node should be awarded. The importance of a node depends on the value of its eigenvector centrality. Let \(A = (a_{i,j})\) be the adjacency matrix of a graph, i.e., \(a_{i,j} = 1\) if node i is linked to node j and \(a_{i,j} = 0 \) otherwise, then the eigenvector centrality of node i is:

    $$\begin{aligned} x(i) = \frac{1}{\lambda } \sum _{j \in G} a_{i,j} \, x(j) , \end{aligned}$$
    (19)

    where \(\lambda \ne 0\) is a constant.

    This can be written in the form of an eigenvector equation as follows

    $$\begin{aligned} A x = \lambda x. \end{aligned}$$
    (20)

4 Model

4.1 Network and Banks

A network is a simple simulation of a banking system and comprises by only one kind of agent, which is bank. It is assumed that a network is comprised of N banks.

4.1.1 Bank Agent and Attributes

There are 3 kinds of attributes associated with bank agent:

  • Balance sheet attributes: cash, inter-bank lending, and external asset comprising Bank’s asset; deposit, inter-bank borrowing, equity comprising Bank’s liability (see Table 1) in which:

    • Cash, external asset, deposit and equity are numbers, reflecting amount of money in VND.

    • Inter-bank lending \(IB^l_i\) of bank i is a vector containing lending of a bank i to other banks, i.e., \(IB^l_i = [X_{i1}, X_{i2},..., X_{iN}]\).

    • Inter-bank borrowing \(IB^b_i\) of bank i is a vector containing borrowing of a bank i from other banks, i.e., \(IB^b_i =[X_{1i}, X_{2i},..., X_{Ni}]\).

    Table 1. Bank’s balance sheet
  • Performance parameter features, which includes:

    • State, which can be one of the values: activating, bankrupt, large, small;

    • Deposit growth rate of a bank, which is assumed to follow log-normal distribution, with mean and standard variation based on historical data;

    • Return on Equity (ROE) of a bank, which is assumed to follow normal distribution with mean and standard variation based on historical data; and

    • Ratio between short-term inter-bank lending (borrowing) and total inter-bank lending (borrowing) are assumed to be fixed for simplicity’s sake.

  • Decision parameter features. Banks decide their decision on lending/borrowing by setting targets of lending, borrowing which is a ratio on total asset, which includes:

    • Ratio between deposit and total liability,

    • Ratio between total inter-bank borrowing and total liability,

    • Ratio between external asset and total asset, and

    • Ratio between total inter-bank lending and total asset.

4.2 Network and Attributes

  • Number of agents includes: total number of banks, number of bankrupt banks, number of affected banks, and numbers of large and small banks.

  • Network asset features:

    • Network total Assets, in million VND,

    • Defaulted Assets in a particular period, in million VND, and

    • Proportion of defaulted asset over total assets in a particular period, in \(\%\).

  • Network equity features:

    • Network total equity,

    • Value of defaulted equity, in million VND, and

    • Proportion of defaulted equity over network total equity, in \(\%\).

  • Network inter-bank matrix: the matrix X of inter-bank lending and borrowing. From this network, we can calculate related coefficients, including:

    • Degree Centrality \(C_D\),

    • Closeness Centrality \(C_C\),

    • Betweeness Centrality \(C_B\), and

    • Eigen-vector Centrality \(C_E\).

4.3 Bank Activities and Behaviors

Bank activities include three rounds, whose details are given below.

4.3.1 Round 1: Update Deposit, Set Liability and Asset Targets

At the beginning of each step, banks will update Deposit - mimicking activities relating to deposit collecting of banks. Then, with this updated deposit, bank calculates targeted total asset, and allocates to external assets and inter-bank lending. Bank also calculates targeted inter-bank borrowing.

Update Deposit

Deposit (D) is assumed to follow log-normal distribution and calculated from historical data. Deposit gain or loss will be recognized as Cash in Asset. New deposit \(D^n\) is calculated as follows

$$\begin{aligned} D^n = D \times \exp (g_{d}), \end{aligned}$$
(21)

in which deposit growth \(g_{d}\) follows normal distribution.

Set Liability and Asset allocation Target

Bank sets target of its Total Liability based on its new deposit and its preferred proportion of deposit to Total Liability. Let target deposit over total liability as \(\frac{D}{L}:=R^{d}_{tg}\), then targeted total asset (\(A_{tg}\)) and targeted total liability (\(L_{tg}\)) are

$$\begin{aligned} A_{tg} = L_{tg} = \frac{D^n}{R^{d}_{tg}}. \end{aligned}$$
(22)

Bank also calculates its inter-bank borrowing target (\(IB^b_{tg}\)) based on targeted inter-bank borrowing over total asset ratio \(R^b_{tg}\) as

$$\begin{aligned} IB^b_{tg} = R^b_{tg} \times A_{tg}. \end{aligned}$$
(23)

From this target, bank set its new borrowing targets (\(IB^{nb}_{tg}\)) the difference between target and old lending (in case this value is positive) as

$$\begin{aligned} IB^{nb}_{tg} = \min (IB^b_{tg} - IB^l, 0). \end{aligned}$$
(24)

Next, bank set target of inter-bank lending and External Asset as fraction of targeted Total Asset. Let \(\frac{IB^l_{tg}}{A} := R^l_{tg}\) and \(\frac{EA}{A}:=R^{ea}_{tg}\), then

$$\begin{aligned} IB^l_{tg} = R^l_{tg} \times A_{tg}, \end{aligned}$$
(25)
$$\begin{aligned} EA_{tg} = R^{ea}_{tg} \times A_{tg}. \end{aligned}$$
(26)

Bank also calculates it available IB lending it wants to make as the difference between target and old lending (in case this value is positive):

$$\begin{aligned} IB^{nl}_{tg} = \min (IB^l_{tg} - IB^l, 0). \end{aligned}$$
(27)

4.3.2 Round 2: Lending-Borrowing Mechanism

Request for loan. Based on new loan target \(IB^{nl}_{tg}\) computed in Round 1, bank asks other banks for a loan. The amount of asking loan is the remaining of loans a bank need to fulfill its new borrowing target. A bank will ask until one of these condition met: the target is fulfilled unless there are no other banks available to borrow.

Response mechanism. The response mechanism is built with pretty simple rules which ensures that larger banks are more likely to lend and banks are more likely to lend other banks having relationship with them previously:

  • Probability that a large bank lends to a bank it has relationship previously ranges from 0.6 to 1,

  • Probability that a large bank lends to a bank it does not have relationship previously ranges from 0.2 to 0.8,

  • Probability that a small bank lends to a bank it has relationship previously ranges from 0.4 to 0.9, and

  • Probability that a small bank lends to a bank it does not have relationship previously ranges from 0 to 0.7.

Amount of loan. The amount of loan a bank wants to lend is a fraction of its available resource. This fraction follows a uniform distribution. Between the amount that lending bank want to give and the amount that borrowing bank want to borrow, the lower one will be the actual value of the loan. After the amount of a loan is set, the inter-bank lending and borrowing accounts of banks will be added. Also, cash account of lending bank will be subtracted, while cash account of borrowing bank will be added.

Also, each new loan is divided to short-term and long-term loans for convenience in the repayment step of the next round.

The order of this process is random, which is suitable to reflect the reality that the time for a loan request depends on many factors and is unpredictable. This request-response process will be repeated until borrowing schedule or lending schedule is emptied.

4.3.3 Round 3: Update Equity and Repay Inter-bank Loans

Update Equity. Bank income will be assumed to depend on its equity and derived return-on-equity ratio (ROE), that is,

$$\begin{aligned} \text {Net Income} = ROE \times E. \end{aligned}$$
(28)

ROE is assumed to follow normal distribution with mean and variance calculated from historical data. This net income will be recognized as Cash in the Asset and as additional equity in Liability.

Inter-bank Borrowing Repayment. Banks make payment on their debts \(P_{IB}\) and receive debt payment \(R_{IB}\). There are 2 types of debts: short-term and long-term debts. Most of short-term loans are repaid within three months, and majority of long-term loans are repaid in less than one year (four periods). Therefore, \(25\%\) of long-term loan is paid and \(75\%\) continue to exist and will be paid gradually in next 3 periods.

We will not simulate the activities (lending, borrowing, repayment) on Deposit and External Asset since this paper aims at analyzing inter-bank activities. For simplicity’s sake, these activities will be combined in updating activity.

4.3.4 Bank Default

Definition: A bank goes to default if the value of its equity (E) becomes negative, i.e.,

$$\begin{aligned} E_i(t) < 0. \end{aligned}$$
(29)

A bank who meets the default condition will be transmitted to Bankrupting process list. This list contains banks who are in the progress of settling its assets and liabilities before becoming bankrupt and removed from the network. When bank i fails at time t, it will default on its inter-bank borrowing. Becoming default forces banks to sell its illiquid assets and leads to loss on these assets’ value. The model assumes that banks will recover from \(50\%\) to \(80\%\) of the value of its external assets, that is,

$$\begin{aligned} EA^r_i = U(50\%, 80\%) \times EA_i. \end{aligned}$$
(30)

The amount of money from selling these assets will be added to Cash account, while external assets will be set back to 0. Bank recognizes the loss in its equity.

After selling external assets, bank will ask other banks that borrow from it to buy back the loan. The asking amount will be smaller than the actual loan and have recovery rate randomly selected from \(50\%\) to \(80\%\):

$$\begin{aligned} IB^a_{i,j} = U(50\%, 80\%) \times IB_{i,j}. \end{aligned}$$
(31)

Then, there will be 2 cases. If bank asked (bank j) is able to repay the loan (repaying the loan doesn’t force j to bankrupt condition), asking bank take the money to Cash, set its lending to j as 0, recognize the loss to equity. While j takes the money from its Cash, sets its borrowing from i as 0, recognizes the gain to equity.

In case bank asked meets bankrupt condition, it pays the amount of money it can and then is moved to bankrupting list to settle later:

$$\begin{aligned} IB^p_{j,i} = \min (C_j, IB^a_{i,j}), \end{aligned}$$
(32)
$$\begin{aligned} WD_{i,j} = IB^l_{i,j} - IB^p_{j,i}. \end{aligned}$$
(33)

This is recognized as all of the money bank i can take from j. It adds the money collected to its Cash, set its lending to j as 0, recognize the loss to equity. Whereas, j set its borrowing from i as 0, subtract its Cash and recognizes the gain to equity.

After selling all the assets, the bankrupt bank will use the money collected to pay its creditors. The allocation is based on the proportion of the loan. Bank i’s creditor get the repayment and transfer to its Cash account, set lending to i as 0 and recognize the lost. It then checks the bankrupt condition and will be moved to bankrupting list if the conditions are met.

$$\begin{aligned} IB^{rc}_{j,i} = C_i \times \frac{IB^l_{j,i}}{D_i + IB^b_i},\end{aligned}$$
(34)
$$\begin{aligned} WD_{j,i} = IB^l_{j,i} - IB^{rc}_{j,i}. \end{aligned}$$
(35)

5 Experiment and Results

5.1 Data Description

The data is collected from public financial statements source, including 19 banks’ quarter balance sheets, which reflect banks’ business and lending-borrowing practices. These balance sheets are simplified to create inter-bank system. To be more specific, simplified balance sheet cover these below six accounts:

  • Cash: most liquid asset of banks, including cash and cash equivalent.

  • Inter-bank Lending: loans a bank giving to other banks in the inter-bank network.

  • External Asset: covers all other kinds of banks’ asset, including stocks, bonds, lending to enterprises, personal loans and other kinds of external asset.

  • Deposit: money bank receives from depositors.

  • Inter-bank Borrowing: the money a bank borrows from other banks in the inter-bank network.

  • Equity: capital of banks from shareholders.

The data sample covers 7 years from 2010 to 2016, although for some banks the data is not sufficient for all 7 years due to public data shortage. For initial balance sheet position, data as of June 30, 2016 is used for the purpose of maximizing the number of banks. A cumulative initial value of banks’ assets is 3,805,256 billions VND.

5.2 Interbank-Network Results

5.2.1 Maximum Entropy Network

As expected, the Maximum entropy method creates a network with every node connecting to others, so every bank has equal and highest degree centrality (18) and the density of the network is maximum (1). Degree centrality of the network is 0 in both in-degree and out-degree cases for the fact that no bank dominates the network. Also, the betweenness centrality and closeness centralization are both 0 as every node connects directly to each other.

5.2.2 Minimum Density - Highly Dense Network (\(\lambda = 0.2\))

The most outstanding characteristic of the network is high level of independence. Every bank in the network can connect to each other, although the network is less dense than Maximum Entropy approach network since not every node connects directly.

VCB and CTG are two most important nodes in the network. They lend and borrow from all other banks in the network. Their betweenness centralities are also highest, 39.5 and 37.1, respectively. This means they are frequently present between linkages of other nodes. CTG is the biggest banks in the system with total asset of 850,209 billion VND, while VCB is the second-biggest banks in the system with total asset of 678,274 billion VND. Either of these two banks going bankrupt may devastate the whole network.

5.2.3 Minimum Entropy - Slightly Dense Network (\(\lambda = 0.5\))

With \(\lambda = 0.5\) this network is less dense than when the density is set to be 0.2. Two most important nodes are still CTG and VCB, but their roles are not as significant as in the Highly Dense Network. The network has high out-centrality (out-degree centrality: 0.798, out-close centrality: 0.583) and low in-centrality (in-degree centrality: 0.298, in-close centrality: 0.196). This means the in-centrality of the network is pretty equal.

CTG and VCB are most important nodes and frequently appear in shortest paths between two other nodes, with betweenness centrality of 101.3 and 129, respectively.

5.2.4 Minimum Entropy - Slightly Sparse Network (\(\lambda = 0.7\))

This network is special comparing to other networks as CTG and VCB do not take as so significant role as in other network. The number of links created for CTG is just 16, and for VCB is just 13. However, while they do not create many direct links, the presence of them in indirect link are still significant (168.5 for CTG and 86 for VCB). The linkages are spread over the network. Some banks (BACA, MBB) have high numbers of connections but low eigen-vector centrality since they only have relationship with small banks. Meanwhile, several banks (ACB, VIB) have low connections but high eigen-vector centrality as they have relationship with large bank.

5.2.5 Minimum Entropy - Highly Sparse Network (\(\lambda = 1\))

This network is the most sparse one among analyzed networks, with the number of linkages are minimized. The network can be relatively considered as an island network with two islands. CTG and VCB are centers of these two islands, which makes them have outstanding high betweenness centrality (238.5 for CTG and 179.5 for VCB). Other banks have a few connections to other banks. This can make the weigh of edge large, and bankruptcy of a particular bank could seriously affect the bank lend to it. However, the contagion will be limited in this connection only.

5.3 Simulations and Result

We simulate on 5 above networks. For each network, we first run the system without shocks for 10 periods (quarters) and observe changes in total assets and capitals of each banks and the whole system.

Then, for the purpose of stress-testing, we apply different kinds of shock for each repetition. There are two kinds of shocks: idiosyncratic shock and systemic shock.

  • Idiosyncratic Shock represents default of several individual banks. Default of a bank will affect banks that lend money by the manner loss to inter-bank asset, then directly write this loss to capital of the affected bank. Three different scenarios are employed:

    • Defaults of individual banks (50 observations).

    • Simultaneous defaults of three random banks (500 observations).

    • Simultaneous defaults of five random banks (500 observations).

    Each bank chosen to be bankrupt will suffered loss from \(50\%\) of its external asset. It will ignite the bankrupt mechanism as explained above.

  • Systemic Shock represents a sudden drop in the value of external asset, such as mortgage loans. In this scenario, there are two forces: direct effects of a shock which reduce bank’s mortgage loan assets, and the contagion effects which reduce bank’s inter-bank assets. The combination of 2 effects makes a systemic shock more damaging.

    We start with a shock (drop in external asset) of \(1\%\). Then we repeat the experiment 19 times more, so that default rate ranges from \(1\%\) to \(20\%\) with an increment of \(1\%\). Affected by shocks, some weak banks in the system may get into the bankrupting conditions. In this case, they are moved to bankrupting list and will be settled in succession as described in the bankrupting mechanism.

For every scenario, we will observe the number of defaulted banks, suffered banks, the value of assets losses, capital losses to compare impacts of shocks.

5.3.1 Networks Without Shocks

In normal condition, asset and liability accounts of banks grow gradually as expected. The most interesting thing happening here is the development of inter-bank matrix. Whatever the initial condition of the matrix, the matrix tends to develop into a modestly sparse matrix. Figure 1 presents the changes in density of matrices over periods. After five periods, the density of the networks converges to values from 0.2–0.4 and fluctuates modestly then. The reason here is that after 5 periods, banks repay all initial inter-bank debts and rules of lending-borrowing start to dominate the trend. All the networks from this period tend to be modestly sparse. This fact shows some insight about inter-bank matrix formation. Since banks in the system will follow particular rules, the network will converge to a particular pattern. Then, combining experience in banking domain and agent-based simulation could be a potential approach to reproduce actual formation of the inter-bank market.

Fig. 1.
figure 1

Density of 5 networks over time of without-shock simulation

5.3.2 Network Under Systemic Shock

A system shock in the model is presented by a sudden drop in external asset. In reality, the shock can come from events that affect the whole economy system such as drop in housing or oil’s prices. It provokes two sorts of negative impact. The first one is loss caused by fall on external asset value, which is recognized as equity loss and drives bank into bankrupt. The second is unfavorable post-event in the market like small drop in income or loss as the result of bankrupts of partners. Banks surviving from the first impact with low equity are highly vulnerable to such unfavorable events.

As analyzed in the previous section, since initial equity of bank is pretty thin, most of banks (17 out of 19) go bankrupt at shock of \(11\%\). Two banks survive are SaiGonBank and PGbank who have highest equity over asset ratio.

With shocks less than \(4\%\), no bank goes bankrupt. SCB - the weakest node in the system goes bankrupt under shock of \(5\%\) magnitude. The ME network and MD network (\(\lambda = 0.2\)) have most affected banks (19 and 17 respectively) as they are two most dense network. In other networks, number of affected banks ranges from 5 to 7.

Under a shock of \(7\%\) magnitude we notice differences between networks. In the most dense ME network and the most sparse MD network (\(\lambda = 1\)), the number of bankrupt bank are least (3 for each), while the 3 remaining networks observes bankruptcy of 5 banks. 3 bank goes bankrupt as the result of first impact are: ACB, LienVietPostBank, SCB. Banks go bankrupt under the contagion of unfavorable conditions are CTG (in MD Network \(\lambda = 0.2\)), SeaBank (in MD networks \(\lambda = 0.2\) and \(\lambda = 0.5\)), VCB (in MD Network \(\lambda = 0.7\)) and STB (in MD Network \(\lambda = 0.7\)). The explanation is that the highly connected networks spread the impact over the network, while in case of a sparse network, bankruptcy of a particular bank only affects a limited number of other banks.

Under shock of \(8\%\) magnitude, the contagion effects fade and the numbers of bankrupt bank in networks are pretty even, ranges from 9 to 11. This number increases to 12–13 under shock of \(9\%\) magnitude. As shock magnitude rises from then, the behavior of networks are pretty alike and there are few signs of credit contagion effect. At \(11\%\), 17 out of 19 banks go bankrupt and at \(19\%\) the whole network collapses in all five structures.

Dynamic of Defaulted Asset and Equity is pretty similar among networks and share the same pattern to dynamic of bank defaulted number.

5.3.3 Network Under Idiosyncratic Shock

Analyzing the network under idiosyncratic shock, we can see that the contagion effect is insignificant. Bankrupts of one, three, or five banks only lead to bankruptcy of two more banks at most. However, the dense network is most resilient since even in the case of 5 bankrupt banks, there is no other banks beside banks shocked at initial stage going bankrupt. In this case, Highly Dense Network under shocks of idiosyncratic acts as risk-sharing mechanism and spread the impact to the whole network. The Highly Sparse Network is also more resilient than the slightly sparse and slightly dense network.

As expected, one bank going bankrupt affects all the other banks in ME network, but only impact an average of 4 banks in MD network with \(\lambda = 1\). However, the level of impact is least significant in the ME network with no more banks going bankrupt. Generally, highly connected networks (ME and MD with \(\lambda = 0.2\)) are least impacted, while moderately connected networks (MD with \(\lambda = 0.5\) and MD with \(\lambda = 0.7\)) are most impacted. However, when the network is particularly sparse, the impact tend to be lessened. On average, the most connected network (ME) loses 5.13\(\%\) total asset and 7.36\(\%\) total equity, while MD network with \(\lambda = 0.7\) loses 6.62\(\%\) of total asset and 9.93\(\%\) of total equity. In the worst case, ME network only loses 25.15\(\%\) of asset and 37.54\(\%\) of equity, while MD network with \(\lambda = 0.7\) loses 32.04\(\%\) of asset and 43.85\(\%\) of equity.

In cases of three and five bankrupt banks, the average loss in asset and equity are pretty similar over networks (about 19\(\%\) for asset loss and 26\(\%\) for equity loss in case of three banks going bankrupt, 32\(\%\) for asset loss and 42\(\%\) for equity loss in case of five banks going bankrupt).

Detail statistics of network features under idiosyncratic shock are represented in Tables 2, 3, 4, 5 and 6 below.

Table 2. ME Network - Selected end-of-period statistics after a default of a single bank, three random banks and five random banks.
Table 3. MD Network (\(\lambda = 0.2\)) - Selected end-of-period statistics after a default of a single bank, three random banks and five random banks
Table 4. MD Network (\(\lambda = 0.5\)) - Selected end-of-period statistics after a default of a single bank, three random banks and five random banks
Table 5. MD Network (\(\lambda = 0.7\)) - Selected end-of-period statistics after a default of a single bank, three random banks and five random banks
Table 6. MD Network (\(\lambda = 1\)) - Selected end-of-period statistics after a default of a single bank, three random banks and five random banks

6 Conclusion

This article builds an agent-based model presenting a banking system of 19 Vietnamese banks, in which banks interact with each others via their balance sheets. Different network structures are evaluated to see the potential effects of credit contagion under various circumstances. These networks are acquired using two most well-established inter-bank network reconstruction methods: Maximum Entropy and Minimum Density. There are several outstanding points which can be inferred from the model:

  • Under normal condition, the network structures tend to converge to a slightly dense network whatever the initial condition is. This result suggests simulation method with proper lending-borrowing behavior maybe a good approach to build actual inter-bank network structure.

  • The equity buffers of Vietnamese banks are pretty thin, that make them become more vulnerable to system shocks. Even a system shocks of \(11\%\) magnitude on external asset can make 17 out of 19 banks going bankrupt and the whole system collapses at shock of \(19\%\) magnitude.

  • Generally, under both system shock and idiosyncratic shock, contagion effect for networks simulated from Vietnam’s banking data is not significant. One reason here is the proportion of inter-bank asset and liability over total asset is small, while ratio of equity over total liability is low and does not vary much.

  • In case of system shock, under shocks of low magnitude, highly connected network and highly sparse network tend to be most resilient. The reason is highly connected networks spread the impact over the network and act as a risk-sharing mechanism, while in case of sparse network, bankrupt of particular bank only affects limited number of other banks and limit the impact of crisis. However, when the magnitude of shock increases, the impact of shocks on different network are pretty equal since most banks meet bankrupting condition. We can only observe the difference in bankrupting behavior of networks under shocks magnitude ranges from 5 to 10\(\%\).

  • In case of idiosyncratic shock, the contagion effect is insignificant. Bankrupts of one, three, or five banks only lead to bankruptcy of two more banks at most. However, the dense network is more resilient since even in the case of 5 banks shocked, there are no other banks beside banks shocked at initial stage going bankrupt. The Highly Sparse Network is also more resilient than the slightly sparse and slightly dense network. However, when the number of banks shocked increase, the impact over all the networks tend to converge.

This article succeeds in building a complete network and gains some insights about inter-bank network and behavior. However, there are a lot of works to improve and make the model more realistic. First, other inter-bank network reconstruction methods could be implemented. Second, lending-borrowing rules in the model could be refined to reflect the reality more accurately. Third, the model could be expanded to include not only banks but also other agents like depositors, customers, traders, government. Forth, other kinds of external force such as changes in policy or liquidity shocks could be included in the model.

All in all, agent-based method is a promising approach to understand interaction in the inter-bank network. It can be a tool for government to perform stress test under different kinds of shocks, as well as experiment new regulations to see whether their targets can be met.