OFFSET
1,1
LINKS
Clark Kimberling, Table of n, a(n) for n = 1..1000
EXAMPLE
In the following table, mh abbreviates mod(h) and p(n) = prime(n).
n . p(n) . m2 . m3 . m4 . m5 . m6 . m7 . m8 . m9 . m10 . m11 #odd #even
1 . 2 .... 0 .. 0 ........................................... 0 .. 2
2 . 3 .... 0 .. 1 .. 0 ...................................... 1 .. 2
3 . 5 .... 0 .. 1 .. 2 .. 1 .. 0 ............................ 2 .. 3
4 . 7 .... 0 .. 1 .. 1 .. 3 .. 2 .. 1 .. 0 .................. 4 .. 3,
MATHEMATICA
z = 1000; f[n_, m_] := If[EvenQ[Mod[Prime[n], m]], 1, 0]
t = Table[f[n, m], {n, 1, z}, {m, 1, Prime[n]}];
Table[Count[t[[k]], 1], {k, 1, z}] (* A244800 *)
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Clark Kimberling, Jul 06 2014
STATUS
approved