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.

A374252 Irregular triangle read by rows where T(n,k) is the number of permutations of the prime factors of n with k runs.

Original entry on oeis.org

1, 1, 1, 0, 1, 0, 2, 1, 1, 0, 0, 1, 0, 0, 2, 1, 0, 2, 1, 1, 0, 2, 0, 2, 1, 0, 0, 0, 1, 0, 2, 1, 1, 0, 2, 1, 0, 2, 0, 2, 1, 0, 2, 2, 0, 1, 0, 0, 2, 1, 0, 0, 0, 2, 1, 1, 0, 0, 6, 1, 1, 0, 0, 0, 0, 0, 2, 0, 2, 0, 2, 0, 2, 2, 2, 1, 0, 2, 0, 2, 0, 2, 2, 0, 1
Offset: 2

Views

Author

Gus Wiseman, Jul 07 2024

Keywords

Comments

An alternative form of this sequence (with the same data) has offset 1 and begins with an empty row.
Note that the prime factors of n are separable (A335433) iff the last term of row n is positive.

Examples

			The T(36,3) = 2 permutations are (2,3,3,2) and (3,2,2,3).
Row n = 72 counts the following permutations:
  .  (2,2,2,3,3)  (2,2,3,3,2)  (2,2,3,2,3)  (2,3,2,3,2)
     (3,3,2,2,2)  (2,3,3,2,2)  (2,3,2,2,3)
                  (3,2,2,2,3)  (3,2,2,3,2)
                               (3,2,3,2,2)
Triangle begins:
   1:
   2: 1
   3: 1
   4: 1  0
   5: 1
   6: 0  2
   7: 1
   8: 1  0  0
   9: 1  0
  10: 0  2
  11: 1
  12: 0  2  1
  13: 1
  14: 0  2
  15: 0  2
  16: 1  0  0  0
  17: 1
  18: 0  2  1
  19: 1
  20: 0  2  1
		

Crossrefs

Row-lengths are A001222.
Row-sums are A008480 (number of permutations of prime factors).
Column k = 1 is A069513.
For compositions instead of permutations of prime factors we have A238130.
Last column is A335452 (where k = A001222(n)), which counts separations.
Position of the last positive term in row n is A373957(n).
The number of zeros at the end of row n is A374246(n).
The number of nonzero terms in row n is A374247(n).
A001221 counts distinct prime factors.
A003242 counts run-compressed compositions, i.e., anti-runs.
A124767 counts runs in standard compositions, anti-runs A333381.
A333755 counts compositions by number of runs.
A335433 lists separable numbers, complement A335448.
A374250 maximizes sum of run-compression, for indices A373956.

Programs

  • Mathematica
    prifacs[n_]:=If[n==1,{},Flatten[ConstantArray@@@FactorInteger[n]]];
    Table[Length[Select[Permutations[prifacs[n]], Length[Split[#]]==k&]],{n,100},{k,PrimeOmega[n]}]