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.

A120855 Row sums of triangle A120854, which is the matrix log of triangle A117939.

Original entry on oeis.org

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

Views

Author

Paul D. Hanna, Jul 08 2006

Keywords

Comments

Triangle A117939 is related to powers of 3 partitions of n and is the matrix square of A117947(n,k) = balanced ternary digits of C(n,k) mod 3, also A117947(n,k) = L(C(n,k)/3) where L(j/p) is the Legendre symbol of j and p.

Crossrefs

Programs

  • Mathematica
    f[n_] := DigitCount[n, 3] /. {a_, b_, c_} -> 2a + b + 0c; Array[f, 105, 0] (* Robert G. Wilson v, Jul 31 2012 *)
  • PARI
    {a(n)=local(M=matrix(n+1,n+1,r,c,(binomial(r-1,c-1)+1)%3-1)^2, L=sum(i=1,#M,-(M^0-M)^i/i));return(sum(k=0,n,L[n+1,k+1]))}

Formula

a(n) = 2*A062756 + A081603(n), where A062756(n) = number of 1's in ternary expansion of n and A081603(n) = number of 2's in ternary expansion of n.

A117939 Triangle related to powers of 3 partitions of n.

Original entry on oeis.org

1, 2, 1, 1, -2, 1, 2, 0, 0, 1, 4, 2, 0, 2, 1, 2, -4, 2, 1, -2, 1, 1, 0, 0, -2, 0, 0, 1, 2, 1, 0, -4, -2, 0, 2, 1, 1, -2, 1, -2, 4, -2, 1, -2, 1, 2, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 2, 0, 0, 0, 0, 0, 0, 0, 2, 1, 2, -4, 2, 0, 0, 0, 0, 0, 0, 1, -2, 1, 4, 0, 0, 2, 0, 0, 0, 0, 0, 2, 0, 0, 1, 8, 4, 0, 4, 2, 0, 0, 0, 0, 4, 2, 0, 2, 1
Offset: 0

Views

Author

Paul Barry, Apr 05 2006

Keywords

Examples

			Triangle begins
  1;
  2,  1;
  1, -2, 1;
  2,  0, 0,  1;
  4,  2, 0,  2,  1;
  2, -4, 2,  1, -2,  1;
  1,  0, 0, -2,  0,  0, 1;
  2,  1, 0, -4, -2,  0, 2,  1;
  1, -2, 1, -2,  4, -2, 1, -2, 1;
		

Crossrefs

Cf. A120854 (matrix log), A117941 (inverse), A117947 (matrix square-root).

Programs

  • Mathematica
    T[n_, k_]:= Sum[JacobiSymbol[Binomial[n, j], 3]*JacobiSymbol[Binomial[n-j, k], 3], {j, 0, n}]; Table[T[n, k], {n,0,15}, {k,0,n}]//Flatten (* G. C. Greubel, Oct 29 2021 *)
  • PARI
    T(n,k)=(matrix(n+1,n+1,r,c,(binomial(r-1,c-1)+1)%3-1)^2)[n+1,k+1] \\ Paul D. Hanna, Jul 08 2006
    
  • Sage
    def A117939(n, k): return sum(jacobi_symbol(binomial(n, j), 3)*jacobi_symbol(binomial(n-j, k), 3) for j in (0..n))
    flatten([[A117939(n, k) for k in (0..n)] for n in (0..15)]) # G. C. Greubel, Oct 29 2021

Formula

Triangle T(n,k) = Sum_{j=0..n} L(C(n,j)/3)*L(C(n-j,k)/3) where L(j/p) is the Legendre symbol of j and p.
T(n, k) mod 2 = A117944(n,k).
T(n, 0) = A059151(n).
T(n, 1) = A117946(n).
Sum_{k=0..n} T(n, k) = A117940(n).
Matrix square of triangle A117947. Matrix log is the integer triangle A120854. - Paul D. Hanna, Jul 08 2006

A117947 T(n,k)=L(C(n,k)/3) where L(j/p) is the Legendre symbol of j and p.

Original entry on oeis.org

1, 1, 1, 1, -1, 1, 1, 0, 0, 1, 1, 1, 0, 1, 1, 1, -1, 1, 1, -1, 1, 1, 0, 0, -1, 0, 0, 1, 1, 1, 0, -1, -1, 0, 1, 1, 1, -1, 1, -1, 1, -1, 1, -1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, -1, 1, 0, 0, 0, 0, 0, 0, 1, -1, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 1, 1, 1, 0, 1, 1, 0, 0, 0, 0, 1, 1, 0, 1, 1, 1, -1, 1, 1, -1, 1, 0, 0, 0, 1, -1, 1, 1, -1, 1
Offset: 0

Views

Author

Paul Barry, Apr 05 2006

Keywords

Comments

Row sums are A059126. Diagonal sums are A117963. Could be called the Legendre-binomial matrix for p=3.
The matrix square equals triangle A117939; the matrix log equals triangle A120854 divided by 2. - Paul D. Hanna, Jul 08 2006

Examples

			Triangle begins:
  1;
  1, 1;
  1, -1, 1;
  1, 0, 0, 1;
  1, 1, 0, 1, 1;
  ...
		

Crossrefs

Cf. A117939 (matrix square), A120854 (2*log).

Programs

Formula

T(n,k) = balanced ternary digit of C(n,k) mod 3. - Paul D. Hanna, Jul 08 2006
Showing 1-3 of 3 results.