Subgroup of O(2) isomorphic to $D_n$, matrices that form that group.
Solution 1:
By definition the question is asking for generators of the isomorphic copy of $D_n$ in $O(2)$.
Hint The usual generators for $D_n$ are $r, s$, satisfying $r^n = s^2 = 1$, $s r = r^{n - 1} s$. So, if we had an map $\phi : D_n \to O(2)$ that is an isomorphism to its image, we could declare $A := \phi(r)$: Then, since $r, s$ generate $D_n$, $A, B$ generate $\phi(D_n)$.
All elements in the nonidentity component $O(2) \setminus SO(2)$ have order $2$, so if $n > 2$, $\phi(r)$ must be in $SO(2)$, which we can identify with the unit circle group $S^1 \cong SO(2)$. Since $r$ has order $n$, so does $A = \phi(r)$.
Additional hint As an element of $S^1$, $A$ is a primitive $n$th root of unity, and the subgroup $\langle A \rangle$ comprises precisely the $n$th roots of unity. If we wish to be concrete, we may as well replace $A$ with the primitive root $\exp \frac{2 \pi i}{n}$, which under the usual isomorphism $S^1 \cong SO(2)$ corresponds to $$A = \pmatrix{\cos \frac{2 \pi}{n} & -\sin \frac{2 \pi}{n} \\ \sin \frac{2 \pi}{n} & \cos \frac{2 \pi}{n}} .$$