8. In $\triangle A B C$, the medians $A E, B F$, and $C D$ intersect at $M$. Given that $E, C, F$, and $M$ are concyclic, and $C D=n$. Find the length of segment $A B$.
(18th All-Russian Competition Problem)
8. With $C$ as the center of homothety and 2 as the ratio of homothety, the homothety transformation results in $E \rightarrow B, F \rightarrow A$. The circumcircle of quadrilateral $E C F M$ becomes the circumcircle of $\triangle A B C$, and point $M$ becomes point $G$ on the circumcircle of $\triangle A B C$. Given $C M: M D=2: 1, C M=M G$, we know $M D=D G=$ $\frac{n}{3}$. By the intersecting chords theorem and $B D=D A$, we have $B D \cdot D A=C D \cdot D G$, which is $B D^{2}=n \cdot \frac{n}{3}$, thus $B D=\frac{n}{\sqrt{3}}$, and therefore $A B=\frac{2}{3} \sqrt{3} n$.