18. (15 points) Let the set $M=\{n \in \mathbf{Z} \mid 0 \leqslant n \leqslant 11\}$, and the set $F=\{(a, b, c, d) \mid a, b, c, d \in M\}$. The mapping $f: F \rightarrow \mathbf{Z}$ is defined such that $(a, b, c, d)$ corresponds to $a b - c d$. If $(u, v, x, y)$ corresponds to 39, and $(u, y, x, v)$ corresponds to 66, find the values of $u, v, x, y$.
18. According to the problem, we have
$$
\left\{\begin{array}{l}
u v - x y = 39, \\
u y - x v = 66 .
\end{array}\right.
$$
Adding (2) and (1) and simplifying, we get
$$
(u - x)(v + y) = 105 = 3 \times 5 \times 7,
$$
Subtracting (1) from (2) and simplifying, we get
$$
(u + x)(y - v) = 27 = 3^{3}.
$$

Since \( x, y, u, v \in M \), we have
$$
\begin{array}{l}
v + y \geqslant 0, u + x \geqslant 0, \\
0 < u - x \leqslant 11, 0 < y - v \leqslant 11,
\end{array}
$$

and
$$
\begin{array}{l}
v + y = \frac{105}{u - x} \geqslant \frac{105}{11} = 9 \frac{6}{11}, \\
u + x = \frac{27}{y - v} \geqslant \frac{27}{11} = 2 \frac{5}{11}.
\end{array}
$$

Thus, \( 10 \leqslant v + y \leqslant 22 \) and \( 3 \leqslant u + x \leqslant 22 \).
From (3), we get
$$
\left\{\begin{array}{l}
u - x = 7, \\
x + y = 15
\end{array}\right.
$$
or
$$
\left\{\begin{array}{l}
u - x = 5, \\
v + y = 21.
\end{array}\right.
$$

But \( u + x \geqslant u - x \), so \( u + x \neq 3 \). Therefore,
$$
\left\{\begin{array}{l}
u - x = 7, \\
v + y = 15, \\
u + x = 9, \\
y - v = 3
\end{array}\right.
$$
or
$$
\left\{\begin{array}{l}
u - x = 5, \\
v + y = 21, \\
u + x = 9, \\
y - v = 3.
\end{array}\right.
$$

Solving the above two sets of equations, we get \( x = 1, y = 9, u = 8, v = 6 \) or \( x = 2, y = 12, u = 7, v = 9 \).

Since \( y = 12 \notin M \), \( x = 2, y = 12, u = 7, v = 9 \) is not valid.
Therefore, \( x = 1, y = 9, u = 8, v = 6 \).