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!)
A297113 a(1) = 0, a(2) = 1, after which, a(n) = a(n/2) if n is of the form 4k+2, and otherwise a(n) = 1+a(A252463(n)). 27
0, 1, 2, 2, 3, 2, 4, 3, 3, 3, 5, 3, 6, 4, 3, 4, 7, 3, 8, 4, 4, 5, 9, 4, 4, 6, 4, 5, 10, 3, 11, 5, 5, 7, 4, 4, 12, 8, 6, 5, 13, 4, 14, 6, 4, 9, 15, 5, 5, 4, 7, 7, 16, 4, 5, 6, 8, 10, 17, 4, 18, 11, 5, 6, 6, 5, 19, 8, 9, 4, 20, 5, 21, 12, 4, 9, 5, 6, 22, 6, 5, 13, 23, 5, 7, 14, 10, 7, 24, 4, 6, 10, 11, 15, 8, 6, 25 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,3
COMMENTS
From Gus Wiseman, Apr 06 2019: (Start)
Also the number of squares in the Young diagram of the integer partition with Heinz number n that are graph-distance 1 from the lower-right boundary, where the Heinz number of an integer partition (y_1,...,y_k) is prime(y_1)*...*prime(y_k). For example, the partition (6,5,5,3) with Heinz number 7865 has diagram
o o o o o o
o o o o o
o o o o o
o o o
with inner rim
o
o
o o
o o o
of size 7, so a(7867) = 7.
(End)
LINKS
FORMULA
a(1) = 0, a(2) = 1, after which, a(n) = a(n/2) if n is of the form 4k+2, and otherwise a(n) = 1+a(A252463(n)) .
For n > 1, a(n) = A001511(A297112(n)), where A297112(n) = Sum_{d|n} moebius(n/d)*A156552(d).
a(n) = A252464(n) - A297155(n).
For n > 1, a(n) = 1+A033265(A156552(n)) = 1+A297167(n) = A046660(n) + A061395(n). - Last two sums added by Antti Karttunen, Sep 02 2018
Other identities. For all n >= 1:
a(A000040(n)) = n. [Each n occurs for the first time at the n-th prime.]
MATHEMATICA
Table[If[n==1, 0, PrimePi[FactorInteger[n][[-1, 1]]]+PrimeOmega[n]-PrimeNu[n]], {n, 100}] (* Gus Wiseman, Apr 06 2019 *)
PROG
(PARI)
A064989(n) = {my(f); f = factor(n); if((n>1 && f[1, 1]==2), f[1, 2] = 0); for (i=1, #f~, f[i, 1] = precprime(f[i, 1]-1)); factorback(f)};
A297113(n) = if(n<=2, n-1, if(n%2, 1+A297113(A064989(n)), !(n%4)+A297113(n/2)));
\\ More complex way, after Moebius transform:
A156552(n) = if(1==n, 0, if(!(n%2), 1+(2*A156552(n/2)), 2*A156552(A064989(n))));
A297112(n) = sumdiv(n, d, moebius(n/d)*A156552(d));
A297113(n) = if(1==n, 0, 1+valuation(A297112(n), 2));
(Scheme, with memoization-macro definec)
(definec (A297113 n) (cond ((<= n 2) (- n 1)) ((= 2 (modulo n 4)) (A297113 (/ n 2))) (else (+ 1 (A297113 (A252463 n))))))
CROSSREFS
One more than A297167 (after the initial term).
Cf. also A297157, A297161, A297162.
Sequence in context: A155043 A337327 A065770 * A086375 A107324 A023522
KEYWORD
nonn
AUTHOR
Antti Karttunen, Dec 26 2017
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 12 20:41 EDT 2024. Contains 372494 sequences. (Running on oeis4.)