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-8 of 8 results.

A267597 Number of sum-product knapsack partitions of n. Number of integer partitions y of n such that every sum of products of the parts of a multiset partition of any submultiset of y is distinct.

Original entry on oeis.org

1, 1, 1, 1, 1, 2, 3, 3, 4, 4, 6, 7, 8, 12, 12, 14, 18, 23, 23, 32, 30, 35, 50, 48, 47, 56, 80, 77, 87, 105, 100, 134, 139, 145, 194, 170, 192, 250
Offset: 0

Views

Author

Gus Wiseman, Oct 04 2018

Keywords

Examples

			The sequence of product-sum knapsack partitions begins:
   0: ()
   1: (1)
   2: (2)
   3: (3)
   4: (4)
   5: (5) (3,2)
   6: (6) (4,2) (3,3)
   7: (7) (5,2) (4,3)
   8: (8) (6,2) (5,3) (4,4)
   9: (9) (7,2) (6,3) (5,4)
  10: (10) (8,2) (7,3) (6,4) (5,5) (4,3,3)
  11: (11) (9,2) (8,3) (7,4) (6,5) (5,4,2) (5,3,3)
The partition (4,4,3) is not a sum-product knapsack partition of 11 because (4*4) = (4)+(4*3).
A complete list of all sums of products of multiset partitions of submultisets of (5,4,2) is:
            0 = 0
          (2) = 2
          (4) = 4
          (5) = 5
        (2*4) = 8
        (2*5) = 10
        (4*5) = 20
      (2*4*5) = 40
      (2)+(4) = 6
      (2)+(5) = 7
    (2)+(4*5) = 22
      (4)+(5) = 9
    (4)+(2*5) = 14
    (5)+(2*4) = 13
  (2)+(4)+(5) = 11
These are all distinct, so (5,4,2) is a sum-product knapsack partition of 11.
		

Crossrefs

Programs

  • Mathematica
    sps[{}]:={{}};
    sps[set:{i_,_}]:=Join@@Function[s,Prepend[#,s]&/@sps[Complement[set,s]]]/@Cases[Subsets[set],{i,_}];
    mps[set_]:=Union[Sort[Sort/@(#/.x_Integer:>set[[x]])]&/@sps[Range[Length[set]]]];
    rrtuks[n_]:=Select[IntegerPartitions[n],Function[q,UnsameQ@@Apply[Plus,Apply[Times,Union@@mps/@Union[Subsets[q]],{2}],{1}]]];
    Table[Length[rrtuks[n]],{n,12}]

Extensions

a(13)-a(37) from Sean A. Irvine, Jul 13 2022

A320055 Heinz numbers of sum-product knapsack partitions.

Original entry on oeis.org

1, 2, 3, 5, 7, 11, 13, 15, 17, 19, 21, 23, 25, 29, 31, 33, 35, 37, 39, 41, 43, 47, 49, 51, 53, 55, 57, 59, 61, 65, 67, 69, 71, 73, 77, 79, 83, 85, 87, 89, 91, 93, 95, 97, 101, 103, 107, 109, 111, 113, 115, 119, 121, 123, 127, 129, 131, 133, 137, 139, 141, 143
Offset: 1

Views

Author

Gus Wiseman, Oct 04 2018

Keywords

Comments

A sum-product knapsack partition is a finite multiset m of positive integers such that every sum of products of parts of any multiset partition of any submultiset of m is distinct.
The Heinz number of an integer partition (y_1, ..., y_k) is prime(y_1) * ... * prime(y_k).
Differs from A320056 in having 2, 845, ... and lacking 245, 455, 847, ....

Examples

			A complete list of sums of products of multiset partitions of submultisets of the partition (6,6,3) is:
            0 = 0
          (3) = 3
          (6) = 6
        (3*6) = 18
        (6*6) = 36
      (3*6*6) = 108
      (3)+(6) = 9
    (3)+(6*6) = 39
      (6)+(6) = 12
    (6)+(3*6) = 24
  (3)+(6)+(6) = 15
These are all distinct, and the Heinz number of (6,6,3) is 845, so 845 belongs to the sequence.
		

Crossrefs

Programs

  • Mathematica
    multWt[n_]:=If[n==1,1,Times@@Cases[FactorInteger[n],{p_,k_}:>PrimePi[p]^k]];
    facs[n_]:=If[n<=1,{{}},Join@@Table[Map[Prepend[#,d]&,Select[facs[n/d],Min@@#>=d&]],{d,Rest[Divisors[n]]}]];
    Select[Range[100],UnsameQ@@Table[Plus@@multWt/@f,{f,Join@@facs/@Divisors[#]}]&]

A320052 Number of product-sum knapsack partitions of n. Number of integer partitions y of n such that every product of sums of the parts of a multiset partition of any submultiset of y is distinct.

Original entry on oeis.org

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

Views

Author

Gus Wiseman, Oct 04 2018

Keywords

Examples

			The sequence of product-sum knapsack partitions begins:
   0: ()
   1:
   2: (2)
   3: (3)
   4: (4)
   5: (5) (3,2)
   6: (6) (4,2) (3,3)
   7: (7) (5,2) (4,3)
   8: (8) (6,2) (5,3) (4,4)
   9: (9) (7,2) (6,3) (5,4)
  10: (10) (8,2) (7,3) (6,4) (5,5) (4,3,3)
  11: (11) (9,2) (8,3) (7,4) (6,5) (5,4,2) (5,3,3) (4,4,3)
  12: (12) (10,2) (9,3) (8,4) (7,5) (7,3,2) (6,6) (4,4,4)
A complete list of all products of sums of multiset partitions of submultisets of (4,3,3) is:
           () = 1
          (3) = 3
          (4) = 4
        (3+3) = 6
        (3+4) = 7
      (3+3+4) = 10
      (3)*(3) = 9
      (3)*(4) = 12
    (3)*(3+4) = 21
    (4)*(3+3) = 24
  (3)*(3)*(4) = 36
These are all distinct, so (4,3,3) is a product-sum knapsack partition of 10.
		

Crossrefs

Programs

  • Mathematica
    sps[{}]:={{}};
    sps[set:{i_,_}]:=Join@@Function[s,Prepend[#,s]&/@sps[Complement[set,s]]]/@Cases[Subsets[set],{i,_}];
    mps[set_]:=Union[Sort[Sort/@(#/.x_Integer:>set[[x]])]&/@sps[Range[Length[set]]]];
    rrsuks[n_]:=Select[IntegerPartitions[n],Function[q,UnsameQ@@Apply[Times,Apply[Plus,Union@@mps/@Union[Subsets[q]],{2}],{1}]]];
    Table[Length[rrsuks[n]],{n,12}]

A320053 Number of spanning sum-product knapsack partitions of n. Number of integer partitions y of n such that every sum of products of the parts of a multiset partition of y is distinct.

Original entry on oeis.org

1, 1, 2, 3, 2, 3, 4, 5, 6, 8, 9, 12, 14
Offset: 0

Views

Author

Gus Wiseman, Oct 04 2018

Keywords

Examples

			The sequence of spanning sum-product knapsack partitions begins:
  0: ()
  1: (1)
  2: (2) (1,1)
  3: (3) (2,1) (1,1,1)
  4: (4) (3,1)
  5: (5) (4,1) (3,2)
  6: (6) (5,1) (4,2) (3,3)
  7: (7) (6,1) (5,2) (4,3) (3,3,1)
  8: (8) (7,1) (6,2) (5,3) (4,4) (3,3,2)
  9: (9) (8,1) (7,2) (6,3) (5,4) (4,4,1) (4,3,2) (3,3,3)
A complete list of all sums of products covering the parts of (3,3,3,2) is:
        (2*3*3*3) = 54
      (2)+(3*3*3) = 29
      (3)+(2*3*3) = 21
      (2*3)+(3*3) = 15
    (2)+(3)+(3*3) = 14
    (3)+(3)+(2*3) = 12
  (2)+(3)+(3)+(3) = 11
These are all distinct, so (3,3,3,2) is a spanning sum-product knapsack partition of 11.
An example of a spanning sum-product knapsack partition that is not a spanning product-sum knapsack partition is (5,4,3,2).
		

Crossrefs

Programs

  • Mathematica
    sps[{}]:={{}};
    sps[set:{i_,_}]:=Join@@Function[s,Prepend[#,s]&/@sps[Complement[set,s]]]/@Cases[Subsets[set],{i,_}];
    mps[set_]:=Union[Sort[Sort/@(#/.x_Integer:>set[[x]])]&/@sps[Range[Length[set]]]];
    rtuks[n_]:=Select[IntegerPartitions[n],Function[q,UnsameQ@@Apply[Plus,Apply[Times,mps[q],{2}],{1}]]];
    Table[Length[rtuks[n]],{n,8}]

A320054 Number of spanning product-sum knapsack partitions of n. Number of integer partitions y of n such that every product of sums the parts of a multiset partition of y is distinct.

Original entry on oeis.org

1, 1, 2, 3, 2, 4, 5, 8, 10, 12, 16, 17, 25
Offset: 0

Views

Author

Gus Wiseman, Oct 04 2018

Keywords

Examples

			The sequence of spanning product-sum knapsack partitions begins
0: ()
1: (1)
2: (2) (1,1)
3: (3) (2,1) (1,1,1)
4: (4) (3,1)
5: (5) (4,1) (3,2) (3,1,1)
6: (6) (5,1) (4,2) (4,1,1) (3,3)
7: (7) (6,1) (5,2) (5,1,1) (4,3) (4,2,1) (4,1,1,1) (3,3,1)
8: (8) (7,1) (6,2) (6,1,1) (5,3) (5,2,1) (5,1,1,1) (4,4) (4,3,1) (3,3,2)
9: (9) (8,1) (7,2) (7,1,1) (6,3) (6,2,1) (6,1,1,1) (5,4) (5,3,1) (4,4,1) (4,3,2) (3,3,3)
A complete list of all products of sums covering the parts of (4,1,1,1) is:
        (1+1+1+4) = 7
      (1)*(1+1+4) = 6
      (4)*(1+1+1) = 12
      (1+1)*(1+4) = 10
    (1)*(1)*(1+4) = 5
    (1)*(4)*(1+1) = 8
  (1)*(1)*(1)*(4) = 4
These are all distinct, so (4,1,1,1) is a spanning product-sum knapsack partition of 7.
A complete list of all products of sums covering the parts of (5,3,1,1) is:
        (1+1+3+5) = 10
      (1)*(1+3+5) = 9
      (3)*(1+1+5) = 21
      (5)*(1+1+3) = 25
      (1+1)*(3+5) = 16
      (1+3)*(1+5) = 24
    (1)*(1)*(3+5) = 8
    (1)*(3)*(1+5) = 18
    (1)*(5)*(1+3) = 20
    (3)*(5)*(1+1) = 30
  (1)*(1)*(3)*(5) = 15
These are all distinct, so (5,3,1,1) is a spanning product-sum knapsack partition of 10.
An example of a spanning sum-product knapsack partition that is not a spanning product-sum knapsack partition is (5,4,3,2).
		

Crossrefs

Programs

  • Mathematica
    sps[{}]:={{}};
    sps[set:{i_,_}]:=Join@@Function[s,Prepend[#,s]&/@sps[Complement[set,s]]]/@Cases[Subsets[set],{i,_}];
    mps[set_]:=Union[Sort[Sort/@(#/.x_Integer:>set[[x]])]&/@sps[Range[Length[set]]]];
    rsuks[n_]:=Select[IntegerPartitions[n],Function[q,UnsameQ@@Apply[Times,Apply[Plus,mps[q],{2}],{1}]]];
    Table[Length[rsuks[n]],{n,10}]

A320057 Heinz numbers of spanning sum-product knapsack partitions.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 8, 10, 11, 13, 14, 15, 17, 19, 21, 22, 23, 25, 26, 29, 31, 33, 34, 35, 37, 38, 39, 41, 43, 46, 47, 49, 50, 51, 53, 55, 57, 58, 59, 61, 62, 65, 67, 69, 71, 73, 74, 75, 77, 79, 82, 83, 85, 86, 87, 89, 91, 93, 94, 95, 97, 98, 101, 103, 105
Offset: 1

Views

Author

Gus Wiseman, Oct 04 2018

Keywords

Comments

A spanning sum-product knapsack partition is a finite multiset m of positive integers such that every sum of products of parts of any multiset partition of m is distinct.
The Heinz number of an integer partition (y_1, ..., y_k) is prime(y_1) * ... * prime(y_k).
Differs from A320058 in having 1155, 1625, 1815, 1875, 1911, ... and lacking 20, 28, 42, 44, 52, ...

Examples

			The sequence of all spanning sum-product knapsack partitions begins: (), (1), (2), (1,1), (3), (2,1), (4), (1,1,1), (3,1), (5), (6), (4,1), (3,2), (7), (8), (4,2), (5,1), (9), (3,3), (6,1).
A complete list of sums of products of multiset partitions of the partition (5,4,3,2) is:
        (2*3*4*5) = 120
      (2)+(3*4*5) = 62
      (3)+(2*4*5) = 43
      (4)+(2*3*5) = 34
      (5)+(2*3*4) = 29
      (2*3)+(4*5) = 26
      (2*4)+(3*5) = 23
      (2*5)+(3*4) = 22
    (2)+(3)+(4*5) = 25
    (2)+(4)+(3*5) = 21
    (2)+(5)+(3*4) = 19
    (3)+(4)+(2*5) = 17
    (3)+(5)+(2*4) = 16
    (4)+(5)+(2*3) = 15
  (2)+(3)+(4)+(5) = 14
These are all distinct, and the Heinz number of (5,4,3,2) is 1155, so 1155 belongs to the sequence.
		

Crossrefs

Programs

  • Mathematica
    multWt[n_]:=If[n==1,1,Times@@Cases[FactorInteger[n],{p_,k_}:>PrimePi[p]^k]];
    facs[n_]:=If[n<=1,{{}},Join@@Table[Map[Prepend[#,d]&,Select[facs[n/d],Min@@#>=d&]],{d,Rest[Divisors[n]]}]];
    Select[Range[100],UnsameQ@@Table[Plus@@multWt/@f,{f,facs[#]}]&]

A320058 Heinz numbers of spanning product-sum knapsack partitions.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 8, 10, 11, 13, 14, 15, 17, 19, 20, 21, 22, 23, 25, 26, 28, 29, 31, 33, 34, 35, 37, 38, 39, 41, 42, 43, 44, 46, 47, 49, 50, 51, 52, 53, 55, 56, 57, 58, 59, 61, 62, 65, 66, 67, 68, 69, 70, 71, 73, 74, 75, 76, 77, 78, 79, 82, 83, 85, 86, 87
Offset: 1

Views

Author

Gus Wiseman, Oct 04 2018

Keywords

Comments

A spanning product-sum knapsack partition is a finite multiset m of positive integers such that every product of sums of parts of any multiset partition of m is distinct.
The Heinz number of an integer partition (y_1, ..., y_k) is prime(y_1) * ... * prime(y_k).
Differs from A320057 in having 20, 28, 42, 44, 52, ... and lacking 1155, 1625, 1815, 1875, 1911, ....

Examples

			The sequence of all spanning product-sum knapsack partitions begins: (), (1), (2), (1,1), (3), (2,1), (4), (1,1,1), (3,1), (5), (6), (4,1), (3,2), (7), (8), (3,1,1), (4,2), (5,1), (9), (3,3), (6,1), (4,1,1).
A complete list of products of sums of multiset partitions of the partition (3,1,1) is:
      (1+1+3) = 5
    (1)*(1+3) = 4
    (3)*(1+1) = 6
  (1)*(1)*(3) = 3
These are all distinct, and the Heinz number of (3,1,1) is 20, so 20 belongs to the sequence.
		

Crossrefs

Programs

  • Mathematica
    heinzWt[n_]:=If[n==1,0,Total[Cases[FactorInteger[n],{p_,k_}:>k*PrimePi[p]]]];
    facs[n_]:=If[n<=1,{{}},Join@@Table[Map[Prepend[#,d]&,Select[facs[n/d],Min@@#>=d&]],{d,Rest[Divisors[n]]}]];
    Select[Range[100],UnsameQ@@Table[Times@@heinzWt/@f,{f,facs[#]}]&]

A380694 Numbers k such that the prime index of the least prime dividing k is larger than the maximum exponent in the prime factorization of k.

Original entry on oeis.org

3, 5, 7, 11, 13, 15, 17, 19, 21, 23, 25, 29, 31, 33, 35, 37, 39, 41, 43, 47, 49, 51, 53, 55, 57, 59, 61, 65, 67, 69, 71, 73, 77, 79, 83, 85, 87, 89, 91, 93, 95, 97, 101, 103, 105, 107, 109, 111, 113, 115, 119, 121, 123, 127, 129, 131, 133, 137, 139, 141, 143, 145, 149
Offset: 1

Views

Author

Amiram Eldar, Jan 30 2025

Keywords

Comments

Differs from A352830 by having the terms 1225, 13475, 15925, ... and not having the terms 1, 147, 363, 507, 867, 1083, ... .
Differs from A320055 by having the terms 105, 165, 195, ... and not having the terms 1 and 2.
Differs from A320056 by having the terms 105, 165, 195, ... and not having the term 1.
Numbers k such that A055396(k) > A051903(k).
Disjoint union of the sequences S_k, k >= 1, where S_k is the sequence of p-rough numbers (numbers whose prime factors are all greater than or equal to p), with p = prime(k+1), whose maximum exponent in their prime factorization is k (i.e., numbers that are (k+1)-free but not k-free, where k-free numbers are numbers whose prime factorization exponents do not exceed k).
The asymptotic density of this sequence is Sum_{i>=1} d(i) = 0.43156823896267860476......, where d(i), the density of S_i, equals f(i+1) * Product_{primes p <= prime(i)} ((1-1/p)/(1-1/p^(i+1))) - f(i) * Product_{primes p <= prime(i)} ((1-1/p)/(1-1/p^i)), f(i) = 1/zeta(i) if i >= 2, and f(1) = 0.

Examples

			3 = 3^1 is a term since PrimePi(3) = 2 > 1.
9 = 3^2 is not a term since PrimePi(3) = 2 is not larger than the exponent 2.
25 = 5^2 is a term since PrimePi(5) = 3 > 2.
		

Crossrefs

Programs

  • Mathematica
    q[k_] := k > 1 && Module[{f = FactorInteger[k]}, f[[1, 1]] > Prime[Max[f[[;; , 2]]]]]; Select[Range[150], q]
  • PARI
    isok(k) = if(k == 1, 0, my(f = factor(k), e = f[,2]); f[1,1] > prime(vecmax(e)));
Showing 1-8 of 8 results.