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.

A114327 Table T(n,m) = n - m read by upwards antidiagonals.

Original entry on oeis.org

0, 1, -1, 2, 0, -2, 3, 1, -1, -3, 4, 2, 0, -2, -4, 5, 3, 1, -1, -3, -5, 6, 4, 2, 0, -2, -4, -6, 7, 5, 3, 1, -1, -3, -5, -7, 8, 6, 4, 2, 0, -2, -4, -6, -8, 9, 7, 5, 3, 1, -1, -3, -5, -7, -9, 10, 8, 6, 4, 2, 0, -2, -4, -6, -8, -10, 11, 9, 7, 5, 3, 1, -1, -3, -5, -7, -9, -11, 12, 10, 8, 6, 4, 2, 0, -2, -4, -6, -8, -10, -12
Offset: 0

Views

Author

Keywords

Comments

From Clark Kimberling, May 31 2011: (Start)
If we arrange A000027 as an array with northwest corner
1 2 4 7 17 ...
3 5 8 12 18 ...
6 9 13 18 24 ...
10 14 19 25 32 ...
diagonals can be numbered as follows depending on their distance to the main diagonal:
Diag 0: 1, 5, 13, 25, ...
Diag 1: 2, 8, 18, 32, ...
Diag -1: 3, 9, 19, 33, ...,
then a(n) in the flattened array is the number of the diagonal that contains n+1. (End)
Construct the infinite-dimensional matrix representation of angular momentum operators (J_1,J_2,J_3) in Jordan-Schwinger form (cf. Harter, Klee, Schwinger). Triangle terms T(n,k) = T(2j,j-m) satisfy: (1/2) T(2j,j-m) = = m. Matrix J_3 is diagonal, so this equality determines the only nonzero entries. - Bradley Klee, Jan 29 2016
For the characteristic polynomial of the n X n matrix M_n (Det(x*1_n - M_n)) with elements M_n(i, j) = i-j see the Michael Somos, Nov 14 2002, comment on A002415. - Wolfdieter Lang, Feb 05 2018
The entries of the n-th antidiagonal, T(n,1), T(n-1,2), ... , T(1,n), are the eigenvalues of the Hamming graph H(2,n-1) (or hypercube Q(n-1)). - Miquel A. Fiol, May 21 2024

Examples

			From _Wolfdieter Lang_, Feb 05 2018: (Start)
The table T(n, m) begins:
  n\m 0  1  2  3  4  5 ...
  0:  0 -1 -2 -3 -4 -5 ...
  1:  1  0 -1 -2 -3 -4 ...
  2:  2  1  0 -1 -2 -3 ...
  3:  3  2  1  0 -1 -2 ...
  4:  4  3  2  1  0 -1 ...
  5:  5  4  3  2  1  0 ...
  ...
The triangle t(n, k) begins:
  n\k  0  1  2  3  4  5  6  7  8  9  10 ...
  0:   0
  1:   1 -1
  2:   2  0 -2
  3:   3  1 -1 -3
  4:   4  2  0 -2 -4
  5:   5  3  1 -1 -3 -5
  6:   6  4  2  0 -2 -4 -6
  7:   7  5  3  1 -1 -3 -5 -7
  8:   8  6  4  2  0 -2 -4 -6 -8
  9:   9  7  5  3  1 -1 -3 -5 -7 -9
  10: 10  8  6  4  2  0 -2 -4 -6 -8 -10
  ... Reformatted and corrected. (End)
		

Crossrefs

Apart from signs, same as A049581. Cf. A003056, A025581, A002262, A002260, A004736. J_1,J_2: A094053; J_1^2,J_2^2: A141387, A268759. A002415.

Programs

  • Haskell
    a114327 n k = a114327_tabl !! n !! k
    a114327_row n = a114327_tabl !! n
    a114327_tabl = zipWith (zipWith (-)) a025581_tabl a002262_tabl
    -- Reinhard Zumkeller, Aug 09 2014
    
  • Maple
    seq(seq(i-2*j,j=0..i),i=0..30); # Robert Israel, Jan 29 2016
  • Mathematica
    max = 12; a025581 = NestList[Prepend[#, First[#]+1]&, {0}, max]; a002262 = Table[Range[0, n], {n, 0, max}]; a114327 = a025581 - a002262 // Flatten (* Jean-François Alcover, Jan 04 2016 *)
    Flatten[Table[-2 m, {j, 0, 10, 1/2}, {m, -j, j}]] (* Bradley Klee, Jan 29 2016 *)
  • PARI
    T(n,m) = n-m \\ Charles R Greathouse IV, Feb 07 2017
    
  • Python
    from math import isqrt
    def A114327(n): return ((m:=isqrt(k:=n+1<<1))+(k>m*(m+1)))**2+1-k # Chai Wah Wu, Nov 09 2024

Formula

G.f. for the table: Sum_{n, m>=0} T(n,m)*x^n*y^n = (x-y)/((1-x)^2*(1-y)^2).
E.g.f. for the table: Sum_{n, m>=0} T(n,m)x^n/n!*y^m/m! = (x-y)*e^{x+y}.
T(n,k) = A025581(n,k) - A002262(n,k).
a(n+1) = A004736(n) - A002260(n) or a(n+1) = ((t*t+3*t+4)/2-n) - (n-t*(t+1)/2), where t=floor((-1+sqrt(8*n-7))/2). - Boris Putievskiy, Dec 24 2012
G.f. as sequence: -(1+x)/(1-x)^2 + Sum_{j>=0} (2*j+1)*x^(j*(j+1)/2) / (1-x). The sum is related to Jacobi theta functions. - Robert Israel, Jan 29 2016
Triangle t(n, k) = n - 2*k, for n >= 0, k = 0..n. (see the Maple program). - Wolfdieter Lang, Feb 05 2018

Extensions

Formula improved by Reinhard Zumkeller, Aug 09 2014

A094053 Triangle read by rows: T(n,k) = k*(n-k), 1 <= k <= n.

Original entry on oeis.org

0, 1, 0, 2, 2, 0, 3, 4, 3, 0, 4, 6, 6, 4, 0, 5, 8, 9, 8, 5, 0, 6, 10, 12, 12, 10, 6, 0, 7, 12, 15, 16, 15, 12, 7, 0, 8, 14, 18, 20, 20, 18, 14, 8, 0, 9, 16, 21, 24, 25, 24, 21, 16, 9, 0, 10, 18, 24, 28, 30, 30, 28, 24, 18, 10, 0, 11, 20, 27, 32, 35, 36, 35, 32, 27, 20, 11, 0, 12
Offset: 1

Views

Author

Reinhard Zumkeller, May 31 2004

Keywords

Comments

T(n,k) = A003991(n-1,k) for 1 <= k < n;
T(n,k) = T(n,n-1-k) for k < n;
T(n,1) = n-1; T(n,n) = 0; T(n,2) = A005843(n-2) for n > 1;
T(n,3) = A008585(n-3) for n>2; T(n,4) = A008586(n-4) for n > 3;
T(n,5) = A008587(n-5) for n>4; T(n,6) = A008588(n-6) for n > 5;
T(n,7) = A008589(n-7) for n>6; T(n,8) = A008590(n-8) for n > 7;
T(n,9) = A008591(n-9) for n>8; T(n,10) = A008592(n-10) for n > 9;
T(n,11) = A008593(n-11) for n>10; T(n,12) = A008594(n-12) for n > 11;
T(n,13) = A008595(n-13) for n>12; T(n,14) = A008596(n-14) for n > 13;
T(n,15) = A008597(n-15) for n>14; T(n,16) = A008598(n-16) for n > 15;
T(n,17) = A008599(n-17) for n>16; T(n,18) = A008600(n-18) for n > 17;
T(n,19) = A008601(n-19) for n>18; T(n,20) = A008602(n-20) for n > 19;
Row sums give A000292; triangle sums give A000332;
All numbers m > 0 occur A000005(m) times;
A002378(n) = T(A005408(n),n+1) = n*(n+1).
k-th columns are arithmetic progressions with step k, starting with 0. If a zero is prefixed to the sequence, then we get a new table where the columns are again arithmetic progressions with step k, but starting with k, k=0,1,2,...: 1st column = (0,0,0,...), 2nd column = (1,2,3,...), 3rd column = (2,4,6,8,...), etc. - M. F. Hasler, Feb 02 2013
Construct the infinite-dimensional matrix representation of angular momentum operators (J_1,J_2,J_3) in the Jordan-Schwinger form (cf. Harter, Klee, Schwinger). The triangle terms T(n,k) = T(2j,j+m) satisfy: (1/2)T(2j,j+m)^(1/2) = = = i = -i . Matrices for J_1 and J_2 are sparse. These equalities determine the only nonzero entries. - Bradley Klee, Jan 29 2016
T(n+1,k+1) is the number of degrees of freedom of a k-dimensional affine subspace within an n-dimensional vector space. This is most readily interpreted geometrically: e.g. in 3 dimensions a line (1-dimensional subspace) has T(4,2) = 4 degrees of freedom and a plane has T(4,3) = 3. T(n+1,1) = n indicates that points in n dimensions have n degrees of freedom. T(n,n) = 0 for any n as all n-dimensional spaces in an n-dimensional space are equivalent. - Daniel Leary, Apr 29 2020

Examples

			From _M. F. Hasler_, Feb 02 2013: (Start)
Triangle begins:
  0;
  1, 0;
  2, 2, 0;
  3, 4, 3, 0;
  4, 6, 6, 4, 0;
  5, 8, 9, 8, 5, 0;
  (...)
If an additional 0 was added at the beginning, this would become:
  0;
  0, 1;
  0, 2, 2;
  0, 3, 4; 3;
  0, 4, 6, 6, 4;
  0, 5, 8, 9, 8, 5;
  ... (End)
		

Crossrefs

J_3: A114327; J_1^2, J_2^2: A141387, A268759.
Cf. A000292 (row sums), A000332 (triangle sums).
T(n,k) for values of k:
A005843 (k=2), A008585 (k=3), A008586 (k=4), A008587 (k=5), A008588 (k=6), A008589 (k=7), A008590 (k=8), A008591 (k=9), A008592 (k=10), A008593 (k=11), A008594 (k=12), A008595 (k=13), A008596 (k=14), A008597 (k=15), A008598 (k=16), A008599 (k=17), A008600 (k=18), A008601 (k=19), A008602 (k=20).

Programs

  • Magma
    /* As triangle */ [[k*(n-k): k in [1..n]]: n in [1.. 15]]; // Vincenzo Librandi, Jan 30 2016
    
  • Mathematica
    Flatten[Table[(j - m) (j + m + 1), {j, 0, 10, 1/2}, {m, -j, j}]] (* Bradley Klee, Jan 29 2016 *)
  • PARI
    {for(n=1, 13, for(k=1, n, print1(k*(n - k)," ");); print(););} \\ Indranil Ghosh, Mar 12 2017

A141387 Triangle read by rows: T(n,m) = n + 2*m*(n - m) (0 <= m <= n).

Original entry on oeis.org

0, 1, 1, 2, 4, 2, 3, 7, 7, 3, 4, 10, 12, 10, 4, 5, 13, 17, 17, 13, 5, 6, 16, 22, 24, 22, 16, 6, 7, 19, 27, 31, 31, 27, 19, 7, 8, 22, 32, 38, 40, 38, 32, 22, 8, 9, 25, 37, 45, 49, 49, 45, 37, 25, 9, 10, 28, 42, 52, 58, 60, 58, 52, 42, 28, 10
Offset: 0

Views

Author

Roger L. Bagula, Aug 03 2008

Keywords

Comments

Construct the infinite-dimensional matrix representation of angular momentum operators (J_1,J_2,J_3) in Jordan-Schwinger form (cf. Harter, Klee, Schwinger). The triangle terms T(n,k)=T(2j,j+m) satisfy:(1/4)T(2j,j+m) = = . Matrices for J_1^2 and J_2^2 are sparse. These diagonal equalities and the off-diagonal equalities of A268759 determine the only nonzero entries. Comments on A268759 provide a conjecture for the clear interpretation of these numbers in the context of binomial coefficients and other geometrical sequences. - Bradley Klee, Feb 20 2016
This sequence appears in the probability of the coin tossing "Gambler's Ruin". Call the probability of winning a coin toss = p, and the probability of losing the toss is 1-p = q, and call z = q/p. A gambler starts with $1, and tosses for $1 stakes till he has $0 (ruin) or has $n (wins). The average time T_win_lose(n) of a game (win OR lose) is a well-known function of z and n. The probability of the gambler winning P_win(n) is also known, and is equal to (1-z)/(1-z^n). T_win(n) defined as the average time it takes the gambler to win such a game is not so well known (I have not found it in the literature). I calculated T_win(n) and found it to be T_win(n) = P_win(n) * Sum_{m=0..n} T(n,m) * z^m. - Steve Newman, Oct 24 2016
As a square array A(n,m), gives the odd number's index of the product of n-th and m-th odd number. See formula. - Rainer Rosenthal, Sep 07 2022

Examples

			As a triangle:
  { 0},
  { 1,  1},
  { 2,  4,  2},
  { 3,  7,  7,  3},
  { 4, 10, 12, 10,  4},
  { 5, 13, 17, 17, 13,  5},
  { 6, 16, 22, 24, 22, 16,  6},
  { 7, 19, 27, 31, 31, 27, 19,  7},
  { 8, 22, 32, 38, 40, 38, 32, 22,  8},
  { 9, 25, 37, 45, 49, 49, 45, 37, 25,  9},
  {10, 28, 42, 52, 58, 60, 58, 52, 42, 28, 10}
From _Peter Munn_, Sep 28 2022: (Start)
Square array A(n,m) starts:
  0,  1,  2,  3,  4,  5,  6,  7, ...
  1,  4,  7, 10, 13, 16, 19, 22, ...
  2,  7, 12, 17, 22, 27, 32, 37, ...
  3, 10, 17, 24, 31, 38, 45, 52, ...
  4, 13, 22, 31, 40, 49, 58, 67, ...
  5, 16, 27, 38, 49, 60, 71, 82, ...
  6, 19, 32, 45, 58, 71, 84, 97, ...
...
(End)
		

References

  • R. N. Cahn, Semi-Simple Lie Algebras and Their Representations, Dover, NY, 2006, ISBN 0-486-44999-8, p. 139.

Crossrefs

[0, 0] together with the row sums give A007290.

Programs

  • Mathematica
    T[n_, m_] = n + 2* m *(-m + n);
    a = Table[Table[T[n, m], {m, 0, n}], {n, 0, 10}];
    Flatten[a]
    (* second program: *)
    Flatten[ Table[2 j + 2 j^2 - 2 m^2, {j, 0, 10, 1/2}, {m, -j, j}]] (* Bradley Klee, Feb 20 2016 *)
  • PARI
    {T(n, m) = if( m<0 || nMichael Somos, May 28 2017

Formula

T(n,m) = n + 2*m*(n-m).
Square array A(n,m) = 2*n*m + n + m, read by antidiagonals, satisfying 2*A(n,m) + 1 = (2*n+1)*(2*m+1) = A005408(n)*A005408(m) = A098353(n+1,m+1). - Rainer Rosenthal, Oct 01 2022

Extensions

Edited by N. J. A. Sloane, Feb 21 2016
Showing 1-3 of 3 results.