# Calculation of Credit Valuation Adjustment Based on Least Square Monte Carlo Methods

Authors: Qian Liu
Journal: Mathematical Problems in Engineering
 (2015)

---

## Abstract

Counterparty credit risk has become one of the highest-profile risks facing participants in the financial markets. Despite this, relatively little is known about how counterparty credit risk is actually priced mathematically. We examine this issue using interest rate swaps. This largely traded financial product allows us to well identify the risk profiles of both institutions and their counterparties. Concretely, Hull-White model for rate and mean-reverting model for default intensity have proven to be in correspondence with the reality and to be well suited for financial institutions. Besides, we find that least square Monte Carlo method is quite efficient in the calculation of credit valuation adjustment (CVA, for short) as it avoids the redundant step to generate inner scenarios. As a result, it accelerates the convergence speed of the CVA estimators. In the second part, we propose a new method to calculate bilateral CVA to avoid double counting in the existing bibliographies, where several copula functions are adopted to describe the dependence of two first to default times.


---

## Body

## 1. Introduction

For nearly three decades, the deepening of financial innovation made the efficiency of social resource allocation gradually increase. The scale of the global financial derivatives market has been far greater than the total size of the global economy. Most global derivatives trading occurs in the OTC market; therefore, counterparty credit risk management for OTC derivatives needs to be focused on. Counterparty credit risk is complex, resulting in the closure of many large financial institutions, thereby causing thousands of counterparties associated with them to suffer huge losses, so how to estimate counterparty credit risk is becoming increasingly important.Credit crisis and the ongoing European sovereign debt crisis have highlighted the native form of credit risk, namely, the counterparty risk (Crépey et al. [1]). Counterparty credit risk is defined as the risk that the counterparty to a derivative transaction could default before the final settlement of the transaction cash flows (Brigo and Pallavicini [2]). Since the subprime crisis and default of many banks afterwards, counterparty credit risk has been taken into account by most financial institutions since the regulator has required banks to keep additional capital charges to compensate counterparty risk. Zhang and Wang [3] developed fast and accurate numerical solutions by using fast Fourier transform (FFT) technique. The simulations show that the SVDEJD model is suitable for modeling the long-time real-market changes and stock returns are negatively correlated with volatility. The model and the proposed option pricing method are useful for empirical analysis of asset returns and managing credit risk. Li et al. [4] propose an improved attribute bagging method, weight-selected attribute bagging (WSAB), to evaluate credit risk. And the experimental results based on two credit benchmark databases show that the method, WSAB, is outstanding in both prediction accuracy and stability.Credit valuation adjustment (CVA) is defined as the difference between the risk-free portfolio value and the true portfolio value that takes into account the possibility of institution and counterparty default (Brigo and Pallavicini [5]). We call it unilateral CVA when only the counterparty has the potential to default and the institution is assumed to be risk-free. Likewise, bilateral CVA assumes that both parties have the possibility to default before the maturity. As in most existing bibliographies such as Zhu and Pykhtin [6], Alavian et al. [7], and Brigo and Pallavicini [8], the authors mainly focus on the details of contracts like collateral agreements, rehypothecation, and close-out rules. Wu et al. [9] propose a stochastic DEA model considering undesirable outputs with weak disposability which not only can deal with the existence of random errors in the collected data, but also depicts the production rules uncovered by weak disposability of the undesirable outputs. This model introduces the concept of risk to define the efficiency of decision making units (DMUs) and utilizes the correlationship matrix of all the variables to portray the weak disposability. Albanese et al. [10] introduce an innovative theoretical framework for the valuation and replication of derivative transactions between defaultable entities based on the principle of arbitrage freedom. The framework extends the traditional formulations based on credit and debit valuation adjustments (CVA and DVA for short, resp.). Bo and Capponi [11] obtain an explicit formula for the bilateral counterparty valuation adjustment of a credit default swaps portfolio referencing an asymptotically large number of entities. They have the result that counterparty adjustments are highly sensitive to portfolio credit risk volatility as well as to the intensity of the common jump process. Rohan and Dmitry [12] think that the effect of counterparty credit on valuation and risk management dramatically increased. Existing modeling and infrastructure no longer worked and a rethink from first principles had to take place. So they evolved a new generation of interest rate modeling based on dual curve pricing and integrated credit valuation adjustment (CVA) is evolving. Jimmy et al. [13] analyse the impact of wrong-way risks on both CVA itself and tail risks of CVA. They demonstrate that the induced tail risk adjustment to account for wrong-way risk can be more significant than the impact on CVA itself. We hope this paper would serve as a complement to the existing research, especially in terms of simulation methods.As universally agreed, least square Monte Carlo method (Longstaff and Schwartz [14]; Thom [15]) is efficient in the valuation of American or Bermudan options. In essence, the valuation of CVA shares the same principle as both require us to calculate conditional expectation as fast as possible. Therefore, this paper is focused on how to apply least square Monte Carlo method to calculate unilateral CVA (UCVA, for short) and then bilateral CVA (BCVA, for short) with the help of copula functions. We find that this method is impeccable and hope it would become a standard in the CVA valuation.


## 2. Unilateral Credit Valuation Adjustment

In credit risk modeling, usually we define the probability space(
Ω
,
G
,
G
t
,
Q
) and the default time of institution and its counterparty by τ
I and τ
c, respectively. We define the augmented filtration G
t
=
max
⁡
(
F
t
,
H
t
), where F
t is the usual filtration containing all market information except defaults, while H
t
∶
=
σ
(
max
⁡
(
τ
I
≤
s
,
τ
c
≤
t
)
,
s
≤
t
) carries only the information of defaults. Besides, we define the default intensity and cumulated default intensity as
(1)
Q
τ
∈
t
,
t
+
d
t
∣
τ
>
t
∶
=
λ
t
d
t
,
Γ
t
∶
=
∫
0
t
λ
s
d
s
.
Then, first time to default (FTD) is defined as (U is standard uniform random variable)
(2)
τ
I
∶
=
inf
⁡
⁡
t
>
0
:
e
-
Γ
t
<
U
I
,
τ
c
∶
=
inf
⁡
t
>
0
:
e
-
Γ
t
<
U
c
.
Moreover, due to the fact that default intensity is always positive, we have
(3)
Q
τ
I
>
t
=
Q
Γ
(
τ
I
)
>
Γ
t
=
Q
e
-
Γ
τ
I
<
e
-
Γ
t
=
Q
U
I
<
e
-
Γ
t
=
E
e
-
Γ
t
.
Thus, the following lemma about conditional expectation will help us calculate CVA:
(4)
Lemma
E
Q
1
t
<
τ
X
∣
G
t
=
1
t
<
τ
E
Q
X
∣
G
t
=
1
t
<
τ
E
Q
1
t
<
τ
X
∣
F
t
Q
t
<
τ
∣
F
t
,
Q
t
<
τ
≤
s
∣
G
t
=
1
t
<
τ
Q
t
<
τ
∣
F
t
Q
t
<
τ
≤
s
∣
F
t
=
1
t
<
τ
E
Q
1
-
e
Γ
t
-
Γ
s
∣
F
t
.
The proof is given in Lee et al. [16].After modeling default events, we need to explore on the other side all the cash flows during the contract’s life. For simplicity, we assume that collateralization or funding is not involved; thus mark-to-market (MtM, for short) value of the contract is defined as the conditional expectation of all the discounted cash-flowΠ
(
t
,
T
) with respect to the filtration G
t.Normally, in the event where a counterparty has defaulted, an institution may close out the position and is not obliged to make future contractual payments (reasonably, since payments are unlikely to be received). However, the underlying contracts must be settled depending on the MtM value at the time of default. Consider the impact of positive or negative MtM with a counterparty in default.(i)
Positive MtM. When a counterparty defaults, they will be unable to make future commitments and hence an institution will have a claim on the positive MtM at the time of the default. The amount of this MtM minus any recovery value will represent the loss due to the default.
(ii)
Negative MtM. In this case, an institution owes its counterparty through negative MtM and is still legally obliged to settle this amount. Hence, from a valuation perspective, the position is essentially unchanged. An institution does not gain or lose from their counterparty’s default in this case.Therefore, when we calculate UCVA, we only take the positive part of MtM into consideration. If we consider further the recovery rate and the discount factor denoted by D
(
0
,
t
), we deduce the following formula on the assumption of no wrong-way risk or, more specifically, no dependence between recovery rate, default, and exposure.A concrete example would be swap, whose fixed/floating leg value is the conditional expectation of all the coupons paid in the future discounted to the current time. Namely, cash-flowΠ
(
t
,
T
) is the sum of all the coupons paid at each future instant. Consider
(5)
UCV
A
0
=
1
-
RE
C
C
E
0
Q
D
0
,
τ
1
0
≤
τ
<
T
E
τ
Π
τ
,
T
+
=
1
-
RE
C
C
∑
i
=
0
n
-
1
E
0
Q
D
0
,
τ
1
T
i
≤
τ
<
T
i
+
1
E
τ
Π
τ
,
T
+
≈
(
1
-
RE
C
C
)
×
∑
i
=
0
n
-
1
E
0
Q
D
0
,
T
i
1
T
i
≤
τ
<
T
i
+
1
E
T
i
Π
T
i
,
T
+
indt
=
1
-
RE
C
C
∑
i
=
0
n
-
1
D
0
,
T
i
Q
T
i
<
τ
≤
T
T
i
+
1
E
0
Q
×
E
T
i
Π
T
i
,
T
+
=
1
-
RE
C
C
∑
i
=
0
n
-
1
D
0
,
T
i
Q
T
i
<
τ
≤
T
T
i
+
1
EPE
(
T
i
)
≈
(
1
-
RE
C
C
)
×
∑
i
=
0
n
-
1
D
0
,
T
i
Q
T
i
<
τ
≤
T
T
i
+
1
1
N
∑
ω
=
1
N
MtM
T
i
+
(
ω
)
lemma
=
(
1
-
RE
C
C
)
×
∑
i
=
0
n
-
1
D
0
,
T
i
E
Q
1
-
e
Γ
T
i
-
Γ
T
i
+
1
1
N
∑
ω
=
1
N
Mt
M
T
i
+
ω
.
According to the formula of UCVA, we need to take the expectation twice so that a natural idea comes to mind, to say we generate random variables ζ to calculate the inner expectation and ω to calculate the outer expectation. Graphically we have Figure 1.Figure 1
Principle of nested Monte Carlo methods.LetMtM
(
ω
,
ζ
) denote the mark-to-market value of the contract on each inner scenario:
(6)
MtM
τ
ω
,
ζ
=
Π
t
,
T
ω
,
ζ
=
∑
t
<
T
j
≤
T
C
~
T
j
ω
,
ζ
,
divide
0
,
T
equally:
0
=
T
0
,
T
1
,
T
1
,
T
2
,
…
T
n
-
1
,
T
n
=
T
,
Mt
M
T
i
ω
,
ζ
=
Π
T
i
,
T
ω
,
ζ
=
∑
i
≤
j
<
n
C
~
T
j
ω
,
ζ
.
Then on each scenario omega, since we have already simulated market data between T
0 and T
i, we generate once again M scenarios between T
i and T
n to get the coupon values on each extended scenario. Thus, the mark-to-market value at instant T
i can be presented as
(7)
Mt
M
T
i
(
ω
)
=
E
T
i
Π
T
i
,
T
ω
,
ζ
=
E
T
i
∑
i
≤
j
<
n
C
~
T
j
ω
,
ζ
≈
1
M
∑
ζ
=
1
M
∑
i
≤
j
<
n
C
~
T
j
ω
,
ζ
=
1
M
∑
ζ
=
1
M
Mt
M
T
i
ω
,
ζ
and the formula of UCVA is given by
(8)
UCV
A
0
MCMC
=
1
-
RE
C
C
×
∑
i
=
0
n
-
1
D
0
,
T
i
E
Q
1
-
e
Γ
T
i
-
Γ
T
i
+
1
1
N
∑
ω
=
1
N
Mt
M
T
i
+
ω
≈
(
1
-
RE
C
C
)
∑
i
=
0
n
-
1
D
0
,
T
i
E
Q
1
-
e
Γ
T
i
-
Γ
T
i
+
1
1
N
×
∑
ω
=
1
N
1
M
∑
ζ
=
1
M
Mt
M
T
i
ω
,
ζ
.
However, this method is not the top choice because of its massive computational efforts. According to [17], the convergence rate is of order −2/3, but this can be improved to −1 owing to the least square Monte Carlo method that we will present below. In fact, under the assumption that all the coupons are Markovian, we can calculate the conditional expectation by regression:
(9)
Mt
M
T
i
ω
=
E
Π
T
i
,
T
ω
,
ζ
∣
G
T
i
=
E
Π
(
T
i
,
T
)
(
ω
,
ζ
)
∣
Z
T
i
≈
∑
l
=
0
L
β
i
,
l
φ
l
Z
T
i
ω
.
Now the problem is the minimization of the expected squared error with respect to coefficients:
(10)
min
⁡
β
E
E
T
i
Π
T
i
,
T
-
∑
l
=
0
L
β
i
,
l
ϕ
l
Z
T
i
(
ω
)
2
.
The necessary condition is therefore
(11)
E
E
T
i
Π
T
i
,
T
ϕ
S
Z
T
i
=
∑
l
=
0
L
β
i
,
l
E
[
ϕ
l
(
Z
T
i
)
ϕ
S
(
Z
T
i
)
]
,
hhhhhhhhhhhhhhhhhhhhhhhhhhhhhh
S
=
0,1
,
…
,
L
.
It would be more convenient to present the result in a matrix formulation and thus we define
(12)
M
ϕ
ϕ
l
,
s
=
E
ϕ
l
Z
T
i
ϕ
S
Z
T
i
,
M
∏
ϕ
S
=
E
E
Π
T
i
,
T
∣
Z
T
i
ϕ
S
Z
T
i
meaurable
=
E
E
Π
T
i
,
T
ϕ
S
Z
T
i
∣
Z
T
i
tower
=
E
Π
T
i
,
T
ϕ
S
Z
T
i
.
In order to find the optimal coefficients we generate N scenarios of the underlying asset Z
(13)
M
ϕ
ϕ
l
,
s
=
1
N
∑
ω
=
1
N
ϕ
l
Z
T
i
ω
ϕ
s
Z
T
i
ω
,
M
∏
ϕ
s
=
1
N
∑
ω
=
1
N
Π
T
i
,
T
ω
ϕ
s
Z
T
i
ω
.
So finally
(14)
β
-
=
M
ϕ
ϕ
l
,
s
-
1
M
∏
ϕ
s
,
Mt
M
T
i
ω
=
∑
l
=
0
L
β
^
i
,
l
ϕ
l
Z
T
i
ω
.
We calculate UCVA by
(15)
UCV
A
0
LSMC
=
(
1
-
RE
C
C
)
∑
i
=
0
n
-
1
D
0
,
T
i
E
Q
1
-
e
Γ
T
i
-
Γ
T
i
+
1
1
N
×
∑
ω
=
1
N
∑
l
=
0
L
β
^
i
,
l
ϕ
l
Z
T
i
ω
+
.Remarks 1.
(i) Good choice of basis functions is the key of regression. The typical choice would be Laguerre polynomial or Legendre polynomial.
(ii) We should generate a new scenario of the underlying asset to evaluate the contract’s value other than the one used for regression to avoid bias.
(iii) The error analysis of the LSMC estimator is far from trivial since it comes from different sources: impossibility of the usage of infinite number of basis functions, error of the coefficients in the regression, error based on the number of exercise dates used in the algorithm, and so forth.
Concerning the aggregation, we have, respectively, positive, absolute, and exercise region:(16)
Mt
M
T
i
+
ω
,
1
2
Mt
M
T
i
ω
+
Mt
M
T
i
ω
,
Mt
M
T
i
(
ω
)
1
Mt
M
T
i
ω
>
0
.


## 3. Numerical Example

Here we intend to examine the algorithm for a vanilla swap [18], where the floating leg is given by the 1-year Libor and the fixed leg is given by the fixed rate K. We suppose the interest rate follows the Hull-White model while the default intensity λ could be constant. We observe that all three estimators converge to the same limit given sufficient numbers of scenarios.The framework of numerical simulation is divided into the following four steps.(1)
We simulate the time of default according to the stochastic model of its default intensity, normally a mean-reverting model.
(2)
We simulate all the cash flows occurring when the trading position is entered, which is based on the underlying assets. For example, we assume the interest rate follows Hull-White model.
(3)
We use nested least square Monte Carlo method (or Markov Chain Monte Carlo method) to calculate the conditional expectation of the future cash flows to determine the future MtM value.
(4)
Based on the future MtM and the probability of default, we use three different aggregation methods to calculate unilateral CVA.From Figures 2, 3, 4 and 5, no matter which kinds of Monte Carlo methods are adopted, we have seen that the convergence of UCVA estimators under least square Monte Carlo method is fast. From this experiment, we find that the theoretical results deduced in Section 2 of this paper are useful to calculate UCVA because all the cases show that the values are convergent no matter which Monte Carlo methods are adopted and no matter which aggregation methods are used. Thus, the theoretical results deduced in Section 2 would be suitable in extensive real-world application situations.Figure 2
Convergence of UCVA estimators, constant default intensity, and least square Monte Carlo.Figure 3
Convergence of UCVA estimators, constant default intensity, and Markov Chain Monte Carlo.Figure 4
Convergence of UCVA estimators, hybrid rate-default model, and least square Monte Carlo.Figure 5
Convergence of UCVA estimators, hybrid rate-default model, and Markov Chain Monte Carlo.


## 4. Bilateral Credit Valuation Adjustment

Unilateral CVA assumes the institution to be risk-free; however, after subprime crisis, people realize that no one is really immune to default risk. A trend that has become increasingly popular, especially since the credit crisis started in 2007, has been to consider the bilateral nature of counterparty risk. This means that an institution would consider a CVA calculated under the assumption that they, as well as their counterparty, may default. Intuitively, using bilateral CVA is compelling, mainly since it has a symmetry that allows the counterparties to agree on a price.However, in the past, the formula of BCVA was based on subtracting the two unilateral credit valuation adjustment (CVA) formulas as seen from the two different parties in the transaction. This formula is only a simplified representation of bilateral risk and ignores the fact that upon the first default close-out proceedings are ignited. As such, it involves double counting. We want to modify it and introduce first to default time so that our formula depends on default dependence between the two parties, whereas the former one does not. Mathematically we have(17)
BCV
A
0
≠
1
-
RE
C
C
E
0
Q
×
D
0
,
τ
c
1
0
≤
τ
c
<
T
E
τ
c
Π
τ
c
,
T
+
-
1
-
RE
C
I
E
0
Q
×
D
0
,
τ
I
1
0
≤
τ
I
<
T
E
τ
I
-
Π
τ
I
,
T
+
.
But rather, given that τ is the first to default time,
(18)
BCV
A
0
=
1
-
RE
C
C
E
0
Q
×
D
0
,
τ
1
0
≤
τ
=
τ
c
<
T
E
τ
Π
τ
,
T
+
-
1
-
RE
C
I
E
0
Q
×
D
0
,
τ
1
0
≤
τ
=
τ
I
<
T
E
τ
-
Π
τ
,
T
+
.
A typical idea would be using copula functions to calculate joint default probability, among which product copula and Gaussian copula are the most commonly used.If two default intensities are supposed to be constant, then we get(19)
Q
τ
c
<
τ
I
,
t
<
τ
c
<
T
=
∫
t
T
Q
x
<
τ
I
,
τ
c
=
x
d
x
=
∫
t
T
λ
c
e
-
∫
0
x
λ
c
1
-
∂
2
C
1
-
e
-
∫
0
x
λ
c
d
x
=
product
λ
c
λ
I
+
λ
c
e
-
λ
I
+
λ
c
t
-
e
-
λ
I
+
λ
c
T
=
gaussian
∫
t
T
λ
C
e
x
λ
c
hhhhhhh
×
1
-
ρ
2
-
1
1
-
Φ
hhhhhhhhh
×
1
-
ρ
2
-
1
Φ
-
1
1
-
e
-
x
λ
I
-
ρ
Φ
-
1
1
-
e
-
x
λ
c
hihhhhhhhhhh
×
1
-
ρ
2
-
1
d
x
.
Intuitively, when the correlation between two default times is larger, two parties tend to default at the same time; therefore UCVA will be offset by DVA to some extent and lead to a BCVA near zero.


## 5. Conclusion

This paper firstly discusses the calculation of unilateral credit valuation adjustment; it can be divided into five steps, giving some definitions about the calculation process of unilateral CVA; then we get the conditional expectation which can help us calculate CVA; in the third step, we explore on the other side all the cash flows during the contract. Through analysis, we get such a result that when we calculate UCVA, we only should take the positive part of MtM into consideration. At last, we get the calculating formula of UCVA. At the third part, we give a numerical example. Then we consider the calculation of bilateral credit valuation adjustment. The main contribution of this paper is the application of least square Monte Carlo methods to the calculation of CVA, which accelerates the convergence rate by a big margin. Another key point is the introduction of first to default time and joint default probability by copula function, which makes bilateral CVA more acceptable and at the same time easy to calculate. Further details remain to be examined by real practice, for example, the calculation of UCVA for different genres of financial products and the choice of copula functions in the calculation of BCVA. Besides, its applications on network model and risk analysis could be paid attention to [19].



---

*Source: 959312-2015-02-17.xml*