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”).

A111397
Composite numbers (modulo 3).
1
1, 0, 2, 0, 1, 0, 2, 0, 1, 0, 2, 0, 1, 0, 1, 2, 0, 1, 0, 2, 0, 1, 2, 0, 2, 0, 1, 0, 2, 0, 1, 0, 1, 2, 0, 1, 0, 1, 2, 0, 1, 0, 2, 0, 1, 2, 0, 2, 0, 1, 0, 2, 0, 1, 2, 0, 2, 0, 1, 0, 1, 2, 0, 1, 0, 1, 2, 0, 1, 2, 0, 2, 0, 1, 0, 2, 0, 1, 0, 2, 0, 1, 0, 1, 2, 0, 1, 2, 0, 1, 2, 0, 1, 2, 0, 2, 0, 1, 0, 1, 2, 0, 1, 0, 2
OFFSET
1,3
COMMENTS
If the terms of this sequence are interpreted as the base-3 expansion of a real number, its value is 0.4124999703972179190135867434954940067125524729635148630103267345... and its continued fraction expansion is 0, 2, 2, 2, 1, 4, 5278, 131, 4, 2, 2, 2, 2, 1, 24, 12, 1, 1, 7, 552, 1, 2, 1, ... with increasing partial quotients 2, 4, 5278, 66292, 274715, 420778, 625399, ...
FORMULA
a(n) == A002808(n) (mod 3).
MATHEMATICA
Composite[n_] := FixedPoint[n + PrimePi[ # ] + 1 &, n]; Table[ Mod[Composite[n], 3], {n, 105}]
CROSSREFS
Sequence in context: A035177 A194591 A070105 * A131743 A357860 A147648
KEYWORD
nonn
AUTHOR
Robert G. Wilson v, Nov 11 2005
STATUS
approved