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 31-34 of 34 results.

A366737 Number of numbers k <= A056239(n) that can be written as a linear combination of the prime indices of n (allowing coefficients of 0).

Original entry on oeis.org

0, 1, 1, 2, 1, 3, 1, 3, 2, 4, 1, 4, 1, 5, 4, 4, 1, 5, 1, 5, 3, 6, 1, 5, 2, 7, 3, 6, 1, 6, 1, 5, 5, 8, 4, 6, 1, 9, 4, 6, 1, 7, 1, 7, 6, 10, 1, 6, 2, 7, 6, 8, 1, 7, 4, 7, 5, 11, 1, 7, 1, 12, 4, 6, 3, 8, 1, 9, 7, 8, 1, 7, 1, 13, 7, 10, 4, 9, 1, 7, 4, 14, 1, 8, 5
Offset: 1

Views

Author

Gus Wiseman, Oct 19 2023

Keywords

Comments

A prime index of n is a number m such that prime(m) divides n. The multiset of prime indices of n is row n of A112798.

Examples

			The prime indices of 33 are {2,5}, with combinations
  2 = 2
  4 = 2+2
  5 = 5
  6 = 2+2+2
  7 = 5+2
Hence a(33) = 5.
		

Crossrefs

For minimum instead of length we have A055396.
Positions of first appearances are 1, 2, and A100484.
For subsets instead of combinations we have A304793, complement A325799.
A056239 adds up prime indices, row sums of A112798.
A126796 counts complete partitions, ranks A325781, strict A188431.
A276024 counts positive subset-sums of partitions, strict A284640.
A365924 counts incomplete partitions, ranks A365830, strict A365831.

Programs

  • Mathematica
    prix[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];
    combs[n_,y_]:=With[{s=Table[{k,i},{k,y},{i,0,Floor[n/k]}]},Select[Tuples[s],Total[Times@@@#]==n&]];
    Table[Length[Select[Range[Total[prix[n]]],combs[#,prix[n]]!={}&]],{n,30}]

Formula

a(2n) = A056239(2n) - 1 for n > 0.

A305613 Numbers whose multiset of prime factors is not knapsack.

Original entry on oeis.org

30, 60, 70, 72, 84, 90, 120, 140, 144, 150, 168, 180, 210, 216, 240, 252, 270, 280, 286, 288, 300, 308, 330, 336, 350, 360, 378, 390, 420, 432, 440, 450, 480, 490, 495, 504, 510, 525, 528, 540, 560, 570, 572, 576, 588, 594, 600, 616, 630, 646, 648, 660, 672
Offset: 1

Views

Author

Gus Wiseman, Jun 06 2018

Keywords

Comments

A multiset of positive integers is knapsack if every distinct submultiset has a different sum.

Examples

			30 = 2 * 3 * 5 is not knapsack because 2 + 3 = 5.
		

Crossrefs

Programs

  • Mathematica
    Select[Range[1000],DivisorSigma[0,#]=!=Length[Union[Total/@Subsets[Join@@Cases[FactorInteger[#],{p_,k_}:>Table[p,{k}]]]]]&]

A367105 Least positive integer with n more divisors than distinct subset-sums of prime indices.

Original entry on oeis.org

1, 12, 24, 48, 60, 192, 144, 120, 180, 336, 240, 630, 420, 360, 900, 1344, 960, 1008, 720, 840, 2340, 1980, 1260, 1440, 3120, 2640, 1680, 4032, 2880, 6840, 3600, 4620, 3780, 2520, 6480, 11700, 8820, 6300, 7200, 10560, 6720, 12240, 9360, 7920, 5040, 10920, 9240
Offset: 1

Views

Author

Gus Wiseman, Nov 09 2023

Keywords

Comments

A prime index of n is a number m such that prime(m) divides n. The multiset of prime indices of n is row n of A112798.An integer n is a subset-sum (A299701, A304792) of a multiset y if there exists a submultiset of y with sum n.

Examples

			The divisors of 60 are {1,2,3,4,5,6,10,12,15,20,30,60}, and the distinct subset-sums of its prime indices {1,1,2,3} are {0,1,2,3,4,5,6,7}, so the difference is 12 - 8 = 4. Since 60 is the first number with this difference, we have a(4) = 60.
The terms together with their prime indices begin:
     1: {}
    12: {1,1,2}
    24: {1,1,1,2}
    48: {1,1,1,1,2}
    60: {1,1,2,3}
   120: {1,1,1,2,3}
   144: {1,1,1,1,2,2}
   180: {1,1,2,2,3}
   192: {1,1,1,1,1,1,2}
   240: {1,1,1,1,2,3}
   336: {1,1,1,1,2,4}
   360: {1,1,1,2,2,3}
   420: {1,1,2,3,4}
   630: {1,2,2,3,4}
   720: {1,1,1,1,2,2,3}
   840: {1,1,1,2,3,4}
   900: {1,1,2,2,3,3}
   960: {1,1,1,1,1,1,2,3}
		

Crossrefs

The first part (divisors) is A000005.
The second part (subset-sums of prime indices) is A299701, positive A304793.
These are the positions of first appearances in the difference A325801.
The binary version is A367093, firsts of A086971 - A366739.
A001222 counts prime factors (or prime indices), distinct A001221.
A056239 adds up prime indices, row sums of A112798.

Programs

  • Mathematica
    nn=1000;
    w=Table[DivisorSigma[0,n]-Length[Union[Total/@Subsets[prix[n]]]],{n,nn}];
    spnm[y_]:=Max@@Select[Union[y],Function[i,Union[Select[y,#<=i&]]==Range[0,i]]];
    Table[Position[w,k][[1,1]],{k,0,spnm[w]}]

Formula

A000005(a(n)) - A299701(a(n)) = n.

A326019 Heinz numbers of non-knapsack partitions such that every non-singleton submultiset has a different sum.

Original entry on oeis.org

12, 30, 40, 63, 70, 112, 154, 165, 198, 220, 273, 286, 325, 351, 352, 364, 442, 561, 595, 646, 714, 741, 748, 765, 832, 850, 874, 918, 931, 952, 988, 1045, 1173, 1254, 1334, 1425, 1495, 1539, 1564, 1653, 1672, 1771, 1794, 1798, 1900, 2139, 2176, 2204, 2254
Offset: 1

Views

Author

Gus Wiseman, Jun 03 2019

Keywords

Comments

A subsequence of A299729.
The Heinz number of an integer partition (y_1,...,y_k) is prime(y_1)*...*prime(y_k).
An integer partition is knapsack if every distinct submultiset has a different sum.

Examples

			The sequence of terms together with their prime indices begins:
   12: {1,1,2}
   30: {1,2,3}
   40: {1,1,1,3}
   63: {2,2,4}
   70: {1,3,4}
  112: {1,1,1,1,4}
  154: {1,4,5}
  165: {2,3,5}
  198: {1,2,2,5}
  220: {1,1,3,5}
  273: {2,4,6}
  286: {1,5,6}
  325: {3,3,6}
  351: {2,2,2,6}
  352: {1,1,1,1,1,5}
  364: {1,1,4,6}
  442: {1,6,7}
  561: {2,5,7}
  595: {3,4,7}
  646: {1,7,8}
		

Crossrefs

Programs

  • Mathematica
    hwt[n_]:=Total[Cases[FactorInteger[n],{p_,k_}:>PrimePi[p]*k]];
    Select[Range[1000],!UnsameQ@@hwt/@Divisors[#]&&UnsameQ@@hwt/@Select[Divisors[#],!PrimeQ[#]&]&]
Previous Showing 31-34 of 34 results.