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.

Showing 1-10 of 61 results. Next

A339846 Number of even-length factorizations of n into factors > 1.

Original entry on oeis.org

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

Views

Author

Gus Wiseman, Dec 28 2020

Keywords

Examples

			The a(n) factorizations for n = 12, 16, 24, 36, 48, 72, 96, 120:
  2*6  2*8      3*8      4*9      6*8      8*9      2*48         2*60
  3*4  4*4      4*6      6*6      2*24     2*36     3*32         3*40
       2*2*2*2  2*12     2*18     3*16     3*24     4*24         4*30
                2*2*2*3  3*12     4*12     4*18     6*16         5*24
                         2*2*3*3  2*2*2*6  6*12     8*12         6*20
                                  2*2*3*4  2*2*2*9  2*2*3*8      8*15
                                           2*2*3*6  2*2*4*6      10*12
                                           2*3*3*4  2*3*4*4      2*2*5*6
                                                    2*2*2*12     2*3*4*5
                                                    2*2*2*2*2*3  2*2*2*15
                                                                 2*2*3*10
		

Crossrefs

The case of set partitions (or n squarefree) is A024430.
The case of partitions (or prime powers) is A027187.
The ordered version is A174725, odd: A174726.
The odd-length factorizations are counted by A339890.
A001055 counts factorizations, with strict case A045778.
A001358 lists semiprimes, with squarefree case A006881.
A027187 counts partitions of even length, ranked by A028260.
A058696 counts partitions of even numbers, ranked by A300061.
A316439 counts factorizations by product and length.
A340102 counts odd-length factorizations into odd factors.

Programs

  • Maple
    g:= proc(n, k, t) option remember; `if`(n>k, 0, t)+
          `if`(isprime(n), 0, add(`if`(d>k, 0, g(n/d, d, 1-t)),
              d=numtheory[divisors](n) minus {1, n}))
        end:
    a:= n-> `if`(n=1, 1, g(n$2, 0)):
    seq(a(n), n=1..100);  # Alois P. Heinz, Dec 30 2020
  • Mathematica
    facs[n_]:=If[n<=1,{{}},Join@@Table[Map[Prepend[#,d]&,Select[facs[n/d],Min@@#>=d&]],{d,Rest[Divisors[n]]}]];
    Table[Length[Select[facs[n],EvenQ@Length[#]&]],{n,100}]
  • PARI
    A339846(n, m=n, e=1) = if(1==n, e, sumdiv(n, d, if((d>1)&&(d<=m), A339846(n/d, d, 1-e)))); \\ Antti Karttunen, Oct 22 2023

Formula

a(n) + A339890(n) = A001055(n).

Extensions

Data section extended up to a(105) by Antti Karttunen, Oct 22 2023

A320655 Number of factorizations of n into semiprimes. Number of multiset partitions of the multiset of prime factors of n, into pairs.

Original entry on oeis.org

1, 0, 0, 1, 0, 1, 0, 0, 1, 1, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 1, 1, 1, 2, 0, 1, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 1, 0, 0, 1, 1, 1, 1, 1, 0, 2, 0, 1, 0, 1, 1, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 1, 1, 0, 2, 1, 1, 1, 1, 0, 2, 1, 0, 1, 1, 1, 1, 0, 0, 0, 2, 0, 0, 0, 1, 0
Offset: 1

Views

Author

Gus Wiseman, Oct 18 2018

Keywords

Comments

The characteristic function of nonzero terms is A065043. - R. J. Mathar, Jan 18 2021

Examples

			The a(900) = 5 factorizations into semiprimes:
  900 = (4*9*25)
  900 = (4*15*15)
  900 = (6*6*25)
  900 = (6*10*15)
  900 = (9*10*10)
The a(900) = 5 multiset partitions into pairs:
  {{1,1},{2,2},{3,3}}
  {{1,1},{2,3},{2,3}}
  {{1,2},{1,2},{3,3}}
  {{1,2},{1,3},{2,3}}
  {{2,2},{1,3},{1,3}}
		

Crossrefs

Programs

  • Mathematica
    semfacs[n_]:=If[n<=1,{{}},Join@@Table[Map[Prepend[#,d]&,Select[semfacs[n/d],Min@@#>=d&]],{d,Select[Rest[Divisors[n]],PrimeOmega[#]==2&]}]];
    Table[Length[semfacs[n]],{n,100}]
  • PARI
    A320655(n, m=n) = if(1==n, 1, my(s=0); fordiv(n, d, if((2==bigomega(d)&&(d<=m)), s += A320655(n/d, d))); (s)); \\ Antti Karttunen, Dec 06 2020

Extensions

Data section extended up to 105 terms by Antti Karttunen, Dec 06 2020

A320911 Numbers with an even number of prime factors (counted with multiplicity) that can be factored into squarefree semiprimes.

Original entry on oeis.org

1, 6, 10, 14, 15, 21, 22, 26, 33, 34, 35, 36, 38, 39, 46, 51, 55, 57, 58, 60, 62, 65, 69, 74, 77, 82, 84, 85, 86, 87, 90, 91, 93, 94, 95, 100, 106, 111, 115, 118, 119, 122, 123, 126, 129, 132, 133, 134, 140, 141, 142, 143, 145, 146, 150, 155, 156, 158, 159
Offset: 1

Views

Author

Gus Wiseman, Oct 23 2018

Keywords

Comments

A squarefree semiprime (A006881) is a product of any two distinct primes.
Also numbers with an even number x of prime factors, whose prime multiplicities do not exceed x/2.

Examples

			360 is in the sequence because it can be factored into squarefree semiprimes as (6*6*10).
4620 is in the sequence, and can be factored into squarefree semiprimes in 6 ways: (6*10*77), (6*14*55), (6*22*35), (10*14*33), (10*21*22), (14*15*22).
		

Crossrefs

Programs

  • Mathematica
    sqfsemfacs[n_]:=If[n<=1,{{}},Join@@Table[Map[Prepend[#,d]&,Select[sqfsemfacs[n/d],Min@@#>=d&]],{d,Select[Rest[Divisors[n]],And[SquareFreeQ[#],PrimeOmega[#]==2]&]}]];
    Select[Range[100],And[EvenQ[PrimeOmega[#]],sqfsemfacs[#]!={}]&]

A338899 Concatenated sequence of prime indices of squarefree semiprimes (A006881).

Original entry on oeis.org

1, 2, 1, 3, 1, 4, 2, 3, 2, 4, 1, 5, 1, 6, 2, 5, 1, 7, 3, 4, 1, 8, 2, 6, 1, 9, 2, 7, 3, 5, 2, 8, 1, 10, 1, 11, 3, 6, 2, 9, 1, 12, 4, 5, 1, 13, 3, 7, 1, 14, 2, 10, 4, 6, 2, 11, 1, 15, 3, 8, 1, 16, 2, 12, 3, 9, 1, 17, 4, 7, 1, 18, 2, 13, 2, 14, 4, 8, 1, 19, 2, 15
Offset: 1

Views

Author

Gus Wiseman, Nov 16 2020

Keywords

Comments

This is a triangle with two columns and strictly increasing rows, namely {A270650(n), A270652(n)}.
A squarefree semiprime is a product of any two distinct prime numbers. A prime index of n is a number m such that the m-th prime number divides n. The multiset of prime indices of n is row n of A112798.

Examples

			The sequence of terms together with their prime indices begins:
      6: {1,2}     57: {2,8}     106: {1,16}    155: {3,11}
     10: {1,3}     58: {1,10}    111: {2,12}    158: {1,22}
     14: {1,4}     62: {1,11}    115: {3,9}     159: {2,16}
     15: {2,3}     65: {3,6}     118: {1,17}    161: {4,9}
     21: {2,4}     69: {2,9}     119: {4,7}     166: {1,23}
     22: {1,5}     74: {1,12}    122: {1,18}    177: {2,17}
     26: {1,6}     77: {4,5}     123: {2,13}    178: {1,24}
     33: {2,5}     82: {1,13}    129: {2,14}    183: {2,18}
     34: {1,7}     85: {3,7}     133: {4,8}     185: {3,12}
     35: {3,4}     86: {1,14}    134: {1,19}    187: {5,7}
     38: {1,8}     87: {2,10}    141: {2,15}    194: {1,25}
     39: {2,6}     91: {4,6}     142: {1,20}    201: {2,19}
     46: {1,9}     93: {2,11}    143: {5,6}     202: {1,26}
     51: {2,7}     94: {1,15}    145: {3,10}    203: {4,10}
     55: {3,5}     95: {3,8}     146: {1,21}    205: {3,13}
		

Crossrefs

A270650 is the first column.
A270652 is the second column.
A320656 counts multiset partitions using these rows, or factorizations into squarefree semiprimes.
A338898 is the version including squares, with columns A338912 and A338913.
A338900 gives row differences.
A338901 gives the row numbers for first appearances.
A001221 and A001222 count distinct/all prime indices.
A001358 lists semiprimes.
A004526 counts 2-part partitions, with strict case shifted right once.
A005117 lists squarefree numbers.
A006881 lists squarefree semiprimes.
A046315 and A100484 list odd and even semiprimes.
A046388 lists odd squarefree semiprimes.
A166237 gives first differences of squarefree semiprimes.

Programs

  • Mathematica
    Join@@Cases[Select[Range[100],SquareFreeQ[#]&&PrimeOmega[#]==2&],k_:>PrimePi/@First/@FactorInteger[k]]

A340653 Number of balanced factorizations of n.

Original entry on oeis.org

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

Views

Author

Gus Wiseman, Jan 15 2021

Keywords

Comments

A factorization into factors > 1 is balanced if it is empty or its length is equal to its maximum Omega (A001222).

Examples

			The balanced factorizations for n = 120, 144, 192, 288, 432, 768:
  3*5*8    2*8*9    3*8*8      4*8*9      6*8*9      8*8*12
  2*2*30   3*6*8    4*6*8      6*6*8      2*8*27     2*2*8*24
  2*3*20   2*4*18   2*8*12     2*8*18     3*8*18     2*3*8*16
  2*5*12   2*6*12   4*4*12     3*8*12     4*4*27     2*4*4*24
           3*4*12   2*2*2*24   4*4*18     4*6*18     2*4*6*16
                    2*2*3*16   4*6*12     4*9*12     3*4*4*16
                               2*12*12    6*6*12     2*2*12*16
                               2*2*2*36   2*12*18    2*2*2*2*48
                               2*2*3*24   3*12*12    2*2*2*3*32
                               2*3*3*16   2*2*2*54
                                          2*2*3*36
                                          2*3*3*24
                                          3*3*3*16
		

Crossrefs

Positions of zeros are A001358.
Positions of nonzero terms are A100959.
The co-balanced version is A340596.
Taking maximum factor instead of maximum Omega gives A340599.
The cross-balanced version is A340654.
The twice-balanced version is A340655.
A001055 counts factorizations.
A045778 counts strict factorizations.
A316439 counts factorizations by product and length.
A320655 counts factorizations into semiprimes.
Other balance-related sequences:
- A010054 counts balanced strict partitions.
- A047993 counts balanced partitions.
- A098124 counts balanced compositions.
- A106529 lists Heinz numbers of balanced partitions.
- A340597 have an alt-balanced factorization.
- A340598 counts balanced set partitions.
- A340600 counts unlabeled balanced multiset partitions.
- A340656 have no twice-balanced factorizations.
- A340657 have a twice-balanced factorization.

Programs

  • Mathematica
    facs[n_]:=If[n<=1,{{}},Join@@Table[Map[Prepend[#,d]&,Select[facs[n/d],Min@@#>=d&]],{d,Rest[Divisors[n]]}]];
    Table[Length[Select[facs[n],#=={}||Length[#]==Max[PrimeOmega/@#]&]],{n,100}]
  • PARI
    A340653(n, m=n, mbo=0, e=0) = if(1==n, mbo==e, sumdiv(n, d, if((d>1)&&(d<=m), A340653(n/d, d, max(mbo,bigomega(d)), 1+e)))); \\ Antti Karttunen, Oct 22 2023

Extensions

Data section extended up to a(120) by Antti Karttunen, Oct 22 2023

A320892 Numbers with an even number of prime factors (counted with multiplicity) that cannot be factored into distinct semiprimes.

Original entry on oeis.org

16, 64, 81, 96, 144, 160, 224, 256, 324, 352, 384, 400, 416, 486, 544, 576, 608, 625, 640, 729, 736, 784, 864, 896, 928, 960, 992, 1024, 1184, 1215, 1296, 1312, 1344, 1376, 1408, 1440, 1504, 1536, 1600, 1664, 1696, 1701, 1888, 1936, 1944, 1952, 2016, 2025
Offset: 1

Views

Author

Gus Wiseman, Oct 23 2018

Keywords

Comments

A semiprime (A001358) is a product of any two not necessarily distinct primes.
If A025487(k) is in the sequence then so is every number with the same prime signature. - David A. Corneth, Oct 23 2018
Numbers for which A001222(n) is even and A322353(n) is zero. - Antti Karttunen, Dec 06 2018

Examples

			A complete list of all factorizations of 1296 into semiprimes is:
  1296 = (4*4*9*9)
  1296 = (4*6*6*9)
  1296 = (6*6*6*6)
None of these is strict, so 1296 belongs to the sequence.
		

Crossrefs

Programs

  • Mathematica
    strsemfacs[n_]:=If[n<=1,{{}},Join@@Table[Map[Prepend[#,d]&,Select[strsemfacs[n/d],Min@@#>d&]],{d,Select[Rest[Divisors[n]],PrimeOmega[#]==2&]}]];
    Select[Range[1000],And[EvenQ[PrimeOmega[#]],strsemfacs[#]=={}]&]
  • PARI
    A322353(n, m=n, facs=List([])) = if(1==n, my(u=apply(bigomega,Vec(facs))); (0==length(u)||(2==vecmin(u)&&2==vecmax(u))), my(s=0, newfacs); fordiv(n, d, if((d>1)&&(d<=m), newfacs = List(facs); listput(newfacs,d); s += A322353(n/d, d-1, newfacs))); (s));
    isA300892(n) = if(bigomega(n)%2,0,(0==A322353(n))); \\ Antti Karttunen, Dec 06 2018

A320663 Number of non-isomorphic multiset partitions of weight n using singletons or pairs.

Original entry on oeis.org

1, 1, 4, 7, 21, 40, 106, 216, 534, 1139, 2715, 5962, 14012, 31420, 73484, 167617, 392714, 908600, 2140429, 5015655, 11905145, 28228533, 67590229, 162067916, 391695348, 949359190, 2316618809, 5673557284, 13979155798, 34583650498, 86034613145, 214948212879
Offset: 0

Views

Author

Gus Wiseman, Oct 18 2018

Keywords

Examples

			Non-isomorphic representatives of the a(1) = 1 through a(4) = 21 multiset partitions:
  {{1}}  {{1,1}}    {{1},{1,1}}    {{1,1},{1,1}}
         {{1,2}}    {{1},{2,2}}    {{1,1},{2,2}}
         {{1},{1}}  {{1},{2,3}}    {{1,2},{1,2}}
         {{1},{2}}  {{2},{1,2}}    {{1,2},{2,2}}
                    {{1},{1},{1}}  {{1,2},{3,3}}
                    {{1},{2},{2}}  {{1,2},{3,4}}
                    {{1},{2},{3}}  {{1,3},{2,3}}
                                   {{1},{1},{1,1}}
                                   {{1},{1},{2,2}}
                                   {{1},{1},{2,3}}
                                   {{1},{2},{1,2}}
                                   {{1},{2},{2,2}}
                                   {{1},{2},{3,3}}
                                   {{1},{2},{3,4}}
                                   {{1},{3},{2,3}}
                                   {{2},{2},{1,2}}
                                   {{1},{1},{1},{1}}
                                   {{1},{1},{2},{2}}
                                   {{1},{2},{2},{2}}
                                   {{1},{2},{3},{3}}
                                   {{1},{2},{3},{4}}
		

Crossrefs

Programs

  • PARI
    EulerT(v)={Vec(exp(x*Ser(dirmul(v,vector(#v,n,1/n))))-1, -#v)}
    permcount(v) = {my(m=1,s=0,k=0,t); for(i=1,#v,t=v[i]; k=if(i>1&&t==v[i-1],k+1,1); m*=t*k;s+=t); s!/m}
    gs(v) = {sum(i=2, #v, sum(j=1, i-1, my(g=gcd(v[i],v[j])); g*x^(2*v[i]*v[j]/g))) + sum(i=1, #v, my(r=v[i]); (1 + (1+r)%2)*x^r + ((1+r)\2)*x^(2*r))}
    a(n)={my(s=0); forpart(p=n, s+=permcount(p)*EulerT(Vec(gs(p) + O(x*x^n), -n))[n]); s/n!} \\ Andrew Howroyd, Oct 26 2018

Extensions

Terms a(11) and beyond from Andrew Howroyd, Oct 26 2018

A320891 Numbers with an even number of prime factors (counted with multiplicity) that cannot be factored into squarefree semiprimes.

Original entry on oeis.org

4, 9, 16, 24, 25, 40, 49, 54, 56, 64, 81, 88, 96, 104, 121, 135, 136, 144, 152, 160, 169, 184, 189, 224, 232, 240, 248, 250, 256, 289, 296, 297, 324, 328, 336, 344, 351, 352, 361, 375, 376, 384, 400, 416, 424, 459, 472, 486, 488, 513, 528, 529, 536, 544, 560
Offset: 1

Views

Author

Gus Wiseman, Oct 23 2018

Keywords

Comments

A squarefree semiprime (A006881) is a product of any two distinct primes.
Also numbers with an even number x of prime factors, whose greatest prime multiplicity exceeds x/2.

Examples

			A complete list of all factorizations of 24 is:
  (2*2*2*3),
  (2*2*6), (2*3*4),
  (2*12), (3*8), (4*6),
  (24).
All of these contain at least one number that is not a squarefree semiprime, so 24 belongs to the sequence.
		

Crossrefs

Programs

  • Mathematica
    semfacs[n_]:=If[n<=1,{{}},Join@@Table[Map[Prepend[#,d]&,Select[semfacs[n/d],Min@@#>=d&]],{d,Select[Rest[Divisors[n]],And[SquareFreeQ[#],PrimeOmega[#]==2]&]}]];
    Select[Range[100],And[EvenQ[PrimeOmega[#]],semfacs[#]=={}]&]

A320894 Numbers with an even number of prime factors (counted with multiplicity) that cannot be factored into distinct squarefree semiprimes.

Original entry on oeis.org

4, 9, 16, 24, 25, 36, 40, 49, 54, 56, 64, 81, 88, 96, 100, 104, 121, 135, 136, 144, 152, 160, 169, 184, 189, 196, 216, 224, 225, 232, 240, 248, 250, 256, 289, 296, 297, 324, 328, 336, 344, 351, 352, 360, 361, 375, 376, 384, 400, 416, 424, 441, 459, 472, 484
Offset: 1

Views

Author

Gus Wiseman, Oct 23 2018

Keywords

Comments

A squarefree semiprime (A006881) is a product of any two distinct primes.

Examples

			A complete list of all strict factorizations of 24 is: (2*3*4), (2*12), (3*8), (4*6), (24). All of these contain at least one number that is not a squarefree semiprime, so 24 belongs to the sequence.
		

Crossrefs

Programs

  • Mathematica
    strsqfsemfacs[n_]:=If[n<=1,{{}},Join@@Table[Map[Prepend[#,d]&,Select[strsqfsemfacs[n/d],Min@@#>d&]],{d,Select[Rest[Divisors[n]],And[SquareFreeQ[#],PrimeOmega[#]==2]&]}]];
    Select[Range[100],And[EvenQ[PrimeOmega[#]],strsqfsemfacs[#]=={}]&]

A338900 Difference between the two prime indices of the n-th squarefree semiprime.

Original entry on oeis.org

1, 2, 3, 1, 2, 4, 5, 3, 6, 1, 7, 4, 8, 5, 2, 6, 9, 10, 3, 7, 11, 1, 12, 4, 13, 8, 2, 9, 14, 5, 15, 10, 6, 16, 3, 17, 11, 12, 4, 18, 13, 19, 1, 7, 20, 8, 21, 14, 5, 22, 15, 23, 16, 9, 2, 24, 17, 25, 6, 10, 26, 3, 18, 27, 11, 7, 28, 19, 1, 29, 12, 20, 2, 21, 4
Offset: 1

Views

Author

Gus Wiseman, Nov 16 2020

Keywords

Comments

A squarefree semiprime is a product of any two distinct prime numbers. A prime index of n is a number m such that the m-th prime number divides n. The multiset of prime indices of n is row n of A112798.
Is this sequence an anti-run, i.e., are there no adjacent equal parts? I have verified this conjecture up to n = 10^6. - Gus Wiseman, Nov 18 2020

Crossrefs

A176506 is the not necessarily squarefree version.
A338899 has row-differences equal to this sequence.
A338901 gives positions of first appearances.
A001221 counts distinct prime indices.
A001222 counts prime indices.
A001358 lists semiprimes.
A002100 and A338903 count partitions using squarefree semiprimes.
A004526 counts 2-part partitions, with strict case A140106 (shifted left).
A005117 lists squarefree numbers.
A006881 lists squarefree semiprimes, with odds A046388 and evens A100484.
A065516 gives first differences of semiprimes.
A166237 gives first differences of squarefree semiprimes.
A270650 and A270652 give the prime indices of squarefree semiprimes.
A338912 and A338913 give the prime indices of semiprimes.

Programs

  • Mathematica
    -Subtract@@PrimePi/@First/@FactorInteger[#]&/@Select[Range[100],SquareFreeQ[#]&&PrimeOmega[#]==2&]

Formula

If the n-th squarefree semiprime is prime(x) * prime(y) with x < y, then a(n) = y - x.
a(n) = A270652(n) - A270650(n).
Showing 1-10 of 61 results. Next