The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A318880 a(n) = 0 if iteration of the map k -> A034460(k) reaches zero when started from k = n, otherwise 1, when it ends into a cycle. 8
0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0 (list; graph; refs; listen; history; text; internal format)
OFFSET
1
COMMENTS
Characteristic function of A003062.
LINKS
FORMULA
a(A003062(n)) = 1, a(A097010(n)) = 0.
MATHEMATICA
a034460[0] = 0; (* avoids dividing by 0 when an iteration reaches 0 *)
a034460[n_] := Total[Select[Divisors[n], GCD[#, n/#]==1&]]-n/; n>0
periodicB[k_] := Boole[NestWhile[a034460, k, UnsameQ, All]!=0]
a318880[n_] := Map[periodicB, Range[n]]
a318880[120] (* Hartmut F. W. Hoft, Jan 25 2024 *)
PROG
(PARI)
A034460(n) = (sumdivmult(n, d, if(gcd(d, n/d)==1, d))-n); \\ From A034460
A318880(n) = { my(visited = Map()); for(j=1, oo, if(mapisdefined(visited, n), return(1), mapput(visited, n, j)); n = A034460(n); if(!n, return(0))); };
CROSSREFS
Sequence in context: A011679 A011682 A185015 * A177063 A341619 A302049
KEYWORD
nonn
AUTHOR
Antti Karttunen, Sep 23 2018
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified May 20 12:27 EDT 2024. Contains 372712 sequences. (Running on oeis4.)