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.

A359755 Positions of first appearances in the sequence of weighted sums of prime indices (A304818).

Original entry on oeis.org

1, 2, 3, 4, 6, 7, 8, 10, 12, 15, 16, 18, 20, 24, 26, 28, 36, 40, 46, 48, 50, 52, 56, 62, 68, 74, 76, 86, 88, 92, 94, 106, 107, 118, 122, 124, 131, 134, 136, 142, 146, 152, 158, 164, 166, 173, 178, 188, 193, 194, 199, 202, 206, 214, 218, 226, 229, 236, 239, 254
Offset: 1

Views

Author

Gus Wiseman, Jan 15 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.
The weighted sum of a sequence (y_1,...,y_k) is Sum_{i=1..k} i*y_i.

Examples

			The terms together with their prime indices begin:
    1: {}
    2: {1}
    3: {2}
    4: {1,1}
    6: {1,2}
    7: {4}
    8: {1,1,1}
   10: {1,3}
   12: {1,1,2}
   15: {2,3}
   16: {1,1,1,1}
   18: {1,2,2}
   20: {1,1,3}
   24: {1,1,1,2}
		

Crossrefs

The version for standard compositions is A089633, zero-based A359756.
Positions of first appearances in A304818, reverse A318283.
The zero-based version is A359675, unsorted A359676.
The reverse zero-based version is A359680, unsorted A359681.
This is the sorted version of A359682, reverse A359679.
The reverse version is A359754.
A053632 counts compositions by weighted sum.
A112798 lists prime indices, length A001222, sum A056239.
A320387 counts multisets by weighted sum, zero-based A359678.
A358136 lists partial sums of prime indices, ranked by A358137, rev A359361.

Programs

  • Mathematica
    nn=1000;
    primeMS[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];
    ots[y_]:=Sum[i*y[[i]],{i,Length[y]}];
    seq=Table[ots[primeMS[n]],{n,1,nn}];
    Select[Range[nn],FreeQ[seq[[Range[#-1]]],seq[[#]]]&]

A124757 Zero-based weighted sum of compositions in standard order.

Original entry on oeis.org

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

Views

Author

Keywords

Comments

The standard order of compositions is given by A066099.
Sum of all positions of 1's except the last in the reversed binary expansion of n. For example, the reversed binary expansion of 14 is (0,1,1,1), so a(14) = 2 + 3 = 5. Keeping the last position gives A029931. - Gus Wiseman, Jan 17 2023

Examples

			Composition number 11 is 2,1,1; 0*2+1*1+2*1 = 3, so a(11) = 3.
The table starts:
  0
  0
  0 1
  0 1 2 3
		

Crossrefs

Cf. A066099, A070939, A029931, A011782 (row lengths), A001788 (row sums).
Row sums of A048793 if we delete the last part of every row.
For prime indices instead of standard comps we have A359674, rev A359677.
Positions of first appearances are A359756.
A003714 lists numbers with no successive binary indices.
A030190 gives binary expansion, reverse A030308.
A230877 adds up positions of 1's in binary expansion, length A000120.
A359359 adds up positions of 0's in binary expansion, length A023416.

Programs

  • Mathematica
    Table[Total[Most[Join@@Position[Reverse[IntegerDigits[n,2]],1]]],{n,30}]

Formula

For a composition b(1),...,b(k), a(n) = Sum_{i=1..k} (i-1)*b(i).
For n>0, a(n) = A029931(n) - A070939(n).

A359676 Least positive integer whose weakly increasing prime indices have zero-based weighted sum n (A359674).

Original entry on oeis.org

1, 4, 6, 8, 14, 12, 16, 20, 30, 24, 32, 36, 40, 52, 48, 56, 100, 72, 80, 92, 96, 104, 112, 124, 136, 148, 176, 152, 214, 172, 184, 188, 262, 212, 272, 236, 248, 244, 304, 268, 346, 284, 328, 292, 386, 316, 398, 332, 376, 356, 458, 388, 478, 404, 472, 412, 526
Offset: 1

Views

Author

Gus Wiseman, Jan 14 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.
The zero-based weighted sum of a sequence (y_1,...,y_k) is Sum_{i=1..k} (i-1)*y_i.

Examples

			The terms together with their prime indices begin:
    1: {}
    4: {1,1}
    6: {1,2}
    8: {1,1,1}
   14: {1,4}
   12: {1,1,2}
   16: {1,1,1,1}
   20: {1,1,3}
   30: {1,2,3}
   24: {1,1,1,2}
   32: {1,1,1,1,1}
   36: {1,1,2,2}
   40: {1,1,1,3}
   52: {1,1,6}
   48: {1,1,1,1,2}
		

Crossrefs

First position of n in A359674, reverse A359677.
The sorted version is A359675, reverse A359680.
The reverse one-based version is A359679, sorted A359754.
The reverse version is A359681.
The one-based version is A359682, sorted A359755.
The version for standard compositions is A359756, one-based A089633.
A053632 counts compositions by zero-based weighted sum.
A112798 lists prime indices, length A001222, sum A056239.
A124757 gives zero-based weighted sum of standard compositions, rev A231204.
A304818 gives weighted sums of prime indices, reverse A318283.
A320387 counts multisets by weighted sum, zero-based A359678.
A358136 lists partial sums of prime indices, ranked by A358137, rev A359361.

Programs

  • Mathematica
    nn=20;
    primeMS[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];
    wts[y_]:=Sum[(i-1)*y[[i]],{i,Length[y]}];
    seq=Table[wts[primeMS[n]],{n,1,Prime[nn]^2}];
    Table[Position[seq,k][[1,1]],{k,0,nn}]

A359682 Least positive integer whose weakly increasing prime indices have weighted sum (A304818) equal to n.

Original entry on oeis.org

1, 2, 3, 4, 7, 6, 8, 10, 15, 12, 16, 18, 20, 26, 24, 28, 50, 36, 40, 46, 48, 52, 56, 62, 68, 74, 88, 76, 107, 86, 92, 94, 131, 106, 136, 118, 124, 122, 152, 134, 173, 142, 164, 146, 193, 158, 199, 166, 188, 178, 229, 194, 239, 202, 236, 206, 263, 214, 271, 218
Offset: 0

Views

Author

Gus Wiseman, Jan 15 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.
The weighted sum of a sequence (y_1,...,y_k) is Sum_{i=1..k} i*y_i.

Examples

			The 5 numbers with weighted sum of prime indices 12, together with their prime indices:
  20: {1,1,3}
  27: {2,2,2}
  33: {2,5}
  37: {12}
  49: {4,4}
Hence a(12) = 20.
		

Crossrefs

The version for standard compositions is A089633, zero-based A359756.
First position of n in A304818, reverse A318283.
The greatest instead of least is A359497, reverse A359683.
The sorted zero-based version is A359675, reverse A359680.
The zero-based version is A359676, reverse A359681.
The reverse version is A359679.
The sorted version is A359755, reverse A359754.
A112798 lists prime indices, length A001222, sum A056239.
A320387 counts multisets by weighted sum, zero-based A359678.
A358136 lists partial sums of prime indices, ranked by A358137, rev A359361.

Programs

  • Mathematica
    nn=20;
    primeMS[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];
    ots[y_]:=Sum[i*y[[i]],{i,Length[y]}];
    seq=Table[ots[primeMS[n]],{n,1,Prime[nn]^2}];
    Table[Position[seq,k][[1,1]],{k,0,nn}]

A359679 Least number with weighted sum of reversed (weakly decreasing) prime indices (A318283) equal to n.

Original entry on oeis.org

1, 2, 3, 4, 6, 10, 8, 12, 19, 18, 16, 24, 27, 36, 43, 32, 48, 59, 61, 67, 71, 64, 79, 83, 89, 97, 101, 103, 107, 109, 113, 127, 131, 137, 139, 149, 151, 157, 163, 167, 173, 179, 181, 191, 193, 197, 199, 211, 223, 227, 229, 233, 239, 241, 251, 257, 263, 269
Offset: 0

Views

Author

Gus Wiseman, Jan 14 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.
The weighted sum of a sequence (y_1,...,y_k) is Sum_{i=1..k} i*y_i.

Examples

			12 has reversed prime indices (2,1,1), with weighted sum 7, and no number < 12 has the same weighted sum of reversed prime indices, so a(7) = 12.
		

Crossrefs

The version for standard compositions is A089633, zero-based A359756.
First position of n in A318283, unreversed A304818.
The unreversed zero-based version is A359676.
The sorted zero-based version is A359680, unreversed A359675.
The zero-based version is A359681.
The unreversed version is A359682.
The greatest instead of least is A359683, unreversed A359497.
The sorted version is A359754, unreversed A359755.
A112798 lists prime indices, length A001222, sum A056239.
A320387 counts multisets by weighted sum, zero-based A359678.
A358136 lists partial sums of prime indices, ranked by A358137, rev A359361.

Programs

  • Mathematica
    nn=20;
    primeMS[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];
    ots[y_]:=Sum[i*y[[i]],{i,Length[y]}];
    seq=Table[ots[Reverse[primeMS[n]]],{n,1,Prime[nn]^2}];
    Table[Position[seq,k][[1,1]],{k,0,nn}]

A359675 Positions of first appearances in the sequence of zero-based weighted sums of prime indices (A359674).

Original entry on oeis.org

1, 4, 6, 8, 12, 14, 16, 20, 24, 30, 32, 36, 40, 48, 52, 56, 72, 80, 92, 96, 100, 104, 112, 124, 136, 148, 152, 172, 176, 184, 188, 212, 214, 236, 244, 248, 262, 268, 272, 284, 292, 304, 316, 328, 332, 346, 356, 376, 386, 388, 398, 404, 412, 428, 436, 452, 458
Offset: 1

Views

Author

Gus Wiseman, Jan 13 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.
The zero-based weighted sum of a sequence (y_1,...,y_k) is Sum_{i=1..k} (i-1)*y_i.

Examples

			The terms together with their prime indices begin:
   1: {}
   4: {1,1}
   6: {1,2}
   8: {1,1,1}
  12: {1,1,2}
  14: {1,4}
  16: {1,1,1,1}
  20: {1,1,3}
  24: {1,1,1,2}
  30: {1,2,3}
  32: {1,1,1,1,1}
  36: {1,1,2,2}
  40: {1,1,1,3}
  48: {1,1,1,1,2}
		

Crossrefs

Positions of first appearances in A359674.
The unsorted version A359676.
The reverse version is A359680, unsorted A359681.
The reverse one-based version is A359754, unsorted A359679.
The one-based version is A359755, unsorted A359682.
The version for standard compositions is A359756, one-based A089633.
A053632 counts compositions by zero-based weighted sum.
A112798 lists prime indices, length A001222, sum A056239.
A124757 gives zero-based weighted sum of standard compositions, rev A231204.
A304818 gives weighted sum of prime indices, reverse A318283.
A320387 counts multisets by weighted sum, zero-based A359678.
A358136 lists partial sums of prime indices, ranked by A358137, rev A359361.

Programs

  • Mathematica
    nn=100;
    primeMS[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];
    wts[y_]:=Sum[(i-1)*y[[i]],{i,Length[y]}];
    seq=Table[wts[primeMS[n]],{n,1,nn}];
    Select[Range[nn],FreeQ[seq[[Range[#-1]]],seq[[#]]]&]

A359680 Positions of first appearances in the sequence of zero-based weighted sums of reversed prime indices (A359677).

Original entry on oeis.org

1, 4, 8, 9, 16, 18, 32, 36, 50, 54, 64, 72, 81, 100, 108, 128, 144, 216, 243, 256, 288, 300, 400, 432, 486, 512, 576, 600, 648, 729, 800, 864, 1024, 1152, 1296, 1350, 1728, 1944, 2048, 2187, 2304, 2400, 2916, 3375, 3456, 3600, 4096, 4374, 4608, 4800, 5184
Offset: 1

Views

Author

Gus Wiseman, Jan 15 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.
The zero-based weighted sum of a sequence (y_1,...,y_k) is Sum_{i=1..k} (i-1)*y_i.

Examples

			The terms together with their prime indices begin:
     1: {}
     4: {1,1}
     8: {1,1,1}
     9: {2,2}
    16: {1,1,1,1}
    18: {1,2,2}
    32: {1,1,1,1,1}
    36: {1,1,2,2}
    50: {1,3,3}
    54: {1,2,2,2}
    64: {1,1,1,1,1,1}
    72: {1,1,1,2,2}
    81: {2,2,2,2}
   100: {1,1,3,3}
   108: {1,1,2,2,2}
   128: {1,1,1,1,1,1,1}
		

Crossrefs

The unreversed version is A359675, unsorted A359676.
Positions of first appearances in A359677, unreversed A359674.
This is the sorted version of A359681.
The one-based version is A359754, unsorted A359679.
The unreversed one-based version is A359755, unsorted A359682.
The version for standard compositions is A359756, one-based A089633.
A053632 counts compositions by zero-based weighted sum.
A112798 lists prime indices, length A001222, sum A056239, reverse A296150.
A124757 gives zero-based weighted sums of standard compositions, rev A231204.
A304818 gives weighted sum of prime indices, reverse A318283.
A320387 counts multisets by weighted sum, zero-based A359678.
A358136 lists partial sums of prime indices, ranked by A358137, rev A359361.

Programs

  • Mathematica
    nn=1000;
    primeMS[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];
    wts[y_]:=Sum[(i-1)*y[[i]],{i,Length[y]}];
    seq=Table[wts[Reverse[primeMS[n]]],{n,1,nn}];
    Select[Range[nn],FreeQ[seq[[Range[#-1]]],seq[[#]]]&]
Showing 1-7 of 7 results.