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

A358136 Irregular triangle read by rows whose n-th row lists the partial sums of the prime indices of n (row n of A112798).

Original entry on oeis.org

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

Views

Author

Gus Wiseman, Oct 31 2022

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

			Triangle begins:
   2: 1
   3: 2
   4: 1 2
   5: 3
   6: 1 3
   7: 4
   8: 1 2 3
   9: 2 4
  10: 1 4
  11: 5
  12: 1 2 4
  13: 6
  14: 1 5
  15: 2 5
  16: 1 2 3 4
  17: 7
  18: 1 3 5
		

Crossrefs

Row-lengths are A001222.
First element in each row is A055396.
Last element in each row is A056239.
Rows are the partial sums of rows of A112798.
Row-sums are A318283.
Sorted Heinz numbers of the rows are A325362.
The version for standard compositions is A358134.
Rows are ranked by A358137.
A000041 counts partitions, strict A000009.
A003963 multiplies prime indices.
A056239 adds up prime indices.

Programs

  • Mathematica
    primeMS[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];
    Table[Accumulate[primeMS[n]],{n,30}]

A359042 Sum of partial sums of the n-th composition in standard order (A066099).

Original entry on oeis.org

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

Views

Author

Gus Wiseman, Dec 20 2022

Keywords

Comments

The k-th composition in standard order (graded reverse-lexicographic, A066099) is obtained by taking the set of positions of 1's in the reversed binary expansion of k, prepending 0, taking first differences, and reversing again. This gives a bijective correspondence between nonnegative integers and integer compositions.

Examples

			The 29th composition in standard order is (1,1,2,1), with partial sums (1,2,4,5), with sum 12, so a(29) = 12.
		

Crossrefs

See link for sequences related to standard compositions.
Each n appears A000009(n) times.
The reverse version is A029931.
Comps counted by this statistic are A053632, ptns A264034, rev ptns A358194.
This is the sum of partial sums of rows of A066099.
The version for Heinz numbers of partitions is A318283, row sums of A358136.
Row sums of A358134.
A011782 counts compositions.
A065120 gives first part of standard compositions, last A001511.
A242628 lists adjusted partial sums, ranked by A253565, row sums A359043.
A358135 gives last minus first of standard compositions.

Programs

  • Mathematica
    stc[n_]:=Differences[Prepend[Join @@ Position[Reverse[IntegerDigits[n,2]],1],0]]//Reverse;
    Table[Total[Accumulate[stc[n]]],{n,0,100}]

A359043 Sum of adjusted partial sums of the n-th composition in standard order (A066099). Row sums of A242628.

Original entry on oeis.org

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

Views

Author

Gus Wiseman, Dec 21 2022

Keywords

Comments

We define the adjusted partial sums of a composition to be obtained by subtracting one from all parts, taking partial sums, and adding one back to all parts.
The k-th composition in standard order (graded reverse-lexicographic, A066099) is obtained by taking the set of positions of 1's in the reversed binary expansion of k, prepending 0, taking first differences, and reversing again. This gives a bijective correspondence between nonnegative integers and integer compositions.

Examples

			The 29th composition in standard order is (1,1,2,1), with adjusted partial sums (1,1,2,2), with sum 6, so a(29) = 6.
		

Crossrefs

See link for sequences related to standard compositions.
The unadjusted reverse version is A029931, row sums of A048793.
The reverse version is A161511, row sums of A125106.
Row sums of A242628, ranked by A253565.
The unadjusted version is A359042, row sums of A358134.
A011782 counts compositions.
A066099 lists standard compositions.
A358135 gives last minus first of standard compositions.
A358194 counts partitions by sum and weighted sum.

Programs

  • Mathematica
    stc[n_]:=Differences[Prepend[Join @@ Position[Reverse[IntegerDigits[n,2]],1],0]]//Reverse;
    Table[Total[Accumulate[stc[n]-1]+1],{n,0,100}]

A358134 Triangle read by rows whose n-th row lists the partial sums of the n-th composition in standard order (row n of A066099).

Original entry on oeis.org

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

Views

Author

Gus Wiseman, Oct 31 2022

Keywords

Comments

The k-th composition in standard order (graded reverse-lexicographic, A066099) is obtained by taking the set of positions of 1's in the reversed binary expansion of k, prepending 0, taking first differences, and reversing again. This gives a bijective correspondence between nonnegative integers and integer compositions.

Examples

			Triangle begins:
  1
  2
  1 2
  3
  2 3
  1 3
  1 2 3
  4
  3 4
  2 4
  2 3 4
  1 4
  1 3 4
  1 2 4
  1 2 3 4
		

Crossrefs

See link for sequences related to standard compositions.
First element in each row is A065120.
Rows are the partial sums of rows of A066099.
Last element in each row is A070939.
An adjusted version is A242628, ranked by A253565.
The first differences instead of partial sums are A358133.
The version for Heinz numbers of partitions is A358136, ranked by A358137.
Row sums are A359042.
A011782 counts compositions.
A351014 counts distinct runs in standard compositions.
A358135 gives last minus first of standard compositions.

Programs

  • Mathematica
    stc[n_]:=Differences[Prepend[Join @@ Position[Reverse[IntegerDigits[n,2]],1],0]]//Reverse;
    Join@@Table[Accumulate[stc[n]],{n,100}]

A358135 Difference of first and last parts of the n-th composition in standard order.

Original entry on oeis.org

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

Views

Author

Gus Wiseman, Oct 31 2022

Keywords

Comments

The k-th composition in standard order (graded reverse-lexicographic, A066099) is obtained by taking the set of positions of 1's in the reversed binary expansion of k, prepending 0, taking first differences, and reversing again. This gives a bijective correspondence between nonnegative integers and integer compositions.

Crossrefs

See link for sequences related to standard compositions.
The first and last parts are A065120 and A001511.
This is the first minus last part of row n of A066099.
The version for Heinz numbers of partitions is A243055.
Row sums of A358133.
The partial sums of standard compositions are A358134, adjusted A242628.
A011782 counts compositions.
A333766 and A333768 give max and min in standard compositions, diff A358138.
A351014 counts distinct runs in standard compositions.

Programs

  • Mathematica
    stc[n_]:=Differences[Prepend[Join @@ Position[Reverse[IntegerDigits[n,2]],1],0]]//Reverse;
    Table[-First[stc[n]]+Last[stc[n]],{n,1,100}]

Formula

a(n) = A001511(n) - A065120(n).

A358170 Heinz number of the partial sums of the n-th composition in standard order (A066099).

Original entry on oeis.org

1, 2, 3, 6, 5, 15, 10, 30, 7, 35, 21, 105, 14, 70, 42, 210, 11, 77, 55, 385, 33, 231, 165, 1155, 22, 154, 110, 770, 66, 462, 330, 2310, 13, 143, 91, 1001, 65, 715, 455, 5005, 39, 429, 273, 3003, 195, 2145, 1365, 15015, 26, 286, 182, 2002, 130, 1430, 910, 10010
Offset: 0

Views

Author

Gus Wiseman, Dec 20 2022

Keywords

Comments

The k-th composition in standard order (graded reverse-lexicographic, A066099) is obtained by taking the set of positions of 1's in the reversed binary expansion of k, prepending 0, taking first differences, and reversing again. This gives a bijective correspondence between nonnegative integers and integer compositions.
The Heinz number of a partition (y_1,...,y_k) is prime(y_1)*...*prime(y_k). This gives a bijective correspondence between positive integers and integer partitions.

Examples

			The terms together with their prime indices begin:
           1: {}
           2: {1}
           3: {2}
           6: {1,2}
           5: {3}
          15: {2,3}
          10: {1,3}
          30: {1,2,3}
           7: {4}
          35: {3,4}
          21: {2,4}
         105: {2,3,4}
          14: {1,4}
          70: {1,3,4}
          42: {1,2,4}
         210: {1,2,3,4}
		

Crossrefs

See link for sequences related to standard compositions.
Applying A001221 or A001222 gives A000120.
The image is A005117 (squarefree numbers).
The reverse version is A019565, triangular version A048793.
Greatest prime index of a(n) is A029837 or A070939.
Least prime index of a(n) is A065120.
The adjusted version is A253565, inverse A253566, reverse A005940.
These are the Heinz numbers of the rows of A358134.
Sum of prime indices of a(n) is A359042.
A066099 lists standard compositions.
A112798 list prime indices, sum A056239.

Programs

  • Mathematica
    stc[n_]:=Differences[Prepend[Join @@ Position[Reverse[IntegerDigits[n,2]],1],0]]//Reverse;
    Times@@Prime/@#&/@Table[Accumulate[stc[n]],{n,0,100}]

A358138 Difference between maximum and minimum part in the n-th composition in standard order.

Original entry on oeis.org

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

Views

Author

Gus Wiseman, Oct 31 2022

Keywords

Comments

The k-th composition in standard order (graded reverse-lexicographic, A066099) is obtained by taking the set of positions of 1's in the reversed binary expansion of k, prepending 0, taking first differences, and reversing again. This gives a bijective correspondence between nonnegative integers and integer compositions.

Crossrefs

See link for sequences related to standard compositions.
The first and last parts are A065120 and A001511, difference A358135.
This is the maximum minus minimum part in row n of A066099.
The version for Heinz numbers of partitions is A243055.
The maximum and minimum parts are A333766 and A333768.
The partial sums of standard compositions are A358134, adjusted A242628.
A011782 counts compositions.
A351014 counts distinct runs in standard compositions.

Programs

  • Mathematica
    stc[n_]:=Differences[Prepend[Join@@Position[Reverse[IntegerDigits[n,2]],1],0]]//Reverse;
    Table[Max[stc[n]]-Min[stc[n]],{n,1,100}]

Formula

a(n) = A333766(n) - A333768(n).
Showing 1-7 of 7 results.