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-10 of 43 results. Next

A238352 Irregular triangle T(n,k) read by rows: T(n,k) is the number of partitions p(1), p(2), ..., p(m) of n (as weakly ascending list of parts) with k parts p at position p (fixed points), n>=0, 0<=k<= (column index of last nonzero term in row n).

Original entry on oeis.org

1, 0, 1, 1, 1, 1, 1, 1, 1, 4, 2, 3, 2, 3, 7, 0, 1, 3, 7, 5, 4, 14, 4, 5, 19, 3, 3, 8, 24, 9, 0, 1, 9, 32, 11, 4, 12, 46, 15, 4, 13, 60, 21, 7, 17, 85, 28, 1, 4, 22, 109, 28, 16, 0, 1, 28, 140, 51, 7, 5, 34, 179, 57, 26, 1, 42, 239, 74, 25, 5, 48, 300, 107, 24
Offset: 0

Views

Author

Joerg Arndt and Alois P. Heinz, Feb 26 2014

Keywords

Comments

Row sums are A000041.
Column k=0 is A238394, row sums over columns k>=1 give A238395.
T(A000217(k),k) = 1,
T(A000217(k),k-1) = 0 for k in {1, 3, 4, 5, ... },
T(A000217(k)-1,k-1) = k-1 for k>1.

Examples

			Triangle starts:
00:   1;
01:   0,   1;
02:   1,   1;
03:   1,   1,   1;
04:   1,   4;
05:   2,   3,   2;
06:   3,   7,   0,  1;
07:   3,   7,   5;
08:   4,  14,   4;
09:   5,  19,   3,  3;
10:   8,  24,   9,  0,  1;
11:   9,  32,  11,  4;
12:  12,  46,  15,  4;
13:  13,  60,  21,  7;
14:  17,  85,  28,  1,  4;
15:  22, 109,  28, 16,  0, 1;
16:  28, 140,  51,  7,  5;
17:  34, 179,  57, 26,  1;
18:  42, 239,  74, 25,  5;
19:  48, 300, 107, 24, 11;
20:  59, 397, 122, 43,  1, 5;
21:  71, 495, 167, 37, 21, 0, 1;
...
The 11 partitions of 6 together with their number of fixed points are:
01:  [ 1 1 1 1 1 1 ]   1
02:  [ 1 1 1 1 2 ]   1
03:  [ 1 1 1 3 ]   1
04:  [ 1 1 2 2 ]   1
05:  [ 1 1 4 ]   1
06:  [ 1 2 3 ]   3
07:  [ 1 5 ]   1
08:  [ 2 2 2 ]   1
09:  [ 2 4 ]   0
10:  [ 3 3 ]   0
11:  [ 6 ]   0
There are 3 partitions with no fixed points, 7 with one, none with 2, and one with 3, giving row 6.
		

Crossrefs

Cf. A238349 (and A238350) for the same statistics for compositions.

Programs

  • Maple
    b:= proc(n, i) option remember; `if`(n=0, 1, `if`(i<1, 0,
          expand(b(n, i-1) +`if`(i>n, 0, (p-> add((c->c*x^j*
          `if`(j=i, z, 1))(coeff(p, x, j)), j=0..degree(p,x)))
          (x*b(n-i, i))))))
        end:
    T:= n-> (p->seq((q->add(coeff(q, x, j), j=0..degree(q, x)))
        (coeff(p, z, i)), i=0..degree(p, z)))(b(n$2)):
    seq(T(n), n=0..25);
  • Mathematica
    b[n_, i_] := b[n, i] = If[n == 0, 1, If[i<1, 0, Expand[b[n, i-1] + If[i>n, 0, Function[{p}, Sum[Function[{c}, c*x^j* If[j == i, z, 1]][Coefficient[p, x, j]], {j, 0, Exponent[p, x]}]] [x*b[n-i, i]]]]]]; T[n_] := Function[{p}, Table[ Function[{q},  Sum[Coefficient[q, x, j], {j, 0, Exponent[q, x]}]][Coefficient[p, z, i]], {i, 0, Exponent[p, z]}]][b[n, n]]; Table[T[n], {n, 0, 25}] // Flatten (* Jean-François Alcover, Feb 11 2015, after Maple *)

A238351 Number of compositions p(1)+p(2)+...+p(k) = n such that for no part p(i) = i (compositions without fixed points).

Original entry on oeis.org

1, 0, 1, 2, 3, 6, 11, 22, 42, 82, 161, 316, 624, 1235, 2449, 4864, 9676, 19267, 38399, 76582, 152819, 305085, 609282, 1217140, 2431992, 4860306, 9714696, 19419870, 38824406, 77624110, 155208405, 310352615, 620601689, 1241036325, 2481803050, 4963170896
Offset: 0

Views

Author

Joerg Arndt and Alois P. Heinz, Feb 25 2014

Keywords

Comments

Column k=0 of A238349 and of A238350.

Examples

			The a(7) = 22 such compositions are:
01:  [ 2 1 1 1 1 1 ]
02:  [ 2 1 1 1 2 ]
03:  [ 2 1 1 2 1 ]
04:  [ 2 1 1 3 ]
05:  [ 2 1 2 1 1 ]
06:  [ 2 1 2 2 ]
07:  [ 2 1 4 ]
08:  [ 2 3 1 1 ]
09:  [ 2 3 2 ]
10:  [ 2 4 1 ]
11:  [ 2 5 ]
12:  [ 3 1 1 1 1 ]
13:  [ 3 1 1 2 ]
14:  [ 3 1 2 1 ]
15:  [ 3 3 1 ]
16:  [ 3 4 ]
17:  [ 4 1 1 1 ]
18:  [ 4 1 2 ]
19:  [ 4 3 ]
20:  [ 5 1 1 ]
21:  [ 6 1 ]
22:  [ 7 ]
		

References

  • M. Archibald, A. Blecher and A. Knopfmacher, Fixed points in compositions and words, accepted by the Journal of Integer Sequences

Programs

  • Maple
    b:= proc(n, i) option remember; `if`(n=0, 1,
           add(`if`(i=j, 0, b(n-j, i+1)), j=1..n))
        end:
    a:= n-> b(n, 1):
    seq(a(n), n=0..50);
  • Mathematica
    b[n_, i_] := b[n, i] = If[n == 0, 1, Sum[If[i == j, 0, b[n-j, i+1]], {j, 1, n}]]; a[n_] := b[n, 1]; Table[a[n], {n, 0, 50}] (* Jean-François Alcover, Nov 06 2014, after Maple *)

Formula

a(n) ~ c * 2^n, where c = A048651/2 = 0.14439404754330121... - Vaclav Kotesovec, May 01 2014

A352822 Number of fixed points y(i) = i, where y is the weakly increasing sequence of prime indices of n.

Original entry on oeis.org

0, 1, 0, 1, 0, 2, 0, 1, 1, 1, 0, 1, 0, 1, 0, 1, 0, 2, 0, 2, 0, 1, 0, 1, 0, 1, 1, 1, 0, 3, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 2, 0, 1, 2, 1, 0, 1, 0, 2, 0, 1, 0, 2, 0, 2, 0, 1, 0, 1, 0, 1, 1, 1, 0, 2, 0, 1, 0, 1, 0, 1, 0, 1, 1, 1, 0, 2, 0, 1, 1, 1, 0, 2, 0, 1, 0, 1, 0, 2, 0, 1, 0, 1, 0, 1, 0, 1, 1, 2, 0, 2, 0, 1, 0
Offset: 1

Views

Author

Gus Wiseman, Apr 05 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

			The prime indices of 6500 are {1,1,3,3,3,6} with fixed points at positions {1,3,6}, so a(6500) = 3.
		

Crossrefs

* = unproved
Positions of first appearances are A002110.
The triangle version is A238352.
Positions of 0's are A352830, counted by A238394.
Positions of 1's are A352831, counted by A352832.
A version for compositions is A352512, complement A352513, triangle A238349.
The complement is A352823.
The reverse version is A352824, complement A352825.
A000700 counts self-conjugate partitions, ranked by A088902.
A001222 counts prime indices, distinct A001221.
*A001522 counts partitions with a fixed point, ranked by A352827.
A056239 adds up prime indices, row sums of A112798 and A296150.
*A064428 counts partitions without a fixed point, ranked by A352826.
A122111 represents partition conjugation using Heinz numbers.
A124010 gives prime signature, sorted A118914, conjugate rank A238745.
A115720 and A115994 count partitions by their Durfee square.
A238395 counts reversed partitions with a fixed point, ranked by A352872.

Programs

  • Maple
    f:= proc(n) local F,J,t;
      F:= sort(ifactors(n)[2],(s,t) -> s[1] numtheory:-pi(t[1])$t[2], F);
      nops(select(t -> J[t]=t, [$1..nops(J)]));
    end proc:
    map(f, [$1..200]); # Robert Israel, Apr 11 2023
  • Mathematica
    pq[y_]:=Length[Select[Range[Length[y]],#==y[[#]]&]];
    Table[pq[Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]],{n,100}]
  • PARI
    A352822(n) = { my(f=factor(n),i=0,c=0); for(k=1,#f~,while(f[k,2], f[k,2]--; i++; c += (i==primepi(f[k,1])))); (c); }; \\ Antti Karttunen, Apr 11 2022

Formula

a(n) = A001222(n) - A352823(n). - Antti Karttunen, Apr 11 2022

Extensions

Data section extended up to 105 terms by Antti Karttunen, Apr 11 2022

A352827 Heinz numbers of integer partitions y with a fixed point y(i) = i. Such a fixed point is unique if it exists.

Original entry on oeis.org

2, 4, 8, 9, 15, 16, 18, 21, 27, 30, 32, 33, 36, 39, 42, 45, 51, 54, 57, 60, 63, 64, 66, 69, 72, 78, 81, 84, 87, 90, 93, 99, 102, 108, 111, 114, 117, 120, 123, 125, 126, 128, 129, 132, 135, 138, 141, 144, 153, 156, 159, 162, 168, 171, 174, 175, 177, 180, 183
Offset: 1

Views

Author

Gus Wiseman, Apr 06 2022

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.

Examples

			The terms together with their prime indices begin:
    2: (1)
    4: (1,1)
    8: (1,1,1)
    9: (2,2)
   15: (3,2)
   16: (1,1,1,1)
   18: (2,2,1)
   21: (4,2)
   27: (2,2,2)
   30: (3,2,1)
   32: (1,1,1,1,1)
   33: (5,2)
   36: (2,2,1,1)
   39: (6,2)
   42: (4,2,1)
   45: (3,2,2)
   51: (7,2)
   54: (2,2,2,1)
For example, the partition (3,2,2) with Heinz number 45 has a fixed point at position 2, so 45 is in the sequence.
		

Crossrefs

* = unproved
*These partitions are counted by A001522, strict A352829.
*The complement is A352826, counted by A064428.
The complement reverse version is A352830, counted by A238394.
The reverse version is A352872, counted by A238395
A000700 counts self-conjugate partitions, ranked by A088902.
A001222 counts prime indices, distinct A001221.
A008290 counts permutations by fixed points, unfixed A098825.
A056239 adds up prime indices, row sums of A112798 and A296150.
A115720 and A115994 count partitions by their Durfee square.
A122111 represents partition conjugation using Heinz numbers.
A124010 gives prime signature, sorted A118914, conjugate rank A238745.
A238349 counts compositions by fixed points, complement A352523.
A238352 counts reversed partitions by fixed points, rank statistic A352822.
A352828 counts strict partitions without a fixed point.
A352833 counts partitions by fixed points.

Programs

  • Mathematica
    pq[y_]:=Length[Select[Range[Length[y]],#==y[[#]]&]];
    Select[Range[100],pq[Reverse[Flatten[Cases[FactorInteger[#],{p_,k_}:>Table[PrimePi[p],{k}]]]]]==1&]

A352523 Number of integer compositions of n with exactly k nonfixed points (parts not on the diagonal).

Original entry on oeis.org

1, 1, 0, 0, 2, 0, 1, 1, 2, 0, 0, 4, 2, 2, 0, 0, 5, 5, 4, 2, 0, 1, 3, 12, 8, 6, 2, 0, 0, 7, 14, 19, 14, 8, 2, 0, 0, 8, 21, 33, 32, 22, 10, 2, 0, 0, 9, 30, 54, 63, 54, 32, 12, 2, 0, 1, 6, 47, 80, 116, 116, 86, 44, 14, 2, 0, 0, 11, 53, 129, 194, 229, 202, 130, 58, 16, 2, 0
Offset: 0

Views

Author

Gus Wiseman, Mar 26 2022

Keywords

Comments

A nonfixed point in a composition c is an index i such that c_i != i.

Examples

			Triangle begins:
   1
   1   0
   0   2   0
   1   1   2   0
   0   4   2   2   0
   0   5   5   4   2   0
   1   3  12   8   6   2   0
   0   7  14  19  14   8   2   0
   0   8  21  33  32  22  10   2   0
   0   9  30  54  63  54  32  12   2   0
   1   6  47  80 116 116  86  44  14   2   0
   ...
For example, row n = 6 counts the following compositions (empty column indicated by dot):
  (123)  (6)   (24)    (231)    (2112)   (21111)    .
         (15)  (33)    (312)    (2121)   (111111)
         (42)  (51)    (411)    (3111)
               (114)   (1113)   (11112)
               (132)   (1122)   (11121)
               (141)   (1311)   (11211)
               (213)   (2211)
               (222)   (12111)
               (321)
               (1131)
               (1212)
               (1221)
		

Crossrefs

Column k = 0 is A010054.
Row sums are A011782.
The version for permutations is A098825.
The corresponding rank statistic is A352513.
Column k = 1 is A352520.
A238349 and A238350 count comps by fixed points, first col A238351, rank stat A352512.
A352486 gives the nonfixed points of A122111, counted by A330644.
A352521 counts comps by strong nonexcedances, first A219282, stat A352514.
A352522 counts comps by weak nonexcedances, first col A238874, stat A352515.
A352524 counts comps by strong excedances, first col A008930, stat A352516.
A352525 counts comps by weak excedances, first col A177510, stat A352517.

Programs

  • Maple
    b:= proc(n, i) option remember; expand(`if`(n=0, 1,
          add(`if`(i=j, 1, x)*b(n-j, i+1), j=1..n)))
        end:
    T:= n-> (p-> seq(coeff(p, x, i), i=0..n))(b(n, 1)):
    seq(T(n), n=0..12);  # Alois P. Heinz, Mar 19 2025
  • Mathematica
    pnq[y_]:=Length[Select[Range[Length[y]],#!=y[[#]]&]];
    Table[Length[Select[Join@@Permutations/@IntegerPartitions[n],pnq[#]==k&]],{n,0,9},{k,0,n}]
  • PARI
    T_xy(max_row) = {my(N=max_row+1, x='x+O('x^N), h= sum(i=0, N, prod(j=1, i, y*(x/(1-x)-x^j)+x^j))); vector(N, n, my(r=Vecrev(polcoeff(h, n-1))); if(n<2, r, concat(r,[0])))}
    T_xy(10) \\ John Tyler Rascoe, Mar 21 2025

Formula

G.f.: Sum_{i>=0} Product_{j=1..i} y*(x/(1-x) - x^j) + x^j. - John Tyler Rascoe, Mar 19 2025

A177510 Number of compositions (p0, p1, p2, ...) of n with pi - p0 <= i and pi >= p0.

Original entry on oeis.org

1, 1, 2, 3, 5, 8, 14, 25, 46, 87, 167, 324, 634, 1248, 2466, 4887, 9706, 19308, 38455, 76659, 152925, 305232, 609488, 1217429, 2432399, 4860881, 9715511, 19421029, 38826059, 77626471, 155211785, 310357462, 620608652, 1241046343, 2481817484, 4963191718, 9925669171, 19850186856, 39698516655, 79394037319
Offset: 0

Views

Author

Mats Granvik, Dec 11 2010

Keywords

Comments

a(0)=1, otherwise row sums of A179748.
For n>=1 cumulative sums of A008930.
a(n) is proportional to A048651*A000079. The error (a(n)-A048651*A000079) divided by sequence A186425 tends to the golden ratio A001622. This can be seen when using about 1000 decimals of the constant A048651 = 0.2887880950866024212... - [Mats Granvik, Jan 01 2015]
From Gus Wiseman, Mar 31 2022: (Start)
Also the number of integer compositions of n with exactly one part on or above the diagonal. For example, the a(1) = 1 through a(5) = 8 compositions are:
(1) (2) (3) (4) (5)
(11) (21) (31) (41)
(111) (112) (212)
(211) (311)
(1111) (1112)
(1121)
(2111)
(11111)
(End)

Examples

			From _Joerg Arndt_, Mar 24 2014: (Start)
The a(7) = 25 such compositions are:
01:  [ 1 1 1 1 1 1 1 ]
02:  [ 1 1 1 1 1 2 ]
03:  [ 1 1 1 1 2 1 ]
04:  [ 1 1 1 1 3 ]
05:  [ 1 1 1 2 1 1 ]
06:  [ 1 1 1 2 2 ]
07:  [ 1 1 1 3 1 ]
08:  [ 1 1 1 4 ]
09:  [ 1 1 2 1 1 1 ]
10:  [ 1 1 2 1 2 ]
11:  [ 1 1 2 2 1 ]
12:  [ 1 1 2 3 ]
13:  [ 1 1 3 1 1 ]
14:  [ 1 1 3 2 ]
15:  [ 1 2 1 1 1 1 ]
16:  [ 1 2 1 1 2 ]
17:  [ 1 2 1 2 1 ]
18:  [ 1 2 1 3 ]
19:  [ 1 2 2 1 1 ]
20:  [ 1 2 2 2 ]
21:  [ 1 2 3 1 ]
22:  [ 2 2 3 ]
23:  [ 2 3 2 ]
24:  [ 3 4 ]
25:  [ 7 ]
(End)
		

Crossrefs

Cf. A238859 (compositions with subdiagonal growth), A238876 (partitions with subdiagonal growth), A001227 (partitions into distinct parts with subdiagonal growth).
Cf. A238860 (partitions with superdiagonal growth), A238861 (compositions with superdiagonal growth), A000009 (partitions into distinct parts have superdiagonal growth by definition).
The version for partitions is A001477, strong A002620.
The version for permutations is A057427, strong A000295.
The opposite version is A238874, first column of A352522.
The version for fixed points is A240736, nonfixed A352520.
The strong version is A351983, column k=1 of A352524.
This is column k = 1 of A352525.
A238349 counts compositions by fixed points, first col A238351.
A352517 counts weak excedances of standard compositions.

Programs

  • Maple
    A179748 := proc(n,k) option remember; if k= 1 then 1; elif k> n then 0 ; else add( procname(n-i,k-1),i=1..k-1) ; end if; end proc:
    A177510 := proc(n) add(A179748(n,k),k=1..n) ;end proc:
    seq(A177510(n),n=1..20) ; # R. J. Mathar, Dec 14 2010
  • Mathematica
    Clear[t, nn]; nn = 39; t[n_, 1] = 1; t[n_, k_] := t[n, k] = If[n >= k, Sum[t[n - i, k - 1], {i, 1, k - 1}], 0]; Table[Sum[t[n, k], {k, 1, n}], {n, 1, nn}] (* Mats Granvik, Jan 01 2015 *)
    pdw[y_]:=Length[Select[Range[Length[y]],#<=y[[#]]&]]; Table[Length[Select[Join@@Permutations/@IntegerPartitions[n],pdw[#]==1&]],{n,0,10}] (* Gus Wiseman, Mar 31 2022 *)
  • PARI
    N=66; q='q+O('q^N); Vec( 1 + q/(1-q) * sum(n=0, N, q^n * prod(k=1, n, (1-q^k)/(1-q) ) ) ) \\ Joerg Arndt, Mar 24 2014
  • Sage
    @CachedFunction
    def T(n, k): # A179748
        if n == 0:  return int(k==0);
        if k == 1:  return int(n>=1);
        return sum( T(n-i, k-1) for i in [1..k-1] );
    # to display triangle A179748 including column zero = [1,0,0,0,...]:
    #for n in [0..10]: print([ T(n,k) for k in [0..n] ])
    def a(n): return sum( T(n,k) for k in [0..n] )
    print([a(n) for n in [0..66]])
    # Joerg Arndt, Mar 24 2014
    

Formula

G.f.: 1 + q/(1-q) * sum(n>=0, q^n * prod(k=1..n, (1-q^k)/(1-q) ) ). [Joerg Arndt, Mar 24 2014]

Extensions

New name and a(0) = 1 prepended, Joerg Arndt, Mar 24 2014

A352486 Heinz numbers of non-self-conjugate integer partitions.

Original entry on oeis.org

3, 4, 5, 7, 8, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 21, 22, 23, 24, 25, 26, 27, 28, 29, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73
Offset: 1

Views

Author

Gus Wiseman, Mar 20 2022

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 sequence lists all Heinz numbers of partitions whose Heinz number is different from that of their conjugate.

Examples

			The terms together with their prime indices begin:
   3: (2)
   4: (1,1)
   5: (3)
   7: (4)
   8: (1,1,1)
  10: (3,1)
  11: (5)
  12: (2,1,1)
  13: (6)
  14: (4,1)
  15: (3,2)
  16: (1,1,1,1)
  17: (7)
  18: (2,2,1)
For example, the self-conjugate partition (4,3,3,1) has Heinz number 350, so 350 is not in the sequence.
		

Crossrefs

The complement is A088902, counted by A000700.
These partitions are counted by A330644.
These are the positions of nonzero terms in A352491.
A000041 counts integer partitions, strict A000009.
A098825 counts permutations by unfixed points.
A238349 counts compositions by fixed points, rank statistic A352512.
A325039 counts partitions w/ same product as conjugate, ranked by A325040.
A352523 counts compositions by unfixed points, rank statistic A352513.
Heinz number (rank) and partition:
- A003963 = product of partition, conjugate A329382
- A008480 = number of permutations of partition, conjugate A321648.
- A056239 = sum of partition
- A122111 = rank of conjugate partition
- A296150 = parts of partition, reverse A112798, conjugate A321649
- A352487 = less than conjugate, counted by A000701
- A352488 = greater than or equal to conjugate, counted by A046682
- A352489 = less than or equal to conjugate, counted by A046682
- A352490 = greater than conjugate, counted by A000701

Programs

  • Mathematica
    primeMS[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];
    conj[y_]:=If[Length[y0]==0,y,Table[Length[Select[y,#>=k&]],{k,1,Max[y]}]];
    Select[Range[100],#!=Times@@Prime/@conj[primeMS[#]]&]

Formula

a(n) != A122111(a(n)).

A352512 Number of fixed points in the n-th composition in standard order.

Original entry on oeis.org

0, 1, 0, 1, 0, 0, 2, 1, 0, 0, 1, 0, 1, 2, 1, 1, 0, 0, 1, 0, 0, 1, 0, 0, 1, 1, 2, 2, 2, 1, 1, 1, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 1, 1, 1, 1, 3, 2, 2, 2, 1, 2, 1, 1, 1, 1, 1, 1, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 2, 1, 1
Offset: 0

Views

Author

Gus Wiseman, Mar 26 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. See also A000120, A059893, A070939, A114994, A225620.
A fixed point of composition c is an index i such that c_i = i.

Examples

			The 169th composition in standard order is (2,2,3,1), with fixed points {2,3}, so a(169) = 2.
		

Crossrefs

The version counting permutations is A008290, unfixed A098825.
The triangular version is A238349, first column A238351.
Unfixed points are counted by A352513, triangle A352523, first A352520.
A011782 counts compositions.
A088902 gives the fixed points of A122111, counted by A000700.
A352521 counts comps by strong nonexcedances, first A219282, stat A352514.
A352522 counts comps by weak nonexcedances, first col A238874, stat A352515.
A352524 counts comps by strong excedances, first col A008930, stat A352516.
A352525 counts comps by weak excedances, first col A177510, stat A352517.

Programs

  • Mathematica
    stc[n_]:=Differences[Prepend[Join@@ Position[Reverse[IntegerDigits[n,2]],1],0]]//Reverse;
    pq[y_]:=Length[Select[Range[Length[y]],#==y[[#]]&]];
    Table[pq[stc[n]],{n,0,100}]

Formula

A000120(n) = A352512(n) + A352513(n).

A352525 Irregular triangle read by rows where T(n,k) is the number of integer compositions of n with k weak excedances (parts on or above the diagonal), all zeros removed.

Original entry on oeis.org

1, 1, 2, 3, 1, 5, 3, 8, 8, 14, 17, 1, 25, 35, 4, 46, 70, 12, 87, 137, 32, 167, 268, 76, 1, 324, 525, 170, 5, 634, 1030, 367, 17, 1248, 2026, 773, 49, 2466, 3999, 1598, 129, 4887, 7914, 3267, 315, 1, 9706, 15695, 6631, 730, 6, 19308, 31181, 13393, 1631, 23
Offset: 0

Views

Author

Gus Wiseman, Mar 22 2022

Keywords

Examples

			Triangle begins:
     1
     1
     2
     3     1
     5     3
     8     8
    14    17     1
    25    35     4
    46    70    12
    87   137    32
   167   268    76     1
   324   525   170     5
For example, row n = 6 counts the following compositions:
  (6)       (15)     (123)
  (51)      (24)
  (312)     (33)
  (411)     (42)
  (1113)    (114)
  (1122)    (132)
  (2112)    (141)
  (2121)    (213)
  (3111)    (222)
  (11112)   (231)
  (11121)   (321)
  (11211)   (1131)
  (21111)   (1212)
  (111111)  (1221)
            (1311)
            (2211)
            (12111)
		

Crossrefs

Row sums are A011782.
The version for partitions is A115994.
The version for permutations is A123125, strong A173018.
Column k = 1 is A177510.
The corresponding rank statistic is A352517.
The strong opposite is A352521, first col A219282, rank statistic A352514.
The opposite version is A352522, first col A238874, rank statistic A352515.
The strong version is A352524, first column A008930, rank statistic A352516.
A008292 is the triangle of Eulerian numbers (version without zeros).
A238349 counts comps by fixed points, first col A238351, rank stat A352512.
A352489 lists the weak excedance set of A122111.
A352523 counts comps by unfixed points, first A352520, rank stat A352513.

Programs

  • Mathematica
    pdw[y_]:=Length[Select[Range[Length[y]],#<=y[[#]]&]];
    DeleteCases[Table[Length[Select[Join@@ Permutations/@IntegerPartitions[n],pdw[#]==k&]],{n,0,10},{k,0,n}],0,{2}]
  • PARI
    T(n)={my(v=vector(n+1, i, i==1), r=v); for(k=1, n, v=vector(#v, j, sum(i=1, j-1, if(k<=i,x,1)*v[j-i])); r+=v); r[1]=x; [Vecrev(p) | p<-r/x]}
    { my(A=T(10)); for(i=1, #A, print(A[i])) } \\ Andrew Howroyd, Jan 19 2023

A352826 Heinz numbers of integer partitions y without a fixed point y(i) = i. Such a fixed point is unique if it exists.

Original entry on oeis.org

1, 3, 5, 6, 7, 10, 11, 12, 13, 14, 17, 19, 20, 22, 23, 24, 25, 26, 28, 29, 31, 34, 35, 37, 38, 40, 41, 43, 44, 46, 47, 48, 49, 50, 52, 53, 55, 56, 58, 59, 61, 62, 65, 67, 68, 70, 71, 73, 74, 75, 76, 77, 79, 80, 82, 83, 85, 86, 88, 89, 91, 92, 94, 95, 96, 97
Offset: 1

Views

Author

Gus Wiseman, Apr 06 2022

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.

Examples

			The terms together with their prime indices begin:
      1: ()          24: (2,1,1,1)     47: (15)
      3: (2)         25: (3,3)         48: (2,1,1,1,1)
      5: (3)         26: (6,1)         49: (4,4)
      6: (2,1)       28: (4,1,1)       50: (3,3,1)
      7: (4)         29: (10)          52: (6,1,1)
     10: (3,1)       31: (11)          53: (16)
     11: (5)         34: (7,1)         55: (5,3)
     12: (2,1,1)     35: (4,3)         56: (4,1,1,1)
     13: (6)         37: (12)          58: (10,1)
     14: (4,1)       38: (8,1)         59: (17)
     17: (7)         40: (3,1,1,1)     61: (18)
     19: (8)         41: (13)          62: (11,1)
     20: (3,1,1)     43: (14)          65: (6,3)
     22: (5,1)       44: (5,1,1)       67: (19)
     23: (9)         46: (9,1)         68: (7,1,1)
		

Crossrefs

* = unproved
*These partitions are counted by A064428, strict A352828.
The complement is A352827.
The reverse version is A352830, counted by A238394.
A000700 counts self-conjugate partitions, ranked by A088902.
A001222 counts prime indices, distinct A001221.
*A001522 counts partitions with a fixed point.
A008290 counts permutations by fixed points, nonfixed A098825.
A056239 adds up prime indices, row sums of A112798 and A296150.
A115720 and A115994 count partitions by their Durfee square.
A122111 represents partition conjugation using Heinz numbers.
A124010 gives prime signature, sorted A118914.
A238349 counts compositions by fixed points, complement A352523.
A238352 counts reversed partitions by fixed points, rank statistic A352822.
A238395 counts reversed partitions with a fixed point, ranked by A352872.
A352833 counts partitions by fixed points.

Programs

  • Mathematica
    pq[y_]:=Length[Select[Range[Length[y]],#==y[[#]]&]];
    Select[Range[100],pq[Reverse[Flatten[Cases[FactorInteger[#],{p_,k_}:>Table[PrimePi[p],{k}]]]]]==0&]
Showing 1-10 of 43 results. Next