6.  The set of positive integers $k$ that make $\left(x^{2}-1\right)^{2 k}+\left(x^{2}+2 x\right)^{2 k}+(2 x+1)^{2 k}=2\left(1+x+x^{2}\right)^{2 k}$ true for all real numbers $x$ is $\qquad$
6. $\{1,2\} k=1$ obviously satisfies the requirement; when $k \geqslant 2$, comparing the coefficients of the $x^{4 k-2}$ term on both sides of the equation, we have: $4 C_{2 k}^{2}-2-C_{2 k} k^{-1}=$ $2 C_{2 k}-2+2 C_{2 k}-1 \Rightarrow 2 k-1=3 \Rightarrow k=2$, checking shows that $k=2$ satisfies the problem statement.