Let $T$ be a measure-preserving and mixing action of a
countable abelian group $G$ on a probability space
$(X,\mathscr S,\mu )$ and $A$ a locally compact second
countable abelian group. A cocycle $c\colon G\times X\to
A$ for $T$ disperses if $\lim_{g\to\infty }c(g,\cdot
)-\alpha (g)=\infty $ in measure for every map $\alpha \colon
G\to A$. We prove that such a cocycle $c$ does not
disperse if and only if there exists a compact subgroup
$A_0\subset A$ such that the composition $\theta \circ c\colon
G\times X\rightarrow A/A_0$ of $c$ with the quotient map
$\theta \colon A\rightarrow A/A_0$ is trivial (i.e.
cohomologous to a homomorphism $\eta \colon G\rightarrow
A/A_0$).This result extends a number of earlier characterizations of
coboundaries and trivial cocycles by tightness conditions on the
distributions of the maps $\{c(g,\cdot ):g\in G\}$ and has
implications for flows under functions: let $T$ be a
measure-preserving ergodic automorphism of a probability
space $(X,\mathscr S,\mu )$, $f\colon X\rightarrow
\mathbb{R}$ be a nonnegative Borel map with $\int f\,d\mu =1$, and
$T^f$ be the flow under the function $f$ with base $T$. Our
main result implies that, if $T$ is mixing and $T^f$ is weakly
mixing, or if $T$ is ergodic and $T^f$ is mixing, then the
cocycle ${\bf f}\colon \mathbb{Z}\times X\rightarrow
\mathbb{R}$ defined by $f$ disperses. The latter statement
answers a question raised by Mariusz Lemańczyk in [7].