login
A354982
a(n) = 1 if n is a prime power congruent to 1 (mod 3), otherwise 0.
3
0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1
OFFSET
1
FORMULA
a(n) = A069513(n) * A079978(n-1).
MATHEMATICA
a[n_] := If[Mod[n, 3] == 1 && PrimePowerQ[n], 1, 0]; Array[a, 100] ( * Amiram Eldar, Jun 15 2022 *)
PROG
(PARI) A354982(n) = ((1==(n%3)) && isprimepower(n));
CROSSREFS
Characteristic function of A137827.
Sequence in context: A107078 A341613 A163533 * A020987 A288372 A354321
KEYWORD
nonn
AUTHOR
Antti Karttunen, Jun 15 2022
STATUS
approved