A problem on matrices: Find the value of $k$ 
If $
        \begin{bmatrix}
        \cos \frac{2 \pi}{7} & -\sin \frac{2 \pi}{7} \\
        \sin \frac{2 \pi}{7} & \cos \frac{2 \pi}{7}  \\
        \end{bmatrix}^k
 = 
        \begin{bmatrix}
        1 & 0 \\
        0 & 1 \\
        \end{bmatrix}
$, then the least positive integral value of $k$ is?

Actually, I got no idea how to solve this.
 I did trial and error method and got 7 as the answer.
how do i solve this? Can you please offer your assistance? Thank you

Look if your matrix is diagonizable. If it is, write it's diagonal form. Let say that $A$ is the matrix you describe in your post, then we will write $B=S^{-1}AS$ its diagonal form where $S$ is the matrix that allows you to change from the canonical base $E$ to a base $G$ where $B$ is diagonal.
Now assume that $A$ is diagonizable you have a diagonal matrix so the problem is to find the smallest integer $k$ for which $\lambda^k_1=1$ and $\lambda^k_2=1$ where $\lambda_1$ and $\lambda_2$ are the eigenvalues of $A$. The answer you will find will be the one you are looking for. Indeed, let's say that $m$ is the smallest value for which $B^m=I_2$ then you have :
$$I_2=B^m=\underbrace{(S^{-1}AS)…(S^{-1}AS)}_{m \text{ times}}=S^{-1}A^mS \implies A^m=I_2$$
