Continuous-Time Markov Chains and Applications