# Vanishing sums of powers modulo n

Is it possible to describe all positive integer sequences $\{x_i\}$ such that $$\sum_i x_i=n \quad \hbox{and} \quad \sum_i x_i^k\equiv 0\pmod n \quad \hbox{for all k (and a given n)?}$$

## Background

We say that two elements of a group belong to the same tribe if their squares are equal. Then

the sum of $k$th powers of tribe sizes is divisible by the order of the group for any positive integer $k$ [http://arxiv.org/abs/1205.2824, Example 1].

This remains true if we replace squares (in the definition of tribes) with cubes or any other powers.

-
If $n$ is prime, then little Fermat implies the only possibility is for each $x_i$ to be 1. If $d$ is any proper divisor of $n$, then there is a solution in which $x_i=d$ for all $i$. –  Gerry Myerson Sep 23 '12 at 12:02
@Gerry, if n is prime, then there are two solutions: n ones and one n. Thanks! –  Anton Klyachko Sep 23 '12 at 12:25