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

A078392 Sum of GCD's of parts in all partitions of n.

Original entry on oeis.org

1, 3, 5, 9, 11, 20, 21, 35, 42, 61, 66, 112, 113, 168, 210, 279, 313, 461, 508, 719, 852, 1088, 1277, 1756, 2006, 2573, 3106, 3937, 4593, 5958, 6872, 8676, 10305, 12655, 15009, 18664, 21673, 26559, 31447, 38217, 44623, 54386, 63303, 76379, 89696, 106879
Offset: 1

Views

Author

Vladeta Jovovic, Dec 24 2002

Keywords

Comments

Equals row sums of triangle A168534. - Gary W. Adamson, Nov 28 2009

Examples

			Partitions of 4 are 1+1+1+1, 1+1+2, 2+2, 1+3, 4, the corresponding GCD's of parts are 1,1,2,1,4 and their sum is a(4) = 9.
		

Crossrefs

Cf. A000010, A000041, A168534, A181844 (the same for LCM), A319301.

Programs

  • Maple
    with(numtheory): with(combinat):
    a:= n-> add(phi(n/d)*numbpart(d), d=divisors(n)):
    seq(a(n), n=1..50);  # Alois P. Heinz, Apr 02 2015
  • Mathematica
    a[n_] := Sum[EulerPhi[n/d]*PartitionsP[d], {d, Divisors[n]}]; Table[a[n], {n, 1, 50}] (* Jean-François Alcover, Jul 01 2015, after Alois P. Heinz *)

Formula

a(n) = Sum_{d|n} d * A000837(n/d).
a(n) = Sum_{d|n} phi(n/d)*numbpart(d) = Sum_{d|n} A000010(n/d)*A000041(d). - Vladeta Jovovic, May 08 2003
From Richard L. Ollerton, May 06 2021: (Start)
a(n) = Sum_{k=1..n} A000041(gcd(n,k)).
a(n) = Sum_{k=1..n} A000041(n/gcd(n,k))*A000010(gcd(n,k))/A000010(n/gcd(n,k)). (End)

A256067 Irregular table T(n,k): the number of partitions of n where the least common multiple of all parts equals k.

Original entry on oeis.org

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

Views

Author

R. J. Mathar, Mar 18 2015

Keywords

Examples

			The 5 partitions of n=4 are 1+1+1+1 (lcm=1), 1+1+2 (lcm=2), 2+2 (lcm=2), 1+3 (lcm=3) and 4 (lcm=4). So k=1, 3 and 4 appear once, k=2 appears twice.
The triangle starts:
  1 ;
  1 ;
  1  1;
  1  1  1;
  1  2  1  1;
  1  2  1  1  1  1;
  1  3  2  2  1  2;
  1  3  2  2  1  3  1  0  0  1  0  1;
  ...
		

Crossrefs

Cf. A000041 (row sums), A000793 (row lengths), A213952, A074761 (diagonal), A074752 (6th column), A008642 (4th column), A002266 (5th column), A002264 (3rd column), A132270 (7th column), A008643 (8th column), A008649 (9th column), A258470 (10th column).
Cf. A009490 (number of nonzero terms of rows), A074064 (last elements of rows), A168532 (the same for gcd), A181844 (Sum k*T(n,k)).

Programs

  • Maple
    A256067 := proc(n,k)
            local a,p ;
            a := 0 ;
            for p in combinat[partition](n) do
                    ilcm(op(p)) ;
                    if % = k then
                            a := a+1 ;
                    end if;
            end do:
            a;
    end proc:
    # second Maple program:
    b:= proc(n, i) option remember; `if`(n=0 or i=1, x,
          b(n, i-1)+(p-> add(coeff(p, x, t)*x^ilcm(t, i),
          t=1..degree(p)))(add(b(n-i*j, i-1), j=1..n/i)))
        end:
    T:= n-> (p-> seq(coeff(p, x, i), i=1..degree(p)))(b(n$2)):
    seq(T(n), n=0..12);  # Alois P. Heinz, Mar 27 2015
  • Mathematica
    b[n_, i_] := b[n, i] = If[n == 0 || i == 1, x, b[n, i-1] + Function[{p}, Sum[ Coefficient[p, x, t]*x^LCM[t, i], {t, 1, Exponent[p, x]}]][Sum[b[n-i*j, i-1], {j, 1, n/i}]]]; T[n_] := Function[{p}, Table[Coefficient[p, x, i], {i, 1, Exponent[p, x]}]][b[n, n]]; Table[T[n], {n, 0, 12}] // Flatten (* Jean-François Alcover, Jun 22 2015, after Alois P. Heinz *)

Extensions

T(0,1)=1 prepended by Alois P. Heinz, Mar 27 2015

A181842 Triangle read by rows: T(n,k) = Sum_{c in partition(n,n-k+1)} lcm(c).

Original entry on oeis.org

1, 1, 2, 1, 2, 3, 1, 2, 5, 4, 1, 2, 5, 10, 5, 1, 2, 5, 12, 12, 6, 1, 2, 5, 12, 18, 28, 7, 1, 2, 5, 12, 20, 38, 32, 8, 1, 2, 5, 12, 20, 44, 57, 48, 9, 1, 2, 5, 12, 20, 46, 67, 100, 55, 10
Offset: 1

Views

Author

Peter Luschny, Dec 07 2010

Keywords

Comments

In A181842 through A181854 the following terminology is used.
Let n, k be positive integers.
* Partition: A (n,k)-partition is the set of all k-sets of
positive integers whose elements sum to n.
- The cardinality of a (n,k)-partition: A008284(n,k).
- Maple: (n,k) -> combstruct[count](Partition(n),size=k).
- The (6,2)-partition is {{1,5},{2,4},{3,3}}.
* Composition: A (n,k)-composition is the set of all k-tuples of positive integers whose elements sum to n.
- The cardinality of a (n,k)-composition: A007318(n-1,k-1).
- Maple: (n,k) -> combstruct[count](Composition(n),size=k).
- The (6,2)-composition is {<5,1>,<4,2>,<3,3>,<2,4>,<1,5>}.
* Combination: A (n,k)-combination is the set of all k-subsets
of {1,2,..,n}.
- The cardinality of a (n,k)-combination: A007318(n,k).
- Maple: (n,k) -> combstruct[count](Combination(n),size=k).
- The (4,2)-combination is {{1,2},{1,3},{1,4},{2,3},{2,4},{3,4}}.

Examples

			[1]   1
[2]   1   2
[3]   1   2   3
[4]   1   2   5   4
[5]   1   2   5   10   5
[6]   1   2   5   12   12   6
[7]   1   2   5   12   18   28   7
		

Crossrefs

Programs

  • Maple
    with(combstruct):
    a181842_row := proc(n) local k,L,l,R,part;
    R := NULL;
    for k from 1 to n do
       L := 0;
       part := iterstructs(Partition(n),size=n-k+1):
       while not finished(part) do
          l := nextstruct(part);
          L := L + ilcm(op(l));
       od;
       R := R,L;
    od;
    R end:
  • Mathematica
    t[n_, k_] := LCM @@@ IntegerPartitions[n, {n - k + 1}] // Total; Table[t[n, k], {n, 1, 10}, {k, 1, n}] // Flatten (* Jean-François Alcover, Jul 26 2013 *)

A256554 Number T(n,k) of cycle types of degree-n permutations having the k-th smallest possible order; triangle T(n,k), n>=0, 1<=k<=A009490(n), read by rows.

Original entry on oeis.org

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

Views

Author

Alois P. Heinz, Apr 01 2015

Keywords

Comments

Sum_{k>=0} A256553(n,k)*T(n,k) = A181844(n).

Examples

			Triangle T(n,k) begins:
  1;
  1;
  1, 1;
  1, 1, 1;
  1, 2, 1, 1;
  1, 2, 1, 1, 1, 1;
  1, 3, 2, 2, 1, 2;
  1, 3, 2, 2, 1, 3, 1, 1, 1;
  1, 4, 2, 4, 1, 5, 1, 1, 1, 1, 1;
  1, 4, 3, 4, 1, 7, 1, 1, 1, 2, 2, 1, 1, 1;
  1, 5, 3, 6, 2, 9, 1, 2, 1, 3, 4, 1, 1, 1, 1, 1;
		

Crossrefs

Row sums give A000041.
Row lengths give A009490.
Columns k=1-9 give: A000012, A004526, A002264, A008642(n-4), A002266, A074752, A132270, A008643(n-8) for n>7, A008649(n-9) for n>8.
Last elements of rows give A074064.
Main diagonal gives A074761.

Programs

  • Maple
    b:= proc(n, i) option remember; `if`(n=0 or i=1, x,
          b(n, i-1)+(p-> add(coeff(p, x, t)*x^ilcm(t, i),
          t=1..degree(p)))(add(b(n-i*j, i-1), j=1..n/i)))
        end:
    T:= n->(p->seq((h->`if`(h=0, [][], h))(coeff(p, x, i))
         , i=1..degree(p)))(b(n$2)):
    seq(T(n), n=0..12);
  • Mathematica
    b[n_, i_] := b[n, i] = If[n == 0 || i == 1, x, b[n, i - 1] + Function[p, Sum[Coefficient[p, x, t]*x^LCM[t, i], {t, 1, Exponent[p, x]}]][Sum[b[n - i*j, i - 1], {j, 1, n/i}]]]; T[n_] := Function[p, Table[Function[h, If[h == 0, {{}, {}}, h]][Coefficient[p, x, i]], {i, 1, Exponent[p, x]}]][b[n, n]]; Table[T[n], {n, 0, 12}] // Flatten (* Jean-François Alcover, Jan 23 2017, translated from Maple *)

A256553 Triangle T(n,k) in which the n-th row contains the increasing list of distinct orders of degree-n permutations; n>=0, 1<=k<=A009490(n).

Original entry on oeis.org

1, 1, 1, 2, 1, 2, 3, 1, 2, 3, 4, 1, 2, 3, 4, 5, 6, 1, 2, 3, 4, 5, 6, 1, 2, 3, 4, 5, 6, 7, 10, 12, 1, 2, 3, 4, 5, 6, 7, 8, 10, 12, 15, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 14, 15, 20, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 14, 15, 20, 21, 30
Offset: 0

Views

Author

Alois P. Heinz, Apr 01 2015

Keywords

Examples

			Triangle T(n,k) begins:
  1;
  1;
  1, 2;
  1, 2, 3;
  1, 2, 3, 4;
  1, 2, 3, 4, 5, 6;
  1, 2, 3, 4, 5, 6;
  1, 2, 3, 4, 5, 6, 7, 10, 12;
  1, 2, 3, 4, 5, 6, 7,  8, 10, 12, 15;
  1, 2, 3, 4, 5, 6, 7,  8,  9, 10, 12, 14, 15, 20;
  1, 2, 3, 4, 5, 6, 7,  8,  9, 10, 12, 14, 15, 20, 21, 30;
		

Crossrefs

Row sums give A060179.
Row lengths give A009490.
Last elements of rows give A000793.
Main diagonal gives A000027.

Programs

  • Maple
    b:= proc(n, i) option remember; `if`(n=0 or i=1, x,
          b(n, i-1)+(p-> add(coeff(p, x, t)*x^ilcm(t, i),
          t=1..degree(p)))(add(b(n-i*j, i-1), j=1..n/i)))
        end:
    T:= n->(p->seq((h->`if`(h=0, [][], i))(coeff(p, x, i))
         , i=1..degree(p)))(b(n$2)):
    seq(T(n), n=0..12);
  • Mathematica
    b[n_, i_] := b[n, i] = If[n == 0 || i == 1, x,
         b[n, i - 1] + Function[p, Sum[Coefficient[p, x, t]*x^LCM[t, i],
         {t, 1, Exponent[p, x]}]][Sum[b[n - i*j, i - 1], {j, 1, n/i}]]];
    T[n_] := Function[p, Table[Function[h, If[h == 0, Nothing, i]][
         Coefficient[p, x, i]], {i, 1, Exponent[p, x]}]][b[n, n]];
    Table[T[n], {n, 0, 12}] // Flatten (* Jean-François Alcover, Jul 15 2021, after Alois P. Heinz *)

Formula

Sum_{k>=0} T(n,k)*A256554(n,k) = A181844(n).
T(n,k) = k for n>0 and 1<=k<=n.

A181843 Triangle read by rows: Partial row sums of A181842.

Original entry on oeis.org

1, 1, 3, 1, 3, 6, 1, 3, 8, 12, 1, 3, 8, 18, 23, 1, 3, 8, 20, 32, 38, 1, 3, 8, 20, 38, 66, 73, 1, 3, 8, 20, 40, 78, 110, 118, 1, 3, 8, 20, 40, 84, 141, 189, 198, 1, 3, 8, 20, 40, 86, 153, 253, 308, 318, 1, 3, 8, 20, 40, 86, 159, 287, 409, 519, 530, 1, 3, 8, 20, 40, 86, 161, 299, 476, 728, 807, 819
Offset: 1

Views

Author

Peter Luschny, Dec 07 2010

Keywords

Examples

			[1]   1
[2]   1   3
[3]   1   3   6
[4]   1   3   8   12
[5]   1   3   8   18   23
[6]   1   3   8   20   32   38
[7]   1   3   8   20   38   66   73
		

Crossrefs

Programs

  • Maple
    with(combstruct):
    a181843_row := proc(n) local k,L,l,R,part;
    R := NULL; L := 0;
    for k from 1 to n do
       part := iterstructs(Partition(n),size=n-k+1):
       while not finished(part) do
          l := nextstruct(part);
          L := L + ilcm(op(l));
       od;
       R := R,L;
    od;
    R end:
  • Mathematica
    t[n_, k_] := LCM @@@ IntegerPartitions[n, {n - k + 1}] // Total; row[n_] := Table[t[n, k], {k, 1, n}] // Accumulate; Table[row[n], {n, 1, 12}] // Flatten (* Jean-François Alcover, Jul 26 2013 *)

Extensions

Terms from an erroneous copy and paste transfer corrected.
More terms from Jean-François Alcover, Jul 26 2013

A306956 Sum over all partitions of n into distinct parts of the LCM of the parts.

Original entry on oeis.org

1, 1, 2, 5, 7, 15, 21, 39, 58, 90, 142, 218, 325, 465, 695, 948, 1411, 1977, 2883, 3940, 5415, 7422, 10126, 14091, 18947, 25666, 34282, 45890, 60710, 82211, 108510, 142960, 185271, 240595, 315158, 409231, 531967, 688689, 880997, 1126451, 1447754, 1849743
Offset: 0

Views

Author

Alois P. Heinz, Mar 17 2019

Keywords

Crossrefs

Programs

  • Maple
    b:= proc(n, i, r) option remember; `if`(i*(i+1)/2 b(n$2, 1):
    seq(a(n), n=0..44);
  • Mathematica
    b[n_, i_, r_] := b[n, i, r] = If[i(i+1)/2 < n, 0, If[n == 0, r, b[n, i-1, r] + b[n-i, Min[i-1, n-i], LCM[i, r]]]];
    a[n_] := b[n, n, 1];
    Table[a[n], {n, 0, 44}] (* Jean-François Alcover, Mar 20 2019, translated from Maple *)

Formula

a(n) mod 2 = A040051(n).
a(n) is even <=> n in { A001560 }.
a(n) is odd <=> n in { A052002 }.

A181845 Triangle read by rows: T(n,k) = max_{c in P(n,n-k+1)} lcm(c) where P(n,m) = A008284(n,m) is the number of partitions of n into m parts.

Original entry on oeis.org

1, 1, 2, 1, 2, 3, 1, 2, 3, 4, 1, 2, 3, 6, 5, 1, 2, 3, 6, 5, 6, 1, 2, 3, 6, 6, 12, 7, 1, 2, 3, 6, 6, 12, 15, 8, 1, 2, 3, 6, 6, 12, 15, 20, 9, 1, 2, 3, 6, 6, 12, 15, 30, 21, 10, 1, 2, 3, 6, 6, 12, 15, 30, 21, 30, 11, 1, 2, 3, 6, 6, 12, 15, 30, 30, 60, 35, 12
Offset: 1

Views

Author

Peter Luschny, Dec 07 2010

Keywords

Comments

See A181842 for the definition of 'partition'. T(n,k) is also the triangle read by rows: T(n,k) = max_{c in C(n,n-k+1)} lcm(c) where C(n,m) is the set of all m-tuples of positive integers whose elements sum to n where the C(n,k) = A007318(n-1,k-1) are called compositions of n of size k.

Examples

			[1]   1
[2]   1   2
[3]   1   2   3
[4]   1   2   3   4
[5]   1   2   3   6   5
[6]   1   2   3   6   5   6
[7]   1   2   3   6   6   12   7
[8]   1   2   3   6   6   12   15   8
[9]   1   2   3   6   6   12   15   20   9
		

Crossrefs

Programs

  • Maple
    with(combstruct):
    a181845_row := proc(n) local k,L,l,R,part;
    R := NULL;
    for k from 1 to n do
       L := 0;
       part := iterstructs(Partition(n),size=n-k+1):
    # alternatively (but slower)
    # part := iterstructs(Composition(n), size=n-k+1):
       while not finished(part) do
          l := nextstruct(part);
          L := max(L,ilcm(op(l)));
       od;
       R := R,L;
    od;
    R end:
  • PARI
    Row(n)={my(v=vector(n)); forpart(p=n, my(i=#p); v[i]=max(v[i], lcm(Vec(p)))); Vecrev(v)}
    { for(n=1, 10, print(Row(n))) } \\ Andrew Howroyd, Apr 20 2021

Extensions

Terms a(56) and beyond from Andrew Howroyd, Apr 20 2021
Showing 1-8 of 8 results.