OFFSET
1,2
COMMENTS
Composites with least prime factor p are on that row of A083140 which begins with p
Sequence with similar values: A122005.
Sequence written as a jagged array A with new row when a(n) > a(n+1):
1, 2, 3,
1, 4, 5, 6,
2, 7, 8, 9,
3, 10, 11,
1, 12,
4, 13, 14, 15,
5, 16,
2, 17, 18,
6, 19, 20, 21,
7, 22, 23,
1, 24,
8, 25, 26,
3, 27,
9, 28, 29, 30.
A153196 is the list B of the first values in successive rows with length 4.
A243811 is the list of the second values in successive rows with length 4.
A047845 is the list of values in the second column and A104279 is the list of values in the third column of the jagged array starting on the second row.
Sequence written as an irregular triangle C with new row when a(n)=1:
1,2,3,
1,4,5,6,2,7,8,9,3,10,11,
1,12,4,13,14,15,5,16,2,17,18,6,19,20,21,7,22,23,
1,24,8,25,26,3,27,9,28,29,30,10,31,4,32,33,11,34,35,36,12,37,2,38,39,13,40,41,5,42,14,43,44,3,45,15,46,6,47,48,16,49,50,51,17,52,53,54,18,55,56,7,57,19,58,4,59.
A243887 is the last value in each row of C.
The second value D on the row n > 1 of the irregular triangle C is a(A053683(n)) or equivalently A084921(n). For example for row 3 of the irregular triangle:
D = a(A053683(3)) = a(16) = 12 or D = A084921(3) = 12. This is the number of composites < A066872(3) with the same least prime factor p as the A053683(3) = 16th composite, A066872(3) = 26.
The number of values in each row of the irregular triangle C begins: 3,11,18,57,39,98,61,141,265,104,351,268,...
The second row of the irregular triangle C is A117385(b) for 3 < b < 15.
The third row of the irregular triangle C has similar values as A117385 in different order.
LINKS
Jamie Morken, Table of n, a(n) for n = 1..10000
FORMULA
EXAMPLE
First composite 4, least prime factor is 2, first case for 2 so a(1)=1.
Next composite 6, least prime factor is 2, second case for 2 so a(2)=2.
Next composite 8, least prime factor is 2, third case for 2 so a(3)=3.
Next composite 9, least prime factor is 3, first case for 3 so a(4)=1.
Next composite 10, least prime factor is 2, fourth case for 2 so a(5)=4.
MATHEMATICA
counts = {}
values = {}
For[i = 2, i < 130, i = i + 1,
If[PrimeQ[i], ,
x = PrimePi[FactorInteger[i][[1, 1]]];
If[Length[counts] >= x,
counts[[x]] = counts[[x]] + 1;
AppendTo[values, counts[[x]]], AppendTo[counts, 1];
AppendTo[values, 1]]]]
(* Print[counts] *)
Print[values]
PROG
(PARI) c(n) = for(k=0, primepi(n), isprime(n++)&&k--); n; \\ A002808
a(n) = my(c=c(n), lpf = vecmin(factor(c)[, 1]), nb=0); for(k=2, c, if (!isprime(k) && vecmin(factor(k)[, 1])==lpf, nb++)); nb; \\ Michel Marcus, Feb 10 2019
CROSSREFS
KEYWORD
nonn,hear
AUTHOR
Jamie Morken and Vincenzo Librandi, Feb 09 2019
STATUS
approved