Finding eigenvalues of a symmetric matrix using QR Algorithm