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!)
A125087 a(1)=1. For n>1, a(n) = the number of terms (from among the first n-1 terms of the sequence) that are equal to at least one exponent in the prime factorization of n. 4
1, 1, 2, 1, 3, 3, 3, 3, 1, 4, 4, 5, 4, 4, 4, 5, 4, 5, 4, 5, 4, 4, 4, 8, 1, 5, 4, 6, 5, 5, 5, 8, 5, 5, 5, 1, 6, 6, 6, 10, 6, 6, 6, 7, 7, 6, 6, 17, 1, 8, 7, 8, 7, 11, 7, 11, 7, 7, 7, 8, 7, 7, 8, 9, 7, 7, 7, 8, 7, 7, 7, 5, 7, 7, 8, 8, 7, 7, 7, 18, 11, 7, 7, 8, 7, 7, 7, 11, 7, 8, 7, 8, 7, 7, 7, 19, 7, 8, 8, 1, 8 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,3
LINKS
EXAMPLE
12 = 2^2 * 3^1, So the exponents in the prime-factorization of 12 are 1 and 2. There are 4 terms that equal 1 among the first 11 terms of the sequence. (Those terms are a(1), a(2), a(4), a(9)). There is one term (a(3)) that equals 2. So a(12) = 4+1 = 5.
14 = 2^1 * 7^1. So the only distinct exponent in the prime-factorization of 14 is 1. There are 4 terms from among the first 13 terms of the sequence that equal 1. So a(14) = 4.
MATHEMATICA
f[l_List] :=Append[l, Length @Select[l, MemberQ[Last /@ FactorInteger[Length[l] + 1], # ] &]]; Nest[f, {1}, 100] (* Ray Chandler, Nov 21 2006 *)
PROG
(Maxima) /* program from Katarzyna Matylla, Feb 19 2008: Variable max = how much terms we need. Generating 1000 terms took a few hours: */
"|"(a, b):= if b=0 then true else if a=0 then false else if (floor(b/a))=(b/a) then true else false;
max:1000;
infix("|");
deg(n, p):=if p<2 then 0 else block(d:0, loop, if ((p^(d+1))|n) then d:d+1 else go(end), go(loop), end, d);
f:makelist(0, i, 1, max);
dg:makelist(0, i, 1, max);
f[1]:1;
for n:2 through max do block(for i:2 through n do dg[i]:deg(n, i), k:0, loop1, k:k+1, p:2, loop, if (f[k]=dg[p]) then block(f[n]:f[n]+1, p:n+1), if (p<=n) then p:next_prime(p), if (p<=n) then go(loop), if k<(n-1) then go(loop1));
CROSSREFS
Cf. A125088.
Sequence in context: A048865 A058754 A279909 * A271373 A307558 A226273
KEYWORD
nonn
AUTHOR
Leroy Quet, Nov 19 2006
EXTENSIONS
Extended by Ray Chandler, Nov 21 2006
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 April 24 22:17 EDT 2024. Contains 371964 sequences. (Running on oeis4.)