16. In Rt $\triangle A B C$, $\angle C=90^{\circ}, A C=11$, point $D$ is on side $A C$ and $A D=10, \angle B D C=$ $3 \angle B A C$. If the perimeter of $\triangle A B C$ is written in the form $\frac{1}{2}(m+\sqrt{n})$ (where $m, n$ are integers), then $m+n=$ $\qquad$ .
16. 638. Let $\angle B A C=\alpha$, then $\angle B D C=3 \alpha, B C=A C \cdot \tan \alpha=C D \cdot \tan 3 \alpha$, so $11 \tan \alpha=\tan 3 \alpha=$ $\frac{\tan \alpha+\tan 2 \alpha}{1-\tan \alpha \cdot \tan 2 \alpha}=\frac{\tan \alpha+2 \tan \alpha /\left(1-\tan ^{2} \alpha\right)}{1-\tan \alpha \cdot 2 \tan \alpha /\left(1-\tan ^{2} \alpha\right)}=\frac{3 \tan \alpha-\tan ^{3} \alpha}{1-3 \tan ^{2} \alpha}$, thus $11-33 \tan ^{2} \alpha=3-\tan ^{2} \alpha$.
That is, $\tan ^{2} \alpha=\frac{1}{4}$, and since $\alpha$ is an acute angle, then $\tan \alpha=\frac{1}{2}, B C=11 \tan \alpha=\frac{11}{2}$,
$\therefore A B=\sqrt{A C^{2}+B C^{2}}=\frac{1}{2} \cdot \sqrt{605}$, perimeter $=\frac{33+\sqrt{605}}{2}$,
$\therefore m+n=33+605=638$.