A361534
Let h,i,j be the latest 3 terms in the sequence, starting with a(1)=1, a(2)=2, a(3)=3. Let R = rad(h*i*j), where rad is A007947, and let S be the smallest number of terms in U = {h,i,j} which are divisible by any prime p dividing R. Then, a(n) is the least novel multiple of the greatest such prime p.
Original entry on oeis.org
1, 2, 3, 6, 9, 4, 12, 15, 5, 8, 18, 10, 20, 21, 7, 25, 30, 14, 28, 35, 40, 42, 24, 49, 56, 27, 33, 11, 22, 36, 39, 13, 16, 45, 26, 52, 50, 55, 65, 78, 44, 66, 91, 104, 77, 88, 117, 130, 99, 110, 143, 156, 60, 121, 169, 182, 132, 154, 195, 208, 165, 176, 221, 17, 234, 48, 34, 51, 68, 54, 85, 70, 102
Offset: 1
a(1,2,3) = 1,2,3 and every prime divisor in R divides only one term (S = 1). Since 3 is the greatest such prime, a(4) = 6, the least novel multiple of 3.
a(2,3,4) = 2,3,6 and S = 2 since both 2 and 3 divide two terms in U and no prime divides more than that. Since 3 is the greatest such prime a(5) must be 9.
a(3,4,5) = 3,6,9 and S = 1 because 2|6 but no other term in {3,6,9}, therefore a(6) = 4, the least novel multiple of 2.
-
nn = 120; c[] = False; q[] = 1;
Array[Set[{a[#], c[#]}, {#, True}] &, 3];
Set[{h, i, j}, {a[1], a[2], a[3]}]; u = 4;
w = Array[FactorInteger[#][[All, 1]] &, 3];
Do[g = Reverse@ Union@ Flatten[w];
p = First[
Join @@ Map[ReverseSort,
SplitBy[SortBy[
Table[{p, Count[{h, i, j}, _?(Divisible[#, p] &)]}, {p, g}],
Last], Last]]][[1]] ;
(k = q[#]; While[c[k #], k++]; k *= #; While[c[# q[#]], q[#]++]) &[p];
Set[{a[n], c[k], w, h, i, j}, {k, True,
Append[w[[2 ;; -1]], FactorInteger[k][[All, 1]]], i, j, k}];
If[k == u, While[c[u], u++]], {n, 4, nn}];
Array[a, nn] (* Michael De Vlieger, Mar 15 2023 *)
A361629
For n <= 2, a(n) = n. Thereafter let p be the greatest prime which divides the least number of terms in U = {a(n-2), a(n-1)}, then a(n) is the smallest multiple of p that is not yet in the sequence.
Original entry on oeis.org
1, 2, 4, 6, 3, 8, 9, 12, 10, 5, 14, 7, 16, 21, 28, 15, 35, 42, 20, 49, 56, 18, 63, 70, 25, 77, 11, 84, 22, 33, 24, 44, 55, 30, 66, 88, 27, 99, 110, 40, 121, 132, 36, 143, 13, 154, 26, 39, 45, 52, 65, 50, 78, 91, 98, 104, 117, 48, 130, 156, 60, 169, 182, 105, 195, 208, 75, 221, 17, 234, 34, 51, 54, 68, 85, 80, 102, 119, 112, 136, 153, 57, 19
Offset: 1
a(1,2) = 1,2 and 2 is the smallest p|R = 2 which divides the least number (1) of terms in U = {1,2}. Therefore a(3) = 4, is the least multiple of 2 which has not already occurred.
a(2,3) = 2,4 and since rad(2) = rad(4) = 2, S = 2 then a(4) = 6, the least multiple of 2 which has not occurred earlier.
a(3,4) = 4,6 so S = 1 since 3|6 but not 2, so a(5) = 3, since 3 has not appeared previously.
The sequence after a(1) can be shown as an irregular table of finite subsequences where each row T(n) starts with prime(n) and ends with the first subsequent multiple of prime(n+1). The table includes the fully developed trajectories of 2,7,11,13 with 3,15,24 terms respectively, each having final term in A006094. T(4) starts with 7, ends with 77 and has 3*(prime(5)-1)/2 = 15 terms.
Table T(n) for n = 1..10:
2,4,6
3,8,9,12,10
5,14
7,16,21,28,15,35,42,20,49,56,18,63,70,25,77
11,84,22,33,24,44,55,30,66,88,27,99,110,40,121,132,36,143
13,154,26,39,45,52,65,50,78,91,98,104,117,48,130,156,60,169,182,105,195,208,75,221
17,234,34,51,54,68,85,80,102,119,112,136,153,57
19,69,
23,72,46,92,138,81,115,161,126,184,207,87
29,90,58,116,174,93
- Michael De Vlieger, Table of n, a(n) for n = 1..16384
- Michael De Vlieger, Log log scatterplot of a(n), n = 1..2^20.
- Michael De Vlieger, Log log scatterplot of a(n), n = 1..2^12, showing primes in red, composite prime powers in gold, squarefree composites in green, and numbers neither prime power nor squarefree in blue, accentuating those last-mentioned whose prime power factors have multiplicities exceeding 1 in light blue.
-
Block[{a, c, g, h, i, j, k, p, q, u, w, nn},
nn = 120; c[] = False; q[] = 1;
a[1] = i = 1; a[2] = j = 2; c[1] = c[2] = True; w = {1, 2}; u = 3;
Do[If[Equal @@ w, p = Times @@ w[[1]],
g = Reverse@ Union@ Flatten[w];
p = First[
Join @@ Map[ReverseSort,
SplitBy[SortBy[
Table[{p, Count[{i, j}, _?(Divisible[#, p] &)]}, {p, g}],
Last], Last]] ][[1]] ];
k = q[p]; While[c[k*p], k++]; k *= p; While[c[p*q[p]], q[p]++]
Set[{a[n], c[k], w, i, j},
{k, True, Append[w[[2 ;; -1]], FactorInteger[k][[All, 1]]], j, k}];
If[k == u, While[c[u], u++]], {n, 3, nn}];
Array[a, nn] ] (* Michael De Vlieger, Mar 18 2023 *)
A362631
Lexicographically earliest infinite sequence of distinct positive integers with a(n) = n for n <= 3, and for n > 3 a(n) is the least novel multiple of the greatest prime divisor of a(n-2) which does not divide a(n-1).
Original entry on oeis.org
1, 2, 3, 4, 6, 5, 9, 10, 12, 15, 8, 20, 7, 25, 14, 30, 21, 35, 18, 28, 24, 42, 11, 49, 22, 56, 33, 63, 44, 70, 55, 77, 40, 66, 45, 88, 50, 99, 60, 110, 27, 121, 36, 132, 13, 143, 16, 26, 17, 39, 34, 52, 51, 65, 68, 78, 85, 91, 102, 104, 119, 117, 136, 130, 153, 156, 170, 169, 187, 182, 204, 195, 221, 75, 238, 80, 255, 32, 272, 19
Offset: 1
a(4,5) = 4, 6 and since rad(4)|rad(6) a(6) = least u = 5.
a(11,12) = 8, 20 and since rad(8)|rad(20) a(13) = least u = 7.
a(44,45) = 132, 13 and gpd(132) = 11 does not divide 13, and since it is the 13th occurrence of p = 11, a(46) = 13*11 = 143.
a(45,46) = 13, 143 which forces a(47) = least u = 16 (see Comment).
a(90,91) = 69, 114 and 23 is the greatest prime dividing 69 which does not divide 114. Since 23 has not appeared earlier in the sequence a(92) = 23.
There is as yet no known formula for the row lengths of the table below. Whereas most rows terminate with a multiple of the prime they start with, there are exceptions, e.g., 47, 109. This behavior is open to explanation.
The table starts:
2;
3,4,6;
5,9,10,12,15,8,20;
7,25,14,30,21,35,18,28,24,42;
11,49,22,56,33,63,44,70,55,77,40,66,45,88,50,99,60,110,27,121,36,132;
13,143,16,26;
17,39,34,52,51,65,68,78,85,91,102,104,119,117,136,130,153,156,170,169,187,182,204,195,221,75,238,80,255,32,272;
19,....
- Michael De Vlieger, Table of n, a(n) for n = 1..10000
- Michael De Vlieger, Scatterplot of a(n) n = 1..10000.
- Michael De Vlieger, Log log scatterplot of a(n) n = 1..2^20.
- Michael De Vlieger, Log log scatterplot of a(n), n = 1..10000, showing primes in red, composite prime powers in gold, squarefree composites in green, and numbers neither squarefree nor prime powers in blue. We accentuate powerful numbers that are not prime powers in light blue.
-
mm = 3; nn = 10^4; c[] := False; q[] := 1;
Array[Set[{a[#], c[#]}, {#, True}] &, mm]; q[2]++; u = mm + 1;
i = a[mm - 1]; j = a[mm]; s = {1};
Do[t = FactorInteger[i][[All, 1]];
If[SubsetQ[s, t], q[u]++; Set[k, u],
p = SelectFirst[Reverse@ t, CoprimeQ[j, #] &];
If[! IntegerQ[p], Set[k, u], While[c[p*q[p]], q[p]++]; k = p*q[p]] ];
Set[{a[n], c[k], i, j, s}, {k, True, j, k, t}];
If[k == u, While[c[u], u++]], {n, mm + 1, nn}];
Array[a, nn]
Showing 1-3 of 3 results.
Comments