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

A216665 Triangular array read by rows: T(n,k) is the number of partitions of n into k parts of 2 different sizes; n>=3, 2<=k<=n-1.

Original entry on oeis.org

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

Views

Author

Geoffrey Critzer, Sep 13 2012

Keywords

Comments

Row sums = A002133.
First column (corresponding to k=2) = floor( (n-1)/2 ).

Examples

			T(8,3) = 3 because we have: 6+1+1, 4+2+2, 3+3+2.
Triangle indexed from n=3 and k=2:
1;
1, 1;
2, 2, 1;
2, 1, 2, 1;
3, 3, 2, 2, 1;
3, 3, 2, 2, 2, 1;
4, 3, 2, 3, 2, 2, 1;
4, 4, 5, 1, 3, 2, 2, 1;
		

Crossrefs

Programs

  • Mathematica
    nn=15;ss=Sum[Sum[y^2 x^(i+j)/(1-y x^i)/(1-y x^j),{j,1,i-1}],{i,1,nn}]; f[list_]:=Select[list,#>0&];Map[f,CoefficientList[Series[ss,{x,0,nn}], {x,y}]]//Flatten

Formula

G.f.: Sum_{i>=1} Sum_{j=1..n-1} y^2*x^(i+j)/((1-y*x^j)*(1-y*x^i)).

A274109 Triangle read by rows: T(n,k) = number of partitions of n into exactly k parts with exactly two different sizes, the sizes being relatively prime (n >= 3, 2 <= k <= n-1).

Original entry on oeis.org

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

Views

Author

N. J. A. Sloane, Jun 17 2016

Keywords

Examples

			Triangle T(n,k) (with columns n >= 3 and k >= 2) begins as follows:
  1;
  1, 1;
  2, 2, 1;
  1, 1, 2, 1;
  3, 3, 2, 2, 1;
  2, 2, 2, 2, 2, 1;
  3, 3, 2, 3, 2, 2, 1;
  2, 2, 4, 1, 3, 2, 2, 1;
  5, 5, 3, 4, 2, 3, 2, 2, 1;
  2, 2, 2, 2, 3, 2, 3, 2, 2, 1;
  6, 6, 4, 5, 2, 4, 2, 3, 2, 2, 1;
  3, 3, 5, 3, 4, 1, 4, 2, 3, 2, 2, 1;
  4, 4, 3, 3, 4, 4, 2, 4, 2, 3, 2, 2, 1;
  ...
		

Crossrefs

Row sums give A274108.

A377812 Number of quadruples of positive integers (x,y,a,b) such that a < b, gcd(a,b) = gcd(x,y) = 1 and a*x + b*y = n.

Original entry on oeis.org

0, 0, 1, 2, 5, 4, 11, 9, 15, 12, 27, 14, 37, 22, 32, 31, 59, 26, 71, 38, 58, 48, 97, 42, 99, 62, 93, 68, 141, 48, 157, 91, 120, 94, 150, 78, 207, 112, 154, 108, 241, 84, 259, 138, 170, 150, 295, 116, 289, 144, 232, 178, 353, 136, 304, 188, 274, 210, 413, 132
Offset: 1

Views

Author

Anshveer Bindra, Nov 08 2024

Keywords

Comments

Number of partitions of n into parts with exactly two different sizes, the sizes being relatively prime and also the multiplicities of the two part sizes being relatively prime. - Andrew Howroyd, Nov 10 2024

Crossrefs

Programs

  • PARI
    a(n)={sum(b=2, n-1, sum(y=1, (n-1)\b, my(s=n-b*y); sumdiv(s, a, aAndrew Howroyd, Nov 10 2024
    
  • PARI
    seq(n)={my(v=Vec(sum(k=1, n-1, numdiv(k)*x^k, O(x^n))^2, -n), u=vector(n, n, moebius(n))); dirmul(dirmul(u,u), vector(#v, n, v[n]+numdiv(n)-sigma(n))/2)} \\ Andrew Howroyd, Nov 10 2024
  • Python
    def a(n):
        count = 0
        for a in range(1, n+1):
            for b in range(a + 1, n+1):
                if gcd(a, b) == 1:
                    for x in range(1, n+1):
                        for y in range(1, n+1):
                            if gcd(x, y) == 1 and a * x + b * y == n:
                                count += 1
        return count
    print([a(n) for n in range(1,21)])
    
  • Python
    from math import gcd
    from sympy import divisors
    def A377812(n): return sum(1 for ax in range(1,n-1) for a in divisors(ax,generator=True) for b in divisors(n-ax,generator=True) if aChai Wah Wu, Dec 11 2024
    

Formula

Moebius transform of A274108. - Andrew Howroyd, Nov 10 2024

Extensions

a(21) onwards from Andrew Howroyd, Nov 10 2024
Showing 1-3 of 3 results.