function [ max_ertek, p, q ] = jacobi_rotate( A )
off_diag = A - diag(diag(A));
[ertek, hely] = max(abs(off_diag));
[max_ertek, q] = max(ertek);
p = hely(q);
end

