AI for mathematics

Permutations with no whole-number averages

If no proper block of a permutation of 1..n averages to a whole number, then n = 2ᵐ − 1; the asker's example works exactly when n is prime, and n = 15, 63 have none.

Partial progress on an open problem

Permutations with no whole-number averages

Call a permutation of 1, …, n good if no block of consecutive entries, of length at least 2 and other than the whole permutation, has an integer average. Philip Weiss asked on MathOverflow (question 514690) whether, for odd n, good permutations exist exactly when n is a Mersenne prime. Sergiu Alexandru Bîsceanu’s answer, building on a comment by te4, shows that n must be 2^m − 1 (Theorem 1). Whether a composite 2^m − 1 can have a good permutation is open.

This note adds:

  • Theorem 2. For n = 2^m − 1, the asker’s permutation 1, n−1, n, n−3, n−2, …, 2, 3 has an integer-average block exactly at the prefixes whose length divides n. So it is good if and only if n is prime. The proof reads off every block average from the closed form a_t = n + 2 − t − (−1)^t.
  • Theorem 3. For n = 7 and 31 there are exactly four good permutations (the asker’s, its reverse, its complement and the reverse of the complement); for the composite n = 15 and 63 there are none. The search for 63 uses the structure in Bîsceanu’s proof (Corollary 5: a_q = q and positions i, i + q hold values q apart), which halves the search.

Preprint v1, 10 October 2026, not peer reviewed. Theorem 1 (with te4’s congruence), Corollary 5 and Theorem 2 are formally verified in Lean 4 (lean/, standard axioms only); Theorem 3 is computational. The author used AI tools (Claude, Anthropic) in this work, as described in the paper’s acknowledgement, and is responsible for its content.