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

A374248 Sum of prime indices of n (with multiplicity) minus the greatest possible sum of run-compression of a permutation of the prime indices of n.

Original entry on oeis.org

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

Views

Author

Gus Wiseman, Jul 10 2024

Keywords

Comments

We define the run-compression of a sequence to be the anti-run obtained by reducing each run of repeated parts to a single part. Alternatively, run-compression removes all parts equal to the part immediately to their left. For example, (1,1,2,2,1) has run-compression (1,2,1).
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 96 are {1,1,1,1,1,2}, with sum 7, and we have permutations such as (1,1,1,1,2,1), with run-compression (1,2,1), with sum 4, so a(96) = 7 - 4 = 3.
		

Crossrefs

Positions of zeros are A335433 (separable).
Positions of positive terms are A335448 (inseparable).
This is an opposite version of A373956, for prime factors A374250.
For prime factors instead of indices we have A374255.
A001221 counts distinct prime factors, A001222 with multiplicity.
A003242 counts run-compressed compositions, i.e., anti-runs.
A007947 (squarefree kernel) represents run-compression of multisets.
A008480 counts permutations of prime factors.
A027746 lists prime factors, row-sums A001414.
A027748 is run-compression of prime factors, row-sums A008472.
A056239 adds up prime indices, row-sums of A112798.
A116861 counts partitions by sum of run-compression.
A304038 is run-compression of prime indices, row-sums A066328.
A373949 counts compositions by sum of run-compression, opposite A373951.
A373957 gives greatest number of runs in a permutation of prime factors.
A374251 run-compresses standard compositions, sum A373953, rank A373948.
A374252 counts permutations of prime factors by number of runs.

Programs

  • Mathematica
    prix[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];
    Table[Total[prix[n]]-Max@@(Total[First/@Split[#]]&/@Permutations[prix[n]]),{n,100}]

Formula

a(n) = A056239(n) - A373956(n).

A381076 Sorted positions of first appearances in A066503 (n minus squarefree kernel of n).

Original entry on oeis.org

1, 4, 8, 16, 18, 20, 24, 25, 27, 32, 44, 48, 50, 52, 54, 64, 68, 72, 75, 76, 80, 81, 92, 96, 98, 108, 112, 116, 121, 125, 128, 144, 148, 152, 160, 162, 164, 172, 175, 176, 188, 189, 192, 196, 198, 200, 212, 216, 232, 236, 242, 243, 244, 256, 260, 264, 268, 272
Offset: 1

Views

Author

Gus Wiseman, Feb 18 2025

Keywords

Comments

In A066503, each value appears for the first time at one of these positions.

Crossrefs

For quotient instead of difference we have A001694, sorted firsts of A003557.
Sorted positions of first appearances in A066503.
For indices and sum we have A380957 (unsorted A380956), firsts of A380955.
For indices and quotient we have A380988 (unsorted A380987), firsts of A290106.
For sum instead of product we have A381075, sorted firsts of A280292, see A280286.
For indices instead of factors we have A381077, sorted firsts of A380986.
A000040 lists the primes, differences A001223.
A001414 adds up prime factors (indices A056239), row sums of A027746 (indices A112798).
A003963 gives product of prime indices, distinct A156061.
A005117 lists squarefree numbers, complement A013929.
A007947 gives squarefree kernel.
A020639 gives least prime factor (index A055396), greatest A061395 (index A006530).

Programs

  • Mathematica
    prifacs[n_]:=If[n==1,{},Flatten[Apply[ConstantArray,FactorInteger[n],{1}]]];
    q=Table[Times@@prifacs[n]-Times@@Union[prifacs[n]],{n,1000}];
    Select[Range[Length[q]],FreeQ[Take[q,#-1],q[[#]]]&]

A381077 Sorted positions of first appearances in A380986 (product of prime indices minus product of distinct prime indices).

Original entry on oeis.org

1, 9, 25, 49, 63, 81, 99, 121, 125, 135, 169, 171, 245, 279, 289, 343, 361, 363, 369, 375, 387, 477, 529, 531, 575, 603, 625, 675, 711, 729, 747, 833, 841, 847, 873, 875, 891, 909, 961, 981, 1029, 1083, 1125, 1127, 1179, 1225, 1251, 1377, 1413, 1445, 1467
Offset: 1

Views

Author

Gus Wiseman, Feb 20 2025

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. A position of first appearance in a sequence q is an index k such that q(k) is different from q(j) for all j < k.
All terms are odd.

Examples

			The terms together with their prime indices begin:
     1: {}
     9: {2,2}
    25: {3,3}
    49: {4,4}
    63: {2,2,4}
    81: {2,2,2,2}
    99: {2,2,5}
   121: {5,5}
   125: {3,3,3}
   135: {2,2,2,3}
   169: {6,6}
   171: {2,2,8}
   245: {3,4,4}
   279: {2,2,11}
		

Crossrefs

For length instead of product we have A151821, firsts of A046660.
For factors instead of indices we have A381076, sorted firsts of A066503.
For sum of factors instead of product of indices we have A381075 (unsorted A280286), A280292.
For quotient instead of difference we have A380988 (unsorted A380987), firsts of A290106.
For quotient and factors we have A001694 (unsorted A064549), firsts of A003557.
For sum instead of product we have A380957 (unsorted A380956), firsts of A380955.
Sorted firsts of A380986, which has nonzero terms at positions A038838.
A000040 lists the primes, differences A001223.
A003963 gives product of prime indices, distinct A156061.
A005117 lists the squarefree numbers, complement A013929.
A007947 gives squarefree kernel.
A055396 gives least prime index, greatest A061395.
A056239 adds up prime indices, row sums of A112798, length A001222.
A304038 lists distinct prime indices, sum A066328, length A001221.

Programs

  • Mathematica
    prix[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];
    q=Table[Times@@prix[n]-Times@@Union[prix[n]],{n,10000}];
    Select[Range[Length[q]],FreeQ[Take[q,#-1],q[[#]]]&]

A374255 Sum of prime factors of n (with multiplicity) minus the greatest possible sum of run-compression of a permutation of the prime factors of n.

Original entry on oeis.org

0, 0, 0, 2, 0, 0, 0, 4, 3, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 2, 5, 0, 6, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 4, 7, 0, 0, 0, 0, 3, 0, 2, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 9, 0, 0, 0, 0, 0, 0
Offset: 1

Views

Author

Gus Wiseman, Jul 10 2024

Keywords

Comments

Contains no ones.
We define the run-compression of a sequence to be the anti-run obtained by reducing each run of repeated parts to a single part. Alternatively, run-compression removes all parts equal to the part immediately to their left. For example, (1,1,2,2,1) has run-compression (1,2,1).

Examples

			The prime factors of 96 are {2,2,2,2,2,3}, with sum 13, and we have permutations such as (2,2,2,2,3,2), with run-compression (2,3,2), with sum 7, so a(96) = 13 - 7 = 6.
		

Crossrefs

Positions of first appearances are A280286.
For least instead of greatest sum of run-compression we have A280292.
Positions of zeros are A335433 (separable).
Positions of positive terms are A335448 (inseparable).
For prime indices instead of factors we have A374248.
This is an opposite version of A374250, for prime indices A373956.
A001221 counts distinct prime factors, A001222 with multiplicity.
A003242 counts run-compressed compositions, i.e., anti-runs.
A007947 (squarefree kernel) represents run-compression of multisets.
A008480 counts permutations of prime factors.
A027746 lists prime factors, row-sums A001414.
A027748 is run-compression of prime factors, row-sums A008472.
A056239 adds up prime indices, row sums of A112798.
A116861 counts partitions by sum of run-compression.
A304038 is run-compression of prime indices, row-sums A066328.
A373949 counts compositions by sum of run-compression, opposite A373951.
A373957 gives greatest number of runs in a permutation of prime factors.
A374251 run-compresses standard compositions, sum A373953, rank A373948.
A374252 counts permutations of prime factors by number of runs.

Programs

  • Mathematica
    prifacs[n_]:=If[n==1,{},Flatten[ConstantArray@@@FactorInteger[n]]];
    Table[Total[prifacs[n]]-Max@@(Total[First/@Split[#]]& /@ Permutations[prifacs[n]]),{n,100}]

Formula

a(n) = A001414(n) - A374250(n).
Previous Showing 11-14 of 14 results.