Question :
Let's suppose $P$ is a probability, $X$ a random variable defined on $\mathbb{Z}$.
Let's suppose we have $|\sum\limits_{k\in \mathbb{Z}}P(X=k)e^{ikt}|=1$ for all $t\in \mathbb{R}$.
Prove that $X$ is almost surely constant.
My attempt :
If we consider the case where $X$ is defined on $\mathbb{N}$, we have $1=|\sum\limits_{k\in \mathbb{Z}}P(X=k)e^{ikt}|\leqslant \sum\limits_{k\in \mathbb{Z}}P(X=k) = 1$ so we have equality in the triangular inequality, but it's a infinite inequality so I'm not sure I can apply the result for the equality case for infinite sum.
Could someone help me ? (there's surely an easiest way than what I tried)
That sum you wrote down is called the characteristic function $\phi(t)=\mathbb E[e^{itX}]$.
Let $Y$ be an iid copy of $X$, then the characteristic function of $X-Y$ is $$\mathbb E[e^{itX}]\cdot\mathbb E[e^{-itY}]=\lvert\phi(t)\rvert^2=1.$$ The unique distribution with characteristic function identically $1$ is the rv that is almost surely $0$, so $X=Y$ almost surely. Then since $X$, $Y$ are iid, $$\mathbb P(X\leq x)=\mathbb P(X\leq x, Y\leq x)=\mathbb P(X\leq x)^2\implies\mathbb P(X\leq x)\in\{0,1\}.$$ This is clearly enough to imply that there is some $a$ in the image of $X$ (which is $\mathbb Z$ in this case) such that $\mathbb P(X=a)=1$.