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

A077028 The rascal triangle, read by rows: T(n,k) (n >= 0, 0 <= k <= n) = k(n-k) + 1.

Original entry on oeis.org

1, 1, 1, 1, 2, 1, 1, 3, 3, 1, 1, 4, 5, 4, 1, 1, 5, 7, 7, 5, 1, 1, 6, 9, 10, 9, 6, 1, 1, 7, 11, 13, 13, 11, 7, 1, 1, 8, 13, 16, 17, 16, 13, 8, 1, 1, 9, 15, 19, 21, 21, 19, 15, 9, 1, 1, 10, 17, 22, 25, 26, 25, 22, 17, 10, 1, 1, 11, 19, 25, 29, 31, 31, 29, 25, 19, 11, 1, 1, 12, 21, 28, 33, 36, 37, 36, 33, 28, 21, 12, 1
Offset: 0

Views

Author

Clark Kimberling, Oct 19 2002

Keywords

Comments

Pascal's triangle is formed using the rule South = West + East, whereas the rascal triangle uses the rule South = (West*East+1)/North. [Anggoro et al.]
The n-th diagonal is congruent to 1 mod n-1.
Row sums are the cake numbers, A000125. Alternating sum of row n is 0 if n even and (3-n)/2 if n odd. Rows are symmetric, beginning and ending with 1. The number of occurrences of k in this triangle is the number of divisors of k-1, given by A000005.
The triangle can be generated by numbers of the form k*(n-k) + 1 for k = 0 to n. Conjecture: except for n = 0,1 and 6 every row contains a prime. - Amarnath Murthy, Jul 15 2005
Above conjecture needs more exceptions, rows 30 and 54 do not contain primes. - Alois P. Heinz, Aug 31 2017
From Moshe Shmuel Newman, Apr 06 2008: (Start)
Consider the semigroup of words in x,y,q subject to the relationships: yx = xyq, qx = xq, qy = yq.
Now take words of length n in x and y, with exactly k y's. If there had been no relationships, the number of different words of this type would be n choose k, sequence A007318. Thanks to the relationships, the number of words of this type is the k-th entry in the n-th row of this sequence (read as a triangle, with the first row indexed by zero and likewise the first entry in each row.)
For example: with three letters and one y, we have three possibilities: xxy, xyx = xxyq, yxx = xxyqq. No two of them are equal, so this entry is still 3, as in Pascal's triangle.
With four letters, two y's, we have the first reduction: xyyx = yxxy = xxyyqq and this is the only reduction for 4 letters. So the middle entry of the fourth row is 5 instead of 6, as in the Pascal triangle. (End)
Main diagonals of this triangle sum to polygonal numbers. See A057145. - Raphie Frank, Oct 30 2012
T(n,k) gives the number of distinct sums of k elements in {1,2,...,n}, e.g., T(5,4) = the number of distinct sums of 4 elements in {1,2,3,4,5}, which is (5+4+3+2) - (4+3+2+1) + 1 = 5. - Derek Orr, Nov 26 2014
Conjecture: excluding the starting and ending 1's in each row, those that contain only prime numbers are n = 2, 3, 5, 7, 13, and 17. Tested up to row 10^9. - Rogério Serôdio, Sep 20 2017
The rascal triangle also uses the rule South = (West+East+1)-North. [Abstracts of AMS, Winter 2019, p. 526, 1145-VS-280, refers to Julian Fleron] - Michael Somos, Jan 12 2019
As a square array read by antidiagonals, selecting terms that give a remainder of 1 when divided by a prime gives evenly sized squares. For example, when each term is divided by 2, showing the remainder looks like:
1 1 1 1 1
1 0 1 0 1
1 1 1 1 1
1 0 1 0 1
1 1 1 1 1 - Nathaniel J. Strout, Jan 01 2020
T(n,k) is the number of binary words of length n which contain exactly k 1s and have at most 1 ascent. T(n,k) is also the number of ascent sequences avoiding 001 and 210 with length n+1 and exactly k ascents. - Amelia Gibbs, May 21 2024
T(n,k) represents the first and foundational instance R1 of a new family of Pascal-like triangles called Iterated Rascal triangles; A374378 is triangle R2; A374452 is triangle R3. - Kolosov Petro, Sep 28 2024

Examples

			Third diagonal (1,3,5,7,...) consists of the positive integers congruent to 1 mod 2.
The triangle T(n, k) begins:
  n\k  0  1  2  3  4  5  6  7  8  9 10 ...
  0:   1
  1:   1  1
  2:   1  2  1
  3:   1  3  3  1
  4:   1  4  5  4  1
  5:   1  5  7  7  5  1
  6:   1  6  9 10  9  6  1
  7:   1  7 11 13 13 11  7  1
  8:   1  8 13 16 17 16 13  8  1
  9:   1  9 15 19 21 21 19 15  9  1
 10:   1 10 17 22 25 26 25 22 17 10  1
 ... reformatted. - _Wolfdieter Lang_, Dec 19 2017
As a square array read by antidiagonals, the first rows are:
  1,  1,  1,  1,  1,  1, ...
  1,  2,  3,  4,  5,  6, ...
  1,  3,  5,  7,  9, 11, ...
  1,  4,  7, 10, 13, 16, ...
  1,  5,  9, 13, 17, 21, ...
		

Crossrefs

The maximum value for each antidiagonal is given by sequence A033638.
Equals A004247(n) + 1.

Programs

  • Maple
    A077028 := proc(n,k)
       if n <0 or k<0 or k > n then
           0;
       else
           k*(n-k)+1 ;
       end if;
    end proc: # R. J. Mathar, Jul 28 2016
  • Mathematica
    t[n_, k_] := k (n - k) + 1; t[0, 0] = 1; Table[ t[n, k], {n, 0, 12}, {k, 0, n}] // Flatten (* Robert G. Wilson v, Jul 06 2012 *)
  • PARI
    {T(n, k) = if( k<0 || k>n, 0, k * (n - k) + 1)}; /* Michael Somos, Mar 20 2011 */

Formula

As a square array read by antidiagonals, a(n, k) = 1 + n*k. a(n, k) = a(n-1, k) + k. Row n has g.f. (1+(n-1)x)/(1-x)^2, n >= 0. - Paul Barry, Feb 22 2003
Still thinking of square arrays. Let f:N->Z and g:N->Z be given and I an integer, then define a(n, k) = I + f(n)*g(k). Then a(n, k)*a(n-1, k-1) = a(n-1, k)*a(n, k-1) + I*(f(n) - f(n-1))*(g(k) - g(k-1)) for suitable n and k. S= (E*W + 1)/N. arises with I = 1, and f = g = id. - Terry Lindgren, Apr 10 2011
Using the above: Having just read J. Fleron's nice article in Discovering the Art of Mathematics on the rascal triangle, it is neat to note and straightforward to show that when I = 1, a(n, k) + a(n-1, k-1) = a(n-1, k) + a(n, k-1) + (f(n) - f(n-1))*(g(k) - g(k-1)), so with I = 1, and f = g = id, we have S+N = E+W + 1, as his students discovered. - Terry Lindgren, Nov 28 2016
T(n, k) = A128139(n-1, k-1). - Gary W. Adamson, Jul 02 2012
O.g.f. (1 - x*(1 + t) + 2*t*x^2)/((1 - x)^2*(1 - t*x)^2) = 1 + (1 + t)*x + (1 + 2*t + t^2)*x^2 + .... Cf. A105851. - Peter Bala, Jul 26 2015
T(n, k) = 0 if n < k, T(n, 0) = 1, T(n,n) = 1, for n >= 0, and T(n, k) = (T(n-1, k-1)*T(n-1, k) + 1)/(T(n-2, k-1)) for 0 < k < n. See the first comment referring to the triangle with its apex in the middle. - Wolfdieter Lang, Dec 19 2017
E.g.f. as square array: exp(x+y)*(1 + x*y). - Stefano Spezia, Aug 10 2025

Extensions

Better definition based on Murthy's comment of Jul 15 2005 and the Anggoro et al. paper. - N. J. A. Sloane, Mar 05 2011

A128140 A128132 * A004736.

Original entry on oeis.org

1, 3, 2, 7, 5, 3, 13, 10, 7, 4, 21, 17, 13, 9, 5, 31, 26, 21, 16, 11, 6, 43, 37, 31, 25, 19, 13, 7, 57, 50, 43, 36, 29, 22, 15, 8, 73, 65, 57, 49, 41, 33, 25, 17, 9, 91, 82, 73, 64, 55, 46, 37, 28, 19, 10
Offset: 1

Views

Author

Gary W. Adamson, Feb 16 2007

Keywords

Comments

Row sums = A006003, starting (1, 5, 15, 34, 65, 111, ...). Left border = A002061: (1, 3, 7, 13, 21, 31, 43, ...) A128139 = A004736 * A128132

Examples

			First few rows of the triangle:
   1;
   3,  2;
   7,  5,  3;
  13, 10,  7,  4;
  21, 17, 13,  9,  5;
  31, 26, 21, 16, 11,  6;
  43, 37, 31, 25, 19, 13,  7;
  ...
		

Crossrefs

Formula

A128132 * A004736 as infinite lower triangular matrices.
Showing 1-2 of 2 results.