Saturday, December 10, 2022

A divisor of a prime power sum will also divide infinite other prime power sums.

For the past two years I've been looking at sums of primes raised to various powers and seeing what can divide them. In particular, if you sum the first n primes each raised to a power k, when is the sum divisible by n?

For example, the sum of the squares of the first 19 primes is divisible by 19:
2**2 + 3**2 + 5**2 + ... + 67**2 = 19*1314
so 19 is a solution for the second power (i.e. k = 2).

Last month I found this theorem about these divisors:

It turns out that if n does divide a power sum of primes, it will* also divide the sum of the same primes raised to a different power. In fact, there are an infinite number of powers that it will satisfy. If n divides the sum of primes to the power of k, it will also divide the sum of primes to the power of k + psi(n), where psi(n) is the Carmichael function (also known as the reduced totient function). In fact, it will divide each of the sums of primes to the power of k + i * psi(n), where i is any integer.

* as long as n is greater than or equal to the maximum power in the prime factorization of k, which is true for all the cases known in the OEIS as of today.

So if 19 is a solution for the 2nd power, it is also a solution for the 20th power as:
2 + psi(19) = 2 + 18 = 20.

Check:
2**20 + 3**20 + 5**20 + ... + 67**20 = 19*217203136831973643667990849432828422

Proof:
Given that sum i=1->n (p_i ** k) mod n = 0 (The sum is over the first n primes.)

and (i ** k) mod n = (i ** (k + psi(n))) mod n, for all integers i, if k > the maximum power in the prime factorization of n

then, sum i=1->n (p_i ** (k + j * psi(n)) mod n = sum i=1->n (p_i ** k) mod n = 0, where j is any positive integer.

Some examples:
19 is a solution for the 2nd power sum, so also a solution for the powers 20, 38, 56...

455 is a solution for the 2nd power sum, so also a solution for the powers 14, 26, 38...

The OEIS only has the solutions for the powers up to 19. 455 is the only case where a value in the OEIS can be predicted from a sequence with a lower power. This is because 455 has a small value of 12 for the Carmichael function.

23 is a solution for the 1st power sum, so also for the powers 23, 45, 67...
23 is a solution for the 13th power, so also for the powers 35, 57, 79...

25 is the solution to many power sums:
25 is a solution for the 3rd power sum, so also a solution for the powers 23, 43, 63...
25 is a solution for the 5th power sum, so also a solution for the powers 25, 45, 65...
25 is a solution for the 7th power sum, so also a solution for the powers 27, 47, 67...
25 is a solution for the 11th power sum, so also a solution for the powers 31, 51, 71...
25 is a solution for the 15th power sum, so also a solution for the powers 35, 55, 75...
25 is a solution for the 19th power sum, so also a solution for the powers 39, 59, 79...

Coincidentally, the first 25 prime numbers are the prime numbers up to 100. From the above, they are a solution for every power ending in 5 (i.e. 5, 15, 25...) and half of the powers ending in 1, 3, 7 and 9. (e.g. 11, 31, 51...)