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 11-20 of 26 results. Next

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[[#]]]&]

A359683 Greatest positive integer whose reversed (weakly decreasing) prime indices have weighted sum (A318283) equal to n.

Original entry on oeis.org

1, 2, 3, 5, 7, 11, 14, 22, 26, 34, 44, 55, 68, 85, 110, 130, 170, 190, 242, 290, 374, 418, 506, 638, 748, 836, 1012, 1276, 1364, 1628, 1914, 2090, 2552, 3190, 3410, 4070, 4510, 5060, 6380, 7018, 8140, 9020, 9922, 11396, 14036, 15004, 17908, 19844, 21692, 23452
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 terms together with their prime indices begin:
      1: {}
      2: {1}
      3: {2}
      5: {3}
      7: {4}
     11: {5}
     14: {1,4}
     22: {1,5}
     26: {1,6}
     34: {1,7}
     44: {1,1,5}
     55: {3,5}
     68: {1,1,7}
     85: {3,7}
    110: {1,3,5}
    130: {1,3,6}
    170: {1,3,7}
    190: {1,3,8}
    242: {1,5,5}
    290: {1,3,10}
The 6 numbers with weighted sum of reversed prime indices 9, together with their prime indices:
  18: {1,2,2}
  23: {9}
  25: {3,3}
  28: {1,1,4}
  33: {2,5}
  34: {1,7}
Hence a(9) = 34.
		

Crossrefs

First position of n in A318283, unreversed A304818.
The unreversed version is A359497.
The least instead of greatest is A359679, unreversed A359682.
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=10;
    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,2^nn}];
    Table[Position[seq,k][[-1,1]],{k,0,nn}]

Extensions

More terms from Jinyuan Wang, Jan 26 2023

A359754 Positions of first appearances in the sequence of weighted sums of reversed prime indices (A318283).

Original entry on oeis.org

1, 2, 3, 4, 6, 8, 10, 12, 16, 18, 19, 24, 27, 32, 36, 43, 48, 59, 61, 64, 67, 71, 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: 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}
    8: {1,1,1}
   10: {1,3}
   12: {1,1,2}
   16: {1,1,1,1}
   18: {1,2,2}
   19: {8}
   24: {1,1,1,2}
   27: {2,2,2}
   32: {1,1,1,1,1}
   36: {1,1,2,2}
   43: {14}
   48: {1,1,1,1,2}
		

Crossrefs

Positions of first appearances in A318283, unreversed A304818.
This is the sorted version of A359679.
The zero-based version is A359680, unreversed A359675.
The unreversed version is A359755, unsorted A359682.
A053632 counts compositions by weighted sum.
A112798 lists prime indices, length A001222, sum A056239, reverse A296150.
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}]]]];
    ots[y_]:=Sum[i*y[[i]],{i,Length[y]}];
    seq=Table[ots[Reverse[primeMS[n]]],{n,1,nn}];
    Select[Range[nn],FreeQ[seq[[Range[#-1]]],seq[[#]]]&]

A231429 Number of partitions of 2n into distinct parts < n.

Original entry on oeis.org

1, 0, 0, 0, 0, 1, 2, 4, 8, 14, 22, 35, 53, 78, 113, 160, 222, 306, 416, 558, 743, 980, 1281, 1665, 2149, 2755, 3514, 4458, 5626, 7070, 8846, 11020, 13680, 16920, 20852, 25618, 31375, 38309, 46649, 56651, 68616, 82908, 99940, 120192, 144238, 172730, 206425
Offset: 0

Views

Author

Reinhard Zumkeller, Nov 14 2013

Keywords

Comments

From Gus Wiseman, Jun 17 2023: (Start)
Also the number of integer compositions of n with weighted sum 3*n, where the weighted sum of a sequence (y_1,...,y_k) is Sum_{i=1..k} i * y_i. The a(0) = 1 through a(9) = 14 compositions are:
() . . . . (11111) (3111) (3211) (3311) (3411)
(11211) (11311) (4121) (4221)
(12121) (11411) (5112)
(21112) (12221) (11511)
(13112) (12321)
(21131) (13131)
(21212) (13212)
(111122) (21231)
(21312)
(22122)
(31113)
(111141)
(111222)
(112113)
For partitions we have A363527, ranks A363531. For reversed partitions we have A363526, ranks A363530.
(End)

Examples

			a(5) = #{4+3+2+1} = 1;
a(6) = #{5+4+3, 5+4+2+1} = 2;
a(7) = #{6+5+3, 6+5+2+1, 6+4+3+1, 5+4+3+2} = 4;
a(8) = #{7+6+3, 7+6+2+1, 7+6+3, 7+5+3+1, 7+4+3+2, 6+5+4+1, 6+5+3+2, 6+4+3+2+1} = 8;
a(9) = #{8+7+3, 8+7+2+1, 8+6+4, 8+6+3+1, 8+5+4+1, 8+5+3+2, 8+4+3+2+1, 7+6+5, 7+6+4+1, 7+6+3+2, 7+5+4+2, 7+5+3+2+1, 6+5+4+3, 6+5+4+2+1} = 14.
		

Crossrefs

A000041 counts integer partitions, strict A000009.
A053632 counts compositions by weighted sum.
A264034 counts partitions by weighted sum, reverse A358194.
A304818 gives weighted sum of prime indices, reverse A318283.
A320387 counts multisets by weighted sum, zero-based A359678.

Programs

  • Haskell
    a231429 n = p [1..n-1] (2*n) where
       p _  0 = 1
       p [] _ = 0
       p (k:ks) m = if m < k then 0 else p ks (m - k) + p ks m
  • Mathematica
    Table[Length[Select[Join@@Permutations/@IntegerPartitions[n], Total[Accumulate[#]]==3n&]],{n,0,15}] (* Gus Wiseman, Jun 17 2023 *)

A363619 Weighted alternating sum of the multiset of prime indices of n.

Original entry on oeis.org

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

Views

Author

Gus Wiseman, Jun 12 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.
We define the weighted alternating sum of a sequence (y_1,...,y_k) to be Sum_{i=1..k} (-1)^(i-1) i * y_i.

Examples

			The prime indices of 300 are {1,1,2,3,3}, with weighted alternating sum 1*1 - 2*1 + 3*2 - 4*3 + 5*3 = 8, so a(300) = 8.
		

Crossrefs

The non-alternating version is A304818, reverse A318283.
The unweighted version is A316524, reverse A344616.
The reverse version is A363620.
The triangle for this rank statistic is A363622, reverse A363623.
For partitions instead of multisets we have A363624, reverse A363625.
A055396 gives minimum prime index, maximum A061395.
A112798 lists prime indices, length A001222, sum A056239.
A264034 counts partitions by weighted sum, reverse A358194.
A320387 counts multisets by weighted sum, zero-based A359678.
A359677 gives zero-based weighted sum of prime indices, reverse A359674.

Programs

  • Mathematica
    prix[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];
    altwtsum[y_]:=Sum[(-1)^(k-1)*k*y[[k]],{k,1,Length[y]}];
    Table[altwtsum[prix[n]],{n,100}]

A363620 Reverse-weighted alternating sum of the multiset of prime indices of n.

Original entry on oeis.org

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

Views

Author

Gus Wiseman, Jun 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.
We define the reverse-weighted alternating sum of a sequence (y_1,...,y_k) to be Sum_{i=1..k} (-1)^(k-i) i * y_{k-i+1}.

Examples

			The prime indices of 300 are {1,1,2,3,3}, with reverse-weighted alternating sum 1*3 - 2*3 + 3*2 - 4*1 + 5*1 = 4, so a(300) = 4.
		

Crossrefs

The reverse non-alternating version is A304818, row-sums of A359361.
The non-alternating version is A318283, row-sums of A358136.
The unweighted version is A344616, reverse A316524.
The reverse version is A363619.
Positions of zeros are A363621.
The triangle for this rank statistic is A363623, reverse A363622.
For partitions instead of multisets we have A363625, reverse A363624.
A055396 gives minimum prime index, maximum A061395.
A112798 lists prime indices, length A001222, sum A056239.
A264034 counts partitions by weighted sum, reverse A358194.
A320387 counts multisets by weighted sum, zero-based A359678.

Programs

  • Mathematica
    prix[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];
    revaltwtsum[y_]:=Sum[(-1)^(Length[y]-k)*k*y[[-k]],{k,1,Length[y]}];
    Table[revaltwtsum[prix[n]],{n,100}]

A359756 First position of n in the sequence of zero-based weighted sums of standard compositions (A124757), if we start with position 0.

Original entry on oeis.org

0, 3, 6, 7, 13, 14, 15, 27, 29, 30, 31, 55, 59, 61, 62, 63, 111, 119, 123, 125, 126
Offset: 0

Views

Author

Gus Wiseman, Jan 17 2023

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 zero-based weighted sum of a sequence (y_1,...,y_k) is Sum_{i=1..k} (i-1)*y_i.
Is this sequence strictly increasing?

Examples

			The terms together with their standard compositions begin:
    0: ()
    3: (1,1)
    6: (1,2)
    7: (1,1,1)
   13: (1,2,1)
   14: (1,1,2)
   15: (1,1,1,1)
   27: (1,2,1,1)
   29: (1,1,2,1)
   30: (1,1,1,2)
   31: (1,1,1,1,1)
		

Crossrefs

The one-based version is A089633, for prime indices A359682.
First index of n in A124757, reverse A231204.
The version for prime indices is A359676, reverse A359681.
A053632 counts compositions by zero-based weighted sum.
A066099 lists standard compositions.
A304818 gives weighted sums of prime indices, reverse A318283.
A320387 counts multisets by weighted sum, zero-based A359678.

Programs

  • Mathematica
    nn=10;
    stc[n_]:=Differences[Prepend[Join@@Position[Reverse[IntegerDigits[n,2]],1],0]]//Reverse;
    wts[y_]:=Sum[(i-1)*y[[i]],{i,Length[y]}];
    seq=Table[wts[stc[n]],{n,0,2^(nn-1)}];
    Table[Position[seq,k][[1,1]]-1,{k,0,nn}]

Formula

Appears to be the complement of A083329 in A089633.

A363531 Heinz numbers of integer partitions such that 3*(sum) = (reverse-weighted sum).

Original entry on oeis.org

1, 32, 144, 216, 243, 672, 1008, 1350, 2176, 2250, 2520, 2673, 3125, 3969, 4160, 4200, 5940, 6240, 6615, 7344, 7424, 7744, 8262, 9261, 9800, 9900, 10400, 11616, 12250, 12312, 12375, 13104, 13720, 14720, 14742, 16767, 16807, 17150, 19360, 21840, 22080, 23100
Offset: 1

Views

Author

Gus Wiseman, Jun 12 2023

Keywords

Comments

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.
The (one-based) weighted sum of a sequence (y_1,...,y_k) is Sum_{i=1..k} i*y_i. The reverse-weighted sum is the weighted sum of the reverse, also the sum of partial sums. For example, the weighted sum of (4,2,2,1) is 1*4 + 2*2 + 3*2 + 4*1 = 18 and the reverse-weighted sum is 4*4 + 3*2 + 2*2 + 1*1 = 27.

Examples

			The terms together with their prime indices begin:
      1: {}
     32: {1,1,1,1,1}
    144: {1,1,1,1,2,2}
    216: {1,1,1,2,2,2}
    243: {2,2,2,2,2}
    672: {1,1,1,1,1,2,4}
   1008: {1,1,1,1,2,2,4}
   1350: {1,2,2,2,3,3}
   2176: {1,1,1,1,1,1,1,7}
   2250: {1,2,2,3,3,3}
   2520: {1,1,1,2,2,3,4}
   2673: {2,2,2,2,2,5}
   3125: {3,3,3,3,3}
   3969: {2,2,2,2,4,4}
   4160: {1,1,1,1,1,1,3,6}
		

Crossrefs

These partitions are counted by A363526.
The non-reverse version is A363530, counted by A363527.
A053632 counts compositions by weighted sum.
A055396 gives minimum prime index, maximum A061395.
A112798 lists prime indices, length A001222, sum A056239.
A264034 counts partitions by weighted sum, reverse A358194.
A304818 gives weighted sum of prime indices, row-sums of A359361.
A318283 gives weighted sum of reversed prime indices, row-sums of A358136.
A320387 counts multisets by weighted sum, zero-based A359678.

Programs

  • Mathematica
    prix[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];
    Select[Range[1000],3*Total[prix[#]]==Total[Accumulate[prix[#]]]&]

Formula

A056239(a(n)) = A318283(a(n))/3.
Previous Showing 11-20 of 26 results. Next