login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A166923
Digital root of prime(n)^2.
3
4, 9, 7, 4, 4, 7, 1, 1, 7, 4, 7, 1, 7, 4, 4, 1, 7, 4, 7, 1, 1, 4, 4, 1, 4, 4, 7, 1, 1, 7, 1, 7, 4, 7, 7, 4, 7, 1, 7, 4, 1, 1, 4, 7, 1, 1, 7, 4, 4, 7, 1, 7, 4, 1, 7, 4, 1, 1, 4, 4, 7, 7, 1, 7, 4, 4, 4, 7, 7, 4, 4, 1, 4, 7, 1, 7, 4, 1, 7, 7, 7, 4, 1, 1, 4, 4, 1, 4, 4, 7, 1, 4, 1, 7, 7, 1, 7, 1, 1, 1, 4, 1, 7, 4, 7
OFFSET
1,1
MATHEMATICA
Table[If[(m9=Mod[Prime[n]^2, 9])==0, 9, m9], {n, 200}]
PROG
(Python)
from sympy import prime
def A166923(n):
....return 1 + (prime(n)**2-1) % 9 # Chai Wah Wu, Sep 03 2014
CROSSREFS
Sequence in context: A021909 A018880 A245670 * A021205 A296425 A335089
KEYWORD
base,nonn
AUTHOR
Zak Seidov, Oct 23 2009
EXTENSIONS
Definition corrected by Chai Wah Wu, Sep 03 2014
STATUS
approved