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!)
A323073 Number of iterations of A049820(x) = x - A000005(x) needed to reach either zero or such x that x and A049820(x) are coprime, when starting from x = n. 6
0, 0, 1, 0, 0, 0, 2, 0, 1, 3, 3, 0, 3, 0, 4, 0, 0, 0, 4, 0, 5, 0, 5, 0, 1, 0, 6, 0, 6, 0, 6, 0, 7, 0, 7, 0, 1, 0, 8, 0, 8, 0, 8, 0, 9, 1, 9, 0, 9, 0, 10, 0, 10, 0, 10, 0, 10, 0, 11, 0, 10, 0, 12, 1, 0, 0, 12, 0, 13, 0, 13, 0, 11, 0, 14, 1, 14, 0, 14, 0, 14, 0, 15, 0, 12, 0, 16, 0, 15, 0, 15, 0, 17, 0, 16, 0, 13, 0 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,7
LINKS
FORMULA
a(0) = 0; for n > 0, if A009191(n) == 1, a(n) = 0, otherwise a(n) = 1 + a(n-A000005(n)).
a(n) <= A155043(n).
PROG
(PARI) A323073(n) = if(!n, 0, my(nn=(n-numdiv(n))); if(1==gcd(n, nn), 0, 1+A323073(nn)));
(PARI) A323073(n) = if(!n, 0, for(j=0, oo, my(nn=(n-numdiv(n))); if((0==nn)||(1==gcd(n, nn)), return(j+(2==n)), n = nn)));
CROSSREFS
Cf. A046642 (positions of zeros after the initial a(0)=0).
Sequence in context: A242379 A103438 A291556 * A167279 A068920 A363882
KEYWORD
nonn
AUTHOR
Antti Karttunen, Jan 05 2019
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 July 19 09:55 EDT 2024. Contains 374392 sequences. (Running on oeis4.)