In master's thesis we focused in solving the Sylvester equation and the Lyapunov equation, as a special case of the Sylvester equation, by using ADI methods. If the matrix dimensions in the Sylvester matrix equation are not too large, then it can be solved by means of direct algorithms, such as the Bartels-Stewart method. When we are solving Sylvester equation with sparse matrices of large dimensions, iterative methods, such as ADI methods, are preferred over direct algorithms. In the thesis the connections between the theory of linear control systems and the Lyapunov equation, as a special case of the Sylvester equation, are first presented.At the same time, the assumptions used in the thesis are also presented. Then the Smith method, the ADI method and some of the most important extensions of the ADI method are presented. Next, the selection of shifts, which determine the rate of convergence of ADI methods,is presented. Some approaches to select the shifts are given. Implementations of algorithms from the previous chapters in Matlab are presented. Comparison of shifts and comparison of methods was obtained for some test cases from the online benchmark collection Slicot.