A226872 1 together with even numbers n >= 2 such that 1^n + 2^n + 3^n + ... + n^n == n/2 (mod n).
1, 2, 4, 8, 10, 14, 16, 22, 26, 28, 32, 34, 38, 44, 46, 50, 52, 56, 58, 62, 64, 68, 70, 74, 76, 82, 86, 88, 92, 94, 98, 104, 106, 112, 116, 118, 122, 124, 128, 130, 134, 136, 142, 146, 148, 152, 154, 158, 164, 166, 170, 172, 176, 178, 182, 184, 188, 190, 194, 196
Offset: 1
Keywords
Links
- Charles R Greathouse IV, Table of n, a(n) for n = 1..10000
Programs
-
Mathematica
Join[{1}, Select[Range[200], Mod[Sum[PowerMod[k, #, #], {k, #}], #] == #/2 &]] (* T. D. Noe, Sep 04 2013 *)
-
PARI
is(n)=if(n%2,return(n==1));my(f=factor(n)[,1]);for(i=2,#f,if(n%(f[i]-1)==0,return(0)));1 \\ Charles R Greathouse IV, Sep 04 2013
Comments