12 Transporting goods from a riverside city $A$ to another location $B$. The shortest distance from $B$ to the riverbank $B C=b$ kilometers, and the distance along the river, $A C$, is $a$ kilometers. If the waterway transportation cost is $\frac{1}{n}$ 
($n$ is a real number greater than 1) of the highway transportation cost, a road is to be built from point $B$ to a point $D$ on the riverbank, to minimize the total transportation cost from $A$ to $B$, then $D C=$ $\qquad$ kilometers.
(12) Method 1: Suppose the road transportation cost is 1, then the water transportation cost is $\frac{1}{n}$. Let $D C=x$ kilometers, then

the total transportation cost from $A$ to $B$ is
$$
f(x)=\frac{1}{n}(a-x)+\sqrt{x^{2}+b^{2}} .
$$

Then
$$
\begin{aligned}
f^{\prime}(x) & =-\frac{1}{n}+\frac{2 x}{2 \sqrt{x^{2}+b^{2}}} \\
& =\frac{n x-\sqrt{x^{2}+b^{2}}}{n \sqrt{x^{2}+b^{2}}} .
\end{aligned}
$$

Since $x>0, b>0$, we have
$$
f^{\prime}(x)>0 \Leftrightarrow n x>\sqrt{x^{2}+b^{2}} \Leftrightarrow x^{2}>\frac{b^{2}}{n^{2}-1} \Leftrightarrow x>\sqrt{\frac{b^{2}}{n^{2}-1}} .
$$

Thus, $f^{\prime}(x)=0$, i.e., $x=\frac{b}{\sqrt{n^{2}-1}}$ is the minimum point of $f(x)$, i.e., $D C=$ $\frac{b}{\sqrt{n^{2}-1}}$ (kilometers).
Method 2: Suppose the cost per kilometer of water transportation is $t$ yuan, then the total transportation cost from $A$ to $B$ is
$$
(a-x) t+n t \sqrt{x^{2}+b^{2}}=\left(-x+n \sqrt{x^{2}+b^{2}}\right) t+a t .
$$

Now
$$
y=-x+n \sqrt{x^{2}+b^{2}}>0,
$$

then
$$
(y+x)^{2}=n^{2}\left(x^{2}+b^{2}\right),
$$

i.e.,
$$
\left(n^{2}-1\right) x^{2}-2 y x+n^{2} b^{2}-y^{2}=0 .
$$

Since $x$ is a real number, we have
$$
\Delta=4 y^{2}-4\left(n^{2}-1\right)\left(n^{2} b^{2}-y^{2}\right) \geqslant 0,
$$

solving for $y \geqslant b \sqrt{n^{2}-1}$, with equality holding if and only if $x=\frac{y}{n^{2}-1}=\frac{b}{\sqrt{n^{2}-1}}$, i.e.,
$$
D C=\frac{b}{\sqrt{n^{2}-1}} \text { (kilometers). }
$$