14. Given that for all $x \in \mathbf{R}$, $3 \sin ^{2} x-\cos ^{2} x+4 a \cos x+a^{2} \leqslant 31$. Find the range of real numbers $a$.

 untranslated text remains the same as requested.
14. Let $f(x)=3 \sin ^{2} x-\cos ^{2} x+4 a \cos x+a^{2}-31$.

Then $f(x)=-4 \cos ^{2} x+4 a \cos x+a^{2}-28$.
Let $t=\cos x$. Then $t \in[-1,1]$.
Therefore, when $t \in[-1,1]$, we always have
$$
g(t)=-4 t^{2}+4 a t+a^{2}-28 \leqslant 0 \text {. }
$$

Note that the axis of symmetry of the quadratic function $g(t)$ is $t=\frac{a}{2}$.
(1) When $\frac{a}{2}>1$, i.e., $a>2$, $g(t)$ is monotonically increasing on the interval $[-1,1]$.
Thus, the maximum value of $g(t)$ is
$$
g(1)=a^{2}+4 a-32 \leqslant 0 \Rightarrow 2<a \leqslant 4 \text {. }
$$

In summary, the range of values for $a$ is $[-4,4]$.