Imagine that you work at a financial institution that has a portfolio of 100 different corporate bonds. Rating agencies such as S&P and Moody's rate such bonds, and such rating indicates its credit quality. These ratings are used by investors to assess the probability that the debt will be repaid, with the AAA rating indicating the highest quality bonds (with a very low probability of default) and the CCC rating indicating low quality bonds that have a considerable probability of defaulting. You would like to know, given the current ratings of all bonds, how much of your bond portfolio may default in the five years that you intend to keep this bond portfolio.

A possible technique to determine this credit risk, is to model the ratings and defaults of the portfolio over time with a Markov Chain model.

A link to an example model is provided here:

In this example Markov Chain simulation model:

- A starting situation indicates what the credit rating is of each of the current bonds (at t = 0). As shown below, the current bond portfolio contains 100 bonds of $1,000,000 each, for a total face-value of $100,000,000.

- Within a Markov Chain model, a transition matrix indicates the probability for each of the different transitions between the different states (the states in this case are the credit ratings). For example, in the following (annual) transition matrix, the probability of an AAA bond transitioning to a AA bond is 0.0583, while the probability of a CCC rated bond defaulting (i.e. moving to the default state) is 0.2526. The sum of all probabilities in each row is 1.

- In a Markov Chain model, the credit rating of the whole portfolio of bonds is then simulated over one or multiple years. Because each bond has a probability of keeping the same credit rating, or moving to
*any*of the credit ratings (only a few transitions have a probability of 0), a multinomial probability distribution is to be used to forecast how many bonds will be in each status in each of the upcoming years. For example, the graph below shows a possible realization (i.e. 1 trial) of the number of defaulting bonds within the model.

- In order to estimate the credit risk of the bond portfolio, the number of defaulting loans (and the value of these bonds) was then simulated (50,000 trials) to obtain the following results. The expected amount of defaulting loans is about $10.5M (10.5% of the portfolio value). The Value at Risk, VaR, (5 years, 99%) is $16M, while the Conditional Value at Risk, CVaR, (5 years, 99%) = $16.5M.

It is important to point out that the above example credit risk model assumes that the transition probabilities remain constant during the full 5 year period, which may not be valid. In addition, in the above example, only the current bond portfolio was considered, and no buying of new bonds or selling of existing bonds, is considered.

**Other applications of Markov Chain models**

Markov chain models also have been applied in the following fields:

- Modeling of diseases, where the transition between different disease statuses
- Modeling the impact of preventive maintenance on the statuses of operational software systems
- Transitioning of countries between different social regimes (i.e. from authoritarian to democratic regimes)