cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

Previous Showing 11-14 of 14 results.

A367098 Number of divisors of n with exactly two distinct prime factors.

Original entry on oeis.org

0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 2, 0, 1, 1, 0, 0, 2, 0, 2, 1, 1, 0, 3, 0, 1, 0, 2, 0, 3, 0, 0, 1, 1, 1, 4, 0, 1, 1, 3, 0, 3, 0, 2, 2, 1, 0, 4, 0, 2, 1, 2, 0, 3, 1, 3, 1, 1, 0, 5, 0, 1, 2, 0, 1, 3, 0, 2, 1, 3, 0, 6, 0, 1, 2, 2, 1, 3, 0, 4, 0, 1, 0, 5, 1, 1, 1
Offset: 1

Views

Author

Gus Wiseman, Nov 09 2023

Keywords

Examples

			The a(n) divisors for n = 1, 6, 12, 24, 36, 60, 72, 120, 144, 216, 288, 360:
  .  6  6   6   6   6   6   6   6    6    6    6
        12  12  12  10  12  10  12   12   12   10
            24  18  12  18  12  18   18   18   12
                36  15  24  15  24   24   24   15
                    20  36  20  36   36   36   18
                        72  24  48   54   48   20
                            40  72   72   72   24
                                144  108  96   36
                                     216  144  40
                                          288  45
                                               72
		

Crossrefs

For just one distinct prime factor we have A001222 (prime-power divisors).
This sequence counts divisors belonging to A007774.
Counting all prime factors gives A086971, firsts A220264.
Column k = 2 of A146289.
- Positions of zeros are A000961 (powers of primes), complement A024619.
- Positions of ones are A006881 (squarefree semiprimes).
- Positions of twos are A054753.
- Positions of first appearances are A367099.
A001221 counts distinct prime factors.
A001358 lists semiprimes, complement A100959.
A367096 lists semiprime divisors, sum A076290.

Programs

  • Mathematica
    Table[Length[Select[Divisors[n], PrimeNu[#]==2&]],{n,100}]
    a[1] = 0; a[n_] := (Total[(e = FactorInteger[n][[;; , 2]])]^2 - Total[e^2])/2; Array[a, 100] (* Amiram Eldar, Jan 08 2024 *)
  • PARI
    a(n) = {my(e = factor(n)[, 2]); (vecsum(e)^2 - e~*e)/2;} \\ Amiram Eldar, Jan 08 2024

Formula

a(n) = (A001222(n)^2 - A090885(n))/2. - Amiram Eldar, Jan 08 2024

A299072 Sequence is an irregular triangle read by rows with zeros removed where T(n,k) is the number of compositions of n whose standard factorization into Lyndon words has k distinct factors.

Original entry on oeis.org

1, 2, 3, 1, 5, 3, 7, 9, 13, 17, 2, 19, 39, 6, 35, 72, 21, 59, 141, 55, 1, 107, 266, 132, 7, 187, 511, 300, 26, 351, 952, 660, 85, 631, 1827, 1395, 240, 3, 1181, 3459, 2901, 636, 15, 2191, 6595, 5977, 1554, 67, 4115, 12604, 12123, 3698, 228, 7711, 24173, 24504
Offset: 1

Views

Author

Gus Wiseman, Feb 01 2018

Keywords

Comments

Row sums are 2^(n-1). First column is A008965. A regular version is A299070.

Examples

			Triangle begins:
    1
    2
    3    1
    5    3
    7    9
   13   17    2
   19   39    6
   35   72   21
   59  141   55    1
  107  266  132    7
  187  511  300   26
		

Crossrefs

Programs

  • Mathematica
    LyndonQ[q_]:=Array[OrderedQ[{q,RotateRight[q,#]}]&,Length[q]-1,1,And]&&Array[RotateRight[q,#]&,Length[q],1,UnsameQ];
    qit[q_]:=If[#===Length[q],{q},Prepend[qit[Drop[q,#]],Take[q,#]]]&[Max@@Select[Range[Length[q]],LyndonQ[Take[q,#]]&]];
    DeleteCases[Table[Length[Select[Join@@Permutations/@IntegerPartitions[n],Length[Union[qit[#]]]===k&]],{n,11},{k,n}],0,{2}]
  • PARI
    \\ here b(n) is A059966.
    b(n)={sumdiv(n, d, moebius(n/d) * (2^d-1))/n}
    A(n)=[Vecrev(p/y) | p<-Vec(prod(k=1, n, (1 - y + y/(1-x^k) + O(x*x^n))^b(k))-1)]
    my(T=A(15)); for(n=1, #T, print(T[n])) \\ Andrew Howroyd, Dec 08 2018

A367099 Least positive integer such that the number of divisors having two distinct prime factors is n.

Original entry on oeis.org

1, 6, 12, 24, 36, 60, 72, 120, 144, 216, 288, 360, 432, 960, 720, 864, 1296, 1440, 1728, 2160, 2592, 3456, 7560, 4320, 5184, 7776, 10800, 8640, 10368, 12960, 15552, 17280, 20736, 40320, 25920, 31104, 41472, 60480, 64800, 51840, 62208, 77760, 93312
Offset: 0

Views

Author

Gus Wiseman, Nov 09 2023

Keywords

Comments

Does this contain every power of six, namely 1, 6, 36, 216, 1296, 7776, ...?
Yes, every power of six is a term, since 6^k = 2^k * 3^k is the least positive integer having n = tau(6^k) - (2k+1) divisors with two distinct prime factors. - Ivan N. Ianakiev, Nov 11 2023

Examples

			The divisors of 60 having two distinct prime factors are: 6, 10, 12, 15, 20. Since 60 is the first number having five such divisors, we have a(5) = 60.
The terms together with their prime indices begin:
     1: {}
     6: {1,2}
    12: {1,1,2}
    24: {1,1,1,2}
    36: {1,1,2,2}
    60: {1,1,2,3}
    72: {1,1,1,2,2}
   120: {1,1,1,2,3}
   144: {1,1,1,1,2,2}
   216: {1,1,1,2,2,2}
   288: {1,1,1,1,1,2,2}
   360: {1,1,1,2,2,3}
   432: {1,1,1,1,2,2,2}
   960: {1,1,1,1,1,1,2,3}
   720: {1,1,1,1,2,2,3}
   864: {1,1,1,1,1,2,2,2}
		

Crossrefs

The version for all divisors is A005179 (firsts of A000005).
For all prime factors (A001222) we have A220264, firsts of A086971.
Positions of first appearances in A367098 (counts divisors in A007774).
A000961 lists prime powers, complement A024619.
A001221 counts distinct prime factors.
A001358 lists semiprimes, squarefree A006881, complement A100959.
A367096 lists semiprime divisors, sum A076290.

Programs

  • Mathematica
    nn=1000;
    w=Table[Length[Select[Divisors[n],PrimeNu[#]==2&]],{n,nn}];
    spnm[y_]:=Max@@NestWhile[Most,y,Union[#]!=Range[0,Max@@#]&];
    Table[Position[w,k][[1,1]],{k,0,spnm[w]}]
  • PARI
    a(n) = my(k=1); while (sumdiv(k, d, omega(d)==2) != n, k++); k; \\ Michel Marcus, Nov 11 2023

A299070 Regular triangle T(n,k) is the number of compositions of n whose standard factorization into Lyndon words has k distinct factors.

Original entry on oeis.org

1, 2, 0, 3, 1, 0, 5, 3, 0, 0, 7, 9, 0, 0, 0, 13, 17, 2, 0, 0, 0, 19, 39, 6, 0, 0, 0, 0, 35, 72, 21, 0, 0, 0, 0, 0, 59, 141, 55, 1, 0, 0, 0, 0, 0, 107, 266, 132, 7, 0, 0, 0, 0, 0, 0, 187, 511, 300, 26, 0, 0, 0, 0, 0, 0, 0
Offset: 1

Views

Author

Gus Wiseman, Feb 01 2018

Keywords

Comments

Row sums are 2^(n-1). First column is A008965. A version without the zeros is A299072.

Examples

			Triangle begins:
    1
    2    0
    3    1    0
    5    3    0    0
    7    9    0    0    0
   13   17    2    0    0    0
   19   39    6    0    0    0    0
   35   72   21    0    0    0    0    0
   59  141   55    1    0    0    0    0    0
  107  266  132    7    0    0    0    0    0    0
  187  511  300   26    0    0    0    0    0    0    0.
The a(5,2) = 9 compositions are (41), (32), (311), (131), (221), (212), (2111), (1211), (1121) with factorizations
    (41) = (4) * (1)
    (32) = (3) * (2)
   (311) = (3) * (1)^2
   (131) = (13) * (1)
   (221) = (2)^2 * (1)
   (212) = (2) * (12)
  (2111) = (2) * (1)^3
  (1211) = (12) * (1)^2
  (1121) = (112) * (1).
		

Crossrefs

Programs

  • Mathematica
    LyndonQ[q_]:=Array[OrderedQ[{q,RotateRight[q,#]}]&,Length[q]-1,1,And]&&Array[RotateRight[q,#]&,Length[q],1,UnsameQ];
    qit[q_]:=If[#===Length[q],{q},Prepend[qit[Drop[q,#]],Take[q,#]]]&[Max@@Select[Range[Length[q]],LyndonQ[Take[q,#]]&]];
    Table[Length[Select[Join@@Permutations/@IntegerPartitions[n],Length[Union[qit[#]]]===k&]],{n,11},{k,n}]
Previous Showing 11-14 of 14 results.